Solved

Using an OpenGL 3D engine to render to a pbuffer

Posted on 2004-08-12
6
4,829 Views
Last Modified: 2013-12-06
Is there anyway i can use an OpenGL 3D to render to a pbuffer?  Is it possible for me to use this engine to animate a 3D model, and then set the world matrix from my code?  If so, how do i get this engine?
0
Comment
Question by:davidastle
  • 3
  • 2
6 Comments
 
LVL 17

Expert Comment

by:davebytes
ID: 11794363
Off-screen Rendering Using Pixel Buffers sample at:
http://www.codesampler.com/oglsrc.htm

about halfway down the page.

You can also certainly use any of the OpenGL based opensource game engines to do things like this.  I can't tell from your question what experience you have with opengl and what you are trying to do, but that link is one decent starting example.

That page has a lot of good sample code for OpenGL us.  The other good tutorial site is:
nehe.gamedev.net

-d
0
 
LVL 2

Author Comment

by:davidastle
ID: 11794536
Basically my problem is that I have an artist who needs to export something from Maya, and I need to be able to run the animation in OpenGL... on a pbuffer.  This is a nightmarish task, and I want to get it done with as little pain as possible.
One of the possibilities that came up is to try to use a 3RD party 3D engine to render the animations on a black background to the pbuffer.  If this works, we may be able to cut out a lot of code.
Would this work?  Could i use a 3RD party 3D engine to do this and still control the OpenGL camera position / model position at any time?
0
 
LVL 17

Expert Comment

by:davebytes
ID: 11794685
Wow.  Yes, that IS a nightmarish task!  From scratch, that's no small job you've got ahead of you...

Yes.  Check out any of the open-source projects on sourceforge.net for Maya support... Plus google is your friend.  You want a free codebase that provides the Maya export/import connection, with animation support.  I don't know of anything off the top of my head.  You might find that some of the cheaper commercial engines (like garagegames.com Torque engine, etc.) might have the needed Maya support, but that's a big piece.

-d
0
 
LVL 2

Author Comment

by:davidastle
ID: 11794852
I've already done the code for rendering non animated Maya objects (obj files), and i have MD3 animations working.  Would it be easier to go for the engine, change my code to load a new animation format (i can reeuse a lot of the MD3 SLERP animation code), make a maya plugin that exports to our own format, or change the MD3 file format to suite my needs (there is a plugin for maya that supposedly exports to MD3, although i havent gotten it to work)?  I dont want to use MD3 since it doesnt really support skeletal animation.  People say that it does, but i ran some tests, and the only joints are the entire lower half of the, the torso, the gun, and the head.  It is a nightmare to try to add support for more joints; i would have to change the file format.
0
 
LVL 17

Accepted Solution

by:
davebytes earned 500 total points
ID: 11827804
If you want to really own the code, you probably want to either adopt a different 'open' object/animation format, or just bite the bullet and write your own format/exporter/importer.  Trying to extend MD3 seems a fruitless endeavor.  Using an existing engine would certainly be a fine approach if you found something that meets your needs for free -- not that many solutions out ther for certain.

Do you want to own the code?  If so, your answer is pretty much there for you: write your own exporter & format to meet your own needs -- or find an alternate existing format/exporter you can adapt (less likely...).

-d
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

As game developers, we quickly learn that Artificial Intelligence (AI) doesn’t need to be so tough.  To reference Space Ghost: “Moltar, I have a giant brain that is able to reduce any complex machine into a simple yes or no answer. (http://www.youtu…
Recently, in one of the tech-blogs I usually read, I saw a post about the best-selling video games through history. The first place in the list is for the classic, extremely addictive Tetris. Well, a long time ago, in a galaxy far far away, I was…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now