Skip to content

Commit

Permalink
Don't use camera->LineSize when allocating shared images. It doesn't …
Browse files Browse the repository at this point in the history
…work because other processes don't know about it.
  • Loading branch information
Isaac Connor committed Aug 6, 2020
1 parent 3ba8ad5 commit 302189a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/zm_monitor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -636,7 +636,7 @@ bool Monitor::connect() {
image_buffer = new Snapshot[image_buffer_count];
for ( int i = 0; i < image_buffer_count; i++ ) {
image_buffer[i].timestamp = &(shared_timestamps[i]);
image_buffer[i].image = new Image( width, camera->LineSize(), height, camera->Colours(), camera->SubpixelOrder(), &(shared_images[i*camera->ImageSize()]) );
image_buffer[i].image = new Image( width, height, camera->Colours(), camera->SubpixelOrder(), &(shared_images[i*camera->ImageSize()]) );
image_buffer[i].image->HoldBuffer(true); /* Don't release the internal buffer or replace it with another */
}
if ( (deinterlacing & 0xff) == 4) {
Expand Down

0 comments on commit 302189a

Please sign in to comment.