MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ normalize_coords_aspect() [2/2]

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)

Parameters
window_xX coordinate in window space
window_yY coordinate in window space
window_widthWindow width in pixels
window_heightWindow height in pixels
Returns
Aspect-corrected NDC coordinates where circles remain circular

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 72 of file Windowing.cpp.

74{
75 return Kinesis::to_ndc_aspect(window_x, window_y, window_width, window_height);
76}

References MayaFlux::Kinesis::to_ndc_aspect().

+ Here is the call graph for this function: