-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OpenGL textures problem #72
Comments
Could you post the code that triggers the bug please? |
Here are more detailled code: glBindTexture(GL_TEXTURE_2D,textureid); glDisable(GL_DITHER); glEnable(GL_TEXTURE_2D); glEnableClientState(GL_VERTEX_ARRAY); glVertexPointer(3,GL_FLOAT,sizeof(tvertex),(gx_void *)tmpvertex); pvertex=tmpvertex; glTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,256,256,0,GL_BGRA,GL_UNSIGNED_BYTE,picturebuffer1); glTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,256,256,0,GL_BGRA,GL_UNSIGNED_BYTE,picturebuffer2); glDepthMask(GL_TRUE); glXSwapBuffers(display,window); |
Is is any of this code called in a loop? You've only called It's strange that you're seeing the second texture before you have uploaded it to the graphics card. |
This is a part of a code used to display a picture on screen. |
Have you tried the code on another platform? |
Yes, it display correctly on other platforms. #include <stdio.h> int main(int argc, char* argv[]) if (!display) // Get a matching FB config printf( "Getting matching framebuffer configs\n" ); // Pick the FB config/visual with the most samples per pixel int i;
} GLXFBConfig bestFbc = fbc[ best_fbc ]; // Be sure to free the FBConfig list allocated by glXChooseFBConfig() // Get a visual printf( "Creating colormap\n" ); printf( "Creating window\n" ); // Done with the visual info data XStoreName( display, win, "GL 3.0 Window" ); printf( "Mapping window\n" ); // Get the default screen's GLX extension list GLXContext ctx = 0; ctx = glXCreateNewContext( display, bestFbc, GLX_RGBA_TYPE, 0, True ); // Sync to ensure any errors generated are processed. if ( !ctx ) // Verifying that context is a direct context printf( "Making context current\n" ); /* End of initialisation, now this code show the texture problem / unsigned int _buffer[256_256*4]; for(;;)
} glXMakeCurrent( display, 0, 0 ); XDestroyWindow( display, win ); return 0; |
I've archived the example here: |
I tried out the binary that you gave me and I can reproduce the problem on my Ci20 running the latest Debian 8 beta. I also installed Could you give me some more information about the system please? Are you running Debian 7, or the new Debian 8 beta? Did you install the mesa development libraries and link against them? |
I use Debian 8 beta, and yes I've installed libgl1-mesa-dev to compile it. |
Hammering the "bank enable" (PBKEN) bit on and off between every command crashes the Nomadik NHK15 with this message: Scanning device for bad blocks Unhandled fault: external abort on non-linefetch (0x008) at 0xcc95e000 pgd = (ptrval) [cc95e000] *pgd=0b808811, *pte=40000653, *ppte=40000552 Internal error: : 8 [#1] PREEMPT ARM Modules linked in: CPU: 0 PID: 1 Comm: swapper Not tainted 4.20.0-rc2+ MIPS#72 Hardware name: Nomadik STn8815 PC is at fsmc_exec_op+0x194/0x204 (...) After a discussion we (me and Boris Brezillon) start to suspect that this bit does not immediately control the chip select line at all, it rather enables access to the bank and the hardware will drive the CS autonomously. If there is a NAND chip connected, we should keep this enabled. As fsmc_nand_setup() sets this bit, we can simply remove the offending code. Fixes: 550b9fc ("mtd: rawnand: fsmc: Stop implementing ->select_chip()") Signed-off-by: Linus Walleij <[email protected]> Acked-by: Miquel Raynal <[email protected]> Signed-off-by: Boris Brezillon <[email protected]>
Hello.
I found some issue with OpenGL driver, then dynamicly updating texture using glTexImage2d() or glTexSubImage2d().
I've tested this with Debian 8 beta.
Here are my OpenGL calls:
glBindTexture(); //Bind a texture ID.
glTexImage2d(); //Upload first texture.
glDrawArrays(); //Bug here, the second texture is displayed here instead of first.
glTexImage2d(); //Upload second texture.
glDrawArrays(); //Second texture is correctly displayed here.
The text was updated successfully, but these errors were encountered: