summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--zmq-camera.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/zmq-camera.c b/zmq-camera.c
index 8ce015a..ce8e3da 100644
--- a/zmq-camera.c
+++ b/zmq-camera.c
@@ -104,6 +104,7 @@ void *sender_thread (void *arg)
unicap_data_buffer_t *returned_buffer;
int conversion_found = 0;
int index = 0;
+ uint64_t zmq_rate = 100000; /* Rate limit for PGM, kbps */
sender_args = (struct sender_args_t *)arg;
@@ -120,6 +121,11 @@ void *sender_thread (void *arg)
zmq_strerror (errno));
exit (1);
}
+ /* PGM transports need to have their default rate limit (100 kbps) raised
+ to something usable for our purposes. Use 100 Mbps as a default
+ for now. */
+ rc = zmq_setsockopt (s, ZMQ_RATE, &zmq_rate, sizeof zmq_rate);
+ assert (rc == 0);
/* Open first available video capture device. */
if (!SUCCESS (unicap_enumerate_devices (NULL, &device, 0))) {