Project: Blender Extensions
Tracker: Py Scripts Upload
Script name: height.py
Author(s): Michel Anders (varkenvarken)
This scripts replaces the weights in the active vertex group to weights that represent the height.
After installation it is available in the 3dview in weight paint mode under Weights->Height
It maps the chosen coordinate (x, y or z-axis) to a weight, which will be 1.0 for the largest value encounters and 0.0 for the smallest.
These coordinates values are interpreted in either object (local) space or world (global) space.
If the the Absolute checkbox is checked negative coordinates will be treated as positive.
The mapping from minimum,maximum coordinate to [0,1] weight is normally linear, but may be influenced with the Power property.
After mapping any values less dan Low will be set to 0, any values larger dan High will be set to 1
A common use case is using the result as desity map for a particle system to populate a landscape mesh with plants for example. It might be easily combined with an vertex weight edit modifier, for example to invert the result when one wants more particles at lower heights.