sorry if this is a little off topic, but i havent been to these forums in a while.
i am trying to get data from a video4linux supported tv card to a OpenGL texture map in linux. so far, i have it working, but its very slow, and im having trouble figuring out how to speed things up. my current code looks something like this (its all spread out in various functions, but this is about how it goes):
int width = 384;
int height = 288;
int size = width * height * 4;
//set everything up
while( running )
read( vidfile, frame, size );
glTexSubImage2D( GL_TEXTURE_2D, 0, 0, 0, width, height, GL_BGRA, GL_UNSIGNED_BYTE, frame );
//draw quad with texture
ive done everything i can to remove any calculations being made in the execution loop, but unfortunately this is still slower than i need it to be. i tried mmaping the file to the memory i need, but i cant get the card to give me any data that way. is there a faster way to do this with read() or is read() just too slow?
thanks for any help
[This message has been edited by Spiral Man (edited 07-26-2003).]