xcb_xv_query_best_size(3)
π xcb_xv_query_best_size β the one where XCB asks X11 "bestie, what size actually fits?" π
okay so this is a page from the XCB manual (libxcb), and it's all about the xcb_xv_query_best_size request in <xcb/xv.h>. she's a lil Xv-flavoured request that goes and asks the server for the β¨bestβ¨ size, and honestly the docs are giving "we'll finish this later" energy but we're gonna work with what we've got π«Ά
β¨ NAME β¨
xcb_xv_query_best_size β no description line in the original, it's just vibes and a name, so that's what we're passing along π
πΈ SYNOPSIS πΈ
first things first, you gotta pull in the header:
#include <xcb/xv.h>
π Request function
xcb_xv_query_best_size_cookie_t
xcb_xv_query_best_size(xcb_connection_t *conn,
xcb_xv_port_t port, uint16_t vid_w, uint16_t vid_h,
uint16_t drw_w, uint16_t drw_h, uint8_t motion);
π¦ Reply datastructure
typedef struct xcb_xv_query_best_size_reply_t {
uint8_t response_type;
uint8_t pad0;
uint16_t sequence;
uint32_t length;
uint16_t actual_width;
uint16_t actual_height;
} xcb_xv_query_best_size_reply_t;
π Reply function
xcb_xv_query_best_size_reply_t
*xcb_xv_query_best_size_reply(xcb_connection_t *conn,
xcb_xv_query_best_size_cookie_t cookie, xcb_generic_error_t **e);
π REQUEST ARGUMENTS π
these are the things you hand over when you fire off the request, bestie:
connβ the XCB connection to X11. your little hotline to the server πportβ TODO: NOT YET DOCUMENTED. yeah. the original really said that πvid_wβ TODO: NOT YET DOCUMENTED. πvid_hβ TODO: NOT YET DOCUMENTED. πdrw_wβ TODO: NOT YET DOCUMENTED. πdrw_hβ TODO: NOT YET DOCUMENTED. πmotionβ TODO: NOT YET DOCUMENTED. π
not me being so real: those TODO: NOT YET DOCUMENTED. lines are literally what the manual says, so I'm not about to invent meanings for them. no cap, I refuse to make stuff up π₯
π REPLY FIELDS π
what comes back in the reply struct:
response_typeβ the type of this reply, in this caseXCB_XV_QUERY_BEST_SIZE. this field is also present in thexcb_generic_reply_tand can be used to tell replies apart from each other. it's giving name-tag at a party π·οΈsequenceβ the sequence number of the last request processed by the X11 server. tracking number energy fr frlengthβ the length of the reply, in words (a word is 4 bytes). math girlies rise πactual_widthβ TODO: NOT YET DOCUMENTED. πactual_heightβ TODO: NOT YET DOCUMENTED. π
π DESCRIPTION π
...and that's it. the DESCRIPTION section of this page is genuinely empty. nothing. a void. main character silence π³οΈβ¨ (the actual explanation was never written, so I'm not gonna pretend otherwise)
π RETURN VALUE π
Returns an xcb_xv_query_best_size_cookie_t. Errors have to be handled when calling the reply function xcb_xv_query_best_size_reply.
If you want to handle errors in the event loop instead, use xcb_xv_query_best_size_unchecked. See xcb-requests(3) for details.
so like β cookie first, then you cash it in with the reply function and deal with any errors right there. or, if you'd rather catch errors while you're vibing in the event loop, there's xcb_xv_query_best_size_unchecked for that. the full tea is in xcb-requests(3) π«
π ERRORS π
This request does never generate any errors.
yup, zero. none. not a single one. she's a good girl, no drama, no error handling required πβ¨
π₯ SEE ALSO π₯
the original lists absolutely nothing here β the section exists and it's empty, which is honestly iconic in a haunted way π»π
πΈ AUTHOR πΈ
Generated from xv.xml. Contact xcb@lists.freedesktop.org for corrections and improvements.
so if you spot something cursed in here, that's the inbox to slide into π¬
okay that's the whole page, you ate it, you understood it, periodt π
and for the cute little sign-off: this one's from X Version 11, shipped with libxcb 1.17.0, and the page answers to the name xcb_xv_query_best_size(3) πππ¦
π¦ where this page comes from
- alpine 3.22: libxcb-doc 1.17.0-r0 Β· MIT
- alpine 3.23: libxcb-doc 1.17.0-r1 Β· MIT
- alpine 3.24: libxcb-doc 1.17.0-r2 Β· MIT
- arch rolling: libxcb 1.17.0-1 Β· X11
- centos-stream 10: libxcb-devel 1.17.0-3.el10 Β· X11
- debian trixie: libxcb-doc 1.17.0-2
- fedora 43: libxcb-devel 1.17.0-6.fc43 Β· X11
- fedora 43: libxcb-devel 1.17.0-6.fc43 Β· X11
- fedora 44: libxcb-devel 1.17.0-7.fc44 Β· X11
- fedora 44: libxcb-devel 1.17.0-7.fc44 Β· X11
- nixpkgs unstable: libxcb 1.17.0
- opensuse-leap 16.0: libxcb-devel-doc 1.17.0-160000.2.2 Β· MIT
- ubuntu questing: libxcb-doc 1.17.0-2build1
- ubuntu resolute: libxcb-doc 1.17.0-2ubuntu1
- ubuntu stonking: libxcb-doc 1.17.0-2ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms