ter2blend

I’ve been playing around with the ter2blend plugin for a few days now and no matter what I do I can’t seem to get the thing to work right. I mean the background images import fine, the mesh imports fine, the problem is they don’t line up. So when you go to put a 3d object in the rendering or animation and it flies behind something it doesn’t look right, It will look like the object has been cutoff by the mountain but the mountain won’t be near it. I guess I should post a picture to show the trouble I’m having but I was hoping someone else here might have encountered the same thing and have some suggestions on how to fix it. I tried emailing the guy that wrote the script but haven’t heard back from him.

thanks,
Chris

did you copy the camera position and lens size properly?

Martin

yes I think so. I made sure to copy them down just like the were in terragen and I made sure that the units were terrain units.

One thing that I noticed is that the ter2blend plugin rounds up the numbers so I did another try at it and made sure that the numbers were rounded numbers so that I didn’t have to worry about ter2blend rounding them up. And that didn’t fix the problem either. Is there something that I’m missing?

Thanks,
Chris

The following are two of the most important things you need to do in order for Ter2Blend to work…

Make sure that the rendersize of your blender output picture matches the rendersize of your terragen pics…

Also… you need to make sure that the Blender camera lens size is set to 22.70 You can check this by clicking on your camera… then hitting F9 (on windows). The default camera lens size is 35

Also… keep in mind that when you copy the “measurements” from Terragen… you are using “terrain units” and NOT “meters” as a measurement unit… additionally… keep in mind that if you did this as an animation… if the “fixed height” buttons are checked in Terragen… it doesn’t matter height differences you recorded in your anim… the terragen render will always maintain a constant height above the surface of your landscape.

I have used Ter2Blend extensively and have found it to be a great addition to the bldner arsenal of tools… I hope you find it the same… :wink:

Jason

thanks for the info. I’ll run downstairs and give it a try.

The most recent version (maybe?) has a huge bug with heading, pitch and bank (mostly bank) that mess up alignment. See here:
https://blenderartists.org/forum/viewtopic.php?t=4674
(NB: in the post, gvr is Guy Van Rentergem, who wrote Ter2Blend)

well I figured out what I was doing wrong with the help of some folks here. I did have the camera set wrong. I was setting the camera to 22.70 when placing the background image but not actually setting the camera to 22.70 in the blender camera settings.

Anyway it works fine now and I’m totally blown away but the results. Totally Awesome !!!

Chris

I have this script and it will be one I will always keep. There is one thing I could never understand about it. Why do you need to import the rendering of the terrain from terragen? Let me explain. To me when you render something in terragen(lets call it a view) its two dimensional. Meaning you its like taking a picture from one point of view. Ok now I would see why you would import that picture into blender to insure that the mesh that the terra2blend script makes lines up correctly. BUT other then that I cannot see why you would need the rendering. In other words what I think you would need would be a top down rendering from high in the terragen sky that you could lay over the mesh as a texture. But a rendering from the terragen camera’s POV would seem to me to be useless if you were going to make any kind of animation. If you were going to do a 2d render of the terrain from blender then you would still need to texture the mesh before you added your blender objects and hit the render button.

I hope someone here understands what I am asking???

Thanks

One of the biggest uses of Ter2Blend is to add shadows to the terrain. The mesh does not need to be textured, but it has an “Only Shadow” material so that shadows are “overlayed” over the Terragen picture.

The animation feature of Ter2Blend is only good to use if you’ve already rendered an animation in Terragen and want to composite objects into the entire animation.

What I intended to use it for was to make terrian that I could then import into blender to do animations or use in the game engine. In that case the “terrain” would need to be texture either in blender or by importing a jpg the was converted from a bmp from terragen. Am I on the right track here?

OK i have done what you wanted (as i have been pioneering this for a while)no ter2blend python script used

to texture a landscape using a texture from terragen you must.

IN TERRAGEN

set the rendersize of the terragen image to maximum. (i do 4000x4000)

remove all sky rendering and atmospheric colour distortion.

set everything to no shadows

camera position and target position to dead centre of terrain.
camera to the lowest posible postion to have evything in view (exactly/no bleck around the edge of the render)

EXPORT

after rendering texture save as BMP then convert to TGA. (4000x4000=45Megabytes)

using a terragen plugin export a DXF file of the landscape

BLENDER

import DXF -remove doubles and join as many pieces as possible.(you’ll understand if you do it)

create a plane that is exactly (exactly did i say that already) the size of the landscape from the top view. (delete one edge on this plane).

duplicate it so that there are the same number of planes as pieces of the landscape. join one plane to each piece(this is to get the texture to line up correctly)

now using you texture from terragen (load image)

–set emit to about .3-.4 (for the ambient light effect)
–let it recive shadows etc (for animations or still photos) (games would be different)

now set up the lighting and render in BLENDER.

check this out

RENDERED IN BLENDER 100% blender shadows

http://www.dm7.net/albums/terra/topdown.jpg
http://www.dm7.net/albums/terra/terrainsolidmist.jpg

be warned for detail this good your .BLEND FILE will be 55Meg but if you use a simpler landscape and a smaller texture it will be fine.

i used a 4000x4000px texture and a 500,000 polygon mesh