|
MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
|
| MAYAFLUX_API std::vector< float > MayaFlux::Kinesis::Vision::downsample_2x | ( | std::span< const float > | src, |
| uint32_t | w, | ||
| uint32_t | h, | ||
| uint32_t & | new_w, | ||
| uint32_t & | new_h | ||
| ) |
2x box-filter downsample.
Each output pixel is the average of the corresponding 2x2 block in src. Output dimensions are floor(w/2) x floor(h/2). Odd-dimension remainders are dropped. new_w and new_h are written before return.
| src | Single-channel float span, size must be w * h. |
| w | Input width in pixels. |
| h | Input height in pixels. |
| new_w | Receives output width (floor(w/2)). |
| new_h | Receives output height (floor(h/2)). |
Definition at line 516 of file PixelOps.cpp.
References downsample_2x(), and h.
Here is the call graph for this function: