External 3D Engine

General discussion about the development of the open source Blender

Moderators: jesterKing, stiv

Post Reply
leinad13
Posts: 192
Joined: Wed Oct 16, 2002 5:35 pm

External 3D Engine

Post by leinad13 »

I read a post on the coding guidelines forum just now and found it very inspiring, the post was about creating an external 3D engine that would be compatable with blender the way i sort of understood was that the guy cant remember his nick :? wanted to sort of create Lightwave Setup with blender, like an external 'Layout'. ( I could have got this all wrong).

Anyway his idea was to create this and have predefined effects such as particles, physics and a game engine.

Basically what im asking for is volunteers, what im planning to do is take this a step further and create a brand new UI for creating OpenGL games. I dont plan on re-writing the Blender Game engine, i plan on doing something that is different. I recently tried to write some games and things using bare bones C++ and OpenGL. I managed to initialise some things, create a cubes, light it etc. Anyway it took me weeks to get anything done because i had to reference the OpenGL documention for every function because they are so abstractly named. (Nowhere near as bad as DirectX tho). Anyway what i want to do is create a User Interface for creating Standalone 2D and 3D games. It would look like the Blender UI, because i think that this setup is great and would easily take Blender Meshes and use them to create games.

To most of you this probably sounds stupid, and kind of nothing to do with blender, but these being the forums where i live i thought id give it a shot to see if anyone would be interested in helping me. Also you would need to know a bit of C++ code, but if you dont and just want to help then im sure we can think of something. Please dont e-mail me yet as unless ur on my conacts ill probably accidently delete your mail. Just post replies on here or leave me a private message on here.
-------------
Over to you boffins

L!13

blackie
Posts: 0
Joined: Mon Apr 28, 2003 5:15 pm

Post by blackie »

hi all,

i've read some of the posts regarding the game engine of blender and now i want to give some commentst, too.

first of all i think it is a good idea to write a game engine with blender support.
i used blender several years ago to model some simple figures and animate a bit.
but soon i turned on the programming side.
in the last 10 month i started developing a 3d game engine, nothing special, but just for me.
i included simple geometry loading from a text file and soon was mad about this text file crap.
so i travelled around the internet searching for a good 3d editor which was useful for creating levels, easy to use or at least easy to learn and then powerful to use and - of course - free or better: OpenSource

there is a big variety of ediors out there but nothing was really good.
finally i found ac3d, it is not free but very easy and you grab a demo on the site.
i wrote a converter for their file format to the file format my engine uses (binary).
but last week, i found that i couldnt use ac3d that well. it is good for editing SIMPLE figures but not more.

i remembered blender and took a look at it again ( after so many years :wink: )

now, that it was open source i searched for the code that writes the blen files and the exporters for the exotic file types (dxf, vrml .. ) ( the file is called exotic.c ).

it seems that it is really possible to write an exporter for blender for my engine file format, so i decided to write one. thats what im doing in these days :P

so, if there are now other people who like to do something similar, that is writing a game engine that is made for blender used as the editor, i really want to contribute.

i already got some experience with some simple rendering mechanisms, but we have to discuss details later.

and of course, i program in c and c++ :shock:

so if there really are serious attempts on doing something similar to this, im with you !

blackie

Money_YaY!
Posts: 442
Joined: Wed Oct 23, 2002 2:47 pm

Post by Money_YaY! »

count me in ^v^

blackie
Posts: 0
Joined: Mon Apr 28, 2003 5:15 pm

Post by blackie »

Money_YaY! wrote:count me in ^v^
sorry to bore you ...

leinad13
Posts: 192
Joined: Wed Oct 16, 2002 5:35 pm

Great

Post by leinad13 »

Great to that you are interested, with your game engine, did u write it using just C and C++ with the OpenGL libaries. And what OS did you work in. Before anyone asks im going to be working in XP but if we just use pure C or C++ and the OpenGL libaries it should work fine on 98. Once i have got a few things working in Windows i will try and organise a Linux port. Im goin to go back to some stuff i have writen in the past and see what i have got.

It would be cool if you would elaborate on what you did a little more.

Ta
-------------
Over to you boffins

L!13

Money_YaY!
Posts: 442
Joined: Wed Oct 23, 2002 2:47 pm

Post by Money_YaY! »

blackie wrote:
Money_YaY! wrote:count me in ^v^
sorry to bore you ...
Wha ? What did I do now ? Count me out. :evil:

Devas73
Posts: 26
Joined: Wed Oct 16, 2002 12:21 am

Post by Devas73 »

Hello,
just wanted to share with you my experience in using blender for level and object creations in an external game engine (Plib).
I made a stunt car racing game which uses PLib and ODE, all modeling made in Blender (it's alpha, just to show what can be done - when I'll have time I plan to fix some problems).
Look here: http://members.xoom.virgilio.it/Devas
Sorry, there's no source code yet, just a binary for win32 to download.

It uses ac3d format (exported using a python script, see the credits in the web page).
PLib reads also many other formats and probably has more features now (it's a bit of time I don't check its status).
It may also be nice to find a way to interface Blender and Cal3d (an open source system for skeletal animation in real time).

blackie
Posts: 0
Joined: Mon Apr 28, 2003 5:15 pm

Post by blackie »

Money_YaY! wrote:
blackie wrote:
Money_YaY! wrote:count me in ^v^
sorry to bore you ...
Wha ? What did I do now ? Count me out. :evil:

uaaahhh, sorry i mixed up some of my comments, this was definitly wrong !

Sorry ! :oops:

blackie

blackie
Posts: 0
Joined: Mon Apr 28, 2003 5:15 pm

Re: Great

Post by blackie »

leinad13 wrote:Great to that you are interested, with your game engine, did u write it using just C and C++ with the OpenGL libaries. And what OS did you work in. Before anyone asks im going to be working in XP but if we just use pure C or C++ and the OpenGL libaries it should work fine on 98. Once i have got a few things working in Windows i will try and organise a Linux port. Im goin to go back to some stuff i have writen in the past and see what i have got.

It would be cool if you would elaborate on what you did a little more.

Ta
ok here some details:

first of all i use linux, not only for programming but also as my main operating system. so i did all development and testing only with linux so far.
but i tried to use the ansi norm as far as possible so it should be fairly portable.
for the window management i used SDL and glut ( two different ports ).

the thing is that i got some experience with this stuff, so maybe i can contribute to the project.

blackie

leinad13
Posts: 192
Joined: Wed Oct 16, 2002 5:35 pm

Good

Post by leinad13 »

Blackie your conribution would be great have a look also the topic in the Coding Guidelines forum which is where this all started. The first thing im interested in getting to know the programming side of a user interface, im not sure about how blender does this at all, so maybe you could enlighten me a bit. What i think we should do first is find a Cross Compatable UI, thats easy to use and can run on as many OS's as possible. I might only speak for myself when saying i only use Windows and Linux and so i dont think i would be able to compile anything Mac or any other OS. We might just want to start off with just Windows and Linux, and then when we have found someone with a wider knowledge of other OS's we can try and port.

I have set an e-mail address dedicated to this project becuase my e-mail address gets too much junk and so some times i accidently delete important e-mails. The address is:

blen_3d_engine@hotmail.com

Please if you feel the need to use that address thats fine, but for now i would prefer to use these forums.
-------------
Over to you boffins

L!13

blackie
Posts: 0
Joined: Mon Apr 28, 2003 5:15 pm

Post by blackie »

hi !

you are definetly right, portability is very important, not ot say it is the power of the OpenSource Software.

so we should make use of opensource libraries or tools.

an example for the ui would be freetype for font rendering ...

i dont know the exact ui functions of blender but maybe i'll take a look a the code if a have the time !

blackie

Curador3
Posts: 0
Joined: Sat Apr 19, 2003 6:57 pm
Location: United Kingdom, (moving to USA soon hopefully)

Nice to See we have some more contributors :D

Post by Curador3 »

leinad13, a lot of people don't seem to remember this name :lol: I don't even want to begin to start explaining where it came from lol.
Its good to see that you've managed to get some contributors to the project, if some of you haven't already looked.. I've posted an ad here describing some of the features I hope to be implemented into the engine:
http://www.blender.org/modules.php?op=m ... ls@aol.com

Curador3
Posts: 0
Joined: Sat Apr 19, 2003 6:57 pm
Location: United Kingdom, (moving to USA soon hopefully)

Terrain Possibilities...

Post by Curador3 »

Today I was looking at the lengthy possibilities of creating a terrain in the engine. I've been looking at an engine called GreatEngine (its not really an engine, just a level developed in OpenGL, nothing is custom), it uses Bitmap's which are grayscale and creates a terrain out of them, then maps a texture onto it with a detail map. Since it created the terrain out of a grayscale picture, instead of using algorithms to create terrains under certain values, it would be a good idea to create a grayscale material editor inside the engine, where a user can build his/her own grayscale map, allowing almost any terrain to be built, I've never heard or seen this been done before, but its something I really want to go for, it shouldn't be hard to implement, because it will only need to deal with a few colours.

About the Ocean Waves... I've decided to make it more powerful, instead of just using a texture map for the reflection, I could allow options for an environment map, this would be highly powerful. For Object physics there could be a physics engine which allow you to modify positions of a character on a terrain, e.g. height above terrain etc. (the movement would be part of the library).

On top of all of this, Ocean waves would be no good for someone wanting to implement rivers into a scene, so... I would go about using the sine wave to create rivers, which would allow texture mapping also so violent water can be implemented (white water), the sine wave would check for terrain collision, therefore turning when the river is a meander, according to the terrain shape.

Later on, I hope to make the world a sphere meaning, this would mean that the world would never end, its a good way of actually creating a huge world, without actually drawing a huge world :wink:

The world rendering engine will use Frustum Culling and Octrees, for optimization, this would make sure the frame rate stays up top.

I was thinking about implementing RenderMan as the render engine, but I'm not sure how possible that would be, I need to look up some information about it since I haven't used the Pixar RenderMan Algorithm before.

Soft Shadows will be a part of the world, e.g. when an object gets in the way the lens flare, behind it will be a antialiased shadow.

I've also been looking at the possibilities of implementing L-Systems (Plant Simulations) into the actual object editor, this would allow you to animate the growth or even the wind against the actual plant.

The ocean waves will actually be visible in 3D unlike in many applications and engines... the waves are simulated in graphics, but when you sink to the level directly above the surface of the water, the water is animated flat!

It would be good if we all could create a Particle Engine as part of the editor.

Of course none of this will be using DirectX, we'll be relying on OpenGL/Mesa3D and other Open Source libraries, the reason for not using DirectX is simple:
-its a Windows only SDK :evil:

If anyone wants to talk to me about any of this, or would like to talk to me about participating, my MSN Messenger Address is as follows: curador3_________________________@hotmail.com

If you want to contact leinard13 contact him through the email he posted earlier on in this topic.

Of course, we both can be contacted through the forum.

And I want to say thanks to those who are willing to help towards the project, that way we can get it up sooner and we can make a more user-friendly and powerful engine :D

Panther
Posts: 0
Joined: Tue Mar 04, 2003 7:55 pm

Post by Panther »

Hi Curador3,

Although I'm not a coder, the following links may be of use to you...


Physics Engine...

ODE - http://opende.sourceforge.net


Terrain Generator...

Demeter - http://www.terrainengine.com


Network System...

Verse - http://www.quelsolaar.com/technology/verse.html


Other 'Good' Game Engines...

Crystal Space - http://crystal.sourceforge.net
NeoEngine - http://neoengine.sourceforge.net
Faked Reality - http://fakedreality.sourceforge.net


Enjoy !!! :wink:

Curador3
Posts: 0
Joined: Sat Apr 19, 2003 6:57 pm
Location: United Kingdom, (moving to USA soon hopefully)

External Engine..

Post by Curador3 »

Hey Panther,

Thanks for those links, most of them I've already seen, but a couple of the other 3d engines I haven't seen or heard of before, including the network example, so I'll go check them out!

I looked at the Demeter library a while back, it was and wasn't really the type of engine I wanted to use for the terrain. Last night and today I found two engines with terrain generators that we of great use to me, both I found in the download section of NeHe.

-TerrainEditor
-GreatEngine

The TerrainEditor although windows based, has an incredibly portable and tidy layout for the codes, a layout that inspired me! The only thing that was a bit messy was the fact that the code files were all in one folder. But the VC++ .dsw had categorised topics and algorithms, which was good and its really easy to understand. Great Engine has the power and its code is pretty clean, but although it can't be helped, theres too much code that doesn't make enough sense, basically it links to too many header files which need to be followed up, some link to python scripts and also registry addresses making it even more awkward to get the full flow of the code.
TerrainEditor has exactly the same technique of loading a terrain, it uses a grayscale image :D So I'm going to use the algorithm from TerrainEngine and normal/Detail Texturing for the terrain in GreatEngine, I'm going to optimise the code also using Frustum culling, and Octree rendering.

Thanks for the info, anything new you can find, let us know! we need all the help we can get.

Leinad13, I thought it would be best if we created the code in MSVC++ 6, I'll be using EE, then layout all the code for the project, then later on, like Blender, add makefiles which support cygwin & gcc, including MingW. What do you think?

P.S. Have you been able to make much of the Interface of Blender? :)

-Sam White
Email: YahooSpecials@aol.com

Post Reply