1 // stream.h 2 // LiVES 3 // (c) G. Finch 2008 - 2016 <salsaman@gmail.com> 4 // released under the GNU GPL 3 or later 5 // see file ../COPYING for licensing details 6 7 #ifndef HAS_LIVES_STREAM_H 8 #define HAS_LIVES_STREAM_H 9 10 11 typedef struct { 12 uint32_t stream_id; 13 uint32_t flags; 14 15 int64_t timecode; 16 int hsize; 17 int vsize; 18 double fps; 19 int palette; 20 int YUV_sampling; 21 int YUV_clamping; 22 int YUV_subspace; 23 int compression_type; 24 25 // TODO - use lives_stream_control_t for these 26 size_t dsize; 27 boolean data_ready; 28 void *handle; 29 30 volatile boolean reading; 31 void *buffer; 32 volatile size_t bufoffs; 33 } lives_vstream_t; 34 35 // stream packet tpyes 36 #define LIVES_STREAM_TYPE_VIDEO 1 37 38 // video stream flags 39 #define LIVES_VSTREAM_FLAGS_IS_CONTINUATION (1<<0) 40 41 // video compression types 42 #define LIVES_VSTREAM_COMPRESSION_NONE 0 43 44 45 void lives2lives_read_stream(const char *host, int port); 46 void weed_layer_set_from_lives2lives(weed_layer_t *layer, int clip, lives_vstream_t *lstream); 47 void on_open_lives2lives_activate(LiVESMenuItem *, livespointer); 48 void on_send_lives2lives_activate(LiVESMenuItem *, livespointer); 49 50 typedef struct { 51 LiVESWidget *dialog; 52 LiVESWidget *entry1; 53 LiVESWidget *entry2; 54 LiVESWidget *entry3; 55 LiVESWidget *entry4; 56 LiVESWidget *port_spin; 57 LiVESWidget *rb_anyhost; 58 } lives_pandh_w; 59 60 lives_pandh_w *create_pandh_dialog(int type); 61 62 63 64 65 #endif // HAS_LIVES_STREAM_H 66