Try Pangolin (6) - SimpleRecord

When I wanted to compile the source code, the terminal gave me an error as below:

 In function ‘void RecordSample(std::string, std::string)’:
         /home/chuyi/codes/Pangolin/SimpleRecord.cpp:7:5: error: ‘VideoInput’ is not a member of ‘pangolin’
         pangolin::VideoInput video(input_uri);
          ^
     though I found "VideoInput" is explained in http://docs.ros.org/fuerte/api/pangolin_wrapper/html/structpangolin_1_1VideoInput.html


And I checked pangolin.h and pangolin/video.h, I found 'VideoInput' is already there:

     in pangolin/pangolin.h:

    

     in pangolin/video.h:

    

     and in video_output.h:

    


I changed the class intostruct, according to this introduction about the difference betweenclass and struct: http://blog.csdn.net/snlying/article/details/2887543


And, I added #include <pangolin/video.h> and #include <pangolin/video_output.h> into the source code, strangely it did make some difference. I thought it wouldn't because they were already included in <pangolin/pangolin.h>, and that's why Steven Lovegrave didn't add them.


Then the terminal reported:

     /home/chuyi/codes/Pangolin/SimpleRecord.cpp: In function ‘void RecordSample(std::string, std::string)’:
     /home/chuyi/codes/Pangolin/SimpleRecord.cpp:15:14: error: ‘struct pangolin::VideoOutput’ has no member named ‘SetStreams’
          recorder.SetStreams(video.Streams());
                   ^
     /home/chuyi/codes/Pangolin/SimpleRecord.cpp:40:22: error: ‘struct pangolin::VideoOutput’ has no member named ‘WriteStreams’
                  recorder.WriteStreams(img);
                           ^

Then I checked video_output.h again and found yay there was not a member named 'SetStream'......then I re-checked Steven Lovegrove's github and found he updated a new video_output.h........fine.


Then I got many errors like:

     video_output.h:71:103: error: ‘json’ does not name a type
          virtual void SetStreams(const std::vector<StreamInfo>& streams, const std::string& uri ="", const json::value& properties = json::value() ) = 0;
                                                                                                            ^

I checked <pangolin/utils/picojson.h> file and found:

     ——so I guess I should use pangolin::json, instead of only json, in video_output.h?

     ——No, it didn't help.


(To Be Continued)


 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值