STRUCT FIMC_CTX(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct_fimc_ctx(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual β€” specifically the page for struct fimc_ctx, and honestly? it's giving "the whole vibe of one camera pipeline, packaged into a single C struct." no cap. this is the device context data, and it's a lot, so grab a strawberry drink πŸ“ and let's go through it field by field. i promise i'll keep it readable πŸ’…


✨ NAME ✨

struct fimc_ctx β€” the device context data

like, the entire context blob for a device. one struct, all the state. iconic behavior honestly πŸ‘‘


🌸 SYNOPSIS 🌸

struct fimc_ctx {
    struct fimc_frame       s_frame;
    struct fimc_frame       d_frame;
    u32 out_order_1p;
    u32 out_order_2p;
    u32 in_order_1p;
    u32 in_order_2p;
    enum fimc_datapath      in_path;
    enum fimc_datapath      out_path;
    struct fimc_scaler      scaler;
    struct fimc_effect      effect;
    int rotation;
    unsigned int            hflip:1;
    unsigned int            vflip:1;
    u32 flags;
    u32 state;
    struct fimc_dev         *fimc_dev;
    struct v4l2_fh          fh;
    struct fimc_ctrls       ctrls;
 };

look at her. twenty lines of pure main character energy. let's break down every single member because we do NOT skip πŸ’€


πŸŽ€ Members πŸŽ€

  • s_frame β€” source frame properties. the "before" picture, literally ✨
  • d_frame β€” destination frame properties. the "after" picture, the glow-up πŸ¦‹
  • out_order_1p β€” output 1-plane YCBCR order
  • out_order_2p β€” output 2-plane YCBCR order
  • in_order_1p β€” input 1-plane YCBCR order
  • in_order_2p β€” input 2-plane YCBCR order

(note how the 1p/2p pairs are just matching sets, in and out. they're twins. they're the moment. anyway πŸ’…)

  • in_path β€” input mode (DMA or camera)
  • out_path β€” output mode (DMA or FIFO)
  • scaler β€” image scaler properties. she resizes, she serves πŸ’β€β™€οΈ
  • effect β€” image effect
  • rotation β€” image clockwise rotation in degrees. clockwise ONLY, bestie, don't @ me πŸ™ˆ
  • hflip β€” indicates image horizontal flip if set
  • vflip β€” indicates image vertical flip if set
  • flags β€” additional flags for image conversion
  • state β€” flags to keep track of user configuration. lowkey the struct's little diary of what you've configured πŸ““
  • fimc_dev β€” the FIMC device this context applies to. her home. her origin story 🏠
  • fh β€” v4l2 file handle
  • ctrls β€” v4l2 controls structure
fr fr, that's every single member β€” nothing skipped, nothing merged, that's the whole roster 🫢

πŸ¦‹ SEE ALSO πŸ¦‹

okay so if you've read this far you're clearly in your unix research era, so here's the whole friend group πŸ’œ


<s>and that's the whole page, periodt.</s> no wait β€” one more thing 🧚

this lil masterpiece comes from ./drivers/media/platform/samsu... and it's dated October 2026, so like... future-coded of it, honestly ⭐ thank you for coming to my ted talk, go configure something pretty πŸ’–πŸŒˆ

πŸ“¦ where this page comes from