Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to create billboards for Oblivion SpeedTree tree
12-03-2006, 06:58 AM,
#1
How to create billboards for Oblivion SpeedTree tree
[What is this tutorial about?]

If you enjoy making your own trees with SpeedTreeCad but are annoyed at the CS spurting assertion errors when they're loaded, or stumped on to how to make them work with LOD, you might want to read this tutorial on how to solve those problems.

[What do I need for this tutorial?]

You need:
- SpeedTreeCad (http://www.speedtree.com)
- Paintshop Pro (http://www.jasc.com)
- DXTBmp (freeware; http://www.silgrad.com/wbb2/jgs_db.php?a...6&katid=11)
- Windows calculator

[Thankyou's]

Thankyou to PoHa! and KhadirgroGhurkag for sharing how the method works.

[Disclaimer]

I'm not saying this is necessary the best way to do it, but the method works none the less.

[title]1. Getting the tree image from SpeedTreeCad[/title]

[Image: th_TutCreatingBillboards_01.jpg] [Image: th_TutCreatingBillboards_02.jpg] [Image: th_TutCreatingBillboards_03.jpg] [Image: th_TutCreatingBillboards_04.jpg]

The secret to getting custom SpeedTree trees to work with LOD, and avoid the annoying assertion errors at the same time, lies in creating billboard images. A real billboard, as you know, is a flat surface along the road used to display advertising. These kinds of billboards remind of the real ones in the sense that they are flat surfaces displayed to you; in essence, your trees are replaced with advanced sprites when viewed at long distances. (For you youngsters out there, a sprite is a two-dimensional picture us oldies had to contend with in computer games of yonder.)

So, the first step is to get the image we need from SpeedTree, and then we're going to work some on it.

Load up your *.spt tree in the program, then go to "File > Export > Tree image...".
Set the size to 1024.
When prompted, name it exactly like your *.spt model (but obviously not with the same file ending) and save it to a folder on your computer.

[title]2. Editing the billboard in Paintshop Pro[/title]

[Image: th_TutCreatingBillboards_05.jpg] [Image: th_TutCreatingBillboards_06.jpg] [Image: th_TutCreatingBillboards_07.jpg] [Image: th_TutCreatingBillboards_08.jpg] [Image: th_TutCreatingBillboards_09.jpg]

Open the *.tga you exported in Paintshop Pro. You'll notice it's dimensions are random, like in the example above 571x637. We want it to be 1024x1024 without having to resize it. So, fire up your everyday windows calculator. Calculate what 1024 minus your image's width split in half is (i.e. 1024-571/2). Go to "Image > Add borders..." and add those two numbers to the left and right. If you did it right your image should be 1024 pixels wide with the picture in the center of it. Now subtract your image's height from 1024 and add that as border at the top. Resize it to 512x512 (or 256x256 if you like) using Bicubic resample. After you've resized it, save it.

[title]3. Fixing it in DXTBmp[/title]

[Image: th_TutCreatingBillboards_10.jpg] [Image: th_TutCreatingBillboards_11.jpg] [Image: th_TutCreatingBillboards_12.jpg] [Image: th_TutCreatingBillboards_13.jpg] [Image: th_TutCreatingBillboards_14.jpg]

Open the *.tga file you edited in Paintshop Pro in DXTBmp. Go to "Alpha > Apply Alpha to Image". Do NOT try to create an Alpha channel, as that will destroy the perfect alpha channel that is already there from when you exported it from SpeedTreeCad. Save it to your folder as a DDS DXT3 texture, then move it over to your folder in "data\trees\billboards\". As you can see in image #13 and #14, you should have your *.spt files and your billboard files in a directory named the same.

Right, that should be it, you're done. Big Grin

/Razorwing 2006-12-03
¤ How to add images or files to your post ¤ Silgrad's UBBCode
My pet peeve: huge images in img code. I reserve the right to make any such image into a clickeable thumbnail whenever I see it.
Angel mired in filth
[Image: SignatureBannerRazorwing.jpg]
Reply
12-14-2006, 08:20 AM,
#2
 
It says there is a free Dwnld for SpeedTree but I can't find it on the pages it says it is on? WTF?
Reply
12-14-2006, 09:00 AM,
#3
 
Yes, that's weird... the links just loop around the same two pages. Clicking the download link on the right sidebar on this page leads to this page - but at the bottom there's just a link back to the first page. My bet is they discontinued the free version and forgot to update their site.
¤ How to add images or files to your post ¤ Silgrad's UBBCode
My pet peeve: huge images in img code. I reserve the right to make any such image into a clickeable thumbnail whenever I see it.
Angel mired in filth
[Image: SignatureBannerRazorwing.jpg]
Reply
01-07-2007, 05:52 PM,
#4
 
Thanks, thats some useful info but ive got a few things to add:
1. When exporting the tree image
-Make the size to be 512*512 as it saves resizing later.
-Make the oversampling value high for better images
-Tick Streak images as the alphamap leaves a small white border when in the cs. This stops that happerning.
-Untick the box Crop as you want the images to remain at the 512*512 constraints.

2.Export the image.
(the next part is for photshop users)
3.Open the image in photoshop. The small problem now is that there is a slight error when speedtree exports and the images it not 512 vertically. Not sure why this happerns!! So select Image-canvas size. In the Anchor section click on the lower box to only allow growth upwards( so tree remains at bottom). Select pixels then 512 in the vertical box. press ok.

3.Saveas the images as a dds file in DXT3 (the alpha is already there) as the same name as the treefile.

Copy into textures\trees\billboards
Done
Trees go data\trees - you dont have to assign anything in the cs or change the billboard size info.

Hope that helps,
Tom
Reply
01-16-2007, 09:45 AM,
#5
 
Thanks windsurfer, those were good tips!

The only thing I have to add is that users should make sure that the name of the billboard folder they use is identical to the name of the folder they put the *.spt files in. Oblivion uses the name of the tree folder as a template for automatically setting up billboards. It's easier to mod with one's trees if they're saved to a subfolder in Oblivion\Data\trees\ since the CS orders them into a neat new list. I'm sure you knew that windsurfer, I just wrote it for readers of the thread. It took me awhile to figure out when I first started working with trees, and it would probably have taken much longer if I hadn't already known that Oblivion uses templates like that in a few other situations. (applying normal maps for instance)

You said that one should make the oversampling value high. But when I entered 512 as the dimension of the exported image, the oversampling drop-down list only offers a value of 1?


Also, I can add that if the exported tree image lacks textures - it just shows Speedtree's default "missing texture" picture instead of yours - try exporting the image to the same folder as the texture is supposed to be in. Don't ask me why but my recently-exported billboards refused to render the leaf texture until I tested exporting it to the same folder the leaf texture was in. Strange.

On the subject of Speedtree, I experimented a bit just now with trying to get it to use more than one leaf texture map. It can do that just fine by it's own of course, but Oblivion only accepts one dds as the leaf texture. I spliced together five leaf textures into one and set it up in SpeedTree, but that corrupted the mapping. Then I tried to set up individual maps in Speedtree but set the spliced map as the one Oblivion should use, but that messed up the mapping royally with graphical glitches everywhere. Does anyone have any tips on how to get it to work?
¤ How to add images or files to your post ¤ Silgrad's UBBCode
My pet peeve: huge images in img code. I reserve the right to make any such image into a clickeable thumbnail whenever I see it.
Angel mired in filth
[Image: SignatureBannerRazorwing.jpg]
Reply
01-16-2007, 10:17 AM,
#6
 
Quote:Originally posted by Razorwing
On the subject of Speedtree, I experimented a bit just now with trying to get it to use more than one leaf texture map. It can do that just fine by it's own of course, but Oblivion only accepts one dds as the leaf texture. I spliced together five leaf textures into one and set it up in SpeedTree, but that corrupted the mapping. Then I tried to set up individual maps in Speedtree but set the spliced map as the one Oblivion should use, but that messed up the mapping royally with graphical glitches everywhere. Does anyone have any tips on how to get it to work?
I don't think it will be possible with SpeedTree Lite. Id doesn't support composite map which is required for multiple leaf and branch textures. Sad
Maybe someday someone will do a program which lets you mess up with spt files.
Michal Cielecki
Composer for Games and Media
http://www.michalcielecki.com

-------------------------------------

Akavir's Island Mod Music
Reply
01-16-2007, 11:04 AM,
#7
 
Quote:Originally posted by mirrored
I don't think it will be possible with SpeedTree Lite. Id doesn't support composite map which is required for multiple leaf and branch textures. Sad
Maybe someday someone will do a program which lets you mess up with spt files.

Oh, ok thanks for letting me know. That's probably also why my billboards appear twodimensional whereas Bethesda's appear threedimensional; it's not that they did something special really, they just had better tools to work with. I guess that solves my problem, albeit in the less-than-desired way. I would imagine the big version of the program is only available (realistically) to companies. Pity.
¤ How to add images or files to your post ¤ Silgrad's UBBCode
My pet peeve: huge images in img code. I reserve the right to make any such image into a clickeable thumbnail whenever I see it.
Angel mired in filth
[Image: SignatureBannerRazorwing.jpg]
Reply
01-16-2007, 05:12 PM,
#8
 
Quote:Originally posted by Razorwing
it's not that they did something special really, they just had better tools to work with.
That's sad truth. As I said - hopefully someday someone will write a program that will let to mess up with Oblivion's trees. I say Oblivion's trees, because for example composite maps for Neverwinter Nights 2' speedtrees are different - in one file there are textures for leaves and the trunk (or branches, can't remember correctly).
Michal Cielecki
Composer for Games and Media
http://www.michalcielecki.com

-------------------------------------

Akavir's Island Mod Music
Reply
01-30-2007, 06:22 PM,
#9
 
Hello!

I?m working on a vwd mod, and because i know you guys from silgrad tower are very deep into modding of oblivion, i got a question. Maybe someone could answer this.
What?s the way to make things like shrubs "visible when distant" in vanilla oblivion?
I tried your tutorial about the speedtree billboards, but it doesn?t work for me.
I can only get the included types of trees and all the other stuff vwd, but no shrubs ?(

This is an example of my modding project:
[Image: screenshot122ui4.th.jpg]

Any ideas?

Thanks in advance,
Jack
Reply
02-05-2007, 09:56 AM,
#10
 
Quote:Originally posted by jacko2
Hello!

I?m working on a vwd mod, and because I know you guys from silgrad tower are very deep into modding of oblivion, I got a question. Maybe someone could answer this.
What?s the way to make things like shrubs "visible when distant" in vanilla oblivion?
I tried your tutorial about the speedtree billboards, but it doesn?t work for me.
I can only get the included types of trees and all the other stuff vwd, but no shrubs ?(

Any ideas?

Thanks in advance,
Jack

Apart from that you need billboards for all new *.spt objects you create you may also want to investigate updating the distant lod. That's done straight in the CS through a menu function, and results in a huge number of files that funnily enough take up relatively no space at all. I didn't get lod to work until I did that menu operation in the CS.
¤ How to add images or files to your post ¤ Silgrad's UBBCode
My pet peeve: huge images in img code. I reserve the right to make any such image into a clickeable thumbnail whenever I see it.
Angel mired in filth
[Image: SignatureBannerRazorwing.jpg]
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)