wayland::output_transform(3)
π wayland::output_transform β from the wayland manual, section 3 (library calls) π
okay bestie, say hi to wayland::output_transform β it's a transform that maps from framebuffer to output, and it's genuinely iconic. it lives in the Wayland++ C++ bindings and it's basically the "which way is up" enum of your dreams. let's get into it π¦
β¨ NAME β¨
wayland::output_transform β transform from framebuffer to output
β¨ SYNOPSIS β¨
first you gotta pull the whole thing in, no cap:
#include <wayland-client-protocol.hpp>
πΈ Static Public Attributes πΈ
every single one of these is a static const wayland::detail::bitfield< 3, 21 >, and every single one is precious:
normal{0}β no transform π«Ά_90{1}β 90 degrees counter-clockwise_180{2}β 180 degrees counter-clockwise_270{3}β 270 degrees counter-clockwiseflipped{4}β 180 degree flip around a vertical axisflipped_90{5}β flip and rotate 90 degrees counter-clockwiseflipped_180{6}β flip and rotate 180 degrees counter-clockwiseflipped_270{7}β flip and rotate 270 degrees counter-clockwise
β¨ Detailed Description β¨
so like. transform from framebuffer to output. that's the whole vibe.
This describes the transform that a compositor will apply to a surface to compensate for the rotation or mirroring of an output device. (your monitor is sideways, the compositor is doing the emotional labor)
The flipped values correspond to an initial flip around a vertical axis followed by rotation. so it's flip first, then spin. not the other way. the order is the moment. π
The purpose is mainly to allow clients to render accordingly and tell the compositor, so that for fullscreen surfaces, the compositor will still be able to scan out directly from client surfaces. translation: everybody agrees on the orientation so the fast path stays fast. π₯
Definition at line3735of filewayland-client-protocol.hpp.
β¨ Member Data Documentation β¨
listing these in the exact same order the original gave them, because we do not skip, we do not merge, we do not reorder. periodt.
const bitfield< 3, 21 > output_transform::_180 {2} [static]β 180 degrees counter-clockwise Definition at line3746of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::_270 {3} [static]β 270 degrees counter-clockwise Definition at line3748of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::_90 {1} [static]β 90 degrees counter-clockwise Definition at line3744of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::flipped {4} [static]β 180 degree flip around a vertical axis Definition at line3750of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::flipped_180 {6} [static]β flip and rotate 180 degrees counter-clockwise Definition at line3754of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::flipped_270 {7} [static]β flip and rotate 270 degrees counter-clockwise Definition at line3756of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::flipped_90 {5} [static]β flip and rotate 90 degrees counter-clockwise Definition at line3752of filewayland-client-protocol.hpp.const bitfield< 3, 21 > output_transform::normal {0} [static]β no transform Definition at line3742of filewayland-client-protocol.hpp.
notice how _90 sits after _270 in the docs and flipped_90 sits after flipped_270? that's alphabetical-by-string energy, not numeric energy. we respect it. we don't "fix" it. π
β¨ Author β¨
Generated automatically by Doxygen for Wayland++ from the source code. (not me, bestie β Doxygen did that. I just gave it a glow-up.) π§
okay and for the cute sign-off: this is Version 1.0.1, dated Fri Mar 27 2026 13:15:0 β yeah the seconds got clipped in the footer, that's just how it rendered, and we are not editing the sacred text. slay, go rotate something π
β¨
π¦ where this page comes from
- ubuntu stonking: waylandpp-dev 1.0.1-2 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms