protected virtual void drawDebug(int touchPoints) { if (!DebugMode) { return; } var color = State == GestureState.Possible ? Color.red : Color.green; switch (touchPoints) { case 1: GLDebug.DrawSquareScreenSpace(debugID, getPointScreenPosition(0), 0f, debugPointerSize, color, float.PositiveInfinity); GLDebug.RemoveFigure(debugID + 1); GLDebug.RemoveFigure(debugID + 2); break; default: var newScreenPos1 = getPointScreenPosition(0); var newScreenPos2 = getPointScreenPosition(1); GLDebug.DrawSquareScreenSpace(debugID, newScreenPos1, 0f, debugPointerSize, color, float.PositiveInfinity); GLDebug.DrawSquareScreenSpace(debugID + 1, newScreenPos2, 0f, debugPointerSize, color, float.PositiveInfinity); GLDebug.DrawLineWithCrossScreenSpace(debugID + 2, newScreenPos1, newScreenPos2, .5f, debugPointerSize * .3f, color, float.PositiveInfinity); break; } }
public void Hide() { if (!Application.isPlaying) { return; } GLDebug.RemoveFigure(currentDebugId); currentDebugId = -1; }
protected virtual void clearDebug() { GLDebug.RemoveFigure(debugID); GLDebug.RemoveFigure(debugID + 1); GLDebug.RemoveFigure(debugID + 2); if (debugCoroutine != null) { StopCoroutine(debugCoroutine); } debugCoroutine = null; }
private void removeDebugFigureForPointer(Pointer pointer) { GLDebug.RemoveFigure(TouchManager.DEBUG_GL_TOUCH + pointer.Id); }
protected override void clearDebug() { base.clearDebug(); GLDebug.RemoveFigure(debugID + 3); }
private void removeDebugFigureForTouch(TouchPoint touch) { GLDebug.RemoveFigure(TouchManager.DEBUG_GL_TOUCH + touch.Id); }