1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 25 module gst.app.c.types; 26 27 public import glib.c.types; 28 public import gobject.c.types; 29 public import gst.base.c.types; 30 public import gstreamer.c.types; 31 32 33 /** 34 * The stream type. 35 */ 36 public enum GstAppStreamType 37 { 38 /** 39 * No seeking is supported in the stream, such as a 40 * live stream. 41 */ 42 STREAM = 0, 43 /** 44 * The stream is seekable but seeking might not 45 * be very fast, such as data from a webserver. 46 */ 47 SEEKABLE = 1, 48 /** 49 * The stream is seekable and seeking is fast, 50 * such as in a local file. 51 */ 52 RANDOM_ACCESS = 2, 53 } 54 alias GstAppStreamType AppStreamType; 55 56 struct GstAppSink 57 { 58 GstBaseSink basesink; 59 GstAppSinkPrivate* priv; 60 void*[4] GstReserved; 61 } 62 63 /** 64 * A set of callbacks that can be installed on the appsink with 65 * gst_app_sink_set_callbacks(). 66 */ 67 struct GstAppSinkCallbacks 68 { 69 /** */ 70 extern(C) void function(GstAppSink* appsink, void* userData) eos; 71 /** */ 72 extern(C) GstFlowReturn function(GstAppSink* appsink, void* userData) newPreroll; 73 /** */ 74 extern(C) GstFlowReturn function(GstAppSink* appsink, void* userData) newSample; 75 void*[4] GstReserved; 76 } 77 78 struct GstAppSinkClass 79 { 80 GstBaseSinkClass basesinkClass; 81 /** */ 82 extern(C) void function(GstAppSink* appsink) eos; 83 /** */ 84 extern(C) GstFlowReturn function(GstAppSink* appsink) newPreroll; 85 /** */ 86 extern(C) GstFlowReturn function(GstAppSink* appsink) newSample; 87 /** 88 * 89 * Params: 90 * appsink = a #GstAppSink 91 * Returns: a #GstSample or NULL when the appsink is stopped or EOS. 92 * Call gst_sample_unref() after usage. 93 */ 94 extern(C) GstSample* function(GstAppSink* appsink) pullPreroll; 95 /** 96 * 97 * Params: 98 * appsink = a #GstAppSink 99 * Returns: a #GstSample or NULL when the appsink is stopped or EOS. 100 * Call gst_sample_unref() after usage. 101 */ 102 extern(C) GstSample* function(GstAppSink* appsink) pullSample; 103 /** 104 * 105 * Params: 106 * appsink = a #GstAppSink 107 * timeout = the maximum amount of time to wait for the preroll sample 108 * Returns: a #GstSample or NULL when the appsink is stopped or EOS or the timeout expires. 109 * Call gst_sample_unref() after usage. 110 */ 111 extern(C) GstSample* function(GstAppSink* appsink, GstClockTime timeout) tryPullPreroll; 112 /** 113 * 114 * Params: 115 * appsink = a #GstAppSink 116 * timeout = the maximum amount of time to wait for a sample 117 * Returns: a #GstSample or NULL when the appsink is stopped or EOS or the timeout expires. 118 * Call gst_sample_unref() after usage. 119 */ 120 extern(C) GstSample* function(GstAppSink* appsink, GstClockTime timeout) tryPullSample; 121 void*[2] GstReserved; 122 } 123 124 struct GstAppSinkPrivate; 125 126 struct GstAppSrc 127 { 128 GstBaseSrc basesrc; 129 GstAppSrcPrivate* priv; 130 void*[4] GstReserved; 131 } 132 133 /** 134 * A set of callbacks that can be installed on the appsrc with 135 * gst_app_src_set_callbacks(). 136 */ 137 struct GstAppSrcCallbacks 138 { 139 /** */ 140 extern(C) void function(GstAppSrc* src, uint length, void* userData) needData; 141 /** */ 142 extern(C) void function(GstAppSrc* src, void* userData) enoughData; 143 /** */ 144 extern(C) int function(GstAppSrc* src, ulong offset, void* userData) seekData; 145 void*[4] GstReserved; 146 } 147 148 struct GstAppSrcClass 149 { 150 GstBaseSrcClass basesrcClass; 151 /** */ 152 extern(C) void function(GstAppSrc* appsrc, uint length) needData; 153 /** */ 154 extern(C) void function(GstAppSrc* appsrc) enoughData; 155 /** */ 156 extern(C) int function(GstAppSrc* appsrc, ulong offset) seekData; 157 /** 158 * 159 * Params: 160 * appsrc = a #GstAppSrc 161 * buffer = a #GstBuffer to push 162 * Returns: #GST_FLOW_OK when the buffer was successfuly queued. 163 * #GST_FLOW_FLUSHING when @appsrc is not PAUSED or PLAYING. 164 * #GST_FLOW_EOS when EOS occured. 165 */ 166 extern(C) GstFlowReturn function(GstAppSrc* appsrc, GstBuffer* buffer) pushBuffer; 167 /** 168 * 169 * Params: 170 * appsrc = a #GstAppSrc 171 * Returns: #GST_FLOW_OK when the EOS was successfuly queued. 172 * #GST_FLOW_FLUSHING when @appsrc is not PAUSED or PLAYING. 173 */ 174 extern(C) GstFlowReturn function(GstAppSrc* appsrc) endOfStream; 175 /** 176 * 177 * Params: 178 * appsrc = a #GstAppSrc 179 * sample = a #GstSample from which buffer and caps may be 180 * extracted 181 * Returns: #GST_FLOW_OK when the buffer was successfuly queued. 182 * #GST_FLOW_FLUSHING when @appsrc is not PAUSED or PLAYING. 183 * #GST_FLOW_EOS when EOS occured. 184 */ 185 extern(C) GstFlowReturn function(GstAppSrc* appsrc, GstSample* sample) pushSample; 186 /** 187 * 188 * Params: 189 * appsrc = a #GstAppSrc 190 * bufferList = a #GstBufferList to push 191 * Returns: #GST_FLOW_OK when the buffer list was successfuly queued. 192 * #GST_FLOW_FLUSHING when @appsrc is not PAUSED or PLAYING. 193 * #GST_FLOW_EOS when EOS occured. 194 */ 195 extern(C) GstFlowReturn function(GstAppSrc* appsrc, GstBufferList* bufferList) pushBufferList; 196 void*[2] GstReserved; 197 } 198 199 struct GstAppSrcPrivate;