You are most likely turning on software rendering by accessing the texture in the vertex shader. <br><br>Textures are uploaded as 8 bit per component which is the standard for images and video. Changing this to 32 bit floats is extremely inefficient. There might be a way to specify the GPU storage to be 32 bit float, but typically the driver would do the conversion slowly and not the GPU.
<br><br>Render to texture using gemframebuffer with a 'format FLOAT' message will give a float texture to read from in the shaders. I see that you filed a bug that this object does not work on your machine though. Maybe you can try another?
<br><br>You could try changing the code in pix_texture and recompiling. Change the format from GL_UNSIGNED_BYTE to GL_FLOAT to see if that works and speeds it up. The uploaded texture will not contain the right values since the GPU expects a float and the image is still 8 bit.
<br><br>I probably won't have time to work on this for a few weeks, but I want to get the framebuffer working better.<br><br><div><span class="gmail_quote">On 9/9/07, <b class="gmail_sendername">cyrille henry</b> <
<a href="mailto:cyrille.henry@la-kitchen.fr">cyrille.henry@la-kitchen.fr</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
hello,<br><br>i'm tring to do more physics on the GPU, and i'm facing some problems.<br>simulation results can be compute on texture (just like the wave example i send month ago), so now i'd like to use this texture to move vertex.
<br><br>if i acces to a texture with a vertex shader just like on a fragment shader, then it's very slow.<br>(cpu is at 100%)<br><br>i found that :<br>"vertex textures must be 32-bit-per-component textures, floating point, and they can't use any filtering mode except nearest filtering."
<br><br>i tryed "quality 0" to pix_texture in order to have the nearest filtering mode, but i'm not sure about the 32 bit per component texture.<br>is it the default on Gem?<br>if no, is it possible to change it?
<br><br>anyone already have an exemple how to use a texture to displace vertex?<br><br><br>thanks<br><br>cyrille<br><br>_______________________________________________<br>GEM-dev mailing list<br><a href="mailto:GEM-dev@iem.at">
GEM-dev@iem.at</a><br><a href="http://lists.puredata.info/listinfo/gem-dev">http://lists.puredata.info/listinfo/gem-dev</a><br></blockquote></div><br>