Advances in Metric-neutral Visualization Charles Gunn Institut für Mathematik Geometry and Visualization Group Technisches Universität Berlin GraVisMa 2010, Brno, October 7, 2010
Overview The talk will cover these new results: Metric neutrality: what it is, and how to realize it in visualization software design. Specific infrastructure innovations: metric-neutral tubing and real-time rendering, and Metric-neutral tracking in an immersive environment.
History In the 19 th century, euclidean geometry (EG) was overthrown as the one true geometry. Not one, but two, different replacements: Projective geometry Noneuclidean metric geometry The Cayley-Klein construction unified these geometries and is foundation of current work.
Projective Geometry Projective geometry (PG) extended EG with ideal points, where parallels intersect. To include new points, homogeneous coordinates introduced. Points: x = (x, y, z, w) Planes: u = [a, b, c, d] Principle of Duality: points and planes are interchangeable. Projective transformations: maps which preserve lines and incidence. Expressed in coordinates: the matrix group PGL(n + 1, R) of invertible real matrices.
Noneuclidean Metric Geometry Are there other geometries satisfying all Euclid s axioms except the Parallel Axiom? Bolyai, Lobachevski, Gauss: yes! (around 1830) Two cases, in all dimensions: Hyperbolic: there is more than one parallel. Elliptic: there are no parallels.
The Cayley-Klein construction Arthur Cayley discovered, and Felix Klein developed, a way to realize euclidean and noneuclidean metric geometries inside of projective geometry. In the 3D case: Begin with a quadric surface in RP 3 written using a diagonal matrix Q ɛ : {x xq ɛ x t = x 2 + y 2 + z 2 + ɛw 2 = 0} Extend it to an inner product between pairs of points: x 0, x 1 ɛ = x 0 x 1 + y 0 y 1 + z 0 z 1 + ɛw 0 w 1
Metric formulae This inner product leads to the following models of noneuclidean geometries (See appendix of article for details.): ɛ metric -1 hyperbolic euclidean 1 elliptic
Metric polarity The polarity on the metric quadric is a correlation that maps a point to its orthogonal complement with respect to the metric: Π(x) := {y yq ɛ x t = 0} This map plays an important role in all computational aspects of this theory. For the noneuclidean cases it is an isomorphism.
The Euclidean case The euclidean quadric is the plane at infinity, a degenerate surface. The euclidean inner product: for points is x 0, x 1 = w 0 w 1 for planes is u 0, u 1 = a 0 a 1 + b 0 b 1 + c 0 c 1 The polarity on the euclidean quadric is not an isomorphism. Polar point of a plane is the point at infinity in the direction normal to the plane (same for parallel planes). Polar plane of every finite point is the plane at infinity. (!)
Isometry groups For a given metric geometry, the subgroup of PGL(n + 1, R) preserving the quadric is called the isometry group of the geometry. Metric Isometry group hyperbolic SO(3, 1) euclidean SE(3) elliptic SO(4) All three groups contain a SO(3) subgroup preserving the origin (0, 0, 0, 1).
Isometries For later reference: A general direct isometry in all 3 geometries can be characterized by a pair of invariant lines, the axes of the isometry. For non-degenerate metric, they are a polar pair. If the isometry fixes one of these lines pointwise, then it is either a rotation or a translation. Otherwise it is a screw motion.
Maniview Visualization of 3D noneuclidean geometry possible since GPU technology supports the full group PGL(4, R). maniview: A 3D manifold viewer (Gunn, SIGGRAPH, 1993). For quotient spaces of H 3, S 3, or E 3 by a discrete group.
Maniview Visualization of 3D noneuclidean geometry possible since GPU technology supports the full group PGL(4, R). maniview: A 3D manifold viewer (Gunn, SIGGRAPH, 1993). For quotient spaces of H 3, S 3, or E 3 by a discrete group.
Maniview Visualization of 3D noneuclidean geometry possible since GPU technology supports the full group PGL(4, R). maniview: A 3D manifold viewer (Gunn, SIGGRAPH, 1993). For quotient spaces of H 3, S 3, or E 3 by a discrete group.
Maniview Visualization of 3D noneuclidean geometry possible since GPU technology supports the full group PGL(4, R). maniview: A 3D manifold viewer (Gunn, SIGGRAPH, 1993). For quotient spaces of H 3, S 3, or E 3 by a discrete group.
Maniview Visualization of 3D noneuclidean geometry possible since GPU technology supports the full group PGL(4, R). maniview: A 3D manifold viewer (Gunn, SIGGRAPH, 1993). For quotient spaces of H 3, S 3, or E 3 by a discrete group.
Maniview Visualization of 3D noneuclidean geometry possible since GPU technology supports the full group PGL(4, R). maniview: A 3D manifold viewer (Gunn, SIGGRAPH, 1993). For quotient spaces of H 3, S 3, or E 3 by a discrete group. Recent rewrite (2005-2010) stimulated the current work.
Metric neutrality We define a metric-neutral visualization system as one which includes euclidean, hyperbolic, and elliptic geometry as equal citizens. Current work is based on the Cayley-Klein construction of the geometries within projective space. Hence, it is restricted to the three constant-curvature cases. Future work: extend to variable curvature (harder!). Previous work: geomview (1990-1995).
Metric-neutral principles The goal: enunciate software design principles to help developers convert existing euclidean visualization software to be metric-neutral. Feature classification Entities and operators can be: Projective: pre-metric Examples: meet and join, incidence properties. Metric-neutral: depend on metric in a uniform way Examples: distance, angle, area, volume, orthogonal complement... Metric-specific: not valid for all metrics Examples: Euclidean free vectors, elliptic Clifford parallels, isotropic scaling (euclidean).
Metric-neutral principles The goal: enunciate software design principles to help developers convert existing euclidean visualization software to be metric-neutral. Feature classification Entities and operators can be: Projective: pre-metric Examples: meet and join, incidence properties. Metric-neutral: depend on metric in a uniform way Examples: distance, angle, area, volume, orthogonal complement... Metric-specific: not valid for all metrics Examples: Euclidean free vectors, elliptic Clifford parallels, isotropic scaling (euclidean).
Metric-neutral principles The goal: enunciate software design principles to help developers convert existing euclidean visualization software to be metric-neutral. Feature classification Entities and operators can be: Projective: pre-metric Examples: meet and join, incidence properties. Metric-neutral: depend on metric in a uniform way Examples: distance, angle, area, volume, orthogonal complement... Metric-specific: not valid for all metrics Examples: Euclidean free vectors, elliptic Clifford parallels, isotropic scaling (euclidean).
Metric-neutral principles The goal: enunciate software design principles to help developers convert existing euclidean visualization software to be metric-neutral. Feature classification Entities and operators can be: Projective: pre-metric Examples: meet and join, incidence properties. Metric-neutral: depend on metric in a uniform way Examples: distance, angle, area, volume, orthogonal complement... Metric-specific: not valid for all metrics Examples: Euclidean free vectors, elliptic Clifford parallels, isotropic scaling (euclidean).
Metric-neutral principles The goal: enunciate software design principles to help developers convert existing euclidean visualization software to be metric-neutral. Feature classification Entities and operators can be: Projective: pre-metric Examples: meet and join, incidence properties. Metric-neutral: depend on metric in a uniform way Examples: distance, angle, area, volume, orthogonal complement... Metric-specific: not valid for all metrics Examples: Euclidean free vectors, elliptic Clifford parallels, isotropic scaling (euclidean).
Cameras are projective This establishes that the projective model of these geometries is the correct model for rendering the insider s view. See article for details!
Software Organization Three software layers based on the degree of user interaction involved: layer No user interaction involved. Interactive layer Traditional interaction, based on mouse. Immersive layer VR-related issues, such as tracking. All solutions discussed here have been implemented in jreality, an open-source, Java-based, metric-neutral 3D scene graph. The metric is an inherited attribute of the scene graph, allowing different metrics to co-exist in the same scene. Example: euclidean museum containing hyperbolic exhibit..
patterns can be grouped into four groups: Geometric representation Geometric operations and modeling Isometries Shading In interests of time, focus on two innovations: tubing and real-time shading.
Tubing jreality renders line sets as thin 3D tubes. These are implemented in a metric-neutral way. Euclidean: A tube is a cylinder. Metric-neutral: A tube is an equi-distant surface. Piece of hyperboloid in elliptic space, and of an ellipsoid in hyperbolic space!
Tubing jreality renders line sets as thin 3D tubes. These are implemented in a metric-neutral way. Euclidean: A tube is a cylinder. Metric-neutral: A tube is an equi-distant surface. Piece of hyperboloid in elliptic space, and of an ellipsoid in hyperbolic space!
Tubing jreality renders line sets as thin 3D tubes. These are implemented in a metric-neutral way. Euclidean: A tube is a cylinder. Metric-neutral: A tube is an equi-distant surface. Piece of hyperboloid in elliptic space, and of an ellipsoid in hyperbolic space!
Tubing jreality renders line sets as thin 3D tubes. These are implemented in a metric-neutral way. Euclidean: A tube is a cylinder. Metric-neutral: A tube is an equi-distant surface. Piece of hyperboloid in elliptic space, and of an ellipsoid in hyperbolic space!
Metric-neutral GPU rendering Real-time noneuclidean shading and rendering Implemented with an OpenGL Shading Language vertex shader All shading operations inner products, distance, light attenuation, fog, reflected directions... handled in metric-neutral way.
Metric-neutral GPU rendering Real-time noneuclidean shading and rendering Implemented with an OpenGL Shading Language vertex shader All shading operations inner products, distance, light attenuation, fog, reflected directions... handled in metric-neutral way.
Metric-neutral Picking Euclidean picking: intersect a ray with a viewing frustum. Intersections are called hits, and are sorted according to distance along the ray. To make this metric-neutral: Replace ray with a projective line segment [P s, P e ]. Must be careful to specify the correct segment: two points determine two segments! Replace the euclidean sorting key with an affine one. Can t use another metric distance since metrics are mixed in the scene graph. Homogeneous coordinates (u, v) for a hit P are the barycentric coordinates of P wrt (P s, P e ): P = up s + vp e. Choose representatives of P s and P e so same-sign (u, v) corresponds to desired segment. Affine coordinate is then v u : 0 at P s and at P e.
Metric-neutral Picking Euclidean picking: intersect a ray with a viewing frustum. Intersections are called hits, and are sorted according to distance along the ray. To make this metric-neutral: Replace ray with a projective line segment [P s, P e ]. Must be careful to specify the correct segment: two points determine two segments! Replace the euclidean sorting key with an affine one. Can t use another metric distance since metrics are mixed in the scene graph. Homogeneous coordinates (u, v) for a hit P are the barycentric coordinates of P wrt (P s, P e ): P = up s + vp e. Choose representatives of P s and P e so same-sign (u, v) corresponds to desired segment. Affine coordinate is then v u : 0 at P s and at P e.
Metric-neutral Picking Euclidean picking: intersect a ray with a viewing frustum. Intersections are called hits, and are sorted according to distance along the ray. To make this metric-neutral: Replace ray with a projective line segment [P s, P e ]. Must be careful to specify the correct segment: two points determine two segments! Replace the euclidean sorting key with an affine one. Can t use another metric distance since metrics are mixed in the scene graph. Homogeneous coordinates (u, v) for a hit P are the barycentric coordinates of P wrt (P s, P e ): P = up s + vp e. Choose representatives of P s and P e so same-sign (u, v) corresponds to desired segment. Affine coordinate is then v u : 0 at P s and at P e.
Interactive tools With metric-neutral picking in place, writing metric-neutral tools is usually just a matter of replacing the construction of a euclidean isometry by the construction of a noneuclidean isometry, based on the same picking information. See article for details.
Metric-neutral immersive environments
There are two main challenges in metric-neutral VR: The scaling problem The tracking problem
Scaling problem Assume we are dealing with a CAVE-like cubical room (2 m edgelength). Immersive environments are characterized by real units (cm, inches, etc). Noneuclidean spaces are characterized by fixed units, too. Example: In a room with unit length = 1 in, hyperbolic space fits in your hand. Cannot apply an isotropic scale to a noneuclidean world! Solution: Use a virtual device in jreality to change the units as tracking data is brought into jreality. Example: Hyperbolic space fits comfortably within a room with unit length = 5 m Be careful to update dependent variables, such as eye separation.
Tracking problem Traditional tracking systems provide a euclidean isometry to represent position and orientation of tracked observers and objects: F e = T e R e where T e is a translation and R e is the orientation. Standard tracking uses T e to move an off-axis camera to the eye-position P and render images for the walls Orientation part R e used only for L/R eye difference. Replace the euclidean isometries with noneuclidean ones. Construct the unique noneuclidean translation T n which moves the origin (0, 0, 0, 1) to P, and use it instead of T e to move the camera into position.
Tracking problem, cont. All rendered views remain valid noneuclidean views for the inside observer! Example As a hyperbolic observer moves away from an object, it decreases exponentially quickly in apparent size, as it should in hyperbolic space. Thought experiment: include the room in the scene graph. What does an observer see as he moves around? The euclidean observer should see that the virtual room remains glued to the real room. The noneuclidean observer, not. See article for figures and details. Also, see article for discussion of metric-neutral treatment of the orientation part of the tracking info (for wands and other pointing devices).
Metric-neutral 3D GUI jreality allows embedding 2D Java GUI in 3D scenes in a metric-neutral way.
Further directions Strategy: identify metric-neutral features and extend the euclidean functionality accordingly. Homogeneous model of geometric algebra work in progress. Kinematics Rigid body motion Subdivision surfaces
We have introduced and characterized a metric-neutral visualization system as one that supports infrastructure, interaction, and immersion for euclidean, hyperbolic and elliptic metrics. Description of a number of specific innovations, including: metric-neutral tubing, metric-neutral realtime shading, and metric-neutral tracking. Provides researchers and educators with significant improvement in the quality and ease of visualization. A tool to deepen appreciation of the manifold connections among these three fundamental geometries.
Notes Thank you for your attention. These slides may be found at: http://www.math.tu-berlin.de/~gunn