Fast Object Distribution

Andrew Willmott Maxis, Electronic Arts

Distributing Objects • Goal: Place objects over an area • Vary attributes (colour, size, etc.) • Lots and lots of solutions – Pseudo Random: LCG, Mersenne Twister – Dart throwing – Blue noise (Ostromoukhov et al.) – Wang tiles (Hall and Oates)

Our Constraints • Fast! (Game use) • Low memory (Low memory -> Fast) • Re-produceable • Control – Position – Orientation, Colour, Alpha, etc. – Density

Summary • Use Halton Sequence to generate N samples • Make it incremental for speed reasons • Use i / N as a magic number – To index attribute tables – To perform rejection sampling against maps

• (You may leave now)

Halton Sequence • Basic idea: take the sample count in base b, and digit reverse it

• In binary: 0 -> 0.0 1 -> 0.1 2 -> 0.01 3 -> 0.11 4 -> 0.001 5 -> 0.101 6 -> 0.011 7 -> 0.111

Halton Sequence • Extends to higher dimensions • Use base 3, 5, 7... to avoid correlation

20

100

500

Why Halton? • Ensures samples are well-spaced • It is extendable – Later samples in the sequence fill in between previous samples

• It’s simple: no subdivision, spatial data structures, no state...

But • Too expensive for our purpose – Requires digit reversal of base 2, 3, 5 (3D) numbers – log_b(x) with divides in inner loop – Problem: Recalculate from scratch for each sample

• Could use look-up tables – But that’s expensive too, for large tables – Also imposes an upper sample count limit

Incremental Halton Sequence • What changes between Hn and Hn+1? • For base 2: – Bottom m bits, depending on carry propagation – Each bit x that flips adds +-2-x – So, form the difference, XOR(n, (n+1)) – Adjust Hn accordingly

• Expected iterations: 2

Incremental: Other Bases • Store count in BC form. – Base 3 = 2 bits per digit, Base 5 = 3 bits per digit

• As we manually propagate the carry, adjust H_n accordingly, either -(b-1)b -x, or +b-x

• Expected carries/iterations – base 3 = 1.5, base 5 = 1.25

Choosing Attributes • Orientation, colour, transparency, size • Our usual approach: Data-drive from table – index with e.g. particle age (0-1) – or random number

• New approach – i is sample number, use i / N to index – Areas well apart in the curve correspond to wellseparated objects

Attribute Tables • Colour: 0

• Size:

• Rotation:

1

Random Selection

Attribute Tables

i/N

• Colour: 0

• Size:

• Rotation:

1

Advantages • More controllable • As well as weighting, curve is controlling effect over distance – Red boxes farthest from yellow boxes

• Curves are correlated too – Big yellow boxes, small red boxes

Object Nesting • Can apply the same technique to different model types

• Allow artist control over where range starts • Subsequent types “fill in” without collision

Large Trees

Medium Trees

Bushes

Object Density Control • Want control either by image map or procedural map • Either may be game-affected, so minimal preprocessing desirable

• Key observation: – As sample count increases, samples fill in between previous samples – Thus can affect overall density by varying N

Density Control • Can achieve the same effect locally by dropping out samples larger than a given cutoff N, depending on a local density control value

• This reduces to: f(pi) < i / N: reject

• (p is sample i’s position, f is density function)

Density Map

Distribution

Density Map

Distribution

Images

Images

Questions?

Fast Object Distribution

Page 1. Page 2. Fast Object. Distribution. Andrew Willmott. Maxis, Electronic Arts. Page 3. Distributing Objects ... Object Nesting. • Can apply the same technique to different model types. • Allow artist control over where range starts. • Subsequent types “fill in” without collision. Page 21. Large Trees. Page 22. Medium Trees ...

1MB Sizes 2 Downloads 329 Views

Recommend Documents

1 Determination of Actual Object Size Distribution ... - Semantic Scholar
-1. ) Size (mm). Simulated (Low mag. change). Reconstructed (Low mag. change). Actual p(R) ps(y) (Low deg. of mag. change) pr(R) (Low deg. of mag. change).

1 Determination of Actual Object Size Distribution from ...
as focused beam reflectance measurement (FBRM), optical fiber probe, ...... Liu, W.; Clark, N. N.; Karamavruc, A. I. General method for the transformation of.

1 Determination of Actual Object Size Distribution from Direct Imaging ...
device. As illustrated in Figure 1, the larger the distance between the object and the imaging device, the smaller the size of the object image and hence, the ... However, a reduction in DOF may not always be possible and the sampling time will be ..

1 Determination of Actual Object Size Distribution from Direct Imaging ...
However, a reduction in DOF may not always be possible and the sampling time will be substantially increased with a ..... For normal application of the proposed technique where DOF is an optical property, the DOF of the imaging device will ..... Mart

Learning SURF Cascade for Fast and Accurate Object ...
ever, big data make the learning a critical bottleneck. This is especially true for training object detectors [37, 23, 41]. As is known, the training is usually required ...

Fast Object Detection with Whiten Hog Feature and its ...
close to Matlab. Figure 1 Dog with bounding box (from ImageNet synset). Page 2. Figure 2 Dog HOG visualization. Figure 3 Dog Patch HOG visualization. 2. LDA. The Linear Discriminative Analysis is to find .... down. A couple of good detections are lis

Fast multiple-part based object detection using KD-Ferns
nearest neighbor search which we developed, termed “KD-. Ferns” ... Detecting objects of a particular class in a given image remains a ..... movies taken from a moving vehicle. ... the most relevant section of the dataset for the automotive case.

Object
object (for example 45 degrees) and using a camera, posi tioned at a second .... computer 14 advantageously provided With a storing device. 16, an output ...

Base Quality Distribution - GitHub
ERR992655. 0. 25. 50. 75. 100. 0.0. 0.1. 0.2. 0.3. Position in read. Base Content Fraction. Base. A. C. G. N. T. Base Content Distribution ...

Base Quality Distribution - GitHub
3216700169. 173893355. 24249557863. 24027309538. 0.990835. 222248325. 0.00916505. 3209151. 0.000132339. 2125617. 8.76559e−05. 26154469.

Base Quality Distribution - GitHub
SRR702072. 0. 25. 50. 75. 100. 0.0. 0.1. 0.2. 0.3. Position in read. Base Content Fraction. Base. A. C. G. N. T. Base Content Distribution ...

Distribution Policy.pdf
Oct 5, 2013 - their service to the organization or at any time within five years of the end of that term. Section II: Applying for Distributions. a. Applicants for distributions from the Denver Actors Fund shall submit a written application. includin

Kendall distribution functions
If X and Y are continuous random variables with joint distribution function H, then the Kendall distribution function of (X; Y) is the distribution function of the random variable H(X; Y). Kendall distribution functions arise in the study of stochast

Resource Re-Distribution
Aug 7, 2015 - to develop as a Model Primary Schools in the Gram Panchayat /. Municipality. ... five (5) Secondary. Grade Teachers for Five (5) classes will be provided for ...... Cherukupalli(HE). 28175000309 MPPS Cherukupalli(APP). 23. 0.

Development of Object Tracking Algorithm and Object ...
Now we applied the SSD formula for a vector with 3 components. 2. _. 1. ( , ). ||( (, ). ) ( (, ). )|| .... Fig 3.4: The plot Original values vs. calculated disparity values. 12 ...

OBJECT TECHNOLOGY.pdf
6. a) Explain the object oriented system development by use case driven. approach. 10. b) Explain messages and sequencing used in behavioural diagram. 10.

6.Object oriented programming
data type. The entire set of data and code of an object can be made a user defined type through a class. 8. ... AI and expert systems. • Neural networks and ..... The compiled output file is placed in the same directory as the source. • If any er