Skip to content

Commit

Permalink
fixup! remove device required ctor arg
Browse files Browse the repository at this point in the history
  • Loading branch information
maloel committed Oct 4, 2023
1 parent 37ca555 commit e8c80df
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/dds/rs-dds-device-info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ namespace librealsense {

std::shared_ptr< device_interface > dds_device_info::create_device()
{
return std::make_shared< dds_device_proxy >( shared_from_this(), _dev );
auto dev_info = std::dynamic_pointer_cast< dds_device_info >( shared_from_this() );
return std::make_shared< dds_device_proxy >( dev_info, _dev );
}


Expand Down
3 changes: 2 additions & 1 deletion src/dds/rs-dds-device-proxy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include "rs-dds-color-sensor-proxy.h"
#include "rs-dds-depth-sensor-proxy.h"
#include "rs-dds-motion-sensor-proxy.h"
#include "rs-dds-device-info.h"

#include <realdds/dds-device.h>
#include <realdds/dds-stream.h>
Expand Down Expand Up @@ -113,7 +114,7 @@ static rs2_extrinsics to_rs2_extrinsics( const std::shared_ptr< realdds::extrins
}


dds_device_proxy::dds_device_proxy( std::shared_ptr< const device_info > const & dev_info,
dds_device_proxy::dds_device_proxy( std::shared_ptr< const dds_device_info > const & dev_info,
std::shared_ptr< realdds::dds_device > const & dev )
: software_device( dev_info )
, _dds_dev( dev )
Expand Down
3 changes: 2 additions & 1 deletion src/dds/rs-dds-device-proxy.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ namespace librealsense {
class stream;
class dds_sensor_proxy;
class stream_profile_interface;
class dds_device_info;


// This is the rs2 device; it proxies to an actual DDS device that does all the actual
Expand All @@ -50,7 +51,7 @@ class dds_device_proxy : public software_device
std::shared_ptr< realdds::dds_motion_stream > stream ) const;

public:
dds_device_proxy( std::shared_ptr< const device_info > const &, std::shared_ptr< realdds::dds_device > const & dev );
dds_device_proxy( std::shared_ptr< const dds_device_info > const &, std::shared_ptr< realdds::dds_device > const & dev );

void tag_default_profile_of_stream( const std::shared_ptr< stream_profile_interface > & profile,
const std::shared_ptr< const realdds::dds_stream > & stream ) const;
Expand Down

0 comments on commit e8c80df

Please sign in to comment.