Friday, April 11, 2008

Strange API of jMonkey

Thanks to our favorite search engine, I found some information on how to generate life-like plants using regular geometrical shapes. I grabbed jMonkey and attempted to implement the same logic there. Everything was just fine until I needed to attach branches to the trunk. It appears jMonkey has NO API that lets me get to the ends of cylinder. More to the point, there is no clean API to get ANYTHING, related to a cylinder location. One would expect something like getLocation call, but no! They have getLocalTranslation(). That seems to return the coordinates of the middle. It should be fairly trivial to get to the ends, knowing the middle and the length, but I don't see any API giving me the direction of cylinder axis. I put a question on jMonkey forum 2 days ago - so far no responses.
I just don't understand this! I can not believe getting the direction is impossible - the engine draws it somehow. But how people can come up with such unclear API and no documentation is beyond my understanding. Project Wonderland wants to switch to jMonkey in the next version - good luck to these folks, they will need it!

No comments: