4th September 2009, 11:12 AM | #1 |
Member
Advanced member
Join Date: Apr 2009
Location: NW
Posts: 48
|
Bas Relief from texture (not enough)
Hi, I was wondering if anyone knew a way to import a .raw or similar hieghtmap gray scale terrain image. The Bas relief does exactly this, but only 256x256, and doesn't leave me with enough terrain detail to make my roads fit well.
I tried 3ds, and it can do up to 1000x1000 pixels, but converting to ac3d the scaling was off slightly and that didn't help with making the roads either. If I make it in 3ds, what scale converts between 3ds and ac3d? I tried 0.25 % in the scale boxes in ac3d, and it was really close, but ended up being off by enough to ruin my roads. |
4th September 2009, 02:03 PM | #2 |
Senior Member
Professional user
Join Date: Jul 2003
Posts: 899
|
Re: Bas Relief from texture (not enough)
You can increase the maximum size of the Bas Relief by editing the basrelief.tcl file in your plugins directory (usually "C:\Program Files\AC3D\plugins\basrelief.tcl" or something similar).
Edit this file with a standard text editor, and scroll down to almost the bottom of the file. You'll see these lines: Code:
# MAXIMUM SIZE OF AN IMAGE (width * height) # This is the maximum number of vertices that will be created from a texture. # Change at your own risk. set ddhbasrelief_maxsiz 65536 HTH |
4th September 2009, 02:28 PM | #3 |
Member
Advanced member
Join Date: Apr 2009
Location: NW
Posts: 48
|
Re: Bas Relief from texture (not enough)
Thanks alot, I didn't know you could change that number.
Although, after its imported, the terrain is pretty bumpy compared to what it is normally. You can see the main road that goes up the hill looks like a motocross whoops section when it should be smooth. Any idea why? |
5th September 2009, 02:21 AM | #4 |
Senior Member
Professional user
Join Date: Jul 2003
Posts: 899
|
Re: Bas Relief from texture (not enough)
Unfortunately, this is a by-product of the limitations of using RGB color to calculate a heightmap.
The bas relief converts the specified texture to grayscale before creating the heightmap. This means there are only 256 possible values for the Y axis. Most images do not have a very smooth transition from one pixel to another, so you end up getting a "stepping" between pixels. One fix for this would be to convert your original image to greyscale (if it isn't already), then use an image editor to smooth/blur the image so the differences between pixels isn't so great. The problem with this is you lose details between lines (in your case the roads would merge with the surrounding landscape). If you have an image editor that can selectively blur areas, that may be a workaround. Not the most ideal solution, but aside from adding a smart smoothing algorithm to the bas relief, I'm not sure what any other options would be... Edit: If you end up going the image editing route, you can get a free image editor at www.gimp.org Last edited by Dennis; 5th September 2009 at 02:23 AM. Reason: Added gimp link |
6th September 2009, 12:05 AM | #5 |
Member
Advanced member
Join Date: Apr 2009
Location: NW
Posts: 48
|
Re: Bas Relief from texture (not enough)
Thanks for the fast reply. I think I have to give up on the bas relief technique and go with a displace modifier in 3ds. I got it spot on with that, now i'm having a hell of a time importing it to ac3d in the correct scale. I need it spot on, otherwise the roads I make will be way off. 3ds meters turn out to be gigantic in ac3d.... I guess i'll just do trial and error with my current roads and find a number that seems right. Thanks again for the help.
|
|
|