Sunday, 15 June 2014

c++ - Rendering an Object more than once -



c++ - Rendering an Object more than once -

right i'm facing issue of rendering same objects more 1 time in directx 11, object has:

a diffuse shader a directional lighting shader a texture shader

now final color should of them somehow set together, maybe this:

render diffuse render texture render directional

final color = (diffuse + texture) * lighting // not sure though

but how can archieved? without effects framework!

it can achieved in directx11 couple of ways. first making "uber shader". means diffuse, texture , lighting in same shader. sec utilize dynamic shader linking , dynamically link unique diffuse/texture/lighting shaders @ runtime. june 2010 sdk has illustration of dynamic shader linking. usual combination of colors is:

final color = diffuse * texture * lighting

c++ object rendering shader directx-11

No comments:

Post a Comment