|
Torque2D Reference
|
Functions | |
| F32 | dglGetPixelScale () |
| F32 | dglGetWorldToScreenScale () |
| The scale factor of a world unit to a screen unit. | |
| F32 | dglProjectRadius (F32 dist, F32 radius) |
| F32 dglGetPixelScale | ( | ) |
Returns the pixel scale, namely:
viewPort.extent.x / 640.0
| F32 dglGetWorldToScreenScale | ( | ) |
The scale factor of a world unit to a screen unit.
| F32 dglProjectRadius | ( | F32 | dist, |
| F32 | radius | ||
| ) |
Returns the screen length of a line of distance "radius" that is "dist" units away from the camera that is perpendicular to the line of sight, namely:
(radius / dist) * worldToScreenScale