对'gst_riff_create_video_caps'

时间:2015-08-17 14:52:01

标签: linker g++ gstreamer

我正在尝试构建一个使用gstreamer-1.0及其插件的软件。当我尝试使用以下g ++命令时出现此错误:

g++ vis.cpp -o vis -O3 -D__STDC_CONSTANT_MACROS -std=c++11  -lopencv_highgui -lopencv_imgproc -lopencv_core -lpng -lv4l1 -lv4l2 -ldc1394 -lswscale -lavdevice -lavformat -lavcodec -lswresample -lavutil -lpthread -lbz2 -lz -lc -lrt -llzma -lva -Idependencies/include -Ldependencies/lib `pkg-config --cflags --libs gstreamer-1.0 gstreamer-base-1.0 gstreamer-app-1.0 gstreamer-pbutils-1.0 gtk+-2.0` 

cap_gstreamer.cpp:(.text._ZN23CvVideoWriter_GStreamer4openEPKcid6CvSizeb+0x434): undefined reference to `gst_riff_create_video_caps'
collect2: error: ld returned 1 exit status
make: *** [vis] Error 1

基础插件中是否已有gst_riff_create_video_caps?或者我必须链接另一个插件吗?

1 个答案:

答案 0 :(得分:0)

我解决了我的问题。显然,我必须将[~,idx] = sort(B,'descend'); A_labels_ordered = sort(A_labels, 'descend'); result = A_labels_ordered(idx) 添加到库标志中,如下所示:

http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gstreamer-riff.html