Post on 03-Jun-2018
transcript
8/12/2019 Volume Visualisation
1/18
5/12/20
Volume Visualization
akjha@iirs.gov.in
Visualization Building Blocks
Viz ElementsGlyphs (e.g. Alphabets,
Arrows)
Lines
Triangles
Voxels* (volume element)
*Cannot be directly
represented on
displays
Viz AttributesTransforms
(Position, Rotation, Scale)
Color
Opacity
View AttributesViewpoint
Projection
(Orthographic, Perspective)
Canvas
Viz ReinforcementTexture
Light
Distortion(e.g. Displacement)
Motion (e.g. Camera ,time steps)
Filter (e.g. threshold, resample, subset, slice, clip)
Add Context(e.g. Connectivity, Mao Overlay)
8/12/2019 Volume Visualisation
2/18
5/12/20
Geometric Visualization Process
Identify regions of same scalarvalue
Utility
2D:Contours
3D:Isosurfaces(Marching Cube,Marching Tetra)
Volume Visualization
To create two-dimensional graphical
representations from scalar datasets that are
defined on three-dimensional grids. E.g.
seismic data to fluid dynamics.
shape (given by the geometry of the grid)
appearance (given by the scalar values or color,
texture, lighting conditions, etc.) Type
Direct volume rendering (DVR)
Direct mapping of voxels on pixels of a 2D image
plane
Indirect volume rendering- or surface-fitting(SF)
Surfaces Creation & used for interactive display
8/12/2019 Volume Visualisation
3/18
5/12/20
How to Visualize the volume dataset?Four Common Methods
Point Cloud Slicing Plane
Isosurface Volume Render
Point Cloud Map each data value to a color. This mapping is called a Color Map.
Display each data value as a point.
Often leads to occlusion. Here is an example that shows only data valuesgreater than 0.3.
0.0 1.0
Color Map
Point cloud of foot dataset
8/12/2019 Volume Visualisation
4/18
5/12/20
Slicing Plane Display a 2D plane as a slice through the 3D dataset.
The 2D plane could be a regular grid, where each pointcorresponds to a point in the 3D space which it slices.
Linearly interpolate the triangles to color the entire 2D slice.
0.0 1.0
One slice of the foot dataset
Color Map
An axis-aligned slicing plane
Isosurface
Select a data value, called an isovalue.
Draw the 3D contour of this value.
A contour simply joins all the points having this samedata value. In 2D, a contour is a line.
In 3D, a contour is a surface, called an isosurface.
Method: Marching cubes The 3D regular grid is considered to be made of atomic
cubes.
Each cube has 8 corners. Each corner corresponds to adata point, and has a value.
8/12/2019 Volume Visualisation
5/18
5/12/20
Marching Cubes AlgorithmVertex Identification
For each corner, mark the corner is 1 if the data value at that corner ishigher than the isovalue, 0 otherwise.
Then, draw surfaces separating the 1 corners from the 0 corners.
There are 16 cases.
Generate triangles for each cube. They will all join together to form anisosurface (assuming we take care of the ambiguous cases).
Example Marching Cube cases
Marching Cubes AlgorithmVertex Value
Linear interpolation between vertices.
Suppose, Data value at v0 is d0,
Data value at v1 is d1
Isovalue is d, and d0 < d < d1
Then, the triangle vertex on this edge v0v1 that is part of the isosurface is:v = (d-d0)/(d1-d0) x v1 + (d1-d)/(d1-d0) x v0
v0
v
v1
8/12/2019 Volume Visualisation
6/18
5/12/20
Optimization: Octree
Marching cubes algorithm is very slow. You have to go through the entire dataset to search for cubes that contain
the isosurface.
To speed things up, use some data structure to help search.
One such data structure is the octree.
Continuously sub-divide dataset into 2x2x2 cubes. In each cube, store themaximum and minimum value.
When drawing an isosurface of value v, traverse the octree. Whenever youreach a node whose range does not contain v, you need to search nofurther down this node.
Volume Rendering
Treat volume as a translucent object.
For every pixel, shoot ray into the 3D volume.
Sample the each ray at small, regular intervals.
At each sample, calculate color and composite.
8/12/2019 Volume Visualisation
7/18
5/12/20
How do you calculate color?
How do you composite?
1. At each sample, get the data value.
Data value obtained by tri-linear interpolation.
2. After getting data value, get color and opacity.
Color obtained from color map.
Opacity obtained from opacity map.
3. Get the normal
Normal approximated by data gradient
Data gradient approximated by central difference
4. Calculate color using lighting
5. Composite. Update the accumulated opacity.
The following slides will elaborate each of these steps
1. Tri-linear Interpolation to get Data Value
a
b
c
d
m
n
P
1
2What is the data value at point P?
First, find the data values at a, b, c and d.
The value at a, for example, is obtained from
linearly interpolating the values at point 1 and
point 2.
Then linearly interpolate a and b to get m.
Similarly, obtain the data value at n.
Finally, linearly interpolate m and n to get the
final data value at P.
8/12/2019 Volume Visualisation
8/18
5/12/20
2. What is an Opacity Map?
Have an opacity value associated with each data value. User specifies a more opaque value for the data value that he/she is
interested in.
For example, if the value for bone is around 0.4, and the value for skin isaround 0.1, the user may wish to use the following opacity map to see thebone through translucent skin.
Opacity
1.0
Data value1.00.1 0.4
3. Approximate surface normal
Surface normal is usually in the direction of thechange of data value.
To get the direction of change of data value, usecentral difference.
Vz+1
Vy-1
Vx-1
Vy+1
Vz-1
Vx+1P
To find the normal at point P:
Consider the six adjacent data points.
Let the value at the next point along the x axis be denoted as V x+1.
Similar notation for the other five points.
Then, the normal at point P is N = (Vx+1-Vx-1,Vy+1-Vy-1,Vz+1-Vz-1).
8/12/2019 Volume Visualisation
9/18
5/12/20
4. Calculate lighting
Calculate lighting using the lighting equations.
We have the color from the color map, C.
We have the normal from the central difference, N.
Assume that the light is white, and is in the direction
L.
Assume that we use only diffuse lighting.
Then, the color seen by the camera is: Cx N.L
5. Consider opacity
We have to diminish the color at each sample point because itis translucent.
To do this, we accumulate color and opacity.
In the beginning,
Coloraccumulatedis set to (0,0,0), and
Opacityaccumulatedis set to 0.0
At each sample point, update Coloraccumulatedby:Coloraccumulated+= (1Opacityaccumulated) xax C x N.L
At each sample point, update Opacityaccumulatedby:
Opacityaccumulated+= (1Opacityaccumulated) xa
whereais the opacity of the sample point from the Opacity Map,
C is the color of the sample point from the Color Map,
N is the unit normal at the sample point from central difference, and
L is the unit vector from the sample point to the light source.
8/12/2019 Volume Visualisation
10/18
5/12/20
Techniques for examining sub-section
of Volume
Slicing
To examine scalar fields
2 dimensional slice plane
Isosurfacing
Isosurfaces are 2D
surfaces
Transparency
Volume materialattenuates reflected
Modern 3D maps
Computer-generated perspective views with
cartographic content are called 3D maps.
8/12/2019 Volume Visualisation
11/18
5/12/20
Design Variables of 3D Maps
Modelling Modelling of digital terrain model objects
Modelling of (topographic) map objects
Modelling of orientating map objects
Symbolization
Graphic appearance
Special graphic aspects
Textures
Text objects
Object animation
Visualization
Perspective (projection)
Camera (viewing) Lighting
Shading and shadow
Atmospheric effects and natural phenomenon
3D Design Requirements
8/12/2019 Volume Visualisation
12/18
5/12/20
3D Visualization pipeline
View-dependent, multi-perspective view
8/12/2019 Volume Visualisation
13/18
5/12/20
LoD
LoDs are mainly determined in relation tothe resolution of sensor data, the precisionof semantic information and the relevantapplication
LoDs for settlements and buildings-Thiemann, (2004) LoD1 = aggregated settlement blocks with a
uniform height
LoD2 = block of the individual buildingswithout roof form
LoD3 = LoD2 enhanced with a simplified roofform
LoDs for individual buildings-Netlexikon vonakademie.de LoD1 = Popping up of the ground plan to a
uniform height
LoD2 = LoD1 enhanced with a texture
LoD3 = External hull of the building with aroof form and small surface elements
LoD4 = LoD3 enhanced with external textures
LoD5 = LoD4 enhanced with internalstructures
LoDs of 3D landscapes-Grger et al., (2004) LOD 0 = A digital terrain model with draped
orthophoto and classification of land use,
LOD 1 = Popping up of the ground plan to auniform height,
LOD 2 = LoD1 enhanced with roof textures,roof structures and vegetation features,
LOD 3 = Architecture models with vegetation
features and street furniture LOD 4 = Indoors architecture models.
3D Buildings
3D buildings is
essentially a linear
continuum
an arbitrary number of
milestones can be said
to exist referred to asLevels of Detail (LoD)
there are no generally
agreed LoDs for 3D
buildings
8/12/2019 Volume Visualisation
14/18
5/12/20
3D Building Generalization
Need
3D building models are too time intensive and
expensive for 3D data acquisition and updating.
high maintenance cost and difficulties for the user
in conducting multi-scale spatial analysis
Modelgeneralization
graphic (or
cartographic)
generalization
3D
Generalization
3D Building Generalization steps
Model generalization
Is a data-to-data transformation that deals with modelobjects, their geometric and semantic precision and theirtopological consistency in the scale space.
Generalized building models are either distributed as dataservices for integration with thematic information of
comparable resolution or regarded as a prior stage tographic generalization
Graphic (or cartographic) generalization
focuses on the visual impression of model objects togetherwith 3D graphic artifacts in relation to the selectedprojection, visualisation style, camera position etc.
8/12/2019 Volume Visualisation
15/18
5/12/20
Description Models of 3D Buildings
Voxel model Parametric description
3D building is constructed through a number of primitivebodies such as cuboid, sphere, cylinder, cone and pyramid-sub components of the structure called geons
absolute position of the building is defined by six furtherparameters of rotation and translation
Constructive solid geometry (CSG) 3D building is constructed through Boolean operations
such as intersection, difference, union or inversion ofelementary building parts
sequence of operations is stored in a CSG tree
Description Models of 3D Buildings
CSG-tree of a building
Boundary Representation
3D building is described by itsboundary surface usingtopological elements such asmesh, edge and vertex.e.g.TIN,VRML
Solid representation (SRep)
3D building is described by aTetrahedral Network
(TEN) composed of theregular or irregulartopological elements:tetrahedron, triangle,edgeand vertex
8/12/2019 Volume Visualisation
16/18
5/12/20
3D building Structure
LOD based- Successive refinement of 3Dbuilding structures based on viewing
distance
The nearer the building objects, the more
details they reveal
Individual- Structural components of
a typical building
3D Building Generalization steps
Segmentation of
building structures
polyhedron
segmentation-feature-
finding
Recognition of 3Dbuilding structures
Segmentation of a sample building with split
planes
Types of ground plan in the top row; Roof types in the middle
and bottom row
8/12/2019 Volume Visualisation
17/18
5/12/20
3D Building Generalization steps
Building Clustering
Hirachial approach classification of
neighbourhood relationshipsand the detection of buildingclusters
Model generalization of 3Dbuildings simplification ofbuilding
data, is introduced
Simplification of parallelstructures
Squaring of inclined roof-facets
Automatically recognised 3D building clusters
Parallel facets under a certain distance are
shifted towards each other
Squaring of roof
3D Building Generalization steps
simplification based on parallel shifts
Results of the roof-squaring procedure
8/12/2019 Volume Visualisation
18/18
5/12/20
3D Building Generalization steps
Graphic generalization
of 3D buildings
Invasive simplification of
3D buildings
reducing and adjusting
the geometric details of
3D buildings
Non-invasive
simplification of 3D
buildings
Presentation based on standard illumination
(left), presentation based on expressive line
drawing (right)