Max2D and GL Drawing
BlitzMax Forums/BlitzMax Beginners Area/Max2D and GL Drawing
| ||
i was trying to mix some Max2d Drawing with 2d OpenGl Commands but i Have strange effects Here is the code Strict Framework BRL.GlMax2D Import BRL.System Import BRL.Basic Import BRL.pngloader Import BRL.Retro SetGraphicsDriver GLMax2DDriver() Graphics 640 , 480 , 0 Global image:TImage = LoadImage("tile.png") While Not KeyDown(Key_Escape) Cls glBegin GL_TRIANGLES 'Drawing Using Triangles glColor4f 1.0,0.0 , 0.0 , 1.0 glVertex2f 0.0, 0 glColor4f 0.0,1.0 , 0.0 , 1.0 glVertex2f GraphicsWidth() , 0.0 glColor4f 0.0,0.0 , 1.0 , 1.0 glVertex2f 0.0 , GraphicsHeight() glEnd SetColor 255 , 255 , 255 DrawImage( image , 100 , 100) Flip FlushMem Wend i cannot provide the image. use any png you have my problem is that i am lossing the green value of the second corner of the triangle. if i remove the drawImage command or use the shape drawing methods of max2d everything it's allright |