]> gerrit.simantics Code Review - simantics/3d.git/blobdiff - org.simantics.g3d/src/org/simantics/proconf/g3d/animation/ChanneledColorInterpolator.java
Removing ancient 3d framework
[simantics/3d.git] / org.simantics.g3d / src / org / simantics / proconf / g3d / animation / ChanneledColorInterpolator.java
diff --git a/org.simantics.g3d/src/org/simantics/proconf/g3d/animation/ChanneledColorInterpolator.java b/org.simantics.g3d/src/org/simantics/proconf/g3d/animation/ChanneledColorInterpolator.java
deleted file mode 100644 (file)
index 7b28077..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-/*******************************************************************************\r
- * Copyright (c) 2007- VTT Technical Research Centre of Finland.\r
- * All rights reserved. This program and the accompanying materials\r
- * are made available under the terms of the Eclipse Public License v1.0\r
- * which accompanies this distribution, and is available at\r
- * http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- * Contributors:\r
- *     VTT Technical Research Centre of Finland - initial API and implementation\r
- *******************************************************************************/\r
-package org.simantics.proconf.g3d.animation;\r
-\r
-import com.jme.renderer.ColorRGBA;\r
-import com.jme.scene.state.MaterialState;\r
-\r
-public class ChanneledColorInterpolator implements Interpolator {\r
-    private ScalarInterpolator rInterpolator;\r
-    private ScalarInterpolator gInterpolator;\r
-    private ScalarInterpolator bInterpolator;\r
-    \r
-    //Material m = null;\r
-    MaterialState m = null;\r
-    int type = 1;\r
-    \r
-    public static final int AMBIENT = 0;\r
-    public static final int DIFFUSE = 1;\r
-    public static final int SPECULAR = 2;\r
-    public static final int EMISSIVE = 3;\r
-    \r
-    \r
-    public ChanneledColorInterpolator(ScalarInterpolator rInterpolator, ScalarInterpolator gInterpolator, ScalarInterpolator bInterpolator) {\r
-        this.rInterpolator = rInterpolator;\r
-        this.gInterpolator = gInterpolator;\r
-        this.bInterpolator = bInterpolator;\r
-    }\r
-    \r
-    public void interpolate(double delta) {\r
-        double r = rInterpolator.evaluate(delta);\r
-        double g = gInterpolator.evaluate(delta);\r
-        double b = bInterpolator.evaluate(delta);\r
-\r
-        ColorRGBA c = new ColorRGBA((float)r, (float)g, (float)b,0.f);\r
-        switch (type) {\r
-        case AMBIENT : \r
-            m.setAmbient(c);\r
-            break;\r
-        case DIFFUSE:\r
-            m.setDiffuse(c);\r
-            break;\r
-        case SPECULAR:\r
-            m.setSpecular(c);\r
-            break;\r
-        case EMISSIVE:\r
-            m.setEmissive(c);\r
-            break;\r
-        }\r
-    }\r
-    \r
-    public void setTarget(Object target) {\r
-       // m = (Material)target;\r
-        m = (MaterialState)target;\r
-    }\r
-    \r
-    public void setType(int type) {\r
-        this.type = type;\r
-    }\r
-\r
-}\r