Archived

This topic is now archived and is closed to further replies.

dachande

PortaLib animation example

Recommended Posts

I recently tried using portalib, and after compiling the modeling example, I managed to get a model to start loading but I always get a "couldnt load textures" error. Help!! This seems like a great library, so thanks to the creator, however I''m not getting very far when I can''t use it! Thanks, Dachande

Share this post


Link to post
Share on other sites
thanks, I do have one question....

Are there any tutorials for ProtaLib out there? The examples are good but I can see a whole lot more potential in that library just ready to be unlocked A nice guide to point us in the right direction would be wonderful.

And a second question:
How can you select which animation you wish to play? The example just plays a default animation as your well aware.. I would love to have a few examples to show me what the animating can really do

Thanks for your time,

Dachande

Share this post


Link to post
Share on other sites
hmm okay, and ANOTHER thing...

How does a person load in a PNG image as a texture, ready to paste on some polygons? Using portaLib/libPng that is!

Just a quick tutorial giving brief explanations of the different sections of PortaLib, would be lovely =)

Thanks,

Dachande

Share this post


Link to post
Share on other sites
Ah, if I had the time...
I used to have more tutorials but I thoguht they were a bit too simple. For example, the Fractal Terrain shows how to use the texture mapping (craete a new texture object, then call ->bind(); before using it)

I''m not sure what you are looking for in terms of animating... Milkshape only provides one animation per file, that''s the reason for it. I''m currently looking at extending this, but soooo busy... (sorry!)

Thanks for your feedback - very much appreciated and taken into account...


~~~
Cheers!
Brett Porter
PortaLib3D : A portable 3D game/demo libary for OpenGL

Share this post


Link to post
Share on other sites
Oh crap, sorry, I screwed up again!!!

Last time I used MilkShape it was for Genesis3d, wich had multiple animations per file... Doh, my mistake.

I guess, I'll have to see if theres a function to start the anim at x frame and end at y frame, and just cram lots of anims in one big line

I've tried adding PNG textures to the model viewer example... I created a load of quads to stick them on to... then called something like:

private:
//TEXTURES
OpenGLTexture2D *Background[1];

then in the constructor:
Background[0] = new OpenGLTexture2D( "data/heart.png", Texture2D:NG, false );

Then after glbegin(GL_QUADS).. :
Background[0]->bind();

but the program just quits I think it might be generateTExture that screws up as when I call it manually, a message pops up telling me a texture name could not be made, or something similar..

Do you know what I'm doing wrong ?

But again, congrats on a fine piece of programming, it's well put together, and is a wonderful learning tool at the least, to discover how to acheive animation and what not.

g'bye,

Dachande

Edited by - dachande on August 9, 2001 11:59:37 AM

Share this post


Link to post
Share on other sites
Are you executing in a place where data/heart.png makes sense?
Often you will beuild to a Debug subdirectory, so data/heart.png is in the wrong place.
In Project -> Settings, change the run directory on the debug tab (assuming VC++).

also, you need to bind outside of glBegin/glEnd.

HTH!

~~~
Cheers!
Brett Porter
PortaLib3D : A portable 3D game/demo libary for OpenGL

Share this post


Link to post
Share on other sites