public void SetThenGetSensorMode(MMALSensorMode mode) { MMALCameraConfig.SensorMode = mode; Fixture.MMALCamera.ConfigureCameraSettings(); Assert.True(Fixture.MMALCamera.Camera.GetSensorMode() == mode); }
public void SetThenGetSensorMode(MMALSensorMode mode) { TestHelper.SetConfigurationDefaults(); MMALCameraConfig.SensorMode = mode; _fixture.MMALCamera.ConfigureCameraSettings(); Assert.True(_fixture.MMALCamera.Camera.GetSensorMode() == mode); }
internal static void SetSensorMode(this MMALCameraComponent camera, MMALSensorMode mode) { var currentMode = (int)camera.Control.GetParameter(MMAL_PARAMETER_CAMERA_CUSTOM_SENSOR_CONFIG); // Don't try and set the sensor mode if we aren't changing it. if (currentMode != 0 || MMALCameraConfig.SensorMode != 0) { camera.Control.SetParameter(MMAL_PARAMETER_CAMERA_CUSTOM_SENSOR_CONFIG, MMALCameraConfig.SensorMode); } }