leaf

A place for users of OGRE to discuss ideas and experiences of utilitising OGRE in their games / demos / applications.
Post Reply
lucky
Gnoblar
Posts: 2
Joined: Tue Apr 07, 2009 3:31 pm

leaf

Post by lucky »

How to make the leaves spin in the air?
User avatar
jacmoe
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 20570
Joined: Thu Jan 22, 2004 10:13 am
Location: Denmark
x 179
Contact:

Re: leaf

Post by jacmoe »

Most often people use a shader for that. :wink:
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
User avatar
Virion
Halfling
Posts: 85
Joined: Mon Jul 24, 2006 11:06 am
Location: Malaysia
x 2

Re: leaf

Post by Virion »

jacmoe wrote:Most often people use a shader for that. :wink:
ahh really? i thought it's particle...
User avatar
jacmoe
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 20570
Joined: Thu Jan 22, 2004 10:13 am
Location: Denmark
x 179
Contact:

Re: leaf

Post by jacmoe »

Virion wrote:
jacmoe wrote:Most often people use a shader for that. :wink:
ahh really? i thought it's particle...
Depends on the leafs.
If they're attached to a branch on a tree, then a particle based approach would be an interesting twist..
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
User avatar
nikki
Old One
Posts: 2730
Joined: Sat Sep 17, 2005 10:08 am
Location: San Francisco
x 13
Contact:

Re: leaf

Post by nikki »

lucky wrote:How to make the leaves spin in the air?
You mean you already have leaves, but you want to make 'em spin?
lucky
Gnoblar
Posts: 2
Joined: Tue Apr 07, 2009 3:31 pm

Re: leaf

Post by lucky »

I use billboards to make the leaves spin in the air. but have a problem in that, no matter which billboard type I use...I still get strange results.

I've tried using various combinations of settings with functions BillboardSet::setBillboardType(), sBillboardSet::setCommonDirection() and BillboardSet::::setCommonUpVector(). I always use accurate facing.

The problem is that the movement of billboards as they shift to face the 1 direction is obvious and odd-looking. Using accurate facing mostly eliminates the problem.

HOW it would rotate and "flip" and look like it's floating? Anybody have an ideas for a solution?
User avatar
aguru
Goblin
Posts: 236
Joined: Tue Feb 26, 2008 5:48 pm
x 3

Re: leaf

Post by aguru »

Post Reply