capabilities.pixelAspectRatio Property | Flash 6 |
the width-to-height ratio of a pixel on the screen | read/write |
The floating-point pixelAspectRatio property indicates the proportions of a single pixel on the screen. It is the ratio of a pixel's width to its height. For example, on screens where pixels are half as wide as they are high, pixelAspectRatio will return .5 (1/2). On most desktop computers, pixels are square, so pixelAspectRatio is 1.
The pixelAspectRatio property lets a movie compensate for potential distortion caused by the aspect ratio of the pixels on the playback device. For example, a circle with a constant radius will appear as an ellipse on devices whose pixel aspect ratio is not 1. On a device with pixels twice as wide as they are high, you might load an alternate movie authored at half of the original width so that the final output displays correctly. At the time of this writing, pixelAspectRatio always returns 1, and the development process for nonsquare pixel devices is not yet determined. Always test on the target device to ensure correct appearance at a nonunity aspect ratio. More information will be provided by Macromedia when it becomes relevant.
The corresponding server string for pixelAspectRatio is AR, with a value of a floating-point number, such as 1.0.
Macromedia's documentation for Flash MX incorrectly claims that the server string for pixelAspectRatio is PAR. The correct server string is AR.
capabilities.screenDPI, capabilities.screenResolutionX, capabilities.screenResolutionY