Sign in to follow this  
Asheh

Enumerating the Video Modes

Recommended Posts

I was looking into fully enumerating the video modes today, since i want my engine to support as many computers as possible I want to develop a flexable class that can switch modes and so on. Anyways after a bit of reading I noticed somthing a bit odd (to me anyways) UINT GetAdapterModeCount( UINT Adapter, D3DFORMAT Format ); This takes a format, which in the docs it says you need to use the following to find out what: EnumAdapterModes( UINT Adapter, D3DFORMAT Format, UINT Mode, D3DDISPLAYMODE* pMode ); This also takes a format, but i mean, how can i find out if the format is supported when both require a format? Can anyone give me the best way to enumerate an adapter, and all its available display modes/formats. Also maybe the other possibilities? Things like anti-aliasing? How do i detect those? D3DCAPS? Thanks.

Share this post


Link to post
Share on other sites
check this


With GetAdapterModeCount it's asking for the adapter format that you want to use. Right now there are 16 bit and 32 bit formats, I think the logic behind this goes something like: If you make your app now and just enumerated all the adapter modes, in a few years an adapter mode might be something like D3DFMT_A128R128B128G128 and all your pixel processing methods are either 32 bit or 16 bit because there were no 128 bit adapter formats at teh time, so your app then (a few years from now) chooses that 128 bit mode as the best mode to run on, but dosnt run properly because it's a 128 bit mode.

Im not quite sure of the above. But I *think* I remember hearing/reading something like that.

So for your adapter modes, you restrict them to the 4 possible ones currently supported by dx9 (they're listed in teh docs in the D3DFORMAT section)

and you enumerate backbuffer modes according to those modes. So when there's a 128 bit mode, your app will still only enumerate teh 32 bit modes.

or something.... Check that link above though.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this