diff options
Diffstat (limited to 'kms++util/inc')
-rw-r--r-- | kms++util/inc/kms++util/extcpuframebuffer.h | 7 | ||||
-rw-r--r-- | kms++util/inc/kms++util/resourcemanager.h | 1 |
2 files changed, 5 insertions, 3 deletions
diff --git a/kms++util/inc/kms++util/extcpuframebuffer.h b/kms++util/inc/kms++util/extcpuframebuffer.h index 5d3be74..3652ec4 100644 --- a/kms++util/inc/kms++util/extcpuframebuffer.h +++ b/kms++util/inc/kms++util/extcpuframebuffer.h @@ -9,9 +9,9 @@ class ExtCPUFramebuffer : public IMappedFramebuffer { public: ExtCPUFramebuffer(uint32_t width, uint32_t height, PixelFormat format, - uint8_t* buffer, uint32_t pitch); + uint8_t* buffer, uint32_t size, uint32_t pitch, uint32_t offset); ExtCPUFramebuffer(uint32_t width, uint32_t height, PixelFormat format, - uint8_t* buffers[4], uint32_t pitches[4]); + uint8_t* buffers[4], uint32_t sizes[4], uint32_t pitches[4], uint32_t offsets[4]); virtual ~ExtCPUFramebuffer(); uint32_t width() const { return m_width; } @@ -22,13 +22,14 @@ public: uint32_t stride(unsigned plane) const { return m_planes[plane].stride; } uint32_t size(unsigned plane) const { return m_planes[plane].size; } - uint32_t offset(unsigned plane) const { return 0; } + uint32_t offset(unsigned plane) const { return m_planes[plane].offset; } uint8_t* map(unsigned plane) { return m_planes[plane].map; } private: struct FramebufferPlane { uint32_t size; uint32_t stride; + uint32_t offset; uint8_t *map; }; diff --git a/kms++util/inc/kms++util/resourcemanager.h b/kms++util/inc/kms++util/resourcemanager.h index 92e7b93..42e5000 100644 --- a/kms++util/inc/kms++util/resourcemanager.h +++ b/kms++util/inc/kms++util/resourcemanager.h @@ -11,6 +11,7 @@ public: void reset(); + Card& card() const { return m_card; } Connector* reserve_connector(const std::string& name = ""); Crtc* reserve_crtc(Connector* conn); Plane* reserve_plane(Crtc* crtc, PlaneType type, PixelFormat format = PixelFormat::Undefined); |