Tabnine Logo
Shape3D.setAppearance
Code IndexAdd Tabnine to your IDE (free)

How to use
setAppearance
method
in
org.scijava.java3d.Shape3D

Best Java code snippets using org.scijava.java3d.Shape3D.setAppearance (Showing top 13 results out of 315)

origin: stackoverflow.com

app.setPolygonAttributes(pa);
sh.setGeometry(lsa);
sh.setAppearance(app);
sh.setPickable(true); 
TransformGroup objRotate = new TransformGroup();
origin: stackoverflow.com

app.setMaterial(mat);
app.setPolygonAttributes(pa);
sh.setAppearance(app);
sh.setPickable(true);
GeometryArray ga=null;
origin: org.scijava/j3dutils

 /** Sets appearance of the Sphere.
  */
 @Override
 public void setAppearance(Appearance ap) {
//     ((Shape3D)((Group)getChild(0)).getChild(BODY)).setAppearance(ap);
   ((Shape3D)getChild(BODY)).setAppearance(ap);
 }

origin: org.scijava/j3dutils

/**
 * Sets appearance of the cone. This will set each part of the
 *  cone (cap & body) to the same appearance. To set each
 *  part's appearance separately, use getShape(partId) to get the
 *  individual shape and call shape.setAppearance(ap).
 */
@Override
public void setAppearance(Appearance ap){
  ((Shape3D)getChild(BODY)).setAppearance(ap);
  ((Shape3D)getChild(CAP)).setAppearance(ap);
}
origin: org.scijava/j3dutils

/** Sets appearance of the cylinder. This will set each part of the
 *  cylinder (TOP,BOTTOM,BODY) to the same appearance. To set each
 *  part's appearance separately, use getShape(partId) to get the
 *  individual shape and call shape.setAppearance(ap).
 */
@Override
public void setAppearance(Appearance ap) {
((Shape3D)getChild(BODY)).setAppearance(ap);
((Shape3D)getChild(TOP)).setAppearance(ap);
((Shape3D)getChild(BOTTOM)).setAppearance(ap);
}
origin: org.scijava/j3dutils

/** Sets the main appearance of the primitive (all subparts) to
 *  same appearance.
 */
public abstract void setAppearance(Appearance ap);
origin: org.scijava/j3dutils

 /**
  *  Sets appearance of the box. This will set each face of the
  *  box to the same appearance. To set each face's appearance
  *  separately, use getShape(partId) to get the
  *  individual shape and call shape.setAppearance(ap).
  */

 @Override
 public void setAppearance(Appearance ap){
//     ((Shape3D)((Group)getChild(0)).getChild(TOP)).setAppearance(ap);
//     ((Shape3D)((Group)getChild(0)).getChild(LEFT)).setAppearance(ap);
//     ((Shape3D)((Group)getChild(0)).getChild(RIGHT)).setAppearance(ap);
//     ((Shape3D)((Group)getChild(0)).getChild(FRONT)).setAppearance(ap);
//     ((Shape3D)((Group)getChild(0)).getChild(BACK)).setAppearance(ap);
//     ((Shape3D)((Group)getChild(0)).getChild(BOTTOM)).setAppearance(ap);
   ((Shape3D)getChild(TOP)).setAppearance(ap);
   ((Shape3D)getChild(LEFT)).setAppearance(ap);
   ((Shape3D)getChild(RIGHT)).setAppearance(ap);
   ((Shape3D)getChild(FRONT)).setAppearance(ap);
   ((Shape3D)getChild(BACK)).setAppearance(ap);
   ((Shape3D)getChild(BOTTOM)).setAppearance(ap);
 }

origin: sc.fiji/3D_Viewer

public void enableTextures() {
  final int[] size = new int[] { volume.xDim, volume.yDim, volume.zDim };
  for (int axis = 0; axis < 3; axis++) {
    for (int i = 0; i < size[axis]; i++) {
      final Appearance app = appCreator.getAppearance(axis, i);
      final Group frontGroup =
        (Group) axisSwitch.getChild(axisIndex[axis][FRONT]);
      ((Shape3D) ((Group) frontGroup.getChild(i)).getChild(0))
        .setAppearance(app);
      final Group backGroup =
        (Group) axisSwitch.getChild(axisIndex[axis][BACK]);
      ((Shape3D) ((Group) backGroup.getChild(size[axis] - i - 1)).getChild(0))
        .setAppearance(app);
    }
  }
}
origin: sc.fiji/3D_Viewer

public void disableTextures() {
  final int[] size = new int[] { volume.xDim, volume.yDim, volume.zDim };
  final Appearance empty = new Appearance();
  for (int axis = 0; axis < 3; axis++) {
    for (int i = 0; i < size[axis]; i++) {
      final Group frontGroup =
        (Group) axisSwitch.getChild(axisIndex[axis][FRONT]);
      final Group backGroup =
        (Group) axisSwitch.getChild(axisIndex[axis][BACK]);
      final Appearance app = getAppearance(axis, i);
      app.getTextureUnitState(0).setTexture(null);
      ((Shape3D) ((Group) frontGroup.getChild(i)).getChild(0))
        .setAppearance(empty);
      ((Shape3D) ((Group) backGroup.getChild(i)).getChild(0))
        .setAppearance(empty);
    }
  }
}
origin: org.scijava/j3dutils

@Override
public void buildGraph() {
  ((Shape3D)node).setAppearance( (Appearance)control.getSymbolTable().getJ3dNode( appearance ) );
  ((Shape3D)node).setGeometry( (Geometry)control.getSymbolTable().getJ3dNode( geometry[0] ) );
  for(int i=1; i<geometry.length; i++) {
    ((Shape3D)node).addGeometry( (Geometry)control.getSymbolTable().getJ3dNode( geometry[i] ) );
  }
  super.buildGraph(); // Must be last call in method
}
origin: sc.fiji/3D_Viewer

shape.addGeometry(makeLine(p[3], p[7], c, td, 0f, ts, true));
shape.setAppearance(createAppearance(color));
addChild(shape);
origin: org.scijava/j3dutils

shape.setAppearance(a);
origin: org.scijava/j3dutils

objectShape.setAppearance(appearance);
objectShapeList.addElement(objectShape);
org.scijava.java3dShape3DsetAppearance

Javadoc

Sets the appearance component of this Shape3D node. Setting it to null specifies that default values are used for all appearance attributes.

Popular methods of Shape3D

  • <init>
    Constructs and initializes a Shape3D node with the specified geometry and appearance components. The
  • getGeometry
    Retrieves the geometry component at the specified index from this Shape3D node's list of geometry co
  • getAppearance
    Retrieves the appearance component of this shape node.
  • addGeometry
    Appends the specified geometry component to this Shape3D node's list of geometry components. If ther
  • setCapability
  • setGeometry
    Replaces the geometry component at the specified index in this Shape3D node's list of geometry compo
  • intersect
    Checks whether the geometry in this shape node intersects with the specified pickShape.
  • numGeometries
    Returns the number of geometry components in this Shape3D node's list of geometry components.
  • checkDuplicateNode
  • checkForCycle
  • cloneTree
  • duplicateAttributes
    Copies all Shape3D information fromoriginalNode into the current node. This method is called from th
  • cloneTree,
  • duplicateAttributes,
  • duplicateNode,
  • getCapability,
  • getCollisionBounds,
  • getNodeComponent,
  • getUserData,
  • isLive,
  • isLiveOrCompiled

Popular in Java

  • Making http requests using okhttp
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getContentResolver (Context)
  • findViewById (Activity)
  • Pointer (com.sun.jna)
    An abstraction for a native pointer data type. A Pointer instance represents, on the Java side, a na
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • Top 12 Jupyter Notebook extensions
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