The MASM Forum

General => The Campus => Topic started by: Farabi on February 21, 2014, 03:17:56 PM

Title: OpenGL Framework
Post by: Farabi on February 21, 2014, 03:17:56 PM
Here is my OpenGL framework. I've tried to make it as simple as I can. There is lack of Physic engine, but for now its just for the rendering system.

http://farabidatacenter.url.ph/MainSystem/MainData/fGE2.zip

-Motion Capture
-Dynamic shadowing system
-Collision Detect
-Simple 3D parser format
Title: Re: OpenGL Framework
Post by: K_F on February 22, 2014, 09:55:05 AM
Thanks dude.. I'll be looking into this, as I think I'll be using something similar
:t
Title: Re: OpenGL Framework
Post by: Farabi on February 22, 2014, 12:46:12 PM
Quote from: K_F on February 22, 2014, 09:55:05 AM
Thanks dude.. I'll be looking into this, as I think I'll be using something similar
:t

Thanks, I hope it will be usefull for somebody. Ask me anything if you found difficulty.
Title: Re: OpenGL Framework
Post by: Farabi on February 25, 2014, 01:29:57 PM
here is how to use the motion capture system http://farabidatacenter.url.ph/MainSystem/MainData/fGE2MotionCaptureDemoSource.zip if you want to change something or put something for the game engine like load a models or any resource put it on the MainSection.inc that is the main code for the framework to work to avoid confusion. I recomended using RadAsm version 2 to open this since it will automatically point to MainSection.inc for you to edit the code for your need.


@JJ:
Maybe you interested to put this on your MASMBasic package as a basic function for 3D game funcionality. I see MASMBasic had a bright future. It was superb package.


@All
have a look at this, I took euphoria graphic system as my main system for the 3D rendering engine using HTML5, on my old zyrex it was very slow but on my vPro centrino it only took 0% CPU usage even without any GPU Driver http://farabidatacenter.url.ph/MainSystem/MainData/Library/MainSystemGraphicLibrary/test0.html
Title: Re: OpenGL Framework
Post by: dedndave on February 25, 2014, 04:39:50 PM
 :t

wish i had more time to play with them
a little busy at the moment, but when i have some time.....
Title: Re: OpenGL Framework
Post by: Farabi on April 21, 2014, 03:06:44 PM
Here is how to use the Collision detect system. http://farabidatacenter.url.ph/MainSystem/MainData/fGE22.zip
I dont know but Im having fun coded this. I never thought math is so awesome. From a spesific formula you can determine wheter a triangle is in front of another one or behind it, or is a point inside a triangle or not, everything in the math language. The next step is building the physic engine.
Title: Re: OpenGL Framework
Post by: Farabi on April 25, 2014, 03:27:48 PM
Here is how to load the lightwave OBJ models https://drive.google.com/file/d/0B4e67L-fbWVQY2lRTTVISVJrNWs/edit?usp=sharing
I dont care about speed anymore since my creation can be speeded up or slowed down by microsoft, I guess my next objective is making everything done. Next step is riging it and integrate it with the motion capture.

(https://fbcdn-sphotos-d-a.akamaihd.net/hphotos-ak-prn1/t1.0-9/p526x296/10247427_10202363598031381_3422553330622775516_n.jpg)

[edit]
Sorry there is some sort of mistake. Please redownload if you please. There is bug on the obj loader that only can be seen on the debuger.
Title: Re: OpenGL Framework
Post by: Gunther on April 25, 2014, 10:33:05 PM
Looks cool Farabi.  :t

Gunther
Title: Re: OpenGL Framework
Post by: RuiLoureiro on April 26, 2014, 06:09:34 AM
Hi
Seems very nice, Farabi  :t
Title: Re: OpenGL Framework
Post by: Farabi on April 26, 2014, 10:47:14 AM
Hi thanks. I was wondering if I can apply a physic and make the models to stand, and then put some AI for the models to move and avoiding things. But I guess it will take a long time.
Title: Re: OpenGL Framework
Post by: Farabi on May 07, 2014, 08:49:42 AM
https://drive.google.com/file/d/0B4e67L-fbWVQSks3TGt6dmZscTA/edit?usp=sharing

Here is the walking robot demo, I succesfully merge the model and the motion capture. The problem is it is not reallly fast, first of all, the model contain 200,000 of triangles and it makes the loading time so slow, about 30 seconds, and seconds, the memory usage is upto 1 GBytes. So it is ineficient. I did not included the source since it is messy, and Im still waiting until I had a good concept to make the code neat.

(http://farabidatacenter.url.ph/MainSystem/MainData/GWalk.jpg)
Title: Re: OpenGL Framework
Post by: Farabi on May 16, 2014, 03:26:41 AM
Here is the source code. I've figured out how to make the loading faster but there is a slight calculation error but not on this source code. This source code is the slow version. https://drive.google.com/file/d/0B4e67L-fbWVQUmZtNFBiRjJ6cTg/edit?usp=sharing
The method I used on the fast version is using GPU calculation instead of using CPU calculation, but there is a slight mistake on the GPU calculation since I cant have the rotated coordinate because the pivot is changing on each rotation.