diff --git a/make.sh b/make.sh new file mode 100755 index 0000000..6e5b564 --- /dev/null +++ b/make.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +PROGRAM=testSDL + +clear; clear; g++ -x c -g -fmax-errors=5 -pedantic -Wall -Wextra -o $PROGRAM $PROGRAM.c -lSDL2 2>&1 >/dev/null && ./$PROGRAM diff --git a/s3l.h b/s3l.h index d9fb6ce..dfd64ae 100644 --- a/s3l.h +++ b/s3l.h @@ -10,6 +10,25 @@ -------------------- + This work's goal is to never be encumbered by any exclusive intellectual + property rights. The work is therefore provided under CC0 1.0 + additional + WAIVER OF ALL INTELLECTUAL PROPERTY RIGHTS that waives the rest of + intellectual property rights not already waived by CC0 1.0. The WAIVER OF ALL + INTELLECTUAL PROPERTY RGHTS is as follows: + + Each contributor to this work agrees that they waive any exclusive rights, + including but not limited to copyright, patents, trademark, trade dress, + industrial design, plant varieties and trade secrets, to any and all ideas, + concepts, processes, discoveries, improvements and inventions conceived, + discovered, made, designed, researched or developed by the contributor either + solely or jointly with others, which relate to this work or result from this + work. Should any waiver of such right be judged legally invalid or + ineffective under applicable law, the contributor hereby grants to each + affected person a royalty-free, non transferable, non sublicensable, non + exclusive, irrevocable and unconditional license to this right. + + -------------------- + CONVENTIONS: Angles are in S3L_Units, a full angle (2 pi) is S3L_FRACTIONS_PER_UNITs. diff --git a/testSDL.c b/testSDL.c index f5c2b67..c8d36ca 100644 --- a/testSDL.c +++ b/testSDL.c @@ -78,7 +78,7 @@ conf.mode = S3L_MODE_TRIANGLES; int cent = (x0 + x1 + x2) / 3.0; x2 = cent + (x2 - cent) * sin(frame * 0.01) * 2; - S3L_drawTriangle(x0,y0,x1,y1,x2,y2,conf); + S3L_drawTriangle(x0,y0,x1,y1,x2,y2,conf,0); setPixel(x0,y0,255,0,0); setPixel(x1,y1,255,0,0); @@ -95,7 +95,7 @@ int16_t rotY1 = 200 + cos((frame + 500) * 0.01) * 50; int16_t rotX2 = 200 + sin((frame + 300) * 0.01) * 50; int16_t rotY2 = 200 + cos((frame + 300) * 0.01) * 50; -S3L_drawTriangle(rotX0,rotY0,rotX1,rotY1,rotX2,rotY2,conf); +S3L_drawTriangle(rotX0,rotY0,rotX1,rotY1,rotX2,rotY2,conf,0); }