Adding/Inserting a GstBuffer to the Gstbuffer pool

﹥>﹥吖頭↗ 提交于 2021-02-11 14:29:27

问题


can any one guide me on how do we can add/insert the Gstbufffer to the GstBuffer pool?

The GstBuffer Pool configuration is as shown below.

pool = gst_buffer_pool_new();
config = gst_buffer_pool_get_config(pool);
size = 420*420*3; // size of the pool buffer
min_ = 1;
max_ = 5;
caps = gst_caps_from_string("video/x-raw");
gst_buffer_pool_config_set_params (config, caps, size, min_, max_);
gst_caps_unref(caps);

if ( gst_buffer_pool_set_config (pool, config)){
    std::cout << "[INFO] Pool configuration done successfully\n";
 
else
    std::cout << "{[ERROR] Failed to set the pool config.\n";}
    //GstBuffer *buf= frmae;

//GstBuffer buf wanted to add inside GstBuffer Pool.

Please also let me know if anything here I am doing wrong.

来源:https://stackoverflow.com/questions/64044659/adding-inserting-a-gstbuffer-to-the-gstbuffer-pool

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!