Getvideoinfo problem

Hi guys,

i have problems using getvideoinfo.
If i try to obtain the total amount of video memory the
result is always “0” and i don’t understand what’s wrong in the code.

Can anyone help me?

SDL_VideoInfo *vi;
Uint32 g;
vi=SDL_GetVideoInfo();
g=vi->video_mem;
printf(“Total memory %ui”,g);

I run Mandrake 8.0 with ATI radeon 64 Mb.

@The_Spider

sragno at libero.it wrote:

If i try to obtain the total amount of video memory the
result is always “0” and i don’t understand what’s wrong in the code.

http://www.libsdl.org/faq/FAQ-General.html#GENERAL_HWACCEL

please read the FAQ before posting