Pixmap color
BlitzMax Forums/BlitzMax Beginners Area/Pixmap color
| ||
Is there any possibilty to set/reset the color of the pixmap. I have tried to draw a white colored rectangle after the pixmap. i.e. infront of the pixmap. But its not working properly. |
| ||
ClearPixels( pixmap:TPixmap,argb=0 ) or pixmap.ClearPixels( argb ) |
| ||
These commands are not working. It says "Clearpixel" not found. I think i have to include Brucey's module. Any other idea.....? Thank you. |
| ||
ClearPixels() works fine - I just checked it. |
| ||
Ah... you need to do a "Syncmods". It is available in the latest code. You can syncmods from the IDE. |
| ||
It says "Clearpixel" not found If it *really* says 'clearpixel not found' then you have missed off the 's' from clearpixelS. <EDIT> This might help : Graphics 800 , 600 Local mypix:tpixmap = LoadPixmap("max.png") DrawPixmap mypix , 0 , 0 tg_clearpixels(mypix,255,255,255) DrawPixmap mypix , 300 , 0 Flip WaitKey() Function tg_clearpixels(mypix:tpixmap , red:Int , green:Int , blue:Int) Local argb:Int=intcolor(red,green,blue) mypix.clearpixels(argb) End Function Function IntColor(R,G,B,A=0) Return A Shl 24 | R Shl 16 | G Shl 8 | B Shl 0 End Function |