Jump to content
  • Advertisement
Sign in to follow this  
david_watt78

directx 10 fx file question

This topic is 3378 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

anyone know how to declare rendertargets and set them in an fx file? I know there is an interface to get and set them as well as depth/stencil views. But, I have found nothing in the sdk docs, samples , or online on how that works in the fx file or for that matter any good in depth info on the fx file format.

Share this post


Link to post
Share on other sites
Advertisement
What do you want exactly?
You can use something like this, to output to multiple render targets at the same time:

struct PS_Output
{
float a : SV_Target0;
float2 b : SV_Target1;
float3 c : SV_Target2;
float4 d : SV_Target3;
};


The render targets are declared and set in the application, as you say.

Share this post


Link to post
Share on other sites
There is an interface ID3D10EffectRenderTargetView in the D3D10 Effect classes. Its a variable type so I would need to know what name to use in getting the variable from the effect class. I assume there must be a way to name the rendertargets, unless the name is the semantic. I have been trying to find any info on this and have been unsuccessful.I have a solution that works now but using that variable would be simpler from my code perspective as the render target would become another variable to set once in the effect class and not need to change in the future.

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!