jeffbass / imagezmq

A set of Python classes that transport OpenCV images from one computer to another using PyZMQ messaging.
MIT License
1.01k stars 160 forks source link

Add Compression? #24

Closed petertorelli closed 4 years ago

petertorelli commented 4 years ago

It looks like the image format is up to the VideoCamera codec, and that ImageZMQ is simply passing the raw data, which may be JPEG, or may not, depends on if PiCam is used. Is this true? Would it be more succinct to refer to the image as a binary data rather than jpeg in the code, since I see nothing specific to images... or am I missing something? Thanks! Great library, btw.

jeffbass commented 4 years ago

Good catch. You are not missing anything. Both the image and jpeg functions are just passing binary blobs. In the current imagezmq version, the calling code does any jpeg transformation. You can see examples in the test programs with jpg in their names. In a future version, the jpg compression will be an option that does that transformation in the imagezmq classes. The current setup is a placeholder as I work on the next version.

petertorelli commented 4 years ago

Whew, ok thanks for confirming!