Plan for Brett Fattori
by Brett Fattori · 07/26/2005 (6:42 pm) · 12 comments
Hey folks, it's been a while since I last posted a .plan for y'all to read. I've been watching others post theirs and got the itch to submit my latest developments. dRacer progresses -- slowly. We're addressing the issues that would cause us to go from being a good title, to a great title. Lately I've been working on getting the static decal system merged with our dynamic decaler.

The dynamic decaler is a system that lets us put decals anywhere on the level, on any surface, and network them to the clients. Decals can be spot decals (essentially a square of texture) or a linked decal (like a smear or a skid). The system handles all the under-the-hood stuff like memory pooling and resource management, and exposes a couple of simple methods to add, update, and remove decals.
Here is what the skidmarks looked like, and what I was aiming for:
vs. 
These skids were essentially a solid texture that was alpha blended onto the track as a linked decal. The UV coordinates weren't really calculated since the texture was solid. This was the simplest way of doing things, but I was never happy with how they looked. The edges were too sharp, making them look too "computerized".
I sat down and started working out the way to get texture coordinates in a format that I needed to support nice soft skidmarks. I needed to be able to draw a texture across the decal, regardless of how it lined up in world or object coordinates. This led to some challenges and late nights, but eventually I came up with (what I think is) a good solution. I knew it worked when I first saw my test texture line up properly.

Now I could be assured that the skids would bend and twist properly as the car bounced off of walls and careened across the road. I had to try it, so let me share my first test image after getting them to work properly:

...and, just a little showing off -- letting the AI generate lots and lots of skids:

- Brett

The dynamic decaler is a system that lets us put decals anywhere on the level, on any surface, and network them to the clients. Decals can be spot decals (essentially a square of texture) or a linked decal (like a smear or a skid). The system handles all the under-the-hood stuff like memory pooling and resource management, and exposes a couple of simple methods to add, update, and remove decals.
Here is what the skidmarks looked like, and what I was aiming for:
vs. 
These skids were essentially a solid texture that was alpha blended onto the track as a linked decal. The UV coordinates weren't really calculated since the texture was solid. This was the simplest way of doing things, but I was never happy with how they looked. The edges were too sharp, making them look too "computerized".
I sat down and started working out the way to get texture coordinates in a format that I needed to support nice soft skidmarks. I needed to be able to draw a texture across the decal, regardless of how it lined up in world or object coordinates. This led to some challenges and late nights, but eventually I came up with (what I think is) a good solution. I knew it worked when I first saw my test texture line up properly.

Now I could be assured that the skids would bend and twist properly as the car bounced off of walls and careened across the road. I had to try it, so let me share my first test image after getting them to work properly:

...and, just a little showing off -- letting the AI generate lots and lots of skids:

- Brett
About the author
Recent Blogs
• A small hello• Recent Stuph
• So long and so out of touch...
• Plan for Brett Fattori
• Plan for Brett Fattori
#3
[17:16] damn skidmarks
[17:16] I can make these things in my drawers all day
[17:16] but on the computer.... NOOOOOOOOOOOOOOOOOO
:)
07/26/2005 (9:18 pm)
Here's a little quote courtesy of my quote file of evilness from quite some time back when Brett was first working on skidmarks and getting a little annoyed ...[17:16]
[17:16]
[17:16]
:)
#4
07/27/2005 (12:11 am)
lol
#5
07/27/2005 (2:05 am)
Cool.... Very cool stuff brett.
#6
Are you moving this over to TSE when done?
07/27/2005 (3:04 am)
Very nice :o). I'm a great fan of Burnout games and would love to see something like that fromthe community. Add some car damage...go on please ;o)Are you moving this over to TSE when done?
#7
@John: About 1 1/2 years so far.. It's been a lot of work since there was a need to redo the entire vehicle system and physics system and networking and... well, you get the point. :-)
@Peter: There's certainly a possibility that this will go TSE. However, TSE doesn't have a big enough reach right now with DirectX only. Once it's OpenGL and supporting Mac and Linux, it'll be a better platform.
- Brett
07/27/2005 (6:19 am)
Gee, thanks Tom for letting people know all about my trouser work!@John: About 1 1/2 years so far.. It's been a lot of work since there was a need to redo the entire vehicle system and physics system and networking and... well, you get the point. :-)
@Peter: There's certainly a possibility that this will go TSE. However, TSE doesn't have a big enough reach right now with DirectX only. Once it's OpenGL and supporting Mac and Linux, it'll be a better platform.
- Brett
#9
07/27/2005 (9:59 am)
looks smart. the cars a bit small :P
#10
07/27/2005 (12:21 pm)
I like the test texture pic, I can imagine how happy you were when you saw that working :)
#11
08/04/2005 (1:41 pm)
Extremely nice and fun looking. (Fun to play, not fun like looking funny) Will there be a beta-release anytime soon, or have it already been one?
#12
http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=10899
08/18/2006 (3:13 pm)
Hi Brett, care to share how you get the texture coords and blend those skids? I'm having a really hard time getting splashes on the player to work... :/http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=10899

Torque Owner John Rockefeller
I am also making a racing game :)