Difference between revisions of "3D Fundamentals Tutorial 12"
From Chilipedia
(→Video) |
(→Video) |
||
(2 intermediate revisions by the same user not shown) | |||
Line 22: | Line 22: | ||
:* Scene definition [https://youtu.be/xcs2IEGVkCk?t=5m02s 5:02] | :* Scene definition [https://youtu.be/xcs2IEGVkCk?t=5m02s 5:02] | ||
* Demo: creating a wave effect [https://youtu.be/xcs2IEGVkCk?t=5m24s 5:24] | * Demo: creating a wave effect [https://youtu.be/xcs2IEGVkCk?t=5m24s 5:24] | ||
− | :* <code>Plane.h</code> defines | + | :* <code>Plane.h</code> defines Tessellation of a plane object [https://youtu.be/xcs2IEGVkCk?t=6m28s 6:28] |
:* <code>WaveVertexTextureEffect.h</code> implements the sinusoid wave effect [https://youtu.be/xcs2IEGVkCk?t=7m21s 7:21] | :* <code>WaveVertexTextureEffect.h</code> implements the sinusoid wave effect [https://youtu.be/xcs2IEGVkCk?t=7m21s 7:21] | ||
:* <code>VertexWaveScene.h</code> [https://youtu.be/xcs2IEGVkCk?t=9m48s 9:48] | :* <code>VertexWaveScene.h</code> [https://youtu.be/xcs2IEGVkCk?t=9m48s 9:48] | ||
− | * Example where | + | * Example where the vertex output type is different from the vertex input type [https://youtu.be/xcs2IEGVkCk?t=10m48s 10:48] |
+ | <div class="mw-collapsible-content"> | ||
:* Example effect: the color of the vertex is determined by its position | :* Example effect: the color of the vertex is determined by its position | ||
:* The input vertex type only holds position as data member, we add color in the output data type <code>VSOut</code> | :* The input vertex type only holds position as data member, we add color in the output data type <code>VSOut</code> | ||
:* You can procedurally add information to your vertices in the vs | :* You can procedurally add information to your vertices in the vs | ||
− | + | </div> | |
</div> | </div> | ||
Latest revision as of 21:08, 28 June 2020
The vertex shader is the one of the two original shaders introduced in Direct3D 8, and it is the only shader besides the pixel shader that must be provided before triangles can be rendered. It's kind of a big deal.
Video
The tutorial video is on YouTube here.
[Expand]
- What is a Vertex Shader (vs) and its position in the pipeline 0:20
- Code implementation walk-through 1:14
-
Pipeline.h
1:14
-
- Demo: creating a wave effect 5:24
- Example where the vertex output type is different from the vertex input type 10:48
Downloads
The GitHub repository for the tutorial code is here.