ISAAC
Overview :: Library Doc :: Server Doc :: JSON Commands

In Situ Animation of Accelerated Computations

RTPImageConnector.hpp
Go to the documentation of this file.
1 /* This file is part of ISAAC.
2  *
3  * ISAAC is free software: you can redistribute it and/or modify
4  * it under the terms of the GNU Lesser General Public License as
5  * published by the Free Software Foundation, either version 3 of the
6  * License, or (at your option) any later version.
7  *
8  * ISAAC is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU Lesser General Public License for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public
14  * License along with ISAAC. If not, see <www.gnu.org/licenses/>. */
15 
16 #pragma once
17 
18 #include "ImageConnector.hpp"
19 #include "Runable.hpp"
20 #include <gst/gst.h>
21 #include <gst/gst.h>
22 #include <gst/app/gstappsrc.h>
23 #include <vector>
24 
26 {
27  public:
28  RTPImageConnector(std::string url,bool zerolatency = false,bool raw = false);
30  errorCode init(int minport, int maxport);
31  errorCode run();
32  std::string getName();
33  private:
34  typedef struct
35  {
36  bool is_used;
37  GstElement *appsrc;
38  GstElement *videoconvert;
39  GstElement *x264enc;
40  GstElement *rtph264pay;
41  GstElement *capsfilter;
42  GstElement *jpegenc;
43  GstElement *rtpjpegpay;
44  GstElement *udpsink;
45  GstElement *pipeline;
46  GstElement *bin;
47  InsituConnectorGroup* group;
48  std::string url;
49  void* ref;
50  } tStream;
51  int minport;
52  int maxport;
53  std::vector<tStream> streams;
54  std::string url;
55  bool zerolatency;
56  bool raw;
57 };
58 
59 void suicideNotify(gpointer data);
60 
RTPImageConnector(std::string url, bool zerolatency=false, bool raw=false)
errorCode init(int minport, int maxport)
int errorCode
Definition: Common.hpp:24
void suicideNotify(gpointer data)