>> > Did you test your airfield grass with some of the newer generated  
>> terrain
>> > (LOWI in my case)?
>>
>> No, I didn't. Shouldn't make a difference for rendering purposes how you
>> created it, at this stage it's all vertices and pixels and the shaders
>> don't care where they come from or how they connect.
>>
>
> Not sure about the airfield grass, but at least the concrete and tar
> surfaces for taxiways and apron use a different mapping.
> If i remember correctly 1 x 1 meter in the new scenery builds.

I'm not sure I understand the problem. After the scenery generation process, 
you have vector data of the terrain mesh, but textures are mapped at tile load 
time using materials.xml - so here we find that a 512x512 sheet of terrain is 
mapped to, say, 2000x2000 m. This is done independent of how the vector 
resolution of the terrain mesh is and has nothing to do with how you generated 
the scenery.

You're also usually not free to change the mapping as you like - texture sheets 
depict real-world structures with a real-world size, and showing 1000 m sized 
houses on the texture just doesn't do.

Shader effects add noise and overlay textures to the base texture mapping, and 
here is where it gets tricky:

* Overlay textures inherit the uv-mapping of the base texture sheet for lookup 
purposes (you can't look them up in world or local cartesian coordinates), and 
read the overlay texture at a fixed fraction of the base texture uv 
coordinates. Which means that if you shrink the base texture, normal maps, 
heightmaps and overlay structures shrink proportionally. This makes sense - 
imagine the urban effect in which you change the scale of the base texture but 
not of the heightmap - suddenly random bits of the base texture show the relief.

* Procedural noise is usually generated at fixed scale in world coordinates or 
local cartesian coordinates - this needs to be so because you need to be able 
to fade it out at a given distance to avoid Moire patterns and flickering, and 
also because the noise often stands for some fixed-size phenomenon (rocks lying 
around, ocean waves...)

So texture size mapping declarations and shader-internal noise  mappings can in 
general not be varied arbitrarily or independently and need to be considered 
together. It would be possible to code shaders in which overlay textures are 
also done at fixed physical sizes - but you'd need a lot of extra parameters to 
do that and I'm not really sure in improves usability. 

If that's what you're doing, i.e. you're changing the mapping of a base texture 
to a physical size, my recommendation is just to undo these changes or to map 
your airports to a different effect in materials.xml. 

The reason is that we have a balance between what details we want to generate 
procedurally and what details need to be on a texture. Some structures (grass 
for instance, agriculture patterns, buildings) need to be on the texture sheet 
because the functions to generate them are very expensive, other more random 
structures can more cheaply be generated by evaluating a function.

So in the case of fields we use a top-down approach - the fields which we can't 
do by function are shown in the texture, the local grainy detail structure is 
done in the shader. The airfield grass uses a bottom-up strategy - the grass 
which isn't easily generated by a function is done by a hires texture mapping, 
this leads to tiling when seen at larger scales, so shader-generated noise is 
used to de-tile the effect.

If you come with a different idea of the base texture size, you may need to 
change the whole approach from top-down to bottom-up or at least the balance 
between what detail scales are on the texture and what detail scale you add 
procedurally. I admit that it's not exactly convenient that all these things 
need to be taken into account when doing texturing together with effects, but 
it's very hard to write an effect like the airfield grass or the runway that 
will work with any base texture  you could come up with - the issues listed 
above are not going to go away easily.

I don't know if that is the issue, but perhaps the explanation makes sense (?)

* Thorsten


------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to