Miarmy Crowd Simulation Documentation (English)

Geometry Weight Control

Introduction

In many cases we like to have our geometry randomization can be controlled by weight proportion.

For examples, there are 100 gunmen agents in scene, we only want 10% of them select Machine Guns and others 90% select Rifles

At this moment we can add some weight value to geometry (or geometry set) and make them can be selected by selection weights

 

Workflow

Firstly, we have to understand the geometry random rules, We highly recommend you read and understand this before move on: Simple Geometry Randomization

Then, we just need add some attributes to the nodes and make it can be weight distributed.

In above image:

  • Must Render: "head_Mesh2", "l_arm_Mesh", "l_shoe_Mesh", "r_arm_Mesh", "r_shoe_Mesh"
  • Select Geometry: one of geometry "tshirt_Mesh", "shirt_Mesh1", "sweatshirt_Mesh2"
  • Select Geometry Set 1: "without" and "with"
  • Select Geometry Set 2: "set1" and "set2"

The geo weight attribute can work on Select Geometry and Select Geometry Set

 

Let's take a look at this example, when render, our system will select one of geometry set from set1 and set2, (set1: shorts, set2: pants)

In normal situation, the agents in shorts(set1) and pants(set2) should be 50 50

Let's change this result:

    1. select set1, and check Miarmy > RENDER > Geometry Select Weight > Add Geometry Select Weight Attr 

    2. select set2, and check Miarmy > RENDER > Geometry Select Weight > Add Geometry Select Weight Attr 

    3. there will be an attribute added to each set

weight attribute

    4. if we set this attribute 1 for set1(shorts) and and 9 for set2(pants), the agents will be 10% in shorts and about 90% in pants

90% pants and 10% shorts

 

    5. if we set this attribute 9 for set1(shorts) and and 1 for set2(pants), the agents will be 90% in shorts and about 10% in pants

90% shorts and 10% pants

 

 

 

 

Basefount Technology