jeromeetienne / tasks

Stuff todo
0 stars 0 forks source link

port compressed texture in three.js #4

Closed jeromeetienne closed 12 years ago

jeromeetienne commented 12 years ago
[10:50am] jetienne: anybody tried or even succeed to use compressed texture with three.js ?
[10:50am] jetienne: https://github.com/mrdoob/three.js/blob/master/src/renderers/WebGLRenderer.js#L6225 it seems not possible right now
[10:56am] coffeecup: mhh, the only way to pass colors of other vertices to the fragment shader is with a texture map?
[11:01am] mrdoob: jetienne, compressed texture? is there a webgl example of that?
[11:04am] jetienne: http://blog.tojicode.com/2011/12/compressed-textures-in-webgl.html
[11:05am] jetienne: mrdoob: i was looking. it seems easy to add at first sight. adding a THREE.*Format constant. Change code creation with gl.compressedTexImage2D()
[11:07am] mrdoob: and a new extension check
[11:07am] mrdoob: WEBKIT_WEBGL_compressed_texture_s3tc
[11:07am] jetienne: mrdoob: yeah i was thinking about that. with anisotropic… what is the policy of three.js on that ?
[11:08am] mrdoob: how do generate a DDS file?
[11:08am] mrdoob: *do you
[11:08am] jetienne: tojiro talks about a tool
[11:09am] jetienne: http://code.google.com/p/crunch/
[11:09am] jetienne: but I'm think there is easier
[11:09am] jetienne: maybe imagemagick
[11:09am] mrdoob: ah, I remember crunch having some patent issues
[11:10am] jetienne: http://trac.imagemagick.org/browser/ImageMagick/trunk/coders/dds.c
[11:10am] jetienne: mrdoob: yeah imagemagick seems able to do something
[11:11am] mrdoob: I see, I see
[11:11am] jetienne: mrdoob: will you give it a shot ?
[11:11am] mrdoob: I haven't seen that being the bottleneck in any project yet
[11:11am] mrdoob: there are other things I can work on that could be more beneficial I think
[11:12am] jetienne: apparently compressed texture are faster to render… so i have been told
[11:12am] mrdoob: but feel free to send over a patch
jeromeetienne commented 12 years ago
 Nadir:  Oui, il utilise la commande nvcompress disponible après l'installation du paquet libnvtt-bin prévu par NVidia
 me:  imagemagick convert got support no ?
 Sent at 11:32 on Tuesday
 Nadir:  It seems not to supprt dds format
jeromeetienne commented 12 years ago

Do it if it is simple! Else drop it

Launch github issue?: how to implement texture compression

jeromeetienne commented 12 years ago

Done https://github.com/mrdoob/three.js/issues/2348