Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ private void createCameraMotion() {

private void createScene() {

model = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
model = assetManager.loadModel("Models/Oto/Oto.j3o");
model.center();
model.setShadowMode(ShadowMode.CastAndReceive);
rootNode.attachChild(model);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ public void simpleInitApp() {
PhysicsTestHelper.createPhysicsTestWorld(rootNode, assetManager,
physicsSpace);

model = (Node) assetManager.loadModel("Models/Sinbad/Sinbad.mesh.xml");
model = (Node) assetManager.loadModel("Models/Sinbad/Sinbad.j3o");
rootNode.attachChild(model);

composer = model.getControl(AnimComposer.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ private void buildPlayer() {
final float mass = 400;

// Load model and get chassis Geometry
carNode = (Node) assetManager.loadModel("Models/Ferrari/Car.scene");
carNode = (Node) assetManager.loadModel("Models/Ferrari/Car_Scene.j3o");
carNode.setShadowMode(ShadowMode.Cast);
Geometry chassis = findGeom(carNode, "Car");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ public void simpleInitApp() {
}

private void buildPlayer() {
spaceCraft = assetManager.loadModel("Models/HoverTank/Tank2.mesh.xml");
spaceCraft = assetManager.loadModel("Models/HoverTank/Tank2.j3o");
CollisionShape colShape = CollisionShapeFactory.createDynamicMeshShape(spaceCraft);
spaceCraft.setShadowMode(ShadowMode.CastAndReceive);
spaceCraft.setLocalTranslation(startLocation);
Expand All @@ -164,7 +164,7 @@ public void makeMissile() {
Quaternion rot = spaceCraft.getWorldRotation();
Vector3f dir = rot.getRotationColumn(2);

Spatial missile = assetManager.loadModel("Models/SpaceCraft/Rocket.mesh.xml");
Spatial missile = assetManager.loadModel("Models/SpaceCraft/Rocket.j3o");
missile.scale(0.5f);
missile.rotate(0, FastMath.PI, 0);
missile.updateGeometricState();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public void simpleInitApp() {
physicsCharacter = new CharacterControl(new CapsuleCollisionShape(0.5f, 1.8f), .1f);
physicsCharacter.setPhysicsLocation(new Vector3f(0, 1, 0));
Node characterNode = new Node("character node");
Spatial model = assetManager.loadModel("Models/Sinbad/Sinbad.mesh.xml");
Spatial model = assetManager.loadModel("Models/Sinbad/Sinbad.j3o");
model.scale(0.25f);
characterNode.addControl(physicsCharacter);
getPhysicsSpace().add(physicsCharacter);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public void simpleInitApp() {
stateManager.attach(bulletAppState);
initCrossHair();

Spatial s = assetManager.loadModel("Models/Elephant/Elephant.mesh.xml");
Spatial s = assetManager.loadModel("Models/Elephant/Elephant.j3o");
s.setLocalScale(0.1f);

CollisionShape collisionShape = CollisionShapeFactory.createMeshShape(s);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,9 @@ public void simpleInitApp() {
physicsSpace);
initWall(2f, 1f, 1f);

model = (Node) assetManager.loadModel("Models/Sinbad/Sinbad.mesh.xml");
model = (Node) assetManager.loadModel("Models/Sinbad/Sinbad.j3o");
rootNode.attachChild(model);

model.lookAt(new Vector3f(0f, 0f, -1f), Vector3f.UNIT_Y);
model.setLocalTranslation(4f, 0f, -7f);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ private void createTerrain() {
private void createCharacter() {
CapsuleCollisionShape capsule = new CapsuleCollisionShape(3f, 4f);
character = new CharacterControl(capsule, 0.01f);
model = (Node) assetManager.loadModel("Models/Oto/Oto.mesh.xml");
model = (Node) assetManager.loadModel("Models/Oto/Oto.j3o");
model.addControl(character);
character.setPhysicsLocation(new Vector3f(-140, 40, -10));
rootNode.attachChild(model);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -262,19 +262,19 @@ private void dropTest2(Vector3f offset) {
}

private void dropPot(Vector3f offset) {
drop(offset.add(-12, 7, 15), "Models/Teapot/Teapot.mesh.xml", 1.0f, 2);
drop(offset.add(-12, 7, 15), "Models/Teapot/Teapot.j3o", 1.0f, 2);
}

private void dropSword(Vector3f offset) {
drop(offset.add(-10, 5, 3), "Models/Sinbad/Sword.mesh.xml", 1.0f, 2);
drop(offset.add(-10, 5, 3), "Models/Sinbad/Sword.j3o", 1.0f, 2);
}

private void dropSign(Vector3f offset) {
drop(offset.add(9, 15, 5), "Models/Sign Post/Sign Post.mesh.xml", 1.0f, 1);
drop(offset.add(9, 15, 5), "Models/Sign Post/Sign Post.j3o", 1.0f, 1);
}

private void dropRocket(Vector3f offset) {
RigidBodyControl c = drop(offset.add(26, 4, 7), "Models/SpaceCraft/Rocket.mesh.xml", 4.0f, 3);
RigidBodyControl c = drop(offset.add(26, 4, 7), "Models/SpaceCraft/Rocket.j3o", 4.0f, 3);
c.setAngularDamping(0.5f);
c.setLinearDamping(0.5f);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ private void setupScene() {
shootables.attachChild(torus);

// load a character from jme3-testdata
Spatial golem = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial golem = assetManager.loadModel("Models/Oto/Oto.j3o");
golem.scale(0.5f);
golem.setLocalTranslation(-1.0f, -1.5f, -0.6f);
shootables.attachChild(golem);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public void simpleInitApp() {
q.updateBound();
// Geometry teapot = new Geometry("MyGeom", q);

teapot = assetManager.loadModel("Models/Teapot/Teapot.mesh.xml");
teapot = assetManager.loadModel("Models/Teapot/Teapot.j3o");
// teapot.scale(2f, 2f, 2f);
// teapot.move(2f, 2f, -.5f);
teapot.rotate(FastMath.HALF_PI, FastMath.HALF_PI, FastMath.HALF_PI);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public void simpleInitApp() {
rootNode.attachChild(geom1);

// load a character from jme3-testdata
golem = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
golem = assetManager.loadModel("Models/Oto/Oto.j3o");
golem.scale(0.5f);
golem.setLocalTranslation(-1.0f, -1.5f, -0.6f);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ public void setupFloor(){
// }

public void setupRobotGuy(){
Node model = (Node) assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Node model = (Node) assetManager.loadModel("Models/Oto/Oto.j3o");
Material mat = assetManager.loadMaterial("Models/Oto/Oto.j3m");
model.getChild(0).setMaterial(mat);
// model.setAnimation("Walk");
Expand All @@ -163,7 +163,7 @@ public void setupRobotGuy(){
}

public void setupSignpost(){
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.mesh.xml");
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.j3o");
Material mat = assetManager.loadMaterial("Models/Sign Post/Sign Post.j3m");
signpost.setMaterial(mat);
signpost.rotate(0, FastMath.HALF_PI, 0);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,13 @@
* plays an animation, and displays debugging information about its skinning
* and material parameters.
*
* @deprecated as of jMonkeyEngine 3.6, for removal in a future version.
* The Ogre model format is deprecated. Consider using glTF (.glb/.gltf) or other modern formats instead.
* This test is maintained for backward compatibility during the transition period.
*
* @author capdevon
*/
@Deprecated
public class TestOgreConvert extends SimpleApplication {

public static void main(String[] args) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public void simpleInitApp() {
rootNode.addLight(dl);

/* Load a model that contains animation */
Node player = (Node) assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Node player = (Node) assetManager.loadModel("Models/Oto/Oto.j3o");
player.setLocalScale(0.5f);
rootNode.attachChild(player);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public void simpleInitApp() {
guiNode.attachChild(helloText);

/* Load a Ninja model (OgreXML + material + texture from test_data) */
Spatial ninja = assetManager.loadModel("Models/Ninja/Ninja.mesh.xml");
Spatial ninja = assetManager.loadModel("Models/Ninja/Ninja.j3o");
ninja.scale(0.05f, 0.05f, 0.05f);
ninja.rotate(0.0f, -3.0f, 0.0f);
ninja.setLocalTranslation(0.0f, -5.0f, -2.0f);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public void simpleInitApp() {
assetManager.registerLocator(
"https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/jmonkeyengine/town.zip",
HttpZipLocator.class);
Spatial sceneModel = assetManager.loadModel("main.scene");
Spatial sceneModel = assetManager.loadModel("main.j3o");
sceneModel.setLocalScale(2f);

// We set up collision detection for the scene by creating a
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ private void initCrossHairs() {

private Spatial makeCharacter() {
// load a character from jme3-testdata
Spatial golem = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial golem = assetManager.loadModel("Models/Oto/Oto.j3o");
golem.scale(0.5f);
golem.setLocalTranslation(-1.0f, -1.5f, -0.6f);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public void simpleInitApp() {
dlsr.setLight(dl);
viewPort.addProcessor(dlsr);

Node player = (Node) assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Node player = (Node) assetManager.loadModel("Models/Oto/Oto.j3o");
player.setShadowMode(RenderQueue.ShadowMode.Cast);
rootNode.attachChild(player);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public static void main(String[] args){
public void simpleInitApp() {
flyCam.setMoveSpeed(10);

Node scene = (Node) assetManager.loadModel("Scenes/ManyLights/Main.scene");
Node scene = (Node) assetManager.loadModel("Scenes/ManyLights/Main.j3o");
rootNode.attachChild(scene);
// guiNode.setCullHint(CullHint.Always);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public void simpleInitApp() {

flyCam.setMoveSpeed(10);

Node scene = (Node) assetManager.loadModel("Scenes/ManyLights/Main.scene");
Node scene = (Node) assetManager.loadModel("Scenes/ManyLights/Main.j3o");
rootNode.attachChild(scene);
Node n = (Node) rootNode.getChild(0);
final LightList lightList = n.getWorldLightList();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public void simpleInitApp() {
characters.setShadowMode(ShadowMode.Cast);
rootNode.attachChild(characters);

Spatial golem = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial golem = assetManager.loadModel("Models/Oto/Oto.j3o");
golem.scale(0.5f);
golem.setLocalTranslation(200.0f, -6f, 200f);
golem.setShadowMode(ShadowMode.CastAndReceive);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ public void setupFloor(){


public void setupSignpost(){
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.mesh.xml");
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.j3o");
Material mat = assetManager.loadMaterial("Models/Sign Post/Sign Post.j3m");
// mat.setBoolean("VertexLighting", true);
signpost.setMaterial(mat);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ public void setupFloor() {
}

public void setupSignpost() {
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.mesh.xml");
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.j3o");
Material mat = assetManager.loadMaterial("Models/Sign Post/Sign Post.j3m");
// mat.setBoolean("VertexLighting", true);
signpost.setMaterial(mat);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public void setupFloor() {
}

public void setupSignpost() {
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.mesh.xml");
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.j3o");
Material matSp = assetManager.loadMaterial("Models/Sign Post/Sign Post.j3m");
MikktspaceTangentGenerator.generate(signpost);
signpost.setMaterial(matSp);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public void setupFloor() {
}

public void setupSignpost() {
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.mesh.xml");
Spatial signpost = assetManager.loadModel("Models/Sign Post/Sign Post.j3o");
Material mat = assetManager.loadMaterial("Models/Sign Post/Sign Post.j3m");
MikktspaceTangentGenerator.generate(signpost);
signpost.setMaterial(mat);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public static void main(String[] args) {

@Override
public void simpleInitApp() {
Node tank = (Node) assetManager.loadModel("Models/HoverTank/Tank2.mesh.xml");
Node tank = (Node) assetManager.loadModel("Models/HoverTank/Tank2.j3o");

flyCam.setEnabled(false);
ChaseCamera chaseCam = new ChaseCamera(cam, tank, inputManager);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public static void main(String[] args){
public void simpleInitApp() {
viewPort.setBackgroundColor(ColorRGBA.DarkGray);

Spatial bumpy = assetManager.loadModel("Models/MonkeyHead/MonkeyHead.mesh.xml");
Spatial bumpy = assetManager.loadModel("Models/MonkeyHead/MonkeyHead.j3o");
rootNode.attachChild(bumpy);

lightMdl = new Geometry("Light", new Sphere(10, 10, 0.1f));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,14 @@
import com.jme3.scene.Spatial;
import com.jme3.scene.shape.Sphere;

/**
* Example demonstrating Ogre model loading.
*
* @deprecated as of jMonkeyEngine 3.6, for removal in a future version.
* The Ogre model format is deprecated. Consider using glTF (.glb/.gltf) or other modern formats instead.
* See TestGltfLoading for a modern alternative.
*/
@Deprecated
public class TestOgreLoading extends SimpleApplication {

private float angle1;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,9 @@ public void simpleInitApp() {
rootNode.addLight(new AmbientLight(ColorRGBA.DarkGray));

Spatial model = assetManager.loadModel("Models/Jaime/Jaime.j3o");
// Spatial model = assetManager.loadModel("Models/Oto/Oto.mesh.xml").scale(0.2f).move(0, 1, 0);
//Spatial model = assetManager.loadModel("Models/Sinbad/Sinbad.mesh.xml");
//Spatial model = assetManager.loadModel("Models/Elephant/Elephant.mesh.xml").scale(0.02f);
// Spatial model = assetManager.loadModel("Models/Oto/Oto.j3o").scale(0.2f).move(0, 1, 0);
//Spatial model = assetManager.loadModel("Models/Sinbad/Sinbad.j3o");
//Spatial model = assetManager.loadModel("Models/Elephant/Elephant.j3o").scale(0.02f);

AnimMigrationUtils.migrate(model);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public void simpleInitApp() {
}

private Spatial loadModel(int i) {
Spatial model = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial model = assetManager.loadModel("Models/Oto/Oto.j3o");
model.setLocalScale(0.1f);
AnimComposer composer = model.getControl(AnimComposer.class);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public void simpleInitApp() {
dl.setColor(new ColorRGBA(1f, 1f, 1f, 1f));
rootNode.addLight(dl);

Spatial model = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial model = assetManager.loadModel("Models/Oto/Oto.j3o");
rootNode.attachChild(model);
model.center();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public void simpleInitApp() {

AnimComposer composer;

Spatial originalModel = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial originalModel = assetManager.loadModel("Models/Oto/Oto.j3o");
composer = originalModel.getControl(AnimComposer.class);
composer.setCurrentAction("Walk");
composer.setGlobalSpeed(1.5f);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,13 @@
import com.jme3.scene.Spatial;
import com.jme3.scene.shape.Box;

/**
* Example demonstrating Ogre model animation.
*
* @deprecated as of jMonkeyEngine 3.6, for removal in a future version.
* The Ogre model format is deprecated. Consider using glTF (.glb/.gltf) or other modern formats instead.
*/
@Deprecated
public class TestOgreAnim extends SimpleApplication implements ActionListener {

private AnimComposer animComposer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,13 @@
import com.jme3.scene.Node;
import com.jme3.scene.debug.custom.ArmatureDebugger;

/**
* Example demonstrating complex Ogre model animations with armature masks and advanced blending.
*
* @deprecated as of jMonkeyEngine 3.6, for removal in a future version.
* The Ogre model format is deprecated. Consider using glTF (.glb/.gltf) or other modern formats instead.
*/
@Deprecated
public class TestOgreComplexAnim extends SimpleApplication {

private SkinningControl skinningControl;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public void simpleInitApp() {

for (int i = 0; i < SIZE; i++) {
for (int j = 0; j < SIZE; j++) {
Spatial model = assetManager.loadModel("Models/Oto/Oto.mesh.xml");
Spatial model = assetManager.loadModel("Models/Oto/Oto.j3o");
//setting a different material
model.setMaterial(m.clone());
model.setLocalScale(0.1f);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ public void setupLighting(){
}

public void setupModel(){
Spatial model = assetManager.loadModel("Models/MonkeyHead/MonkeyHead.mesh.xml");
Spatial model = assetManager.loadModel("Models/MonkeyHead/MonkeyHead.j3o");
makeToonish(model);
model.rotate(0, FastMath.PI, 0);
// signpost.setLocalTranslation(12, 3.5f, 30);
Expand Down
Loading