Billboard Clouds

Threads related to Google Summer of Code
User avatar
jacmoe
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 20570
Joined: Thu Jan 22, 2004 10:13 am
Location: Denmark
x 179
Contact:

Post by jacmoe »

Falagard wrote:I know how SpeedTree works, I've spent months with it, and implemented my own unique version similar to it, remember? :-)
Yeah, that's me trying to teach your GrandMother to suck eggs.. Sorry. :)
Thank you for explaining how SpeedTree works. From watching OldBlivion I was able to see it in action. And I don't think it should be a problem when using billboard clouds, because as far as I can see, there's no animating leaves on but up close.
Well, I guess we are waiting for a live demo of it in action. :wink:

<edit>
fronds must be another name for billboard clouds, right?
</edit>
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
Lioric
Google Summer of Code Mentor
Google Summer of Code Mentor
Posts: 295
Joined: Fri Aug 06, 2004 10:25 pm

Post by Lioric »

The texture billboard cloud generation is done using ogre, a render system and render texture, that is why its not important if you render your original tree with shaders or not
User avatar
Falagard
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2060
Joined: Thu Feb 26, 2004 12:11 am
Location: Toronto, Canada
x 3
Contact:

Post by Falagard »

I'm having lots of problems with SpeedTree tree style rendering for various reasons and would prefer to avoid them so this billboard cloud solution is very interesting.

Not to hijack this thread, but I hope these problems point out some of the benefits of using billboard clouds for the leaves:

1. Lower end hardware without vertex shader support - means you have to create two different versions of the same tree if you want to support older hardware.

2. Lighting quads that face the camera is a problem, since they are facing the camera the lighting is wrong.

3. Shadows cast from quads that face the camera is a problem, especially since my current implementation isn't done using a custom movable object factory and only works with a single camera, meaning the quads are oriented towards one camera each frame and don't work with any number of cameras that might render that tree from different directions. Can fix but takes work.

Billboard clouds won't have some of these problems though lighting will still be a bit of an issue.

Clay
User avatar
jacmoe
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 20570
Joined: Thu Jan 22, 2004 10:13 am
Location: Denmark
x 179
Contact:

Post by jacmoe »

@Lioric:
http://www.vrvis.at/vr/billboardclouds/ wrote:We use the simplified models as static levels-of-detail in the medium to far field.
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
User avatar
Falagard
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2060
Joined: Thu Feb 26, 2004 12:11 am
Location: Toronto, Canada
x 3
Contact:

Post by Falagard »

The texture billboard cloud generation is done using ogre, a render system and render texture, that is why its not important if you render your original tree with shaders or not
Thanks for the answer, that clears things up a lot. What if the extents of the billboard cloud are calculated by going through all the verts in the original mesh and finding min and max values of the vertex positions, but I'm positioning the verts in my shader and the positions in the actual vertex data of the mesh is not the final position that is rendered on screen? :-)
User avatar
Falagard
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2060
Joined: Thu Feb 26, 2004 12:11 am
Location: Toronto, Canada
x 3
Contact:

Post by Falagard »

We use the simplified models as static levels-of-detail in the medium to far field.
Ah crap that means that I was wrong about seeing billboard layers for the trunk when I freeze framed it - it must have been really low lod trunk mesh then.

*edit* although I just watched the second video and I swear you can see the cross sectioned tree trunk.
Lioric
Google Summer of Code Mentor
Google Summer of Code Mentor
Posts: 295
Joined: Fri Aug 06, 2004 10:25 pm

Post by Lioric »

Probably when they say "we use simplified models as lods" they refer to billboard clouds with different error threshold to produce the level of detail model

I dont know the exact method they might be using in that video, but the proposed algorithm suggests using the error threshold and the texture resolution to produce the lods

The trunk is created using a "Card Board Plane", so what you have watched in the video is probably correct, although i dont see a reason why you cant use the real geometry for the trunk if you want and dont generate the card boar plane, with little modifications
User avatar
Falagard
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2060
Joined: Thu Feb 26, 2004 12:11 am
Location: Toronto, Canada
x 3
Contact:

Post by Falagard »

I must have been tired when I posted these. I re-read the page and he's definitely just saying that they generated simplified models using billboard clouds and use them as levels of detail for distant trees, which implies that you wouldn't use them for near viewing.

He doesn't say that he's using full meshes for near viewing in the video demo, and the video shows that he's not.
User avatar
SuprChikn
Bugbear
Posts: 863
Joined: Tue Apr 19, 2005 6:10 am
Location: Melbourne, Aus
Contact:

Post by SuprChikn »

jacmoe wrote:fronds must be another name for billboard clouds, right?
frond
n.
  1. The leaf of a fern.
  2. A large compound leaf of a palm.
  3. A leaflike thallus, as of a seaweed or lichen.
;)
User avatar
Falagard
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2060
Joined: Thu Feb 26, 2004 12:11 am
Location: Toronto, Canada
x 3
Contact:

Post by Falagard »

fronds must be another name for billboard clouds, right?
Not at all. As SuprChickn stated, fronds in SpeedTree are used for Palm tree type leaves that don't face the camera, for ferns, etc. but also used for fake branch geometry. They don't do dozens of cross sectioned quads for a fronds, it's usually just a few polys.

In my tutorial on how to create trees for GOOF (which as you might know, I've pulled trees out of GOOF so far because of the aforementioned problems) take a look at this picture:

http://www.larabie.net/ogre/MaxScreenshot.jpg

then this picture:

http://www.larabie.net/ogre/MaxScreenshot2.jpg

Some of the branches are full geometry, and others are the fins, or as SpeedTree calls fronds.
User avatar
jacmoe
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 20570
Joined: Thu Jan 22, 2004 10:13 am
Location: Denmark
x 179
Contact:

Post by jacmoe »

Great!
Can't wait to see this billboard clouds business in real-time! :)
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
Joshua
Halfling
Posts: 90
Joined: Thu Dec 15, 2005 7:46 pm

Post by Joshua »

http://graphics.cs.brown.edu/games/Hybr ... hybrid.pdf

Not the most helpful of whitepapers (just an abstract) but it does have some nice screens of mesh trunk + bbc leaves.
swx
Google Summer of Code Student
Google Summer of Code Student
Posts: 31
Joined: Sun May 21, 2006 4:03 am
Location: Sweden
Contact:

Post by swx »

I'm just gonna post a small progress report. I'm currently working on implementing the more complex plane selector. There are a lot of things needed for it to work properly, and it's very easy to make some silly error that costs several hours of debugging, but I'll hopefully have it working before the end of the week. Then I need to optimize it, add some different plane modifiers and clean up the code. I'll also add generation of heightmaps for the billboards so that more complex bumpmapping techniques can be used :)
User avatar
syedhs
Silver Sponsor
Silver Sponsor
Posts: 2703
Joined: Mon Aug 29, 2005 3:24 pm
Location: Kuala Lumpur, Malaysia
x 51

Post by syedhs »

Sounds good.. :)
swx
Google Summer of Code Student
Google Summer of Code Student
Posts: 31
Joined: Sun May 21, 2006 4:03 am
Location: Sweden
Contact:

Post by swx »

An update: The billboard cloud generator is basically complete, there's mostly more optimization thats needs to be done, but the generator should work now. Any comments on the interface would be appreciated. I might add so that it can work with existing Ogre roots instead of creating its own if people want it, but since the generation is so time consuming, so I dont really see how it could be integrated into other tools in some good way, so perhaps its best to use it as a stand along command line tool?

I'm thinking about adding support for tree models that have their leaves assigned to various stems in the tree, probably using some sort of xml format. This would allow the creation of billboard clouds that could be used in combination with tree animation. But this will have to be something I do after the summer of code is completed. But since I'll probably use this tool myself, I'll continue updating it even if I dont get money for it ;)
User avatar
Falagard
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 2060
Joined: Thu Feb 26, 2004 12:11 am
Location: Toronto, Canada
x 3
Contact:

Post by Falagard »

Congrats! Sorry, is this available in Ogreaddons or something?

Command line tool sounds fine.
swx
Google Summer of Code Student
Google Summer of Code Student
Posts: 31
Joined: Sun May 21, 2006 4:03 am
Location: Sweden
Contact:

Post by swx »

ogreaddons/billboardclouds in the "ogrenew" branch.
User avatar
bibiteinfo
Gremlin
Posts: 197
Joined: Wed Apr 12, 2006 2:48 pm
Location: Montreal, Canada

Post by bibiteinfo »

swx wrote:ogreaddons/billboardclouds in the "ogrenew" branch.
I think you made a little mistake, it's in the "ogreaddons" branch
swx
Google Summer of Code Student
Google Summer of Code Student
Posts: 31
Joined: Sun May 21, 2006 4:03 am
Location: Sweden
Contact:

Post by swx »

hmm, perhaps... I've just checked it out once, and that was 2+ months ago ;)

Edit: yeah, you're correct, I did a checkout on the ogrenew branch too, so I got it mixed up. So it's "billboardclouds" in the ogreaddons branch :)
User avatar
Assaf Raman
OGRE Team Member
OGRE Team Member
Posts: 3092
Joined: Tue Apr 11, 2006 3:58 pm
Location: TLV, Israel
x 76

progress bar

Post by Assaf Raman »

It would be nice if you can give the process a progress status while the "Billboard Cloud Generator" generates the end result.

Currently you can't estimate if you are going to wait for a day or only for an hour for it to finish.
Watch out for my OGRE related tweets here.
swx
Google Summer of Code Student
Google Summer of Code Student
Posts: 31
Joined: Sun May 21, 2006 4:03 am
Location: Sweden
Contact:

Post by swx »

I've added support for a listener that will be notified of events in the build process.
User avatar
Assaf Raman
OGRE Team Member
OGRE Team Member
Posts: 3092
Joined: Tue Apr 11, 2006 3:58 pm
Location: TLV, Israel
x 76

try this out - a simple tree

Post by Assaf Raman »

I have created a nice tree for you to try out as a good sample.

I have tried to convert it with your project.

No success. :(

I waited for a long time and the program didn't finish its work on the module.

:?: Do I need to use different settings in the project?

The obj file:http://www.upload2.net/page/download/gb ... e.zip.html

This is how it looks:
Image
Watch out for my OGRE related tweets here.
pbergeron
Gnoblar
Posts: 22
Joined: Mon Jun 05, 2006 6:26 pm

Post by pbergeron »

we are interested in evaluating this add-on. can you provide instructions or a help file for its use?
swx
Google Summer of Code Student
Google Summer of Code Student
Posts: 31
Joined: Sun May 21, 2006 4:03 am
Location: Sweden
Contact:

Post by swx »

Assaf Raman: The generator is really slow now since I haven't added the custom memory allocator yet. So expect to wait 15-20min for models like that ;) Anyway, the newest version has working support for listeners, so you're notified when the generator changes phase and when planes are selected, so you can keep track on the number of faces left to simplify.

My wavefront .obj loader doesnt support multiple materials per object, so the textures for that tree wont be correct... I'm gonna try to fix this tomorrow.

I'll try to start working on some kind of help file or tutorial once I've got the .obj files working properly. The parameters to the generator makes a huge difference both in terms of generation speed and in quality of the output model.
Captain Nemo
Greenskin
Posts: 134
Joined: Sun May 02, 2004 5:06 pm
Location: Kassel, Germany
Contact:

Post by Captain Nemo »

Keep up the good work, swx! I am REALLY interested in this project and will try it out soon.
http://www.aridocean.com
The Marine Life Simulation
Post Reply