Download modules/gapi/src/streaming/gstreamer/gstreamer_buffer_utils.cpp from tgollogly/test: direct link, hf CLI and curl.
- Browser
- Download file 855 Bytes
-
https://huggingface.co/tgollogly/test/resolve/main/modules/gapi/src/streaming/gstreamer/gstreamer_buffer_utils.cpp
- Command line
-
hf download hf://tgollogly/test/modules/gapi/src/streaming/gstreamer/gstreamer_buffer_utils.cpp
-
curl -L -o gstreamer_buffer_utils.cpp https://huggingface.co/tgollogly/test/resolve/main/modules/gapi/src/streaming/gstreamer/gstreamer_buffer_utils.cpp
855 Bytes
| // This file is part of OpenCV project. | |
| // It is subject to the license terms in the LICENSE file found in the top-level directory | |
| // of this distribution and at http://opencv.org/license.html. | |
| // | |
| // Copyright (C) 2021 Intel Corporation | |
| namespace cv { | |
| namespace gapi { | |
| namespace wip { | |
| namespace gstreamer_utils { | |
| void mapBufferToFrame(GstBuffer& buffer, GstVideoInfo& info, GstVideoFrame& frame, | |
| GstMapFlags mapFlags) { | |
| bool mapped = gst_video_frame_map(&frame, &info, &buffer, mapFlags); | |
| GAPI_Assert(mapped && "Failed to map GStreamer buffer to system memory as video-frame!"); | |
| } | |
| } // namespace gstreamer_utils | |
| } // namespace wip | |
| } // namespace gapi | |
| } // namespace cv | |