This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project gfxprim.git.
The branch, master has been updated via 6ce5bcc70a435c39f01488e7dbe225374f56527f (commit) via 4f1e099df9eea9423c5cc44d6ac814642a8bde86 (commit) from f5ba4d748fcead8e9acdce5a110ebb718ee8fd0c (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.
- Log ----------------------------------------------------------------- http://repo.or.cz/w/gfxprim.git/commit/6ce5bcc70a435c39f01488e7dbe225374f565...
commit 6ce5bcc70a435c39f01488e7dbe225374f56527f Author: Cyril Hrubis metan@ucw.cz Date: Sat May 4 23:03:45 2013 +0200
core,gfx: Fix HLine & WritePixels.
* Offset in write pixels is now passed in bits
* The GP_HLine uses correct macros for computing offsets (Fixes modulo by zero on RGB666)
Signed-off-by: Cyril Hrubis metan@ucw.cz
diff --git a/libs/core/GP_WritePixel.c b/libs/core/GP_WritePixel.c index 27b300b..f53ad9f 100644 --- a/libs/core/GP_WritePixel.c +++ b/libs/core/GP_WritePixel.c @@ -189,17 +189,17 @@ void GP_WritePixels_2BPP_LE(void *start, uint8_t off, switch (off) { case 0: break; - case 1: + case 2: GP_SET_BITS1_ALIGNED(2, 2, start, val);
if (--len == 0) return; - case 2: + case 4: GP_SET_BITS1_ALIGNED(4, 2, start, val);
if (--len == 0) return; - case 3: + case 6: GP_SET_BITS1_ALIGNED(6, 2, start, val);
if (--len == 0) @@ -235,17 +235,17 @@ void GP_WritePixels_2BPP_BE(void *start, uint8_t off, switch (off) { case 0: break; - case 1: + case 2: GP_SET_BITS1_ALIGNED(6, 2, start, val);
if (--len == 0) return; - case 2: + case 4: GP_SET_BITS1_ALIGNED(4, 2, start, val);
if (--len == 0) return; - case 3: + case 6: GP_SET_BITS1_ALIGNED(2, 2, start, val);
if (--len == 0) @@ -286,7 +286,7 @@ void GP_WritePixels_4BPP_LE(void *start, uint8_t off, switch (off) { case 0: break; - case 1: + case 4: GP_SET_BITS1_ALIGNED(4, 4, start, val);
if (--len == 0) @@ -318,7 +318,7 @@ void GP_WritePixels_4BPP_BE(void *start, uint8_t off, switch (off) { case 0: break; - case 1: + case 4: GP_SET_BITS1_ALIGNED(0, 4, start, val);
if (--len == 0) diff --git a/libs/gfx/GP_HLine.gen.c.t b/libs/gfx/GP_HLine.gen.c.t index 5e0a761..ce93f98 100644 --- a/libs/gfx/GP_HLine.gen.c.t +++ b/libs/gfx/GP_HLine.gen.c.t @@ -29,6 +29,7 @@
%% block body
+#include "core/GP_GetPutPixel.gen.h" #include "core/GP_WritePixel.h"
#include "gfx/GP_HLine.h" @@ -54,7 +55,9 @@ void GP_HLine_Raw_{{ ps.suffix }}(GP_Context *context, int x0, int x1, int y, void *start = GP_PIXEL_ADDR(context, x0, y);
%% if ps.needs_bit_endian() - GP_WritePixels_{{ ps.suffix }}(start, x0 % (8 / context->bpp), length, pixel); + unsigned int offset = GP_PIXEL_ADDR_OFFSET_{{ ps.suffix }}(x0); + + GP_WritePixels_{{ ps.suffix }}(start, offset, length, pixel); %% else GP_WritePixels_{{ ps.suffix }}(start, length, pixel); %% endif
http://repo.or.cz/w/gfxprim.git/commit/4f1e099df9eea9423c5cc44d6ac814642a8bd...
commit 4f1e099df9eea9423c5cc44d6ac814642a8bde86 Author: Cyril Hrubis metan@ucw.cz Date: Sat May 4 22:28:15 2013 +0200
core: WritePixel: Print Unimplemented on 18BPP
Signed-off-by: Cyril Hrubis metan@ucw.cz
diff --git a/libs/core/GP_WritePixel.gen.c.t b/libs/core/GP_WritePixel.gen.c.t index 2bc89b3..89ecc1f 100644 --- a/libs/core/GP_WritePixel.gen.c.t +++ b/libs/core/GP_WritePixel.gen.c.t @@ -16,7 +16,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, * * Boston, MA 02110-1301 USA * * * - * Copyright (C) 2009-2012 Cyril Hrubis metan@ucw.cz * + * Copyright (C) 2009-2013 Cyril Hrubis metan@ucw.cz * * * *****************************************************************************/
@@ -29,6 +29,7 @@ #include "core/GP_GetSetBits.h" #include "core/GP_GetPutPixel.h" #include "core/GP_WritePixel.gen.h" +#include "core/GP_Debug.h"
{# Some pixel types has hand written optimized functions #} %% set hand_optimized = ['1BPP_LE', '1BPP_BE', @@ -43,12 +44,12 @@ void GP_WritePixels_{{ ps.suffix }}(void *start, uint8_t off, size_t cnt, unsigned int val) { - //TODO: + GP_TODO("Unimplemented"); } %% else void GP_WritePixels_{{ ps.suffix }}(void *start, size_t cnt, unsigned int val) { - //TODO: + GP_TODO("Unimplemented"); } %% endif
-----------------------------------------------------------------------
Summary of changes: libs/core/GP_WritePixel.c | 16 ++++++++-------- libs/core/GP_WritePixel.gen.c.t | 7 ++++--- libs/gfx/GP_HLine.gen.c.t | 5 ++++- 3 files changed, 16 insertions(+), 12 deletions(-)
repo.or.cz automatic notification. Contact project admin jiri.bluebear.dluhos@gmail.com if you want to unsubscribe, or site admin admin@repo.or.cz if you receive no reply.