本文整理匯總了Java中com.jme3.renderer.RenderManager.renderScene方法的典型用法代碼示例。如果您正苦於以下問題:Java RenderManager.renderScene方法的具體用法?Java RenderManager.renderScene怎麽用?Java RenderManager.renderScene使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.jme3.renderer.RenderManager
的用法示例。
在下文中一共展示了RenderManager.renderScene方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: simpleRender
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
@Override
public void simpleRender(RenderManager rm){
Renderer r = rm.getRenderer();
//do FBO rendering
r.setFrameBuffer(fb);
rm.setCamera(cam, false); // FBO uses current camera
r.clearBuffers(true, true, true);
rm.renderScene(fbNode, viewPort);
rm.flushQueue(viewPort);
//go back to default rendering and let
//SimpleApplication render the default scene
r.setFrameBuffer(null);
}
示例2: render
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
/**
* For internal use only
* specific render for the ragdoll(if debugging)
* @param rm
* @param vp
*/
public void render(RenderManager rm, ViewPort vp) {
if (enabled && space != null && space.getDebugManager() != null) {
if (!debug) {
attachDebugShape(space.getDebugManager());
}
for (Iterator<PhysicsBoneLink> it = boneLinks.values().iterator(); it.hasNext();) {
PhysicsBoneLink physicsBoneLink = it.next();
Spatial debugShape = physicsBoneLink.rigidBody.debugShape();
if (debugShape != null) {
debugShape.setLocalTranslation(physicsBoneLink.rigidBody.getMotionState().getWorldLocation());
debugShape.setLocalRotation(physicsBoneLink.rigidBody.getMotionState().getWorldRotationQuat());
debugShape.updateGeometricState();
rm.renderScene(debugShape, vp);
}
}
}
}
示例3: render
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
public void render(RenderManager rm, ViewPort vp) {
if (enabled && space != null && space.getDebugManager() != null) {
if (debugShape == null) {
attachDebugShape(space.getDebugManager());
}
debugShape.setLocalTranslation(motionState.getWorldLocation());
debugShape.setLocalRotation(motionState.getWorldRotation());
debugShape.updateLogicalState(0);
debugShape.updateGeometricState();
rm.renderScene(debugShape, vp);
}
}
示例4: render
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
public void render(RenderManager rm, ViewPort vp) {
if (enabled && space != null && space.getDebugManager() != null) {
if (debugShape == null) {
attachDebugShape(space.getDebugManager());
}
debugShape.setLocalTranslation(getPhysicsLocation());
debugShape.updateLogicalState(0);
debugShape.updateGeometricState();
rm.renderScene(debugShape, vp);
}
}
示例5: render
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
public void render(RenderManager rm, ViewPort vp) {
if (enabled && space != null && space.getDebugManager() != null) {
if (debugShape == null) {
attachDebugShape(space.getDebugManager());
}
//TODO: using spatial traslation/rotation..
debugShape.setLocalTranslation(spatial.getWorldTranslation());
debugShape.setLocalRotation(spatial.getWorldRotation());
debugShape.updateLogicalState(0);
debugShape.updateGeometricState();
rm.renderScene(debugShape, vp);
}
}
示例6: render
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
public void render(RenderManager rm, ViewPort vp) {
if (enabled && space != null && space.getDebugManager() != null) {
if (debugShape == null) {
attachDebugShape(space.getDebugManager());
}
debugShape.setLocalTranslation(spatial.getWorldTranslation());
debugShape.setLocalRotation(spatial.getWorldRotation());
debugShape.updateLogicalState(0);
debugShape.updateGeometricState();
rm.renderScene(debugShape, vp);
}
}
示例7: render
import com.jme3.renderer.RenderManager; //導入方法依賴的package包/類
public void render(RenderManager rm, ViewPort vp) {
if (enabled && space != null && space.getDebugManager() != null) {
if (debugShape == null) {
attachDebugShape(space.getDebugManager());
}
Node debugNode = (Node) debugShape;
debugShape.setLocalTranslation(spatial.getWorldTranslation());
debugShape.setLocalRotation(spatial.getWorldRotation());
int i = 0;
for (Iterator<VehicleWheel> it = wheels.iterator(); it.hasNext();) {
VehicleWheel physicsVehicleWheel = it.next();
Vector3f location = physicsVehicleWheel.getLocation().clone();
Vector3f direction = physicsVehicleWheel.getDirection().clone();
Vector3f axle = physicsVehicleWheel.getAxle().clone();
float restLength = physicsVehicleWheel.getRestLength();
float radius = physicsVehicleWheel.getRadius();
Geometry locGeom = (Geometry) debugNode.getChild("WheelLocationDebugShape" + i);
Geometry dirGeom = (Geometry) debugNode.getChild("WheelDirectionDebugShape" + i);
Geometry axleGeom = (Geometry) debugNode.getChild("WheelAxleDebugShape" + i);
Geometry wheelGeom = (Geometry) debugNode.getChild("WheelRadiusDebugShape" + i);
Arrow locArrow = (Arrow) locGeom.getMesh();
locArrow.setArrowExtent(location);
Arrow axleArrow = (Arrow) axleGeom.getMesh();
axleArrow.setArrowExtent(axle.normalizeLocal().multLocal(0.3f));
Arrow wheelArrow = (Arrow) wheelGeom.getMesh();
wheelArrow.setArrowExtent(direction.normalizeLocal().multLocal(radius));
Arrow dirArrow = (Arrow) dirGeom.getMesh();
dirArrow.setArrowExtent(direction.normalizeLocal().multLocal(restLength));
dirGeom.setLocalTranslation(location);
axleGeom.setLocalTranslation(location.addLocal(direction));
wheelGeom.setLocalTranslation(location);
i++;
}
debugShape.updateLogicalState(0);
debugShape.updateGeometricState();
rm.renderScene(debugShape, vp);
}
}