using the 256 flag in LoadTexture command
Blitz3D Forums/Blitz3D Programming/using the 256 flag in LoadTexture command
| ||
hello to all... i'm new to blitz3d but i have programming background on C/C++ and JAva... just want to ask what does "store in Vram " mean in the Loadtexture command.. i mean , what's the difference if i use it or not... will it make the game run faster? or do some compression or something on the texture... hmmm |
| ||
It will store your texture in memory for as long as the program is running. Nice to meet you, btw! :) ~GF |
| ||
If possible, I would like to add you to yahoo messenger, NG! :) |
| ||
oh thanks Guy Fawkes! here's my email "ervin_cezar_09@..." i'm currently making a 3d rpg game in blitz3d ... i know programming and 3d modeling(well at least lowpoly ones).. but i suck at character design(2d).. and i realized that i need to do it that just "modeling blindly" |
| ||
@Guy Fawkes>>I had one smart comment to make but i kept it for myself. Take note of my incredible self control. (i don't know if this will last long...) |
| ||
Added, NG! :) Check your messenger! :) |
| ||
I'm not sure the above entirely correct. ANY Textures Loaded will all remain in memory until Free'd, regardless of flags - this makes them especially prone to memory leaks. I understand the flag to mean that the texture will be stored within the Graphics Adapater RAM (VRAM) as opposed to the standard computer RAM (Heap). Graphics3D 800,600,32,0 Local Iter Global Sample[100] ;TEST A Local TestA1=AvailVidMem() For Iter=0 To 99 Sample[Iter]=CreateTexture(1,1,1) Next Local TestA2=AvailVidMem() For Iter=0 To 99 FreeTexture Sample[Iter] Next Local TestAResult=TestA1-TestA2 ;TEST B Local TestB1=AvailVidMem() For Iter=0 To 99 Sample[Iter]=CreateTexture(1,1,257) Next Local TestB2=AvailVidMem() For Iter=0 To 99 FreeTexture Sample[Iter] Next Local TestBResult=TestB1-TestB2 Print "Test A Used: "+Str(TestAResult)+" VRAM" Print "Test B Used: "+Str(TestBResult)+" VRAM" |