本文整理汇总了Java中com.sun.j3d.utils.behaviors.vp.OrbitBehavior类的典型用法代码示例。如果您正苦于以下问题:Java OrbitBehavior类的具体用法?Java OrbitBehavior怎么用?Java OrbitBehavior使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
OrbitBehavior类属于com.sun.j3d.utils.behaviors.vp包,在下文中一共展示了OrbitBehavior类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* OrbitBehaviour allows the user to rotate around the scene, and to zoom in
* and out.
*/
private void orbitControls(Canvas3D c) {
OrbitBehavior orbit = new OrbitBehavior(c, OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(bounds);
ViewingPlatform vp = su.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例2: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* allows for navigation with the mouse
*
* @param canvas3D the canvas through which shall be navigated
*/
private void orbitControls(Canvas3D canvas3D) {
//logger.info("orbitControls");
OrbitBehavior orbit = new OrbitBehavior(canvas3D, OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(boundingSphere);
ViewingPlatform vp = simpleUniverse.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例3: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* allows for navigation with the mouse
*
* @param canvas3D
* the canvas through which shall be navigated
*/
private void orbitControls(Canvas3D canvas3D) {
//logger.info("orbitControls");
OrbitBehavior orbit = new OrbitBehavior(canvas3D, OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(boundingSphere);
ViewingPlatform vp = simpleUniverse.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例4: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* OrbitBehaviour allows the user to rotate around the scene, and to zoom in
* and out.
*/
private void orbitControls(Canvas3D c) {
OrbitBehavior orbit = new OrbitBehavior(c, OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(bounds);
ViewingPlatform vp = su.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例5: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* �}�E�X������\�ɂ���
*
* @param canvas �L�����o�X
*/
private void orbitControls(Canvas3D canvas) {
BoundingSphere bounds = new BoundingSphere(new Point3d(0, 0, 0), 100);
OrbitBehavior orbit = new OrbitBehavior(canvas,
OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(bounds);
ViewingPlatform vp = universe.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例6: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* �}�E�X����
*
* @param canvas
* �L�����o�X
*/
private void orbitControls(Canvas3D canvas) {
OrbitBehavior orbit = new OrbitBehavior(canvas,
OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(bounds); // �e�����y�ڂ��͈͂�ݒ�
ViewingPlatform vp = universe.getViewingPlatform(); // ���_���擾
vp.setViewPlatformBehavior(orbit); // ���_���}�E�X�Ő���\�ɂȂ�
}
示例7: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
/**
* �}�E�X������\�ɂ���
*
* @param canvas �L�����o�X
*/
private void orbitControls(Canvas3D canvas) {
BoundingSphere bounds = new BoundingSphere(new Point3d(), Double.POSITIVE_INFINITY);
OrbitBehavior orbit = new OrbitBehavior(canvas,
OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(bounds);
ViewingPlatform vp = universe.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例8: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
private void orbitControls(Canvas3D canvas3D) {
OrbitBehavior orbit = new OrbitBehavior(canvas3D, OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(bounds);
ViewingPlatform vp = simpleU.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例9: orbitControls
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
private void orbitControls(Canvas3D canvas3D) {
OrbitBehavior orbit = new OrbitBehavior(canvas3D, OrbitBehavior.REVERSE_ALL);
orbit.setSchedulingBounds(new BoundingSphere());
ViewingPlatform vp = simpleU.getViewingPlatform();
vp.setViewPlatformBehavior(orbit);
}
示例10: init
import com.sun.j3d.utils.behaviors.vp.OrbitBehavior; //导入依赖的package包/类
private void init( )
{
canvasComponent.setPreferredSize( new Dimension( 400 , 400 ) );
canvasComponent.setSize( new Dimension( 400 , 400 ) );
universe = new SimpleUniverse( this.canvas );
frame = new JFrame( );
frame.getContentPane( ).setLayout( new BorderLayout( ) );
frame.getContentPane( ).add( BorderLayout.CENTER , canvas );
vp = universe.getViewingPlatform( );
camera = new Camera3D( vp );
camera.setLocation( new Point3d( 0 , 2 , 0 ) , true );
camera.lookAt( new Point3d( 0 , 0 , 0 ) , true );
sceneRoot = new BranchGroup( );
sceneRoot.setCapability( BranchGroup.ALLOW_CHILDREN_EXTEND );
sceneRoot.setCapability( BranchGroup.ALLOW_CHILDREN_READ );
sceneRoot.setCapability( BranchGroup.ALLOW_CHILDREN_WRITE );
axes = new XyzAxes2( .05f , 1f );
sceneRoot.addChild( axes );
ambientLight = new AmbientLight( new Color3f( .3f , .3f , .3f ) );
worldBounds = new BoundingSphere( new Point3d( ) , 10000.0 );
ambientLight.setInfluencingBounds( worldBounds );
ambientLight.setCapability( Light.ALLOW_STATE_WRITE );
sceneRoot.addChild( ambientLight );
sceneTrans = new TransformGroup( );
sceneTrans.setCapability( TransformGroup.ALLOW_TRANSFORM_WRITE );
sceneTrans.addChild( sceneRoot );
worldRoot = new BranchGroup( );
worldRoot.addChild( sceneTrans );
orbiter = new OrbitBehavior( universe.getCanvas( ) );
orbiter.setSchedulingBounds( worldBounds );
vp.setViewPlatformBehavior( orbiter );
universe.addBranchGraph( worldRoot );
frame.pack( );
}