Commit ce10d407 authored by Fernando Herrero's avatar Fernando Herrero

Setting pixel clock, modifies frame_rate

parent 2eb941d5
......@@ -340,10 +340,13 @@ void CMvbluefox3::SetConfig(CParams &params, bool ini)
// Request time out
if (ini || this->params_.req_timeout != params.req_timeout)
SetTimeoutMS(params.req_timeout);
// Pixel Clock
if (ini || this->params_.pixel_clock != params.pixel_clock)
{
SetPixelClock(params.pixel_clock);
params.frame_rate = this->params_.frame_rate;
}
// Frame rate
if (ini || this->params_.frame_rate != params.frame_rate)
......@@ -638,6 +641,7 @@ void CMvbluefox3::SetPixelClock(int &pclk_khz)
WriteProperty(this->dev_ctrl_->mvDeviceClockFrequency,pclk_khz);
int fps = PixelClockToFrameRate(pclk_khz, params_.width, params_.height, params_.expose_us);
SetFrameRate(fps);
this->params_.frame_rate=fps;
}catch (CmvBlueFOX3Exception& e) {
throw CmvBlueFOX3Exception(_HERE_, "Unable to set pixel clock: " + e.what() );
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment