Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

< Previous PageNext Page > Hide TOC

Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Nonstandard Cubes

Although the default representation for a cubic panorama is six square faces of a cube, it is possible to depart from this standard representation. When doing so, a new atom must be added to the pano sample atom container. The atom type is 'cufa'. The atom is an array of data structures of type QTVRCubicFaceData. Each entry in the array describes one face of whatever polyhedron is being defined. QTVRCubicFaceData is defined as follows:

struct QTVRCubicFaceData {
    float orientation[4]; //see Table 3
    float center[2]; // see Figure 23
    float aspect; // 1.0
    float skew; // set to 0
};
typedef struct QTVRCubicFaceDataQTVRCubicFaceData;

The mathematical explanation of these data structures is beyond the scope of this document but will be described in a separate Apple Technote at http://developer.apple.com/technotes/index.html. Table 1-3 shows what values QuickTime uses for the default representation of six square sides.

The values shown in Table 1-3 will work, since quaternions can be multiplied by -1 and still represent the same orientation. However, it is standard practice to make the largest, and then the first element be positive.

Table 1-3  Values used for representing six square sides

Orientation (quaternion)

Center

Aspect

Skew

w

x

y

z

x

y

+1

0

0

0

0

0

1

0

# front

+.5

0

-.5

0

0

0

1

0

# right

0

0

1

0

0

0

1

0

# back

+.5

0

+.5

0

0

0

1

0

# left

+.5

+.5

0

0

0

0

1

0

# top

+.5

-.5

0

0

0

0

1

0

# bottom

Figure 1-40 shows QTVR cubic values in 2 x 2 and 3 x 3 matrices. These values are represented in a resolution-independent format. In particular, the co-ordinates for the center are in units of one-half of the image height, specifically (height - 1)/2.


Figure 1-40  QTVR cubic values

Figure 1-40 QTVR cubic values



< Previous PageNext Page > Hide TOC


Last updated: 2001-10-01




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Get information on Apple products.
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Copyright © 2007 Apple Inc.
All rights reserved. | Terms of use | Privacy Notice