

Fl0wer.png.html - ent
http://demoseen.com/windowpane/fl0wer.png.html

======
daeken
Huh, didn't think this would be posted. This is a little demo effect I threw
together last week when I was bored. It's built on top of WebGL (the effect
itself is really just in a shader), and the reason it looks like a PNG is that
it's a self-extracting PNG as described in my article here:
<http://daeken.com/superpacking-js-demos>

------
icebraining
(Note: I'm not blaming anyone!)

Impressive: Firefox hold fine and rendered it, but after I opened it the
second time, _all_ the text in my system (that includes the browser, but also
the terminals, Awesome, etc) was FUBAR - even after restarting the X server!

I have no idea what kind of bug leads to only the text being corrupted (so, it
doesn't seem a bug in the graphic drivers, since AFAIK they're agnostic to
that) but survives restarting the display manager.

~~~
cydonian_monk
I've had similar experiences with graphical corruption in X, and Firefox was
almost always involved. Same radeon driver as you. And it seems to be distro-
agnostic: I've seen it with Arch, Gentoo and Mint. All I know is that it's a
recent thing: if I run an older version of my Gentoo build, it doesn't happen.
But otherwise I see the same results.

I have no idea what to point to, because it's really weird. Scrambles
/everything/ that goes through video. (And until now, I figured it was a quirk
of my bizarre hardware. Guess not.)

~~~
dfc
its a bug with cairo and the radeon driver:

<https://bugs.freedesktop.org/show_bug.cgi?id=47266>

on debian you can pin libcairo to fix the issue. /etc/apt/preferences:

    
    
      Package: libcairo2
      Pin:version 1.10.2-7
      Pin-Priority: 1001
    
      Package: libcairo-gobject2
      Pin:version 1.10.2-7
      Pin-Priority: 1001

~~~
lloeki
Fantastic. I've been trying to pinpoint the cause of it since aeons. It's
absolutely dreadful in awesome wm and at some point I laid the blame on
(cairo-)XCB, or some Xft bug, but it cropped back too, only less often, under
gnome/xfce.

------
zokier
I think the comments hilight very nicely why some people are not all that
thrilled about having OpenGL in their browsers in the form of WebGL. Graphics
drivers seem to be extremely difficult to "get right", especially if any
degree of performance is wanted.

~~~
willvarfar
My considered opinion (from the industry) is that its really shocking how
under-invested-in the drivers are.

If a fraction of the effort that went into making the card went into making
the drivers and maintaining and fixing them, we'd all be massively better off.

~~~
modeless
The problem may be too much investment in drivers. Modern graphics card
drivers are little operating systems unto themselves; they even have built-in
compilers. They are incredibly complex, yet written in unsafe languages for
maximum performance, with tons of ugly hacks for compatibility.

What we really need is a simplification of graphics APIs so that graphics
drivers don't need to be so complex. That may be impossible without
convergence in hardware though.

~~~
willvarfar
Not really.

That graphics drivers are a mess internally says more about the insufficient
resourcing to do it properly and cleanly and refactor than it does about the
really rather trivial and well-understood APIs that the driver implements.

~~~
modeless
You think OpenGL and DirectX are "trivial"? I'm sorry, but an API that
involves passing text strings of complete programs for the driver to compile,
link, and asynchronously run on a vector coprocessor is _not_ trivial to
implement, not to mention the complex NUMA memory management going on.

------
Cushman
I think we need to start using a [WebGL] tag or something for these...
obviously some browsers don't take it well, and it would keep a lid on all the
(kinda pointless) "Doesn't work"/"works for me" comments.

Works for me. Super cool.

~~~
sigmaxipi
In some cases, it's even worse. Low end netbooks running Chrome will load the
page and then the entire machine locks up as the WebGL starts rendering and
takes over the weak GPU. Easy way of DOSing someone is to send them a WebGL
link if they're on a weak computer.

------
zbowling
It worked the first time in chrome. Crashed it the second time. Very clever.

The blackhat-spidy-sense in me is getting a tingle. XSS injection if a PNG
could used to execute javascript possibly.

~~~
daeken
This can't be used for XSS or the like, really. The way it works is that the
PNG is first interpreted as HTML by the browser (hence the filename) and then
it loads itself into an image tag, causing it to be interpreted as a PNG. Once
it's loaded into the image tag, the image is drawn to a canvas so that the
code -- embedded in the PNG -- can be extracted and executed.

While fun, the only real security concern here is that it's really good at
pissing off IDSes.

Edit: I linked my article describing the technique in another comment here if
you want to see how horrible it really is. I'm always both proud of and
disgusted by myself for this technique.

~~~
zbowling
I just dug into and can confirm. MIME is returned as text/html and browser
reads it as such. still very clever.

It's actually kind of a good test of browser compliance in a sick way.

~~~
willvarfar
The Duff's Device of browsers? :)

------
PStamatiou
This crashed my mac entirely. avoid.

~~~
njharman
If viewing a web page crashes your OS, seriously, you need to take that crap
back and get a refund.

~~~
lloeki
How do I get a refund on my Arch setup? Seriously, WebGL talks to the driver
almost directly. All it takes is a browser/driver bug and the whole display
stack goes down, possibly bringing the OS with it.

~~~
TazeTSchnitzel
Good thing we don't use composited rendering these days, or rely on hardware-
accelerated interfaces.

Oh wait.

------
jes5199
Works on Chrome/MacLion

... but I'm not sure what it's _doing_

------
wordsaretoys
If you're having WebGL/video driver issues and you'd like to assist the
developers in fixing them, here's a link to a crowdsourced driver test at
Khronos: <http://www.khronos.org/webgl/wiki/CrowdsourcingDriverTesting>

------
machrider
Not seeing anything (totally white browser) in both Firefox 12 and Chromium 18
on Ubuntu.

~~~
TazeTSchnitzel
>Ubuntu

There's your problem. Are you using an ATI card, by the way?

Make sure you have restricted drivers installed. If you're using an ATI card
you'll have to do the further step of going to about:flags in Chrome and
making it ignore the software rendering blacklist.

~~~
machrider
Actually I'm on a nVidia Quadro card with the Nouveau driver.

------
DiabloD3
All I see is the text "‰PNG  IHDR[$‘þVœjawh". MIME type screw up server
side?

------
Jach
NoScript is the new subject for "I run Linux, I don't have to worry about..."
But after I enabled scripting it worked fine, very neat-looking demo. Also I
admit that I enjoy reading about the problems of others here...

------
unicornporn
Crashed Firefox 12 on OS X. Crashed latest Opera Mobile on Android ICS.

------
pooriaazimi
Shame. It's not working on Safari 5.2 beta (Lion 10.7.3); nor does it work in
Opera, or any of iOS browsers. But is fine on both Chrome and Firefox...

I'm sure Safari supported WebGL...

~~~
eridius
There's an option in the Develop menu to enable WebGL, but even with that on
this doesn't work.

------
benguild
Doesn't work in Safari.

------
ent
The file seems to be a png with some html tags in it that trick the browser.
Seems to work on firefox and conkeror but not on my chromium.

~~~
ComputerGuru
Works in Chrome/Windows.

------
swhitt
Ah! My browser! I lost my thesis :(

~~~
icebraining
What kind of crappy online editor are you using that doesn't save
continuously?

~~~
moconnor
Office Live. You have to click on the save button. I'm not even making this
up.

~~~
lloeki
You mean the one with a floppy disk (honest question: I'm not even remotely a
Office Live user)?

------
martindale
Doesn't work on Chromium/Ubuntu.

18.0.1025.151 (Developer Build 130497 Linux) Ubuntu 12.04

~~~
sohn
Same here.

~~~
TazeTSchnitzel
1) Restricted Drivers

2) about:flags disable software rendering blacklist

------
simplyinfinity
Had no effect in Opera 12 alpha with HW acceleration and webgl turned on, just
black screen

------
saturn7
Works, Amazing, I think you accidently just created a way to hypnotize people
in a second.

------
gphilip
Shouldn't there be some kind of seizure warning to go with the link?

------
TazeTSchnitzel
Goes well with trance music. Keep forgetting it's not in the demo.

------
NDizzle
I'm freakin' out, man!

------
xkcdfanboy
This crashed my OSX Lion running Chrome, lost all my work and had to reboot.
Just tested Firefox too, crashes as well. Safari doesn't load anything, just a
bunch of PNG binary text? Might want to work on compatibility ;)

~~~
dewiz
.. same platform but none of the problems you experienced, perhaps you're
using some old versions ?

------
kba
What is this supposed to do, other than attempt to crash my browser?

