Items with no label
3335 Discussions

Initializing RGB and depth buffer at max resolution ...

PTozo
Beginner
1,477 Views

Hey all -- just getting started and trying to adapt the RealSense code samples to initialize the camera at max resolution.

By default, the RGB stream starts at 640x480 and the depth stream at 1280x720, and we want max detail.

 

So far I'm adding the following:

 

rs2::config cfg;

cfg.enable_device( device_name ); // device_name is a std::string with the correct serial number of the RealSense camera

cfg.enable_stream( RS2_STREAM_COLOR, 1920, 1080, RS2_FORMAT_RGB8, 30 );

cfg.enable_stream( RS2_STREAM_DEPTH, 1920, 1080, RS2_FORMAT_Z16, 30 );

rs2::pipeline pipe;

pipe.start( cfg );

Unfortunately, this seems to barf. It appears to be adding the depth stream that causes the problem -- but if I I only add the color stream.

What am I missing? Can it not support frames of that size at 30 fps, or am I doing something wrong here?

EDIT: changing both to 640x480 just as a test does appear to work -- so it seems like a built-in limitation. I'll try reducing the resolutions gradually til I find out what it lets me use.

0 Kudos
1 Solution
MartyG
Honored Contributor III
471 Views

1920x1080 resolution is just for the RGB stream. The maximum depth resolution is 1280x720.

View solution in original post

1 Reply
MartyG
Honored Contributor III
472 Views

1920x1080 resolution is just for the RGB stream. The maximum depth resolution is 1280x720.

Reply