summaryrefslogtreecommitdiff
path: root/includes/misc.h
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2012-11-17 19:43:59 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2012-11-17 19:43:59 (GMT)
commite3594aba9e05c6865d396418c028049cda92c2f3 (patch)
tree4b825dc642cb6eb9a060e54bf8d69288fbee4904 /includes/misc.h
parentfb43f7d23e99765ae093fc45608901cb5907d1d8 (diff)
downloadpowder-e3594aba9e05c6865d396418c028049cda92c2f3.zip
powder-e3594aba9e05c6865d396418c028049cda92c2f3.tar.gz
Remove old code
Diffstat (limited to 'includes/misc.h')
-rw-r--r--includes/misc.h125
1 files changed, 0 insertions, 125 deletions
diff --git a/includes/misc.h b/includes/misc.h
deleted file mode 100644
index 0253ee9..0000000
--- a/includes/misc.h
+++ /dev/null
@@ -1,125 +0,0 @@
-/**
- * Powder Toy - miscellaneous functions (header)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-#ifndef UTILS_H
-#define UTILS_H
-#include <stdio.h>
-#include <stdlib.h>
-
-#if defined(WIN32) && !defined(__GNUC__)
-#define x86_cpuid(func,af,bf,cf,df) \
- do {\
- __asm mov eax, func\
- __asm cpuid\
- __asm mov af, eax\
- __asm mov bf, ebx\
- __asm mov cf, ecx\
- __asm mov df, edx\
- } while(0)
-#else
-#define x86_cpuid(func,af,bf,cf,df) \
-__asm__ __volatile ("cpuid":\
- "=a" (af), "=b" (bf), "=c" (cf), "=d" (df) : "a" (func));
-#endif
-
-static char hex[] = "0123456789ABCDEF";
-
-//Signum function
-int isign(float i);
-
-unsigned clamp_flt(float f, float min, float max);
-
-float restrict_flt(float f, float min, float max);
-
-char *mystrdup(char *s);
-
-struct strlist
-{
- char *str;
- struct strlist *next;
-};
-
-void strlist_add(struct strlist **list, char *str);
-
-int strlist_find(struct strlist **list, char *str);
-
-void strlist_free(struct strlist **list);
-
-void save_presets(int do_update);
-
-void clean_text(char *text, int vwidth);
-
-void load_presets(void);
-
-void save_string(FILE *f, char *str);
-
-int sregexp(const char *str, char *pattern);
-
-int load_string(FILE *f, char *str, int max);
-
-void strcaturl(char *dst, char *src);
-
-void strappend(char *dst, char *src);
-
-void *file_load(char *fn, int *size);
-
-void clipboard_push_text(char * text);
-
-void draw_bframe();
-
-void erase_bframe();
-
-char * clipboard_pull_text();
-
-extern char *clipboard_text;
-
-int register_extension();
-
-int cpu_check(void);
-
-void HSV_to_RGB(int h,int s,int v,int *r,int *g,int *b);
-
-void RGB_to_HSV(int r,int g,int b,int *h,int *s,int *v);
-
-void membwand(void * dest, void * src, size_t destsize, size_t srcsize);
-// a b
-// c d
-struct matrix2d {
- float a,b,c,d;
-};
-typedef struct matrix2d matrix2d;
-
-// column vector
-struct vector2d {
- float x,y;
-};
-typedef struct vector2d vector2d;
-
-matrix2d m2d_multiply_m2d(matrix2d m1, matrix2d m2);
-vector2d m2d_multiply_v2d(matrix2d m, vector2d v);
-matrix2d m2d_multiply_float(matrix2d m, float s);
-vector2d v2d_multiply_float(vector2d v, float s);
-
-vector2d v2d_add(vector2d v1, vector2d v2);
-vector2d v2d_sub(vector2d v1, vector2d v2);
-
-matrix2d m2d_new(float me0, float me1, float me2, float me3);
-vector2d v2d_new(float x, float y);
-
-extern vector2d v2d_zero;
-extern matrix2d m2d_identity;
-
-#endif