January 23, 2018, 07:45:22 AM
bigger smaller reset 800px Wide width Full width Reset * *

NRTracks

 
Welcome, Guest. Please login or register.

Login with username, password and session length
« previous next »
Pages: [1] Go Down Print
Author Topic: Sandbox_Bumpmapping  (Read 6611 times)
fortine_oo
Legacy
Sr. Member
*****
Posts: 188



« on: October 28, 2010, 04:49:13 AM »

riviera71

You know bumpmapping?
Like, how do the 4 boxes relate to each other (in the size row)?
...how do the 4 boxes relate to each other (in the distance row)?
...how does the numbered box in the size category relate to the numbered box in the distance category?
Why is Scale Params (head & tail) grayed out?

I've been trying to get some bumps to simulate the raised bumps on curbs, but I've only been able to do it if it's on an inside location. I can't seem to get small consistent bumps for outside turns where there is pavement farther outside that can be run on (like T1 at Hockenheim).


* BM section.jpg (37.9 KB, 685x101 - viewed 338 times.)

* hock T1.jpg (91.74 KB, 964x544 - viewed 385 times.)
« Last Edit: October 28, 2010, 05:05:51 AM by fortine_oo » Logged
riviera71
NR2K3 Veteran
Member
*****
Posts: 19


« Reply #1 on: October 28, 2010, 08:23:46 AM »

This is all by far the least documented aspect of sandbox so most of it is guesswork and trial and error lol.
As far as I know they work in pairs so in your example there would be one bump that's 0.2mm every 0.4 meter (first boxes in each row), a bump that's 2mm every 10th meter (2nd box in each row) and so on. Then it all repeats like waves so you could get some pretty major bumps depending on how you choose the distances. For instance the distances 1, 10, 25 and 50 will have all the bumps coinciding at 50 meters. 

The Scale Param boxes seems to only have with BS sections to do. Add a BS section (light blue) and you'll see that those boxes are the only ones you can work with.

As for the "where did my bumps go?", I have the same problem Tongue One of these days I'll sit down and really try to figure it out because right now at the track I'm working on I'm not getting any bumps.

Logged
riviera71
NR2K3 Veteran
Member
*****
Posts: 19


« Reply #2 on: October 28, 2010, 04:13:58 PM »

I found an old write up by Mark Royer and here's his findings:
Quote
==================================
Unified Theory of Bump Mapping
==================================
Note: The following is HIGHLY speculative! I will continue to work to verify the theory through experimentation. Commentary, speculation and observations are welcome - I will continue to update this as we figure it out.

To help my experimentation, I cranked up to maximum the stiffness of my springs and shocks to minimize confusion introduced by chassis bounce. I also created a specialized, all-white with black-line grid, asphalt mip so I could see exactly where I was in a segment while driving.

---------------
Bump Map Params
---------------
 

There is a "Track Default" Bump Map Param descriptor. In addition, you can add "new" bump map param descriptors with your own names. Bump map params are applied to BM-sections (see below).

Each Bump Map Params Descriptor allows you to specify up to four "waves" of bumps. For each wave, you specify the height in millimeters (Size) and wavelength in meters (Distance). Therefore, the bump will repeat at the wavelength. "Waves" 2, 3 and 4 appear to not be used unless wave 1 has non-zero size and distance. If wave 1 is in play, then 2, 3 and 4 affect the segment bumps, but it's unclear to me exactly how. I suspect the size and distance of 2, 3, and 4 have the same effect as they do in 1 and the bump waves are simply overlaid on top of one-another (but I haven't been able to convince myself of this with certainty yet).


 


---------------
The BM-Section
---------------
 

BM-sections are placed in segments (just like X, F and W-sections). For each BM-section, you select a Bump Map Params Descriptor (see above). If you have no BM-sections in a segment, the "Track Default" bump map param descriptor is used laterally across the entire segment.

When a single BM-Section is defined for a segment, I believe that the bumps created run laterally across the entire segment and the wave of bumps runs the entire segment head to tail. I have not experimented with multiple BM-Sections in a segment yet. That will come after I understand exactly how bump waves 2, 3 and 4 work.

From reading various discussions scattered around the forums, what I expect to happen with multiple BM-sections is that between the BM-section lines the height of the bumps of one section will be interpolated to the other and vice-versa. Outside the outer-most BM-section and inside the inner-most BM-section the bumps of those sections just extended to the edge of the track.


---------------
The BS-Section
---------------
BS-sections are placed in segments (just like X, F and W-sections). The BS-section appears to be a scalar height multiplier to the Bump Map Params of the BM-section. You specify the multiplier at the head and at the tail of the BS-section. The multiplier value is then interpolated along the BS-Section in the forward direction of the track and applied to the Bump-wave at that position.

So, for example, if a BS-Section were specifed with a head = 1.0 and a tail = 0.5, any bump height at the start of the segment would be the height, in the middle of the segment 0.75x height and at the end of the segment 0.5 times the height.

 

Similar interpolation appears to be done laterally across the track too from one BS-section to a another. So, for example, if we had two BS-Sections, the outside one at the retainer wall with head = 3.0 and the inside one on the apron with head = 1.0, the height of a bump at the start of the segment would be multiplied by 3.0 at the retainer wall, 2.0 in the middle of the track and 1.0 on the apron.


-Mark R.
(it used to have some pictures but they had transformed into not so pretty red X's)

Based on that I think the layout in the picture below might work for making curbs. Atleast it's worth a try even if sandbox never ceases to amaze Wink
Logged
fortine_oo
Legacy
Sr. Member
*****
Posts: 188



« Reply #3 on: October 28, 2010, 08:08:12 PM »

riviera71

Thanks for that.
I've searched many, many times and places looking for any kind of explanation and have never been able to come up with anything "sandbox" related to bumpmapping.
I've done a lot of testing, but with no inkling of how the values inter-relate, it's been impossible (for me) to formulate any logical plan of attack.
(I did have some "track surface decals" on the track paralleling the bumpmap line, but I really like Mark R's idea of a grid.)
I've stayed away from BS-Section because I thought it was strictly for total segment coverage, like for a bumpy track. I also assumed it was linear. The possibility of having multiple lines interfacing laterally could provide alternatives to adding X-sections for linear dips/gutters (like they have at Hockenheim).

I'll have to digest the information, but I can't wait to try it out. yahoo


Thanks again. thumbsup
fortine_oo


* hock gutter.jpg (26.77 KB, 462x380 - viewed 326 times.)
Logged
riviera71
NR2K3 Veteran
Member
*****
Posts: 19


« Reply #4 on: October 29, 2010, 03:25:57 AM »

np Smiley
This one http://www.thepits.us/files/tutorials/thepits_n2003_bumpmap.pdf is out there too and I think that's the only official (iirc Grant was a Papy guy) explanation.
Logged
fortine_oo
Legacy
Sr. Member
*****
Posts: 188



« Reply #5 on: October 29, 2010, 05:51:07 AM »

Thanks again, but I already have that. (I have all the tutorials.)
Most of that discussion doesn't seem to be about bumpmapping (at least not in sandbox), and the part that is (by GrantR) never made any sense to me. Once I understand the explanation from the previous post, which appears to be pretty straight-forward, I might be able to comprehend/use the information in the tutorial.

If you dig up any more tidbits, I'm ready for schoolin'.

Thank you.  cheers
fortine_oo
Logged
Lyndon
Administrator
Sr. Member
*****
Posts: 147



WWW
« Reply #6 on: October 31, 2010, 05:32:35 PM »

Now that's what I'm talking about... intelligent questions and intelligent answers (with thanks to Mark Royer for his write-up also).
Logged
Radt Dastard
Member
*
Posts: 3



« Reply #7 on: October 31, 2010, 05:39:09 PM »

Did you get that Lyndon? 'Cause I don't think you did. Better close your mouth before any flies get in. You guys are good but do you really think Lyndon will ever pick up on this? He'll probably try to take credit for this like he tries to take credit for my driving ability. As one wheelman to two others--we all know he's the weak link here.
Logged
fortine_oo
Legacy
Sr. Member
*****
Posts: 188



« Reply #8 on: October 31, 2010, 11:32:56 PM »

After a short experimentation, I have come to a preliminary hypothesis.
You have to contain (laterally) the BM-Sections with BS-Sections, and then contain (laterally) both of those sections with "Track Default" BM-Sections and BS-Sections. I also added "Track Default" BS-Sections at the extreme edges of the track, but I didn't try it without those, so I don't yet know if if they are needed.
Without the containment Track Default sections, the bumps were present (laterally) well beyond (if not completely to the track edges) the curb area.

I re-iterate, this is strictly preliminary. I just wanted to add what seems to work...so far. I only used the first window of the BM-Section (for the curb bumps), and I had the Track Default set to zero.


* bump map confined.jpg (123.93 KB, 1435x912 - viewed 441 times.)
Logged
fortine_oo
Legacy
Sr. Member
*****
Posts: 188



« Reply #9 on: January 10, 2012, 06:07:34 PM »

At some point, I'm going to try and make a bumpmapping tutorial, but it'll require more time and effort than I have the desire to commit to right now.   
For now, an example of the application of bumpmap values can be had by downloading Edenvale (http://www.nrtracks.com/files/dl_edenvale.html).
I used different values "size-wise", and varied appications, some a single bump and some a variety of bumps in a variety of sizes.
I used bumpmaps for general track bumpiness, edge of track crumbly asphalt, and for the cones in T1.

To see the values, unpack the dat file, load those unpacked files (the loose files and the trackmat folder) into the (edenvale) track folder (which will need to be in the NASCAR Racing 2003 Season\tracks folder), and then open the ptf file with Sanbox. With the track opened in Sandbox, select the "View" tab, then "Bumpmap Editing View" from the dropdown list. Click on the bumpmap lines, the same as you would for any section, to see the values.
The orange lines are the "bumpmap" properties (the bumps).
The turquoise lines are "bumpsection" properties. I have already forgotten exactly what the BS lines do, but by placing one outside each bumpmap line they keep the bumps confined to the area between them. The BS parameters (scale params) provide additional affect, but I don't recall exactly what that is, but I'm gonna guess it's for lateral bump-spacing, where a larger value is for greater spacing between the bumps (laterally).   
Compare the line layout and values to the "feel" they provide on track.
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  

Powered by SMF 1.1.15 | SMF © 2006-2008, Simple Machines
Leviathan design by Bloc | XHTML | CSS