commit
7b219c4600
@ -0,0 +1,3 @@
|
||||
This was my first attempt and contributing to any open source software.
|
||||
I made a graphics assignment into an XscreenSave hack. Unfortunately, it
|
||||
was not accepted but I still liked it quite a bit.
|
@ -0,0 +1,31 @@
|
||||
bspline-hack by John Cantrell
|
||||
|
||||
bspline-hack is an xscreensaver hack that draws b-splines in motion.
|
||||
|
||||
Maybe one day this will be included in xscreensaver, but until then:
|
||||
|
||||
To compile:
|
||||
tar -xzvf xscreensaver-4.xx.tar.gz
|
||||
tar -xzvf bspline-hack
|
||||
|
||||
cp bspline-hack.c xscreensaver/hacks/glx
|
||||
cp bspline-hack.config xscreensaver/hacks/config
|
||||
cp particle.xpm xscreensaver/hacks/images
|
||||
cp makefile.in.patch xscreensaver/hacks/glx
|
||||
|
||||
patch ./Makefile.in ./makefile.in.patch
|
||||
cd ../..
|
||||
./configure
|
||||
make
|
||||
|
||||
and finally
|
||||
|
||||
make install
|
||||
|
||||
This has been tested with xscreensaver-4.18 hopefully it will work with
|
||||
other versions but I have not personally tested this.
|
||||
|
||||
Notes:
|
||||
Try a high level of curviness with -points, it looks pretty neat.
|
||||
|
||||
Well that is all and I hope you enjoy this simple program.
|
@ -0,0 +1,436 @@
|
||||
/*bsplines-hack.c - John Cantrell - jdcantrell@gmail.com*/
|
||||
/* bsplines, Copyright (c) 2003 John Cantrell*/
|
||||
/* dangerball, Copyright (c) 2001, 2002 Jamie Zawinski <jwz@jwz.org>
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||
* documentation for any purpose is hereby granted without fee, provided that
|
||||
* the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation. No representations are made about the suitability of this
|
||||
* software for any purpose. It is provided "as is" without express or
|
||||
* implied warranty.
|
||||
*/
|
||||
|
||||
/*NOTES:
|
||||
* Parts of this program were borrowed from dangerball, gears and atunnel.
|
||||
* The bspline algorithm is one based off the one given in the class
|
||||
* EECE636 - Intro to Computer Graphics by Kenneth Carepenter at Kansas
|
||||
* State University
|
||||
*/
|
||||
|
||||
/*REVISION HISTORY:
|
||||
* 05/04/03 - Initial Revision
|
||||
* 05/06/03 - Made the curves plot in 3d
|
||||
* 06/09/03 - Initial attempt at converting into xscreensaver hack
|
||||
* 06/14/03 - Added more options
|
||||
* 06/29/03 - made depth testing optional
|
||||
* 08/18/04 - ported over texture code and updates from current standalone
|
||||
*
|
||||
* todo
|
||||
* mess with color blending
|
||||
* find ways to speed it up
|
||||
*
|
||||
*/
|
||||
|
||||
/*************************************************************/
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <time.h>
|
||||
#include <X11/Intrinsic.h>
|
||||
/*************************************************************/
|
||||
extern XtAppContext app;
|
||||
|
||||
#define PROGCLASS "B-Splines"
|
||||
#define HACK_INIT init
|
||||
#define HACK_DRAW display
|
||||
#define HACK_RESHAPE reshape
|
||||
#define sws_opts xlockmore_opts
|
||||
|
||||
#define DEF_STEPS "30"
|
||||
#define DEF_CURVES "1"
|
||||
#define DEF_SPEED "10"
|
||||
#define DEF_POINTS "10"
|
||||
#define DEF_ANTIALIAS "True"
|
||||
#define DEF_LINE "True"
|
||||
#define DEF_SIZE "2"
|
||||
#define DEF_DOTEXTURE "False"
|
||||
|
||||
|
||||
#define DEFAULTS "*delay: 30000 \n" \
|
||||
"*showFPS: false \n" \
|
||||
"*antialias:" DEF_ANTIALIAS "\n" \
|
||||
"*speed: " DEF_SPEED " \n" \
|
||||
"*steps: " DEF_STEPS "\n" \
|
||||
"*curves: " DEF_CURVES "\n" \
|
||||
"*controlPoints:" DEF_POINTS "\n" \
|
||||
"*lines:" DEF_LINE "\n" \
|
||||
"*size:" DEF_SIZE "\n" \
|
||||
"*dotexture:" DEF_DOTEXTURE "\n"
|
||||
#define sws_opts xlockmore_opts
|
||||
#undef countof
|
||||
#define countof(x) (sizeof((x))/sizeof((*x)))
|
||||
#define randomNumber while ((randomNum = (random()/(float)RAND_MAX))<=.0001) {}
|
||||
|
||||
#include "xlockmore.h"
|
||||
#include "gltrackball.h"
|
||||
#include "xpm-ximage.h"
|
||||
#include "../images/particle.xpm"
|
||||
#define I_HAVE_XPM
|
||||
#include <ctype.h>
|
||||
#include <GL/glu.h>
|
||||
|
||||
static int speed;
|
||||
static int curves;
|
||||
static int steps;
|
||||
static int controlPoints;
|
||||
static float size;
|
||||
static Bool antialias;
|
||||
static Bool lines;
|
||||
static Bool dotexture;
|
||||
|
||||
static XrmOptionDescRec opts[] = {
|
||||
{ "-speed", ".speed", XrmoptionSepArg, 0 },
|
||||
{ "-curves", ".curves", XrmoptionSepArg, 0 },
|
||||
{ "-smoothness", ".smoothness", XrmoptionSepArg, 0 },
|
||||
{ "-curviness", ".curviness", XrmoptionSepArg, 0 },
|
||||
{ "-noantialias", ".noantialias", XrmoptionNoArg, "false" },
|
||||
{ "-points", ".points", XrmoptionNoArg, "false" },
|
||||
{"-dotexture",".dotexture",XrmoptionNoArg,"true"},
|
||||
{ "-size", ".size", XrmoptionSepArg, 0 }
|
||||
|
||||
};
|
||||
|
||||
static argtype vars[] = {
|
||||
{&curves, "curves", "Curves", DEF_CURVES, t_Int},
|
||||
{&speed, "speed", "Speed", DEF_SPEED, t_Int},
|
||||
{&steps, "smoothness", "Smoothness", DEF_STEPS, t_Int},
|
||||
{&controlPoints, "curviness", "Curviness", DEF_STEPS, t_Int},
|
||||
{&antialias, "noantialias", "No Antialias", DEF_ANTIALIAS, t_Bool},
|
||||
{&lines, "points", "Points", DEF_LINE, t_Bool},
|
||||
{&size, "size", "Size", DEF_SIZE, t_Float},
|
||||
{&dotexture, "dotexture", "Do Texture", DEF_DOTEXTURE, t_Bool},
|
||||
};
|
||||
|
||||
ModeSpecOpt sws_opts = {countof(opts), opts, countof(vars), vars, NULL};
|
||||
|
||||
typedef struct {
|
||||
GLXContext *glx_context;
|
||||
int ncolors;
|
||||
XColor *colors;
|
||||
int ccolor;
|
||||
int color_shift;
|
||||
} screen_stuff;
|
||||
|
||||
static screen_stuff *screen = NULL;
|
||||
|
||||
struct lineList {
|
||||
float *x,*y,*z,*dx,*dy,*dz;
|
||||
float r1,g1,b1;
|
||||
float rinc,binc,ginc;
|
||||
int numberOfPoints;
|
||||
struct lineList* previous;
|
||||
struct lineList* next;
|
||||
};
|
||||
|
||||
int width, height;
|
||||
struct lineList* head = NULL;
|
||||
struct lineList* tail = NULL;
|
||||
|
||||
/*blending poly tables*/
|
||||
float* poly1;
|
||||
float* poly2;
|
||||
float* poly3;
|
||||
float* poly4;
|
||||
float texOffset;
|
||||
GLuint texture;
|
||||
/******************************************************************************************/
|
||||
static void LoadTexture(ModeInfo * mi, char **fn)
|
||||
{
|
||||
#if defined( I_HAVE_XPM )
|
||||
XImage *teximage; /* Texture data */
|
||||
|
||||
if ((teximage = xpm_to_ximage(MI_DISPLAY(mi), MI_VISUAL(mi),
|
||||
MI_COLORMAP(mi), fn)) == None) {
|
||||
(void) fprintf(stdout, "Error reading the texture.\n");
|
||||
glDeleteTextures(1, &texture);
|
||||
dotexture = False;
|
||||
#ifdef STANDALONE
|
||||
exit(0);
|
||||
#else
|
||||
return;
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef HAVE_GLBINDTEXTURE
|
||||
glBindTexture(GL_TEXTURE_2D, texture);
|
||||
#endif /* HAVE_GLBINDTEXTURE */
|
||||
glPixelStorei(GL_UNPACK_ALIGNMENT, 4);
|
||||
clear_gl_error();
|
||||
|
||||
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, teximage->width, teximage->height,
|
||||
0, GL_RGBA, GL_UNSIGNED_BYTE, teximage->data);
|
||||
check_gl_error("texture");
|
||||
|
||||
/* Texture parameters, LINEAR scaling for better texture quality */
|
||||
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
|
||||
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
|
||||
|
||||
XDestroyImage(teximage);
|
||||
#else /* !I_HAVE_XPM */
|
||||
dotexture = False;
|
||||
#endif /* !I_HAVE_XPM */
|
||||
}
|
||||
|
||||
/*************************************************************/
|
||||
/* adds a new b-spline loop
|
||||
* first 6 parameters are rgb values for colors
|
||||
* last parameter is the number of control points for b-spline drawing
|
||||
*/
|
||||
void addLoop(
|
||||
float nr1,float ng1,float nb1,float nr2,float ng2,float nb2,int points) {
|
||||
int t=0,a=0;
|
||||
float temp[points+5];
|
||||
struct lineList* new;
|
||||
new = malloc(sizeof(struct lineList));
|
||||
|
||||
/*we add 5 extra points to redraw the fist 4 to get a nice smooth loop*/
|
||||
float *newx = malloc(sizeof(temp));
|
||||
float *newy = malloc(sizeof(temp));
|
||||
float *newz = malloc(sizeof(temp));
|
||||
float *newdx = malloc(sizeof(temp));
|
||||
float *newdy = malloc(sizeof(temp));
|
||||
float *newdz = malloc(sizeof(temp));
|
||||
|
||||
/* add an array of new points */
|
||||
for (t=0;t<points;t++) {
|
||||
float randomNum=0;
|
||||
randomNumber/* macro defined above*/
|
||||
*(newx+t)=randomNum*2-1;
|
||||
randomNumber
|
||||
*(newy+t)=randomNum*2-1;
|
||||
randomNumber
|
||||
*(newz+t)=randomNum*1;
|
||||
randomNumber
|
||||
*(newdx+t)= (randomNum*2-1)/(10*speed);
|
||||
randomNumber
|
||||
*(newdy+t)= (randomNum*2-1)/(10*speed);
|
||||
randomNumber
|
||||
*(newdz+t)= (randomNum*2-1)/(10*speed);
|
||||
}
|
||||
/*add the last few points to make a loop */
|
||||
|
||||
for (t=t;t<points+5;t++) {
|
||||
*(newx+t)=*(newx+a);
|
||||
*(newy+t)=*(newy+a);
|
||||
*(newz+t)=*(newz+a);
|
||||
*(newdx+t)= *(newdx+a);
|
||||
*(newdy+t)= *(newdy+a);
|
||||
*(newdz+t)= *(newdz+a);
|
||||
a++;
|
||||
}
|
||||
|
||||
/*add to the linelist struct*/
|
||||
new->x=newx;
|
||||
new->y=newy;
|
||||
new->z=newz;
|
||||
new->dx=newdx;
|
||||
new->dy=newdy;
|
||||
new->dz=newdz;
|
||||
|
||||
/* set colors */
|
||||
new->r1=nr1;
|
||||
new->g1=ng1;
|
||||
new->b1=nb1;
|
||||
|
||||
/*calculate color blending increments */
|
||||
new->rinc = (nr2-nr1)/(.5*(points)*steps);
|
||||
new->ginc = (ng2-ng1)/(.5*(points)*steps);
|
||||
new->binc = (nb2-nb1)/(.5*(points)*steps);
|
||||
|
||||
new->numberOfPoints=points+4;
|
||||
|
||||
/*set links */
|
||||
new->previous=tail;
|
||||
new->next=NULL;
|
||||
if (head==NULL) {head=new;}
|
||||
if (tail!=NULL) {tail->next=new;}
|
||||
tail=new;
|
||||
}
|
||||
/*************************************************************/
|
||||
void display(ModeInfo *mi) {
|
||||
|
||||
Display *dpy = MI_DISPLAY(mi);
|
||||
Window window = MI_WINDOW(mi);
|
||||
float r, g, b, py, px,pz,rinc,binc,ginc,px1=0.,py1=0.,pz1=0.;
|
||||
float *x, *y, *dx, *dy,*z,*dz;
|
||||
int numPoint=0,points;
|
||||
struct lineList* currentLine;
|
||||
int t,s;
|
||||
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
/*cycle through each curve*/
|
||||
for(currentLine=head;currentLine!=NULL;currentLine=currentLine->next) {
|
||||
numPoint=0;/*current point number*/
|
||||
px1=-1;/* first point unset*/
|
||||
|
||||
x=currentLine->x;
|
||||
y=currentLine->y;
|
||||
z=currentLine->z;
|
||||
dx=currentLine->dx;
|
||||
dy=currentLine->dy;
|
||||
dz=currentLine->dz;
|
||||
rinc = currentLine->rinc;
|
||||
ginc = currentLine->ginc;
|
||||
binc = currentLine->binc;
|
||||
r=currentLine->r1;
|
||||
g=currentLine->g1;
|
||||
b=currentLine->b1;
|
||||
points = currentLine->numberOfPoints;
|
||||
|
||||
/*begin drawing curve*/
|
||||
|
||||
if (!dotexture) {
|
||||
if (lines) {glBegin(GL_LINE_STRIP);}
|
||||
else {glBegin(GL_POINTS);}
|
||||
}
|
||||
for (t=0;t<points-4;t++) {
|
||||
for (s=0;s<steps;s++) {
|
||||
/*find x,y,z pointer math for no reason*/
|
||||
px = ((*x)*(*(poly1+s)) + *(x+1)*(*(poly2+s)) + *(x+2)*(*(poly3+s))
|
||||
+ *(x+3)*(*(poly4+s)));
|
||||
py = ((*y)*(*(poly1+s)) + *(y+1)*(*(poly2+s)) + *(y+2)*(*(poly3+s))
|
||||
+ *(y+3)*(*(poly4+s)));
|
||||
pz = ((*z)*(*(poly1+s)) + *(z+1)*(*(poly2+s)) + *(z+2)*(*(poly3+s))
|
||||
+ *(z+3)*(*(poly4+s)));
|
||||
/*inc colors*/
|
||||
if (((float)numPoint/points)<.3) {r+=rinc;b+=binc;g+=ginc;}
|
||||
else {r-=rinc;g-=ginc;b-=binc;}
|
||||
/*glColor3f(r,g,b);*/
|
||||
glColor4f(r,g,b,(pz+1)/2);
|
||||
if (px1==-1) {px1=px;py1=py;pz1=pz;}
|
||||
|
||||
if (dotexture) {
|
||||
glBegin(GL_TRIANGLE_STRIP);
|
||||
glTexCoord2d(1, 1);
|
||||
glVertex3f(px + texOffset, py + texOffset, pz);
|
||||
glTexCoord2d(0, 1);
|
||||
glVertex3f(px - texOffset, py + texOffset, pz);
|
||||
glTexCoord2d(1, 0);
|
||||
glVertex3f(px + texOffset, py - texOffset, pz);
|
||||
glTexCoord2d(0, 0);
|
||||
glVertex3f(px - texOffset, py - texOffset, pz);
|
||||
glEnd();
|
||||
}
|
||||
else
|
||||
{
|
||||
glVertex3f(px,py,pz);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/*update points */
|
||||
*x+=*dx,*y+=*dy,*z+=*dz;
|
||||
if (*x>1||*x<-1) *dx=-*dx;
|
||||
if (*y>1||*y<-1) *dy=-*dy;
|
||||
if (*z>1||*z<-1) *dz=-*dz;
|
||||
numPoint++,x++,dx++,y++,z++,dz++,dy++;
|
||||
}
|
||||
if (!dotexture) {
|
||||
glVertex3f(px1,py1,pz1);
|
||||
glEnd();
|
||||
}
|
||||
|
||||
/*update the last few points */
|
||||
for (t=0; t<4;t++) {
|
||||
*x+=*dx,*y+=*dy,*z+=*dz;
|
||||
if (*x>1||*x<-1) *dx=-*dx;
|
||||
if (*y>1||*y<-1) *dy=-*dy;
|
||||
if (*z>1||*z<-1) *dz=-*dz;
|
||||
x++,dx++,y++,dy++,z++,dz++;
|
||||
}
|
||||
}
|
||||
if (mi->fps_p) do_fps (mi);
|
||||
glFinish();
|
||||
glXSwapBuffers(dpy, window);
|
||||
}
|
||||
/*************************************************************/
|
||||
void reshape(ModeInfo *mi, int w, int h) {
|
||||
width=w;
|
||||
height=h;
|
||||
glLoadIdentity();
|
||||
glViewport(0,0,w,h);
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glFrustum(-1.0,1.0,-1.0,1.0,-15.0,15.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
}
|
||||
/*************************************************************/
|
||||
void init (ModeInfo *mi) {
|
||||
float s;int p=0;
|
||||
screen_stuff *sp;
|
||||
|
||||
if (!screen) {
|
||||
screen = (screen_stuff *)
|
||||
calloc (MI_NUM_SCREENS(mi), sizeof (screen_stuff));
|
||||
if (!screen) {
|
||||
fprintf(stderr, "%s: out of memory\n", progname);
|
||||
exit(1);
|
||||
}
|
||||
sp = &screen[MI_SCREEN(mi)];
|
||||
}
|
||||
|
||||
sp = &screen[MI_SCREEN(mi)];
|
||||
sp->glx_context = init_GL(mi);
|
||||
|
||||
if (speed<=0) speed=1;
|
||||
|
||||
reshape (mi, MI_WIDTH(mi), MI_HEIGHT(mi));
|
||||
|
||||
glViewport(0,0,width,height);
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glFrustum(-1.0,1.0,-1.0,1.0,-5.0,10.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glClearColor (0.0, 0.0, 0.0, 0.0);
|
||||
|
||||
/*enable smoothing */
|
||||
if (antialias) {
|
||||
glEnable(GL_POINT_SMOOTH);
|
||||
glEnable(GL_LINE_SMOOTH);
|
||||
glEnable(GL_BLEND);
|
||||
glEnable(GL_TEXTURE_2D);
|
||||
glBlendFunc(GL_SRC_ALPHA, GL_ONE);
|
||||
glHint(GL_POINT_SMOOTH_HINT, GL_NICEST);
|
||||
glHint(GL_LINE_SMOOTH_HINT, GL_NICEST);
|
||||
}
|
||||
|
||||
/*set sizes*/
|
||||
glLineWidth(size);
|
||||
glPointSize(size);
|
||||
|
||||
/*init blending poly tables*/
|
||||
|
||||
poly1 = malloc(sizeof(float)*(steps+5));
|
||||
poly2 = malloc(sizeof(float)*(steps+5));
|
||||
poly3 = malloc(sizeof(float)*(steps+5));
|
||||
poly4 = malloc(sizeof(float)*(steps+5));
|
||||
/*these are our blending polynomials. they make a neat graph where at any
|
||||
*given point all four add up to one */
|
||||
for (s=0;s<=1+3*(1.0/steps);s+=1.0/steps) {
|
||||
*(poly1+p)=(1.0/6)*((1-s)*(1-s)*(1-s));
|
||||
*(poly2+p)=(1.0/6)*((s+2)*(1-s)*(1-s)+(s+1)*(1-s)*(2-s)+s*(2-s)*(2-s));
|
||||
*(poly3+p)=(1.0/6)*((s+1)*(s+1)*(1-s)+s*(s+1)*(2-s)+s*s*(3-s));
|
||||
*(poly4+p)=(1.0/6)*s*s*s;
|
||||
p++;
|
||||
}
|
||||
if (dotexture) {
|
||||
texOffset = 13.0/width;
|
||||
glGenTextures(1, &texture);
|
||||
LoadTexture(mi, particle_xpm);
|
||||
}
|
||||
/*add lines - dirty but it works*/
|
||||
if (controlPoints<2) controlPoints=2;
|
||||
addLoop(0.0,1.0,1.0,0.0,0.0,1.0,controlPoints);
|
||||
if (curves>=2) {addLoop(1.0,1.0,0.0,1.0,0.0,0.0,controlPoints);}
|
||||
if (curves>=3) {addLoop(1.0,1.0,1.0,0.0,1.0,0.0,controlPoints);}
|
||||
if (curves>=4) {addLoop(1.0,1.0,1.0,0.45,0.0,0.45,controlPoints);}
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
|
||||
<screensaver name="bspline-hack" _label="B-splines">
|
||||
|
||||
<command arg="-root"/>
|
||||
|
||||
<select id="drawtype">
|
||||
<option id="normal" _label="Lines"/>
|
||||
<option id="points" _label="Points"
|
||||
arg-set="-points"/>
|
||||
<option id="textures" _label="Textures"
|
||||
arg-set="-dotexture"/>
|
||||
</select>
|
||||
|
||||
<number id="curves" type="spinbutton" arg="-curves %"
|
||||
_label="Curves" low="1" high="4" default="1"/>
|
||||
|
||||
<number id="speed" type="slider" arg="-speed %"
|
||||
_label="Speed" _low-label="Slow" _high-label="Fast"
|
||||
low="1" high="50" default="30"
|
||||
convert="invert"/>
|
||||
|
||||
<number id="delay" type="slider" arg="-delay %"
|
||||
_label="Delay" _low-label="Low" _high-label="Lots"
|
||||
low="1" high="100000" default="30000"/>
|
||||
|
||||
<number id="smoothness" type="slider" arg="-smoothness %"
|
||||
_label="Smoothness" _low-label="Jagged" _high-label="Smooth"
|
||||
low="1" high="100" default="30"/>
|
||||
|
||||
<number id="curviness" type="slider" arg="-curviness %"
|
||||
_label="Curviness" _low-label="Circular" _high-label="Tangled Distaster"
|
||||
low="3" high="500" default="10"/>
|
||||
|
||||
<number id="size" type="slider" arg="-size %"
|
||||
_label="Thickness" _low-label="Thin" _high-label="Thick"
|
||||
low="1" high="10" default="2"/>
|
||||
|
||||
<boolean id="antialias" _label="No Antialiasing" arg-set="-noantialias"/>
|
||||
<boolean id="fps" _label="Show Fps" arg-set="-fps"/>
|
||||
|
||||
<_description>
|
||||
Draws b-splines moving around.
|
||||
</_description>
|
||||
</screensaver>
|
@ -0,0 +1,21 @@
|
||||
74c74
|
||||
< buildlwo.c cage.c dolphin.c gears.c lament.c moebius.c \
|
||||
---
|
||||
> buildlwo.c cage.c dolphin.c gears.c bspline-hack.c lament.c moebius.c \
|
||||
99c99
|
||||
< buildlwo.o cage.o dolphin.o gears.o lament.o moebius.o \
|
||||
---
|
||||
> buildlwo.o cage.o dolphin.o gears.o bspline-hack.o lament.o moebius.o \
|
||||
122c122
|
||||
< GL_EXES = cage gears moebius pipes sproingies stairs superquadrics \
|
||||
---
|
||||
> GL_EXES = cage gears bspline-hack moebius pipes sproingies stairs superquadrics \
|
||||
390c390,391
|
||||
<
|
||||
---
|
||||
> bspline-hack: bspline-hack.o $(HACK_OBJS) $(TRACK_OBJS) xpm-ximage.o
|
||||
> $(CC_HACK) -o $@ $@.o xpm-ximage.o $(HACK_OBJS) $(TRACK_OBJS) $(HACK_LIBS) $(XPM_LIBS)
|
||||
642a644,646
|
||||
> bspline-hack.o: ../../config.h
|
||||
> bspline-hack.o: $(HACK_SRC)/images/particle.xpm
|
||||
> bspline-hack.o: $(srcdir)/xpm-ximage.h
|
@ -0,0 +1,202 @@
|
||||
/* XPM */
|
||||
static char * particle_xpm[] = {
|
||||
"32 32 167 2",
|
||||
" c #000000",
|
||||
". c #030303",
|
||||
"+ c #020202",
|
||||
"@ c #050505",
|
||||
"# c #070707",
|
||||
"$ c #060606",
|
||||
"% c #0A0A0A",
|
||||
"& c #0B0B0B",
|
||||
"* c #090909",
|
||||
"= c #0C0C0C",
|
||||
"- c #0E0E0E",
|
||||
"; c #0D0D0D",
|
||||
"> c #080808",
|
||||
", c #040404",
|
||||
"' c #101010",
|
||||
") c #111111",
|
||||
"! c #121212",
|
||||
"~ c #0F0F0F",
|
||||
"{ c #010101",
|
||||
"] c #141414",
|
||||
"^ c #131313",
|
||||
"/ c #161616",
|
||||
"( c #151515",
|
||||
"_ c #181818",
|
||||
": c #191919",
|
||||
"< c #1B1B1B",
|
||||
"[ c #1A1A1A",
|
||||
"} c #1D1D1D",
|
||||
"| c #1C1C1C",
|
||||
"1 c #1E1E1E",
|
||||
"2 c #202020",
|
||||
"3 c #1F1F1F",
|
||||
"4 c #212121",
|
||||
"5 c #222222",
|
||||
"6 c #232323",
|
||||
"7 c #262626",
|
||||
"8 c #242424",
|
||||
"9 c #2C2C2C",
|
||||
"0 c #2B2B2B",
|
||||
"a c #2D2D2D",
|
||||
"b c #292929",
|
||||
"c c #171717",
|
||||
"d c #252525",
|
||||
"e c #282828",
|
||||
"f c #313131",
|
||||
"g c #323232",
|
||||
"h c #353535",
|
||||
"i c #3B3B3B",
|
||||
"j c #3C3C3C",
|
||||
"k c #393939",
|
||||
"l c #383838",
|
||||
"m c #333333",
|
||||
"n c #272727",
|
||||
"o c #3D3D3D",
|
||||
"p c #454545",
|
||||
"q c #484848",
|
||||
"r c #4D4D4D",
|
||||
"s c #4A4A4A",
|
||||
"t c #494949",
|
||||
"u c #414141",
|
||||
"v c #2E2E2E",
|
||||
"w c #363636",
|
||||
"x c #575757",
|
||||
"y c #595959",
|
||||
"z c #5D5D5D",
|
||||
"A c #616161",
|
||||
"B c #5C5C5C",
|
||||
"C c #555555",
|
||||
"D c #4F4F4F",
|
||||
"E c #3F3F3F",
|
||||
"F c #343434",
|
||||
"G c #4E4E4E",
|
||||
"H c #585858",
|
||||
"I c #686868",
|
||||
"J c #727272",
|
||||
"K c #777777",
|
||||
"L c #7C7C7C",
|
||||
"M c #787878",
|
||||
"N c #707070",
|
||||
"O c #6B6B6B",
|
||||
"P c #464646",
|
||||
"Q c #2A2A2A",
|
||||
"R c #5B5B5B",
|
||||
"S c #6C6C6C",
|
||||
"T c #7E7E7E",
|
||||
"U c #979797",
|
||||
"V c #989898",
|
||||
"W c #9C9C9C",
|
||||
"X c #9B9B9B",
|
||||
"Y c #969696",
|
||||
"Z c #858585",
|
||||
"` c #696969",
|
||||
" . c #626262",
|
||||
".. c #505050",
|
||||
"+. c #404040",
|
||||
"@. c #515151",
|
||||
"#. c #676767",
|
||||
"$. c #808080",
|
||||
"%. c #999999",
|
||||
"&. c #ACACAC",
|
||||
"*. c #BDBDBD",
|
||||
"=. c #C8C8C8",
|
||||
"-. c #C4C4C4",
|
||||
";. c #B4B4B4",
|
||||
">. c #8A8A8A",
|
||||
",. c #666666",
|
||||
"'. c #424242",
|
||||
"). c #3A3A3A",
|
||||
"!. c #2F2F2F",
|
||||
"~. c #909090",
|
||||
"{. c #AAAAAA",
|
||||
"]. c #D4D4D4",
|
||||
"^. c #F3F3F3",
|
||||
"/. c #F8F8F8",
|
||||
"(. c #F6F6F6",
|
||||
"_. c #DDDDDD",
|
||||
":. c #B3B3B3",
|
||||
"<. c #919191",
|
||||
"[. c #3E3E3E",
|
||||
"}. c #303030",
|
||||
"|. c #7A7A7A",
|
||||
"1. c #F1F1F1",
|
||||
"2. c #FDFDFD",
|
||||
"3. c #FEFEFE",
|
||||
"4. c #CECECE",
|
||||
"5. c #A0A0A0",
|
||||
"6. c #4C4C4C",
|
||||
"7. c #606060",
|
||||
"8. c #FAFAFA",
|
||||
"9. c #DADADA",
|
||||
"0. c #A1A1A1",
|
||||
"a. c #878787",
|
||||
"b. c #525252",
|
||||
"c. c #656565",
|
||||
"d. c #868686",
|
||||
"e. c #A6A6A6",
|
||||
"f. c #D7D7D7",
|
||||
"g. c #FCFCFC",
|
||||
"h. c #D9D9D9",
|
||||
"i. c #A3A3A3",
|
||||
"j. c #888888",
|
||||
"k. c #9F9F9F",
|
||||
"l. c #B8B8B8",
|
||||
"m. c #E4E4E4",
|
||||
"n. c #ECECEC",
|
||||
"o. c #5E5E5E",
|
||||
"p. c #6F6F6F",
|
||||
"q. c #898989",
|
||||
"r. c #9D9D9D",
|
||||
"s. c #B9B9B9",
|
||||
"t. c #E2E2E2",
|
||||
"u. c #C2C2C2",
|
||||
"v. c #8E8E8E",
|
||||
"w. c #434343",
|
||||
"x. c #373737",
|
||||
"y. c #A2A2A2",
|
||||
"z. c #ABABAB",
|
||||
"A. c #A9A9A9",
|
||||
"B. c #9E9E9E",
|
||||
"C. c #8D8D8D",
|
||||
"D. c #757575",
|
||||
"E. c #5F5F5F",
|
||||
"F. c #838383",
|
||||
"G. c #717171",
|
||||
"H. c #565656",
|
||||
"I. c #646464",
|
||||
"J. c #535353",
|
||||
" . + @ # $ $ % & * % % = = = - ; = % & & * % % > # $ $ @ + ",
|
||||
", . , # $ > * * = = ; - ' ) ' ! ' ) ~ ' ~ & & & = * $ $ $ , { ",
|
||||
"@ , $ $ % % * = ; ' ' ] ] ^ ^ / ( ^ ) ] ! ~ ~ ; ; * * # # $ . . ",
|
||||
"$ $ $ % & & & ~ ! ] ! _ _ : : < : _ _ _ ( ( ^ ! ~ & % * # $ @ , ",
|
||||
"# $ % * = ; ' ! ( _ [ } | | 1 2 1 | | | [ : / ( ! - % % % > $ , ",
|
||||
"> * % & - ) ! ( _ | 3 4 5 6 6 7 7 8 6 2 4 } | ( ] ) ; = = % $ $ ",
|
||||
"> % % - ! ] / _ | 3 6 7 9 0 9 a a 9 0 7 b 8 | | c ] ^ ~ ; % # $ ",
|
||||
"% % - ) ! c : 1 4 d e f g h i j k l m f a n 5 | 1 [ ( ) ; * % # ",
|
||||
"& = ~ ) : : } 4 n 0 f o p q r r s t u u l 9 d 8 5 | ] ! ~ & % * ",
|
||||
"& = ' ^ c } 8 e v w o q x y z A B B C D E F a 0 2 [ c ^ ! ; * & ",
|
||||
"% ; ) ( _ 3 8 v k E G H I J K L M N O B s P k Q 8 1 _ ( ] ' = % ",
|
||||
"; ~ ! c | 2 d v j r R S T U V W X Y Z ` ...k a e 4 } [ ( ) & % ",
|
||||
"; ) ^ : 3 4 e F +.@.#.$.%.&.*.=.-.;.U >.,.@.'.).!.7 1 [ / ) = % ",
|
||||
"~ ! ] : 2 7 a ).q H O ~.{.].^./.(._.:.<.K ...[.}.7 3 [ / ^ ; * ",
|
||||
"- ) c < 5 e !.j G .|.%.*.1.2.3.3./.4.5.Z .6.j v 7 2 < / ! ; % ",
|
||||
"- ! ] [ 2 8 9 ).6.7.L %.=.8.2.3.3.2.9.0.a.,.b.+.m 0 5 } _ ] ~ = ",
|
||||
"- ! ( _ 2 8 9 i G c.d.e.f.g.2.3.3.g.h.i.j. .D [.v 7 2 < c ! ; % ",
|
||||
"- ! ^ [ 2 n }.E C I $.k.l.m.8.2.3.n.*.U $.c.@.[.v d 2 < / ! ; * ",
|
||||
"~ ! ( : 5 Q m o s o.p.q.r.s.f.t._.u.5.v.O H w.k !.7 5 < / ! = % ",
|
||||
"; ! : } 3 8 9 x.u @.R N >.%.y.z.A.B.C.D. .D j f b 5 | [ c ) - % ",
|
||||
"~ ) ' c 3 8 7 9 l '.b.E.O T a.~.~.F.G.E.H.P x.9 d 4 : ( ! ~ = * ",
|
||||
"% - ! c < } 5 e !.k p 6.o.I.c.O S I.A D w.o }.b 8 } _ ( ! - % & ",
|
||||
"& ; ' ) : < } 8 b f w +.s G ..J.H ..s p x.9 0 d 2 [ / ) ) = * % ",
|
||||
"& * = ) ^ c < 3 7 e Q F k j o w.p E k ).v e 4 4 } : ] ) - % * > ",
|
||||
"> * & - ! ( _ < 5 4 d Q a }.!.m g F a 9 Q 5 3 [ < c ) ~ - % * $ ",
|
||||
"> % * ; ' ! ^ _ [ } 2 4 d e 7 b e 0 8 4 6 1 _ _ ] ! ' ; * % $ $ ",
|
||||
"# # * % - ~ ! ^ / : < | 4 2 5 5 5 7 1 } } | / ] ^ ' ; = & # @ $ ",
|
||||
"# $ * % * ; - ) ! / / _ < [ | < [ 3 : : c _ ) ! ~ = * * % $ $ , ",
|
||||
"$ $ @ # & * % - ) ) ' ! _ / c _ c _ / ^ ! ' ' - = * * > $ $ , . ",
|
||||
", , , # > % > * ; - - ' ^ ) ^ ! ! ) ! ! ' - ; % * % # $ # @ , { ",
|
||||
"{ . . $ # $ > % % * & - - - ~ - - ~ ~ ; = % * % % # $ $ $ . { { ",
|
||||
" + , # $ $ # & & > * * * ; & = * & * % & * * $ # , @ . { "};
|
Ładowanie…
Reference in new issue