Hey could i ask you another question on texturing?
Thanks:
So i would like to use the gl function described in the last message. But it says that this function copy an area of the framebuffer in the current texture. But my application uses many textures, so how can i do to say to this function to write in a selected texture???
I’m kinda doing the same type of thing only instead of normals I need half angle vectors for per pixel specular highlights. My changes seem to be more organized than yours will be but I still found it too random of changing to actually change via a systamatic method. I don’t understand how you plan to do something like that fast with glCopyTexSubImage2d but mybe you can. I was trying to use the color matrix for my method which would have been super fast but it just couldn’t work. Now I will just take a snap shot of the volume now cause it will take over 5 seconds to generate all these new half angle textures. Once the nv20 comes out though I should be set.
Do you want to replace a part of your texture with some texture data og some part of the frame buffer, because glCopyTexSubImage2D is damn slow, and if you want to change part of a texture with your own texturedata use glTexSubImage2D.
The using dynamic textures is heavily affects the fps rate. The program I wrote uses the following scheme: in every frame I upload a 128x128 texture (rgba) to render a projected shadow for an object. I every 30. frame I upload 2 256x256 textures to modify the outlook of an object. And you can see it. Even in a geforce class card. Little slowdowns.
My advice is: use glTexSubImage, and update the necessary region only.
I talked of this subject with a friend of mine and he said to me that there is an extension nvidia with which u can write directly in the texture memory.
Does anyone know this extension???