X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=video_widget.h;h=30b4b9b4747343258cc3da68aa7ba8148e72a67b;hb=a1575a3d3bc7c3c37ec83576ab2e1627d1b517bc;hp=24aaea3b6a8129e179ff6c7c23343b7dc4872874;hpb=86c1674e30b19750b55581743c3bdc9a2853dd13;p=pkanalytics diff --git a/video_widget.h b/video_widget.h index 24aaea3..30b4b9b 100644 --- a/video_widget.h +++ b/video_widget.h @@ -44,13 +44,14 @@ public: void mouseReleaseEvent(QMouseEvent *e); void mouseMoveEvent(QMouseEvent *e); - // Should really have a PBO, but this is OK for now. // public due to shared_ptr. struct Frame { unsigned width, height; unsigned chroma_width, chroma_height; - std::unique_ptr data; // Y, followed by Cb, followed by Cr. VideoWidget *owner; // For the freelist. + GLuint pbo; + uint8_t *data; // Persistently mapped into the PBO. Y, followed by Cb, followed by Cr. + size_t need_flush_len; // 0 = no flush needed. }; signals: