mirror of https://github.com/odrling/Aegisub
Added support for drawing of \iclip on visual tools, but no button to invert it yet.
Originally committed to SVN as r2352.
This commit is contained in:
parent
2cb713baef
commit
d8c5da67d8
|
@ -123,7 +123,6 @@ void VisualToolVectorClip::Draw() {
|
|||
spline.GetPointList(points,pointCurve);
|
||||
|
||||
// Draw stencil mask
|
||||
// FIXME: This should understand inverse clips too
|
||||
glEnable(GL_STENCIL_TEST);
|
||||
glColorMask(0,0,0,0);
|
||||
glStencilFunc(GL_NEVER,1,1);
|
||||
|
@ -136,6 +135,11 @@ void VisualToolVectorClip::Draw() {
|
|||
glEnd();
|
||||
}
|
||||
|
||||
// Invert stencil
|
||||
if (inverse) {
|
||||
DrawRectangle(0,0,sw,sh);
|
||||
}
|
||||
|
||||
// Draw "outside clip" mask
|
||||
glColorMask(1,1,1,1);
|
||||
glStencilFunc(GL_EQUAL, 0, 1);
|
||||
|
|
Loading…
Reference in New Issue