We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 236 - SDL 1.2.10 loading graphics into virtual memory?
Summary: SDL 1.2.10 loading graphics into virtual memory?
Status: RESOLVED INVALID
Alias: None
Product: SDL
Classification: Unclassified
Component: video (show other bugs)
Version: 2.0.0
Hardware: x86 Windows (XP)
: P2 major
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-05-19 13:54 UTC by Steve Allen
Modified: 2006-05-21 16:24 UTC (History)
0 users

See Also:


Attachments
The test file is also included here. I didn't see this before. (422.96 KB, application/zip)
2006-05-19 13:55 UTC, Steve Allen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Steve Allen 2006-05-19 13:54:01 UTC
SDL 1.2.10 appears to be loading all my graphics into virtual memory instead of real memory.  This did not happen with 1.2.9.  I have provided a link below to a test file that illustrates the issue.  I have tried this with a couple different small apps and wrote this one specifically to illustrate the problem.

I have included the SDL dlls that I downloaded directly from the SDL website.  The linked file has all the grimy details.  Please let me know if you require any additional information.  Thanks!

http://www.wretchedsoft.com/bugtest.zip
Comment 1 Steve Allen 2006-05-19 13:55:58 UTC
Created attachment 131 [details]
The test file is also included here.  I didn't see this before.

Thanks again!
Comment 2 Ryan C. Gordon 2006-05-20 00:56:38 UTC
Probably due to the switch to windib as the default video target on Windows.

Try forcing it to use DirectX and see if it goes back to old behaviour.

--ryan.
Comment 3 Steve Allen 2006-05-20 14:03:14 UTC
(In reply to comment #2)
> Probably due to the switch to windib as the default video target on Windows.
> 
> Try forcing it to use DirectX and see if it goes back to old behaviour.
> 
> --ryan.
> 

Hello again,

what would be the best method of going about this?  I don't see a use_this_driver()-esque api call.  Should I recompile the dll with the defaults switched?  Thanks! 
Comment 4 Ryan C. Gordon 2006-05-20 16:34:34 UTC
You can set an environment variable: SDL_VIDEODRIVER=directx

Be careful that SDL actually picks that up, since Windows is a little fruity about environment variables. Check SDL_VideoDriverName() to see what you got (if it tells you "windib", then you got the default one).

Alternately, you could rebuild SDL, but this should work.

--ryan.

Comment 5 Steve Allen 2006-05-21 15:21:32 UTC
Looks like you are correct sir.  

I set the environ var to directx and all is 
behaving splendidly again.  The memory usage is correct and doesn't appear to be paging anymore.  I removed the environment var and rebooted again and get windib back with its paging fetish.

Let me know if you want me to try anything else.

Thanks!
Comment 6 Ryan C. Gordon 2006-05-21 16:24:29 UTC
Ok, that's expected, then.

What I would recommend is that you forcibly set that environment variable in your program before the SDL_Init() call...we changed the default to windib because we had a lot of problems with buggy drivers crashing machines, but if it hasn't been a problem for you, you might as well use it.

We're adding a better means to select a video backend to SDL 1.3, and hopefully moving the Windows code to something that's more powerful than DirectX 5, too.

--ryan.