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 a2ab269a2f82b1cb6e30c5b9afdddded7f307659 (commit) from d05b5939892335e58f0f578928a89a05df78f2a0 (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/a2ab269a2f82b1cb6e30c5b9afdddded7f307...
commit a2ab269a2f82b1cb6e30c5b9afdddded7f307659 Author: Cyril Hrubis metan@ucw.cz Date: Sun Dec 11 21:05:35 2011 +0100
gfx: Fix merge.
diff --git a/configure b/configure index 36b0418..bb7c7cb 100755 --- a/configure +++ b/configure @@ -167,7 +167,7 @@ if __name__ == '__main__': [header_exists, "jpeglib.h"], "", "-ljpeg"], ["freetype", "A high-quality and portable font engine", - [header_exists, "ft2build.h"], "", ""]], cfg) + [header_exists, "ft2build.h"], "", "`freetype-config --libs`"]], cfg) parser = OptionParser(); diff --git a/include/gfx/GP_Gfx.h b/include/gfx/GP_Gfx.h index ef5a77c..3c36bf0 100644 --- a/include/gfx/GP_Gfx.h +++ b/include/gfx/GP_Gfx.h @@ -48,7 +48,6 @@ #include "GP_Circle.h" #include "GP_Arc.h" #include "GP_Ellipse.h" -#include "GP_Arc.h" #include "GP_Polygon.h" #include "GP_Symbol.h"
diff --git a/libs/text/GP_Font.c b/libs/text/GP_Font.c index 8778ce3..b3b8681 100644 --- a/libs/text/GP_Font.c +++ b/libs/text/GP_Font.c @@ -126,13 +126,12 @@ GP_RetCode GP_FontLoad(GP_Font **pfont, const char *filename) if (pfont == NULL || filename == NULL) return GP_ENULLPTR;
- /* allocate the font metadata structure */ - GP_Font *font = (GP_Font *) calloc(1, sizeof(*font)); + GP_Font *font = malloc(sizeof(*font)); if (font == NULL) return GP_ENOMEM;
- /* open the font file */ FILE *f = fopen(filename, "r"); + if (f == NULL) { result = GP_ENOENT; goto bad; diff --git a/libs/text/Makefile b/libs/text/Makefile index 300ad6e..448c8fb 100644 --- a/libs/text/Makefile +++ b/libs/text/Makefile @@ -1,5 +1,9 @@ TOPDIR=../.. CSOURCES=$(shell ls *.c) LIBNAME=text + include $(TOPDIR)/include.mk include $(TOPDIR)/lib.mk + +GP_FreeType.dep: CFLAGS+=`freetype-config --cflags` +GP_FreeType.o: CFLAGS+=`freetype-config --cflags` diff --git a/pylib/templates/common.c.t b/pylib/templates/common.c.t index b4af2f8..d3fcbd8 100644 --- a/pylib/templates/common.c.t +++ b/pylib/templates/common.c.t @@ -9,3 +9,8 @@ * Maybe opts, adds comma on the right side. */ {% macro maybe_opts_r(opts) %}{% if opts %}{{ opts }}, {% endif %}{% endmacro %} + +/* + * Converts channels to params + */ +{% macro expand_chanslist(chlist) %} {{ chlist[0][0] }}{% for i in chlist %}, {{ i[0] }}{% endfor %}{% endmacro %} diff --git a/tests/SDL/fonttest.c b/tests/SDL/fonttest.c index 4bfa945..feefc73 100644 --- a/tests/SDL/fonttest.c +++ b/tests/SDL/fonttest.c @@ -197,9 +197,9 @@ int main(int argc, char *argv[]) if (argc > 1) { GP_RetCode err; fprintf(stderr, "nLoading font '%s'n", argv[1]); - err = GP_FontLoad(&font, argv[1]); + font = GP_FontFreeTypeLoad(argv[1], 20, 30);
- if (err) { + if (font == NULL) { fprintf(stderr, "Error: %sn", GP_RetCodeName(err)); return 1; }
-----------------------------------------------------------------------
Summary of changes: configure | 2 +- include/gfx/GP_Gfx.h | 1 - libs/text/GP_Font.c | 5 ++--- libs/text/Makefile | 4 ++++ pylib/templates/common.c.t | 5 +++++ tests/SDL/fonttest.c | 4 ++-- 6 files changed, 14 insertions(+), 7 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.