upipe/upipe_helper_ubuf_mgr.h header reference

Upipe helper functions for ubuf manager More

Header inclusion  

Members  

Macro  

Description  

Upipe helper functions for ubuf manager

Members detail  

#define UPIPE_HELPER_UBUF_MGR(STRUCTURE, UBUF_MGR, FLOW_DEF)  

This macro is declared in upipe/upipe_helper_ubuf_mgr.h source file, line 88.

This macro declares four functions dealing with the ubuf manager used on the output of a pipe.

You must add two members to your private upipe structure, for instance:

struct ubuf_mgr *ubuf_mgr;
struct uref *flow_def;

where the flow_def is probably shared with UPIPE_HELPER_OUTPUT.

You must also declare UPIPE_HELPER_UPIPE prior to using this macro.

Supposing the name of your structure is upipe_foo, it declares:

  • void upipe_foo_init_ubuf_mgr(struct upipe *upipe)

    Typically called in your upipe_foo_alloc() function.

  • int upipe_foo_attach_ubuf_mgr(struct upipe *upipe)

    Typically called from your upipe_foo_control() handler, such as:

    case UPIPE_ATTACH_UBUF_MGR: {
    return upipe_foo_attach_ubuf_mgr(upipe);
    }
  • int upipe_foo_check_ubuf_mgr(struct upipe *upipe)

    Checks if the ubuf manager is available, and asks for it otherwise.

  • void upipe_foo_clean_ubuf_mgr(struct upipe *upipe)

    Typically called from your upipe_foo_free() function.

Parameters list:

  • STRUCTURE: name of your private upipe structure
  • UBUF_MGR: name of the struct ubuf_mgr * field of your private upipe structure
  • FLOW_DEF: name of the struct uref * field of your private upipe structure

#define _UPIPE_UPIPE_HELPER_UBUF_MGR_H_  

This macro is declared in upipe/upipe_helper_ubuf_mgr.h source file, line 31.

Valid XHTML 1.0 StrictGenerated by cmassiot on Thu Nov 6 12:15:37 2014 using MkDoc