# HG changeset patch # User Radek Brich # Date 1193669417 -3600 # Node ID e74bf781067e4de5f788b4a839b351ebc39c6b16 # Parent 3547b885df7e1c8e75db77422279c9762558689e use python-config, strip python version from demos, change [PyRit] to [pyrit] -- should use unix name everywhere diff -r 3547b885df7e -r e74bf781067e Makefile --- a/Makefile Thu Oct 25 16:40:22 2007 +0200 +++ b/Makefile Mon Oct 29 15:50:17 2007 +0100 @@ -6,7 +6,7 @@ LDFLAGS+=-L"C:\Program Files\Python25\libs" -lpython25 MODULENAME=raytracer.pyd else - CCFLAGS+=-fPIC -I/usr/include/python2.4 + CCFLAGS+=-fPIC `python-config --includes` MODULENAME=raytracermodule.so endif diff -r 3547b885df7e -r e74bf781067e demos/demo.py --- a/demos/demo.py Thu Oct 25 16:40:22 2007 +0200 +++ b/demos/demo.py Mon Oct 29 15:50:17 2007 +0100 @@ -1,4 +1,4 @@ -#!/usr/bin/python2.4 +#!/usr/bin/python import sys sys.path.append("../") diff -r 3547b885df7e -r e74bf781067e demos/spheres_ao.py --- a/demos/spheres_ao.py Thu Oct 25 16:40:22 2007 +0200 +++ b/demos/spheres_ao.py Mon Oct 29 15:50:17 2007 +0100 @@ -1,4 +1,4 @@ -#!/usr/bin/python2.4 +#!/usr/bin/python import sys sys.path.append("../") diff -r 3547b885df7e -r e74bf781067e demos/spheres_shadow.py --- a/demos/spheres_shadow.py Thu Oct 25 16:40:22 2007 +0200 +++ b/demos/spheres_shadow.py Mon Oct 29 15:50:17 2007 +0100 @@ -1,4 +1,4 @@ -#!/usr/bin/python2.4 +#!/usr/bin/python import sys sys.path.append("../") diff -r 3547b885df7e -r e74bf781067e demos/triangles_monkey.py --- a/demos/triangles_monkey.py Thu Oct 25 16:40:22 2007 +0200 +++ b/demos/triangles_monkey.py Mon Oct 29 15:50:17 2007 +0100 @@ -1,4 +1,4 @@ -#!/usr/bin/python2.4 +#!/usr/bin/python import sys sys.path.append("../") diff -r 3547b885df7e -r e74bf781067e demos/triangles_sphere.py --- a/demos/triangles_sphere.py Thu Oct 25 16:40:22 2007 +0200 +++ b/demos/triangles_sphere.py Mon Oct 29 15:50:17 2007 +0100 @@ -1,4 +1,4 @@ -#!/usr/bin/python2.4 +#!/usr/bin/python import sys sys.path.append("../") diff -r 3547b885df7e -r e74bf781067e src/raytracermodule.cc --- a/src/raytracermodule.cc Thu Oct 25 16:40:22 2007 +0200 +++ b/src/raytracermodule.cc Mon Oct 29 15:50:17 2007 +0100 @@ -7,6 +7,7 @@ */ #include + #include #include "scene.h" #include "raytracer.h" @@ -446,7 +447,7 @@ if (!PyArg_ParseTuple(args, "(ii)", &w, &h)) return NULL; - printf("[PyRit] Raytracing...\n"); + printf("[pyrit] Raytracing...\n"); data = ((RaytracerObject *)self)->raytracer->render(w, h); if (!data) { Py_INCREF(Py_None); @@ -454,7 +455,7 @@ } // convert data to char - printf("[PyRit] Converting image data (float to char)...\n"); + printf("[pyrit] Converting image data (float to char)...\n"); chardata = (char *) malloc(w*h*3); float *d = data; for (char *c = chardata; c != chardata + w*h*3; c++, d++) { @@ -466,7 +467,7 @@ free(data); o = Py_BuildValue("s#", chardata, w*h*3); free(chardata); - printf("[PyRit] Done.\n"); + printf("[pyrit] Done.\n"); return o; }