From fab9bb700372008130e5026fa9fe5fd22ac6ec4e Mon Sep 17 00:00:00 2001 From: Tomi Valkeinen Date: Tue, 3 Oct 2017 12:32:52 +0300 Subject: Rework framebuffer classes Drop (I)MappedFramebuffer, as it doesn't really provide any value, and have most of the methods be present in IFramebuffer with default exception throwing implementation. This gives us simpler way to use the framebuffers, as almost always we can just use a pointer to IFramebuffer. --- kms++util/src/testpat.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'kms++util/src/testpat.cpp') diff --git a/kms++util/src/testpat.cpp b/kms++util/src/testpat.cpp index faacda3..cf43d00 100644 --- a/kms++util/src/testpat.cpp +++ b/kms++util/src/testpat.cpp @@ -13,7 +13,7 @@ using namespace std; namespace kms { -static RGB get_test_pattern_pixel(IMappedFramebuffer& fb, unsigned x, unsigned y) +static RGB get_test_pattern_pixel(IFramebuffer& fb, unsigned x, unsigned y) { const unsigned w = fb.width(); const unsigned h = fb.height(); @@ -97,7 +97,7 @@ static RGB get_test_pattern_pixel(IMappedFramebuffer& fb, unsigned x, unsigned y } } -static void draw_test_pattern_part(IMappedFramebuffer& fb, unsigned start_y, unsigned end_y, YUVType yuvt) +static void draw_test_pattern_part(IFramebuffer& fb, unsigned start_y, unsigned end_y, YUVType yuvt) { unsigned x, y; unsigned w = fb.width(); @@ -151,7 +151,7 @@ static void draw_test_pattern_part(IMappedFramebuffer& fb, unsigned start_y, uns } } -static void draw_test_pattern_impl(IMappedFramebuffer& fb, YUVType yuvt) +static void draw_test_pattern_impl(IFramebuffer& fb, YUVType yuvt) { if (fb.height() < 20) { draw_test_pattern_part(fb, 0, fb.height(), yuvt); @@ -181,7 +181,7 @@ static void draw_test_pattern_impl(IMappedFramebuffer& fb, YUVType yuvt) t.join(); } -void draw_test_pattern(IMappedFramebuffer &fb, YUVType yuvt) +void draw_test_pattern(IFramebuffer &fb, YUVType yuvt) { #ifdef DRAW_PERF_PRINT Stopwatch sw; -- cgit v1.2.3