Computer Graphics & Geometry
Ilia A. Bogaevski,
Aizu University, Japan
Edward A. Kopylov,
Moscow State University
Andrei B. Khodulev,
Keldysh Institute of Applied Mathematics RAS
Key words: Cloth modeling, yarn, fiber, woven textile visualization, stochastic ray tracing, virtual goniometrical spectrophotometer, Monte Carlo, anisotropic reflection, BSDF, BRDF.
There are two different approaches widely used in computer graphics to simulate light propagation with objects of random geometry. First deterministic approach is to generate randomly positioned objects and then store this information and process it as ordinary. So, if a ray during ray tracing meets a surface S at a point P then each next ray going through point P will meet the same surface S there. This approach allows us to accurately simulate randomness of a material but it needs memory to keep all the data.
Such approach named explicit geometry modeling with respect to a cloth was implemented in [1] where resultant geometry is approximated by cylinders and fibers are randomly situated in yarn crossections. However, how it was noted in the conclusion, with this approach the randomness is generated conditionally because of efficiency reason and therefore there were differences between measured and calculated data. Let us consider the randomness of cloth geometry in details.
A cloth structure represents both deterministic and statistical elements (Fig. 1). Deterministic elements at the top level are knitting patterns and color of yarns. As we go down with cloth hierarchy we encounter such deterministic elements as number of fibers in a yarn, fiber cross-section shape, attenuation coefficient of the yarn etc. Most significant statistical elements are fiber distributions along the yarn then we also have roughness of the fiber surface etc. This is the area where cloth analysis is expected to be enhanced by statistical approach.
|
|
|
Fig.1. Woven textiles received via scanning electronic microscope Hitachi S800.
The statistical approach realizes the idea of implicit model of a cloth, i.e. that we do not have any explicit geometry: doing ray tracing from fiber to fiber we find stochastically ray-fiber meet point, kind of fiber, normal direction, attributes and geometrical parameters of the fiber.
The statistical approach to light propagation simulation is already successfully used in several areas, for example paint coating design [2, 3, 4] and atmosphere optics [5]. The method's applicability however depends on particular task. The following chapters consider the method's applicability to cloth simulation.
Cloth is assumed to consist of fibers situated stochastically. The distribution of their directions and positions is called specific length, which is defined in detail in chapter 3. The specific length is a function of a fiber direction and a point in the space. This function is equal to zero outside of the cloth.
Stochastic ray tracing provides a base for BSDF calculation by virtual goniometric spectrophotometer (VGSP) [1]. VGSP uses Monte Carlo approach, which in principle does not impose any restrictions on the complexity of light propagation in the simulated cloth. Below is a rough idea of the method.
The directions of initial light rays are chosen in accordance with uniform spherical distribution of incoming light. Rays are stochastically traced in some plain cloth sample until they go out of the cloth or absorbed. The resultant BSDF is a contribution of outcoming rays (
) with respect to corresponding incoming rays (
). Below the idea of stochastic ray tracing algorithm (SRTA) is outlined.
Stochastic ray tracing algorithm generates the nearest intersection of the ray with a fiber (
), the direction of this fiber (
), and the outward normal to the fiber at the point of its intersection with the ray (
) (Fig. 2).
Fig.2. Cloth fiber segment.
The input data for SRTA are the original point of the ray (
), the specific length of fibers at this point, and the original direction of the ray (
). The original point of the ray must be inside of the cloth.
The distance between the original point of the ray and its nearest intersection with a fiber, the direction of this fiber, and its outward normal are random variables. At first the converter to implicit model calculates their distribution functions and then SRTA simulates them. Here we describe only the converter.
After generating the nearest intersection of the ray with a fiber, the direction of this fiber, its outward normal, and the fiber’s kind we need to simulate the result of the interaction of the ray with the fiber. To do it we replace the fiber with its approximating cylinder as it is shown in the figure 3. The length of this approximating cylinder is much more than its radius being equal to the fiber’s radius. Here we assume that the mean bending of the fibers in the cloth is much less than their radius. The position of the approximating cylinder is completely defined by the generated intersection point, the fiber direction, and the normal. (The intersection point with the ray is the middle of an element of the cylinder.) The kind of the fiber is determined by fiber’s direction. It gives the simple and efficient solution suitable for this increment but on the other hand it leads to a restriction on the magnitude of fiber rotation.
Fig.3. Approximating cylinder for cloth fiber.
The simulation of the interaction of the ray and the approximating cylinder can have the following three results: the ray is absorbed by the cylinder, the ray abandons the cylinder through one of its bases, the ray abandons the cylinder through its side surface. The interaction of the ray and the approximating cylinder is solved in accordance with Fresnel’s law similar to the method implemented in [1] until ray left the cylinder or absorbed. Then SRTA is run again.
The specific length of fibers with respect to solid angle and volume or just specific length is our basic characteristic of cloth. It is a function of a fiber direction and a point in the space. The specific length is equal to the mean length of the fibers whose directions and positions are close to given ones. More precisely, let
be a fiber direction (or a point in the unit top semi-sphere
) and
be a point in the space. Let
be a solid angle element containing the direction
,
be a volume element containing the point
, and
be the mean length of all fibers whose directions are in the solid angle element
and which themselves lie inside of the volume element
. In this situation
![]()
where
is the specific length.
The specific visible area of side surfaces of fibers with respect to solid angle and volume or just specific visible area is a function of a ray direction, a fiber direction, and a point in the space. The specific visible area is equal to the mean visible (in the ray direction) area of the side surfaces of the fibers whose directions and positions are close to given ones. More precisely, let
be a ray direction (or a point in the unit sphere
),
be a fiber direction (or a point in the unit top semi-sphere
), and
be a point in the space. Let
be a solid angle element containing the direction
,
be a volume element containing the point
, and
be the mean visible (in the ray direction
) area of the side surfaces of all fibers whose directions are in the solid angle element
and which themselves lie inside of the volume element
. In this situation
![]()
where
is the specific visible area.
The visible specific area is defined by the specific length:
![]()
where
is the visible specific area,
is the radius of fibers,
is the length of the vector product, and
is the specific length.
The total specific visible area of side surfaces of fibers with respect to volume or just total specific visible area is a function of a ray direction and a point in the space. The total specific visible area is equal to the mean visible (in the ray direction) area of the side surfaces of the fibers whose positions are close to a given one. More precisely, let
be a ray direction (or a point in the unit sphere
), and
be a point in the space. Let
be a volume element containing the point
and
be the mean visible (in the ray direction
) area of the side surfaces of all fibers lying inside of the volume element
. In this situation
![]()
where
is the total specific visible area.
The total specific visible area is defined by the specific visible area:
![]()
where
is the unit top semi-sphere and
is the area.
Let us consider a ray with an original direction
and an original point
. The distance
between the original point
and the nearest intersection
of the ray with a fiber is assumed to be a Poisson random variable:
![]()
where
is the total specific visible area and
.
The fiber direction at the point of the nearest intersection of the ray with a fiber is a random variable too. Its probability distribution is assumed to be defined by the specific visible area
at the point
:
![]()
where
is the fiber direction,
is the unit top semi-sphere,
is the area.
Because the ray intersects the fiber,
. In this case for the outward unit normal
to the fiber at the intersection point we get the formula
![]()
where
is the scalar product and
is the projection of the normal to the direction
. It turns out that
is a random variable uniformly distributed in the segment
. Indeed,
is proportional to the distance between the ray and the fiber axis. But this distance is uniformly distributed.
Distribution calculator (DC) finds the specific length for the elaborated explicit cloth model based on primitives. To do it DC divides a periodical element of the cloth into cells with planes which are parallel to the faces of the element (see the figure below). Inside of each cell the output specific length does not depend on a point of the space (only on a fiber direction).
So, let
be a fiber direction
(or a point in the unit top semi-sphere
)
and
be a point in the space.
To compute the value of the specific length DC finds the cell, which contains the point
. Now let us consider the cone with the vertex
, the axis
, and a fixed angle radius
(
):

Fig.4. Cloth sample domain.

DC calculates the total length
of all primitives whose directions
are inside of this cone and whose centers lie in the cell. The unknown value of the specific length is equal to
![]()
where
is the solid angle of the cone and
is the volume of the cell. The directions
(which are inside of the cone) satisfy the condition
.
Rigorously speaking, the specific length is a function of a fiber direction, which is an element of projective plane, and a point in the space. However, it is more convenient to characterize a fiber direction using one of the two possible unit vectors, which are elements of the unit sphere
. Then the specific length is represented by an even function on
(and of a point in the space). We can always choose a unit vector
characterizing a fiber direction from the unit top semi-sphere
:
.
If
are Cartesian coordinates in the space and
are spherical coordinates in our semi-sphere, then:
where
and
.
DC is a procedure computing the value of the specific length at a given point:
.
The computation of specific length value only as soon as we need will be slow down the ray tracing it is required a noticeable time for statistic calculation. As for the approximation with spherical harmonics, it seems not to be good because the corresponding series converge slowly. So we propose to use the tabulation of this function.
This work is supported in part by the Russian Foundation for Basic Research under a grant entitled “Physically accurate solution of global illumination analysis” (98-01-00547) and the Integra Inc.
1. Vladimir V.Volevich, Andrei B.Khodulev, E.Kopylov, Olga A.Karpenko. An Approach to Cloth Synthesis and Visualization. The 7-th International Conference on Computer Graphics and Visualization, Moscow, Russia, May 21-24, 1997.
2. Beard, J., Maxwell, J.R., Bidirectional Reflectance Model Validation and Utilization, Technical Report Number AFAL-TR-73-303, October 1973.
3. Keating, J. D., Comparison of BRDF Models Based on Reflectivity Measurements of Aircraft Paints (U), UNCLASSIFIED, Proceedings of the IRIS Specialty Group on Active Systems, 20-22 October 1987.
4. Bohren, C., Huffman, D., Absorption and Scattering of Light by Small Particles, John Wiley and Sons, New York, 1983.
5. Hansen, J., Travis, L., Light Scattering in Planetary Atmospheres, Space Science Reviews, Vol. 16, pp. 527-610, 1974.
Computer Graphics & Geometry