SimArboreal Release - Formerly "Tree Editor"

@Ogli said: Very cool project!

One question: Is it possible to rotate the trees, so that they have a different up-vector, e.g. when having a “little planet” with trees?
Or will one of the solutions (e.g. the billboards for the branches) not work for such a scenario?

:slight_smile:

EDIT: I will check this later … it would bee needed for certain camera types too (e.g. when you can fly with loopings and roll movements).

If you run the application you can see that in the grid section there is a way to vary the lean angle… if you set it to max then you can see the trees lean right over almost horizontally.

Wind assumes flat earth, though.

1 Like

Hi all, when I export the file j3o from SimArboreal Editor (.exe windows) and after I go to open in Scene Composer says “Error opening myfile.j3o” why?

1 Like
@GluckOs said: Hi all, when I export the file j3o from SimArboreal Editor (.exe windows) and after I go to open in Scene Composer says "Error opening myfile.j3o" why?

What does the “Application” console log say? Or is there otherwise more information to the error?

1 Like
@pspeed said: What does the "Application" console log say? Or is there otherwise more information to the error?

thanks for the reply…
the console does not give me any information error …

If I try to do File-> Import Model
This file can not be loaded, it is either in an unsupported format or is incompatible.
Check the bottom right corner of the SDK for a little warning sign. If it is there double-click it and report the stack trace contained at jmonkeyengine.org.
In Console: Clearing Asset List
Clearing Asset List
Start offview panel

1 Like

Odd that there was no little icon in the lower right.

Well, as a random guess, the most likely issue is that you haven’t included the sim-arboreal assets in your project dependencies. But I’d have expected you to have the little exploded monkey head in the lower corner of the SDK (or a similar icon) where you could see the stack trace and/or some kind of message in the “Application” console tab.

1 Like
@pspeed said: Odd that there was no little icon in the lower right.

Well, as a random guess, the most likely issue is that you haven’t included the sim-arboreal assets in your project dependencies. But I’d have expected you to have the little exploded monkey head in the lower corner of the SDK (or a similar icon) where you could see the stack trace and/or some kind of message in the “Application” console tab.

I feel very stupid… I tried to add dependencies but never finds the textures…the little exploded monkey head in the lower corner of the SDK says Cannot locate Texture… thanks again

1 Like

If it’s not finding the texture then you haven’t added the arboreal-assets.jar to your dependencies. It is available in the same place that you grabbed the SimArboreal.jar… (which you will also need).

1 Like

works !! thanks !! :slight_smile:

1 Like

Hello,
I am sorry to bump the topic but I have a problem to load a tree stored in a .j3o (genareted with SimArboreal) in my game.
Here is the error that I get:

déc. 18, 2014 11:50:17 PM com.jme3.app.Application handleError
GRAVE: Uncaught exception thrown in Thread[LWJGL Renderer Thread,5,main]
java.lang.IllegalArgumentException: Material parameter is not defined: BranchFlexibility
	at com.jme3.material.Material.checkSetParam(Material.java:457)
	at com.jme3.material.Material.read(Material.java:1217)
	at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:344)
	at com.jme3.export.binary.BinaryInputCapsule.readSavable(BinaryInputCapsule.java:457)
	at com.jme3.scene.Geometry.read(Geometry.java:518)
	at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:344)
	at com.jme3.export.binary.BinaryInputCapsule.resolveIDs(BinaryInputCapsule.java:483)
	at com.jme3.export.binary.BinaryInputCapsule.readSavableArray(BinaryInputCapsule.java:471)
	at com.jme3.export.binary.BinaryInputCapsule.readSavableArrayList(BinaryInputCapsule.java:587)
	at com.jme3.scene.Node.read(Node.java:599)
	at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:344)
	at com.jme3.export.binary.BinaryInputCapsule.resolveIDs(BinaryInputCapsule.java:483)
	at com.jme3.export.binary.BinaryInputCapsule.readSavableArray(BinaryInputCapsule.java:471)
	at com.jme3.export.binary.BinaryInputCapsule.readSavableArrayList(BinaryInputCapsule.java:587)
	at com.jme3.scene.Node.read(Node.java:599)
	at com.jme3.export.binary.BinaryImporter.readObject(BinaryImporter.java:344)
	at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:242)
	at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:125)
	at com.jme3.export.binary.BinaryImporter.load(BinaryImporter.java:109)
	at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:288)
	at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:374)
	at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:378)
	at be.editor.v2.world.Scene$1.run(Scene.java:83)
	at be.editor.v2.world.Scene.simpleUpdate(Scene.java:233)
	at com.jme3.app.SimpleApplication.update(SimpleApplication.java:242)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.runLoop(LwjglAbstractDisplay.java:151)
	at com.jme3.system.lwjgl.LwjglCanvas.runLoop(LwjglCanvas.java:229)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:228)
	at java.lang.Thread.run(Unknown Source)

I have added the assets to project, how can I solve that ?

1 Like

It seems like somehow the arboreal assets jar you added to your project (I assume that’s what you meant) doesn’t match the version of the tool that you are using. Hmmm… looks like maybe I didn’t update the arboreal-assets.jar with the release.

I’ve pushed a new version of the arboreal-assets.jar up… it has some even newer stuff in it so hopefully it doesn’t break in a different way. I’m not sure when I’ll be in the position to have the time to do another full release. Though, if it still breaks that will definitely up the priority I suppose.

1 Like

I updated arboreal-assets and I got this error:

RAVE: Uncaught exception thrown in Thread[LWJGL Renderer Thread,5,main]
com.jme3.asset.AssetNotFoundException: MatDefs/VertScattering.glsllib
	at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:283)
	at com.jme3.shader.plugins.GLSLLoader.loadNode(GLSLLoader.java:101)
	at com.jme3.shader.plugins.GLSLLoader.load(GLSLLoader.java:180)
	at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:288)
	at com.jme3.asset.DesktopAssetManager.loadShader(DesktopAssetManager.java:410)
	at com.jme3.material.Technique.loadShader(Technique.java:218)
	at com.jme3.material.Technique.makeCurrent(Technique.java:202)
	at com.jme3.material.Material.selectTechnique(Material.java:943)
	at com.jme3.material.Material.autoSelectTechnique(Material.java:951)
	at com.jme3.material.Material.render(Material.java:1070)
	at com.jme3.renderer.RenderManager.renderGeometry(RenderManager.java:541)
	at com.jme3.renderer.queue.RenderQueue.renderGeometryList(RenderQueue.java:322)
	at com.jme3.renderer.queue.RenderQueue.renderQueue(RenderQueue.java:374)
	at com.jme3.renderer.RenderManager.renderViewPortQueues(RenderManager.java:781)
	at com.jme3.renderer.RenderManager.flushQueue(RenderManager.java:737)
	at com.jme3.renderer.RenderManager.renderViewPort(RenderManager.java:1001)
	at com.jme3.renderer.RenderManager.render(RenderManager.java:1047)
	at com.jme3.app.SimpleApplication.update(SimpleApplication.java:252)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.runLoop(LwjglAbstractDisplay.java:151)
	at com.jme3.system.lwjgl.LwjglCanvas.runLoop(LwjglCanvas.java:229)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:228)
	at java.lang.Thread.run(Unknown Source)

I do not know if it comes from my jME version or if an assets is missing ?

1 Like

Ah, you may need the assets jar from SimFX also… and unfortunately I haven’t checked that in yet. :-/

I will try to put together new releases soon.

Edit: you could try to build from source if you are in a real hurry.

1 Like

No it’s ok I’ll wait,thank you for your help :slight_smile:

1 Like

The result is very interesting, I will certainly test it in my RTS :slight_smile:

Did you think about using L-System for the general shape growing? I think it should be very usefull to compute young and old subjects in the same way. After all, L-System as been invented for vegetation modelisation at the first place.

Keep up the good work !

1 Like
@methusalah said: The result is very interesting, I will certainly test it in my RTS :)

Did you think about using L-System for the general shape growing? I think it should be very usefull to compute young and old subjects in the same way. After all, L-System as been invented for vegetation modelisation at the first place.

Keep up the good work !

This is essentially just a simplified L-system. A full L-system would be too hard to configure in a UI… or at least it could take months and months to write such a UI. I specifically picked a simplified approach.

It’s one of the reasons I separated the parts the way I did. The algorithm generates an intermediate form that just defines the trunk/branch sections and then another step is responsible for turning it into Geometry. Thus, one could use a full up in-code L-system if they wanted to. Just spit out the intermediate form and you get the geometry stage for free.

1 Like
@pspeed said: This is essentially just a simplified L-system. A full L-system would be too hard to configure in a UI... or at least it could take months and months to write such a UI. I specifically picked a simplified approach.

It’s one of the reasons I separated the parts the way I did. The algorithm generates an intermediate form that just defines the trunk/branch sections and then another step is responsible for turning it into Geometry. Thus, one could use a full up in-code L-system if they wanted to. Just spit out the intermediate form and you get the geometry stage for free.

Very interesting ! I will have a look to the code directly, then :slight_smile:

1 Like

Just wondering about a slight issue: I exported a tree j3o file using the editor and I wanted to open this tree in the sdk to be able to add it to other scenes. I have found that if a tree as an imposter mesh type for a LOD level, the sdk wont open the j3o file with the error “Error opening tree.j3o”. There are no logs written to the output of the sdk, so I have no idea whats causing this error. Any idea what could be causing this?

1 Like

Two things:

  1. are you using the latest version of Sim-Arboreal?
  2. have you included the latest version of the arboreal-assets jar in your project?

I just wonder if it’s missing a material or something.

It’s odd that you wouldn’t at least get a stack trace either in the application log or in the exploding monkey head icon in the lower right.

1 Like

Well I assume I’m using the latest version, I’m using the one found in the first post (in the zip file). And yes I included the arboreal-assets jar as well as the SimArboreal.jar, SimFX.jar and simfx-assets.jar. I’m able to open j3o files that dont use an imposter, but as soon as I add an imposter, the sdk just rejects it.

EDIT: Looking at the source for SimArboreal, the LevelOfDetailParameters.ReductionType.Impostor enum is not used anywhere in the code. Could that have something to do with it?

1 Like

Uh… it must be used somewhere. Or at least somehow imposters are used. Could be that it’s an editor specific thing. I don’t have time to look at the code right now and I can’t remember for sure… but I have loaded tree j3o’s before without issue, even with imposters. In fact, it was quite some effort to get that to work properly using embedded textures.

Also, what version of the SDK are you using?

1 Like