bringing objects into scenes, single & population

Started by cadmar, December 03, 2012, 08:27:16 PM

Previous topic - Next topic

cadmar

Hello.

When you bring an object into a scene, the three translate equations under transform is where you want it placed in the image. Is there an easier way to get those translate numbers into the box, aside from manually filling them in. Reason I ask is, as soon as you move your mouse to fill in the first number, you won't find the same spot again & you will miss out on the other two numbers.  I assume scale is the size you make the object? Where do the rotate numbers come from? What is angular position? Where do all those numbers come from for heading, elevation & distance?

IF I imported as population, lets say a tree. How do I get them at the right elevation, (since the ground is not flat) and how do I keep the trees away from a certain area of terrain, I do not want any trees. Finally, if I only wanted say 10 trees in a certain spot, is it easier to bring them in one at a time or population & where do these numbers come from, since you are dealing with just a tiny area, yet an area that would require more then 1 equation, otherwise you'd have all ten trees landing on the same spot.


Thanks in advance

Rick  :)

jo

Hi Rick,

In the parameter view for nodes you can find a button in the top left with a question mark. Click that and you will be taken to the online documentation for that node. There are still gaps in the documentation, but the population and object nodes are there. Having said that the population page needs updating and I'll get on to that today.

The values you mention don't really "come from" anywhere. You define them, although some objects are placed in a certain location depending on the camera view when you create them. Others are placed at the origin. They have default settings and you change them to suit your purposes.

With populations you don't need to worry about getting things at the correct elevation. In the Terrain tab of the populator there's a "Sit on terrain" checkbox. If this is checked then population instances (the objects in the population) are positioned on the terrain. The "terrain" is defined by the shader link fields in the Terrain tab. By default these are connected to the Compute Terrain node and the default planet. Unless you have special needs then this default setup is sufficient to have the population instances sit on the terrain. I should say that exactly how an object sets on the terrain depends on where the object origin is. For example the Xfrog tree models typically have their origin set just above the roots, where the ground would normally be on a tree. That means the roots are effectively "underground" when the model sits on the terrain.

To control where population instances appear you can use a density shader. This can be a distribution shader, an image map shader with a mask image, a painted shader or many of other sorts of shaders. The Painted Shader Guide has an example project using a density shader (Painted shader in that case) with a population:

http://www.planetside.co.uk/wiki/index.php?title=Painted_Shader_Guide

Go down to the Examples section, it's the first one. Also try searching the forum for population and density, or similar.

Population instances are placed randomly. You can use the "Spacing variation in a,b" parameter to control how random the placement is. The default setting of 1 is "completely random". If used 0 it wouldn't be random at all, the instances would be placed on a grid the spacing of which is determined by the "Object spacing in a,b" parameter. Changing the seed value in the Seed tab lets you change the general pattern of the random placement.

You don't have to define any equations or anything to control the placement of population instances, with the exception of the density shader perhaps. It will try to place things randomly according to the parameters you set. Just play with it and see what happens.

If you wanted trees in specific places then it's best to place them yourself. The idea behind the populator is to make it easy to place lots of copies of the object across an area. The populator has the advantage that it uses a lot less memory than if you used invididual objects. If you're not too worried about absolutely exact placement you can use a density shader with the populator to control specific places where instances should appear. For example you might use the painted shader to paint some dots on the landscape where you want trees. With a bit of messing about you could get the populator to show trees in those places. It's up to you whether it's easier to place individual objects and their higher memory use or spend time getting the populator to do what you want and save some memory.

Regards,

Jo

cadmar

Thank you so much Jo. You have been so much help to me. Because of that I've learned a lot about Terragen 2. IT is a wonderful program & there is no end to learning things about it. You can create such wonderful scenes with it.

I know it all comes in time. I will definitely go through those tutorials.

Thank you again Jo, :) I hope I'm not too much of a pest.

Rick

Oshyan

It should also be mentioned that you can easily copy the coordinates at the position under your mouse cursor in the 3D preview by right-clicking and selecting from the menu. You can then paste these coordinates into your object or camera position to move them instantly there. There are "clipboard" buttons next to most coordinate input fields that have a Paste option that you can use once you Copy coordinates from the 3D preview.

- Oshyan

cadmar

Thank you so much for that information Oahyan! I really appreciate it.






Rick  :)