| 72 | } |
| 73 | |
| 74 | static void gst_debug_buffer(GstBuffer* buffer) { |
| 75 | assert(buffer); |
| 76 | const auto now = std::chrono::steady_clock::now().time_since_epoch().count(); |
| 77 | openhd::log::get_default()->debug( |
| 78 | "Buffer info[offset:{}, offset_end:{} duration:{} pts:{} dts:{} now:{}]", |
| 79 | buffer->offset, buffer->offset_end, buffer->duration, buffer->pts, |
| 80 | buffer->dts, now); |
| 81 | } |
| 82 | |
| 83 | // From https://github.com/mshabunin/gstreamer-example/blob/master/main.cpp |
| 84 | static void gst_debug_sample(GstSample* sample) { |