[devlog] jme3 as blender renderer

Hi,

I would like to share my current wip tool :

Goals :

  • use blender as level editor
  • use blender as visual editor for jme (or other game engine)

Happy Christmas + 3

9 Likes

Really looking forward to this

Wow!
This is my dream!
Do you modify blender sources?

@mifth said: Wow! This is my dream! Do you modify blender sources?

No, I learn blender scripting ;-). I use regular blender 2.72b packaged for ArchLinux (my OS).

I create the following stack :

  1. a blender-addon: send request over sockect (IPC), can be reuse by any game engine, tools,... (license : GPL)
  2. a open source format to exchange data (and command) over network or file (a future OpenGex competitor :-P ) (license : CC0)
  3. an AppState that act as a socket server to manage command send from blender-addon (license : CC0)

The 3 items are WIP. But I hope to release a first playable version in 2015-01.
Only the 3. is jme aware, everything else is game engine agnostic.

Thanks for your interest.

1 Like

basic support for lights and material (no texture)

2 Likes

Hi,

very nice tool :slight_smile:
I just wonder how do you export data to jme so that it can see it ?
Do you use python in blender to export the scene directly to j3o or other format like OGRE ?

I transfert data throught network socket. I create an extensible protocol. For the 3D data, I give a try to :

  • opengex, but I've got some special need (for network and partial update) that it doesn't match. I didn't invest more on other blender exporter / jme importer, because there are made for file transfert (and often text based, each one with its owns issues)
  • home made msgpack based format, but coding saver/loader require too many time

So for 3D data (and some commands) I create my own (protobuf based): pgex. You can take a look to the FAQ.

Currently I didn’t provide a blender exporter (I’ll do). User can use its favorite format (.blend, ogre, fbx) to save the scene/model and to import it into jme. The blender side is not jme specific (I could be used with any game engine).

The 3 projects are very WIP, every contributions are welcome.

a new video to show progress

2 Likes

So basically your model format already has a somewhat working exporter for blender? Neat.

That’s impressive!
Good work

Thanks for comments, I really appreciate and I hope to provide a usefull tool/stack (first release before end of this month).

@EmpirePhoenix, in fact I didn’t code the exporter (to file) for blender. I’ll do it today.

FYI the javafx windows I used to display jme’scene is available as a lib (jar + source): jme3_ext_spatial_explorer. It’s very easy to integrate it java8+jme apps and to add action into context menu (see README).

1 Like

I published the elements (blender addon + jme app, jme lib,…) used to make the demo (see video).

If you want to give it a try : https://github.com/davidB/blender_external_renderer

UPDATE: basic support of texture

2 Likes

UPDATE: a small video to show the optimisation in network communication :

  • animations run on blender side
  • geometries are sent and merged at every frames
3 Likes

It’s pretty crazy what you are doing. Kudos for undertaking this work.

Even though I don’t understand the technicalities yet, but does it means we don’t need dedicated shader editor and cinematic editor for jME SDK any more? Can we use blender to do the heavy lifting?

Thanks, being able to use blender for material edition or to create cinematic is one of the goals. But it’s far to be done. :stuck_out_tongue:

Currently the jme side use Unshaded.j3md or Ligthing.j3md for material, and the Blender side will not allow you to tweak every parameters. Also I didn’t create .j3m.

So you still need the jME SDK.

1 Like

A Quick update :

  • I’m working on animation (slow progress), I’m not happy with the current work (I’ll change it later)
  • today I rewrote all the java8 code of pgex and remote editor (the jme side) in Xtend, so it generates java 1.7 code and I continue to have syntax sugar on lambda,… => pgex and animation stuff will be usable with java 1.7 (android,…). But the javaFX stuff will only run on jvm 1.8.

Imgur

1 Like

Demo: basic animation of cube between 2 keyframes

Notes :

  • keyframe interpolation supported (shown in the video) : constant, linear, bezier curve
  • no baking, no sampling (neither on blender side nor jme side)
  • blender NLA is used to define animation
    • content of the animation
    • to what (object => spatial) animation is attached
4 Likes

Some progress on animation, but I revert support of bezier curve and the exporter sample transform (per frame) :-(, because it’s easier for third party like jME to import. Maybe I’ll retry to export curve later.

But also some issues, bone’s influence is not correct, like animation SideKick or Taunt (any suggestion with soo many info :stuck_out_tongue: )

http://i.imgur.com/WQVJhcB.png

2 Likes

Maybe try to apply the model & armature transform in Blender, see if it improves anything.