Jump to content
  • Advertisement
Sign in to follow this  
Wizecoder

Couple questions about dx9 and 10

This topic is 3449 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have a few questions(more may come later): 1st. What is one of the recommended ways to have your application check for dx10 support on the OS(as in engine needing to support dx9 and 10). 2nd. What are some of the ways to efficiently store and manage dx9 and 10 effects(as in game engine effect manager). Thanks in advance.

Share this post


Link to post
Share on other sites
Advertisement
the DX10 support check i do like this:


// create Factory
IDXGIFactory* dxgiFactory;
hr = CreateDXGIFactory(__uuidof(IDXGIFactory), (void**)(&dxgiFactory));
if (FAILED(hr)) return hr;

// enum Adapters
IDXGIAdapter* dxgiAdapter;
UINT ai = 0;
while (dxgiFactory->EnumAdapters(ai, &dxgiAdapter) != DXGI_ERROR_NOT_FOUND) {
ai++;
bool canDX10 = SUCCEEDED(dxgiAdapter->CheckInterfaceSupport(__uuidof(ID3D10Device), NULL));
if (!canDX10) {
dxgiAdapter->Release();
continue;
}

Share this post


Link to post
Share on other sites
Quote:
Original post by Wizecoder
Anyone else able to help with the second question?
This tends to be more an exercise in general software design really. There aren't really any requirements imposed by the underlying technology except for efficiency.

For other people on these forums asking similar design questions it often boils down to the decision of ownership. Does the renderer own the objects to be rendered, or do the objects render themselves?

The main factors tend to be complexity (every object rendering itself can get quite messy) versus expressibility (a centralised renderer may need a complex interface to handle all rendering scenarios)...

Once you've resolve that part it often becomes clearer where you want to locate shared resources and the various connections between them (e.g. the above decision can completely flip a 1:many/many:1 connection) should become a lot clearer.


hth
Jack

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!