Update video.cpp

This commit is contained in:
Dzmitry Maladzenkau 2024-04-27 15:24:19 +02:00 committed by GitHub
parent a02f8f3887
commit 2e3f36933d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -118,6 +118,7 @@ GstCaps *Image2rtsp::gst_caps_new_from_image(const sensor_msgs::msg::Image::Shar
{sensor_msgs::image_encodings::BGRA16, "BGRA16"}, {sensor_msgs::image_encodings::BGRA16, "BGRA16"},
{sensor_msgs::image_encodings::MONO8, "GRAY8"}, {sensor_msgs::image_encodings::MONO8, "GRAY8"},
{sensor_msgs::image_encodings::MONO16, "GRAY16_LE"}, {sensor_msgs::image_encodings::MONO16, "GRAY16_LE"},
{sensor_msgs::image_encodings::YUV422, "YUY2"},
}; };
if (msg->is_bigendian){ if (msg->is_bigendian){
@ -170,4 +171,4 @@ void Image2rtsp::topic_callback(const sensor_msgs::msg::Image::SharedPtr msg){
GST_BUFFER_FLAG_SET(buf, GST_BUFFER_FLAG_LIVE); GST_BUFFER_FLAG_SET(buf, GST_BUFFER_FLAG_LIVE);
gst_app_src_push_buffer(appsrc, buf); gst_app_src_push_buffer(appsrc, buf);
} }
} }