Original Post
Hello, I've got a problem with texture borders. I want to display video data using openGL and do some convolutions on it using Cg. The camera data is 640x480. I fetch the camera data, upload it to a texture and possibly do some convolutions, and then display the data. Unfortunately openGL (unless using extensions) requires power of 2 texture sizes, so i upload the data with subImage2D to a 1024x1024 texture. Because of this the videodata borders are not the texture-borders. So when i do convolutions or display the data when the texture is made with GL_LINEAR, i get errors at the edges of the video-data because the convolutionfilters and GL_LINEAR uses data from the texture wich is not part of the videodata. So my question is: Is there some way to set the borders from a texture at a differnent position. (eg. make GL_CLAMP clamp to range [0, 0.2476] or something) or do I have to use extensions to create a non-power-of-2 texture? Or is there another way perhaps. Thanks in advance [Edited by - Dybbuk on April 14, 2005 4:16:19 AM]