Skip to content
Snippets Groups Projects
Commit dcdd9f53 authored by Nicolas Pope's avatar Nicolas Pope
Browse files

Fix remaining unit tests

parent d19e2d1b
No related branches found
No related tags found
1 merge request!311Resolves #296 removal of NvPipe
Pipeline #27139 failed
...@@ -174,12 +174,12 @@ TEST_CASE( "Receiver generating onFrameSet" ) { ...@@ -174,12 +174,12 @@ TEST_CASE( "Receiver generating onFrameSet" ) {
} }
SECTION("a tiled lossy depth frame") { SECTION("a tiled lossy depth frame") {
cv::cuda::GpuMat m(cv::Size(2560,720), CV_8UC4, cv::Scalar(0)); cv::cuda::GpuMat m(cv::Size(2560,720), CV_32F, cv::Scalar(0));
ftl::stream::injectCalibration(&stream, dummy, 0, 0, 1); ftl::stream::injectCalibration(&stream, dummy, 0, 0, 1);
spkt.channel = Channel::Depth; spkt.channel = Channel::Depth;
pkt.frame_count = 2; pkt.frame_count = 2;
pkt.flags = ftl::codecs::kFlagFloat | ftl::codecs::kFlagMappedDepth; pkt.flags = 0;
bool r = encoder.encode(m, pkt); bool r = encoder.encode(m, pkt);
REQUIRE( r ); REQUIRE( r );
...@@ -208,12 +208,13 @@ TEST_CASE( "Receiver generating onFrameSet" ) { ...@@ -208,12 +208,13 @@ TEST_CASE( "Receiver generating onFrameSet" ) {
} }
SECTION("a tiled lossless depth frame") { SECTION("a tiled lossless depth frame") {
cv::cuda::GpuMat m(cv::Size(2560,720), CV_16U, cv::Scalar(0)); cv::cuda::GpuMat m(cv::Size(2560,720), CV_32F, cv::Scalar(0));
ftl::stream::injectCalibration(&stream, dummy, 0, 0, 1); ftl::stream::injectCalibration(&stream, dummy, 0, 0, 1);
spkt.channel = Channel::Depth; spkt.channel = Channel::Depth;
pkt.frame_count = 2; pkt.frame_count = 2;
pkt.flags = ftl::codecs::kFlagFloat; pkt.flags = 0;
pkt.codec = codec_t::HEVC_LOSSLESS;
bool r = encoder.encode(m, pkt); bool r = encoder.encode(m, pkt);
REQUIRE( r ); REQUIRE( r );
......
...@@ -201,7 +201,7 @@ TEST_CASE( "Sender::post() video frames" ) { ...@@ -201,7 +201,7 @@ TEST_CASE( "Sender::post() video frames" ) {
fs.frames[1].create<cv::cuda::GpuMat>(Channel::Depth).create(cv::Size(1280,720), CV_32F); fs.frames[1].create<cv::cuda::GpuMat>(Channel::Depth).create(cv::Size(1280,720), CV_32F);
fs.frames[1].get<cv::cuda::GpuMat>(Channel::Depth).setTo(cv::Scalar(0.0f)); fs.frames[1].get<cv::cuda::GpuMat>(Channel::Depth).setTo(cv::Scalar(0.0f));
sender->set("lossless", true); sender->set("codec", (int)codec_t::HEVC_LOSSLESS);
sender->post(fs); sender->post(fs);
REQUIRE( count == 1 ); REQUIRE( count == 1 );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment