LineGizmo.bslinc 452 B

1234567891011121314151617181920212223242526
  1. mixin LineGizmoBase
  2. {
  3. code
  4. {
  5. cbuffer Uniforms
  6. {
  7. float4x4 gMatViewProj;
  8. float4 gViewDir;
  9. }
  10. void vsmain(
  11. in float3 inPos : POSITION,
  12. in float4 color : COLOR0,
  13. out float4 oPosition : SV_Position,
  14. out float4 oColor : COLOR0)
  15. {
  16. oPosition = mul(gMatViewProj, float4(inPos.xyz, 1));
  17. oColor = color;
  18. }
  19. float4 fsmain(in float4 inPos : SV_Position, in float4 color : COLOR0) : SV_Target
  20. {
  21. return color;
  22. }
  23. };
  24. };