Thnks for Reply.
Here is my abstract code of Prioritize Texture.
/* settings */
int max_texturs = 16;
glGenTextures( max_textures , texture_id );
for( i=0;i<max_textures;i++ ){
glBindTexture( GL_TEXTURE_3D_EXT , texture_id[i] );
glTexImage3DEXT( … );
}
GLfloat priority[]={1,1,1,1, 1,1,0,0, 0,0,0,0 , 0,0,0,0 };
glPrioritizeTextures( max_textures , texture_id , priority );
/* display routine ( call by glutDisplayFunc, Redraw by glutPostRedisply ) */
GLboolean status[max_textures];
glAreTexturesResident( max_textures , texture_id , status );
print_resident_status( sttus );
for( i=0;i<max_textures;i++ ){
glBindTexture(GL_TEXTURE_3D_EXT,texture_id[i] );
draw_texture();
}
I hope that texture_0 to texture_5 stay on textuer memory.
(disired status)
(1)1,1,1,1, 1,1,0,0, 0,0,0,0, 0,0,0,0
(2)1,1,1,1, 1,1,0,0, 0,0,0,0, 0,0,0,0
…
but in fact, each dispay callbacks, glAreTextureResidents returns following result.
(sample returned status)
(1)1,1,1,1, 1,1,1,0, 0,0,0,0, 0,0,0,0
(2)0,1,1,1, 0,0,1,0, 1,0,0,0, 0,0,1,1
(3)0,0,0,0, 1,1,0,0, 1,0,0,1, 1,1,0,1
Why don’t stay prioritized textures on texure memory?