19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

28
1 06/20/22 16:40 Graphics II 91.547 Volume Rendering Session 10

Transcript of 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

Page 1: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

104/19/23 17:23

Graphics II 91.547

Volume Rendering

Session 10

Page 2: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

204/19/23 17:23

What do we mean by “volume rendering”?Conventional rendering:

Bicubic Parametric Patches

Polygons

3D Structured Objects

2D Image

I x y( , )

Page 3: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

304/19/23 17:23

What do we mean by “volume rendering”?The starting point:

V x y z( , , )Scalar Field:

Page 4: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

404/19/23 17:23

Volume Rendering:Options for presentation of the data

Cutaway, or cross section Isosurface

Page 5: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

504/19/23 17:23

What do we mean by “volume rendering”?What the samples mean:

Voxel with samplesat vertices.

Voxel with sampleat center.

Page 6: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

604/19/23 17:23

What do we mean by “volume rendering”?The process:

V x y z( , , )

V x y z( , , )

Structured 3DModel

3D Scalar Field

3D Scalar Field

2D Scalar Image

Page 7: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

704/19/23 17:23

Data volume geometries

Cartesian - (also known as a voxel grid) cubic data elements,axis aligned Preferred

Regular - same as cartesian, except that the cells are rectangular,i.e. different sizes along different axes Most medical data

Rectilinear - aligned to axes, but distance between cells alongeach axis can vary

Structured or curvilinear non rectilinear, but cells are hexahedra rectangular warped to fill a volume or to fit aroundan object Often used in CFD

Unstructured - no geometric constraints imposed

Page 8: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

804/19/23 17:23

Early Volume Visualization TechniquesHerman & Liu 1979

V x y z k( , , ) Establish a threshold:

Binary Partitioning of the volume:

2D Slice:

“Boundary” Voxels are considered opaque cubesand rendered by standard lighting model.

Inside

Outside

Page 9: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

904/19/23 17:23

Improving the blockiness of the image:The gradient operator

V x y z k( , , )

V x y z

V

x

V

y

V

z

( , , )

0

Page 10: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1004/19/23 17:23

V x y z

V x y z V x y z

V x y z V x y z

V x y z V x y zi j k

i j k i j k

i j k i j k

i j k i j k

( , , )

[ ( , , ) ( , , )]

[ ( , , ) ( , , )]

[ ( , , ) ( , , )]

12 1 1

12 1 1

12 1 1

0

Approximating the gradient numerically:

Page 11: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1104/19/23 17:23

Projecting from Contour Data:Pizer 1986

y j

y j 1

V x y z k( , , )

Polygon structure generated by “skimming”

Page 12: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1204/19/23 17:23

Topological problem withPizer approach: branching structures

Page 13: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1304/19/23 17:23

The “Marching Cubes” AlgorithmLorenson & Cline 1987

Inside

Outside

Page 14: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1404/19/23 17:23

The “Marching Cubes” Algorithm

V x y z k( , , )

V x y z k( , , )

V x y z k( , , )

Page 15: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1504/19/23 17:23

The “Marching Cubes” AlgorithmPossible Vertex States

Page 16: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1604/19/23 17:23

The “Marching Cubes” AlgorithmGenerated contour

Page 17: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1704/19/23 17:23

Generation of contour from subcontours

Page 18: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1804/19/23 17:23

Generation of contour from subcontours:Disconnected regions

Page 19: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

1904/19/23 17:23

Marching Cubes AlgorithmPossible Polygon Arrangements

Page 20: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2004/19/23 17:23

Marching Cubes AlgorithmPossible Polygon Arrangements

Page 21: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2104/19/23 17:23

Marching Cubes

Direction of march

Current cube Previously dealt with

New vertex

Page 22: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2204/19/23 17:23

Weaknesses of Intermediate Structure Methods

0 Can impose a structure on the data which does not exist, per se.- Selection of a “constant” implies a binary decision on the

existence of an intermediate surface that should be extracted and rendered

- Could just be a gradual transition in density through the medium

0 Not feasible to visualize structures within structures0 Does not handle objects that would intrinsically be

transparent such as fluids, clouds

Page 23: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2304/19/23 17:24

Volume rendering by ray castingBlinn 1982/Kajiya 1984

0 Volume made up of small spherical particles that both scatter (reflect) and attenuate light

0 Parallel rays are cast from viewer into the volume.- At each point, the progressive attenuation due to the

particle field is calculated- Light scattered in the eye direction from the light

source(s) is calculated at each point- These values are integrated along the ray and a single

brightness value at the eye is calculated

Page 24: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2404/19/23 17:24

Scattering/Attenuation Model

Light Source

D x y z( , , )

t1 t2t

Eye Point

D x t y t z t D t

I x t y t z t I t

( ( ), ( ), ( )) ( )

( ( ), ( ), ( )) ( )

Density:

Illumination:

Light scattered along R in direction of eye from point at t:

R

I t D t P( ) ( ) cos

Page 25: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2504/19/23 17:24

Scattering/Attenuation Model

Attenuation of light scattered from point t: exp ( )

D s dst

t

1

Summing the intensity of light arriving at the eye along R fromall of the elements:

B D s ds I t D t P dtt

t

t

t

exp ( ) ( ) ( ) cos 11

2

Page 26: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2604/19/23 17:24

Additive ReprojectionLevoy 1988

R

V x y z( , , )

C R k

R k

( , )

( , )

C R( )

Image Plane

Page 27: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2704/19/23 17:24

Additive ReprojectionLevoy 1988

Determining the color of a voxel: C i j k( , , )

Calculated using the Phong model, assuming that the normal is given by the gradient: V x y zi j k( , , )

f1 f2 f3 f4

f 1

f 2

f 3

f 4

( )X

V X( )

Determining the opacity: ( , , )i j k

Page 28: 19/18/2015 08:34 Graphics II 91.547 Volume Rendering Session 10.

2804/19/23 17:24

Additive ReprojectionLevoy 1988

CinCout

C R k

R k

( , )

( , )

C C R k C R k R kout in ( ( , )) ( , ) ( , )1

TransparencyTerm

OpacityTerm

C R C R k R k R ii k

K

k

K

( ) ( , ) ( , ) ( ( , ))

110

kth voxel along R