Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix stop capture #105

waveform80 opened this issue Jun 8, 2014 · 0 comments

Fix stop capture #105

waveform80 opened this issue Jun 8, 2014 · 0 comments


Copy link

Just discovered an issue with multi-res record: if recording is started on (for example) port 1, then another is started on port 2, the recording on port 1 must be stopped last. The started_capture attribute in the encoder tracks which encoder started the recording, but it shouldn't - instead we should be disabling the capture in the last active active encoder rather than simply in the one that started capture. Unfortunately, fixing this is tricky. Only the PiCamera class has knowledge of which other encoders exist and what ports they use so we probably need to shift start/stop capture code back into PiCamera and call it from the encoder's start and stop methods (and I bet there'll be a few race conditions to deal with there too)

@waveform80 waveform80 added this to the 1.5 milestone Jun 8, 2014
@waveform80 waveform80 added the bug label Jun 8, 2014
@waveform80 waveform80 self-assigned this Jun 8, 2014
waveform80 added a commit that referenced this issue Jun 9, 2014
Refactor how we go about allocating, deallocating, starting and stopping
decoders. This introduces some violation of encapsulation (just think of
PiEncoder as a friend class of PiCamera), but there's not much I can do
about that: the camera class has to be the one to start and stop the
video port as it's the only thing that "knows" about how many encoders
are attached to the splitter.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

No branches or pull requests

1 participant