Sign in to follow this  

Anyone know how you can pass more than one texture to a CustomEffect in SharpDX >= 3.0.2?

This topic is 411 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 made a couple of HLSL pixel shaders and everything worked out fine.

I am however unable to find a way of passing two different textures to the HLSL.

 

I did try to:

customEffect.SetInput(0, t1, true);

customEffect.SetInput(1, t2, true);

But it doesn't seem to do the trick.

 

If you have any idea, I would really appreciate a hand here.

Thank you

 

Solved:

Reading again the sources I found the original DirectX class for this and also an example with everything that is needed.

For anyone having this problem: ID2D1EffectImpl (https://msdn.microsoft.com/en-us/library/windows/desktop/hh404568(v=vs.85).aspx)

https://msdn.microsoft.com/en-us/library/windows/desktop/jj710194(v=vs.85).aspx

And the example that saved the day:

https://code.msdn.microsoft.com/Anti-Aliasing-Recovery-19a06124/sourcecode?fileId=81254&pathId=1389018927

Edited by happycoding

Share this post


Link to post
Share on other sites

This topic is 411 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.

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