4 >SDL_DisplayFormatAlpha</TITLE
7 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+
10 TITLE="SDL Library Documentation"
11 HREF="index.html"><LINK
14 HREF="video.html"><LINK
16 TITLE="SDL_DisplayFormat"
17 HREF="sdldisplayformat.html"><LINK
20 HREF="sdlwarpmouse.html"></HEAD
31 SUMMARY="Header navigation table"
40 >SDL Library Documentation</TH
48 HREF="sdldisplayformat.html"
62 HREF="sdlwarpmouse.html"
73 NAME="SDLDISPLAYFORMATALPHA"
75 >SDL_DisplayFormatAlpha</H1
83 >SDL_DisplayFormatAlpha -- Convert a surface to the display format</DIV
85 CLASS="REFSYNOPSISDIV"
99 CLASS="FUNCSYNOPSISINFO"
100 >#include "SDL.h"</PRE
107 >SDL_DisplayFormatAlpha</B
109 >(SDL_Surface *surface);</CODE
123 >This function takes a surface and copies it to a new surface of the
124 pixel format and colors of the video framebuffer plus an alpha channel,
125 suitable for fast blitting onto the display surface. It calls
127 HREF="sdlconvertsurface.html"
128 >SDL_ConvertSurface</A
131 >If you want to take advantage of hardware colorkey or alpha blit
132 acceleration, you should set the colorkey and alpha value before
133 calling this function.</P
135 >This function can be used to convert a colourkey to an alpha channel,
139 > flag is set on the surface.
140 The generated surface will then be transparent (alpha=0) where the
141 pixels match the colourkey, and opaque (alpha=255) elsewhere.</P
151 >If the conversion fails or runs out of memory, it returns
166 HREF="sdlconvertsurface.html"
167 >SDL_ConvertSurface</A
170 HREF="sdlsetalpha.html"
174 HREF="sdlsetcolorkey.html"
178 HREF="sdldisplayformat.html"
179 >SDL_DisplayFormat</A
182 HREF="sdlsurface.html"
191 SUMMARY="Footer navigation table"
202 HREF="sdldisplayformat.html"
220 HREF="sdlwarpmouse.html"
230 >SDL_DisplayFormat</TD