Jump to content

  • Log In with Google      Sign In   
  • Create Account


crynas

Member Since 10 Jul 2010
Offline Last Active Jan 20 2012 02:54 AM
-----

Posts I've Made

In Topic: Direct3D 10 InputLayout

18 August 2011 - 02:47 PM

You can do this, but then how will you validate your shaders against the used input layout? Unless you have another way to ensure that they match, then why not just create one at shader compilation time? Unless you create lots and lots of shader objects this shouldn't really pose a problem.


So you are proposing, that I should mimic Direct3D 10 API? Have a method like
CreateVertexLayout(VertexLayoutDescription, CompiledShader)
? I was thinking about checking compatibility of VL and Shader in debug build using shader introspection or something like that.

Thx

In Topic: Direct3D 10 InputLayout

18 August 2011 - 02:12 AM

Hi,

firstly I would like to thank you for your time and responses. Ok, back to topic.

I wanted my render API to allow me usage like this:

1. Create some kind of a vertex layout object (like in Direct3D 10). No compiled shader would by necessary at creation time.
2. Use created layout object with any compatible shader. In debug build I would check shader input against active layout (at shader bind time) by my self.

Is this design/usage a bad idea? This idead seems viable to me. Problem is, that I dont know too much about what is happing under the hood. So may be it is not that viable at all.

Thx

PARTNERS