public YoArtifact(String name, double[] constants, Color color, YoVariable<?>... variableArray) { super(name); this.variableArray = variableArray; this.constants = constants; this.appearance = new YoAppearanceRGBColor(color, 0.0); this.color = color; }
public YoArtifact(String name, double[] constants, Color color, YoVariable<?>... variableArray) { super(name); this.variableArray = variableArray; this.constants = constants; this.appearance = new YoAppearanceRGBColor(color, 0.0); this.color = color; }
public static AppearanceDefinition RGBColor(float red, float green, float blue) { return new YoAppearanceRGBColor(red, green, blue, 0.0); }
public static AppearanceDefinition RGBColor(double red, double green, double blue) { return new YoAppearanceRGBColor(red, green, blue, 0.0); }
public static AppearanceDefinition RGBColor(float red, float green, float blue) { return new YoAppearanceRGBColor(red, green, blue, 0.0); }
public static AppearanceDefinition RGBColor(double red, double green, double blue, double transparency) { return new YoAppearanceRGBColor(red, green, blue, transparency); }
public static AppearanceDefinition RGBColor(double red, double green, double blue, double transparency) { return new YoAppearanceRGBColor(red, green, blue, transparency); }
private void setupTrackBallsVisualization() { comTrack = new BagOfBalls(numberOfTrackBalls, trackBallSize, "CoMTrack", new YoAppearanceRGBColor(comPointsColor, 0.0), registry, graphicsListRegistry); icpTrack = new BagOfBalls(numberOfTrackBalls, trackBallSize, "ICPTrack", new YoAppearanceRGBColor(icpPointsColor, 0.0), registry, graphicsListRegistry); cmpTrack = new BagOfBalls(numberOfTrackBalls, trackBallSize, "CMPTrack", new YoAppearanceRGBColor(cmpPointsColor, 0.0), registry, graphicsListRegistry); copTrack = new BagOfBalls(numberOfTrackBalls, trackBallSize, "CoPTrack", new YoAppearanceRGBColor(copPointsColor, 0.0), registry, graphicsListRegistry); }
@Override public void unSelect(boolean reset) { cylinderGraphic.setAppearance(new YoAppearanceRGBColor(defaultColor, unselectTransparency)); }
@Override public void unSelect(boolean reset) { boxGraphics.setAppearance(new YoAppearanceRGBColor(defaultColor, unselectTransparency)); }
@Override public void unSelect(boolean reset) { wheelGraphic.setAppearance(new YoAppearanceRGBColor(defaultColor, unselectTransparency)); }
public void run() { transparency += 0.01; if (transparency > 1.0) transparency = 0.0; MutableColor color = new MutableColor((float) Math.random(), (float) Math.random(), (float) Math.random()); YoAppearanceRGBColor appearance = new YoAppearanceRGBColor(color, 0.0); appearance.setTransparency(transparency); instruction.setAppearance(appearance); }
public void run() { transparency += 0.01; if (transparency > 1.0) transparency = 0.0; MutableColor color = new MutableColor((float) Math.random(), (float) Math.random(), (float) Math.random()); YoAppearanceRGBColor appearance = new YoAppearanceRGBColor(color, 0.0); appearance.setTransparency(transparency); instruction.setAppearance(appearance); }
public void run() { transparency += 0.01; if (transparency > 1.0) transparency = 0.0; Color3f color = new Color3f((float) Math.random(), (float) Math.random(), (float) Math.random()); YoAppearanceRGBColor appearance = new YoAppearanceRGBColor(color, 0.0); appearance.setTransparency(transparency); instruction.setAppearance(appearance); }
public void run() { transparency += 0.01; if (transparency > 1.0) transparency = 0.0; Color3f color = new Color3f((float) Math.random(), (float) Math.random(), (float) Math.random()); YoAppearanceRGBColor appearance = new YoAppearanceRGBColor(color, 0.0); appearance.setTransparency(transparency); instruction.setAppearance(appearance); }
private AppearanceDefinition getAppearanceForCost(double cost) { double greenCost = 0.0; double redCost = 1.5; cost -= greenCost; cost = -cost; double index = cost * 1000.0 / (greenCost - redCost); index = MathTools.clamp(index, 0, 999); colorIndexYoVariable.set(index); Color costColor = costColorGradient[(int) (index)]; return new YoAppearanceRGBColor(costColor, 0.0); } }
@Override public void select() { unSelect(false); boxGraphics.setAppearance(new YoAppearanceRGBColor(selectedColor, selectTransparency)); notifySelectedListenersThisWasSelected(this); }
@Override public void select() { unSelect(false); wheelGraphic.setAppearance(new YoAppearanceRGBColor(selectedColor, selectTransparency)); notifySelectedListenersThisWasSelected(this); }
@Override public void select() { unSelect(false); cylinderGraphic.setAppearance(new YoAppearanceRGBColor(selectedColor, selectTransparency)); notifySelectedListenersThisWasSelected(this); }
public static void addCube(double cubeX, double cubeY, double cubeSize, Color color, SimulationConstructionSet scs) { final double CUBE_HEIGHT = 0.001; // Make cubes a tiny bit smaller so they don't blend together. cubeSize *= 0.9; Graphics3DObject linkGraphics = new Graphics3DObject(); linkGraphics.translate(new Vector3D(cubeX, cubeY ,CUBE_HEIGHT)); linkGraphics.addCube(cubeSize, cubeSize, cubeSize, new YoAppearanceRGBColor(new MutableColor(color), 0.0)); scs.addStaticLinkGraphics(linkGraphics); }