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

Testing Windows fix #392

Merged
merged 6 commits into from
Oct 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
set (sources
BrownDistortionModel.cc
CameraSensorUtil.cc
Distortion.cc
EnvironmentalData.cc
GaussianNoiseModel.cc
Expand Down Expand Up @@ -59,7 +58,7 @@ target_link_libraries(${rendering_target}
gz-rendering${GZ_RENDERING_VER}::gz-rendering${GZ_RENDERING_VER}
)

set(camera_sources CameraSensor.cc)
set(camera_sources CameraSensor.cc CameraSensorUtil.cc)
gz_add_component(camera
SOURCES ${camera_sources}
DEPENDS_ON_COMPONENTS rendering
Expand All @@ -76,7 +75,7 @@ target_link_libraries(${camera_target}
gz-transport${GZ_TRANSPORT_VER}::gz-transport${GZ_TRANSPORT_VER}
)

set(depth_camera_sources DepthCameraSensor.cc)
set(depth_camera_sources DepthCameraSensor.cc CameraSensorUtil.cc)
gz_add_component(depth_camera
SOURCES ${depth_camera_sources}
DEPENDS_ON_COMPONENTS camera
Expand Down Expand Up @@ -165,7 +164,7 @@ gz_add_component(force_torque SOURCES ${force_torque_sources} GET_TARGET_NAME fo
set(navsat_sources NavSatSensor.cc)
gz_add_component(navsat SOURCES ${navsat_sources} GET_TARGET_NAME navsat_target)

set(rgbd_camera_sources RgbdCameraSensor.cc)
set(rgbd_camera_sources RgbdCameraSensor.cc CameraSensorUtil.cc)
gz_add_component(rgbd_camera
SOURCES ${rgbd_camera_sources}
DEPENDS_ON_COMPONENTS camera
Expand Down
4 changes: 2 additions & 2 deletions src/CameraSensor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ bool CameraSensor::CreateCamera()
double cx = cameraSdf->LensIntrinsicsCx();
double cy = cameraSdf->LensIntrinsicsCy();
double s = cameraSdf->LensIntrinsicsSkew();
auto projectionMatrix = buildProjectionMatrix(
auto projectionMatrix = gz::sensors::buildProjectionMatrix(
this->dataPtr->camera->ImageWidth(),
this->dataPtr->camera->ImageHeight(),
fx, fy, cx, cy, s,
Expand Down Expand Up @@ -313,7 +313,7 @@ bool CameraSensor::CreateCamera()
double cy = cameraSdf->LensProjectionCy();
double s = 0;

auto projectionMatrix = buildProjectionMatrix(
auto projectionMatrix = gz::sensors::buildProjectionMatrix(
this->dataPtr->camera->ImageWidth(),
this->dataPtr->camera->ImageHeight(),
fx, fy, cx, cy, s,
Expand Down
4 changes: 2 additions & 2 deletions src/DepthCameraSensor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -405,7 +405,7 @@
double cx = cameraSdf->LensIntrinsicsCx();
double cy = cameraSdf->LensIntrinsicsCy();
double s = cameraSdf->LensIntrinsicsSkew();
auto projectionMatrix = buildProjectionMatrix(
auto projectionMatrix = gz::sensors::buildProjectionMatrix(

Check warning on line 408 in src/DepthCameraSensor.cc

View check run for this annotation

Codecov / codecov/patch

src/DepthCameraSensor.cc#L408

Added line #L408 was not covered by tests
this->dataPtr->depthCamera->ImageWidth(),
this->dataPtr->depthCamera->ImageHeight(), fx, fy, cx, cy, s,
this->dataPtr->depthCamera->NearClipPlane(),
Expand Down Expand Up @@ -446,7 +446,7 @@
double cy = cameraSdf->LensProjectionCy();
double s = 0;

auto projectionMatrix = buildProjectionMatrix(
auto projectionMatrix = gz::sensors::buildProjectionMatrix(

Check warning on line 449 in src/DepthCameraSensor.cc

View check run for this annotation

Codecov / codecov/patch

src/DepthCameraSensor.cc#L449

Added line #L449 was not covered by tests
this->dataPtr->depthCamera->ImageWidth(),
this->dataPtr->depthCamera->ImageHeight(),
fx, fy, cx, cy, s,
Expand Down