Editor (First King, tool) UPDATED: 29/07/2008

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Editor (First King, tool) UPDATED: 29/07/2008

Post by christianclavet »

Hi, I'm currently enhancing the IRRlicht model viewer to be of use in my project: "The first king".

I've put this model viewer in my sourceforge site, and the main.cpp as been worked on to have includes now. Each file is classified with their appropriates functions. The original main.cpp file was being hard to manage. (with my modification was more than 1400+ lines)
Here is the current includes file organisation inside the project
(If youre not using DEVC++, this is a good reference to setup the files for your compiler)
Image

Here are the current features:
- Multiples viewmodes: 4 Viewport, Single view: perspective, top, front, side views
- Animation tool for defining and playing animated mesh
- Lighting tools to add shadow volume on the mesh and remove it
- Support multiple meshes loading in a single scene
- selector window to select the mesh and modify them, place them.
- Have a selection tool to select the mesh to animate
- Can move the mesh directly with the mouse in 4 viewport mode
- Can also move, rotate, scale mesh with a numeric panel
- Edition can be done in all views including perspective.
- Configuration file can change the display mode (full screen, windowed, resolution can be set or desktop resolution can be choosen)
Also, the driver can be defined before loading the application there (OpenGL / DirectX / Software -(Burning))

Some details:
- Panning the view in the orthogonal view take place with the left mouse button. Right mouse button in perspective view, rotation is done with left mouse button for perspective view.
- Zooming is done with the mouse wheel. (all views)
Does a Mac have a wheel on it's mouse? Anybody tried to compile on the Mac?

Perspective mode:
- Moving, rotating, and scale are possible in this view now.
In move mode, right mouse button does move in Y axis. Left mouse move in X,Z.
In scale mode, the mousewheel scale the model
In rotate mode, the right mouse button rotate the Z axis. Left mouse move the X,Z

-----------------------------------------------------------------
EDIT: Changes (Sun 2 march, 2008)
- Added a new file selector to the application (filetypes icons + file filters)
- Added the capability to save/load IRRScenes
For the moment saved Scene must be in the application folder
(Relative path problem to fix, Item added are based on the application path)


Here are the current screenshots:The new file selector in action:
Image

Perspective moving, rotating, and scaling using the mouse:
Image

Quad view editing (Right panel can be hidden with TAB key):
Image

Viewing options on models:
Image

This file contain, the source and a binary, dowload from sourceforge:
http://downloads.sourceforge.net/first- ... e=16330840[img]

EDIT: /UPDATE: 29/07/2008/
This current editor will not be continued as it is now. I'm completely rewriting it because my coding style was very bad, separated some components in includes but didnt' created them in classes, so lots of mistakes. A good rewrite is in order, so it will be easier to maintain.

Was able to recompile the source on Microsoft Visual C++ express 2008, and fixed some warning and compiler error so it would work. The source archive now contain a MSVC project. But about nothing else changed.
There is still an issue with paths with the file manager. You can enter the path manually and it should work.

Produced a new binary with MSVC express 2008.
Here is the link to the source: (1.17Mb)
http://www.clavet.org/files/Storage/FKEditor_Source.zip

Here is the link to the binary release: (2.32MB)
http://www.clavet.org/files/Storage/FKEditor_Binary.zip

When a new release of the rewritten application will come up, I'll will create another thread for it. This current editor is still functionnal for Windows and could be useful.
Last edited by christianclavet on Tue Jul 29, 2008 5:54 pm, edited 14 times in total.
Virion
Competition winner
Posts: 2148
Joined: Mon Dec 18, 2006 5:04 am

Post by Virion »

Looks cool. :)
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Post by christianclavet »

Thanks.

I'm working now in the "Animation Control interface":

- Changed a method to get the IAnimatedMesh pointer from the node instead to keeping it after it was being loaded. This will allow me later to load a complete IRR scene, and get the character already placed there.
- Done a refresh on the "Animation Control" window when selecting a mesh. So you can setup multiple mesh and the interface will retrieve immediately the settings of each animated mesh.
Image

Animation Control interface will be more complete in a few days. I'll need to define some animations(working), save them(current) and you can select them by a list of animation names. For MD2 anim, it will retrieve the animations name.

Once that is working better, the other "big" thing i'd like to do inside this is a "Timeline" windows where you can define and place animations, so you can define some animation scripts based on time. (Mostly useful for creating "Cutscenes" in a game.) I'm still thinking about how the GUI for that will look like... Perhaps a Adobe Premiere style timeline...

The functions I will be defining will serve to link to the IRRai code. Theses codes will go back into the engine (First King).

The more I'll advance in the project, the more I will be able to tell.

In short here are the thing I'm planning to implement for animation:
- load IRRScenes
- Export objects (Collada, IRRmesh), save IRRscenes
- Create a selection list from the scene graph instead of the current method. (So will be able to manipulate animated mesh that were placed in IRRedit.)
- Create "Actions" with defined Animation script (Visually in the editor)
EX: Pressing a RUN Action button example will show an interface that you will put the destination point and time to reach it, and select the defined animation that you created previously
- Using theses defined "Action" in a Premiere/After Effect type timeline and place them on a defined order. The interface need to be simple because I'll only use IRRlicht GUI. (Could be a button, that could be move horizontally (X screen coordinate) on the timeline window.
- Will have to save this in XML in a file to retrieve it after. (IRRanim)?
Halifax
Posts: 1424
Joined: Sun Apr 29, 2007 10:40 pm
Location: $9D95

Post by Halifax »

Wow, great job christianclavet, I definitely like the new stuff you added. Keep up the good work!
TheQuestion = 2B || !2B
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Post by christianclavet »

New changes (15 Feb 2008)

Biggest changes:
- Can load a IRRscene for meshes placement
- A selection list is build from the filenames of objects
- Selected objects can be hidden/wireframe and is displayed in the list as color code: (RED=Hidden), (Green=Wireframe).
- Object placement (move, rotate, scale) can be done in all views now (Perspective, top, front, side)
- All viewports functions are put in a single class that is in 2 files(viewports.cpp and viewports.h)
- Used Dark_Kilauea "Editor style Grid SceneNode". in the editor. This is the grid that is used in the viewports.

Future work:
- Working on implementing custom icons with a spritebank to add type icons and states in the list.
- New file requester in work, for having file filters, be easier and faster to load/save. Perhaps check to put pictures preview. Also if spritebank method work. Will put custom icons for different filetypes.
- Will check for already named node before putting a name. (Also check for duplicate names. Selections are based on node names.) Will be easier to work with IRRedit. (Won't rename nodes named in IRRedit)

The first thread is updated with the lastest screenshots.
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

Just downloaded this to check out the skeletal structure of some models and it's very nice Christian! Much more fully featured than the standard irrlicht mesh viewer (obviously the mesh viewer isn't meant to be fully featured but is just an example of how you could start off).

I think it would be cool to make this a standard irrlicht tool, have it linked to on the website or provided in the SDK!

I found a slight bug in it though, not sure if anyone else has noticed but if you go to open up a model and use the mouse wheel to scroll then it zooms the viewport as well as scrolling up and down the list. A fairly easy thing to fix i would think, just have a flag when you open up any gui window that has a scroll bar and don't zoom if there's a window open.
Image Image Image
Yustme
Posts: 107
Joined: Sat Dec 01, 2007 10:50 pm

Post by Yustme »

Hi,

Your modelviewer looks awesome christian!

Thanks for sharing this :wink:
MasterGod
Posts: 2061
Joined: Fri May 25, 2007 8:06 pm
Location: Israel
Contact:

Post by MasterGod »

What an amazing work. Great Job Christian!!
I just want to ask how did you do the reflection thing? I really like it..
Image
Dev State: Abandoned (For now..)
Requirements Analysis Doc: ~87%
UML: ~0.5%
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Post by christianclavet »

Hi! I should put a new release soon with a new file selector replacing the standard Irrlicht one. There could have some delays. My Pc is broken (videoslot broken, have to use the integrated vidéo).

I'm using my iPod touch now to type this thread.

I think I will be able to replace my PC in about 2-3 months. Meanwhile, I'll should start next monday my training at the Ubisoft campus.

The new file selector will have definable filetypes and icons, i've put some time to make it using a new class and includes.
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

Oh so you got the placement with Ubisoft eh? Congratulations!
Image Image Image
iZigoo
Posts: 53
Joined: Fri Feb 23, 2007 1:32 pm

Post by iZigoo »

Hello Chrstian,

this tool is really great !
I just downloaded and tried it. I am excited to see
what features are coming in the next versions.

iZigoo
-------------------------------------------------------
iZigoo - The open 3D internet

iZigoo Homepage
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Post by christianclavet »

Hi, A new version will be released shortly, with a new filerequester.

Does anyone attempted to compile this for the MAC? It would be great that this editor could work on the mac. (Don't have a mac here)
iZigoo
Posts: 53
Joined: Fri Feb 23, 2007 1:32 pm

Post by iZigoo »

Hello Chrstian,

would be great if you set the camera setFarValue very high to about 100000 . Then big models show up in the editor without cutting the end.
I use many big models so it would be useful.

By the way what IDE do you use for your development ?

Markus from iZigoo
-------------------------------------------------------
iZigoo - The open 3D internet

iZigoo Homepage
Halifax
Posts: 1424
Joined: Sun Apr 29, 2007 10:40 pm
Location: $9D95

Post by Halifax »

iZigoo wrote:Hello Chrstian,

would be great if you set the camera setFarValue very high to about 100000 . Then big models show up in the editor without cutting the end.
I use many big models so it would be useful.

By the way what IDE do you use for your development ?

Markus from iZigoo
To answer your question, it is pretty obvious from his post that he is using Dev-C++. Unless he has some ingenious way of getting a skin on MSVC. :lol:

And also, I think it would be better if he just allowed the far and near value to be set dynamically from within the editor.
TheQuestion = 2B || !2B
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Post by christianclavet »

Yes, that's a nice idea. It's will not be implemented now, but I wanted to have a "settings" menu. That will go in that window (settings).

The application can be set fullscreen from the configuration file. (For now, you'll have to edit it, the editor can be set:
- Fullscreen with a specified resolution or use the current desktop resolution
- Use of a specific driver (OpenGl, DirectX9 or Software (Burning))
The interface will be able to save the configuration when I implement this later.

I've just made a "commit" now to the SVN. The editor now have a working file selector that is much more easy to use than the basic IRRlicht one (Filetypes icons + file filters). I fixed some things, but there other issues (If you close the file selector window the application doesnt know it and it block some moving until you open the file selector again and use "cancel" to close the window. Not a major issue, but this need to be fixed. I don't have a response event when closing the windows to release the interface.

David (LostAnimator) is doing an exellent job on the model, and he's just produced some normal maps with the current model. So, I'm trying to implement normal mapping implementation (will try to use the IRRlicht one first, will not be clean, once I have the feature working, I'll put a real interface over this)

Next step for tommorow (Saturday). Try to implement a SAVE IRR Scene feature, and use the file selector to save files (will try to check for existing files and warn before overwriting). If it work, then I do a next release of the files. If you want to check the new fileselector before I release, get it over the SVN.
Post Reply