|
MayaFlux 0.3.0
Digital-First Multimedia Processing Framework
|
| MAYAFLUX_API glm::vec3 MayaFlux::normalize_coords_aspect | ( | double | window_x, |
| double | window_y, | ||
| uint32_t | window_width, | ||
| uint32_t | window_height | ||
| ) |
Normalize coordinates preserving aspect ratio (useful for circular/square shapes)
| window_x | X coordinate in window space |
| window_y | Y coordinate in window space |
| window_width | Window width in pixels |
| window_height | Window height in pixels |
Unlike normalize_coords(), this ensures geometric shapes maintain their proportions. The shorter dimension maps to [-1, +1], the longer dimension extends beyond.
Definition at line 78 of file Windowing.cpp.
References aspect_ratio().
Referenced by normalize_coords_aspect().
Here is the call graph for this function:
Here is the caller graph for this function: