Download presentation
Presentation is loading. Please wait.
Published byFrank Matthews Modified over 9 years ago
1
Scientific Visualization An Introduction Michel O. R. Eboueya Computer Sciences Department Pôle Sciences et Technologies Université de La Rochelle
2
2 Outline Introduction:Definitions, Goals and History of Visualization Part 1 –Visualization Concepts –Characterization of data and Short Vocabulary –Algorithms (Scalars, Vectors, Direct volume rendering ) Part 2 –Visualization Techniques –Advanced topics (Virtual reality,Texture ) –Scientific Visualization Tools (Some commonly used programs ) Conclusion
3
3 Algorithms Scalar Algorithms Color Mapping Contouring (contour tracking, Marching squares, cubes…) scalar generation Vector Algorithm Hedgehog and Oriented Glyphs Warping Displacement Plots Time Animations Streamlines Modeling Algorithms Implicit Functions Glyphs Cuttings
4
4 Algorithms scalar data types possess a magnitude, but not directional information other than a sign; they are simply defined as single numbers. Same as quantitative data types in this text. vectors have direction and magnitude. Quantitatively, their mathematical presentation requires a number of scalar components equal to the dimensionality of the coordinate system. In general, a vector is a unified entity, which implies the problem of displaying independent, multivariate scalar fields. thresholding A technique used primarily with surface rendering, in which a density value of the interface between two materials in the dataset is selected so that the interface surface can be identified for rendering.
5
5 Cells specify Topology Vertex Polyvertex Line Polyline Triangle Triangle Strip Quadrilateral Polygon Tetrahedron Hexahedron Voxel
6
6 There are two alternative methods of dividing a volume dataset into data elements. Voxels. A voxel is an area of constant value surrounding a central grid point Cells. The cell approach views the volume as a collection of cells whose corners are grid points and whose value varies between the grid points.
7
7 Cells Cell is defined by an ordered list of points –Triangle, quadrilateral points specified counter clockwise –Others as shown 0 1 2 3 0 1 2 3 4 5 6 7 Tetrahedron Hexahedron
8
8 Meshes are made of Cells Cells can be many different shapes and sizes –e.g. in 2D: Triangles, Quadrilaterals, etc –e.g. in 3D Tetrahedra, Hexahedra, Pyramids, etc. Meshes can consist of one or more types of cells Triangle Quadrilateral TetrahedronHexahedron Prism Mesh
9
9 Organizing structure plus attributes –Structured points –Rectilinear Grid –Structured Grid Datasets
10
10 Unstructured Grid A collection of vertices, edges, faces and cells whose connectivity information must be explicitly stored
11
11 How are unstructured meshes different than regular grids? Regular Grids –e.g., Cartesian grids, logically rectangular grids –mesh info accessed implicitly using grid point indices Efficient in both computation and storage –typically use finite difference discretization Unstructured Meshes –mesh connectivity information must be stored Incurs memory and computational cost –handles complex geometries and grid adaptivity –typically use finite volume or finite element discretization –mesh quality becomes a concern
12
12 Algorithms Scalar Algorithms Color Mapping Contouring (contour tracking, Marching squares, cubes…) scalar generation Vector Algorithm Hedgehog and Oriented Glyphs Warping Displacement Plots Time Animations Streamlines Modeling Algorithms Implicit Functions Glyphs Cuttings
13
13 Color Mapping Use a Table Looku table. un tableau de trois couleurs(RVB par exemple). On associe a la table un minimum et un maximum,le domaine de variation du scalaire (min, max.). Avec si valeur scalaire et i un indice de la table de consultation, If (si < min) then i=0; If (si >max ) theni = i -1; i = (si - min)/ (max. - min); Another way: Use a Colormap: a function that maps data values to colors.
14
14 Common Steps in Volume Visualization Algorithms Several of the steps are common to all the algorithms and most of the algorithms contain a subset of the steps discussed here. The steps are as follows: 1.Data acquisition either via empirical measurement or computer simulation. 2.Put the data into a format that can be easily manipulated. This may entail scaling the data for a better value distribution, enhancing contrast, filtering out noise, and removing out-of-range data. The same set of operations must be applied to all the data slices. 3.The data is mapped onto geometric or display primitives. 4.The primitives are stored, manipulated, and displayed.
15
15 The two main approaches to visualizing volume data sets which will be considered in the following sections are: Surface rendering. This method involves constructing surfaces in the datasets and using standard computer graphics techniques to render them. Volume rendering. Here each data element is assigned a colour and opacity value. Rays are then `fired' into the volume from an imaginary image plane and the colour and opacity values are summed along the ray. –Classification and shading –Ray casting –Splatting
16
16 Countouring :Visualization of Attributes 2D contours lines and 3D Isosurface 110 4 8 Contour Value is 5
17
17 Contouring 2D or contour tracking in 2D In the figure, the isovalue is 5. Detect an edge intersection(i.e.) the contour passes through an edge) And track this contour as it moves across cell boundaries. If a contour enter a cell, it muts exit the cell as well. The contour is tracked until it closes back on itself, or exits a dataset boundary
18
18 Contouring example
19
19 Contouring 3D Assumes Volume Contains Thin Boundary Surfaces Classify All Cells as Inside, Outside, or "On" The Surface Fit Constant-value Surfaces to All "On" Cells Render Surfaces
20
20 Contouring 3D Contour Connecting is an object-ordered Surface Fitting method. Given a threshold value, a closed contour is traced for each data slice and then the contours in adjacent slices are connected and a tesselation, usually of triangles, is performed.
21
21 Contouring or Contour Tracking Here is an example of a contoured head that is then tesselated.
22
22 Marching Squares In this algorithm the user first specifies a threshold value. For this value, some voxels will be entirely inside or outside the corresponding isosurface and some voxels will be intersected by the isosurface. In the first pass of the algorithm the voxels that are intersected by the threshold value are identified. In the second pass these voxels are examined and a set of one or more polygons is produced, which are then output for rendering. Each of the voxel's 4 vertices can be either inside or outside of the isosurface value, thus, there are 2^4 = 16 possible ways in which a surface can intersect the voxel.
23
23 Marching Squares Select a cell Calculate inside/outside state for each vertex of the cell Create an index by storing the binary state of each vertex in a separate bit Use the index to loukup the topological stateof all cell in a case table Calculate the contour location for each edge in the case table
24
24 Marching Squares
25
25 Marching Cubes In this algorithm the user first specifies a threshold value. For this value, some voxels will be entirely inside or outside the corresponding isosurface and some voxels will be intersected by the isosurface. In the first pass of the algorithm the voxels that are intersected by the threshold value are identified. In the second pass these voxels are examined and a set of one or more polygons is produced, which are then output for rendering. Each of the voxel's 8 vertices can be either inside or outside of the isosurface value, thus, there are 2^8 = 256 possible ways in which a surface can intersect the voxel.
26
26 Marching Cubes Marching Cubes Algorithm 1.User Specifies Threshold Value 2.(?Read Four Slices Into Memory 3.Scan Middle Two Slices and Create a Cel?)l 4.Classify Eight Vertices. Construct Index Number. 5.Use Index to Look Up List of Edges 6.Find 3 Surf/Edge Intersections via Linear Interpolation 7.Calculate Unit Normal (Gradient) at 3 Intersections 8.Output the Triangle Vertices and Vertex Normals
27
27 Edge Intersection Table : 256 Cases Reduce to 15 using symetry By symmetry these 256 ways can be reduced to 15. The exact edge intersection points are determined and the polygons are created. Use a Table Lookup to Reduce Edge Intersection Tests Basic Idea For Each Cell Through Which an Isosurface Passes Create Small Polygons Approximating the Surface Within the Cell Surfaces Intersect Edges Where Vertices Bracket the Threshold Maximum of 1 Intersection
28
28 Marching Cubes ambiguity Arbitrarily closing Marching Cubes cases leads to holes in the isosurface
29
29 Iso surface of human skull
30
30 Marching Cubes Complementary cases 3C 6C 7C 10C 12C 13C
31
31 Marching thétrahédra
32
32 Dividing cubes This is similar to the Marching Cubes algorithm except that when a voxel is determined to be intersected by the isosurface, it is projected to the image plane. If it projects to a single pixel or smaller, than it is just rendered as a point, else it is subdivided into surfaces as with the Marching Cubes algorithm. Basic Idea: Create "Surface Points" Instead of Triangles Associate Surface Normal with Each Surface Point Surface Points, When Rendered, Add Pixel Size Subdivide Cells as Necessary
33
33 Dividing cubes Subdivide Cells as Necessary Eliminates Scan Conversion Step Point Cloud Rendering Randomly Ordered Points No Topology
34
34 Dividing cubes Dividing Cubes Algorithm User Specifies Threshold Value Read Four Slices Into Memory Compute Gradients Divide Cells Into AxBxC Cubes. Resample Test for Surface Intersections Interpolate Gradient Vectors Where Needed Shade Cube Rotate/Project Each Cube & Paint Pixel
35
35 Surface-fitting Fundamentals Surface-fitting Advantages –Rendering Methods are Known: Shadows, Depth Cueing, Reflections, etc. –Render in Hardware –Display List in Memory –Changing View/Light(s) Requires Only Rendering –Compact Storage & Transmission –Good Spatial Coherence for Efficient Rendering Surface-fitting Disadvantages –Requires Binary Classification –Throws Away Data Between Surfaces –False Positives and Negatives –Handles Small Features Poorly –Can't Handle Branching –User Intervention Sometimes Required –30 Minutes to Extract 500,000 Triangles
36
36 Scalar generation Normalisez dot product Si = (P1 – P0).(Ph - PL) ------------------------ /Ph – PL/^2 Given a oriented line starting Po (see level) and ending Ph(mountain top) Si is the elevation Figure of terrain data from Honolulu Hawai.
37
37 Other scalar algorithm: carpet plots Exponential Cosine fonction f(r)= e-r cos(10r)
38
38 Algorithms Scalar Algorithms Color Mapping Contouring (contour tracking, Marching squares, cubes…) scalar generation Vector Algorithm Hedgehog and Oriented Glyphs Warping Displacement Plots Time Animations Streamlines Modeling Algorithms Implicit Functions Glyphs Cuttings
39
39 Representing Vectors As vector data has several values at any one point, the values must be encoded before they can be visualized. There are several different ways of doing this: Extract a single component of the data. Extract the magnitude of the vector. Calculate the divergence of the field.
40
40 Representing Vectors : Visualization of Attributes Vectors –Oriented Lines –Oriented Glyphs –Streamlines
41
41 Vectored Field Vectors(2d,3d domain): Arrows or other icons used to display vectors at the grid points when displaying a vector field.
42
42 Representing Vectors : hedgehog hedgehog : The arrow length is used to represent the magnitude of the vector at each point. The shaft direction represents the direction of the vector field at a particular point in the grid. A variation on the basic hedgehog idea is the unit hedgehog. Here each arrow shaft has exactly the same length. This reduces the problems with occlusion, although it does not eliminate the problem entirely. The basic hedgehog uses the length of the arrow shaft to represent the magnitude of the vector. As the arrow shafts of unit hedgehogs are all the same length some other method is required to represent the magnitude. The most common method of representing the magnitude of unit hedgehogs is with colour.
43
43 Particles and Streak line Particles(2d,3d domain): Moving points show the motion of tiny (usually weightless) objects in a vector field. Streak line or Trace (2s, 3d domain):Shows the path that a particle will take in a vector field.
44
44 Streaklines Streaklines or set of particles trace at a particular time t that has passed in a specified point x. Stream lines in a travels through the office and exist through an exhaust duct
45
45 Streamlines and Stream tubes A streamline is a line that is tangential to the instantaneous velocity direction (velocity is a vector, and it has a magnitude and a direction). Another way to visualize flow patterns is by streaklines. A streakline is the line traced out by all the particles that passed through a particular point at some earlier time. For instance, if we issued fluorescent dye continuously from a fixed point, the dye makes up a streakline as it passes downstream. To continue the freeway analogy, it is the line made up of the lights on all the vehicles that passed through the same toll booth. If they all follow the same path (a steady flow), a single line results, but if they follow different paths (unsteady flow), it is possible for the line to cross over itself. In unsteady flow, streamlines, pathlines and streaklines are all different, but in steady flow, streamlines, pathlines and streaklines are identical.
46
46 Stream tubes Stream tubes in a travels through the office and exist through an exhaust duct. The radius of the stream tube varies accordingly to flow velocity. Slower speeds results in fatter tubes; larger speeds result in thinner tubes
47
47 définitions () Animate: Provides flow control for time series data, to produce a movie of sequential time frames. Axes: displays axes. Help understand where the data is Bounding box: the smallest axis-aligned box containing the data. Colormap: a function that maps data values to colors. Crop: Restrict area of data to be used. Labels: Text used to annotate visualization
48
48 Volume de visualisation Volume Visualization(3d domain): Displays volumetric (3D-mesh) data by showing a color, greyscale or object at every grid point. Usually uses transparency to show as much data as possible.
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.