Live data from Hacker News

Web GL Ocean Simulation

david.li

121–130 of 138 posts

Re: Web GL Ocean Simulation

#123
post #53

Earlier quoted context omitted.

Because you can see the code does not mean you have the right to distribute it. With your argument you mean it is ok to record music from some music service and post this wherever you like just because it is possible? Ability to do something does not mean it is ok to do it.

I'd argue that it WOULD be okay to repost sound files. Just because someone was the first to string together a set of information means that nobody else is allowed to share it?

Please look up copyright. I know the concept of magical numbers that nobody is allowed to duplicate is grating, but this is what business and life is built on.

As a musician, if I posted a piece of music to a site that permitted it to be played in their Flash player on the site, this does NOT mean I want it to be distributed does it? Unless I explicitly stated that it was alright to distribute it.

EDIT: I didn't mean this to come across as snappily as it did btw!

Re: Web GL Ocean Simulation

#124
post #74

Might be system dependent, though couldn't help but notice a non-trivial difference in the OpenGL rendering quality, between Firefox and Chrome. Chrome 32 beta on OS X, produced an anti-aliased canvas, whereas Firefox 25 had the dreaded jaggies @ 1680x1050

I have the same thing in Win and Linux.

Re: Web GL Ocean Simulation

#125
post #104

I really like the layout of the controls, it's a mix between infographics & some movie-like GUI and it works pretty well.

I can't use the controls at all (Chrome, OS X). Clicking the sliders just moves the whole plane around.

Re: Web GL Ocean Simulation

#126
post #35

Earlier quoted context omitted.

Just to clarify - the bulk of the work here is done in GLSL shaders on the GPU, not with matrices in JavaScript. All that matrix code you see in the source here is basically just the minimum prerequisite for doing 3D graphics, it would be the same if you just wanted to get a spinning cube with some camera control. The real magic happens in the shaders which compute water mesh displacement, normals and shading directl…

>basically using graphics rendering pipeline to do GPGPU without need for OpenCL / CUDA It would be really cool to see a project that would make that easier to do in JS more generally. Basically a similar idea to Parakeet or Numba, but with GLSL as a target.

How about WebCL? http://www.khronos.org/webcl/

Re: Web GL Ocean Simulation

#127
post #11

> Your browser does not appear to support the required technologies. It would've been nice to have an 'I don't care, proceed anyway' button. The check excludes Safari 7, which runs the demo just as well as Chrome. http://jsfiddle.net/bYHfh ^ removes the hasWebGLSupport() invocation. Very nice demo, though!

I am on latest chrome on win8, I still get that message. I guess it needs something more powerful than the onboard GPU I have.

I'm using the onboard/ondie Intel HD4000 and it works. You might have a driver that is blacklisted. Chrome and I think other browsers have a list of drivers known to allow execution of dangerous shader code and block WebGL in those cases.

Re: Web GL Ocean Simulation

#128
post #107

Earlier quoted context omitted.

1999 navier stokes solver on GPU: http://www.cs.unm.edu/~mskarim/fluid_smoke_gpu.htm I was doing this in college 10 years ago. Cmon now.

It won't impress anyone on the internet until you port it to WebGL.

I wasn't trying to say this simulation isn't rad (it is) but the idea that the contribution here is that it does fluid dynamics on the gpu is absurd

Re: Web GL Ocean Simulation

#129
post #70

computers have now become so powerful that this stuff is easy. you can implement it in a way which, aside from platform, is really quite naive and wasteful - and still get applause. most programmers can come up with a much better solution to this problem if removed from google and forbidden access to gpu gems. this is at least well presented though... its a shame the code has been posted. whilst i normally assume tha…

What is wrong with this solution?

Re: Web GL Ocean Simulation

#130

The code is quite cool to look at. Love seeing the extensive use of matrices and mathematics to create such a beautiful and mesmerizing display. If anyone is interested in playing around with it, I threw it up at JSFiddle here: http://jsfiddle.net/zyAzg/ Excellent demo.

I wonder if it was all handwritten. Esp. functions like invertMatrix or premultiplyMatrix. Or what he used to generate the code. I once used WolframAlpha to get me some complicated formulas and wrote a custom WA-plaintext-output-to-C translator for that output to use it in my code. Here is the script: https://github.com/albertz/helpers/blob/master/wolframalpha_... Example input: http://www.wolframalpha.com/input/?i=s…

For cases where the most basic simplifications are enough (0*x=0 etc.) there is this one: http://glat.info/flatorize/
Post reply on HN