Mercurial > sdl-ios-xcode
comparison src/video/win32/SDL_gdirender.c @ 4929:aa8888658021
Use the enumerated type for blend and scale mode instead of int
Renamed SDL_TextureScaleMode to SDL_ScaleMode
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sun, 12 Dec 2010 15:19:05 -0800 |
parents | e1664f94f026 |
children |
comparison
equal
deleted
inserted
replaced
4927:d716dff4b13e | 4929:aa8888658021 |
---|---|
88 (SDL_RENDERER_SINGLEBUFFER | SDL_RENDERER_PRESENTCOPY | | 88 (SDL_RENDERER_SINGLEBUFFER | SDL_RENDERER_PRESENTCOPY | |
89 SDL_RENDERER_PRESENTFLIP2 | SDL_RENDERER_PRESENTFLIP3 | | 89 SDL_RENDERER_PRESENTFLIP2 | SDL_RENDERER_PRESENTFLIP3 | |
90 SDL_RENDERER_PRESENTDISCARD | SDL_RENDERER_ACCELERATED), | 90 SDL_RENDERER_PRESENTDISCARD | SDL_RENDERER_ACCELERATED), |
91 (SDL_TEXTUREMODULATE_NONE | SDL_TEXTUREMODULATE_ALPHA), | 91 (SDL_TEXTUREMODULATE_NONE | SDL_TEXTUREMODULATE_ALPHA), |
92 (SDL_BLENDMODE_NONE | SDL_BLENDMODE_MASK), | 92 (SDL_BLENDMODE_NONE | SDL_BLENDMODE_MASK), |
93 (SDL_TEXTURESCALEMODE_NONE | SDL_TEXTURESCALEMODE_FAST), | 93 (SDL_SCALEMODE_NONE | SDL_SCALEMODE_FAST), |
94 14, | 94 14, |
95 { | 95 { |
96 SDL_PIXELFORMAT_INDEX8, | 96 SDL_PIXELFORMAT_INDEX8, |
97 SDL_PIXELFORMAT_RGB555, | 97 SDL_PIXELFORMAT_RGB555, |
98 SDL_PIXELFORMAT_RGB565, | 98 SDL_PIXELFORMAT_RGB565, |
578 | 578 |
579 static int | 579 static int |
580 GDI_SetTextureScaleMode(SDL_Renderer * renderer, SDL_Texture * texture) | 580 GDI_SetTextureScaleMode(SDL_Renderer * renderer, SDL_Texture * texture) |
581 { | 581 { |
582 switch (texture->scaleMode) { | 582 switch (texture->scaleMode) { |
583 case SDL_TEXTURESCALEMODE_NONE: | 583 case SDL_SCALEMODE_NONE: |
584 case SDL_TEXTURESCALEMODE_FAST: | 584 case SDL_SCALEMODE_FAST: |
585 return 0; | 585 return 0; |
586 case SDL_TEXTURESCALEMODE_SLOW: | 586 case SDL_SCALEMODE_SLOW: |
587 case SDL_TEXTURESCALEMODE_BEST: | 587 case SDL_SCALEMODE_BEST: |
588 SDL_Unsupported(); | 588 SDL_Unsupported(); |
589 texture->scaleMode = SDL_TEXTURESCALEMODE_FAST; | 589 texture->scaleMode = SDL_SCALEMODE_FAST; |
590 return -1; | 590 return -1; |
591 default: | 591 default: |
592 SDL_Unsupported(); | 592 SDL_Unsupported(); |
593 texture->scaleMode = SDL_TEXTURESCALEMODE_NONE; | 593 texture->scaleMode = SDL_SCALEMODE_NONE; |
594 return -1; | 594 return -1; |
595 } | 595 } |
596 return 0; | 596 return 0; |
597 } | 597 } |
598 | 598 |