Quote Originally Posted by itsmeandnobodyelse View Post
It sounds as if the video controller runs out-of-memory. If so, one of the pointers in the assign statement probably is NULL and that's why an exception was thrown ...

Can you tell where in your code allocations were made? (In calls to OpenGL)
thank you

if I understand properly, you mean the location of the exception?
the debugger points to the line of code where the pixels values are assigned to the array of pointers after reading the buffer with glReadPixels, the pixels values are saved in an array pixels_index_temp and assigned to pixels_index array

pixels_index[global_index] = pixels_index_temp[local_index];

the global array pixels_index is going to be displayed on screen after the whole scanning process

I hope I answered your question
many thanks to you