why are you wasting so much time optimizing
a gimmick effect that is pretty much unwatchable after
couple seconds and dont optimize something else
and if one of your answers is
1)because i can ,well there better things to optimize
2)like what , i dont know work on something interactive
you strike me as a smart person dont confine yourself
with just this
FrozenVoid, why don't you make a canvas-based danmaku game?
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-03 10:14
>>162
Its called recreational programming or hacking: I'm not a code monkey assigned to optimize indian bloatware or open source developer striving to develop a "product".
>>165
Then hack a bit and optimize something useful, such as Hurd. You don't have to try to finish it, just improve it.
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-03 10:27
>>167
I don't "join open source projects".
I could take the code, optimize it and post to pastebin, but i will not "distribute" or "support" anything
And i certainly don't want to optimize GNU/Turd ancient code.
>>169
In open source terms i will "fork the code", and i will not improve your code i will improve my code.
Name:
Anonymous2011-11-03 10:34
>>171
Okay, do that.
As long as your code is also published under a free license, the original project can benefit from it. Also, your fork may actually be better than the original. Both are Good.
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-03 10:40
>>172
>your code is also published
I'd use creative commons for my code, but since i won't support it i won't "publish"
A fork quality is dependent on effort spent into it.
I can optimize a small 10kb script all day long with minimum effort but OS development is far more resource intensive.
LoseThos author spent 9 years to write a VGA-only Multiuser DOS clone.
If you consider effort/reward ratio for OS development(very low), its useless for hacking unless the OS itself is very small.
OS performance is not a primary goal in most cases: usability/security/design always trumps such concerns as absolute algorithmic speed(i.e. there is no point optimizing it for speed,unlike an abstract algorithm).
The idea that developing an OS is serious, productive and respectable work while coding a script is useless gimmick is like comparing
people working at orchestra and people playing a violin at home.
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-03 11:07
If you can find an algorithm(source code in JavaScript or C(i dislike debugging complex C code, but i like to write low-level bithacks which require C)) where
1.Performance is ultimate concern
2.Algorithm can be tested many time per hour
3.Its provides a useful effect,feature or some other result which depends on performance.
I'll copy it to my script folder and optimize it,
if it works better, i'll post it on /prog/ and my subreddit.
Name:
Anonymous2011-11-03 11:28
>>176
>Optimizing algorithms instead of software
Are you a Computer Scientist?
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-03 11:53
>>177
I suppose I am in some form a computer scientist, but my field of "science" is more about hacking algorithms and far removed from writing papers or proving theorems(i.e. i'm more concerned about algos as code, rather then their theoretical properties)
When i use a sine formula, i use it like a tool, i don't intend to comprehend it as long as it works(unlike a computer scientist who would describe its algorithmic complexity, minimal running time or some arcane abstract proof from algorithmic theory)
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-03 12:56
I can see the gulf between theoretical computer science and algorithm hacking as
1. the first is all about the purity of form, the algorithm has to be expressed as succinctly as possible(lambda calculus, function combinators)
2. the second is all about the purity of essence, stripping the code from internal cruft and removing inefficiency, the algorithm external look is irrelevant.
Name:
Anonymous2011-11-03 12:58
>>179
So you say computer scientists are Protoss and hackers are Zerg?
the code is a huge mess someone should put some comments
if it to be redistributed
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-04 14:08
>>187
>is a huge mess
Pretty clear to me. it precomputes a chain of tables, saves indexes to wint array and displays them frame by frame.
New version is more CPU-intensive but uses 4 times less memory(since it stores 8 bits per pixel(index)).
Name:
Anonymous2011-11-04 14:10
its pretty clear to you that spent so much time with it
if you want someone to immediately get a grip
comments are a necessity especially
when the code is a mess
>>190
How on earth that code has been mutated into >>193
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-04 15:16
>>194
>I am to lazy to read the entire thread, please post an outline
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-04 17:11
http://pastebin.com/61361hxi
Better dispframe() performance with unrolled convert loop.
render speed is the same:
120frames at 3360ms
30 frames at 902 ms
Name:
Anonymous2011-11-04 17:24
>xsum*((((xsum>=0)|0)<<1)-1)
What the fuck?
Name:
FrozenVoid!!mJCwdV5J0Xy2A212011-11-04 17:35
>>197
A way to calculate absolute value. Its just an alternative to express x*( x>0?1:-1) without the ternary.
Math.abs is faster(due fact JS converts doubles to int32 each time a bitwise operation is required and back.)
Name:
Anonymous2011-11-04 17:42
>>197
Wouldn't something like xsum - 2 * xsum * (xsum<0) be simpler?