@@ -61,9 +61,9 @@ class StreamPrivate;
61
61
/* *
62
62
* Stream visual data to a deflect::Server.
63
63
*
64
- * A Stream can be subdivided into one or more images. This allows to have
65
- * different applications each responsible for sending one part of the global
66
- * image.
64
+ * A Stream can be subdivided into one or more images and eye passes. This
65
+ * allows to have different applications each responsible for sending one part
66
+ * of the global image.
67
67
*
68
68
* The methods in this class are reentrant (all instances are independant) but
69
69
* are not thread-safe.
@@ -123,49 +123,31 @@ class Stream
123
123
/* * Future signaling success of asyncSend(). @version 1.5 */
124
124
using Future = std::future<bool >;
125
125
126
- /* *
127
- * Send an image and finish the frame asynchronously.
128
- *
129
- * The send (and the optional compression) and finishFrame() are executed in
130
- * a different thread. The result of this operation can be obtained by the
131
- * returned future object.
132
- *
133
- * @param image The image to send. Note that the image is not copied, so the
134
- * referenced must remain valid until the send is finished
135
- * @return true if the image data could be sent, false otherwise
136
- * @see send()
137
- * @version 1.1
138
- */
139
- DEFLECT_API Future asyncSend (const ImageWrapper& image);
140
- // @}
126
+ DEFLECT_API Future asyncSend (const ImageWrapper& image); // <! @deprecated
141
127
142
- /* * @name Synchronous send API */
143
- // @{
144
128
/* *
145
- * Send an image synchronously .
129
+ * Send an image asynchronously .
146
130
*
147
- * @note A call to send() while an asyncSend() is pending is undefined.
148
131
* @param image The image to send
149
132
* @return true if the image data could be sent, false otherwise
150
133
* @version 1.0
151
134
* @sa finishFrame()
152
135
*/
153
- DEFLECT_API bool send (const ImageWrapper& image);
136
+ DEFLECT_API Future send (const ImageWrapper& image);
154
137
155
138
/* *
156
- * Notify that all the images for this frame have been sent.
139
+ * Asynchronously notify that all the images for this frame have been sent.
157
140
*
158
141
* This method must be called everytime this Stream instance has finished
159
142
* sending its image(s) for the current frame. The receiver will display
160
143
* the images once all the senders which use the same identifier have
161
- * finished a frame.
144
+ * finished a frame. This is only to be called once per frame, even for
145
+ * stereo rendering.
162
146
*
163
- * @note A call to finishFrame() while an asyncSend() is pending is
164
- * undefined.
165
- * @see send()
147
+ * @sa send()
166
148
* @version 1.0
167
149
*/
168
- DEFLECT_API bool finishFrame ();
150
+ DEFLECT_API Future finishFrame ();
169
151
// @}
170
152
171
153
/* *
@@ -240,17 +222,19 @@ class Stream
240
222
DEFLECT_API Event getEvent ();
241
223
242
224
/* *
243
- * Send size hints to the stream host to indicate sizes that should be
244
- * respected by resize operations on the host side.
225
+ * Send size hints to the stream server to indicate sizes that should be
226
+ * respected by resize operations on the server side.
245
227
*
246
- * @param hints the new size hints for the host
228
+ * @note do not use while asynchronous send operations are pending.
229
+ * @param hints the new size hints for the server
247
230
* @version 1.2
248
231
*/
249
232
DEFLECT_API void sendSizeHints (const SizeHints& hints);
250
233
251
234
/* *
252
235
* Send data to the Server.
253
236
*
237
+ * @note do not use while asynchronous send operations are pending.
254
238
* @param data the pointer to the data buffer.
255
239
* @param count the number of bytes to send.
256
240
* @return true if the data could be sent, false otherwise
0 commit comments