Codota Logo
JavaFXMeshBuilder.addMesh
Code IndexAdd Codota to your IDE (free)

How to use
addMesh
method
in
us.ihmc.javaFXToolkit.shapes.JavaFXMeshBuilder

Best Java code snippets using us.ihmc.javaFXToolkit.shapes.JavaFXMeshBuilder.addMesh (Showing top 11 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Connection c =
  • Codota IconDataSource dataSource;dataSource.getConnection()
  • Codota IconString url;DriverManager.getConnection(url)
  • Codota IconIdentityDatabaseUtil.getDBConnection()
  • Smart code suggestions by Codota
}
origin: us.ihmc/ihmc-javafx-toolkit

/**
* Combines the given mesh with the mesh contained in this builder while specifying the color of the given mesh.
* @param meshDataHolder the mesh to combine. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color));
}
origin: us.ihmc/ihmc-javafx-toolkit

/**
* Rotates, translates, then combines the given mesh with the mesh contained in this builder.
* @param meshDataHolder the mesh to translate and combine. Not Modified.
* @param offset the translation to apply to the given mesh. Not modified.
* @param orientation the axis-angle describing the rotation to apply to the given mesh. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Tuple3DReadOnly offset, AxisAngle orientation, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color), offset, orientation);
}
origin: us.ihmc/IHMCJavaFXToolkit

/**
* Translates then combines the given mesh with the mesh contained in this builder.
* @param meshDataHolder the mesh to translate and combine. Not Modified.
* @param offset the translation to apply to the given mesh. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Tuple3d offset, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color), offset);
}
origin: us.ihmc/IHMCJavaFXToolkit

/**
* Combines the given mesh with the mesh contained in this builder while specifying the color of the given mesh.
* @param meshDataHolder the mesh to combine. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color));
}
origin: us.ihmc/ihmc-javafx-toolkit

/**
* Translates then combines the given mesh with the mesh contained in this builder.
* @param meshDataHolder the mesh to translate and combine. Not Modified.
* @param offset the translation to apply to the given mesh. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Tuple3DReadOnly offset, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color), offset);
}
origin: us.ihmc/IHMCJavaFXToolkit

/**
* Rotates, translates, then combines the given mesh with the mesh contained in this builder.
* @param meshDataHolder the mesh to translate and combine. Not Modified.
* @param offset the translation to apply to the given mesh. Not modified.
* @param orientation the axis-angle describing the rotation to apply to the given mesh. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Tuple3d offset, AxisAngle4d orientation, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color), offset, orientation);
}
origin: us.ihmc/IHMCJavaFXToolkit

/**
* Translates then combines the given mesh with the mesh contained in this builder.
* @param meshDataHolder the mesh to translate and combine. Not Modified.
* @param offset the translation to apply to the given mesh. Not modified.
* @param color color of the given mesh. Color accuracy depends on the color palette in use.
*/
public void addMesh(MeshDataHolder meshDataHolder, Tuple3f offset, Color color)
{
 meshBuilder.addMesh(setColor(meshDataHolder, color), offset);
}
origin: us.ihmc/IHMCJavaFXToolkit

  private void addCones(JavaFXMeshBuilder meshBuilder)
  {
   Point3d conePosition = new Point3d(0.4, 0.0, 0.0);
   double height = 0.3;
   double radius = 0.1;
   meshBuilder.addCone(height, radius, conePosition);
//      meshBuilder.addMesh(MeshDataGenerator.ArcTorus(0.0, 2.0 * Math.PI, 0.3, 0.01, 128));
   meshBuilder.addMesh(MeshDataGenerator.Cone(height, radius, 64));
  }

origin: us.ihmc/IHMCJavaFXToolkit

  private void addCylinders(JavaFXMeshBuilder meshBuilder)
  {
   Point3d cylinderPosition = new Point3d(1.0, 0.0, 0.0);
   double height = 0.3;
   double radius = 0.1;
   meshBuilder.addCylinder(height, radius, cylinderPosition);
//      meshBuilder.addMesh(MeshDataGenerator.ArcTorus(0.0, 2.0 * Math.PI, 0.3, 0.01, 128));
   meshBuilder.addMesh(MeshDataGenerator.Cylinder(radius, height, 64));
  }

origin: us.ihmc/IHMCJavaFXToolkit

/**
* Add a 3D line to this builder.
* @param x0 x-coordinate of the line start.
* @param y0 y-coordinate of the line start.
* @param z0 z-coordinate of the line start.
* @param xf x-coordinate of the line end.
* @param yf y-coordinate of the line end.
* @param zf z-coordinate of the line end.
* @param lineWidth width of the line.
* @param startColor color at the line start. Color accuracy depends on the color palette in use.
* @param endColor color at the line end. Color accuracy depends on the color palette in use.
*/
public void addLine(float x0, float y0, float z0, float xf, float yf, float zf, float lineWidth, Color startColor, Color endColor)
{
 MeshDataHolder lineMeshData = MeshDataGenerator.Line(x0, y0, z0, xf, yf, zf, lineWidth);
 float expectedDistance = 2.0f * lineWidth * lineWidth;
 Point3f[] vertices = lineMeshData.getVertices();
 TexCoord2f[] texturePoints = lineMeshData.getTexturePoints();
 Point3f start = new Point3f(x0, y0, z0);
 for (int i = 0; i < vertices.length; i++)
 {
   if (MathTools.epsilonEquals(vertices[i].distanceSquared(start), expectedDistance, 1.0e-5))
    texturePoints[i].set(colorPalette.getTextureLocation(startColor));
   else
    texturePoints[i].set(colorPalette.getTextureLocation(endColor));
 }
 meshBuilder.addMesh(lineMeshData);
}
origin: us.ihmc/ihmc-javafx-toolkit

/**
* Add a 3D line to this builder.
* @param x0 x-coordinate of the line start.
* @param y0 y-coordinate of the line start.
* @param z0 z-coordinate of the line start.
* @param xf x-coordinate of the line end.
* @param yf y-coordinate of the line end.
* @param zf z-coordinate of the line end.
* @param lineWidth width of the line.
* @param startColor color at the line start. Color accuracy depends on the color palette in use.
* @param endColor color at the line end. Color accuracy depends on the color palette in use.
*/
public void addLine(float x0, float y0, float z0, float xf, float yf, float zf, float lineWidth, Color startColor, Color endColor)
{
 MeshDataHolder lineMeshData = MeshDataGenerator.Line(x0, y0, z0, xf, yf, zf, lineWidth);
 Point3D32[] vertices = lineMeshData.getVertices();
 TexCoord2f[] texturePoints = lineMeshData.getTexturePoints();
 Point3D32 start = new Point3D32(x0, y0, z0);
 Point3D32 end = new Point3D32(xf, yf, zf);
 for (int i = 0; i < vertices.length; i++)
 {
   if (vertices[i].distanceSquared(start) < vertices[i].distanceSquared(end))
    texturePoints[i].set(colorPalette.getTextureLocation(startColor));
   else
    texturePoints[i].set(colorPalette.getTextureLocation(endColor));
 }
 meshBuilder.addMesh(lineMeshData);
}
us.ihmc.javaFXToolkit.shapesJavaFXMeshBuilderaddMesh

Popular methods of JavaFXMeshBuilder

  • generateMesh
  • <init>
  • addLine
  • addTetrahedron
  • clear
  • addPolygon
  • generateMeshDataHolder
  • addBox
  • addCone
  • addCube
  • addCylinder
  • addMultiLine
  • addCylinder,
  • addMultiLine,
  • addSphere

Popular in Java

  • Making http requests using okhttp
  • startActivity (Activity)
  • onRequestPermissionsResult (Fragment)
  • runOnUiThread (Activity)
  • FileOutputStream (java.io)
    A file output stream is an output stream for writing data to aFile or to a FileDescriptor. Whether
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • SortedSet (java.util)
    A Set that further provides a total ordering on its elements. The elements are ordered using their C
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • JLabel (javax.swing)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now