• Welcome to Kart Racing Pro Official Forum. Please login or sign up.
 
November 24, 2020, 07:26:43 AM

News:

Kart Racing Pro release11f available! :)


Is it possible to do 3D grass and wet reflections from 3DS Max 2013 x64?

Started by rainey06au, July 31, 2020, 12:28:08 PM

Previous topic - Next topic

rainey06au

Okay I'm getting closer through a lot of trial and error!  Obviously the density is too high but I needed to see proof that my densitymap was actually working.

I still don't know how to combine my .EDF objects into the .MAP file though. :(

LXS77

Right, OK, looks like you're following a procedure of creating a track for MX Bikes (another project by PiBoSo). Kart Racing Pro, however, uses a different approach, which is (in my opinion) way simpler .

I highly recommend going through these articles:
1. http://docs.piboso.com/wiki/index.php?title=Track_Creation_Guide
2. http://docs.piboso.com/wiki/index.php?title=TrackEd
3. http://docs.piboso.com/wiki/index.php?title=MapView

All your objects should stay in 3DS Max as a part of your track. No need to export them separately into different formats. They only thing you need to do before exporting into .FBX - name surfaces and collidable objects as described in the Track Creation Guide.

P.S. And one more thing - .map, .trp and the sub-directory where these files are located should have the same name (e.g. sampletrack.map and sampletrack.trp sitting in sampletrack sub-dir). Another example is the filelist of the Lydd track (image attached).

rainey06au

Quote from: LXS77 on August 05, 2020, 11:36:41 AMAll your objects should stay in 3DS Max as a part of your track. No need to export them separately into different formats. They only thing you need to do before exporting into .FBX - name surfaces and collidable objects as described in the Track Creation Guide.

You're right, I did start with MX Bikes, but I've been referencing those resources in my efforts to make this KRP track.  All my objects are correctly named, so it sounds like I just need to select them all in one go from 3DS Max and export them to one single .FBX file. Then disregard all the other parts of the MX Bikes compile process.


rainey06au

I've discovered another little setback.  Looks like you can't use more than 1 different densitymap in a project. I had different masks made for my different grass textures but when I leave them in the .GRS file it does some sort of funky blend of them in the distribution of 3d grass... sadly.

rainey06au

So I'm pretty happy with how it looks with some grass. I wanted to have the bare patches of dirt stay bare so I made the density mask. It's got some side effects across some of my terrain grass textures but you don't notice for the most part.  My rain puddles are not working still but I'm much happier with this workflow now thanks to you LXS77. :)






LXS77

Quote from: rainey06au on August 05, 2020, 12:32:37 PMI've discovered another little setback.  Looks like you can't use more than 1 different densitymap in a project. I had different masks made for my different grass textures but when I leave them in the .GRS file it does some sort of funky blend of them in the distribution of 3d grass... sadly.

It's one density map per texture. You can create individual .grs files for each grass texture, FBX2EDF will process them. Just keep the density map in the TGA's Alpha channel.

LXS77

Quote from: rainey06au on August 05, 2020, 01:15:01 PMSo I'm pretty happy with how it looks with some grass. I wanted to have the bare patches of dirt stay bare so I made the density mask. It's got some side effects across some of my terrain grass textures but you don't notice for the most part.  My rain puddles are not working still but I'm much happier with this workflow now thanks to you LXS77. :)


Glad I could help! :)

The track looks great! Are you going to publish it when it's ready or is it just for personal use?

rainey06au

Quote from: LXS77 on August 05, 2020, 02:29:20 PMIt's one density map per texture. You can create individual .grs files for each grass texture, FBX2EDF will process them. Just keep the density map in the TGA's Alpha channel.
Isn't working for me, I create .GRS files for each texture with the correct values inside the code, including referencing the different density .TGA of each texture (all suffixed with '_g'). RGB channel is 255 white, alpha channel is my density. FBX2EDF starts to mix them together with some very bizarre behavior. I decided to just use my edge density map across all textures in the end because I really didn't want grass being drawn right up to the track edge (through the dirt).

I am developing the track as a training tool for my 10yo daughter and to improve my modelling abilities (hence the attention to detail). No plans to release publicly but I might one day!

I just cut some test laps (in 10% wet lol) running the track counter clockwise for fun (it's currently running clockwise in reality, you can see some onboards from my daughter if you browse my YT channel).

LXS77

Quote from: rainey06au on August 05, 2020, 02:41:59 PMIsn't working for me, I create .GRS files for each texture with the correct values inside the code, including referencing the different density .TGA of each texture (all suffixed with '_g'). RGB channel is 255 white, alpha channel is my density. FBX2EDF starts to mix them together with some very bizarre behavior. I decided to just use my edge density map across all textures in the end because I really didn't want grass being drawn right up to the track edge (through the dirt).

I've run some tests with multiple grass textures and separate .GRS files. Well, yeah, this densitymap thing is weird. Perhaps, there's something wrong with the function (if I'm not mistaken, in the MXB process there was a single grass density mask for the entire track) or we're just using it incorrectly (which is more likely) ;D

Anyway, it's an optional feature and you can still play with the max_density value for each grass texture (gives pretty good results BTW).

Quote from: rainey06au on August 05, 2020, 02:41:59 PMI am developing the track as a training tool for my 10yo daughter and to improve my modelling abilities (hence the attention to detail). No plans to release publicly but I might one day!

Ah, I see. Well, for training purposes the track's perfect! All the best to your future Jamie Chadwick! :)

rainey06au

Thanks mate! I'm pretty happy with the track so far.  I managed to get the wet track puddles working by using Channel 2 in the Specular map rather than the Glossiness map of the material. Still doesn't seem right though, near reflections don't appear to reflect the skydome, but 100m in the distance the track does appear to reflect the skydome.  Not sure if I should be specifying reflections in the .shd or not (I'm assuming the reflection factormin etc. is only for a permanently reflective surface like glass or water).

LXS77

I'm glad you're enjoying the results! Sadly, can't help you with puddles (just never done them for my tracks). Have you studied the Track Creation Guide?  ;) Though it doesn't really provide detailed instructions on this matter, it definitely mentions rain puddles as a texture in the Specular channel :)

rainey06au

Dude I have the Piboso Track Creation Guide open whenever I'm working on my track but there are so many things that it doesn't cover in detail, so I research on these forums and only find small pieces of information from other members, usually with expired images etc. so it's really hard to learn how things work with so much old information floating around. I know rain puddles can be in the specular but I saw other members confirming that it works in the glossiness as well, which in my attempts does not work.

rainey06au

Just so people can see what I mean. Rain at overcast looks correct, but rain during clear day does not reflect the sky.








PiBoSo

Quote from: rainey06au on August 15, 2020, 07:39:03 PMJust so people can see what I mean. Rain at overcast looks correct, but rain during clear day does not reflect the sky.

Please note that the sky is not reflected in puddles.
A constant color is used instead, that is set with "sky_color", for each weather condition, in the track AMB file.