Commit d0cb86e7 authored by Frédéric Larue's avatar Frédéric Larue
Browse files

Minor modifications in the texel/vertex real-time selection mode.

parent 57e29494
......@@ -89,12 +89,11 @@ const char* SelectionManagerMeshTexels::s_RealTimeSelectionShaderFSH =
"void main()"
"{"
" float sgn = sign( u_SelectionStateUpdateValue - 0.5 );"
" vec3 clipCoord = getClippingCoordinates( vertex );"
" if( isInsideViewport(clipCoord) && isInsideSelectionArea(clipCoord) && passOcclusionTest(vertex) )"
" selectionState = vec4( toBrushCenter(), sgn*squareDistanceToBrush(), 1.0 );"
" selectionState = vec4( toBrushCenter(), squareDistanceToBrush(), 1.0 );"
" else"
" selectionState = vec4( 0.0, 0.0, sgn, 1.0 );"
" selectionState = vec4( -1.0, -1.0, -1.0, 1.0 );"
"}";
void SelectionManagerMeshTexels::initTexture()
......
......@@ -117,11 +117,10 @@ const char* SelectionManagerMeshVertices::s_RealTimeSelectionShaderFSH =
"void main()"
"{"
" float sgn = sign( u_SelectionStateUpdateValue - 0.5 );"
" if( selectionTestFunction(vertex,normal) )"
" selectionState = vec4( toBrushCenter(), sgn*squareDistanceToBrush(), 1.0 );"
" else"
" selectionState = vec4( 0.0, 0.0, sgn, 1.0 );"
" selectionState = vec4( toBrushCenter(), squareDistanceToBrush(), 1.0 );"
" else"
" selectionState = vec4( -1.0, -1.0, -1.0, 1.0 );"
"}";
const char* SelectionManagerMeshVertices::s_SelectionShader_WithOcclusionTestFSH =
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment