Skip to content

Commit

Permalink
core: app: Fix stride configuration
Browse files Browse the repository at this point in the history
Set the stride to 0 before validating configurations, so validate will
set the correct stride for each configuration.

Signed-off-by: William Vinnicombe <[email protected]>
  • Loading branch information
will-v-pi committed Dec 12, 2023
1 parent 93ccdc9 commit 4d3d65e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions core/rpicam_app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1002,6 +1002,8 @@ void RPiCamApp::setupCapture()
{
// First finish setting up the configuration.

for (auto &config : *configuration_)
config.stride = 0;
CameraConfiguration::Status validation = configuration_->validate();
if (validation == CameraConfiguration::Invalid)
throw std::runtime_error("failed to valid stream configurations");
Expand Down

0 comments on commit 4d3d65e

Please sign in to comment.