From 9e371de1cbbeb717c183caf52d675477e136050d Mon Sep 17 00:00:00 2001 From: Mohammad Durrani <46766905+mdurrani808@users.noreply.github.com> Date: Sat, 16 Sep 2023 10:17:28 -0400 Subject: [PATCH] Remove casts to double in SetLEDMode and set pipeline (#906) * Remove casts to double * Run wpiformat --- photon-lib/src/main/native/cpp/photonlib/PhotonCamera.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/photon-lib/src/main/native/cpp/photonlib/PhotonCamera.cpp b/photon-lib/src/main/native/cpp/photonlib/PhotonCamera.cpp index 7988774324..d0901b10bd 100644 --- a/photon-lib/src/main/native/cpp/photonlib/PhotonCamera.cpp +++ b/photon-lib/src/main/native/cpp/photonlib/PhotonCamera.cpp @@ -115,9 +115,7 @@ void PhotonCamera::TakeOutputSnapshot() { bool PhotonCamera::GetDriverMode() const { return driverModeSubscriber.Get(); } -void PhotonCamera::SetPipelineIndex(int index) { - pipelineIndexPub.Set(static_cast(index)); -} +void PhotonCamera::SetPipelineIndex(int index) { pipelineIndexPub.Set(index); } int PhotonCamera::GetPipelineIndex() const { return static_cast(pipelineIndexSub.Get()); @@ -137,7 +135,7 @@ std::optional PhotonCamera::GetCameraMatrix() { } void PhotonCamera::SetLEDMode(LEDMode mode) { - ledModePub.Set(static_cast(static_cast(mode))); + ledModePub.Set(static_cast(mode)); } const std::string_view PhotonCamera::GetCameraName() const {