xcb_xv_query_encodings(3)

πŸ“¦
version 1.17.0 Β· 4 versions
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, centos-stream 10, debian trixie, fedora 43, fedora 44, nixpkgs unstable, opensuse-leap 16.0, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ xcb_xv_query_encodings πŸ’…

okay so bestie, welcome to the XCB Requests corner of the universe, where we ask the X server politely about stuff and it answers in structs πŸ¦‹. This one is xcb_xv_query_encodings β€” the Xv (that's X Video, the thing that makes your video players go brrr) request that goes and asks the server what video encodings are even available. iykyk. πŸŽ€


🌸 NAME 🌸

xcb_xv_query_encodings β€” she queries the encodings, no cap, that's literally it πŸ’–


✨ SYNOPSIS ✨

First things first, you gotta invite her in:

#include <xcb/xv.h>

🫢 Request function

xcb_xv_query_encodings_cookie_t
       xcb_xv_query_encodings(xcb_connection_t *conn,
       xcb_xv_port_t port);

πŸŽ€ Reply datastructure

typedef struct xcb_xv_query_encodings_reply_t {
    uint8_t  response_type;
    uint8_t  pad0;
    uint16_t sequence;
    uint32_t length;
    uint16_t num_encodings;
    uint8_t  pad1[22];
} xcb_xv_query_encodings_reply_t;

πŸ¦‹ Reply function

xcb_xv_query_encodings_reply_t
       *xcb_xv_query_encodings_reply(xcb_connection_t *conn,
       xcb_xv_query_encodings_cookie_t cookie, xcb_generic_error_t **e);

πŸ’œ Reply accessors

int xcb_xv_query_encodings_info_length(const
       xcb_xv_query_encodings_reply_t *reply);

xcb_xv_encoding_info_iterator_t
       xcb_xv_query_encodings_info_iterator(const
       xcb_xv_query_encodings_reply_t *reply);

πŸ’– REQUEST ARGUMENTS πŸ’–

  • conn β€” the XCB connection to X11. your lil hotline to the server, she's the main character here ✨
  • port β€” TODO: NOT YET DOCUMENTED. yeah bestie, even the manpage is like "idk her" 😭 the docs just never got written for this one, no cap

🌈 REPLY FIELDS 🌈

  • response_type β€” the type of this reply, and in this case it's XCB_XV_QUERY_ENCODINGS. lowkey iconic because this exact field also lives in xcb_generic_reply_t, so you can use it to tell replies apart from each other when they're all showing up at the function πŸ’…
  • sequence β€” the sequence number of the last request processed by the X11 server. it's giving "receipt number" 🧾
  • length β€” the length of the reply, measured in words. and heads up, a word here is 4 bytes, not whatever your English teacher said πŸ“
  • num_encodings β€” TODO: NOT YET DOCUMENTED. again!! the docs really said "we'll do it later" and then never did πŸ™ˆ

⭐ DESCRIPTION ⭐

(no description in the original β€” she's mysterious, she's aloof, she says nothing and looks pretty πŸ’€)


πŸ“ RETURN VALUE πŸ“

She hands you back an xcb_xv_query_encodings_cookie_t πŸͺ. That's your little voucher, your claim ticket, your "come back later and I'll have your answer ready" slip.

But listen β€” errors have to be handled when you call the reply function xcb_xv_query_encodings_reply. You don't get to skip that part, bestie, that's the whole deal.

If you'd rather handle errors in the event loop instead, use xcb_xv_query_encodings_unchecked β€” she's the chaotic, no-safety-net version πŸ”₯. See xcb-requests(3) for all the details on how that works.


πŸŽ€ ERRORS πŸŽ€

This request does never generate any errors. periodt. zero drama, zero problems, she simply does not miss. πŸ’…βœ¨

πŸ’œ SEE ALSO πŸ’œ

(nothing listed in the original β€” the see-also section is empty, so like... go look at literally anything else, queen πŸ‘‘)


🌸 AUTHOR 🌸

Generated from xv.xml. If something's wrong or you wanna make it better, contact xcb@lists.freedesktop.org for corrections and improvements. they're literally waiting for your email 🫢


and that's the whole page bestie!! πŸŽ‰ this one came to you straight out of X Version 11 with libxcb 1.17.0 energy, from your favorite manual page for xcb_xv_query_encodings(3) β€” go forth and query those encodings, you've got this πŸ’–πŸ¦‹βœ¨