Live data from Hacker News

Show HN: My first WebGL demo, the first self-extracting PNG ever?

demoseen.com

31–40 of 56 posts

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#31
post #20

Earlier quoted context omitted.

Only thing I can think of at this point is that you have an extension inserting something into the body before the canvas. While on Magister, drop javascript:alert(document.body.firstChild) into the address bar and see if you get the canvas -- if not, that's the problem.

The tab crashes after a while when I try that. Weird. Even with all extensions disabled, it hangs without ever finishing loading.

Old version of chrome perhaps? Works fine on my chrome on osx here. 12.0.742.122 here. (I'm technically out of date too, mostly because I haven't restarted chrome in a while)

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#32
post #24
post #23

Earlier quoted context omitted.

It's fairly GPU intensive, and if Windows Vista/7 don't get a response from the GPU after a short period of time, it'll restart the drivers. Happens every once in a while even on newer GPUs, unfortunately.

Ah. So your interpretation is not that the driver actually crashed, but that it simply was overwhelmed by the workload, and didn't respond properly within the timeout limit as set by the OS?

Windows watchdog kills tasks running on a GPU after ~5 seconds (using CUDA) same might apply here

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#33
post #5
post #4

Earlier quoted context omitted.

Pretty cool hack! I'm looking forward to the blog post. It doesn't seem to eat my processor too much. In Chrome with AMD processor it's sitting at about 25% CPU usage.

Thanks! It isn't too be on the CPU for most people, but for some reason it's eating a massive chunk of CPU-time for some people -- seems to be only in the latest Firefox nightlies, but i'm not seeing it here, so I'm unsure of what it could be.

Just to add another token data point. I have it up full screen at 1920x1200. CPU usage is sitting between 50 and 75% of one core and GPU usage jumps back and forth between 40% for a few seconds and then 80% for a few seconds. This is using Chrome 14.0.814.0 dev-m

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#34
post #31

Earlier quoted context omitted.

The tab crashes after a while when I try that. Weird. Even with all extensions disabled, it hangs without ever finishing loading.

Old version of chrome perhaps? Works fine on my chrome on osx here. 12.0.742.122 here. (I'm technically out of date too, mostly because I haven't restarted chrome in a while)

Nope, I'm on the same version as you, although it tells me that's the latest version.

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#35

So, it the header makes it look like a PNG: magister.html: PNG image data, 1242 x 1, 8-bit grayscale, non-interlaced If you look at this in an image viewer, it's as advertised: a long black bar. So what this is is some garbage data with a PNG header, a token PNG image, and some HTML that bootstraps a javascript program whose main body looks like binary garbage. But it's not a self-extracting PNG, it's a very strange…

You were right up until saying it was garbage data. The image data is the demo code itself. This is a real PNG, even if it looks random.

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#36
post #20

Earlier quoted context omitted.

I cannot, although all of the demos I've tried here work: http://www.khronos.org/webgl/wiki/Demo_Repository

Only thing I can think of at this point is that you have an extension inserting something into the body before the canvas. While on Magister, drop javascript:alert(document.body.firstChild) into the address bar and see if you get the canvas -- if not, that's the problem.

Same situation as the rest of this thread - I just get cpu usage and a white screen, in Chrome stable/beta/dev. OSX on a MBP, only thing I can think that might be shared with others having problems is my GPU: GeForce 8600M GT. I haven't heard of problems with this card before, but OSX + GPU ≠ consistent results, at times.

Though interestingly, the behavior in all three Chromes is wildly different: Dev runs 60% CPU use in the rendering process, Beta sometimes uses nothing, sometimes 60%, and Stable uses the same 60% + 120% on "google chrome helper". The alert test works (shows a canvas element) in both Dev and Beta, Stable shows me a "page unresponsive" after a couple seconds and never alerts anything.

Other GL tests work just fine in all 3. I'll be happy to test other things if you can come up with them :)

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#38
post #10
post #6

Earlier quoted context omitted.

Do you have a quad core CPU by chance? 25% is the max that a single-threaded process would use. (Someone please correct me if this is wrong, but at least this is the behavior I've observed.) That being said, this uses only 10-12% CPU on my quad-core machine.

It depends on what you use to report CPU usage. Many monitoring tools stick with 100%/core, but some normalize it.

Good point. I believe Windows' task manager reports it the way I said, while OS X's Activity Monitor reports each core up to 100%.

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#39
post #11

Apologies, but nothing happens when I view it. Running Chrome 12.0.742.122. I see the initial raw PNG splat, but get nothing but a lot of high cpu and a blank browser screen after running a couple minutes.

For what its worth, it seems to be running now without any changes on my part.

Re: Show HN: My first WebGL demo, the first self-extracting PNG ever?

#40
post #39
post #11

Apologies, but nothing happens when I view it. Running Chrome 12.0.742.122. I see the initial raw PNG splat, but get nothing but a lot of high cpu and a blank browser screen after running a couple minutes.

For what its worth, it seems to be running now without any changes on my part.

Wow, that's strange. No changes here either. Wonder what's going on.
Post reply on HN