OpenGL 3 port

Get technical support about the C++ source code and about Lua scripts for maps, entities, GUIs, the console, materials, etc. Also covered are the Cafu libraries and APIs, as well as compiling, linking, and the build system.
Post Reply
sycoso
Posts: 13
Joined: 2012-09-18, 21:23

OpenGL 3 port

Post by sycoso » 2012-09-25, 22:51

Hello Carsten,

I wanted to learn OpenGL 3 and thought of trying to implement it into Cafu. Don't expect anything, it's more like me learning how to use OpenGL, but I wanted to ask if you already started implementing it so I don't rewrite existing code.


sycoso
User avatar
Carsten
Site Admin
Posts: 2160
Joined: 2004-08-19, 13:46
Location: Germany
Contact:

Re: OpenGL 3 port

Post by Carsten » 2012-09-25, 23:16

Hi sycoso,
sycoso wrote:I wanted to learn OpenGL 3 and thought of trying to implement it into Cafu. Don't expect anything, it's more like me learning how to use OpenGL, but I wanted to ask if you already started implementing it so I don't rewrite existing code.
Great to hear this!
Previous attempts unfortunately never produced any practically significant code.

A related ticket is http://trac.cafu.de/ticket/17
A related thread is http://www.cafu.de/forum/viewtopic.php?f=8&t=933

(Unfortunately, Thomas never sent me the last state of his code.)
Best regards,
Carsten
HWGuy
Posts: 95
Joined: 2011-05-31, 07:37

Re: OpenGL 3 port

Post by HWGuy » 2012-10-08, 00:51

Thomas has stopped working on OpenGL 3 for Cafu(Cafu needs some reworking for it, handling geometry), he's currently researching new rendering methods, getting OpenGL and OpenCL to do realtime raytracing and raster mixed together.
If successful he'll have sample code for Cafu which you can integrate, if not, well, his voxel raytracer is progressing well and it'll be a portable lib.
I think he still has his simple implementation of OGL3 sitting around, it doesn't have any big advantages(since Cafu needs some reworking for OGL3+), incomplete.

I'm actually working with Go golang.org now, using Cafu and your paper and some other papers as educational material for making a partial engine like Cafu using Gocos gocos2d.org(site not up, still internal alpha only) as the kit.

I'm no good at networking and prediction though... one day I may try merging Cafu with a Go project, dumping Lua, replacing renderer with OGL3(Gocos), GUI system would be using Gocos2D.
So a cleaned up stripped Cafu with Go instead of Lua.
User avatar
Carsten
Site Admin
Posts: 2160
Joined: 2004-08-19, 13:46
Location: Germany
Contact:

Re: OpenGL 3 port

Post by Carsten » 2012-10-08, 10:54

Regarding voxel raytracing, is this something like in http://s08.idav.ucdavis.edu/olick-curre ... -games.pdf, starting on page 97?
Best regards,
Carsten
HWGuy
Posts: 95
Joined: 2011-05-31, 07:37

Re: OpenGL 3 port

Post by HWGuy » 2012-10-08, 19:42

Well when it comes to using an octree for optimization, yes, but beyond that it's rather conventional raytracing(highly optimized) for lighting only and raster to draw the lit scene.

Instead of a regular raytracer which casts from the screen and looks for lights(and of there's something in the way if there's a shadow), the lights cast rays which hit the geometry to light it.
A stationary light and stationary geometry uses no CPU power, if the light is in motion you gotta update all of it's rays, but, if there's an object moving you only have to update the rays being cast towards the thing.
Ambient light is in the octree, areas full of rays brighter than places with few.
Haven't done bounce lighting yet.
This actually works in realtime on a modern $50 graphics card.
sycoso
Posts: 13
Joined: 2012-09-18, 21:23

Re: OpenGL 3 port

Post by sycoso » 2012-10-11, 07:04

Hi,

So I did find the time to read the thread. *yay*

Carsten, may I ask how far you got with implementing UnivMeshT?
User avatar
Carsten
Site Admin
Posts: 2160
Joined: 2004-08-19, 13:46
Location: Germany
Contact:

Re: OpenGL 3 port

Post by Carsten » 2012-10-12, 11:53

sycoso wrote:So I did find the time to read the thread. *yay*

Carsten, may I ask how far you got with implementing UnivMeshT?
Unfortunately, in the light of more pressing concerns at that time, I never completed a working instance of it.

Nevertheless, as mentioned in the former thread, I still think that this can be implemented in small steps, that are each easy to write and easy to review.

No huge, global one-time effort should be required before work can start on an OpenGL 3 renderer, because it should be possible to introduce the new UnivMeshT in parallel to the old code, and to try it out in a small, chosen area of the code, e.g. in the Model Viewer (or elsewhere).


I have re-read most, but honestly not all of the old thread. In any case, don't let that stop you -- I'll be happy to help on any question you have and in any way that I can. :up:
Best regards,
Carsten
sycoso
Posts: 13
Joined: 2012-09-18, 21:23

Re: OpenGL 3 port

Post by sycoso » 2012-10-12, 12:29

Okay, good to know, I'll see what I can do ;-)

And awesome how helpful you always are :up:
Last edited by sycoso on 2012-10-12, 22:22, edited 1 time in total.
sycoso
Posts: 13
Joined: 2012-09-18, 21:23

Re: OpenGL 3 port

Post by sycoso » 2012-10-12, 21:51

Where do I find the Model Viewer? Sorry, but I just can't find it...
User avatar
Carsten
Site Admin
Posts: 2160
Joined: 2004-08-19, 13:46
Location: Germany
Contact:

Re: OpenGL 3 port

Post by Carsten » 2012-10-12, 22:36

The Model Viewer is a part of CaWE. Start the CaWE program, then follow the instructions at http://www.cafu.de/wiki/modeleditor:int ... del_editor

For developing or testing OpenGL 3 code, note that I mentioned the Model Editor just as an example -- other program parts may be suitable as well. :up:
Best regards,
Carsten
sycoso
Posts: 13
Joined: 2012-09-18, 21:23

Re: OpenGL 3 port

Post by sycoso » 2013-07-18, 08:58

Sorry for not keeping you updated, but since I have a full-time job atm I just can't find the time to get into the project. So no port from me, sorry.
User avatar
Carsten
Site Admin
Posts: 2160
Joined: 2004-08-19, 13:46
Location: Germany
Contact:

Re: OpenGL 3 port

Post by Carsten » 2013-07-18, 15:13

sycoso wrote:Sorry for not keeping you updated, but since I have a full-time job atm I just can't find the time to get into the project. So no port from me, sorry.
I'm sorry to hear that, but congrats to your job of course and still thanks for the explicit update! :cheesy:

I'm currently working a couple of hours every day on the new Component Systems as detailed in other threads, and hope to get back to newer renderers as soon as that's done. And of course, I'd be very happy if you joined in again at a later, more convenient time! :up:
Best regards,
Carsten
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests