test/automated/rwops/TestSupportRWops_Generic.c
author David Ludwig <dludwig@pobox.com>
Tue, 12 Feb 2013 12:57:06 -0500
changeset 8424 3cf9501008f1
parent 5062 e8916fe9cfc8
child 7191 75360622e65f
permissions -rw-r--r--
WinRT: fixed bug: SDL_CreateWindow wouldn't work after an initial window was created + destroyed
     1 /* Generic implementation for file opening routines.
     2 * Customizations for specific platforms should go in alternative files.
     3 */
     4 
     5 // quiet windows compiler warnings
     6 #define _CRT_SECURE_NO_WARNINGS
     7 
     8 #include <stdio.h>
     9 #include "SDL.h"
    10 
    11 const char* RWOPS_READ = "rwops/read";
    12 const char* RWOPS_WRITE = "rwops/write";
    13 
    14 FILE* TestSupportRWops_OpenFPFromReadDir(const char *file, const char *mode)
    15 {
    16 	return fopen(file, mode);
    17 }
    18 
    19 FILE* TestSupportRWops_OpenFPFromWriteDir(const char *file, const char *mode)
    20 {
    21 	return fopen(file, mode);
    22 }
    23 
    24 SDL_RWops* TestSupportRWops_OpenRWopsFromReadDir(const char *file, const char *mode)
    25 {
    26 	return SDL_RWFromFile(file, mode);
    27 }
    28 
    29 SDL_RWops* TestSupportRWops_OpenRWopsFromWriteDir(const char *file, const char *mode)
    30 {
    31 	return SDL_RWFromFile(file, mode);
    32 }