diff options
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/BKE_colortools.h | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/path_util.c | 4 | ||||
-rw-r--r-- | source/blender/blenlib/intern/storage.c | 6 | ||||
-rw-r--r-- | source/blender/blenlib/intern/threads.c | 2 | ||||
-rw-r--r-- | source/blender/blenloader/BLO_sys_types.h | 4 | ||||
-rw-r--r-- | source/blender/editors/screen/glutil.c | 11 | ||||
-rw-r--r-- | source/blender/imbuf/intern/anim_movie.c | 104 | ||||
-rw-r--r-- | source/blender/nodes/intern/node_util.h | 2 | ||||
-rw-r--r-- | source/creator/creator.c | 14 | ||||
-rw-r--r-- | source/gameengine/Converter/BL_ShapeActionActuator.cpp | 4 | ||||
-rw-r--r-- | source/gameengine/Ketsji/KX_IpoActuator.cpp | 5 |
11 files changed, 9 insertions, 149 deletions
diff --git a/source/blender/blenkernel/BKE_colortools.h b/source/blender/blenkernel/BKE_colortools.h index 5b40fa5d758..758789683d5 100644 --- a/source/blender/blenkernel/BKE_colortools.h +++ b/source/blender/blenkernel/BKE_colortools.h @@ -41,8 +41,6 @@ struct rctf; #if defined _WIN32 # define DO_INLINE __inline -#elif defined (__sgi) -# define DO_INLINE #elif defined (__sun) || defined (__sun__) # define DO_INLINE #else diff --git a/source/blender/blenlib/intern/path_util.c b/source/blender/blenlib/intern/path_util.c index f89283178ec..0b750d5fff3 100644 --- a/source/blender/blenlib/intern/path_util.c +++ b/source/blender/blenlib/intern/path_util.c @@ -1155,8 +1155,8 @@ char *BLI_get_folder_version(const int id, const int ver, const int do_check) void BLI_setenv(const char *env, const char*val) { - /* SGI or free windows */ -#if (defined(__sgi) || ((defined(WIN32) || defined(WIN64)) && defined(FREE_WINDOWS))) + /* free windows */ +#if (defined(WIN32) || defined(WIN64)) && defined(FREE_WINDOWS) char *envstr= MEM_mallocN(sizeof(char) * (strlen(env) + strlen(val) + 2), "envstr"); /* one for = another for \0 */ sprintf(envstr, "%s=%s", env, val); diff --git a/source/blender/blenlib/intern/storage.c b/source/blender/blenlib/intern/storage.c index 67e27063fd0..04a6d15a0ea 100644 --- a/source/blender/blenlib/intern/storage.c +++ b/source/blender/blenlib/intern/storage.c @@ -45,7 +45,7 @@ #include <time.h> #include <sys/stat.h> -#if defined (__sun__) || defined (__sun) || defined (__sgi) || defined (__NetBSD__) +#if defined (__sun__) || defined (__sun) || defined (__NetBSD__) #include <sys/statvfs.h> /* Other modern unix os's should probably use this also */ #elif !defined(__FreeBSD__) && !defined(linux) && (defined(__sparc) || defined(__sparc__)) #include <sys/statfs.h> @@ -165,7 +165,7 @@ double BLI_diskfree(const char *dir) return (double) (freec*bytesps*sectorspc); #else -#if defined (__sun__) || defined (__sun) || defined (__sgi) || defined (__NetBSD__) +#if defined (__sun__) || defined (__sun) || defined (__NetBSD__) struct statvfs disk; #else struct statfs disk; @@ -187,7 +187,7 @@ double BLI_diskfree(const char *dir) if (statfs(name, &disk)) return(-1); #endif -#if defined (__sun__) || defined (__sun) || defined (__sgi) || defined (__NetBSD__) +#if defined (__sun__) || defined (__sun) || defined (__NetBSD__) if (statvfs(name, &disk)) return(-1); #elif !defined(__FreeBSD__) && !defined(linux) && (defined(__sparc) || defined(__sparc__)) /* WARNING - This may not be supported by geeneric unix os's - Campbell */ diff --git a/source/blender/blenlib/intern/threads.c b/source/blender/blenlib/intern/threads.c index 7b59a7905aa..f9cd675dd8c 100644 --- a/source/blender/blenlib/intern/threads.c +++ b/source/blender/blenlib/intern/threads.c @@ -318,8 +318,6 @@ int BLI_system_thread_count( void ) mib[1] = HW_NCPU; len = sizeof(t); sysctl(mib, 2, &t, &len, NULL, 0); -# elif defined(__sgi) - t = sysconf(_SC_NPROC_ONLN); # else t = (int)sysconf(_SC_NPROCESSORS_ONLN); # endif diff --git a/source/blender/blenloader/BLO_sys_types.h b/source/blender/blenloader/BLO_sys_types.h index 4b3902dca43..8c0996528c6 100644 --- a/source/blender/blenloader/BLO_sys_types.h +++ b/source/blender/blenloader/BLO_sys_types.h @@ -99,7 +99,7 @@ unsigned long __attribute__((__stdcall__)) htonl(unsigned long); #else - /* FreeBSD, Irix, Solaris */ + /* FreeBSD, Solaris */ #include <sys/types.h> #endif /* ifdef platform for types */ @@ -118,7 +118,7 @@ unsigned long __attribute__((__stdcall__)) htonl(unsigned long); #include <sys/param.h> #elif defined (__APPLE__) #include <sys/types.h> -#else /* irix sun linux */ +#else /* sun linux */ #include <netinet/in.h> #endif /* ifdef platform for htonl/ntohl */ diff --git a/source/blender/editors/screen/glutil.c b/source/blender/editors/screen/glutil.c index f56ae17d366..589d652a275 100644 --- a/source/blender/editors/screen/glutil.c +++ b/source/blender/editors/screen/glutil.c @@ -279,18 +279,7 @@ void setlinestyle(int nr) void set_inverted_drawing(int enable) { glLogicOp(enable?GL_INVERT:GL_COPY); - - /* Use GL_BLEND_EQUATION_EXT on sgi (if we have it), - * apparently GL_COLOR_LOGIC_OP doesn't work on O2? - * Is this an sgi bug or our bug? - */ -#if defined(__sgi) && defined(GL_BLEND_EQUATION_EXT) - glBlendEquationEXT(enable?GL_LOGIC_OP:GL_FUNC_ADD_EXT); - glToggle(GL_BLEND, enable); -#else glToggle(GL_COLOR_LOGIC_OP, enable); -#endif - glToggle(GL_DITHER, !enable); } diff --git a/source/blender/imbuf/intern/anim_movie.c b/source/blender/imbuf/intern/anim_movie.c index c4fe1523e90..3c3cecc0e96 100644 --- a/source/blender/imbuf/intern/anim_movie.c +++ b/source/blender/imbuf/intern/anim_movie.c @@ -114,109 +114,6 @@ #endif #endif -/****/ - -#ifdef __sgi - -#include <dmedia/moviefile.h> - -static void movie_printerror(char * str) { - const char * errstr = mvGetErrorStr(mvGetErrno()); - - if (str) { - if (errstr) printf("%s: %s\n", str, errstr); - else printf("%s: returned error\n", str); - } else printf("%s\n", errstr); -} - -static int startmovie(struct anim * anim) { - if (anim == 0) return(-1); - - if ( mvOpenFile (anim->name, O_BINARY|O_RDONLY, &anim->movie ) != DM_SUCCESS ) { - printf("Can't open movie: %s\n", anim->name); - return(-1); - } - if ( mvFindTrackByMedium (anim->movie, DM_IMAGE, &anim->track) != DM_SUCCESS ) { - printf("No image track in movie: %s\n", anim->name); - mvClose(anim->movie); - return(-1); - } - - anim->duration = mvGetTrackLength (anim->track); - anim->params = mvGetParams( anim->track ); - - anim->x = dmParamsGetInt( anim->params, DM_IMAGE_WIDTH); - anim->y = dmParamsGetInt( anim->params, DM_IMAGE_HEIGHT); - anim->interlacing = dmParamsGetEnum (anim->params, DM_IMAGE_INTERLACING); - anim->orientation = dmParamsGetEnum (anim->params, DM_IMAGE_ORIENTATION); - anim->framesize = dmImageFrameSize(anim->params); - - anim->curposition = 0; - anim->preseek = 0; - - /*printf("x:%d y:%d size:%d interl:%d dur:%d\n", anim->x, anim->y, anim->framesize, anim->interlacing, anim->duration);*/ - return (0); -} - -static ImBuf * movie_fetchibuf(struct anim * anim, int position) { - ImBuf * ibuf; -/* extern rectcpy(); */ - int size; - unsigned int *rect1, *rect2; - - if (anim == 0) return (0); - - ibuf = IMB_allocImBuf(anim->x, anim->y, 24, IB_rect); - - if ( mvReadFrames(anim->track, position, 1, ibuf->x * ibuf->y * - sizeof(int), ibuf->rect ) != DM_SUCCESS ) { - movie_printerror("mvReadFrames"); - IMB_freeImBuf(ibuf); - return(0); - } - -/* - if (anim->interlacing == DM_IMAGE_INTERLACED_EVEN) { - rect1 = ibuf->rect + (ibuf->x * ibuf->y) - 1; - rect2 = rect1 - ibuf->x; - - for (size = ibuf->x * (ibuf->y - 1); size > 0; size--){ - *rect1-- = *rect2--; - } - } -*/ - - if (anim->interlacing == DM_IMAGE_INTERLACED_EVEN) - { - rect1 = ibuf->rect; - rect2 = rect1 + ibuf->x; - - for (size = ibuf->x * (ibuf->y - 1); size > 0; size--){ - *rect1++ = *rect2++; - } - } - /*if (anim->orientation == DM_TOP_TO_BOTTOM) IMB_flipy(ibuf);*/ - - - return(ibuf); -} - -static void free_anim_movie(struct anim * anim) { - if (anim == NULL) return; - - if (anim->movie) { - mvClose(anim->movie); - anim->movie = NULL; - } - anim->duration = 0; -} - -int ismovie(char *name) { - return (mvIsMovieFile(name) == DM_TRUE); -} - -#else - int ismovie(const char *UNUSED(name)) { return 0; } @@ -226,7 +123,6 @@ static int startmovie(struct anim *UNUSED(anim)) { return 1; } static ImBuf * movie_fetchibuf(struct anim *UNUSED(anim), int UNUSED(position)) { return NULL; } static void free_anim_movie(struct anim *UNUSED(anim)) { ; } -#endif #if defined(_WIN32) # define PATHSEPERATOR '\\' diff --git a/source/blender/nodes/intern/node_util.h b/source/blender/nodes/intern/node_util.h index 8d38d57f577..885c48599f8 100644 --- a/source/blender/nodes/intern/node_util.h +++ b/source/blender/nodes/intern/node_util.h @@ -66,8 +66,6 @@ const char *node_filter_label(struct bNode *node); // this is needed for inlining behaviour #if defined _WIN32 # define DO_INLINE __inline -#elif defined (__sgi) -# define DO_INLINE #elif defined (__sun) || defined (__sun__) # define DO_INLINE #else diff --git a/source/creator/creator.c b/source/creator/creator.c index 91c2d74dc26..56108f6c251 100644 --- a/source/creator/creator.c +++ b/source/creator/creator.c @@ -46,12 +46,6 @@ #include <stddef.h> #include <string.h> -/* for setuid / getuid */ -#ifdef __sgi -#include <sys/types.h> -#include <unistd.h> -#endif - /* This little block needed for linking to Blender... */ #include "MEM_guardedalloc.h" @@ -156,7 +150,7 @@ char btempdir[FILE_MAX]; static void setCallbacks(void); /* set breakpoints here when running in debug mode, useful to catch floating point errors */ -#if defined(__sgi) || defined(__linux__) || defined(_WIN32) || defined(OSX_SSE_FPE) +#if defined(__linux__) || defined(_WIN32) || defined(OSX_SSE_FPE) static void fpe_handler(int UNUSED(sig)) { // printf("SIGFPE trapped\n"); @@ -365,7 +359,7 @@ static int debug_mode(int UNUSED(argc), const char **UNUSED(argv), void *data) static int set_fpe(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data)) { -#if defined(__sgi) || defined(__linux__) || defined(_WIN32) || defined(OSX_SSE_FPE) +#if defined(__linux__) || defined(_WIN32) || defined(OSX_SSE_FPE) /* zealous but makes float issues a heck of a lot easier to find! * set breakpoints on fpe_handler */ signal(SIGFPE, fpe_handler); @@ -1193,10 +1187,6 @@ int main(int argc, const char **argv) BLI_argsParse(ba, 1, NULL, NULL); -#ifdef __sgi - setuid(getuid()); /* end superuser */ -#endif - #if defined(WITH_PYTHON_MODULE) || defined(WITH_HEADLESS) G.background= 1; /* python module mode ALWAYS runs in background mode (for now) */ #else diff --git a/source/gameengine/Converter/BL_ShapeActionActuator.cpp b/source/gameengine/Converter/BL_ShapeActionActuator.cpp index ac377cdb7ca..c81ff107a98 100644 --- a/source/gameengine/Converter/BL_ShapeActionActuator.cpp +++ b/source/gameengine/Converter/BL_ShapeActionActuator.cpp @@ -32,11 +32,7 @@ */ -#if defined (__sgi) -#include <math.h> -#else #include <cmath> -#endif #include "SCA_LogicManager.h" #include "BL_ShapeActionActuator.h" diff --git a/source/gameengine/Ketsji/KX_IpoActuator.cpp b/source/gameengine/Ketsji/KX_IpoActuator.cpp index aed6c666404..cc5a8ecc727 100644 --- a/source/gameengine/Ketsji/KX_IpoActuator.cpp +++ b/source/gameengine/Ketsji/KX_IpoActuator.cpp @@ -33,12 +33,7 @@ * \ingroup ketsji */ - -#if defined (__sgi) -#include <math.h> -#else #include <cmath> -#endif #include "KX_IpoActuator.h" #include "KX_GameObject.h" |