mirror of
https://github.com/WiVRn/WiVRn.git
synced 2026-11-20 00:51:32 -08:00
Send feedback if decoder is not initialized
This commit is contained in:
1 parent
72e8a5d84d
commit
ed6cac545e
1 file changed
+11
-2
@@ -547,7 +547,7 @@ void decoder::push_data(std::span<std::span<const uint8_t>> data, uint64_t frame
|
||||
auto [csd, not_csd] = filter_csd(contiguous_data, description.codec);
|
||||
if (csd.empty())
|
||||
{
|
||||
// TODO request I frame
|
||||
// We can't initizale the encoder, drop the data
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -593,8 +593,17 @@ void decoder::push_data(std::span<std::span<const uint8_t>> data, uint64_t frame
|
||||
|
||||
void decoder::frame_completed(xrt::drivers::wivrn::from_headset::feedback & feedback, const xrt::drivers::wivrn::to_headset::video_stream_data_shard::view_info_t & view_info)
|
||||
{
|
||||
// nothing required for decoder, mediacodec will callback when done
|
||||
if (not media_codec)
|
||||
{
|
||||
// If media_codec is not initialized, frame processing ends here
|
||||
auto scene = weak_scene.lock();
|
||||
if (scene)
|
||||
{
|
||||
scene->send_feedback(feedback);
|
||||
}
|
||||
}
|
||||
|
||||
// nothing required for decoder, mediacodec will callback when done
|
||||
feedback.sent_to_decoder = application::now();
|
||||
frame_infos.push(std::make_pair(feedback, view_info));
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user