Hi! I need to write one tricky shader.
I hope, it is enough to set vertex alpha to zero to hide it from render, but I do not know how to get access to certain vertexes.
For instance, I have plane parallel to X axis. Using C-Lite, I can get exact part of model which needs to be cut:
if (divide_plane.x > object.x)
{
if ((divide_plane.x - object.x) > object.max_x)
/// Does not matter, cutter plane is outside objects
else
trace_for_divider = (you.x - me.x);//Now this matters, we get X amount of object which needs to be cut
}
else
{
same vise versa
}
So, trace_for_divider will hold number, and if this number is, lets say, 2, then all vertexes, lying further away then 2 on X axis (relevant to local object coordinates, its origin), needs to be hide.
What I do not know, is hot to transfer this
affect_only_vertexes_which_position_is_more_then_2_on_X_axis_local_object_coordinates to HLSL ?