SDL Library

Dependents:   H261_decoder

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers SDL_test_images.h Source File

SDL_test_images.h

Go to the documentation of this file.
00001 /*
00002   Simple DirectMedia Layer
00003   Copyright (C) 1997-2014 Sam Lantinga <slouken@libsdl.org>
00004 
00005   This software is provided 'as-is', without any express or implied
00006   warranty.  In no event will the authors be held liable for any damages
00007   arising from the use of this software.
00008 
00009   Permission is granted to anyone to use this software for any purpose,
00010   including commercial applications, and to alter it and redistribute it
00011   freely, subject to the following restrictions:
00012 
00013   1. The origin of this software must not be misrepresented; you must not
00014      claim that you wrote the original software. If you use this software
00015      in a product, an acknowledgment in the product documentation would be
00016      appreciated but is not required.
00017   2. Altered source versions must be plainly marked as such, and must not be
00018      misrepresented as being the original software.
00019   3. This notice may not be removed or altered from any source distribution.
00020 */
00021 
00022 /**
00023  *  \file SDL_test_images.h
00024  *
00025  *  Include file for SDL test framework.
00026  *
00027  *  This code is a part of the SDL2_test library, not the main SDL library.
00028  */
00029 
00030 /*
00031 
00032  Defines some images for tests.
00033 
00034 */
00035 
00036 #ifndef _SDL_test_images_h
00037 #define _SDL_test_images_h
00038 
00039 #include "SDL.h"
00040 
00041 #include "begin_code.h"
00042 /* Set up for C function definitions, even when using C++ */
00043 #ifdef __cplusplus
00044 extern "C" {
00045 #endif
00046 
00047 /**
00048  *Type for test images.
00049  */
00050 typedef struct SDLTest_SurfaceImage_s {
00051   int width;
00052   int height;
00053   unsigned int bytes_per_pixel; /* 3:RGB, 4:RGBA */
00054   const char *pixel_data;
00055 } SDLTest_SurfaceImage_t;
00056 
00057 /* Test images */
00058 SDL_Surface *SDLTest_ImageBlit();
00059 SDL_Surface *SDLTest_ImageBlitColor();
00060 SDL_Surface *SDLTest_ImageBlitAlpha();
00061 SDL_Surface *SDLTest_ImageBlitBlendAdd();
00062 SDL_Surface *SDLTest_ImageBlitBlend();
00063 SDL_Surface *SDLTest_ImageBlitBlendMod();
00064 SDL_Surface *SDLTest_ImageBlitBlendNone();
00065 SDL_Surface *SDLTest_ImageBlitBlendAll();
00066 SDL_Surface *SDLTest_ImageFace();
00067 SDL_Surface *SDLTest_ImagePrimitives();
00068 SDL_Surface *SDLTest_ImagePrimitivesBlend();
00069 
00070 /* Ends C function definitions when using C++ */
00071 #ifdef __cplusplus
00072 }
00073 #endif
00074 #include "close_code.h"
00075 
00076 #endif /* _SDL_test_images_h */
00077 
00078 /* vi: set ts=4 sw=4 expandtab: */