Change Image filtering/mipmap after creation?
BlitzMax Forums/BlitzMax Programming/Change Image filtering/mipmap after creation?
| ||
Does anyone have any code for altering an images FILTEREDIMAGE and MIPMAPPEDIMAGE "properties" after the image has been created? The scenario I have is that I have an image shared across multiple canveses. In some circumstance I want to draw the image without filtering/mipmap but in some circumstances I want to draw with! I could keep two copies of the image but ID rather not! So does anyone know if this is possible? I am using GL and DX (dependant on users system) but either would do... Last edited 2012 |
| ||
Pretty sure this has to be done at the point of creation, though I could be wrong, but I imagine the changed image has to be re-uploaded to the graphics card. Best I could think of, and it's quite nasty, was this... Graphics 640, 480 ' Filtered... Local image:TImage = LoadImage ("boing.png", MASKEDIMAGE | FILTEREDIMAGE) Repeat Cls SetScale 4, 4 DrawImage image, MouseX (), MouseY () If MouseHit (1) ' Unfiltered... image = LoadImage (LockImage (image), MASKEDIMAGE) UnlockImage image EndIf Flip Until KeyHit (KEY_ESCAPE) End |
| ||
Hey, yeah I thought it might be as much. I guess I now need to ponder what I will do! Thanks for the pointer! |