Property
|
Description
|
Class
|
- <DRM Image Mapping Function>
|
Superclass
|
|
Subclass
|
|
Definition
|
An instance of this DRM class specifies how the given <DRM Image>
instance is to be mapped onto a given textured object,
including the mapping method, the projection, and how
<DRM Texture Coordinate> instances
(if present) are to be treated if they fall outside the image space
bounded by the image indexes (0, 0) and (1, 1).
The image_mapping_method
field specifies how to combine the
referenced texture map with any <DRM Colour>
instances on the textured object.
The image_wrap_s
field specifies whether to clamp or repeat
the given <DRM Image> instance in s.
The image_wrap_t
field specifies whether to clamp or repeat
the given <DRM Image> instance in t.
The image_projection_type
field specifies the type of projection
to be used when applying the given <DRM Image>
instance to textured objects.
If planar projection is specified, the following cases may apply.
-
The DRM object may have
<DRM Texture Coordinate> instances or
<DRM Tack Point> instances, in which case
7.2.42 Image mapping functions and texture coordinates
applies.
-
The <DRM Image Mapping Function>
instance may have
a <DRM Image Anchor> component.
-
The <DRM Image> instance may have
a <DRM Image Anchor> component.
If cylindrical or spherical projection is specified, the DRM object
shall not have <DRM Texture Coordinate> instances or
<DRM Tack Point> instances. Instead, either the
<DRM Image Mapping Function> instance or its
<DRM Image> instance shall have
a <DRM Image Anchor> component.
The intensity_level field specifies
the percent contribution of the <DRM Image Mapping Function>
instance to the total effect on the textured object. For
a <DRM Image> instance with a colour coordinate component
specified by its signature, multiply first, second, and third colour
coordinate values within the texels of the <DRM Image>
instance by this value.
The value of the gain
field is to be added to each colour data
value from the texel data of the given <DRM Image>
instance to obtain the displayed image.
The image_detail_mapping field
specifies whether the
<DRM Image Mapping Function> instance
is used to describe mapping of a detail image on the
textured object.
|
Class diagram
|
Figure 6.134 —
DRM_Image_Mapping_Function
|
Inherited field elements
|
Field name
|
Range
|
Field data type
|
None |
|
|
|
Field elements
|
|
Default field values
|
Default field values for DRM_Image_Mapping_Function
|
Associated to (one-way) (inherited) |
|
Associated to (one-way) |
|
Associated by (one-way) (inherited) |
|
Associated by (one-way) |
|
Associated with (two-way) (inherited) |
|
Associated with (two-way) |
|
Composed of (two-way) (inherited) |
|
Composed of (two-way) |
|
Composed of (two-way metadata) (inherited) |
|
Composed of (two-way metadata) |
|
Component of (two-way) (inherited) |
|
Component of (two-way) |
|
Constraints
|
|
Clarifications
|
None.
|
Example(s)
|
Consider the visualization of a tree. An image of a tree stored
in a <DRM Image> instance is to be mapped onto a rectangular polygon
represented by a <DRM Polygon> instance as depicted in
Figure 6.135.
Figure 6.135 — <DRM Image Mapping Function> example
The <DRM Polygon> instance is composed of:
a <DRM Image Mapping Function> component associated to the
<DRM Image> instance containing the tree data, and composed of
a <DRM Presentation Domain> component with
presentation_domain
= {OTW}.
The fields of the <DRM Image Mapping Function> instance are
specified as follows:
four <DRM Vertex> components, where each <DRM Vertex> component
is composed of:
-
A <DRM LSR 3D Location> component specifying the location
coordinate of the <DRM Vertex> instance, and
-
A <DRM Texture Coordinate> component specifying the
texture coordinate of the vertex onto the texture map.
The texture coordinate values for each vertex map to
the [0,0, 0,0],
[1,0, 1,0] range of
texture coordinate space.
Consider a <DRM Polygon> instance with two
<DRM Image Mapping Function> components. One
<DRM Image Mapping Function> component specifies the
<DRM Image> instance displayed for most cases. The second
<DRM Image Mapping Function> component, if
instance, if image_detail_mapping
is TRUE, specifies the imagery that is added to
the <DRM Polygon> instance when the eyepoint is so close
to the <DRM Polygon> instance that the main <DRM Image>
instance texels are no longer useful for texturing the
<DRM Polygon> instance.
Considering <DRM Polygon> instance D
representing the door of a truck that is painted brown, where
the door has a forestry service logo on it. D
has a <DRM Inline Colour> component that colours the
polygon brown and a <DRM Image Mapping Function> component
F that texture maps the logo onto the surface
of the door representation as follows.
F has
image_mapping_method =
DECAL.
The logo image has 123COLOUR_ALPHA
signature. The logo portion of the image has alpha = 1, the border of the
logo has alpha =
0,5, and the background of the image outside
the logo has alpha = 0,0. When
F is applied to the surface of
D, therefore, the logo replaces the
brown colour since it has alpha = 1, the background of the logo
is replaced by the brown colour since it has alpha = 0, and
the border of the logo blends the logo colour with the
brown colour since it has alpha = 0,5.
|