2 * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3 * Copyright (C) 2016 - Caio SOUZA
5 * Copyright (C) 2012 - 2016 - Scilab Enterprises
7 * This file is hereby licensed under the terms of the GNU GPL v2.0,
8 * pursuant to article 5.3.4 of the CeCILL v.2.1.
9 * This file was originally licensed under the terms of the CeCILL v2.1,
10 * and continues to be available under such terms.
11 * For more information, see the COPYING file which you should have received
12 * along with this program.
14 package org.scilab.modules.renderer.JoGLView.util;
16 import static org.scilab.modules.graphic_objects.figure.Figure.PixelDrawingMode;
17 import org.scilab.forge.scirenderer.implementation.jogl.JoGLPixelDrawingMode;
19 public class PixelDrawingModeUtils {
21 public static JoGLPixelDrawingMode figureToJoGLmode(PixelDrawingMode mode) {
24 return JoGLPixelDrawingMode.CLEAR;
26 return JoGLPixelDrawingMode.AND;
28 return JoGLPixelDrawingMode.AND_REVERSE;
30 return JoGLPixelDrawingMode.COPY;
32 return JoGLPixelDrawingMode.AND_INVERTED;
34 return JoGLPixelDrawingMode.NOOP;
36 return JoGLPixelDrawingMode.XOR;
38 return JoGLPixelDrawingMode.OR;
40 return JoGLPixelDrawingMode.NOR;
42 return JoGLPixelDrawingMode.EQUIV;
44 return JoGLPixelDrawingMode.INVERT;
46 return JoGLPixelDrawingMode.OR_REVERSE;
48 return JoGLPixelDrawingMode.COPY_INVERTED;
50 return JoGLPixelDrawingMode.OR_INVERTED;
52 return JoGLPixelDrawingMode.NAND;
54 return JoGLPixelDrawingMode.SET;