Tabnine Logo
MutableColor.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
us.ihmc.graphicsDescription.color.MutableColor
constructor

Best Java code snippets using us.ihmc.graphicsDescription.color.MutableColor.<init> (Showing top 14 results out of 315)

origin: us.ihmc/ihmc-model-file-loader

public static MutableColor stringToColor(String color)
{
 String[] vecString = color.split("\\s+");
 MutableColor color3f = new MutableColor(Float.parseFloat(vecString[0]), Float.parseFloat(vecString[1]), Float.parseFloat(vecString[2]));
 return color3f;
}
origin: us.ihmc/ihmc-graphics-description

  public static MutableColor parseColor3f(String color)
  {
   try
   {
     StringTokenizer s = new StringTokenizer(color, ",");

     return new MutableColor(new float[] {Float.parseFloat(s.nextToken()), Float.parseFloat(s.nextToken()), Float.parseFloat(s.nextToken())});
   }
   catch (Exception e)
   {
     return null;
   }
  }
}
origin: us.ihmc/ihmc-graphics-description

public YoAppearanceRGBColor(Color color, double transparency)
{
 this.color = new MutableColor(color);
 awtColor = new Color(color.getRed() / 255.0f, color.getGreen() / 255.0f, color.getBlue() / 255.0f, (float) (1.0 - transparency));
 setTransparency(transparency);
}
origin: us.ihmc/ihmc-graphics-description

public YoAppearanceRGBColor(double red, double green, double blue, double transparency)
{
 color = new MutableColor((float) red, (float) green, (float) blue);
 awtColor = new Color((float) red, (float) green, (float) blue, (float) (1.0 - transparency));
 setTransparency(transparency);
}
origin: us.ihmc/ihmc-graphics-description

public YoAppearanceRGBColor(float red, float green, float blue, double transparency)
{
 color = new MutableColor(red, green, blue);
 awtColor = new Color(red, green, blue, (float) (1.0 - transparency));
 setTransparency(transparency);
}
origin: us.ihmc/ihmc-graphics-description

public static AppearanceDefinition Color(Color color)
{
 return Color(new MutableColor(color));
}
origin: us.ihmc/ihmc-jmonkey-engine-toolkit

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);
}
origin: us.ihmc/ihmc-jmonkey-engine-toolkit

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);
}
origin: us.ihmc/simulation-construction-set-tools

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);
}
origin: us.ihmc/ihmc-graphics-description

public YoAppearanceRGBColor(MutableColor color, double transparency)
{
 this.color = new MutableColor(color);
 awtColor = new Color(this.color.getX(), this.color.getY(), this.color.getZ(), (float) (1.0 - transparency));
 setTransparency(transparency);
}
origin: us.ihmc/simulation-construction-set-tools

appearance.setDiffuseColor(new MutableColor(color));
appearance.setSpecularColor(new MutableColor(color));
appearance.setShininess(5.0f);
origin: us.ihmc/ihmc-robot-data-logger

private RemoteYoGraphic getRemoteGraphic(DynamicGraphicMessage msg)
{
 int registrationID = msg.getType();
 String name = msg.getName();
 YoVariable<?>[] vars = new YoVariable[msg.getYoIndexCount()];
 for (int v = 0; v < vars.length; v++)
   vars[v] = variables.get(msg.getYoIndex(v));
 double[] consts = ArrayUtils.toPrimitive(msg.getConstantList().toArray(new Double[msg.getConstantCount()]));
 AppearanceDefinition appearance = new YoAppearanceRGBColor(Color.red, 0.0);
 if (msg.hasAppearance())
 {
   appearance = new YoAppearanceRGBColor(new MutableColor((float) msg.getAppearance().getX(), (float) msg.getAppearance().getY(),
                              (float) msg.getAppearance().getZ()),
                      msg.getAppearance().getTransparency());
 }
 return yoGraphicFromMessage(registrationID, name, vars, consts, appearance);
}
origin: us.ihmc/ihmc-robot-data-logger

  private RemoteYoGraphic getRemoteGraphic(GraphicObjectMessage graphicObjectMessage)
  {
   int registrationID = graphicObjectMessage.getRegistrationID();

   String name = graphicObjectMessage.getNameAsString();
   YoVariable<?>[] vars = new YoVariable[graphicObjectMessage.getYoVariableIndex().size()];
   for (int v = 0; v < vars.length; v++)
     vars[v] = variables.get(graphicObjectMessage.getYoVariableIndex().get(v));

   double[] consts = graphicObjectMessage.getConstants().toArray();

   AppearanceDefinition appearance = new YoAppearanceRGBColor(new MutableColor((float) graphicObjectMessage.getAppearance().getR(),
                                         (float) graphicObjectMessage.getAppearance().getG(),
                                         (float) graphicObjectMessage.getAppearance().getB()),
                                 graphicObjectMessage.getAppearance().getTransparency());

   return yoGraphicFromMessage(registrationID, name, vars, consts, appearance);
  }
}
origin: us.ihmc/valkyrie

mat.setAmbientColor(new MutableColor(0.5f,0.5f,0.5f));
mat.setDiffuseColor(new MutableColor(0.5f,0.5f,0.5f));
mat.setSpecularColor(new MutableColor(0.5f,0.5f,0.5f));
us.ihmc.graphicsDescription.colorMutableColor<init>

Popular methods of MutableColor

  • getX
  • getY
  • getZ
  • get
  • set
  • setX
  • setY
  • setZ

Popular in Java

  • Updating database using SQL prepared statement
  • requestLocationUpdates (LocationManager)
  • putExtra (Intent)
  • setContentView (Activity)
  • VirtualMachine (com.sun.tools.attach)
    A Java virtual machine. A VirtualMachine represents a Java virtual machine to which this Java vir
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • ServerSocket (java.net)
    This class represents a server-side socket that waits for incoming client connections. A ServerSocke
  • NoSuchElementException (java.util)
    Thrown when trying to retrieve an element past the end of an Enumeration or Iterator.
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.> This module, both source code and documentation, is in t
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now