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 f8e9982dea3d60b4db125a4b6aeb56b661f9fe43 (commit)
from 6cc8cbbe7416776f1349a808a7c12fde991a49aa (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/f8e9982dea3d60b4db125a4b6aeb56b661f9…
commit f8e9982dea3d60b4db125a4b6aeb56b661f9fe43
Author: Cyril Hrubis <metan(a)ucw.cz>
Date: Wed Jan 2 00:36:58 2013 +0100
doc: context: Clarify the context->pixels description.
diff --git a/doc/context.txt b/doc/context.txt
index 0d1d18b..b973f91 100644
--- a/doc/context.txt
+++ b/doc/context.txt
@@ -37,10 +37,17 @@ typedef struct GP_Context {
} GP_Context;
-------------------------------------------------------------------------------
-The 'pixels' field points to the image data, stored as a one-dimensional
-array of byte-aligned lines. (There can be some unused space at the end of
-each line; this is reflected by the 'bytes_per_row' value being greater
-than what would be needed for that pixel format).
+The 'pixels' field points to the image data.
+
+The 'pixels' are stored as a one-dimensional array consisting of byte-aligned
+lines (i.e. each image line starts at whole byte and ends at whole byte). The
+'pixels' array starts exactly at the start of the first line. Each line is
+'bytes_per_row' bytes long. The first pixel may actually start at 'offset' bit
+in the first byte in each line (but only for some sub contexts for pixel types
+that are not byte aligned). The first pixel is followed by the rest of the
+pixels in the image line (there is 'w' pixels in each line) and ends somewhere
+before the end of the line (i.e. there may be padding before the start of the
+next line or in case of subcontexts image data of the parent context).
Rotation
^^^^^^^^
-----------------------------------------------------------------------
Summary of changes:
doc/context.txt | 15 +++++++++++----
1 files changed, 11 insertions(+), 4 deletions(-)
repo.or.cz automatic notification. Contact project admin jiri.bluebear.dluhos(a)gmail.com
if you want to unsubscribe, or site admin admin(a)repo.or.cz if you receive
no reply.
--
gfxprim.git ("A simple 2D graphics library with emphasis on correctness and well-defined operation.")
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 6cc8cbbe7416776f1349a808a7c12fde991a49aa (commit)
via 0adeef8600221b641cdc7dcb94b8a78f8d7b17de (commit)
from 19c17eca8a9cfe5e86527548a50512d43ff26cf0 (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/6cc8cbbe7416776f1349a808a7c12fde991a…
commit 6cc8cbbe7416776f1349a808a7c12fde991a49aa
Merge: 0adeef8 19c17ec
Author: Cyril Hrubis <metan(a)ucw.cz>
Date: Tue Jan 1 21:37:32 2013 +0100
Merge ssh://repo.or.cz/srv/git/gfxprim
http://repo.or.cz/w/gfxprim.git/commit/0adeef8600221b641cdc7dcb94b8a78f8d7b…
commit 0adeef8600221b641cdc7dcb94b8a78f8d7b17de
Author: Cyril Hrubis <metan(a)ucw.cz>
Date: Tue Jan 1 21:36:06 2013 +0100
core: Comment out broken blit optimalization.
The optimalization code for not byte aligned pixels
is wrong and triggers asserts. Comment it out and
make use of the naive implementation for now.
diff --git a/libs/core/GP_Blit.gen.c.t b/libs/core/GP_Blit.gen.c.t
index 07a153c..0c482af 100644
--- a/libs/core/GP_Blit.gen.c.t
+++ b/libs/core/GP_Blit.gen.c.t
@@ -64,7 +64,7 @@ static void blitXYXY_Raw_{{ ps.suffix }}(const GP_Context *src,
GP_PIXEL_ADDR_{{ ps.suffix }}(src, x0, y0 + y),
{{ int(ps.size/8) }} * (x1 - x0 + 1));
%% else
- /* Rectangles may not be bit-aligned in the same way! */
+{# /* Rectangles may not be bit-aligned in the same way! */
/* Alignment (index) of first bits in the first byte */
//TODO: This is wrong for subcontexts where the offset
// needs to be summed with context->offset and moduled
@@ -96,6 +96,7 @@ static void blitXYXY_Raw_{{ ps.suffix }}(const GP_Context *src,
end_p2 += dst->bytes_per_row;
}
} else /* Different bit-alignment, can't use memcpy() */
+#}
blitXYXY_Naive_Raw(src, x0, y0, x1, y1, dst, x2, y2);
%% endif
}
-----------------------------------------------------------------------
Summary of changes:
libs/core/GP_Blit.gen.c.t | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
repo.or.cz automatic notification. Contact project admin jiri.bluebear.dluhos(a)gmail.com
if you want to unsubscribe, or site admin admin(a)repo.or.cz if you receive
no reply.
--
gfxprim.git ("A simple 2D graphics library with emphasis on correctness and well-defined operation.")
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 19c17eca8a9cfe5e86527548a50512d43ff26cf0 (commit)
from 0841a375e21de5071687413607915ed4d5b191bf (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/19c17eca8a9cfe5e86527548a50512d43ff2…
commit 19c17eca8a9cfe5e86527548a50512d43ff26cf0
Author: Tomas Gavenciak <gavento(a)ucw.cz>
Date: Tue Jan 1 21:35:53 2013 +0100
doc: Coding style for Python
diff --git a/doc/coding_style.txt b/doc/coding_style.txt
index b4afeaf..ebd0f3f 100644
--- a/doc/coding_style.txt
+++ b/doc/coding_style.txt
@@ -16,13 +16,13 @@ link:http://www.kernel.org/doc/Documentation/CodingStyle[link] (it's funny and
enligthening reading).
.Indentation and whitespaces
-
+
* We use tabs for indentation and tab is eight spaces wide.
-
+
* Lines should be at most 80 chars long.
-
+
* No additional whitespaces (other than newline) at the end of line.
-
+
* Each file must end with newline (most editors do that automatically, beware
of Kate).
@@ -37,11 +37,11 @@ enligthening reading).
/* WRONG */
if (something) do_work();
do_other();
-
+
/* RIGHT */
if (something)
do_work();
-
+
do_other();
----
@@ -117,7 +117,7 @@ GFXprim Specific Rules
** The basic structures are also typedefed so you can wite 'GP_Context'
instead of 'struct GP_Context'.
** Other uses of typedef are frowned upon.
-
+
* When you add an externally visible symbol, i.e. new API function
please add its name into the corresponding file at 'build/syms/'. You may
also run the 'buld/check_symbols.sh' script to check that you haven't
@@ -126,4 +126,22 @@ GFXprim Specific Rules
Python Coding Style
~~~~~~~~~~~~~~~~~~~
-TODO
+The Python parts of GFXprim follow mostly coding style outlined in
+link:http://www.python.org/dev/peps/pep-0008/[PEP 8].
+The major difference is that the default indent is 2 spaces.
+All files should be ASCII unless required otherwise.
+
+GFXPrim uses CamelCase as described in the C section.
+The names are mostly derived from the corresponding C names without
+the 'GP_' prefix.
+All wrapped symbols of a module are available in the SWIG modules 'foo.c_foo'
+(i.e. 'core.c_core').
+
+Some number and enum types are typedeffed in C, but left as integers
+in the Python interface.
+All constants are available in 'foo.C' submodules (i.e. 'core.C')
+to avoid clutter.
+
+Where this makes sense, functions should be available as methods of
+an object (i.e. 'Context.Copy()' rather than 'Copy(context)'). Be Pythonic.
+
-----------------------------------------------------------------------
Summary of changes:
doc/coding_style.txt | 34 ++++++++++++++++++++++++++--------
1 files changed, 26 insertions(+), 8 deletions(-)
repo.or.cz automatic notification. Contact project admin jiri.bluebear.dluhos(a)gmail.com
if you want to unsubscribe, or site admin admin(a)repo.or.cz if you receive
no reply.
--
gfxprim.git ("A simple 2D graphics library with emphasis on correctness and well-defined operation.")