├── .gitignore ├── BUGS ├── COPYING ├── CREDITS ├── LICENSE ├── Makefile ├── Makefile.aros ├── Makefile.cross ├── Makefile.morphos ├── README-SDL.txt ├── README.md ├── SDL.c ├── SDL_amigasas.c ├── SDL_amigasas2.c ├── SDL_amigastub.c ├── SDL_cdrom.c ├── SDL_error.c ├── SDL_error_c.h ├── SDL_fatal.c ├── SDL_fatal.h ├── SDL_inline.h ├── SDL_lutstub.s ├── SDL_lutstubrel.s ├── SDL_syscdrom.c ├── SDL_syscdrom.h ├── SDLstub.c ├── audio ├── SDL_audio.c ├── SDL_audio.c.bak ├── SDL_audio_c.h ├── SDL_audiocvt.c ├── SDL_audiodev_c.h ├── SDL_audiomem.h ├── SDL_mixer.c ├── SDL_mixer_MMX.h ├── SDL_mixer_MMX_VC.h ├── SDL_mixer_m68k.c ├── SDL_mixer_m68k.h ├── SDL_sysaudio.h ├── SDL_wave.c ├── SDL_wave.h └── amigaos │ ├── SDL_ahiaudio.c │ └── SDL_ahiaudio.h ├── begin_code.h ├── cdrom ├── SDL_cdrom.c ├── SDL_syscdrom.h ├── aix │ └── SDL_syscdrom.c ├── beos │ └── SDL_syscdrom.cc ├── bsdi │ └── SDL_syscdrom.c ├── dc │ └── SDL_syscdrom.c ├── dummy │ └── SDL_syscdrom.c ├── freebsd │ └── SDL_syscdrom.c ├── linux │ └── SDL_syscdrom.c ├── macos │ ├── SDL_syscdrom.c │ └── SDL_syscdrom_c.h ├── macosx │ ├── AudioFilePlayer.c │ ├── AudioFilePlayer.h │ ├── AudioFileReaderThread.c │ ├── CDPlayer.c │ ├── CDPlayer.h │ ├── SDLOSXCAGuard.c │ ├── SDLOSXCAGuard.h │ ├── SDL_syscdrom.c │ └── SDL_syscdrom_c.h ├── mint │ └── SDL_syscdrom.c ├── openbsd │ └── SDL_syscdrom.c ├── os2 │ └── SDL_syscdrom.c ├── osf │ └── SDL_syscdrom.c ├── qnx │ └── SDL_syscdrom.c └── win32 │ └── SDL_syscdrom.c ├── close_code.h ├── cpuinfo └── SDL_cpuinfo.c ├── docs.html ├── docs ├── html │ ├── audio.html │ ├── cdrom.html │ ├── event.html │ ├── eventfunctions.html │ ├── eventstructures.html │ ├── general.html │ ├── guide.html │ ├── guideaboutsdldoc.html │ ├── guideaudioexamples.html │ ├── guidebasicsinit.html │ ├── guidecdromexamples.html │ ├── guidecredits.html │ ├── guideeventexamples.html │ ├── guideexamples.html │ ├── guideinput.html │ ├── guideinputkeyboard.html │ ├── guidepreface.html │ ├── guidethebasics.html │ ├── guidetimeexamples.html │ ├── guidevideo.html │ ├── guidevideoopengl.html │ ├── index.html │ ├── joystick.html │ ├── reference.html │ ├── sdlactiveevent.html │ ├── sdladdtimer.html │ ├── sdlaudiocvt.html │ ├── sdlaudiospec.html │ ├── sdlblitsurface.html │ ├── sdlbuildaudiocvt.html │ ├── sdlcd.html │ ├── sdlcdclose.html │ ├── sdlcdeject.html │ ├── sdlcdname.html │ ├── sdlcdnumdrives.html │ ├── sdlcdopen.html │ ├── sdlcdpause.html │ ├── sdlcdplay.html │ ├── sdlcdplaytracks.html │ ├── sdlcdresume.html │ ├── sdlcdstatus.html │ ├── sdlcdstop.html │ ├── sdlcdtrack.html │ ├── sdlcloseaudio.html │ ├── sdlcolor.html │ ├── sdlcondbroadcast.html │ ├── sdlcondsignal.html │ ├── sdlcondwait.html │ ├── sdlcondwaittimeout.html │ ├── sdlconvertaudio.html │ ├── sdlconvertsurface.html │ ├── sdlcreatecond.html │ ├── sdlcreatecursor.html │ ├── sdlcreatemutex.html │ ├── sdlcreatergbsurface.html │ ├── sdlcreatergbsurfacefrom.html │ ├── sdlcreatesemaphore.html │ ├── sdlcreatethread.html │ ├── sdlcreateyuvoverlay.html │ ├── sdldelay.html │ ├── sdldestroycond.html │ ├── sdldestroymutex.html │ ├── sdldestroysemaphore.html │ ├── sdldisplayformat.html │ ├── sdldisplayformatalpha.html │ ├── sdldisplayyuvoverlay.html │ ├── sdlenablekeyrepeat.html │ ├── sdlenableunicode.html │ ├── sdlenvvars.html │ ├── sdlevent.html │ ├── sdleventstate.html │ ├── sdlexposeevent.html │ ├── sdlfillrect.html │ ├── sdlflip.html │ ├── sdlfreecursor.html │ ├── sdlfreesurface.html │ ├── sdlfreewav.html │ ├── sdlfreeyuvoverlay.html │ ├── sdlgetappstate.html │ ├── sdlgetaudiostatus.html │ ├── sdlgetcliprect.html │ ├── sdlgetcursor.html │ ├── sdlgeterror.html │ ├── sdlgeteventfilter.html │ ├── sdlgetgammaramp.html │ ├── sdlgetkeyname.html │ ├── sdlgetkeystate.html │ ├── sdlgetmodstate.html │ ├── sdlgetmousestate.html │ ├── sdlgetrelativemousestate.html │ ├── sdlgetrgb.html │ ├── sdlgetrgba.html │ ├── sdlgetthreadid.html │ ├── sdlgetticks.html │ ├── sdlgetvideoinfo.html │ ├── sdlgetvideosurface.html │ ├── sdlglattr.html │ ├── sdlglgetattribute.html │ ├── sdlglgetprocaddress.html │ ├── sdlglloadlibrary.html │ ├── sdlglsetattribute.html │ ├── sdlglswapbuffers.html │ ├── sdlinit.html │ ├── sdlinitsubsystem.html │ ├── sdljoyaxisevent.html │ ├── sdljoyballevent.html │ ├── sdljoybuttonevent.html │ ├── sdljoyhatevent.html │ ├── sdljoystickclose.html │ ├── sdljoystickeventstate.html │ ├── sdljoystickgetaxis.html │ ├── sdljoystickgetball.html │ ├── sdljoystickgetbutton.html │ ├── sdljoystickgethat.html │ ├── sdljoystickindex.html │ ├── sdljoystickname.html │ ├── sdljoysticknumaxes.html │ ├── sdljoysticknumballs.html │ ├── sdljoysticknumbuttons.html │ ├── sdljoysticknumhats.html │ ├── sdljoystickopen.html │ ├── sdljoystickopened.html │ ├── sdljoystickupdate.html │ ├── sdlkey.html │ ├── sdlkeyboardevent.html │ ├── sdlkeysym.html │ ├── sdlkillthread.html │ ├── sdllistmodes.html │ ├── sdlloadbmp.html │ ├── sdlloadwav.html │ ├── sdllockaudio.html │ ├── sdllocksurface.html │ ├── sdllockyuvoverlay.html │ ├── sdlmaprgb.html │ ├── sdlmaprgba.html │ ├── sdlmixaudio.html │ ├── sdlmousebuttonevent.html │ ├── sdlmousemotionevent.html │ ├── sdlmutexp.html │ ├── sdlmutexv.html │ ├── sdlnumjoysticks.html │ ├── sdlopenaudio.html │ ├── sdloverlay.html │ ├── sdlpalette.html │ ├── sdlpauseaudio.html │ ├── sdlpeepevents.html │ ├── sdlpixelformat.html │ ├── sdlpollevent.html │ ├── sdlpumpevents.html │ ├── sdlpushevent.html │ ├── sdlquit.html │ ├── sdlquitevent.html │ ├── sdlquitsubsystem.html │ ├── sdlrect.html │ ├── sdlremovetimer.html │ ├── sdlresizeevent.html │ ├── sdlsavebmp.html │ ├── sdlsempost.html │ ├── sdlsemtrywait.html │ ├── sdlsemvalue.html │ ├── sdlsemwait.html │ ├── sdlsemwaittimeout.html │ ├── sdlsetalpha.html │ ├── sdlsetcliprect.html │ ├── sdlsetcolorkey.html │ ├── sdlsetcolors.html │ ├── sdlsetcursor.html │ ├── sdlseteventfilter.html │ ├── sdlsetgamma.html │ ├── sdlsetgammaramp.html │ ├── sdlsetmodstate.html │ ├── sdlsetpalette.html │ ├── sdlsettimer.html │ ├── sdlsetvideomode.html │ ├── sdlshowcursor.html │ ├── sdlsurface.html │ ├── sdlsyswmevent.html │ ├── sdlthreadid.html │ ├── sdlunlockaudio.html │ ├── sdlunlocksurface.html │ ├── sdlunlockyuvoverlay.html │ ├── sdlupdaterect.html │ ├── sdlupdaterects.html │ ├── sdluserevent.html │ ├── sdlvideodrivername.html │ ├── sdlvideoinfo.html │ ├── sdlvideomodeok.html │ ├── sdlwaitevent.html │ ├── sdlwaitthread.html │ ├── sdlwarpmouse.html │ ├── sdlwasinit.html │ ├── sdlwmgetcaption.html │ ├── sdlwmgrabinput.html │ ├── sdlwmiconifywindow.html │ ├── sdlwmsetcaption.html │ ├── sdlwmseticon.html │ ├── sdlwmtogglefullscreen.html │ ├── thread.html │ ├── time.html │ ├── video.html │ └── wm.html ├── images │ └── rainbow.gif ├── index.html └── man3 │ ├── SDLKey.3 │ ├── SDL_ActiveEvent.3 │ ├── SDL_AddTimer.3 │ ├── SDL_AudioCVT.3 │ ├── SDL_AudioSpec.3 │ ├── SDL_BlitSurface.3 │ ├── SDL_BuildAudioCVT.3 │ ├── SDL_CD.3 │ ├── SDL_CDClose.3 │ ├── SDL_CDEject.3 │ ├── SDL_CDName.3 │ ├── SDL_CDNumDrives.3 │ ├── SDL_CDOpen.3 │ ├── SDL_CDPause.3 │ ├── SDL_CDPlay.3 │ ├── SDL_CDPlayTracks.3 │ ├── SDL_CDResume.3 │ ├── SDL_CDStatus.3 │ ├── SDL_CDStop.3 │ ├── SDL_CDtrack.3 │ ├── SDL_CloseAudio.3 │ ├── SDL_Color.3 │ ├── SDL_CondBroadcast.3 │ ├── SDL_CondSignal.3 │ ├── SDL_CondWait.3 │ ├── SDL_CondWaitTimeout.3 │ ├── SDL_ConvertAudio.3 │ ├── SDL_ConvertSurface.3 │ ├── SDL_CreateCond.3 │ ├── SDL_CreateCursor.3 │ ├── SDL_CreateMutex.3 │ ├── SDL_CreateRGBSurface.3 │ ├── SDL_CreateRGBSurfaceFrom.3 │ ├── SDL_CreateSemaphore.3 │ ├── SDL_CreateThread.3 │ ├── SDL_CreateYUVOverlay.3 │ ├── SDL_Delay.3 │ ├── SDL_DestroyCond.3 │ ├── SDL_DestroyMutex.3 │ ├── SDL_DestroySemaphore.3 │ ├── SDL_DisplayFormat.3 │ ├── SDL_DisplayFormatAlpha.3 │ ├── SDL_DisplayYUVOverlay.3 │ ├── SDL_EnableKeyRepeat.3 │ ├── SDL_EnableUNICODE.3 │ ├── SDL_Event.3 │ ├── SDL_EventState.3 │ ├── SDL_ExposeEvent.3 │ ├── SDL_FillRect.3 │ ├── SDL_Flip.3 │ ├── SDL_FreeCursor.3 │ ├── SDL_FreeSurface.3 │ ├── SDL_FreeWAV.3 │ ├── SDL_FreeYUVOverlay.3 │ ├── SDL_GL_GetAttribute.3 │ ├── SDL_GL_GetProcAddress.3 │ ├── SDL_GL_LoadLibrary.3 │ ├── SDL_GL_SetAttribute.3 │ ├── SDL_GL_SwapBuffers.3 │ ├── SDL_GLattr.3 │ ├── SDL_GetAppState.3 │ ├── SDL_GetAudioStatus.3 │ ├── SDL_GetClipRect.3 │ ├── SDL_GetCursor.3 │ ├── SDL_GetError.3 │ ├── SDL_GetEventFilter.3 │ ├── SDL_GetGamma.3 │ ├── SDL_GetGammaRamp.3 │ ├── SDL_GetKeyName.3 │ ├── SDL_GetKeyState.3 │ ├── SDL_GetModState.3 │ ├── SDL_GetMouseState.3 │ ├── SDL_GetRGB.3 │ ├── SDL_GetRGBA.3 │ ├── SDL_GetRelativeMouseState.3 │ ├── SDL_GetThreadID.3 │ ├── SDL_GetTicks.3 │ ├── SDL_GetVideoInfo.3 │ ├── SDL_GetVideoSurface.3 │ ├── SDL_Init.3 │ ├── SDL_InitSubSystem.3 │ ├── SDL_JoyAxisEvent.3 │ ├── SDL_JoyBallEvent.3 │ ├── SDL_JoyButtonEvent.3 │ ├── SDL_JoyHatEvent.3 │ ├── SDL_JoystickClose.3 │ ├── SDL_JoystickEventState.3 │ ├── SDL_JoystickGetAxis.3 │ ├── SDL_JoystickGetBall.3 │ ├── SDL_JoystickGetButton.3 │ ├── SDL_JoystickGetHat.3 │ ├── SDL_JoystickIndex.3 │ ├── SDL_JoystickName.3 │ ├── SDL_JoystickNumAxes.3 │ ├── SDL_JoystickNumBalls.3 │ ├── SDL_JoystickNumButtons.3 │ ├── SDL_JoystickNumHats.3 │ ├── SDL_JoystickOpen.3 │ ├── SDL_JoystickOpened.3 │ ├── SDL_JoystickUpdate.3 │ ├── SDL_KeyboardEvent.3 │ ├── SDL_KillThread.3 │ ├── SDL_ListModes.3 │ ├── SDL_LoadBMP.3 │ ├── SDL_LoadWAV.3 │ ├── SDL_LockAudio.3 │ ├── SDL_LockSurface.3 │ ├── SDL_LockYUVOverlay.3 │ ├── SDL_MapRGB.3 │ ├── SDL_MapRGBA.3 │ ├── SDL_MixAudio.3 │ ├── SDL_MouseButtonEvent.3 │ ├── SDL_MouseMotionEvent.3 │ ├── SDL_NumJoysticks.3 │ ├── SDL_OpenAudio.3 │ ├── SDL_Overlay.3 │ ├── SDL_Palette.3 │ ├── SDL_PauseAudio.3 │ ├── SDL_PeepEvents.3 │ ├── SDL_PixelFormat.3 │ ├── SDL_PollEvent.3 │ ├── SDL_PumpEvents.3 │ ├── SDL_PushEvent.3 │ ├── SDL_Quit.3 │ ├── SDL_QuitEvent.3 │ ├── SDL_QuitSubSystem.3 │ ├── SDL_RWFromFile.3 │ ├── SDL_Rect.3 │ ├── SDL_RemoveTimer.3 │ ├── SDL_ResizeEvent.3 │ ├── SDL_SaveBMP.3 │ ├── SDL_SemPost.3 │ ├── SDL_SemTryWait.3 │ ├── SDL_SemValue.3 │ ├── SDL_SemWait.3 │ ├── SDL_SemWaitTimeout.3 │ ├── SDL_SetAlpha.3 │ ├── SDL_SetClipRect.3 │ ├── SDL_SetColorKey.3 │ ├── SDL_SetColors.3 │ ├── SDL_SetCursor.3 │ ├── SDL_SetEventFilter.3 │ ├── SDL_SetGamma.3 │ ├── SDL_SetGammaRamp.3 │ ├── SDL_SetModState.3 │ ├── SDL_SetPalette.3 │ ├── SDL_SetTimer.3 │ ├── SDL_SetVideoMode.3 │ ├── SDL_ShowCursor.3 │ ├── SDL_Surface.3 │ ├── SDL_SysWMEvent.3 │ ├── SDL_ThreadID.3 │ ├── SDL_UnlockAudio.3 │ ├── SDL_UnlockSurface.3 │ ├── SDL_UnlockYUVOverlay.3 │ ├── SDL_UpdateRect.3 │ ├── SDL_UpdateRects.3 │ ├── SDL_UserEvent.3 │ ├── SDL_VideoDriverName.3 │ ├── SDL_VideoInfo.3 │ ├── SDL_VideoModeOK.3 │ ├── SDL_WM_GetCaption.3 │ ├── SDL_WM_GrabInput.3 │ ├── SDL_WM_IconifyWindow.3 │ ├── SDL_WM_SetCaption.3 │ ├── SDL_WM_SetIcon.3 │ ├── SDL_WM_ToggleFullScreen.3 │ ├── SDL_WaitEvent.3 │ ├── SDL_WaitThread.3 │ ├── SDL_WarpMouse.3 │ ├── SDL_WasInit.3 │ ├── SDL_keysym.3 │ ├── SDL_mutexP.3 │ └── SDL_mutexV.3 ├── dummy.c ├── events ├── SDL_active.c ├── SDL_events.c ├── SDL_events_c.h ├── SDL_expose.c ├── SDL_keyboard.c ├── SDL_mouse.c ├── SDL_mouse.c.bak ├── SDL_quit.c ├── SDL_resize.c └── SDL_sysevents.h ├── file └── SDL_rwops.c ├── gl_dummy ├── dummy.c └── makefile ├── include ├── GL │ ├── Amigamesa.i │ ├── amigamesa.h │ ├── gl.h │ ├── glaux.h │ ├── glext.h │ ├── glsmap.h │ ├── gltk.h │ ├── glu.h │ ├── glut.h │ ├── glx.h │ └── tube.h └── SDL │ ├── SDL.h │ ├── SDL_active.h │ ├── SDL_audio.h │ ├── SDL_byteorder.h │ ├── SDL_cdrom.h │ ├── SDL_config.h │ ├── SDL_config.h.default │ ├── SDL_config.h.in │ ├── SDL_config_amigaos.h │ ├── SDL_config_dreamcast.h │ ├── SDL_config_macos.h │ ├── SDL_config_macosx.h │ ├── SDL_config_minimal.h │ ├── SDL_config_nds.h │ ├── SDL_config_os2.h │ ├── SDL_config_symbian.h │ ├── SDL_config_win32.h │ ├── SDL_copying.h │ ├── SDL_cpuinfo.h │ ├── SDL_endian.h │ ├── SDL_error.h │ ├── SDL_events.h │ ├── SDL_getenv.h │ ├── SDL_joystick.h │ ├── SDL_keyboard.h │ ├── SDL_keysym.h │ ├── SDL_loadso.h │ ├── SDL_main.h │ ├── SDL_mouse.h │ ├── SDL_mutex.h │ ├── SDL_name.h │ ├── SDL_opengl.h │ ├── SDL_platform.h │ ├── SDL_quit.h │ ├── SDL_rwops.h │ ├── SDL_stdinc.h │ ├── SDL_syswm.h │ ├── SDL_thread.h │ ├── SDL_timer.h │ ├── SDL_types.h │ ├── SDL_version.h │ ├── SDL_video.h │ ├── begin_code.h │ ├── close_code.h │ └── doxyfile ├── joystick ├── SDL_joystick.c ├── SDL_joystick_c.h ├── SDL_sysjoystick.c ├── SDL_sysjoystick.h └── dummy │ └── SDL_sysjoystick.c ├── main ├── amigaos │ └── SDL_main.h └── dummy │ └── SDL_dummy_main.c ├── mmx.h ├── mydebug.h ├── readme-amiga.txt ├── stabs.h ├── stdlib ├── SDL_getenv.c ├── SDL_iconv.c ├── SDL_malloc.c ├── SDL_qsort.c ├── SDL_stdlib.c └── SDL_string.c ├── thread ├── SDL_systhread.h ├── SDL_thread_c.h ├── amigaos │ ├── SDL_syscond.c │ ├── SDL_sysmutex.c │ ├── SDL_sysmutex_c.h │ ├── SDL_syssem.c │ ├── SDL_syssem_o.c │ ├── SDL_systhread.c │ ├── SDL_systhread_c.h │ └── SDL_thread.c ├── generic │ ├── SDL_syscond.c │ ├── SDL_sysmutex.c │ ├── SDL_sysmutex_c.h │ ├── SDL_syssem.c │ ├── SDL_systhread.c │ └── SDL_systhread_c.h ├── pth │ ├── SDL_syscond.c │ ├── SDL_sysmutex.c │ ├── SDL_sysmutex_c.h │ ├── SDL_systhread.c │ └── SDL_systhread_c.h └── pthread │ ├── SDL_syscond.c │ ├── SDL_sysmutex.c │ ├── SDL_sysmutex_c.h │ ├── SDL_syssem.c │ ├── SDL_systhread.c │ └── SDL_systhread_c.h ├── timer ├── SDL_systimer.h ├── SDL_timer.c ├── SDL_timer_c.h ├── amigaos │ └── SDL_systimer.c ├── beos │ └── SDL_systimer.c ├── dc │ └── SDL_systimer.c ├── dummy │ └── SDL_systimer.c ├── macos │ ├── FastTimes.c │ ├── FastTimes.h │ ├── SDL_MPWtimer.c │ └── SDL_systimer.c ├── mint │ ├── SDL_systimer.c │ ├── SDL_vbltimer.S │ └── SDL_vbltimer_s.h ├── nds │ └── SDL_systimer.c ├── os2 │ └── SDL_systimer.c ├── riscos │ └── SDL_systimer.c ├── symbian │ └── SDL_systimer.cpp ├── unix │ └── SDL_systimer.c ├── win32 │ └── SDL_systimer.c └── wince │ └── SDL_systimer.c └── video ├── SDL_RLEaccel.c ├── SDL_RLEaccel_c.h ├── SDL_blit.c ├── SDL_blit.h ├── SDL_blit_0.c ├── SDL_blit_1.c ├── SDL_blit_A.c ├── SDL_blit_N.c ├── SDL_bmp.c ├── SDL_cursor.c ├── SDL_cursor_c.h ├── SDL_gamma.c ├── SDL_glfuncs.h ├── SDL_leaks.h ├── SDL_pixels.c ├── SDL_pixels_c.h ├── SDL_stretch.c ├── SDL_stretch_c.h ├── SDL_surface.c ├── SDL_sysvideo.h ├── SDL_sysvideo_o.h ├── SDL_video.c ├── SDL_yuv.c ├── SDL_yuv_sw.c ├── SDL_yuv_sw_c.h ├── SDL_yuvfuncs.h ├── amigaos ├── SDL_agavideo.c ├── SDL_amigaevents.c ├── SDL_amigaevents_c.h ├── SDL_amigamouse.c ├── SDL_amigamouse_c.h ├── SDL_cgxaccel.c ├── SDL_cgxgl.c ├── SDL_cgxgl_c.h ├── SDL_cgxgl_wrapper.c ├── SDL_cgximage.c ├── SDL_cgximage_c.h ├── SDL_cgxmodes.c ├── SDL_cgxmodes_c.h ├── SDL_cgxvideo.c ├── SDL_cgxvideo.h ├── SDL_cgxwm.c ├── SDL_cgxwm_c.h ├── SDL_cgxyuv.c ├── SDL_cgxyuv_c.h └── SDL_syswm.h ├── apollo ├── apolloammxenable.asm ├── apolloammxenable.h ├── asminterface.h ├── blitapollo.asm ├── blitapollo.h ├── colorkeyapollo.asm └── colorkeyapollo.h ├── blank_cursor.h ├── default_cursor.h ├── directfb ├── SDL_DirectFB_events.c ├── SDL_DirectFB_events.h ├── SDL_DirectFB_keys.h ├── SDL_DirectFB_video.c ├── SDL_DirectFB_video.h ├── SDL_DirectFB_yuv.c └── SDL_DirectFB_yuv.h └── dummy ├── SDL_nullevents.c ├── SDL_nullevents_c.h ├── SDL_nullmouse.c ├── SDL_nullmouse_c.h ├── SDL_nullvideo.c └── SDL_nullvideo.h /.gitignore: -------------------------------------------------------------------------------- 1 | #objects 2 | *.go 3 | *.a 4 | /Default/ 5 | .idea/ 6 | -------------------------------------------------------------------------------- /BUGS: -------------------------------------------------------------------------------- 1 | 2 | Bugs are now managed in the SDL bug tracker, here: 3 | 4 | http://bugzilla.libsdl.org/ 5 | 6 | You may report bugs there, and search to see if a given issue has already 7 | been reported, discussed, and maybe even fixed. 8 | 9 | 10 | 11 | You may also find help at the SDL mailing list. Subscription information: 12 | 13 | http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org 14 | 15 | Bug reports are welcome here, but we really appreciate if you use Bugzilla, as 16 | bugs discussed on the mailing list may be forgotten or missed. 17 | 18 | 19 | -------------------------------------------------------------------------------- /CREDITS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/CREDITS -------------------------------------------------------------------------------- /README-SDL.txt: -------------------------------------------------------------------------------- 1 | 2 | Please distribute this file with the SDL runtime environment: 3 | 4 | The Simple DirectMedia Layer (SDL for short) is a cross-platfrom library 5 | designed to make it easy to write multi-media software, such as games and 6 | emulators. 7 | 8 | The Simple DirectMedia Layer library source code is available from: 9 | http://www.libsdl.org/ 10 | 11 | This library is distributed under the terms of the GNU LGPL license: 12 | http://www.gnu.org/copyleft/lesser.html 13 | 14 | -------------------------------------------------------------------------------- /SDL_fatal.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | #ifdef SAVE_RCSID 24 | static char rcsid = 25 | "@(#) $Id: SDL_fatal.h,v 1.3 2003/09/07 17:09:23 gabry Exp $"; 26 | #endif 27 | 28 | /* General fatal signal handling code for SDL */ 29 | 30 | extern void SDL_InstallParachute(void); 31 | extern void SDL_UninstallParachute(void); 32 | 33 | -------------------------------------------------------------------------------- /SDL_lutstub.s: -------------------------------------------------------------------------------- 1 | #NO_APP 2 | gcc2_compiled.: 3 | ___gnu_compiled_c: 4 | .text 5 | .even 6 | .globl _WLUT 7 | 8 | _WLUT: 9 | moveml #0x3f36,sp@- 10 | movel sp@(48),a5 11 | movel sp@(52),a3 12 | movel sp@(56),d2 13 | movel sp@(64),a2 14 | movel sp@(68),d3 15 | movel sp@(72),d4 16 | movel sp@(76),d5 17 | movel sp@(80),d6 18 | movel sp@(84),d7 19 | movel _CyberGfxBase,a6 20 | movel sp@(44),a0 21 | movew a5,d0 22 | movew a3,d1 23 | movel sp@(60),a1 24 | #APP 25 | jsr a6@(-0xc6:W) 26 | #NO_APP 27 | moveml sp@+,#0x6cfc 28 | rts 29 | -------------------------------------------------------------------------------- /SDL_lutstubrel.s: -------------------------------------------------------------------------------- 1 | gcc2_compiled.: 2 | ___gnu_compiled_c: 3 | .text 4 | .even 5 | .globl _mygeta4 6 | .globl _WLUT 7 | 8 | _mygeta4: 9 | movel a6@(40:W),a4 10 | lea a4@(_SysBase:W),a5 11 | rts 12 | 13 | _WLUT: 14 | moveml #0x3f36,sp@- 15 | movel sp@(48),a5 16 | movel sp@(52),a3 17 | movel sp@(56),d2 18 | movel sp@(64),a2 19 | movel sp@(68),d3 20 | movel sp@(72),d4 21 | movel sp@(76),d5 22 | movel sp@(80),d6 23 | movel sp@(84),d7 24 | movel a4@(_CyberGfxBase:W),a6 25 | movel sp@(44),a0 26 | movew a5,d0 27 | movew a3,d1 28 | movel sp@(60),a1 29 | #APP 30 | jsr a6@(-0xc6:W) 31 | #NO_APP 32 | moveml sp@+,#0x6cfc 33 | rts 34 | -------------------------------------------------------------------------------- /SDL_syscdrom.c: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | #ifdef SAVE_RCSID 24 | static char rcsid = 25 | "@(#) $Id: SDL_syscdrom.c,v 1.3 2003/09/07 17:09:24 gabry Exp $"; 26 | #endif 27 | 28 | /* Stub functions for system-level CD-ROM audio control */ 29 | 30 | #include "SDL_cdrom.h" 31 | #include "SDL_syscdrom.h" 32 | 33 | int SDL_SYS_CDInit(void) 34 | { 35 | return(0); 36 | } 37 | 38 | void SDL_SYS_CDQuit(void) 39 | { 40 | return; 41 | } 42 | 43 | -------------------------------------------------------------------------------- /SDLstub.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include "SDL_types.h" 3 | #include "SDL_inline.h" 4 | #include 5 | #include 6 | 7 | struct Library *SDLBase=NULL; 8 | extern struct ExecBase *SysBase; 9 | 10 | int SDL_Init(unsigned long flags) 11 | { 12 | if(!SDLBase) 13 | if(!(SDLBase=OpenLibrary("SDL.library",0L))) 14 | return -1; 15 | 16 | return SDL_RealInit(flags); 17 | } 18 | 19 | void SDL_Quit(void) 20 | { 21 | if(SDLBase) { 22 | SDL_RealQuit(); 23 | CloseLibrary(SDLBase); 24 | SDLBase=NULL; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /audio/SDL_audio_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Functions and variables exported from SDL_audio.c for SDL_sysaudio.c */ 25 | 26 | /* Functions to get a list of "close" audio formats */ 27 | extern Uint16 SDL_FirstAudioFormat(Uint16 format); 28 | extern Uint16 SDL_NextAudioFormat(void); 29 | 30 | /* Function to calculate the size and silence for a SDL_AudioSpec */ 31 | extern void SDL_CalculateAudioSpec(SDL_AudioSpec *spec); 32 | 33 | /* The actual mixing thread function */ 34 | extern int SDLCALL SDL_RunAudio(void *audiop); 35 | -------------------------------------------------------------------------------- /audio/SDL_audiodev_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Open the audio device, storing the pathname in 'path' */ 25 | extern int SDL_OpenAudioPath(char *path, int maxlen, int flags, int classic); 26 | 27 | -------------------------------------------------------------------------------- /audio/SDL_audiomem.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #define SDL_AllocAudioMem SDL_malloc 25 | #define SDL_FreeAudioMem SDL_free 26 | -------------------------------------------------------------------------------- /audio/SDL_mixer_MMX.h: -------------------------------------------------------------------------------- 1 | /* 2 | headers for MMX assembler version of SDL_MixAudio 3 | Copyright 2002 Stephane Marchesin (stephane.marchesin@wanadoo.fr) 4 | This code is licensed under the LGPL (see COPYING for details) 5 | 6 | Assumes buffer size in bytes is a multiple of 16 7 | Assumes SDL_MIX_MAXVOLUME = 128 8 | */ 9 | #include "SDL_config.h" 10 | 11 | #if defined(__GNUC__) && defined(__i386__) && defined(SDL_ASSEMBLY_ROUTINES) 12 | void SDL_MixAudio_MMX_S16(char* ,char* ,unsigned int ,int ); 13 | void SDL_MixAudio_MMX_S8(char* ,char* ,unsigned int ,int ); 14 | #endif 15 | 16 | -------------------------------------------------------------------------------- /audio/SDL_mixer_MMX_VC.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | 25 | #if ((defined(_MSC_VER) && defined(_M_IX86)) || defined(__WATCOMC__)) && defined(SDL_ASSEMBLY_ROUTINES) 26 | /* headers for MMX assembler version of SDL_MixAudio 27 | Copyright 2002 Stephane Marchesin (stephane.marchesin@wanadoo.fr) 28 | Converted to Intel ASM notation by Cth 29 | This code is licensed under the LGPL (see COPYING for details) 30 | 31 | Assumes buffer size in bytes is a multiple of 16 32 | Assumes SDL_MIX_MAXVOLUME = 128 33 | */ 34 | void SDL_MixAudio_MMX_S16_VC(char* ,char* ,unsigned int ,int ); 35 | void SDL_MixAudio_MMX_S8_VC(char* ,char* ,unsigned int ,int ); 36 | #endif 37 | -------------------------------------------------------------------------------- /audio/SDL_mixer_m68k.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* 25 | m68k assembly mix routines 26 | 27 | Patrice Mandin 28 | */ 29 | 30 | #if defined(__M68000__) && defined(__GNUC__) 31 | void SDL_MixAudio_m68k_U8(char* dst,char* src, long len, long volume, char* mix8); 32 | void SDL_MixAudio_m68k_S8(char* dst,char* src, long len, long volume); 33 | 34 | void SDL_MixAudio_m68k_S16MSB(short* dst,short* src, long len, long volume); 35 | void SDL_MixAudio_m68k_S16LSB(short* dst,short* src, long len, long volume); 36 | #endif 37 | -------------------------------------------------------------------------------- /cdrom/dummy/SDL_syscdrom.c: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #if defined(SDL_CDROM_DUMMY) || defined(SDL_CDROM_DISABLED) 25 | 26 | /* Stub functions for system-level CD-ROM audio control */ 27 | 28 | #include "SDL_cdrom.h" 29 | #include "../SDL_syscdrom.h" 30 | 31 | int SDL_SYS_CDInit(void) 32 | { 33 | return(0); 34 | } 35 | 36 | void SDL_SYS_CDQuit(void) 37 | { 38 | return; 39 | } 40 | 41 | #endif /* SDL_CDROM_DUMMY || SDL_CDROM_DISABLED */ 42 | -------------------------------------------------------------------------------- /cdrom/macos/SDL_syscdrom.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/cdrom/macos/SDL_syscdrom.c -------------------------------------------------------------------------------- /cdrom/macosx/SDLOSXCAGuard.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/cdrom/macosx/SDLOSXCAGuard.c -------------------------------------------------------------------------------- /cdrom/macosx/SDLOSXCAGuard.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/cdrom/macosx/SDLOSXCAGuard.h -------------------------------------------------------------------------------- /close_code.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | /* This file reverses the effects of begin_code.h and should be included 24 | after you finish any function and structure declarations in your headers 25 | */ 26 | 27 | #undef _begin_code_h 28 | 29 | /* Reset structure packing at previous byte alignment */ 30 | #if defined(_MSC_VER) || defined(__MWERKS__) || defined(__WATCOMC__) || defined(__BORLANDC__) 31 | #ifdef __BORLANDC__ 32 | #pragma nopackwarning 33 | #endif 34 | #if (defined(__MWERKS__) && defined(macintosh)) 35 | #pragma options align=reset 36 | #pragma enumsalwaysint reset 37 | #else 38 | #pragma pack(pop) 39 | #endif 40 | #endif /* Compiler needs structure packing set */ 41 | 42 | -------------------------------------------------------------------------------- /docs/html/guidecredits.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/docs/html/guidecredits.html -------------------------------------------------------------------------------- /docs/images/rainbow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/docs/images/rainbow.gif -------------------------------------------------------------------------------- /docs/man3/SDL_ActiveEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_ActiveEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_ActiveEvent \- Application visibility event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | Uint8 gain; 10 | Uint8 state; 11 | } SDL_ActiveEvent;\fR 12 | .fi 13 | .PP 14 | .SH "STRUCTURE DATA" 15 | .TP 20 16 | \fBtype\fR 17 | \fBSDL_ACTIVEEVENT\&.\fP 18 | .TP 20 19 | \fBgain\fR 20 | 0 if the event is a loss or 1 if it is a gain\&. 21 | .TP 20 22 | \fBstate\fR 23 | \fBSDL_APPMOUSEFOCUS\fP if mouse focus was gained or lost, \fBSDL_APPINPUTFOCUS\fP if input focus was gained or lost, or \fBSDL_APPACTIVE\fP if the application was iconified (\fBgain\fR=0) or restored(\fBgain\fR=1)\&. 24 | .SH "DESCRIPTION" 25 | .PP 26 | \fBSDL_ActiveEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_ACTIVEEVENT\fP is reported\&. 27 | .PP 28 | When the mouse leaves or enters the window area a \fBSDL_APPMOUSEFOCUS\fP type activation event occurs, if the mouse entered the window then \fBgain\fR will be 1, otherwise \fBgain\fR will be 0\&. A \fBSDL_APPINPUTFOCUS\fP type activation event occurs when the application loses or gains keyboard focus\&. This usually occurs when another application is made active\&. Finally, a \fBSDL_APPACTIVE\fP type event occurs when the application is either minimised/iconified (\fBgain\fR=0) or restored\&. 29 | .PP 30 | .RS 31 | \fBNote: 32 | .PP 33 | This event does not occur when an application window is first created\&. 34 | .RE 35 | .SH "SEE ALSO" 36 | .PP 37 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_GetAppState\fP\fR 38 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 39 | -------------------------------------------------------------------------------- /docs/man3/SDL_BuildAudioCVT.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_BuildAudioCVT" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_BuildAudioCVT \- Initializes a SDL_AudioCVT structure for conversion 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_BuildAudioCVT\fP\fR(\fBSDL_AudioCVT *cvt, Uint16 src_format, Uint8 src_channels, int src_rate, Uint16 dst_format, Uint8 dst_channels, int dst_rate\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Before an \fI\fBSDL_AudioCVT\fR\fR structure can be used to convert audio data it must be initialized with source and destination information\&. 12 | .PP 13 | \fBsrc_format\fR and \fBdst_format\fR are the source and destination format of the conversion\&. (For information on audio formats see \fI\fB SDL_AudioSpec\fR\fR)\&. \fBsrc_channels\fR and \fBdst_channels\fR are the number of channels in the source and destination formats\&. Finally, \fBsrc_rate\fR and \fBdst_rate\fR are the frequency or samples-per-second of the source and destination formats\&. Once again, see \fI\fBSDL_AudioSpec\fR\fR\&. 14 | .SH "RETURN VALUES" 15 | .PP 16 | Returns \fB-1\fR if the filter could not be built or 1 if it could\&. 17 | .SH "EXAMPLES" 18 | .PP 19 | See \fI\fBSDL_ConvertAudio\fP\fR\&. 20 | .SH "SEE ALSO" 21 | .PP 22 | \fI\fBSDL_ConvertAudio\fP\fR, \fI\fBSDL_AudioCVT\fP\fR 23 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 24 | -------------------------------------------------------------------------------- /docs/man3/SDL_CD.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CD" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CD \- CDROM Drive Information 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | int id; 9 | CDstatus status; 10 | int numtracks; 11 | int cur_track; 12 | int cur_frame; 13 | SDL_CDtrack track[SDL_MAX_TRACKS+1]; 14 | } SDL_CD;\fR 15 | .fi 16 | .PP 17 | .SH "STRUCTURE DATA" 18 | .TP 20 19 | \fBid\fR 20 | Private drive identifier 21 | .TP 20 22 | \fBstatus\fR 23 | Drive \fIstatus\fR 24 | .TP 20 25 | \fBnumtracks\fR 26 | Number of tracks on the CD 27 | .TP 20 28 | \fBcur_track\fR 29 | Current track 30 | .TP 20 31 | \fBcur_frame\fR 32 | Current frame offset within the track 33 | .TP 20 34 | \fBtrack\fR[SDL_MAX_TRACKS+1] 35 | Array of track descriptions\&. (see \fI\fBSDL_CDtrack\fR\fR) 36 | .SH "DESCRIPTION" 37 | .PP 38 | An \fBSDL_CD\fR structure is returned by \fI\fBSDL_CDOpen\fP\fR\&. It represents an opened CDROM device and stores information on the layout of the tracks on the disc\&. 39 | .PP 40 | A frame is the base data unit of a CD\&. \fBCD_FPS\fP frames is equal to 1 second of music\&. SDL provides two macros for converting between time and frames: \fBFRAMES_TO_MSF(f, M,S,F)\fP and \fBMSF_TO_FRAMES\fP\&. 41 | .SH "EXAMPLES" 42 | .PP 43 | .nf 44 | \f(CWint min, sec, frame; 45 | int frame_offset; 46 | 47 | FRAMES_TO_MSF(cdrom->cur_frame, &min, &sec, &frame); 48 | printf("Current Position: %d minutes, %d seconds, %d frames 49 | ", min, sec, frame); 50 | 51 | frame_offset=MSF_TO_FRAMES(min, sec, frame);\fR 52 | .fi 53 | .PP 54 | .SH "SEE ALSO" 55 | .PP 56 | \fI\fBSDL_CDOpen\fP\fR, \fI\fBSDL_CDtrack\fR\fR 57 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 58 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDClose.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDClose" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDClose \- Closes a SDL_CD handle 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_CDClose\fP\fR(\fBSDL_CD *cdrom\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Closes the given \fBcdrom\fR handle\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_CDOpen\fP\fR, \fI\fBSDL_CD\fR\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDEject.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDEject" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDEject \- Ejects a CDROM 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_CDEject\fP\fR(\fBSDL_CD *cdrom\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Ejects the given \fBcdrom\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CD\fR\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDName.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDName" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDName \- Returns a human-readable, system-dependent identifier for the CD-ROM\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBconst char *\fBSDL_CDName\fP\fR(\fBint drive\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns a human-readable, system-dependent identifier for the CD-ROM\&. \fBdrive\fR is the index of the drive\&. Drive indices start to 0 and end at \fBSDL_CDNumDrives()\fP-1\&. 12 | .SH "EXAMPLES" 13 | .PP 14 | .IP " \(bu" 6 15 | "/dev/cdrom" 16 | .IP " \(bu" 6 17 | "E:" 18 | .IP " \(bu" 6 19 | "/dev/disk/ide/1/master" 20 | .SH "SEE ALSO" 21 | .PP 22 | \fI\fBSDL_CDNumDrives\fP\fR 23 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 24 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDNumDrives.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDNumDrives" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDNumDrives \- Returns the number of CD-ROM drives on the system\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_CDNumDrives\fP\fR(\fBvoid\fR) 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns the number of CD-ROM drives on the system\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_CDOpen\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDPause.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDPause" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDPause \- Pauses a CDROM 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_CDPause\fP\fR(\fBSDL_CD *cdrom\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Pauses play on the given \fBcdrom\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CDPlay\fP\fR, \fI\fBSDL_CDResume\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDPlay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDPlay" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDPlay \- Play a CD 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_CDPlay\fP\fR(\fBSDL_CD *cdrom, int start, int length\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Plays the given \fBcdrom\fR, starting a frame \fBstart\fR for \fBlength\fR frames\&. 12 | .SH "RETURN VALUES" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CDPlayTracks\fP\fR, \fI\fBSDL_CDStop\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDResume.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDResume" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDResume \- Resumes a CDROM 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_CDResume\fP\fR(\fBSDL_CD *cdrom\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Resumes play on the given \fBcdrom\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CDPlay\fP\fR, \fI\fBSDL_CDPause\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDStop.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDStop" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDStop \- Stops a CDROM 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_CDStop\fP\fR(\fBSDL_CD *cdrom\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Stops play on the given \fBcdrom\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CDPlay\fP\fR, 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_CDtrack.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CDtrack" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CDtrack \- CD Track Information Structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 id; 9 | Uint8 type; 10 | Uint32 length; 11 | Uint32 offset; 12 | } SDL_CDtrack;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBid\fR 18 | Track number (0-99) 19 | .TP 20 20 | \fBtype\fR 21 | \fBSDL_AUDIO_TRACK\fP or \fBSDL_DATA_TRACK\fP 22 | .TP 20 23 | \fBlength\fR 24 | Length, in frames, of this track 25 | .TP 20 26 | \fBoffset\fR 27 | Frame offset to the beginning of this track 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_CDtrack\fR stores data on each track on a CD, its fields should be pretty self explainatory\&. It is a member a the \fI\fBSDL_CD\fR\fR structure\&. 31 | .PP 32 | .RS 33 | \fBNote: 34 | .PP 35 | Frames can be converted to standard timings\&. There are \fBCD_FPS\fP frames per second, so \fBSDL_CDtrack\fR\&.\fBlength\fR/\fBCD_FPS\fP=length_in_seconds\&. 36 | .RE 37 | .SH "SEE ALSO" 38 | .PP 39 | \fI\fBSDL_CD\fR\fR 40 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 41 | -------------------------------------------------------------------------------- /docs/man3/SDL_CloseAudio.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CloseAudio" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CloseAudio \- Shuts down audio processing and closes the audio device\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_CloseAudio\fP\fR(\fBvoid\fR) 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function shuts down audio processing and closes the audio device\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_OpenAudio\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_Color.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Color" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Color \- Format independent color description 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 r; 9 | Uint8 g; 10 | Uint8 b; 11 | Uint8 unused; 12 | } SDL_Color;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBr\fR 18 | Red intensity 19 | .TP 20 20 | \fBg\fR 21 | Green intensity 22 | .TP 20 23 | \fBb\fR 24 | Blue intensity 25 | .TP 20 26 | \fBunused\fR 27 | Unused 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_Color\fR describes a color in a format independent way\&. You can convert a \fBSDL_Color\fR to a pixel value for a certain pixel format using \fI\fBSDL_MapRGB\fP\fR\&. 31 | .SH "SEE ALSO" 32 | .PP 33 | \fI\fBSDL_PixelFormat\fR\fR, \fI\fBSDL_SetColors\fP\fR, \fI\fBSDL_Palette\fP\fR 34 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 35 | -------------------------------------------------------------------------------- /docs/man3/SDL_CondBroadcast.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CondBroadcast" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CondBroadcast \- Restart all threads waiting on a condition variable 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_CondBroadcast\fP\fR(\fBSDL_cond *cond\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Restarts all threads that are waiting on the condition variable, \fBcond\fR\&. Returns \fB0\fR on success, or \fB-1\fR on an error\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CondSignal\fP\fR, \fI\fBSDL_CondWait\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_CondSignal.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CondSignal" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CondSignal \- Restart a thread wait on a condition variable 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_CondSignal\fP\fR(\fBSDL_cond *cond\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Restart one of the threads that are waiting on the condition variable, \fBcond\fR\&. Returns \fB0\fR on success of \fB-1\fR on an error\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CondWait\fP\fR, \fI\fBSDL_CondBroadcast\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_CondWait.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CondWait" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CondWait \- Wait on a condition variable 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_CondWait\fP\fR(\fBSDL_cond *cond, SDL_mutex *mut\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Wait on the condition variable \fBcond\fR and unlock the provided mutex\&. The mutex must the locked before entering this function\&. Returns \fB0\fR when it is signalled, or \fB-1\fR on an error\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CondWaitTimeout\fP\fR, \fI\fBSDL_CondSignal\fP\fR, \fI\fBSDL_mutexP\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_CondWaitTimeout.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CondWaitTimeout" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CondWaitTimeout \- Wait on a condition variable, with timeout 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_CondWaitTimeout\fP\fR(\fBSDL_cond *cond, SDL_mutex *mutex, Uint32 ms\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Wait on the condition variable \fBcond\fR for, at most, \fBms\fR milliseconds\&. \fBmut\fR is unlocked so it must be locked when the function is called\&. Returns \fBSDL_MUTEX_TIMEDOUT\fP if the condition is not signalled in the allotted time, \fB0\fR if it was signalled or \fB-1\fR on an error\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CondWait\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_ConvertSurface.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_ConvertSurface" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_ConvertSurface \- Converts a surface to the same format as another surface\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL/SDL\&.h" 7 | .sp 8 | \fBSDL_Surface *\fBSDL_ConvertSurface\fP\fR(\fBSDL_Surface *src, SDL_PixelFormat *fmt, Uint32 flags\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Creates a new surface of the specified format, and then copies and maps the given surface to it\&. If this function fails, it returns \fBNULL\fP\&. 12 | .PP 13 | The \fBflags\fR parameter is passed to \fI\fBSDL_CreateRGBSurface\fP\fR and has those semantics\&. 14 | .PP 15 | This function is used internally by \fI\fBSDL_DisplayFormat\fP\fR\&. 16 | .PP 17 | This function can only be called after SDL_Init\&. 18 | .SH "RETURN VALUE" 19 | .PP 20 | Returns either a pointer to the new surface, or \fBNULL\fP on error\&. 21 | .SH "SEE ALSO" 22 | .PP 23 | \fI\fBSDL_CreateRGBSurface\fP\fR, \fI\fBSDL_DisplayFormat\fP\fR, \fI\fBSDL_PixelFormat\fR\fR, \fI\fBSDL_Surface\fR\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_CreateCond.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CreateCond" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CreateCond \- Create a condition variable 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBSDL_cond *\fBSDL_CreateCond\fP\fR(\fBvoid\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Creates a condition variable\&. 13 | .SH "EXAMPLES" 14 | .PP 15 | .nf 16 | \f(CWSDL_cond *cond; 17 | 18 | cond=SDL_CreateCond(); 19 | \&. 20 | \&. 21 | /* Do stuff */ 22 | 23 | \&. 24 | \&. 25 | SDL_DestroyCond(cond);\fR 26 | .fi 27 | .PP 28 | .SH "SEE ALSO" 29 | .PP 30 | \fI\fBSDL_DestroyCond\fP\fR, \fI\fBSDL_CondWait\fP\fR, \fI\fBSDL_CondSignal\fP\fR 31 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 32 | -------------------------------------------------------------------------------- /docs/man3/SDL_CreateMutex.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CreateMutex" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CreateMutex \- Create a mutex 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBSDL_mutex *\fBSDL_CreateMutex\fP\fR(\fBvoid\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Create a new, unlocked mutex\&. 13 | .SH "EXAMPLES" 14 | .PP 15 | .nf 16 | \f(CWSDL_mutex *mut; 17 | 18 | mut=SDL_CreateMutex(); 19 | \&. 20 | \&. 21 | if(SDL_mutexP(mut)==-1){ 22 | fprintf(stderr, "Couldn\&'t lock mutex 23 | "); 24 | exit(-1); 25 | } 26 | \&. 27 | /* Do stuff while mutex is locked */ 28 | \&. 29 | \&. 30 | if(SDL_mutexV(mut)==-1){ 31 | fprintf(stderr, "Couldn\&'t unlock mutex 32 | "); 33 | exit(-1); 34 | } 35 | 36 | SDL_DestroyMutex(mut); 37 | \fR 38 | .fi 39 | .PP 40 | .SH "SEE ALSO" 41 | .PP 42 | \fI\fBSDL_mutexP\fP\fR, \fI\fBSDL_mutexV\fP\fR, \fI\fBSDL_DestroyMutex\fP\fR 43 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 44 | -------------------------------------------------------------------------------- /docs/man3/SDL_CreateRGBSurfaceFrom.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CreateRGBSurfaceFrom" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CreateRGBSurfaceFrom \- Create an SDL_Surface from pixel data 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Surface *\fBSDL_CreateRGBSurfaceFrom\fP\fR(\fBvoid *pixels, int width, int height, int depth, int pitch, Uint32 Rmask, Uint32 Gmask, Uint32 Bmask, Uint32 Amask\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Creates an SDL_Surface from the provided pixel data\&. 12 | .PP 13 | The data stored in \fBpixels\fR is assumed to be of the \fBdepth\fR specified in the parameter list\&. The pixel data is not copied into the \fBSDL_Surface\fR structure so it should not be freed until the surface has been freed with a called to \fISDL_FreeSurface\fR\&. \fBpitch\fR is the length of each scanline in bytes\&. 14 | .PP 15 | See \fI\fBSDL_CreateRGBSurface\fP\fR for a more detailed description of the other parameters\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | Returns the created surface, or \fBNULL\fR upon error\&. 19 | .SH "SEE ALSO" 20 | .PP 21 | \fI\fBSDL_CreateRGBSurface\fP\fR, \fI\fBSDL_FreeSurface\fP\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_CreateSemaphore.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CreateSemaphore" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CreateSemaphore \- Creates a new semaphore and assigns an initial value to it\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBSDL_sem *\fBSDL_CreateSemaphore\fP\fR(\fBUint32 initial_value\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_CreateSemaphore()\fP creates a new semaphore and initializes it with the value \fBinitial_value\fR\&. Each locking operation on the semaphore by \fISDL_SemWait\fR, \fISDL_SemTryWait\fR or \fISDL_SemWaitTimeout\fR will atomically decrement the semaphore value\&. The locking operation will be blocked if the semaphore value is not positive (greater than zero)\&. Each unlock operation by \fISDL_SemPost\fR will atomically increment the semaphore value\&. 13 | .SH "RETURN VALUE" 14 | .PP 15 | Returns a pointer to an initialized semaphore or \fBNULL\fR if there was an error\&. 16 | .SH "EXAMPLES" 17 | .PP 18 | .PP 19 | .nf 20 | \f(CWSDL_sem *my_sem; 21 | 22 | my_sem = SDL_CreateSemaphore(INITIAL_SEM_VALUE); 23 | 24 | if (my_sem == NULL) { 25 | return CREATE_SEM_FAILED; 26 | }\fR 27 | .fi 28 | .PP 29 | .SH "SEE ALSO" 30 | .PP 31 | \fI\fBSDL_DestroySemaphore\fP\fR, \fI\fBSDL_SemWait\fP\fR, \fI\fBSDL_SemTryWait\fP\fR, \fI\fBSDL_SemWaitTimeout\fP\fR, \fI\fBSDL_SemPost\fP\fR, \fI\fBSDL_SemValue\fP\fR 32 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 33 | -------------------------------------------------------------------------------- /docs/man3/SDL_CreateThread.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CreateThread" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CreateThread \- Creates a new thread of execution that shares its parent\&'s properties\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBSDL_Thread *\fBSDL_CreateThread\fP\fR(\fBint (*fn)(void *), void *data\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_CreateThread\fP creates a new thread of execution that shares all of its parent\&'s global memory, signal handlers, file descriptors, etc, and runs the function \fBfn\fR passed the void pointer \fBdata\fR The thread quits when this function returns\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_KillThread\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_CreateYUVOverlay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_CreateYUVOverlay" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_CreateYUVOverlay \- Create a YUV video overlay 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Overlay *\fBSDL_CreateYUVOverlay\fP\fR(\fBint width, int height, Uint32 format, SDL_Surface *display\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_CreateYUVOverlay\fP creates a YUV overlay of the specified \fBwidth\fR, \fBheight\fR and \fBformat\fR (see \fI\fBSDL_Overlay\fR\fR for a list of available formats), for the provided \fBdisplay\fR\&. A \fI\fBSDL_Overlay\fR\fR structure is returned\&. 12 | .PP 13 | The term \&'overlay\&' is a misnomer since, unless the overlay is created in hardware, the contents for the display surface underneath the area where the overlay is shown will be overwritten when the overlay is displayed\&. 14 | .SH "SEE ALSO" 15 | .PP 16 | \fI\fBSDL_Overlay\fR\fR, \fI\fBSDL_DisplayYUVOverlay\fP\fR, \fI\fBSDL_FreeYUVOverlay\fP\fR 17 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 18 | -------------------------------------------------------------------------------- /docs/man3/SDL_Delay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Delay" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Delay \- Wait a specified number of milliseconds before returning\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_Delay\fP\fR(\fBUint32 ms\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Wait a specified number of milliseconds before returning\&. \fBSDL_Delay\fP will wait at \fIleast\fP the specified time, but possible longer due to OS scheduling\&. 12 | .PP 13 | .RS 14 | \fBNote: 15 | .PP 16 | Count on a delay granularity of \fIat least\fP 10 ms\&. Some platforms have shorter clock ticks but this is the most common\&. 17 | .RE 18 | .SH "SEE ALSO" 19 | .PP 20 | \fI\fBSDL_AddTimer\fP\fR 21 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 22 | -------------------------------------------------------------------------------- /docs/man3/SDL_DestroyCond.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_DestroyCond" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_DestroyCond \- Destroy a condition variable 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBvoid \fBSDL_DestroyCond\fP\fR(\fBSDL_cond *cond\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Destroys a condition variable\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CreateCond\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_DestroyMutex.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_DestroyMutex" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_DestroyMutex \- Destroy a mutex 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBvoid \fBSDL_DestroyMutex\fP\fR(\fBSDL_mutex *mutex\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Destroy a previously \fIcreated\fR mutex\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CreateMutex\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_DestroySemaphore.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_DestroySemaphore" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_DestroySemaphore \- Destroys a semaphore that was created by \fISDL_CreateSemaphore\fR\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBvoid \fBSDL_DestroySemaphore\fP\fR(\fBSDL_sem *sem\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_DestroySemaphore\fP destroys the semaphore pointed to by \fBsem\fR that was created by \fI\fBSDL_CreateSemaphore\fP\fR\&. It is not safe to destroy a semaphore if there are threads currently blocked waiting on it\&. 13 | .SH "EXAMPLES" 14 | .PP 15 | .PP 16 | .nf 17 | \f(CWif (my_sem != NULL) { 18 | SDL_DestroySemaphore(my_sem); 19 | my_sem = NULL; 20 | }\fR 21 | .fi 22 | .PP 23 | .SH "SEE ALSO" 24 | .PP 25 | \fI\fBSDL_CreateSemaphore\fP\fR, \fI\fBSDL_SemWait\fP\fR, \fI\fBSDL_SemTryWait\fP\fR, \fI\fBSDL_SemWaitTimeout\fP\fR, \fI\fBSDL_SemPost\fP\fR, \fI\fBSDL_SemValue\fP\fR 26 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 27 | -------------------------------------------------------------------------------- /docs/man3/SDL_DisplayFormat.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_DisplayFormat" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_DisplayFormat \- Convert a surface to the display format 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Surface *\fBSDL_DisplayFormat\fP\fR(\fBSDL_Surface *surface\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function takes a surface and copies it to a new surface of the pixel format and colors of the video framebuffer, suitable for fast blitting onto the display surface\&. It calls \fISDL_ConvertSurface\fR 12 | .PP 13 | If you want to take advantage of hardware colorkey or alpha blit acceleration, you should set the colorkey and alpha value before calling this function\&. 14 | .PP 15 | If you want an alpha channel, see \fISDL_DisplayFormatAlpha\fR\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | If the conversion fails or runs out of memory, it returns \fBNULL\fR 19 | .SH "SEE ALSO" 20 | .PP 21 | \fI\fBSDL_ConvertSurface\fP\fR, \fI\fBSDL_DisplayFormatAlpha\fP\fR \fI\fBSDL_SetAlpha\fP\fR, \fI\fBSDL_SetColorKey\fP\fR, \fI\fBSDL_Surface\fR\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_DisplayFormatAlpha.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_DisplayFormatAlpha" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_DisplayFormatAlpha \- Convert a surface to the display format 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Surface *\fBSDL_DisplayFormatAlpha\fP\fR(\fBSDL_Surface *surface\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function takes a surface and copies it to a new surface of the pixel format and colors of the video framebuffer plus an alpha channel, suitable for fast blitting onto the display surface\&. It calls \fISDL_ConvertSurface\fR 12 | .PP 13 | If you want to take advantage of hardware colorkey or alpha blit acceleration, you should set the colorkey and alpha value before calling this function\&. 14 | .PP 15 | This function can be used to convert a colourkey to an alpha channel, if the \fBSDL_SRCCOLORKEY\fP flag is set on the surface\&. The generated surface will then be transparent (alpha=0) where the pixels match the colourkey, and opaque (alpha=255) elsewhere\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | If the conversion fails or runs out of memory, it returns \fBNULL\fR 19 | .SH "SEE ALSO" 20 | .PP 21 | \fISDL_ConvertSurface\fR, \fISDL_SetAlpha\fR, \fISDL_SetColorKey\fR, \fISDL_DisplayFormat\fR, \fISDL_Surface\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_DisplayYUVOverlay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_DisplayYUVOverlay" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_DisplayYUVOverlay \- Blit the overlay to the display 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_DisplayYUVOverlay\fP\fR(\fBSDL_Overlay *overlay, SDL_Rect *dstrect\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Blit the \fBoverlay\fR to the surface specified when it was \fIcreated\fR\&. The \fI\fBSDL_Rect\fR\fR structure, \fBdstrect\fR, specifies the position and size of the destination\&. If the \fBdstrect\fR is a larger or smaller than the overlay then the overlay will be scaled, this is optimized for 2x scaling\&. 12 | .SH "RETURN VALUES" 13 | .PP 14 | Returns 0 on success 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_Overlay\fR\fR, \fI\fBSDL_CreateYUVOverlay\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_EnableKeyRepeat.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_EnableKeyRepeat" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_EnableKeyRepeat \- Set keyboard repeat rate\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_EnableKeyRepeat\fP\fR(\fBint delay, int interval\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Enables or disables the keyboard repeat rate\&. \fBdelay\fR specifies how long the key must be pressed before it begins repeating, it then repeats at the speed specified by \fBinterval\fR\&. Both \fBdelay\fR and \fBinterval\fR are expressed in milliseconds\&. 12 | .PP 13 | Setting \fBdelay\fR to 0 disables key repeating completely\&. Good default values are \fBSDL_DEFAULT_REPEAT_DELAY\fP and \fISDL_DEFAULT_REPEAT_INTERVAL\fP\&. 14 | .SH "RETURN VALUE" 15 | .PP 16 | Returns \fB0\fR on success and \fB-1\fR on failure\&. 17 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 18 | -------------------------------------------------------------------------------- /docs/man3/SDL_EnableUNICODE.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_EnableUNICODE" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_EnableUNICODE \- Enable UNICODE translation 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_EnableUNICODE\fP\fR(\fBint enable\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Enables/Disables Unicode keyboard translation\&. 12 | .PP 13 | To obtain the character codes corresponding to received keyboard events, Unicode translation must first be turned on using this function\&. The translation incurs a slight overhead for each keyboard event and is therefore disabled by default\&. For each subsequently received key down event, the \fBunicode\fR member of the \fI\fBSDL_keysym\fR\fR structure will then contain the corresponding character code, or zero for keysyms that do not correspond to any character code\&. 14 | .PP 15 | A value of 1 for \fBenable\fR enables Unicode translation; 0 disables it, and -1 leaves it unchanged (useful for querying the current translation mode)\&. 16 | .PP 17 | Note that only key press events will be translated, not release events\&. 18 | .SH "RETURN VALUE" 19 | .PP 20 | Returns the previous translation mode (\fB0\fR or \fB1\fR)\&. 21 | .SH "SEE ALSO" 22 | .PP 23 | \fI\fBSDL_keysym\fR\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_EventState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_EventState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_EventState \- This function allows you to set the state of processing certain events\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 \fBSDL_EventState\fP\fR(\fBUint8 type, int state\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function allows you to set the state of processing certain event \fBtype\fR\&'s\&. 12 | .PP 13 | If \fBstate\fR is set to \fBSDL_IGNORE\fP, that event \fBtype\fR will be automatically dropped from the event queue and will not be filtered\&. 14 | .PP 15 | If \fBstate\fR is set to \fBSDL_ENABLE\fP, that event \fBtype\fR will be processed normally\&. 16 | .PP 17 | If \fBstate\fR is set to \fBSDL_QUERY\fP, \fBSDL_EventState\fP will return the current processing state of the specified event \fBtype\fR\&. 18 | .PP 19 | A list of event \fBtype\fR\&'s can be found in the \fI\fBSDL_Event\fR\fR section\&. 20 | .SH "SEE ALSO" 21 | .PP 22 | \fI\fBSDL_Event\fR\fR 23 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 24 | -------------------------------------------------------------------------------- /docs/man3/SDL_ExposeEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_ExposeEvent" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_ExposeEvent \- Quit requested event 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type 9 | } SDL_ExposeEvent;\fR 10 | .fi 11 | .PP 12 | .SH "STRUCTURE DATA" 13 | .TP 20 14 | \fBtype\fR 15 | \fBSDL_VIDEOEXPOSE\fP 16 | .SH "DESCRIPTION" 17 | .PP 18 | \fBSDL_ExposeEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used whan an event of type \fBSDL_VIDEOEXPOSE\fP is reported\&. 19 | .PP 20 | A VIDEOEXPOSE event is triggered when the screen has been modified outside of the application, usually by the window manager and needs to be redrawn\&. 21 | .SH "SEE ALSO" 22 | .PP 23 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_SetEventFilter\fP\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_FillRect.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_FillRect" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_FillRect \- This function performs a fast fill of the given rectangle with some color 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_FillRect\fP\fR(\fBSDL_Surface *dst, SDL_Rect *dstrect, Uint32 color\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function performs a fast fill of the given rectangle with \fBcolor\fR\&. If \fBdstrect\fR is \fBNULL\fP, the whole surface will be filled with \fBcolor\fR\&. 12 | .PP 13 | The color should be a pixel of the format used by the surface, and can be generated by the \fISDL_MapRGB\fR or \fISDL_MapRGBA\fR functions\&. If the color value contains an alpha value then the destination is simply "filled" with that alpha information, no blending takes place\&. 14 | .PP 15 | If there is a clip rectangle set on the destination (set via \fISDL_SetClipRect\fR) then this function will clip based on the intersection of the clip rectangle and the \fBdstrect\fR rectangle and the dstrect rectangle will be modified to represent the area actually filled\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | This function returns \fB0\fR on success, or \fB-1\fR on error\&. 19 | .SH "SEE ALSO" 20 | .PP 21 | \fI\fBSDL_MapRGB\fP\fR, \fI\fBSDL_MapRGBA\fP\fR, \fI\fBSDL_BlitSurface\fP\fR, \fI\fBSDL_Rect\fR\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_Flip.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Flip" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Flip \- Swaps screen buffers 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_Flip\fP\fR(\fBSDL_Surface *screen\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | On hardware that supports double-buffering, this function sets up a flip and returns\&. The hardware will wait for vertical retrace, and then swap video buffers before the next video surface blit or lock will return\&. On hardware that doesn\&'t support double-buffering, this is equivalent to calling \fISDL_UpdateRect\fR\fB(screen, 0, 0, 0, 0)\fR 12 | .PP 13 | The \fBSDL_DOUBLEBUF\fP flag must have been passed to \fISDL_SetVideoMode\fR, when setting the video mode for this function to perform hardware flipping\&. 14 | .SH "RETURN VALUE" 15 | .PP 16 | This function returns \fB0\fR if successful, or \fB-1\fR if there was an error\&. 17 | .SH "SEE ALSO" 18 | .PP 19 | \fI\fBSDL_SetVideoMode\fP\fR, \fI\fBSDL_UpdateRect\fP\fR, \fI\fBSDL_Surface\fR\fR 20 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 21 | -------------------------------------------------------------------------------- /docs/man3/SDL_FreeCursor.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_FreeCursor" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_FreeCursor \- Frees a cursor created with SDL_CreateCursor\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_FreeCursor\fP\fR(\fBSDL_Cursor *cursor\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Frees a \fBSDL_Cursor\fR that was created using \fISDL_CreateCursor\fR\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fISDL_CreateCursor\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_FreeSurface.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_FreeSurface" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_FreeSurface \- Frees (deletes) a SDL_Surface 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_FreeSurface\fP\fR(\fBSDL_Surface *surface\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Frees the resources used by a previously created \fBSDL_Surface\fR\&. If the surface was created using \fISDL_CreateRGBSurfaceFrom\fR then the pixel data is not freed\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_CreateRGBSurface\fP\fR \fI\fBSDL_CreateRGBSurfaceFrom\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_FreeWAV.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_FreeWAV" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_FreeWAV \- Frees previously opened WAV data 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_FreeWAV\fP\fR(\fBUint8 *audio_buf\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | After a WAVE file has been opened with \fI\fBSDL_LoadWAV\fP\fR its data can eventually be freed with \fBSDL_FreeWAV\fP\&. \fBaudio_buf\fR is a pointer to the buffer created by \fBSDL_LoadWAV\fP\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_LoadWAV\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_FreeYUVOverlay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_FreeYUVOverlay" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_FreeYUVOverlay \- Free a YUV video overlay 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_FreeYUVOverlay\fP\fR(\fBSDL_Overlay *overlay\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Frees and \fI\fBoverlay\fR\fR created by \fI\fBSDL_CreateYUVOverlay\fP\fR\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_Overlay\fR\fR, \fI\fBSDL_DisplayYUVOverlay\fP\fR, \fI\fBSDL_FreeYUVOverlay\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GL_GetAttribute.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GL_GetAttribute" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GL_GetAttribute \- Get the value of a special SDL/OpenGL attribute 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_GL_GetAttribute\fP\fR(\fBSDLGLattr attr, int *value\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Places the value of the SDL/OpenGL \fIattribute\fR \fBattr\fR into \fBvalue\fR\&. This is useful after a call to \fI\fBSDL_SetVideoMode\fP\fR to check whether your attributes have been \fIset\fR as you expected\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_GL_SetAttribute\fP\fR, \fIGL Attributes\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_GL_GetProcAddress.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GL_GetProcAddress" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GL_GetProcAddress \- Get the address of a GL function 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid *\fBSDL_GL_GetProcAddress\fP\fR(\fBconst char* proc\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns the address of the GL function \fBproc\fR, or \fBNULL\fR if the function is not found\&. If the GL library is loaded at runtime, with \fI\fBSDL_GL_LoadLibrary\fP\fR, then \fIall\fP GL functions must be retrieved this way\&. Usually this is used to retrieve function pointers to OpenGL extensions\&. 12 | .SH "EXAMPLE" 13 | .PP 14 | .nf 15 | \f(CWtypedef void (*GL_ActiveTextureARB_Func)(unsigned int); 16 | GL_ActiveTextureARB_Func glActiveTextureARB_ptr = 0; 17 | int has_multitexture=1; 18 | \&. 19 | \&. 20 | \&. 21 | /* Get function pointer */ 22 | glActiveTextureARB_ptr=(GL_ActiveTextureARB_Func) SDL_GL_GetProcAddress("glActiveTextureARB"); 23 | 24 | /* Check for a valid function ptr */ 25 | if(!glActiveTextureARB_ptr){ 26 | fprintf(stderr, "Multitexture Extensions not present\&. 27 | "); 28 | has_multitexture=0; 29 | } 30 | \&. 31 | \&. 32 | \&. 33 | \&. 34 | if(has_multitexture){ 35 | glActiveTextureARB_ptr(GL_TEXTURE0_ARB); 36 | \&. 37 | \&. 38 | } 39 | else{ 40 | \&. 41 | \&. 42 | }\fR 43 | .fi 44 | .PP 45 | .SH "SEE ALSO" 46 | .PP 47 | \fI\fBSDL_GL_LoadLibrary\fP\fR 48 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 49 | -------------------------------------------------------------------------------- /docs/man3/SDL_GL_LoadLibrary.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GL_LoadLibrary" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GL_LoadLibrary \- Specify an OpenGL library 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_GL_LoadLibrary\fP\fR(\fBconst char *path\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | If you wish, you may load the OpenGL library at runtime, this must be done before \fI\fBSDL_SetVideoMode\fP\fR is called\&. The \fBpath\fR of the GL library is passed to \fBSDL_GL_LoadLibrary\fP and it returns \fB0\fR on success, or \fB-1\fR on an error\&. You must then use \fI\fBSDL_GL_GetProcAddress\fP\fR to retrieve function pointers to GL functions\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_GL_GetProcAddress\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GL_SetAttribute.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GL_SetAttribute" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GL_SetAttribute \- Set a special SDL/OpenGL attribute 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_GL_SetAttribute\fP\fR(\fBSDL_GLattr attr, int value\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the OpenGL \fIattribute\fR \fBattr\fR to \fBvalue\fR\&. The attributes you set don\&'t take effect until after a call to \fI\fBSDL_SetVideoMode\fP\fR\&. You should use \fI\fBSDL_GL_GetAttribute\fP\fR to check the values after a \fBSDL_SetVideoMode\fP call\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on error\&. 15 | .SH "EXAMPLE" 16 | .PP 17 | .nf 18 | \f(CWSDL_GL_SetAttribute( SDL_GL_RED_SIZE, 5 ); 19 | SDL_GL_SetAttribute( SDL_GL_GREEN_SIZE, 5 ); 20 | SDL_GL_SetAttribute( SDL_GL_BLUE_SIZE, 5 ); 21 | SDL_GL_SetAttribute( SDL_GL_DEPTH_SIZE, 16 ); 22 | SDL_GL_SetAttribute( SDL_GL_DOUBLEBUFFER, 1 ); 23 | if ( (screen=SDL_SetVideoMode( 640, 480, 16, SDL_OPENGL )) == NULL ) { 24 | fprintf(stderr, "Couldn\&'t set GL mode: %s 25 | ", SDL_GetError()); 26 | SDL_Quit(); 27 | return; 28 | }\fR 29 | .fi 30 | .PP 31 | .PP 32 | .RS 33 | \fBNote: 34 | .PP 35 | The \fBSDL_DOUBLEBUF\fP flag is not required to enable double buffering when setting an OpenGL video mode\&. Double buffering is enabled or disabled using the SDL_GL_DOUBLEBUFFER attribute\&. 36 | .RE 37 | .SH "SEE ALSO" 38 | .PP 39 | \fI\fBSDL_GL_GetAttribute\fP\fR, \fIGL Attributes\fR 40 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 41 | -------------------------------------------------------------------------------- /docs/man3/SDL_GL_SwapBuffers.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GL_SwapBuffers" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GL_SwapBuffers \- Swap OpenGL framebuffers/Update Display 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_GL_SwapBuffers\fP\fR(\fBvoid \fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Swap the OpenGL buffers, if double-buffering is supported\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_SetVideoMode\fP\fR, \fI\fBSDL_GL_SetAttribute\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GLattr.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GLattr" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GLattr \- SDL GL Attributes 4 | .SH "ATTRIBUTES" 5 | .TP 20 6 | \fBSDL_GL_RED_SIZE\fP 7 | Size of the framebuffer red component, in bits 8 | .TP 20 9 | \fBSDL_GL_GREEN_SIZE\fP 10 | Size of the framebuffer green component, in bits 11 | .TP 20 12 | \fBSDL_GL_BLUE_SIZE\fP 13 | Size of the framebuffer blue component, in bits 14 | .TP 20 15 | \fBSDL_GL_ALPHA_SIZE\fP 16 | Size of the framebuffer alpha component, in bits 17 | .TP 20 18 | \fBSDL_GL_DOUBLEBUFFER\fP 19 | 0 or 1, enable or disable double buffering 20 | .TP 20 21 | \fBSDL_GL_BUFFER_SIZE\fP 22 | Size of the framebuffer, in bits 23 | .TP 20 24 | \fBSDL_GL_DEPTH_SIZE\fP 25 | Size of the depth buffer, in bits 26 | .TP 20 27 | \fBSDL_GL_STENCIL_SIZE\fP 28 | Size of the stencil buffer, in bits 29 | .TP 20 30 | \fBSDL_GL_ACCUM_RED_SIZE\fP 31 | Size of the accumulation buffer red component, in bits 32 | .TP 20 33 | \fBSDL_GL_ACCUM_GREEN_SIZE\fP 34 | Size of the accumulation buffer green component, in bits 35 | .TP 20 36 | \fBSDL_GL_ACCUM_BLUE_SIZE\fP 37 | Size of the accumulation buffer blue component, in bits 38 | .TP 20 39 | \fBSDL_GL_ACCUM_ALPHA_SIZE\fP 40 | Size of the accumulation buffer alpha component, in bits 41 | .SH "DESCRIPTION" 42 | .PP 43 | While you can set most OpenGL attributes normally, the attributes list above must be known \fIbefore\fP SDL sets the video mode\&. These attributes a set and read with \fI\fBSDL_GL_SetAttribute\fP\fR and \fI\fBSDL_GL_GetAttribute\fP\fR\&. 44 | .SH "SEE ALSO" 45 | .PP 46 | \fI\fBSDL_GL_SetAttribute\fP\fR, \fI\fBSDL_GL_GetAttribute\fP\fR 47 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 48 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetAppState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetAppState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | \fBSDL_GetAppState\fP \- Get the state of the application 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 \fBSDL_GetAppState\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function returns the current state of the application\&. The value returned is a bitwise combination of: 12 | .TP 20 13 | \fBSDL_APPMOUSEFOCUS\fP 14 | The application has mouse focus\&. 15 | .TP 20 16 | \fBSDL_APPINPUTFOCUS\fP 17 | The application has keyboard focus 18 | .TP 20 19 | \fBSDL_APPACTIVE\fP 20 | The application is visible 21 | .SH "SEE ALSO" 22 | .PP 23 | \fI\fBSDL_ActiveEvent\fR\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetAudioStatus.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetAudioStatus" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetAudioStatus \- Get the current audio state 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_audiostatus\fBSDL_GetAudioStatus\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | .nf 12 | \f(CWtypedef enum{ 13 | SDL_AUDIO_STOPPED, 14 | SDL_AUDIO_PAUSED, 15 | SDL_AUDIO_PLAYING 16 | } SDL_audiostatus;\fR 17 | .fi 18 | .PP 19 | .PP 20 | Returns either \fBSDL_AUDIO_STOPPED\fP, \fBSDL_AUDIO_PAUSED\fP or \fBSDL_AUDIO_PLAYING\fP depending on the current audio state\&. 21 | .SH "SEE ALSO" 22 | .PP 23 | \fI\fBSDL_PauseAudio\fP\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetClipRect.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetClipRect" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetClipRect \- Gets the clipping rectangle for a surface\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_GetClipRect\fP\fR(\fBSDL_Surface *surface, SDL_Rect *rect\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Gets the clipping rectangle for a surface\&. When this surface is the destination of a blit, only the area within the clip rectangle is drawn into\&. 12 | .PP 13 | The rectangle pointed to by \fBrect\fR will be filled with the clipping rectangle of the surface\&. 14 | .SH "SEE ALSO" 15 | .PP 16 | \fI\fBSDL_SetClipRect\fP\fR, \fI\fBSDL_BlitSurface\fP\fR, \fI\fBSDL_Surface\fR\fR 17 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 18 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetCursor.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetCursor" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetCursor \- Get the currently active mouse cursor\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Cursor *\fBSDL_GetCursor\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns the currently active mouse cursor\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_SetCursor\fP\fR, \fI\fBSDL_CreateCursor\fP\fR, \fI\fBSDL_ShowCursor\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetError.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetError" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetError \- Get SDL error string 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL/SDL\&.h" 7 | .sp 8 | \fBchar *\fBSDL_GetError\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_GetError\fP returns a NULL terminated string containing information about the last internal SDL error\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | \fBSDL_GetError\fP returns a string containing the last error\&. 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetEventFilter.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetEventFilter" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetEventFilter \- Retrieves a pointer to he event filter 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_EventFilter \fBSDL_GetEventFilter\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function retrieces a pointer to the event filter that was previously set using \fI\fBSDL_SetEventFilter\fP\fR\&. An SDL_EventFilter function is defined as: 12 | .PP 13 | .nf 14 | \f(CWtypedef int (*SDL_EventFilter)(const SDL_Event *event);\fR 15 | .fi 16 | .PP 17 | .SH "RETURN VALUE" 18 | .PP 19 | Returns a pointer to the event filter or \fBNULL\fP if no filter has been set\&. 20 | .SH "SEE ALSO" 21 | .PP 22 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_SetEventFilter\fP\fR 23 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 24 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetGamma.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetGamma" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetGamma \- Gets the gamma of the display 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_GetGamma\fP\fR(\fBfloat *red, float *green, float *blue\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Gets the color gamma of the display\&. The gamma value for each color component will be place in the parameters \fBred\fR, \fBgreen\fR and \fBblue\fR\&. The values can range from 0\&.1 to 10\&. 12 | .PP 13 | .RS 14 | \fBNote: 15 | .PP 16 | This function currently only works on XFreee 4\&.0 and up\&. 17 | .RE 18 | .SH "SEE ALSO" 19 | .PP 20 | \fI\fBSDL_SetGamma\fP\fR, \fI\fBSDL_SetVideoMode\fP\fR 21 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 22 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetGammaRamp.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetGammaRamp" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetGammaRamp \- Gets the color gamma lookup tables for the display 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_GetGammaRamp\fP\fR(\fBUint16 *redtable, Uint16 *greentable, Uint16 *bluetable\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Gets the gamma translation lookup tables currently used by the display\&. Each table is an array of 256 Uint16 values\&. 12 | .PP 13 | Not all display hardware is able to change gamma\&. 14 | .SH "RETURN VALUE" 15 | .PP 16 | Returns -1 on error\&. 17 | .SH "SEE ALSO" 18 | .PP 19 | \fISDL_SetGamma\fR \fISDL_SetGammaRamp\fR 20 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 21 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetKeyName.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetKeyName" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetKeyName \- Get the name of an SDL virtual keysym 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBchar *\fBSDL_GetKeyName\fP\fR(\fBSDLKey key\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns the SDL-defined name of the \fI\fBSDLKey\fR\fR \fBkey\fR\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDLKey\fR\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetKeyState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetKeyState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetKeyState \- Get a snapshot of the current keyboard state 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 *\fBSDL_GetKeyState\fP\fR(\fBint *numkeys\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Gets a snapshot of the current keyboard state\&. The current state is return as a pointer to an array, the size of this array is stored in \fBnumkeys\fR\&. The array is indexed by the \fI\fBSDLK_*\fP\fR symbols\&. A value of 1 means the key is pressed and a value of 0 means its not\&. The pointer returned is a pointer to an internal SDL array and should not be freed by the caller\&. 12 | .PP 13 | .RS 14 | \fBNote: 15 | .PP 16 | Use \fI\fBSDL_PumpEvents\fP\fR to update the state array\&. 17 | .RE 18 | .SH "EXAMPLE" 19 | .PP 20 | .PP 21 | .nf 22 | \f(CWUint8 *keystate = SDL_GetKeyState(NULL); 23 | if ( keystate[SDLK_RETURN] ) printf("Return Key Pressed\&. 24 | ");\fR 25 | .fi 26 | .PP 27 | .SH "SEE ALSO" 28 | .PP 29 | \fI\fBSDL Key Symbols\fP\fR, \fI\fBSDL_PumpEvents\fP\fR 30 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 31 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetModState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetModState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetModState \- Get the state of modifier keys\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDLMod \fBSDL_GetModState\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns the current state of the modifier keys (CTRL, ALT, etc\&.)\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | The return value can be an OR\&'d combination of the SDLMod enum\&. 15 | .PP 16 | .PP 17 | .RS 18 | \fBSDLMod\fR 19 | .PP 20 | .PP 21 | .nf 22 | \f(CWtypedef enum { 23 | KMOD_NONE = 0x0000, 24 | KMOD_LSHIFT= 0x0001, 25 | KMOD_RSHIFT= 0x0002, 26 | KMOD_LCTRL = 0x0040, 27 | KMOD_RCTRL = 0x0080, 28 | KMOD_LALT = 0x0100, 29 | KMOD_RALT = 0x0200, 30 | KMOD_LMETA = 0x0400, 31 | KMOD_RMETA = 0x0800, 32 | KMOD_NUM = 0x1000, 33 | KMOD_CAPS = 0x2000, 34 | KMOD_MODE = 0x4000, 35 | } SDLMod;\fR 36 | .fi 37 | .PP 38 | .RE 39 | SDL also defines the following symbols for convenience: 40 | .PP 41 | .RS 42 | .PP 43 | .nf 44 | \f(CW#define KMOD_CTRL (KMOD_LCTRL|KMOD_RCTRL) 45 | #define KMOD_SHIFT (KMOD_LSHIFT|KMOD_RSHIFT) 46 | #define KMOD_ALT (KMOD_LALT|KMOD_RALT) 47 | #define KMOD_META (KMOD_LMETA|KMOD_RMETA)\fR 48 | .fi 49 | .PP 50 | .RE 51 | .SH "SEE ALSO" 52 | .PP 53 | \fI\fBSDL_GetKeyState\fP\fR 54 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 55 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetMouseState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetMouseState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetMouseState \- Retrieve the current state of the mouse 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 \fBSDL_GetMouseState\fP\fR(\fBint *x, int *y\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | The current button state is returned as a button bitmask, which can be tested using the \fBSDL_BUTTON(X)\fP macros, and \fBx\fR and \fBy\fR are set to the current mouse cursor position\&. You can pass \fBNULL\fP for either \fBx\fR or \fBy\fR\&. 12 | .SH "EXAMPLE" 13 | .PP 14 | .nf 15 | \f(CWSDL_PumpEvents(); 16 | if(SDL_GetMouseState(NULL, NULL)&SDL_BUTTON(1)) 17 | printf("Mouse Button 1(left) is pressed\&. 18 | ");\fR 19 | .fi 20 | .PP 21 | .SH "SEE ALSO" 22 | .PP 23 | \fI\fBSDL_GetRelativeMouseState\fP\fR, \fI\fBSDL_PumpEvents\fP\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetRGB.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetRGB" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetRGB \- Get RGB values from a pixel in the specified pixel format\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_GetRGB\fP\fR(\fBUint32 pixel, SDL_PixelFormat *fmt, Uint8 *r, Uint8 *g, Uint8 *b\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Get RGB component values from a pixel stored in the specified pixel format\&. 12 | .PP 13 | This function uses the entire 8-bit [0\&.\&.255] range when converting color components from pixel formats with less than 8-bits per RGB component (e\&.g\&., a completely white pixel in 16-bit RGB565 format would return [0xff, 0xff, 0xff] not [0xf8, 0xfc, 0xf8])\&. 14 | .SH "SEE ALSO" 15 | .PP 16 | \fI\fBSDL_GetRGBA\fP\fR, \fI\fBSDL_MapRGB\fP\fR, \fI\fBSDL_MapRGBA\fP\fR, \fI\fBSDL_PixelFormat\fR\fR 17 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 18 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetRGBA.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetRGBA" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetRGBA \- Get RGBA values from a pixel in the specified pixel format\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_GetRGBA\fP\fR(\fBUint32 pixel, SDL_PixelFormat *fmt, Uint8 *r, Uint8 *g, Uint8 *b, Uint8 *a\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Get RGBA component values from a pixel stored in the specified pixel format\&. 12 | .PP 13 | This function uses the entire 8-bit [0\&.\&.255] range when converting color components from pixel formats with less than 8-bits per RGB component (e\&.g\&., a completely white pixel in 16-bit RGB565 format would return [0xff, 0xff, 0xff] not [0xf8, 0xfc, 0xf8])\&. 14 | .PP 15 | If the surface has no alpha component, the alpha will be returned as 0xff (100% opaque)\&. 16 | .SH "SEE ALSO" 17 | .PP 18 | \fISDL_GetRGB\fR, \fISDL_MapRGB\fR, \fISDL_MapRGBA\fR, \fISDL_PixelFormat\fR 19 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 20 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetRelativeMouseState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetRelativeMouseState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetRelativeMouseState \- Retrieve the current state of the mouse 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 \fBSDL_GetRelativeMouseState\fP\fR(\fBint *x, int *y\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | The current button state is returned as a button bitmask, which can be tested using the \fBSDL_BUTTON(X)\fP macros, and \fBx\fR and \fBy\fR are set to the change in the mouse position since the last call to \fBSDL_GetRelativeMouseState\fP or since event initialization\&. You can pass \fBNULL\fP for either \fBx\fR or \fBy\fR\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_GetMouseState\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetThreadID.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetThreadID" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetThreadID \- Get the SDL thread ID of a SDL_Thread 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBUint32 \fBSDL_GetThreadID\fP\fR(\fBSDL_Thread *thread\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Returns the ID of a \fBSDL_Thread\fR created by \fISDL_CreateThread\fR\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fISDL_CreateThread\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetTicks.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetTicks" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetTicks \- Get the number of milliseconds since the SDL library initialization\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint32 \fBSDL_GetTicks\fP\fR(\fBvoid\fR) 9 | .SH "DESCRIPTION" 10 | .PP 11 | Get the number of milliseconds since the SDL library initialization\&. Note that this value wraps if the program runs for more than ~49 days\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_Delay\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetVideoInfo.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetVideoInfo" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetVideoInfo \- returns a pointer to information about the video hardware 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_VideoInfo *\fBSDL_GetVideoInfo\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function returns a read-only pointer to \fIinformation\fR about the video hardware\&. If this is called before \fISDL_SetVideoMode\fR, the \fBvfmt\fR member of the returned structure will contain the pixel format of the "best" video mode\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_SetVideoMode\fP\fR, \fI\fBSDL_VideoInfo\fR\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_GetVideoSurface.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_GetVideoSurface" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_GetVideoSurface \- returns a pointer to the current display surface 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Surface *\fBSDL_GetVideoSurface\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function returns a pointer to the current display surface\&. If SDL is doing format conversion on the display surface, this function returns the publicly visible surface, not the real video surface\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_Surface\fR\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_Init.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Init" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Init \- Initializes SDL 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_Init\fP\fR(\fBUint32 flags\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Initializes SDL\&. This should be called before all other SDL functions\&. The \fBflags\fR parameter specifies what part(s) of SDL to initialize\&. 12 | .TP 20 13 | \fBSDL_INIT_TIMER\fP 14 | Initializes the \fItimer\fR subsystem\&. 15 | .TP 20 16 | \fBSDL_INIT_AUDIO\fP 17 | Initializes the \fIaudio\fR subsystem\&. 18 | .TP 20 19 | \fBSDL_INIT_VIDEO\fP 20 | Initializes the \fIvideo\fR subsystem\&. 21 | .TP 20 22 | \fBSDL_INIT_CDROM\fP 23 | Initializes the \fIcdrom\fR subsystem\&. 24 | .TP 20 25 | \fBSDL_INIT_JOYSTICK\fP 26 | Initializes the \fIjoystick\fR subsystem\&. 27 | .TP 20 28 | \fBSDL_INIT_EVERYTHING\fP 29 | Initialize all of the above\&. 30 | .TP 20 31 | \fBSDL_INIT_NOPARACHUTE\fP 32 | Prevents SDL from catching fatal signals\&. 33 | .TP 20 34 | \fBSDL_INIT_EVENTTHREAD\fP 35 | .SH "RETURN VALUE" 36 | .PP 37 | Returns \fB-1\fR on an error or \fB0\fR on success\&. 38 | .SH "SEE ALSO" 39 | .PP 40 | \fI\fBSDL_Quit\fP\fR, \fI\fBSDL_InitSubSystem\fP\fR 41 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 42 | -------------------------------------------------------------------------------- /docs/man3/SDL_InitSubSystem.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_InitSubSystem" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_InitSubSystem \- Initialize subsystems 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_InitSubSystem\fP\fR(\fBUint32 flags\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | After SDL has been initialized with \fI\fBSDL_Init\fP\fR you may initialize uninitialized subsystems with \fBSDL_InitSubSystem\fP\&. The \fBflags\fR parameter is the same as that used in \fI\fBSDL_Init\fP\fR\&. 12 | .SH "EXAMPLES" 13 | .PP 14 | .nf 15 | \f(CW/* Seperating Joystick and Video initialization\&. */ 16 | SDL_Init(SDL_INIT_VIDEO); 17 | \&. 18 | \&. 19 | SDL_SetVideoMode(640, 480, 16, SDL_DOUBLEBUF|SDL_FULLSCREEN); 20 | \&. 21 | /* Do Some Video stuff */ 22 | \&. 23 | \&. 24 | /* Initialize the joystick subsystem */ 25 | SDL_InitSubSystem(SDL_INIT_JOYSTICK); 26 | 27 | /* Do some stuff with video and joystick */ 28 | \&. 29 | \&. 30 | \&. 31 | /* Shut them both down */ 32 | SDL_Quit();\fR 33 | .fi 34 | .PP 35 | .SH "RETURN VALUE" 36 | .PP 37 | Returns \fB-1\fR on an error or \fB0\fR on success\&. 38 | .SH "SEE ALSO" 39 | .PP 40 | \fI\fBSDL_Init\fP\fR, \fI\fBSDL_Quit\fP\fR, \fI\fBSDL_QuitSubSystem\fP\fR 41 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 42 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoyAxisEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoyAxisEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoyAxisEvent \- Joystick axis motion event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | Uint8 which; 10 | Uint8 axis; 11 | Sint16 value; 12 | } SDL_JoyAxisEvent;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBtype\fR 18 | \fBSDL_JOYAXISMOTION\fP 19 | .TP 20 20 | \fBwhich\fR 21 | Joystick device index 22 | .TP 20 23 | \fBaxis\fR 24 | Joystick axis index 25 | .TP 20 26 | \fBvalue\fR 27 | Axis value (range: -32768 to 32767) 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_JoyAxisEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_JOYAXISMOTION\fP is reported\&. 31 | .PP 32 | A \fBSDL_JOYAXISMOTION\fP event occurs when ever a user moves an axis on the joystick\&. The field \fBwhich\fR is the index of the joystick that reported the event and \fBaxis\fR is the index of the axis (for a more detailed explaination see the \fIJoystick section\fR)\&. \fBvalue\fR is the current position of the axis\&. 33 | .SH "SEE ALSO" 34 | .PP 35 | \fI\fBSDL_Event\fR\fR, \fIJoystick Functions\fR, \fI\fBSDL_JoystickEventState\fP\fR, \fI\fBSDL_JoystickGetAxis\fP\fR 36 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 37 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoyBallEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoyBallEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoyBallEvent \- Joystick trackball motion event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | Uint8 which; 10 | Uint8 ball; 11 | Sint16 xrel, yrel; 12 | } SDL_JoyBallEvent;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBtype\fR 18 | \fBSDL_JOYBALLMOTION\fP 19 | .TP 20 20 | \fBwhich\fR 21 | Joystick device index 22 | .TP 20 23 | \fBball\fR 24 | Joystick trackball index 25 | .TP 20 26 | \fBxrel\fR, \fByrel\fR 27 | The relative motion in the X/Y direction 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_JoyBallEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_JOYBALLMOTION\fP is reported\&. 31 | .PP 32 | A \fBSDL_JOYBALLMOTION\fP event occurs when a user moves a trackball on the joystick\&. The field \fBwhich\fR is the index of the joystick that reported the event and \fBball\fR is the index of the trackball (for a more detailed explaination see the \fIJoystick section\fR)\&. Trackballs only return relative motion, this is the change in position on the ball since it was last polled (last cycle of the event loop) and it is stored in \fBxrel\fR and \fByrel\fR\&. 33 | .SH "SEE ALSO" 34 | .PP 35 | \fI\fBSDL_Event\fR\fR, \fIJoystick Functions\fR, \fI\fBSDL_JoystickEventState\fP\fR, \fI\fBSDL_JoystickGetBall\fP\fR 36 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 37 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoyButtonEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoyButtonEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoyButtonEvent \- Joystick button event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | Uint8 which; 10 | Uint8 button; 11 | Uint8 state; 12 | } SDL_JoyButtonEvent;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBtype\fR 18 | \fBSDL_JOYBUTTONDOWN\fP or \fBSDL_JOYBUTTONUP\fP 19 | .TP 20 20 | \fBwhich\fR 21 | Joystick device index 22 | .TP 20 23 | \fBbutton\fR 24 | Joystick button index 25 | .TP 20 26 | \fBstate\fR 27 | \fBSDL_PRESSED\fP or \fBSDL_RELEASED\fP 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_JoyButtonEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_JOYBUTTONDOWN\fP or \fBSDL_JOYBUTTONUP\fP is reported\&. 31 | .PP 32 | A \fBSDL_JOYBUTTONDOWN\fP or \fBSDL_JOYBUTTONUP\fP event occurs when ever a user presses or releases a button on a joystick\&. The field \fBwhich\fR is the index of the joystick that reported the event and \fBbutton\fR is the index of the button (for a more detailed explaination see the \fIJoystick section\fR)\&. \fBstate\fR is the current state or the button which is either \fBSDL_PRESSED\fP or \fBSDL_RELEASED\fP\&. 33 | .SH "SEE ALSO" 34 | .PP 35 | \fI\fBSDL_Event\fR\fR, \fIJoystick Functions\fR, \fI\fBSDL_JoystickEventState\fP\fR, \fI\fBSDL_JoystickGetButton\fP\fR 36 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 37 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickClose.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickClose" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickClose \- Closes a previously opened joystick 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_JoystickClose\fP\fR(\fBSDL_Joystick *joystick\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Close a \fBjoystick\fR that was previously opened with \fI\fBSDL_JoystickOpen\fP\fR\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_JoystickOpen\fP\fR, \fI\fBSDL_JoystickOpened\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickEventState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickEventState" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickEventState \- Enable/disable joystick event polling 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_JoystickEventState\fP\fR(\fBint state\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function is used to enable or disable joystick event processing\&. With joystick event processing disabled you will have to update joystick states with \fI\fBSDL_JoystickUpdate\fP\fR and read the joystick information manually\&. \fBstate\fR is either \fBSDL_QUERY\fP, \fBSDL_ENABLE\fP or \fBSDL_IGNORE\fP\&. 12 | .PP 13 | .RS 14 | \fBNote: 15 | .PP 16 | Joystick event handling is prefered 17 | .RE 18 | .SH "RETURN VALUE" 19 | .PP 20 | If \fBstate\fR is \fBSDL_QUERY\fP then the current state is returned, otherwise the new processing \fBstate\fR is returned\&. 21 | .SH "SEE ALSO" 22 | .PP 23 | \fISDL Joystick Functions\fR, \fI\fBSDL_JoystickUpdate\fP\fR, \fI\fBSDL_JoyAxisEvent\fR\fR, \fI\fBSDL_JoyBallEvent\fR\fR, \fI\fBSDL_JoyButtonEvent\fR\fR, \fI\fBSDL_JoyHatEvent\fR\fR 24 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 25 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickGetAxis.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickGetAxis" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickGetAxis \- Get the current state of an axis 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSint16 \fBSDL_JoystickGetAxis\fP\fR(\fBSDL_Joystick *joystick, int axis\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_JoystickGetAxis\fP returns the current state of the given \fBaxis\fR on the given \fBjoystick\fR\&. 12 | .PP 13 | On most modern joysticks the X axis is usually represented by \fBaxis\fR 0 and the Y axis by \fBaxis\fR 1\&. The value returned by \fBSDL_JoystickGetAxis\fP is a signed integer (-32768 to 32768) representing the current position of the \fBaxis\fR, it maybe necessary to impose certain tolerances on these values to account for jitter\&. It is worth noting that some joysticks use axes 2 and 3 for extra buttons\&. 14 | .SH "RETURN VALUE" 15 | .PP 16 | Returns a 16-bit signed integer representing the current position of the \fBaxis\fR\&. 17 | .SH "EXAMPLES" 18 | .PP 19 | .PP 20 | .nf 21 | \f(CWSint16 x_move, y_move; 22 | SDL_Joystick *joy1; 23 | \&. 24 | \&. 25 | x_move=SDL_JoystickGetAxis(joy1, 0); 26 | y_move=SDL_JoystickGetAxis(joy1, 1);\fR 27 | .fi 28 | .PP 29 | .SH "SEE ALSO" 30 | .PP 31 | \fI\fBSDL_JoystickNumAxes\fP\fR 32 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 33 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickGetBall.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickGetBall" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickGetBall \- Get relative trackball motion 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_JoystickGetBall\fP\fR(\fBSDL_Joystick *joystick, int ball, int *dx, int *dy\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Get the \fBball\fR axis change\&. 12 | .PP 13 | Trackballs can only return relative motion since the last call to \fBSDL_JoystickGetBall\fP, these motion deltas a placed into \fBdx\fR and \fBdy\fR\&. 14 | .SH "RETURN VALUE" 15 | .PP 16 | Returns \fB0\fR on success or \fB-1\fR on failure 17 | .SH "EXAMPLES" 18 | .PP 19 | .PP 20 | .nf 21 | \f(CWint delta_x, delta_y; 22 | SDL_Joystick *joy; 23 | \&. 24 | \&. 25 | \&. 26 | SDL_JoystickUpdate(); 27 | if(SDL_JoystickGetBall(joy, 0, &delta_x, &delta_y)==-1) 28 | printf("TrackBall Read Error! 29 | "); 30 | printf("Trackball Delta- X:%d, Y:%d 31 | ", delta_x, delta_y);\fR 32 | .fi 33 | .PP 34 | .SH "SEE ALSO" 35 | .PP 36 | \fI\fBSDL_JoystickNumBalls\fP\fR 37 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 38 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickGetButton.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickGetButton" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickGetButton \- Get the current state of a given button on a given joystick 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 \fBSDL_JoystickGetButton\fP\fR(\fBSDL_Joystick *joystick, int button\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | SDL_JoystickGetButton returns the current state of the given \fBbutton\fR on the given \fBjoystick\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | \fB1\fR if the button is pressed\&. Otherwise, \fB0\fR\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_JoystickNumButtons\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickGetHat.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickGetHat" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickGetHat \- Get the current state of a joystick hat 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint8 \fBSDL_JoystickGetHat\fP\fR(\fBSDL_Joystick *joystick, int hat\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | SDL_JoystickGetHat returns the current state of the given \fBhat\fR on the given \fBjoystick\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | The current state is returned as a Uint8 which is defined as an OR\&'d combination of one or more of the following 15 | .IP "" 10 16 | \fBSDL_HAT_CENTERED\fP 17 | .IP "" 10 18 | \fBSDL_HAT_UP\fP 19 | .IP "" 10 20 | \fBSDL_HAT_RIGHT\fP 21 | .IP "" 10 22 | \fBSDL_HAT_DOWN\fP 23 | .IP "" 10 24 | \fBSDL_HAT_LEFT\fP 25 | .IP "" 10 26 | \fBSDL_HAT_RIGHTUP\fP 27 | .IP "" 10 28 | \fBSDL_HAT_RIGHTDOWN\fP 29 | .IP "" 10 30 | \fBSDL_HAT_LEFTUP\fP 31 | .IP "" 10 32 | \fBSDL_HAT_LEFTDOWN\fP 33 | .SH "SEE ALSO" 34 | .PP 35 | \fI\fBSDL_JoystickNumHats\fP\fR 36 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 37 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickIndex.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickIndex" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickIndex \- Get the index of an SDL_Joystick\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_JoystickIndex\fP\fR(\fBSDL_Joystick *joystick\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Returns the index of a given \fBSDL_Joystick\fR structure\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Index number of the joystick\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_JoystickOpen\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickName.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickName" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickName \- Get joystick name\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBconst char *\fBSDL_JoystickName\fP\fR(\fBint index\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Get the implementation dependent name of joystick\&. The \fBindex\fR parameter refers to the N\&'th joystick on the system\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns a char pointer to the joystick name\&. 15 | .SH "EXAMPLES" 16 | .PP 17 | .PP 18 | .nf 19 | \f(CW/* Print the names of all attached joysticks */ 20 | int num_joy, i; 21 | num_joy=SDL_NumJoysticks(); 22 | printf("%d joysticks found 23 | ", num_joy); 24 | for(i=0;i0){ 22 | // Open joystick 23 | joy=SDL_JoystickOpen(0); 24 | 25 | if(joy) 26 | { 27 | printf("Opened Joystick 0 28 | "); 29 | printf("Name: %s 30 | ", SDL_JoystickName(0)); 31 | printf("Number of Axes: %d 32 | ", SDL_JoystickNumAxes(joy)); 33 | printf("Number of Buttons: %d 34 | ", SDL_JoystickNumButtons(joy)); 35 | printf("Number of Balls: %d 36 | ", SDL_JoystickNumBalls(joy)); 37 | } 38 | else 39 | printf("Couldn\&'t open Joystick 0 40 | "); 41 | 42 | // Close if opened 43 | if(SDL_JoystickOpened(0)) 44 | SDL_JoystickClose(joy); 45 | }\fR 46 | .fi 47 | .PP 48 | .SH "SEE ALSO" 49 | .PP 50 | \fI\fBSDL_JoystickClose\fP\fR 51 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 52 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickOpened.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickOpened" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickOpened \- Determine if a joystick has been opened 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_JoystickOpened\fP\fR(\fBint index\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Determines whether a joystick has already been opened within the application\&. \fBindex\fR refers to the N\&'th joystick on the system\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB1\fR if the joystick has been opened, or \fB0\fR if it has not\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_JoystickOpen\fP\fR, \fI\fBSDL_JoystickClose\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_JoystickUpdate.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_JoystickUpdate" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_JoystickUpdate \- Updates the state of all joysticks 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_JoystickUpdate\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Updates the state(position, buttons, etc\&.) of all open joysticks\&. If joystick events have been enabled with \fI\fBSDL_JoystickEventState\fP\fR then this is called automatically in the event loop\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_JoystickEventState\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_KeyboardEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_KeyboardEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_KeyboardEvent \- Keyboard event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | Uint8 state; 10 | SDL_keysym keysym; 11 | } SDL_KeyboardEvent;\fR 12 | .fi 13 | .PP 14 | .SH "STRUCTURE DATA" 15 | .TP 20 16 | \fBtype\fR 17 | \fBSDL_KEYDOWN\fP or \fBSDL_KEYUP\fP 18 | .TP 20 19 | \fBstate\fR 20 | \fBSDL_PRESSED\fP or \fBSDL_RELEASED\fP 21 | .TP 20 22 | \fBkeysym\fR 23 | Contains key press information 24 | .SH "DESCRIPTION" 25 | .PP 26 | \fBSDL_KeyboardEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_KEYDOWN\fP or \fBSDL_KEYUP\fP is reported\&. 27 | .PP 28 | The \fBtype\fR and \fBstate\fR actually report the same information, they just use different values to do it! A keyboard event occurs when a key is released (\fBtype\fR=\fBSDK_KEYUP\fP or \fBstate\fR=\fBSDL_RELEASED\fP) and when a key is pressed (\fBtype\fR=\fBSDL_KEYDOWN\fP or \fBstate\fR=\fBSDL_PRESSED\fP)\&. The information on what key was pressed or released is in the \fI\fBkeysym\fR\fR structure\&. 29 | .PP 30 | .RS 31 | \fBNote: 32 | .PP 33 | Repeating \fBSDL_KEYDOWN\fP events will occur if key repeat is enabled (see \fI\fBSDL_EnableKeyRepeat\fP\fR)\&. 34 | .RE 35 | .SH "SEE ALSO" 36 | .PP 37 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_keysym\fR\fR, \fI\fBSDL_EnableKeyRepeat\fP\fR, \fI\fBSDL_EnableUNICODE\fP\fR 38 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 39 | -------------------------------------------------------------------------------- /docs/man3/SDL_KillThread.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_KillThread" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_KillThread \- Gracelessly terminates the thread\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBvoid \fBSDL_KillThread\fP\fR(\fBSDL_Thread *thread\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_KillThread\fP gracelessly terminates the thread associated with \fBthread\fR\&. If possible, you should use some other form of IPC to signal the thread to quit\&. 13 | .SH "SEE ALSO" 14 | .PP 15 | \fI\fBSDL_CreateThread\fP\fR, \fI\fBSDL_WaitThread\fP\fR 16 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 17 | -------------------------------------------------------------------------------- /docs/man3/SDL_LoadBMP.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_LoadBMP" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_LoadBMP \- Load a Windows BMP file into an SDL_Surface\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_Surface *\fBSDL_LoadBMP\fP\fR(\fBconst char *file\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Loads a surface from a named Windows BMP file\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns the new surface, or \fBNULL\fP if there was an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_SaveBMP\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_LoadWAV.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_LoadWAV" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_LoadWAV \- Load a WAVE file 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_AudioSpec *\fBSDL_LoadWAV\fP\fR(\fBconst char *file, SDL_AudioSpec *spec, Uint8 **audio_buf, Uint32 *audio_len\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_LoadWAV\fP This function loads a WAVE \fBfile\fR into memory\&. 12 | .PP 13 | If this function succeeds, it returns the given \fI\fBSDL_AudioSpec\fP\fR, filled with the audio data format of the wave data, and sets \fBaudio_buf\fR to a \fBmalloc\fP\&'d buffer containing the audio data, and sets \fBaudio_len\fR to the length of that audio buffer, in bytes\&. You need to free the audio buffer with \fI\fBSDL_FreeWAV\fP\fR when you are done with it\&. 14 | .PP 15 | This function returns \fBNULL\fP and sets the SDL error message if the wave file cannot be opened, uses an unknown data format, or is corrupt\&. Currently raw, MS-ADPCM and IMA-ADPCM WAVE files are supported\&. 16 | .SH "EXAMPLE" 17 | .PP 18 | .nf 19 | \f(CWSDL_AudioSpec wav_spec; 20 | Uint32 wav_length; 21 | Uint8 *wav_buffer; 22 | 23 | /* Load the WAV */ 24 | if( SDL_LoadWAV("test\&.wav", &wav_spec, &wav_buffer, &wav_length) == NULL ){ 25 | fprintf(stderr, "Could not open test\&.wav: %s 26 | ", SDL_GetError()); 27 | exit(-1); 28 | } 29 | \&. 30 | \&. 31 | \&. 32 | /* Do stuff with the WAV */ 33 | \&. 34 | \&. 35 | /* Free It */ 36 | SDL_FreeWAV(wav_buffer);\fR 37 | .fi 38 | .PP 39 | .SH "SEE ALSO" 40 | .PP 41 | \fI\fBSDL_AudioSpec\fR\fR, \fI\fBSDL_OpenAudio\fP\fR, \fI\fBSDL_FreeWAV\fP\fR 42 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 43 | -------------------------------------------------------------------------------- /docs/man3/SDL_LockAudio.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_LockAudio" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_LockAudio \- Lock out the callback function 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_LockAudio\fP\fR(\fBvoid\fR) 9 | .SH "DESCRIPTION" 10 | .PP 11 | The lock manipulated by these functions protects the callback function\&. During a LockAudio period, you can be guaranteed that the callback function is not running\&. Do not call these from the callback function or you will cause deadlock\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_OpenAudio\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_LockYUVOverlay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_LockYUVOverlay" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_LockYUVOverlay \- Lock an overlay 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_LockYUVOverlay\fP\fR(\fBSDL_Overlay *overlay\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Much the same as \fI\fBSDL_LockSurface\fP\fR, \fBSDL_LockYUVOverlay\fP locks the \fI\fBoverlay\fR\fR for direct access to pixel data\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on success, or \fB-1\fR on an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_UnlockYUVOverlay\fP\fR, \fI\fBSDL_CreateYUVOverlay\fP\fR, \fI\fBSDL_Overlay\fR\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_MapRGB.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_MapRGB" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_MapRGB \- Map a RGB color value to a pixel format\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint32 \fBSDL_MapRGB\fP\fR(\fBSDL_PixelFormat *fmt, Uint8 r, Uint8 g, Uint8 b\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Maps the RGB color value to the specified pixel format and returns the pixel value as a 32-bit int\&. 12 | .PP 13 | If the format has a palette (8-bit) the index of the closest matching color in the palette will be returned\&. 14 | .PP 15 | If the specified pixel format has an alpha component it will be returned as all 1 bits (fully opaque)\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | A pixel value best approximating the given RGB color value for a given pixel format\&. If the pixel format bpp (color depth) is less than 32-bpp then the unused upper bits of the return value can safely be ignored (e\&.g\&., with a 16-bpp format the return value can be assigned to a \fBUint16\fP, and similarly a \fBUint8\fP for an 8-bpp format)\&. 19 | .SH "SEE ALSO" 20 | .PP 21 | \fI\fBSDL_GetRGB\fP\fR, \fI\fBSDL_GetRGBA\fP\fR, \fI\fBSDL_MapRGBA\fP\fR, \fI\fBSDL_PixelFormat\fR\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_MapRGBA.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_MapRGBA" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_MapRGBA \- Map a RGBA color value to a pixel format\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBUint32 \fBSDL_MapRGBA\fP\fR(\fBSDL_PixelFormat *fmt, Uint8 r, Uint8 g, Uint8 b, Uint8 a\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Maps the RGBA color value to the specified pixel format and returns the pixel value as a 32-bit int\&. 12 | .PP 13 | If the format has a palette (8-bit) the index of the closest matching color in the palette will be returned\&. 14 | .PP 15 | If the specified pixel format has no alpha component the alpha value will be ignored (as it will be in formats with a palette)\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | A pixel value best approximating the given RGBA color value for a given pixel format\&. If the pixel format bpp (color depth) is less than 32-bpp then the unused upper bits of the return value can safely be ignored (e\&.g\&., with a 16-bpp format the return value can be assigned to a \fBUint16\fP, and similarly a \fBUint8\fP for an 8-bpp format)\&. 19 | .SH "SEE ALSO" 20 | .PP 21 | \fISDL_GetRGB\fR, \fISDL_GetRGBA\fR, \fISDL_MapRGB\fR, \fISDL_PixelFormat\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_MixAudio.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_MixAudio" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_MixAudio \- Mix audio data 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_MixAudio\fP\fR(\fBUint8 *dst, Uint8 *src, Uint32 len, int volume\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function takes two audio buffers of \fBlen\fR bytes each of the playing audio format and mixes them, performing addition, volume adjustment, and overflow clipping\&. The \fBvolume\fR ranges from 0 to \fBSDL_MIX_MAXVOLUME\fP and should be set to the maximum value for full audio volume\&. Note this does not change hardware volume\&. This is provided for convenience -- you can mix your own audio data\&. 12 | .PP 13 | .RS 14 | \fBNote: 15 | .PP 16 | Do not use this function for mixing together more than two streams of sample data\&. The output from repeated application of this function may be distorted by clipping, because there is no accumulator with greater range than the input (not to mention this being an inefficient way of doing it)\&. Use mixing functions from SDL_mixer, OpenAL, or write your own mixer instead\&. 17 | .RE 18 | .SH "SEE ALSO" 19 | .PP 20 | \fI\fBSDL_OpenAudio\fP\fR 21 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 22 | -------------------------------------------------------------------------------- /docs/man3/SDL_MouseButtonEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_MouseButtonEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_MouseButtonEvent \- Mouse button event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | Uint8 button; 10 | Uint8 state; 11 | Uint16 x, y; 12 | } SDL_MouseButtonEvent;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBtype\fR 18 | \fBSDL_MOUSEBUTTONDOWN\fP or \fBSDL_MOUSEBUTTONUP\fP 19 | .TP 20 20 | \fBbutton\fR 21 | The mouse button index (SDL_BUTTON_LEFT, SDL_BUTTON_MIDDLE, SDL_BUTTON_RIGHT) 22 | .TP 20 23 | \fBstate\fR 24 | \fBSDL_PRESSED\fP or \fBSDL_RELEASED\fP 25 | .TP 20 26 | \fBx\fR, \fBy\fR 27 | The X/Y coordinates of the mouse at press/release time 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_MouseButtonEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_MOUSEBUTTONDOWN\fP or \fBSDL_MOUSEBUTTONUP\fP is reported\&. 31 | .PP 32 | When a mouse button press or release is detected then number of the button pressed (from 1 to 255, with 1 usually being the left button and 2 the right) is placed into \fBbutton\fR, the position of the mouse when this event occured is stored in the \fBx\fR and the \fBy\fR fields\&. Like \fI\fBSDL_KeyboardEvent\fR\fR, information on whether the event was a press or a release event is stored in both the \fBtype\fR and \fBstate\fR fields, but this should be obvious\&. 33 | .SH "SEE ALSO" 34 | .PP 35 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_MouseMotionEvent\fR\fR 36 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 37 | -------------------------------------------------------------------------------- /docs/man3/SDL_NumJoysticks.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_NumJoysticks" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_NumJoysticks \- Count available joysticks\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_NumJoysticks\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Counts the number of joysticks attached to the system\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns the number of attached joysticks 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_JoystickName\fP\fR, \fI\fBSDL_JoystickOpen\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_Palette.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Palette" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Palette \- Color palette for 8-bit pixel formats 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | int ncolors; 9 | SDL_Color *colors; 10 | } SDL_Palette;\fR 11 | .fi 12 | .PP 13 | .SH "STRUCTURE DATA" 14 | .TP 20 15 | \fBncolors\fR 16 | Number of colors used in this palette 17 | .TP 20 18 | \fBcolors\fR 19 | Pointer to \fI\fBSDL_Color\fR\fR structures that make up the palette\&. 20 | .SH "DESCRIPTION" 21 | .PP 22 | Each pixel in an 8-bit surface is an index into the \fBcolors\fR field of the \fBSDL_Palette\fR structure store in \fI\fBSDL_PixelFormat\fR\fR\&. A \fBSDL_Palette\fR should never need to be created manually\&. It is automatically created when SDL allocates a \fBSDL_PixelFormat\fR for a surface\&. The colors values of a \fI\fBSDL_Surface\fR\fRs palette can be set with the \fI\fBSDL_SetColors\fP\fR\&. 23 | .SH "SEE ALSO" 24 | .PP 25 | \fI\fBSDL_Color\fR\fR, \fI\fBSDL_Surface\fR\fR, \fI\fBSDL_SetColors\fP\fR \fI\fBSDL_SetPalette\fP\fR 26 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 27 | -------------------------------------------------------------------------------- /docs/man3/SDL_PauseAudio.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_PauseAudio" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_PauseAudio \- Pauses and unpauses the audio callback processing 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_PauseAudio\fP\fR(\fBint pause_on\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | This function pauses and unpauses the audio callback processing\&. It should be called with \fBpause_on\fR=0 after opening the audio device to start playing sound\&. This is so you can safely initialize data for your callback function after opening the audio device\&. Silence will be written to the audio device during the pause\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_GetAudioStatus\fP\fR, \fI\fBSDL_OpenAudio\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_PeepEvents.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_PeepEvents" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_PeepEvents \- Checks the event queue for messages and optionally returns them\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_PeepEvents\fP\fR(\fBSDL_Event *events, int numevents, SDL_eventaction action, Uint32 mask\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Checks the event queue for messages and optionally returns them\&. 12 | .PP 13 | If \fBaction\fR is \fBSDL_ADDEVENT\fP, up to \fBnumevents\fR events will be added to the back of the event queue\&. 14 | .PP 15 | If \fBaction\fR is \fBSDL_PEEKEVENT\fP, up to \fBnumevents\fR events at the front of the event queue, matching \fI\fBmask\fR\fR, will be returned and will not be removed from the queue\&. 16 | .PP 17 | If \fBaction\fR is \fBSDL_GETEVENT\fP, up to \fBnumevents\fR events at the front of the event queue, matching \fI\fBmask\fR\fR, will be returned and will be removed from the queue\&. 18 | .PP 19 | This function is thread-safe\&. 20 | .SH "RETURN VALUE" 21 | .PP 22 | This function returns the number of events actually stored, or \fB-1\fR if there was an error\&. 23 | .SH "SEE ALSO" 24 | .PP 25 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_PollEvent\fP\fR, \fI\fBSDL_PushEvent\fP\fR 26 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 27 | -------------------------------------------------------------------------------- /docs/man3/SDL_PollEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_PollEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_PollEvent \- Polls for currently pending events\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_PollEvent\fP\fR(\fBSDL_Event *event\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Polls for currently pending events, and returns \fB1\fR if there are any pending events, or \fB0\fR if there are none available\&. 12 | .PP 13 | If \fBevent\fR is not \fBNULL\fP, the next event is removed from the queue and stored in that area\&. 14 | .SH "EXAMPLES" 15 | .PP 16 | .PP 17 | .nf 18 | \f(CWSDL_Event event; /* Event structure */ 19 | 20 | \&. 21 | \&. 22 | \&. 23 | /* Check for events */ 24 | while(SDL_PollEvent(&event)){ /* Loop until there are no events left on the queue */ 25 | switch(event\&.type){ /* Process the appropiate event type */ 26 | case SDL_KEYDOWN: /* Handle a KEYDOWN event */ 27 | printf("Oh! Key press 28 | "); 29 | break; 30 | case SDL_MOUSEMOTION: 31 | \&. 32 | \&. 33 | \&. 34 | default: /* Report an unhandled event */ 35 | printf("I don\&'t know what this event is! 36 | "); 37 | } 38 | }\fR 39 | .fi 40 | .PP 41 | .SH "SEE ALSO" 42 | .PP 43 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_WaitEvent\fP\fR, \fI\fBSDL_PeepEvents\fP\fR 44 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 45 | -------------------------------------------------------------------------------- /docs/man3/SDL_PumpEvents.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_PumpEvents" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_PumpEvents \- Pumps the event loop, gathering events from the input devices\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_PumpEvents\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Pumps the event loop, gathering events from the input devices\&. 12 | .PP 13 | \fBSDL_PumpEvents\fP gathers all the pending input information from devices and places it on the event queue\&. Without calls to \fBSDL_PumpEvents\fP no events would ever be placed on the queue\&. Often calls the need for \fBSDL_PumpEvents\fP is hidden from the user since \fI\fBSDL_PollEvent\fP\fR and \fI\fBSDL_WaitEvent\fP\fR implicitly call \fBSDL_PumpEvents\fP\&. However, if you are not polling or waiting for events (e\&.g\&. your filtering them), then you must call \fBSDL_PumpEvents\fP to force an event queue update\&. 14 | .PP 15 | .RS 16 | \fBNote: 17 | .PP 18 | You can only call this function in the thread that set the video mode\&. 19 | .RE 20 | .SH "SEE ALSO" 21 | .PP 22 | \fI\fBSDL_PollEvent\fP\fR 23 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 24 | -------------------------------------------------------------------------------- /docs/man3/SDL_PushEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_PushEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_PushEvent \- Pushes an event onto the event queue 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_PushEvent\fP\fR(\fBSDL_Event *event\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | The event queue can actually be used as a two way communication channel\&. Not only can events be read from the queue, but the user can also push their own events onto it\&. \fBevent\fR is a pointer to the event structure you wish to push onto the queue\&. 12 | .PP 13 | .RS 14 | \fBNote: 15 | .PP 16 | Pushing device input events onto the queue doesn\&'t modify the state of the device within SDL\&. 17 | .RE 18 | .SH "RETURN VALUE" 19 | .PP 20 | Returns \fB0\fR on success or \fB-1\fR if the event couldn\&'t be pushed\&. 21 | .SH "EXAMPLES" 22 | .PP 23 | See \fI\fBSDL_Event\fR\fR\&. 24 | .SH "SEE ALSO" 25 | .PP 26 | \fI\fBSDL_PollEvent\fP\fR, \fI\fBSDL_PeepEvents\fP\fR, \fI\fBSDL_Event\fR\fR 27 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 28 | -------------------------------------------------------------------------------- /docs/man3/SDL_Quit.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Quit" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Quit \- Shut down SDL 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_Quit\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_Quit\fP shuts down all SDL subsystems and frees the resources allocated to them\&. This should always be called before you exit\&. For the sake of simplicity you can set \fBSDL_Quit\fP as your \fBatexit\fP call, like: 12 | .PP 13 | .nf 14 | \f(CWSDL_Init(SDL_INIT_VIDEO|SDL_INIT_AUDIO); 15 | atexit(SDL_Quit); 16 | \&. 17 | \&.\fR 18 | .fi 19 | .PP 20 | .PP 21 | .RS 22 | \fBNote: 23 | .PP 24 | While using \fBatexit\fP maybe be fine for small programs, more advanced users should shut down SDL in their own cleanup code\&. Plus, using \fBatexit\fP in a library is a sure way to crash dynamically loaded code 25 | .RE 26 | .SH "SEE ALSO" 27 | .PP 28 | \fI\fBSDL_QuitSubsystem\fP\fR, \fI\fBSDL_Init\fP\fR 29 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 30 | -------------------------------------------------------------------------------- /docs/man3/SDL_QuitEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_QuitEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_QuitEvent \- Quit requested event 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type 9 | } SDL_QuitEvent;\fR 10 | .fi 11 | .PP 12 | .SH "STRUCTURE DATA" 13 | .TP 20 14 | \fBtype\fR 15 | \fBSDL_QUIT\fP 16 | .SH "DESCRIPTION" 17 | .PP 18 | \fBSDL_QuitEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used whan an event of type \fBSDL_QUIT\fP is reported\&. 19 | .PP 20 | As can be seen, the SDL_QuitEvent structure serves no useful purpose\&. The event itself, on the other hand, is very important\&. If you filter out or ignore a quit event then it is impossible for the user to close the window\&. On the other hand, if you do accept a quit event then the application window will be closed, and screen updates will still report success event though the application will no longer be visible\&. 21 | .PP 22 | .RS 23 | \fBNote: 24 | .PP 25 | The macro \fBSDL_QuitRequested\fP will return non-zero if a quit event is pending 26 | .RE 27 | .SH "SEE ALSO" 28 | .PP 29 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_SetEventFilter\fP\fR 30 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 31 | -------------------------------------------------------------------------------- /docs/man3/SDL_QuitSubSystem.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_QuitSubSystem" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_QuitSubSystem \- Shut down a subsystem 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_QuitSubSystem\fP\fR(\fBUint32 flags\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_QuitSubSystem\fP allows you to shut down a subsystem that has been previously initialized by \fI\fBSDL_Init\fP\fR or \fI\fBSDL_InitSubSystem\fP\fR\&. The \fBflags\fR tells \fBSDL_QuitSubSystem\fP which subsystems to shut down, it uses the same values that are passed to \fI\fBSDL_Init\fP\fR\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_Quit\fP\fR, \fI\fBSDL_Init\fP\fR, \fI\fBSDL_InitSubSystem\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_RWFromFile.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_FunctionName" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_FunctionName \- Short description of function 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBreturn type\fBSDL_FunctionName\fP\fR(\fBparameter\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Full description 12 | .SH "EXAMPLES" 13 | .PP 14 | examples here 15 | .SH "SEE ALSO" 16 | .PP 17 | \fISDL_AnotherFunction\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_Rect.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_Rect" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_Rect \- Defines a rectangular area 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Sint16 x, y; 9 | Uint16 w, h; 10 | } SDL_Rect;\fR 11 | .fi 12 | .PP 13 | .SH "STRUCTURE DATA" 14 | .TP 20 15 | \fBx, y\fR 16 | Position of the upper-left corner of the rectangle 17 | .TP 20 18 | \fBw, h\fR 19 | The width and height of the rectangle 20 | .SH "DESCRIPTION" 21 | .PP 22 | A \fBSDL_Rect\fR defines a rectangular area of pixels\&. It is used by \fI\fBSDL_BlitSurface\fP\fR to define blitting regions and by several other video functions\&. 23 | .SH "SEE ALSO" 24 | .PP 25 | \fI\fBSDL_BlitSurface\fP\fR, \fI\fBSDL_UpdateRect\fP\fR 26 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 27 | -------------------------------------------------------------------------------- /docs/man3/SDL_RemoveTimer.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_RemoveTimer" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_RemoveTimer \- Remove a timer which was added with \fISDL_AddTimer\fR\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_bool \fBSDL_RemoveTimer\fP\fR(\fBSDL_TimerID id\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Removes a timer callback previously added with \fISDL_AddTimer\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns a boolean value indicating success\&. 15 | .SH "EXAMPLES" 16 | .PP 17 | .PP 18 | .nf 19 | \f(CWSDL_RemoveTimer(my_timer_id);\fR 20 | .fi 21 | .PP 22 | .SH "SEE ALSO" 23 | .PP 24 | \fI\fBSDL_AddTimer\fP\fR 25 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 26 | -------------------------------------------------------------------------------- /docs/man3/SDL_ResizeEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_ResizeEvent" "3" "Tue 11 Sep 2001, 22:59" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_ResizeEvent \- Window resize event structure 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | int w, h; 10 | } SDL_ResizeEvent;\fR 11 | .fi 12 | .PP 13 | .SH "STRUCTURE DATA" 14 | .TP 20 15 | \fBtype\fR 16 | \fBSDL_VIDEORESIZE\fP 17 | .TP 20 18 | \fBw\fR, \fBh\fR 19 | New width and height of the window 20 | .SH "DESCRIPTION" 21 | .PP 22 | \fBSDL_ResizeEvent\fR is a member of the \fI\fBSDL_Event\fR\fR union and is used when an event of type \fBSDL_VIDEORESIZE\fP is reported\&. 23 | .PP 24 | When \fBSDL_RESIZABLE\fP is passed as a \fBflag\fR to \fI\fBSDL_SetVideoMode\fP\fR the user is allowed to resize the applications window\&. When the window is resized an \fBSDL_VIDEORESIZE\fP is report, with the new window width and height values stored in \fBw\fR and \fBh\fR, respectively\&. When an \fBSDL_VIDEORESIZE\fP is received the window should be resized to the new dimensions using \fI\fBSDL_SetVideoMode\fP\fR\&. 25 | .SH "SEE ALSO" 26 | .PP 27 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_SetVideoMode\fP\fR 28 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:59 29 | -------------------------------------------------------------------------------- /docs/man3/SDL_SaveBMP.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SaveBMP" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SaveBMP \- Save an SDL_Surface as a Windows BMP file\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_SaveBMP\fP\fR(\fBSDL_Surface *surface, const char *file\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Saves the \fBSDL_Surface\fR \fBsurface\fR as a Windows BMP file named \fBfile\fR\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR if successful or \fB-1\fR if there was an error\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_LoadBMP\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_SemPost.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SemPost" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SemPost \- Unlock a semaphore\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_SemPost\fP\fR(\fBSDL_sem *sem\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_SemPost\fP unlocks the semaphore pointed to by \fBsem\fR and atomically increments the semaphores value\&. Threads that were blocking on the semaphore may be scheduled after this call succeeds\&. 13 | .PP 14 | \fBSDL_SemPost\fP should be called after a semaphore is locked by a successful call to \fISDL_SemWait\fR, \fISDL_SemTryWait\fR or \fISDL_SemWaitTimeout\fR\&. 15 | .SH "RETURN VALUE" 16 | .PP 17 | Returns \fB0\fR if successful or \fB-1\fR if there was an error (leaving the semaphore unchanged)\&. 18 | .SH "EXAMPLES" 19 | .PP 20 | .PP 21 | .nf 22 | \f(CWSDL_SemPost(my_sem);\fR 23 | .fi 24 | .PP 25 | .SH "SEE ALSO" 26 | .PP 27 | \fI\fBSDL_CreateSemaphore\fP\fR, \fI\fBSDL_DestroySemaphore\fP\fR, \fI\fBSDL_SemWait\fP\fR, \fI\fBSDL_SemTryWait\fP\fR, \fI\fBSDL_SemWaitTimeout\fP\fR, \fI\fBSDL_SemValue\fP\fR 28 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 29 | -------------------------------------------------------------------------------- /docs/man3/SDL_SemTryWait.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SemTryWait" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SemTryWait \- Attempt to lock a semaphore but don\&'t suspend the thread\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_SemTryWait\fP\fR(\fBSDL_sem *sem\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_SemTryWait\fP is a non-blocking varient of \fI\fBSDL_SemWait\fP\fR\&. If the value of the semaphore pointed to by \fBsem\fR is positive it will atomically decrement the semaphore value and return 0, otherwise it will return \fBSDL_MUTEX_TIMEOUT\fR instead of suspending the thread\&. 13 | .PP 14 | After \fBSDL_SemTryWait\fP is successful, the semaphore can be released and its count atomically incremented by a successful call to \fISDL_SemPost\fR\&. 15 | .SH "RETURN VALUE" 16 | .PP 17 | Returns \fB0\fR if the semaphore was successfully locked or either \fBSDL_MUTEX_TIMEOUT\fR or \fB-1\fR if the thread would have suspended or there was an error, respectivly\&. 18 | .PP 19 | If the semaphore was not successfully locked, the semaphore will be unchanged\&. 20 | .SH "EXAMPLES" 21 | .PP 22 | .PP 23 | .nf 24 | \f(CWres = SDL_SemTryWait(my_sem); 25 | 26 | if (res == SDL_MUTEX_TIMEOUT) { 27 | return TRY_AGAIN; 28 | } 29 | if (res == -1) { 30 | return WAIT_ERROR; 31 | } 32 | 33 | \&.\&.\&. 34 | 35 | SDL_SemPost(my_sem);\fR 36 | .fi 37 | .PP 38 | .SH "SEE ALSO" 39 | .PP 40 | \fI\fBSDL_CreateSemaphore\fP\fR, \fI\fBSDL_DestroySemaphore\fP\fR, \fI\fBSDL_SemWait\fP\fR, \fI\fBSDL_SemWaitTimeout\fP\fR, \fI\fBSDL_SemPost\fP\fR, \fI\fBSDL_SemValue\fP\fR 41 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 42 | -------------------------------------------------------------------------------- /docs/man3/SDL_SemValue.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SemValue" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SemValue \- Return the current value of a semaphore\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL/SDL_thread\&.h" 8 | .sp 9 | \fBUint32 \fBSDL_SemValue\fP\fR(\fBSDL_sem *sem\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_SemValue()\fP returns the current semaphore value from the semaphore pointed to by \fBsem\fR\&. 13 | .SH "RETURN VALUE" 14 | .PP 15 | Returns current value of the semaphore\&. 16 | .SH "EXAMPLES" 17 | .PP 18 | .PP 19 | .nf 20 | \f(CW sem_value = SDL_SemValue(my_sem);\fR 21 | .fi 22 | .PP 23 | .SH "SEE ALSO" 24 | .PP 25 | \fI\fBSDL_CreateSemaphore\fP\fR, \fI\fBSDL_DestroySemaphore\fP\fR, \fI\fBSDL_SemWait\fP\fR, \fI\fBSDL_SemTryWait\fP\fR, \fI\fBSDL_SemWaitTimeout\fP\fR, \fI\fBSDL_SemPost\fP\fR 26 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 27 | -------------------------------------------------------------------------------- /docs/man3/SDL_SemWait.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SemWait" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SemWait \- Lock a semaphore and suspend the thread if the semaphore value is zero\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_SemWait\fP\fR(\fBSDL_sem *sem\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | \fBSDL_SemWait()\fP suspends the calling thread until either the semaphore pointed to by \fBsem\fR has a positive value, the call is interrupted by a signal or error\&. If the call is successful it will atomically decrement the semaphore value\&. 13 | .PP 14 | After \fBSDL_SemWait()\fP is successful, the semaphore can be released and its count atomically incremented by a successful call to \fISDL_SemPost\fR\&. 15 | .SH "RETURN VALUE" 16 | .PP 17 | Returns \fB0\fR if successful or \fB-1\fR if there was an error (leaving the semaphore unchanged)\&. 18 | .SH "EXAMPLES" 19 | .PP 20 | .PP 21 | .nf 22 | \f(CWif (SDL_SemWait(my_sem) == -1) { 23 | return WAIT_FAILED; 24 | } 25 | 26 | \&.\&.\&. 27 | 28 | SDL_SemPost(my_sem);\fR 29 | .fi 30 | .PP 31 | .SH "SEE ALSO" 32 | .PP 33 | \fI\fBSDL_CreateSemaphore\fP\fR, \fI\fBSDL_DestroySemaphore\fP\fR, \fI\fBSDL_SemTryWait\fP\fR, \fI\fBSDL_SemWaitTimeout\fP\fR, \fI\fBSDL_SemPost\fP\fR, \fI\fBSDL_SemValue\fP\fR 34 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 35 | -------------------------------------------------------------------------------- /docs/man3/SDL_SetClipRect.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SetClipRect" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SetClipRect \- Sets the clipping rectangle for a surface\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_SetClipRect\fP\fR(\fBSDL_Surface *surface, SDL_Rect *rect\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the clipping rectangle for a surface\&. When this surface is the destination of a blit, only the area within the clip rectangle will be drawn into\&. 12 | .PP 13 | The rectangle pointed to by \fBrect\fR will be clipped to the edges of the surface so that the clip rectangle for a surface can never fall outside the edges of the surface\&. 14 | .PP 15 | If \fBrect\fR is \fBNULL\fP the clipping rectangle will be set to the full size of the surface\&. 16 | .SH "SEE ALSO" 17 | .PP 18 | \fI\fBSDL_GetClipRect\fP\fR, \fI\fBSDL_BlitSurface\fP\fR, \fI\fBSDL_Surface\fR\fR 19 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 20 | -------------------------------------------------------------------------------- /docs/man3/SDL_SetColorKey.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SetColorKey" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SetColorKey \- Sets the color key (transparent pixel) in a blittable surface and RLE acceleration\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_SetColorKey\fP\fR(\fBSDL_Surface *surface, Uint32 flag, Uint32 key\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the color key (transparent pixel) in a blittable surface and enables or disables RLE blit acceleration\&. 12 | .PP 13 | RLE acceleration can substantially speed up blitting of images with large horizontal runs of transparent pixels (i\&.e\&., pixels that match the \fBkey\fR value)\&. The \fBkey\fR must be of the same pixel format as the \fBsurface\fR, \fI\fBSDL_MapRGB\fP\fR is often useful for obtaining an acceptable value\&. 14 | .PP 15 | If \fBflag\fR is \fBSDL_SRCCOLORKEY\fP then \fBkey\fR is the transparent pixel value in the source image of a blit\&. 16 | .PP 17 | If \fBflag\fR is OR\&'d with \fBSDL_RLEACCEL\fP then the surface will be draw using RLE acceleration when drawn with \fISDL_BlitSurface\fR\&. The surface will actually be encoded for RLE acceleration the first time \fISDL_BlitSurface\fR or \fISDL_DisplayFormat\fR is called on the surface\&. 18 | .PP 19 | If \fBflag\fR is 0, this function clears any current color key\&. 20 | .SH "RETURN VALUE" 21 | .PP 22 | This function returns \fB0\fR, or \fB-1\fR if there was an error\&. 23 | .SH "SEE ALSO" 24 | .PP 25 | \fI\fBSDL_BlitSurface\fP\fR, \fI\fBSDL_DisplayFormat\fP\fR, \fI\fBSDL_MapRGB\fP\fR, \fI\fBSDL_SetAlpha\fP\fR 26 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 27 | -------------------------------------------------------------------------------- /docs/man3/SDL_SetCursor.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SetCursor" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SetCursor \- Set the currently active mouse cursor\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_SetCursor\fP\fR(\fBSDL_Cursor *cursor\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the currently active cursor to the specified one\&. If the cursor is currently visible, the change will be immediately represented on the display\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_GetCursor\fP\fR, \fI\fBSDL_CreateCursor\fP\fR, \fI\fBSDL_ShowCursor\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_SetGamma.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SetGamma" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SetGamma \- Sets the color gamma function for the display 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_SetGamma\fP\fR(\fBfloat redgamma, float greengamma, float bluegamma\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the "gamma function" for the display of each color component\&. Gamma controls the brightness/contrast of colors displayed on the screen\&. A gamma value of 1\&.0 is identity (i\&.e\&., no adjustment is made)\&. 12 | .PP 13 | This function adjusts the gamma based on the "gamma function" parameter, you can directly specify lookup tables for gamma adjustment with \fISDL_SetGammaRamp\fR\&. 14 | .PP 15 | Not all display hardware is able to change gamma\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | Returns -1 on error (or if gamma adjustment is not supported)\&. 19 | .SH "SEE ALSO" 20 | .PP 21 | \fISDL_GetGammaRamp\fR \fISDL_SetGammaRamp\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_SetGammaRamp.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SetGammaRamp" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SetGammaRamp \- Sets the color gamma lookup tables for the display 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_SetGammaRamp\fP\fR(\fBUint16 *redtable, Uint16 *greentable, Uint16 *bluetable\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the gamma lookup tables for the display for each color component\&. Each table is an array of 256 Uint16 values, representing a mapping between the input and output for that channel\&. The input is the index into the array, and the output is the 16-bit gamma value at that index, scaled to the output color precision\&. You may pass NULL to any of the channels to leave them unchanged\&. 12 | .PP 13 | This function adjusts the gamma based on lookup tables, you can also have the gamma calculated based on a "gamma function" parameter with \fISDL_SetGamma\fR\&. 14 | .PP 15 | Not all display hardware is able to change gamma\&. 16 | .SH "RETURN VALUE" 17 | .PP 18 | Returns -1 on error (or if gamma adjustment is not supported)\&. 19 | .SH "SEE ALSO" 20 | .PP 21 | \fISDL_SetGamma\fR \fISDL_GetGammaRamp\fR 22 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 23 | -------------------------------------------------------------------------------- /docs/man3/SDL_SetModState.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SetModState" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SetModState \- Set the current key modifier state 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_SetModState\fP\fR(\fBSDLMod modstate\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | The inverse of \fI\fBSDL_GetModState\fP\fR, \fBSDL_SetModState\fP allows you to impose modifier key states on your application\&. 12 | .PP 13 | Simply pass your desired modifier states into \fBmodstate\fR\&. This value my be a logical OR\&'d combination of the following: 14 | .PP 15 | .nf 16 | \f(CWtypedef enum { 17 | KMOD_NONE = 0x0000, 18 | KMOD_LSHIFT= 0x0001, 19 | KMOD_RSHIFT= 0x0002, 20 | KMOD_LCTRL = 0x0040, 21 | KMOD_RCTRL = 0x0080, 22 | KMOD_LALT = 0x0100, 23 | KMOD_RALT = 0x0200, 24 | KMOD_LMETA = 0x0400, 25 | KMOD_RMETA = 0x0800, 26 | KMOD_NUM = 0x1000, 27 | KMOD_CAPS = 0x2000, 28 | KMOD_MODE = 0x4000, 29 | } SDLMod;\fR 30 | .fi 31 | .PP 32 | .SH "SEE ALSO" 33 | .PP 34 | \fI\fBSDL_GetModState\fP\fR 35 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 36 | -------------------------------------------------------------------------------- /docs/man3/SDL_ShowCursor.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_ShowCursor" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_ShowCursor \- Toggle whether or not the cursor is shown on the screen\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_ShowCursor\fP\fR(\fBint toggle\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Toggle whether or not the cursor is shown on the screen\&. Passing \fBSDL_ENABLE\fP displays the cursor and passing \fBSDL_DISABLE\fP hides it\&. The current state of the mouse cursor can be queried by passing \fBSDL_QUERY\fP, either \fBSDL_DISABLE\fP or \fBSDL_ENABLE\fP will be returned\&. 12 | .PP 13 | The cursor starts off displayed, but can be turned off\&. 14 | .SH "RETURN VALUE" 15 | .PP 16 | Returns the current state of the cursor\&. 17 | .SH "SEE ALSO" 18 | .PP 19 | \fI\fBSDL_CreateCursor\fP\fR, \fI\fBSDL_SetCursor\fP\fR 20 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 21 | -------------------------------------------------------------------------------- /docs/man3/SDL_SysWMEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_SysWMEvent" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_SysWMEvent \- Platform-dependent window manager event\&. 4 | .SH "DESCRIPTION" 5 | .PP 6 | The system window manager event contains a pointer to system-specific information about unknown window manager events\&. If you enable this event using \fI\fBSDL_EventState()\fP\fR, it will be generated whenever unhandled events are received from the window manager\&. This can be used, for example, to implement cut-and-paste in your application\&. 7 | .PP 8 | .nf 9 | \f(CWtypedef struct { 10 | Uint8 type; /* Always SDL_SysWM */ 11 | } SDL_SysWMEvent;\fR 12 | .fi 13 | .PP 14 | If you want to obtain system-specific information about the window manager, you can fill the version member of a \fBSDL_SysWMinfo\fR structure (details can be found in \fBSDL_syswm\&.h\fP, which must be included) using the \fBSDL_VERSION()\fP macro found in \fBSDL_version\&.h\fP, and pass it to the function: 15 | .PP 16 | .sp 17 | \fBint \fBSDL_GetWMInfo\fP\fR(\fBSDL_SysWMinfo *info\fR); 18 | .SH "SEE ALSO" 19 | .PP 20 | \fI\fBSDL_EventState\fP\fR 21 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 22 | -------------------------------------------------------------------------------- /docs/man3/SDL_ThreadID.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_ThreadID" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_ThreadID \- Get the 32-bit thread identifier for the current thread\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBUint32 \fBSDL_ThreadID\fP\fR(\fBvoid\fR) 10 | .SH "DESCRIPTION" 11 | .PP 12 | Get the 32-bit thread identifier for the current thread\&. 13 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 14 | -------------------------------------------------------------------------------- /docs/man3/SDL_UnlockAudio.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_UnlockAudio" "3" "Tue 11 Sep 2001, 22:58" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_UnlockAudio \- Unlock the callback function 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_UnlockAudio\fP\fR(\fBvoid\fR) 9 | .SH "DESCRIPTION" 10 | .PP 11 | Unlocks a previous \fI\fBSDL_LockAudio\fP\fR call\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_OpenAudio\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 22:58 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_UnlockSurface.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_UnlockSurface" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_UnlockSurface \- Unlocks a previously locked surface\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_UnlockSurface\fP\fR(\fBSDL_Surface *surface\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Surfaces that were previously locked using \fBSDL_LockSurface\fP must be unlocked with \fBSDL_UnlockSurface\fP\&. Surfaces should be unlocked as soon as possible\&. 12 | .PP 13 | It should be noted that since 1\&.1\&.8, surface locks are recursive\&. See \fI\fBSDL_LockSurface\fP\fR\&. 14 | .SH "SEE ALSO" 15 | .PP 16 | \fI\fBSDL_LockSurface\fP\fR 17 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 18 | -------------------------------------------------------------------------------- /docs/man3/SDL_UnlockYUVOverlay.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_UnlockYUVOverlay" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_UnlockYUVOverlay \- Unlock an overlay 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_UnlockYUVOverlay\fP\fR(\fBSDL_Overlay *overlay\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | The opposite to \fI\fBSDL_LockYUVOverlay\fP\fR\&. Unlocks a previously locked overlay\&. An overlay must be unlocked before it can be displayed\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_UnlockYUVOverlay\fP\fR, \fI\fBSDL_CreateYUVOverlay\fP\fR, \fI\fBSDL_Overlay\fR\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_UpdateRect.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_UpdateRect" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_UpdateRect \- Makes sure the given area is updated on the given screen\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_UpdateRect\fP\fR(\fBSDL_Surface *screen, Sint32 x, Sint32 y, Sint32 w, Sint32 h\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Makes sure the given area is updated on the given screen\&. The rectangle must be confined within the screen boundaries (no clipping is done)\&. 12 | .PP 13 | If \&'\fBx\fR\&', \&'\fBy\fR\&', \&'\fBw\fR\&' and \&'\fBh\fR\&' are all 0, \fBSDL_UpdateRect\fP will update the entire screen\&. 14 | .PP 15 | This function should not be called while \&'\fBscreen\fR\&' is \fIlocked\fR\&. 16 | .SH "SEE ALSO" 17 | .PP 18 | \fI\fBSDL_UpdateRects\fP\fR, \fI\fBSDL_Rect\fR\fR, \fI\fBSDL_Surface\fR\fR, \fI\fBSDL_LockSurface\fP\fR 19 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 20 | -------------------------------------------------------------------------------- /docs/man3/SDL_UpdateRects.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_UpdateRects" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_UpdateRects \- Makes sure the given list of rectangles is updated on the given screen\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_UpdateRects\fP\fR(\fBSDL_Surface *screen, int numrects, SDL_Rect *rects\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Makes sure the given list of rectangles is updated on the given screen\&. The rectangles must all be confined within the screen boundaries (no clipping is done)\&. 12 | .PP 13 | This function should not be called while \fBscreen\fR is \fIlocked\fR\&. 14 | .PP 15 | .RS 16 | \fBNote: 17 | .PP 18 | It is adviced to call this function only once per frame, since each call has some processing overhead\&. This is no restriction since you can pass any number of rectangles each time\&. 19 | .PP 20 | The rectangles are not automatically merged or checked for overlap\&. In general, the programmer can use his knowledge about his particular rectangles to merge them in an efficient way, to avoid overdraw\&. 21 | .RE 22 | .SH "SEE ALSO" 23 | .PP 24 | \fI\fBSDL_UpdateRect\fP\fR, \fI\fBSDL_Rect\fR\fR, \fI\fBSDL_Surface\fR\fR, \fI\fBSDL_LockSurface\fP\fR 25 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 26 | -------------------------------------------------------------------------------- /docs/man3/SDL_UserEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_UserEvent" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_UserEvent \- A user-defined event type 4 | .SH "STRUCTURE DEFINITION" 5 | .PP 6 | .nf 7 | \f(CWtypedef struct{ 8 | Uint8 type; 9 | int code; 10 | void *data1; 11 | void *data2; 12 | } SDL_UserEvent;\fR 13 | .fi 14 | .PP 15 | .SH "STRUCTURE DATA" 16 | .TP 20 17 | \fBtype\fR 18 | \fBSDL_USEREVENT\fP through to \fBSDL_NUMEVENTS-1\fP 19 | .TP 20 20 | \fBcode\fR 21 | User defined event code 22 | .TP 20 23 | \fBdata1\fR 24 | User defined data pointer 25 | .TP 20 26 | \fBdata2\fR 27 | User defined data pointer 28 | .SH "DESCRIPTION" 29 | .PP 30 | \fBSDL_UserEvent\fR is in the \fBuser\fR member of the structure \fI\fBSDL_Event\fR\fR\&. This event is unique, it is never created by SDL but only by the user\&. The event can be pushed onto the event queue using \fI\fBSDL_PushEvent\fP\fR\&. The contents of the structure members or completely up to the programmer, the only requirement is that \fBtype\fR is a value from \fBSDL_USEREVENT\fP to \fBSDL_NUMEVENTS-1\fP (inclusive)\&. 31 | .SH "EXAMPLES" 32 | .PP 33 | .PP 34 | .nf 35 | \f(CWSDL_Event event; 36 | 37 | event\&.type = SDL_USEREVENT; 38 | event\&.user\&.code = my_event_code; 39 | event\&.user\&.data1 = significant_data; 40 | event\&.user\&.data2 = 0; 41 | SDL_PushEvent(&event);\fR 42 | .fi 43 | .PP 44 | .SH "SEE ALSO" 45 | .PP 46 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_PushEvent\fP\fR 47 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 48 | -------------------------------------------------------------------------------- /docs/man3/SDL_VideoDriverName.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_VideoDriverName" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_VideoDriverName \- Obtain the name of the video driver 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBchar *\fBSDL_VideoDriverName\fP\fR(\fBchar *namebuf, int maxlen\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | The buffer pointed to by \fBnamebuf\fR is filled up to a maximum of \fBmaxlen\fR characters (include the NULL terminator) with the name of the initialised video driver\&. The driver name is a simple one word identifier like "x11" or "windib"\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fBNULL\fP if video has not been initialised with \fBSDL_Init\fP or a pointer to \fBnamebuf\fR otherwise\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_Init\fP\fR \fI\fBSDL_InitSubSystem\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_VideoModeOK.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_VideoModeOK" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_VideoModeOK \- Check to see if a particular video mode is supported\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_VideoModeOK\fP\fR(\fBint width, int height, int bpp, Uint32 flags\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | \fBSDL_VideoModeOK\fP returns \fB0\fR if the requested mode is not supported under any bit depth, or returns the bits-per-pixel of the closest available mode with the given width, height and requested \fIsurface\fR flags (see \fI\fBSDL_SetVideoMode\fP\fR)\&. 12 | .PP 13 | The bits-per-pixel value returned is only a suggested mode\&. You can usually request and bpp you want when \fIsetting\fR the video mode and SDL will emulate that color depth with a shadow video surface\&. 14 | .PP 15 | The arguments to \fBSDL_VideoModeOK\fP are the same ones you would pass to \fISDL_SetVideoMode\fR 16 | .SH "EXAMPLE" 17 | .PP 18 | .nf 19 | \f(CWSDL_Surface *screen; 20 | Uint32 bpp; 21 | \&. 22 | \&. 23 | \&. 24 | printf("Checking mode 640x480@16bpp\&. 25 | "); 26 | bpp=SDL_VideoModeOK(640, 480, 16, SDL_HWSURFACE); 27 | 28 | if(!bpp){ 29 | printf("Mode not available\&. 30 | "); 31 | exit(-1); 32 | } 33 | 34 | printf("SDL Recommends 640x480@%dbpp\&. 35 | ", bpp); 36 | screen=SDL_SetVideoMode(640, 480, bpp, SDL_HWSURFACE); 37 | \&. 38 | \&.\fR 39 | .fi 40 | .PP 41 | .SH "SEE ALSO" 42 | .PP 43 | \fI\fBSDL_SetVideoMode\fP\fR, \fI\fBSDL_GetVideoInfo\fP\fR 44 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 45 | -------------------------------------------------------------------------------- /docs/man3/SDL_WM_GetCaption.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WM_GetCaption" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WM_GetCaption \- Gets the window title and icon name\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_WM_GetCaption\fP\fR(\fBchar **title, char **icon\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Set pointers to the window \fBtitle\fR and \fBicon\fR name\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_WM_SetCaption\fP\fR, \fI\fBSDL_WM_SetIcon\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_WM_GrabInput.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WM_GrabInput" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WM_GrabInput \- Grabs mouse and keyboard input\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBSDL_GrabMode \fBSDL_WM_GrabInput\fP\fR(\fBSDL_GrabMode mode\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Grabbing means that the mouse is confined to the application window, and nearly all keyboard input is passed directly to the application, and not interpreted by a window manager, if any\&. 12 | .PP 13 | When \fBmode\fR is \fBSDL_GRAB_QUERY\fP the grab mode is not changed, but the current grab mode is returned\&. 14 | .PP 15 | .PP 16 | .nf 17 | \f(CWtypedef enum { 18 | SDL_GRAB_QUERY, 19 | SDL_GRAB_OFF, 20 | SDL_GRAB_ON 21 | } SDL_GrabMode;\fR 22 | .fi 23 | .PP 24 | 25 | .SH "RETURN VALUE" 26 | .PP 27 | The current/new \fBSDL_GrabMode\fR\&. 28 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 29 | -------------------------------------------------------------------------------- /docs/man3/SDL_WM_IconifyWindow.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WM_IconifyWindow" "3" "Tue 11 Sep 2001, 23:02" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WM_IconifyWindow \- Iconify/Minimise the window 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_WM_IconifyWindow\fP\fR(\fBvoid\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | If the application is running in a window managed environment SDL attempts to iconify/minimise it\&. If \fBSDL_WM_IconifyWindow\fP is successful, the application will receive a \fI\fBSDL_APPACTIVE\fP\fR loss event\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns non-zero on success or \fB0\fR if iconification is not support or was refused by the window manager\&. 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:02 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_WM_SetCaption.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WM_SetCaption" "3" "Tue 11 Sep 2001, 23:02" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WM_SetCaption \- Sets the window tile and icon name\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_WM_SetCaption\fP\fR(\fBconst char *title, const char *icon\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the title-bar and icon name of the display window\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_WM_GetCaption\fP\fR, \fI\fBSDL_WM_SetIcon\fP\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:02 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_WM_SetIcon.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WM_SetIcon" "3" "Tue 11 Sep 2001, 23:02" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WM_SetIcon \- Sets the icon for the display window\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_WM_SetIcon\fP\fR(\fBSDL_Surface *icon, Uint8 *mask\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Sets the icon for the display window\&. Win32 icons must be 32x32\&. 12 | .PP 13 | This function must be called before the first call to \fISDL_SetVideoMode\fR\&. 14 | .PP 15 | It takes an \fBicon\fR surface, and a \fBmask\fR in MSB format\&. 16 | .PP 17 | If \fBmask\fR is \fBNULL\fP, the entire icon surface will be used as the icon\&. 18 | .SH "EXAMPLE" 19 | .PP 20 | .nf 21 | \f(CWSDL_WM_SetIcon(SDL_LoadBMP("icon\&.bmp"), NULL);\fR 22 | .fi 23 | .PP 24 | .SH "SEE ALSO" 25 | .PP 26 | \fI\fBSDL_SetVideoMode\fP\fR, \fI\fBSDL_WM_SetCaption\fP\fR 27 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:02 28 | -------------------------------------------------------------------------------- /docs/man3/SDL_WM_ToggleFullScreen.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WM_ToggleFullScreen" "3" "Tue 11 Sep 2001, 23:02" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WM_ToggleFullScreen \- Toggles fullscreen mode 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_WM_ToggleFullScreen\fP\fR(\fBSDL_Surface *surface\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Toggles the application between windowed and fullscreen mode, if supported\&. (X11 is the only target currently supported, BeOS support is experimental)\&. 12 | .SH "RETURN VALUE" 13 | .PP 14 | Returns \fB0\fR on failure or \fB1\fR on success\&. 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:02 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_WaitEvent.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WaitEvent" "3" "Tue 11 Sep 2001, 23:00" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WaitEvent \- Waits indefinitely for the next available event\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBint \fBSDL_WaitEvent\fP\fR(\fBSDL_Event *event\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Waits indefinitely for the next available event, returning \fB1\fR, or \fB0\fR if there was an error while waiting for events\&. 12 | .PP 13 | If \fBevent\fR is not \fBNULL\fP, the next event is removed from the queue and stored in that area\&. 14 | .SH "SEE ALSO" 15 | .PP 16 | \fI\fBSDL_Event\fR\fR, \fI\fBSDL_PollEvent\fP\fR 17 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:00 18 | -------------------------------------------------------------------------------- /docs/man3/SDL_WaitThread.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WaitThread" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WaitThread \- Wait for a thread to finish\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBvoid \fBSDL_WaitThread\fP\fR(\fBSDL_Thread *thread, int *status\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Wait for a thread to finish (timeouts are not supported)\&. 13 | .SH "RETURN VALUE" 14 | .PP 15 | The return code for the thread function is placed in the area pointed to by \fBstatus\fR, if \fBstatus\fR is not \fBNULL\fR\&. 16 | .SH "SEE ALSO" 17 | .PP 18 | \fI\fBSDL_CreateThread\fP\fR 19 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 20 | -------------------------------------------------------------------------------- /docs/man3/SDL_WarpMouse.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_WarpMouse" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_WarpMouse \- Set the position of the mouse cursor\&. 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | .sp 8 | \fBvoid \fBSDL_WarpMouse\fP\fR(\fBUint16 x, Uint16 y\fR); 9 | .SH "DESCRIPTION" 10 | .PP 11 | Set the position of the mouse cursor (generates a mouse motion event)\&. 12 | .SH "SEE ALSO" 13 | .PP 14 | \fI\fBSDL_MouseMotionEvent\fR\fR 15 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 16 | -------------------------------------------------------------------------------- /docs/man3/SDL_mutexP.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_mutexP" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_mutexP \- Lock a mutex 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_mutexP\fP\fR(\fBSDL_mutex *mutex\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Locks the \fBmutex\fR, which was previously created with \fI\fBSDL_CreateMutex\fP\fR\&. If the mutex is already locked then \fBSDL_mutexP\fP will not return until it is \fIunlocked\fR\&. Returns \fB0\fR on success, or \fB-1\fR on an error\&. 13 | .PP 14 | SDL also defines a macro \fB#define SDL_LockMutex(m) SDL_mutexP(m)\fP\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CreateMutex\fP\fR, \fI\fBSDL_mutexV\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /docs/man3/SDL_mutexV.3: -------------------------------------------------------------------------------- 1 | .TH "SDL_mutexV" "3" "Tue 11 Sep 2001, 23:01" "SDL" "SDL API Reference" 2 | .SH "NAME" 3 | SDL_mutexV \- Unlock a mutex 4 | .SH "SYNOPSIS" 5 | .PP 6 | \fB#include "SDL\&.h" 7 | #include "SDL_thread\&.h" 8 | .sp 9 | \fBint \fBSDL_mutexV\fP\fR(\fBSDL_mutex *mutex\fR); 10 | .SH "DESCRIPTION" 11 | .PP 12 | Unlocks the \fBmutex\fR, which was previously created with \fI\fBSDL_CreateMutex\fP\fR\&. Returns \fB0\fR on success, or \fB-1\fR on an error\&. 13 | .PP 14 | SDL also defines a macro \fB#define SDL_UnlockMutex(m) SDL_mutexV(m)\fP\&. 15 | .SH "SEE ALSO" 16 | .PP 17 | \fI\fBSDL_CreateMutex\fP\fR, \fI\fBSDL_mutexP\fP\fR 18 | .\" created by instant / docbook-to-man, Tue 11 Sep 2001, 23:01 19 | -------------------------------------------------------------------------------- /dummy.c: -------------------------------------------------------------------------------- 1 | 2 | /* This is needed for automake, so that it can build an empty archive */ 3 | 4 | int pointless_symbol_so_the_archive_doesnt_look_empty; 5 | -------------------------------------------------------------------------------- /events/SDL_sysevents.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is SDL_free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include "../video/SDL_sysvideo.h" 25 | 26 | /* Useful functions and variables from SDL_sysevents.c */ 27 | 28 | #ifdef __BEOS__ /* The Be event loop runs in a separate thread */ 29 | #define MUST_THREAD_EVENTS 30 | #endif 31 | 32 | #ifdef __WIN32__ /* Win32 doesn't allow a separate event thread */ 33 | #define CANT_THREAD_EVENTS 34 | #endif 35 | 36 | #ifdef IPOD /* iPod doesn't support threading at all */ 37 | #define CANT_THREAD_EVENTS 38 | #endif 39 | 40 | #ifdef __MACOS__ /* MacOS 7/8 don't support preemptive multi-tasking */ 41 | #define CANT_THREAD_EVENTS 42 | #endif 43 | 44 | #ifdef __OS2__ /* The OS/2 event loop runs in a separate thread */ 45 | #define MUST_THREAD_EVENTS 46 | #endif 47 | -------------------------------------------------------------------------------- /gl_dummy/makefile: -------------------------------------------------------------------------------- 1 | DEFINES= DEFINE=inline=__inline 2 | CFLAGS = VERBOSE CPU=68040 CODE=FAR DATA=NEAR 3 | GCCFLAGS = -DFULL_SPECIFIERS -m68040 -I../headers/ -O3 -fomit-frame-pointer -mnobitfield 4 | GLFLAGS = -DSHARED_LIB 5 | 6 | #GCCDEFINES = -DNO_SIGNAL_H 7 | 8 | OBJS = dummy.o 9 | 10 | %.o: %.c 11 | $(CC) $(GCCFLAGS) $(GCCDEFINES) -o $@ -c $*.c 12 | 13 | 14 | #%.wo: %.c 15 | # ppc-amigaos-gcc -warpup $(GCCFLAGS) $(GCCDEFINES) -DWARPOS -DNO_AMIGADEBUG -o $@ -c $*.c 16 | 17 | all: libgl_dummy.a 18 | 19 | # gg:lib/libb/libnix/libnix.a gg:lib/libb/libnix/libstubs.a gg:lib/libb/libnix/libm.a -o $@ -ldebug 20 | 21 | # slink to $@ LIBFD SDL.fd lib lib:sc.lib lib:scm.lib lib:debug.lib noicons libversion 1 librevision 2 smalldata stripdebug libprefix _LIB from lib:libent.o lib:libinitr.o $(OBJS) SDL_amigasas.so 22 | # gcc -v -fbaserel -nostartfiles -noixemul gg:lib/libnix/libinitr.o $(LOBJS) -o $@ -lm -ldebug 23 | # gcc -v -s -resident -nostdlib gg:lib/libnix/libinitr.o $(LOBJS) -o $@ -ldebug 24 | 25 | libgl_dummy.a: $(OBJS) 26 | -rm -f libgl_dummy.a 27 | ar cru libgl_dummy.a $(OBJS) 28 | /usr/local/amiga/bin/ranlib libgl_dummy.a 29 | -cp libgl_dummy.a /usr/local/amiga/m68k-amigaos/lib/ 30 | 31 | clean: 32 | -rm -f $(OBJS) 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /include/SDL/SDL_byteorder.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | /** 24 | * @file SDL_byteorder.h 25 | * @deprecated Use SDL_endian.h instead 26 | */ 27 | 28 | /* DEPRECATED */ 29 | #include "SDL_endian.h" 30 | -------------------------------------------------------------------------------- /include/SDL/SDL_config.h.default: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | #ifndef _SDL_config_h 24 | #define _SDL_config_h 25 | 26 | #include "SDL_platform.h" 27 | 28 | /* Add any platform that doesn't build using the configure system */ 29 | #if defined(__DREAMCAST__) 30 | #include "SDL_config_dreamcast.h" 31 | #elif defined(__MACOS__) 32 | #include "SDL_config_macos.h" 33 | #elif defined(__MACOSX__) 34 | #include "SDL_config_macosx.h" 35 | #elif defined(__SYMBIAN32__) 36 | #include "SDL_config_symbian.h" /* must be before win32! */ 37 | #elif defined(__WIN32__) 38 | #include "SDL_config_win32.h" 39 | #elif defined(__OS2__) 40 | #include "SDL_config_os2.h" 41 | #else 42 | #include "SDL_config_minimal.h" 43 | #endif /* platform config */ 44 | 45 | #endif /* _SDL_config_h */ 46 | -------------------------------------------------------------------------------- /include/SDL/SDL_copying.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | -------------------------------------------------------------------------------- /include/SDL/SDL_getenv.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | /** @file SDL_getenv.h 24 | * @deprecated Use SDL_stdinc.h instead 25 | */ 26 | 27 | /* DEPRECATED */ 28 | #include "SDL_stdinc.h" 29 | -------------------------------------------------------------------------------- /include/SDL/SDL_name.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef _SDLname_h_ 3 | #define _SDLname_h_ 4 | 5 | #if defined(__STDC__) || defined(__cplusplus) 6 | #define NeedFunctionPrototypes 1 7 | #endif 8 | 9 | #define SDL_NAME(X) SDL_##X 10 | 11 | #endif /* _SDLname_h_ */ 12 | -------------------------------------------------------------------------------- /include/SDL/SDL_types.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | /** @file SDL_types.h 24 | * @deprecated Use SDL_stdinc.h instead. 25 | */ 26 | 27 | /* DEPRECATED */ 28 | #include "SDL_stdinc.h" 29 | -------------------------------------------------------------------------------- /include/SDL/close_code.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | /** 24 | * @file close_code.h 25 | * This file reverses the effects of begin_code.h and should be included 26 | * after you finish any function and structure declarations in your headers 27 | */ 28 | 29 | #undef _begin_code_h 30 | 31 | /** 32 | * @file close_code.h 33 | * Reset structure packing at previous byte alignment 34 | */ 35 | #if defined(_MSC_VER) || defined(__MWERKS__) || defined(__WATCOMC__) || defined(__BORLANDC__) 36 | #ifdef __BORLANDC__ 37 | #pragma nopackwarning 38 | #endif 39 | #if (defined(__MWERKS__) && defined(__MACOS__)) 40 | #pragma options align=reset 41 | #pragma enumsalwaysint reset 42 | #else 43 | #pragma pack(pop) 44 | #endif 45 | #endif /* Compiler needs structure packing set */ 46 | 47 | -------------------------------------------------------------------------------- /main/dummy/SDL_dummy_main.c: -------------------------------------------------------------------------------- 1 | 2 | /* Include the SDL main definition header */ 3 | #include "SDL_main.h" 4 | 5 | #ifdef main 6 | #undef main 7 | int main(int argc, char *argv[]) 8 | { 9 | return(SDL_main(argc, argv)); 10 | } 11 | #else 12 | /* Nothing to do on this platform */ 13 | #endif 14 | -------------------------------------------------------------------------------- /mydebug.h: -------------------------------------------------------------------------------- 1 | #ifndef MYDEBUG 2 | 3 | #ifndef NO_AMIGADEBUG 4 | #define D(x) x 5 | #define bug kprintf 6 | 7 | extern void kprintf(const char *, ...); 8 | 9 | #else 10 | #define D(x) 11 | #endif 12 | 13 | #define MAKE_HIT() {char *a=NULL,b;b=*a;} 14 | 15 | #define MYDEBUG 16 | #endif 17 | -------------------------------------------------------------------------------- /thread/amigaos/SDL_sysmutex_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #ifndef _SDL_mutex_c_h 25 | #define _SDL_mutex_c_h 26 | 27 | #if !SDL_THREADS_DISABLED 28 | 29 | struct SDL_mutex { 30 | int recursive; 31 | Uint32 owner; 32 | SDL_sem *sem; 33 | }; 34 | 35 | #endif 36 | 37 | 38 | #endif /* _SDL_mutex_c_h */ 39 | 40 | -------------------------------------------------------------------------------- /thread/generic/SDL_sysmutex_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | -------------------------------------------------------------------------------- /thread/generic/SDL_systhread.c: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Thread management routines for SDL */ 25 | 26 | #include "SDL_thread.h" 27 | #include "../SDL_systhread.h" 28 | 29 | int SDL_SYS_CreateThread(SDL_Thread *thread, void *args) 30 | { 31 | SDL_SetError("Threads are not supported on this platform"); 32 | return(-1); 33 | } 34 | 35 | void SDL_SYS_SetupThread(void) 36 | { 37 | return; 38 | } 39 | 40 | Uint32 SDL_ThreadID(void) 41 | { 42 | return(0); 43 | } 44 | 45 | void SDL_SYS_WaitThread(SDL_Thread *thread) 46 | { 47 | return; 48 | } 49 | 50 | void SDL_SYS_KillThread(SDL_Thread *thread) 51 | { 52 | return; 53 | } 54 | 55 | -------------------------------------------------------------------------------- /thread/generic/SDL_systhread_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2004 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Stub until we implement threads on this platform */ 25 | typedef int SYS_ThreadHandle; 26 | -------------------------------------------------------------------------------- /thread/pth/SDL_sysmutex_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #ifndef _SDL_SYSMUTEX_C_H_ 25 | #define _SDL_SYSMUTEX_C_H_ 26 | 27 | struct SDL_mutex { 28 | pth_mutex_t mutexpth_p; 29 | }; 30 | 31 | #endif /* _SDL_SYSMUTEX_C_H_ */ 32 | -------------------------------------------------------------------------------- /thread/pth/SDL_systhread_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2004 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #ifndef _SDL_SYSTHREAD_C_H_ 25 | #define _SDL_SYSTHREAD_C_H_ 26 | 27 | #include 28 | 29 | typedef pth_t SYS_ThreadHandle; 30 | 31 | #endif /* _SDL_SYSTHREAD_C_H_ */ 32 | -------------------------------------------------------------------------------- /thread/pthread/SDL_sysmutex_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #ifndef _SDL_mutex_c_h 25 | #define _SDL_mutex_c_h 26 | 27 | struct SDL_mutex { 28 | pthread_mutex_t id; 29 | }; 30 | 31 | #endif /* _SDL_mutex_c_h */ 32 | -------------------------------------------------------------------------------- /thread/pthread/SDL_systhread_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2004 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include 25 | 26 | typedef pthread_t SYS_ThreadHandle; 27 | -------------------------------------------------------------------------------- /timer/SDL_systimer.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* The system dependent timer handling functions */ 25 | 26 | #include "SDL_timer.h" 27 | #include "SDL_timer_c.h" 28 | 29 | 30 | /* Initialize the system dependent timer subsystem */ 31 | extern int SDL_SYS_TimerInit(void); 32 | 33 | /* Quit the system dependent timer subsystem */ 34 | extern void SDL_SYS_TimerQuit(void); 35 | 36 | /* Start a timer set up by SDL_SetTimer() */ 37 | extern int SDL_SYS_StartTimer(void); 38 | 39 | /* Stop a previously started timer */ 40 | extern void SDL_SYS_StopTimer(void); 41 | -------------------------------------------------------------------------------- /timer/macos/FastTimes.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/timer/macos/FastTimes.c -------------------------------------------------------------------------------- /timer/macos/FastTimes.h: -------------------------------------------------------------------------------- 1 | /* File "FastTimes.h" - Original code by Matt Slot */ 2 | #include "SDL_config.h" 3 | /* Created 4/24/99 - This file is hereby placed in the public domain */ 4 | /* Updated 5/21/99 - Calibrate to VIA, add TBR support, renamed functions */ 5 | /* Updated 10/4/99 - Use AbsoluteToNanoseconds() in case Absolute = double */ 6 | /* Updated 2/15/00 - Check for native Time Manager, no need to calibrate */ 7 | /* Updated 3/21/00 - Fixed ns conversion, create 2 different scale factors */ 8 | /* Updated 5/03/00 - Added copyright and placed into PD. No code changes */ 9 | 10 | /* This file is Copyright (C) Matt Slot, 1999-2000. It is hereby placed into 11 | the public domain. The author makes no warranty as to fitness or stability */ 12 | 13 | #ifndef __FAST_TIMES_HEADER__ 14 | #define __FAST_TIMES_HEADER__ 15 | 16 | /* **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** */ 17 | /* **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** */ 18 | 19 | extern void FastInitialize(void); 20 | extern UInt64 FastMicroseconds(void); 21 | extern UInt64 FastMilliseconds(void); 22 | extern StringPtr FastMethod(void); 23 | 24 | /* **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** */ 25 | /* **** **** **** **** **** **** **** **** **** **** **** **** **** **** **** */ 26 | 27 | #endif /* __FAST_TIMES_HEADER__ */ 28 | -------------------------------------------------------------------------------- /timer/mint/SDL_vbltimer_s.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* 25 | * TOS/MiNT timer driver 26 | * based on vbl vector 27 | * 28 | * Patrice Mandin 29 | */ 30 | 31 | extern volatile long SDL_Atari_hz200; 32 | 33 | /* Functions prototypes */ 34 | extern int SDL_AtariVblInstall(void *newvector); 35 | extern void SDL_AtariVblUninstall(void *newvector); 36 | -------------------------------------------------------------------------------- /video/SDL_RLEaccel.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/video/SDL_RLEaccel.c -------------------------------------------------------------------------------- /video/SDL_RLEaccel_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2009 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Useful functions and variables from SDL_RLEaccel.c */ 25 | 26 | extern int SDL_RLESurface(SDL_Surface *surface); 27 | extern int SDL_RLEBlit(SDL_Surface *src, SDL_Rect *srcrect, 28 | SDL_Surface *dst, SDL_Rect *dstrect); 29 | extern int SDL_RLEAlphaBlit(SDL_Surface *src, SDL_Rect *srcrect, 30 | SDL_Surface *dst, SDL_Rect *dstrect); 31 | extern void SDL_UnRLESurface(SDL_Surface *surface, int recode); 32 | -------------------------------------------------------------------------------- /video/SDL_leaks.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Define this if you want surface leak detection code enabled */ 25 | /*#define CHECK_LEAKS*/ 26 | 27 | /* Global variables used to check leaks in code using SDL */ 28 | 29 | #ifdef CHECK_LEAKS 30 | extern int surfaces_allocated; 31 | #endif 32 | -------------------------------------------------------------------------------- /video/SDL_stretch_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Perform a stretch blit between two surfaces of the same format. 25 | NOTE: This function is not safe to call from multiple threads! 26 | */ 27 | extern int SDL_SoftStretch(SDL_Surface *src, SDL_Rect *srcrect, 28 | SDL_Surface *dst, SDL_Rect *dstrect); 29 | 30 | -------------------------------------------------------------------------------- /video/SDL_yuv_sw_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include "SDL_video.h" 25 | #include "SDL_sysvideo.h" 26 | 27 | /* This is the software implementation of the YUV video overlay support */ 28 | 29 | extern SDL_Overlay *SDL_CreateYUV_SW(_THIS, int width, int height, Uint32 format, SDL_Surface *display); 30 | 31 | extern int SDL_LockYUV_SW(_THIS, SDL_Overlay *overlay); 32 | 33 | extern void SDL_UnlockYUV_SW(_THIS, SDL_Overlay *overlay); 34 | 35 | extern int SDL_DisplayYUV_SW(_THIS, SDL_Overlay *overlay, SDL_Rect *src, SDL_Rect *dst); 36 | 37 | extern void SDL_FreeYUV_SW(_THIS, SDL_Overlay *overlay); 38 | -------------------------------------------------------------------------------- /video/SDL_yuvfuncs.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* This is the definition of the YUV video surface function structure */ 25 | 26 | #include "SDL_video.h" 27 | #include "SDL_sysvideo.h" 28 | 29 | #ifndef _THIS 30 | #define _THIS SDL_VideoDevice *_this 31 | #endif 32 | struct private_yuvhwfuncs { 33 | int (*Lock)(_THIS, SDL_Overlay *overlay); 34 | void (*Unlock)(_THIS, SDL_Overlay *overlay); 35 | int (*Display)(_THIS, SDL_Overlay *overlay, SDL_Rect *src, SDL_Rect *dst); 36 | void (*FreeHW)(_THIS, SDL_Overlay *overlay); 37 | }; 38 | -------------------------------------------------------------------------------- /video/amigaos/SDL_amigaevents_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | #ifdef SAVE_RCSID 24 | static char rcsid = 25 | "@(#) $Id: SDL_amigaevents_c.h,v 1.2 2002/11/20 08:51:18 gabry Exp $"; 26 | #endif 27 | 28 | #include "SDL_cgxvideo.h" 29 | 30 | /* Functions to be exported */ 31 | extern void amiga_InitOSKeymap(_THIS); 32 | 33 | extern void amiga_PumpEvents(_THIS); 34 | 35 | -------------------------------------------------------------------------------- /video/amigaos/SDL_amigamouse_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | #ifdef SAVE_RCSID 24 | static char rcsid = 25 | "@(#) $Id: SDL_amigamouse_c.h,v 1.2 2002/11/20 08:51:19 gabry Exp $"; 26 | #endif 27 | 28 | #include "SDL_cgxvideo.h" 29 | 30 | /* Functions to be exported */ 31 | extern void amiga_FreeWMCursor(_THIS, 32 | WMcursor *cursor 33 | ); 34 | 35 | extern WMcursor *amiga_CreateWMCursor(_THIS, 36 | Uint8 *data, Uint8 37 | *mask, 38 | int w, 39 | int h, 40 | int hot_x, 41 | int hot_y 42 | ); 43 | 44 | extern int amiga_ShowWMCursor(_THIS, 45 | WMcursor *cursor 46 | ); 47 | 48 | extern void amiga_WarpWMCursor(_THIS, 49 | Uint16 x, Uint16 50 | y); 51 | 52 | extern void amiga_CheckMouseMode(_THIS); 53 | -------------------------------------------------------------------------------- /video/amigaos/SDL_cgxwm_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Library General Public 7 | License as published by the Free Software Foundation; either 8 | version 2 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Library General Public License for more details. 14 | 15 | You should have received a copy of the GNU Library General Public 16 | License along with this library; if not, write to the Free 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | #ifdef SAVE_RCSID 24 | static char rcsid = 25 | "@(#) $Id: SDL_cgxwm_c.h,v 1.2 2002/11/20 08:51:54 gabry Exp $"; 26 | #endif 27 | 28 | #include "SDL_cgxvideo.h" 29 | 30 | /* Functions to be exported */ 31 | extern void CGX_SetCaption(_THIS, 32 | const char *title, 33 | const char *icon 34 | ); 35 | 36 | extern void CGX_SetIcon(_THIS, 37 | SDL_Surface *icon, Uint8 38 | *mask); 39 | 40 | extern int CGX_IconifyWindow(_THIS); 41 | 42 | extern SDL_GrabMode CGX_GrabInputNoLock(_THIS, 43 | SDL_GrabMode mode 44 | ); 45 | 46 | extern SDL_GrabMode CGX_GrabInput(_THIS, 47 | SDL_GrabMode mode 48 | ); 49 | 50 | extern int CGX_GetWMInfo(_THIS, 51 | SDL_SysWMinfo *info 52 | ); 53 | 54 | -------------------------------------------------------------------------------- /video/apollo/apolloammxenable.h: -------------------------------------------------------------------------------- 1 | /* 2 | apolloammxenable.h 3 | 4 | author: Henryk Richter 5 | 6 | purpose: Enable AMMX (per task) 7 | 8 | */ 9 | #ifndef _INC_APOLLOAMMXENABLE_H 10 | #define _INC_APOLLOAMMXENABLE_H 11 | 12 | #include "asminterface.h" 13 | 14 | /* 15 | return 0 = fail 16 | 1 = AMMX ready for use 17 | */ 18 | ASM int Apollo_EnableAMMX( void ); 19 | 20 | /* 21 | 1 = AMMX is ready for use 22 | 0 = AMMX unavailable 23 | */ 24 | extern unsigned char Apollo_AMMXon; 25 | extern unsigned char Apollo_AMMX2on; 26 | 27 | #endif /* _INC_APOLLOAMMXENABLE_H */ 28 | -------------------------------------------------------------------------------- /video/apollo/asminterface.h: -------------------------------------------------------------------------------- 1 | /* 2 | asminterface.h 3 | 4 | Henryk Richter 5 | 6 | Interface macros for ASM subroutines for GCC and SAS/C 7 | 8 | syntax: 9 | ASM SAVEDS int some_asm_subroutine( 10 | ASMR(d3) unsigned int some_data ASMREG(d3), 11 | ASMR(a0) unsigned char *some_address ASMREG(a0) 12 | ); 13 | 14 | Reason for the double spec of An/Dn: some compilers (SAS) require the register 15 | on the left hand side, gcc on the right hand side. I wanted to avoid a big macro 16 | for the whole argument and moved the stuff into two macros per argument. 17 | 18 | */ 19 | #ifndef _INC_ASMINTERFACE_H 20 | #define _INC_ASMINTERFACE_H 21 | 22 | #ifdef __SASC 23 | 24 | #define ASM __asm 25 | #define ASMR(x) register __ ## x 26 | #define ASMREG(x) 27 | #define SAVEDS __saveds 28 | 29 | #else /* __SASC */ 30 | 31 | #ifdef __GNUC__ 32 | 33 | #define ASM 34 | #define ASMR(x) register 35 | #define ASMREG(x) __asm("" #x "") 36 | #define SAVEDS __saveds 37 | 38 | #else /* __GNUC__ */ 39 | 40 | #error "Compiler not supported yet in asminterface.h" 41 | 42 | #endif /* __GNUC__ */ 43 | #endif /* __SASC */ 44 | 45 | 46 | #endif /* _INC_ASMINTERFACE_H */ 47 | -------------------------------------------------------------------------------- /video/apollo/colorkeyapollo.h: -------------------------------------------------------------------------------- 1 | /* 2 | colorkeyapollo.h 3 | 4 | author: Henryk Richter 5 | 6 | purpose: AMMX optimized SDL blitter functions 7 | 8 | */ 9 | #ifndef _INC_COLORKEYAPOLLO_H 10 | #define _INC_COLORKEYAPOLLO_H 11 | 12 | #include "asminterface.h" 13 | 14 | /* 15 | interface for all functions 16 | input: iptr = input in any color format 17 | optr = output in any color format 18 | istride = line width (total, in bytes) of input 19 | ostride = line width (total, in bytes) of output 20 | w = width (in pixels) to copy 21 | h = height (in pixels) to copy 22 | key = color key to compare (if match, no write) 23 | */ 24 | #define APOLLOCBLIT(_name_) \ 25 | ASM void _name_( ASMR(a0) unsigned char *iptr ASMREG(a0),\ 26 | ASMR(a1) unsigned char *optr ASMREG(a1),\ 27 | ASMR(d2) unsigned int istride ASMREG(d2),\ 28 | ASMR(d3) unsigned int ostride ASMREG(d3),\ 29 | ASMR(d0) unsigned int w ASMREG(d0),\ 30 | ASMR(d1) unsigned int h ASMREG(d1),\ 31 | ASMR(d6) unsigned int key ASMREG(d6)\ 32 | ); 33 | 34 | 35 | /* target: RGB565 */ 36 | //APOLLOCBLIT( ApolloARGBtoRGB565 ); 37 | //APOLLOCBLIT( ApolloRGBtoRGB565 ); 38 | //APOLLOCBLIT( ApolloBGRtoRGB565 ); 39 | //APOLLOCBLIT( ApolloBGRAtoRGB565 ); 40 | 41 | /* target: RGB24 */ 42 | //APOLLOCBLIT( ApolloARGBtoRGB24 ); 43 | //APOLLOCBLIT( ApolloBGRAtoRGB24 ); 44 | //APOLLOCBLIT( ApolloBGRtoRGB24 ); 45 | 46 | /* target: RGB32 */ 47 | //APOLLOCBLIT( ApolloKeyARGBtoARGB ); 48 | 49 | APOLLOCBLIT( ApolloKeyRGB565toRGB565 ); 50 | 51 | 52 | #endif /* _INC_COLORKEYAPOLLO_H */ 53 | -------------------------------------------------------------------------------- /video/blank_cursor.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | 23 | /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * 24 | * A default blank 8x8 cursor */ 25 | 26 | #define BLANK_CWIDTH 8 27 | #define BLANK_CHEIGHT 8 28 | #define BLANK_CHOTX 0 29 | #define BLANK_CHOTY 0 30 | 31 | static unsigned char blank_cdata[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; 32 | static unsigned char blank_cmask[8] = { 0, 0, 0, 0, 0, 0, 0, 0 }; 33 | 34 | -------------------------------------------------------------------------------- /video/default_cursor.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/AmigaPorts/libSDL12/324f6bc150eea7fbf25a0fb9a4d26f1ef6b9d984/video/default_cursor.h -------------------------------------------------------------------------------- /video/directfb/SDL_DirectFB_events.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include "SDL_DirectFB_video.h" 25 | 26 | /* Functions to be exported */ 27 | extern void DirectFB_InitOSKeymap(_THIS); 28 | extern void DirectFB_PumpEvents(_THIS); 29 | 30 | -------------------------------------------------------------------------------- /video/directfb/SDL_DirectFB_yuv.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* This is the DirectFB implementation of YUV video overlays */ 25 | 26 | #include "SDL_video.h" 27 | #include "SDL_DirectFB_video.h" 28 | 29 | extern SDL_Overlay *DirectFB_CreateYUVOverlay(_THIS, int width, int height, Uint32 format, SDL_Surface *display); 30 | 31 | extern int DirectFB_LockYUVOverlay(_THIS, SDL_Overlay *overlay); 32 | 33 | extern void DirectFB_UnlockYUVOverlay(_THIS, SDL_Overlay *overlay); 34 | 35 | extern int DirectFB_DisplayYUVOverlay(_THIS, SDL_Overlay *overlay, SDL_Rect *src, SDL_Rect *dst); 36 | 37 | extern void DirectFB_FreeYUVOverlay(_THIS, SDL_Overlay *overlay); 38 | 39 | -------------------------------------------------------------------------------- /video/dummy/SDL_nullevents.c: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | /* Being a null driver, there's no event stream. We just define stubs for 25 | most of the API. */ 26 | 27 | #include "SDL.h" 28 | #include "../../events/SDL_sysevents.h" 29 | #include "../../events/SDL_events_c.h" 30 | 31 | #include "SDL_nullvideo.h" 32 | #include "SDL_nullevents_c.h" 33 | 34 | void DUMMY_PumpEvents(_THIS) 35 | { 36 | /* do nothing. */ 37 | } 38 | 39 | void DUMMY_InitOSKeymap(_THIS) 40 | { 41 | /* do nothing. */ 42 | } 43 | 44 | /* end of SDL_nullevents.c ... */ 45 | 46 | -------------------------------------------------------------------------------- /video/dummy/SDL_nullevents_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include "SDL_nullvideo.h" 25 | 26 | /* Variables and functions exported by SDL_sysevents.c to other parts 27 | of the native video subsystem (SDL_sysvideo.c) 28 | */ 29 | extern void DUMMY_InitOSKeymap(_THIS); 30 | extern void DUMMY_PumpEvents(_THIS); 31 | 32 | /* end of SDL_nullevents_c.h ... */ 33 | 34 | -------------------------------------------------------------------------------- /video/dummy/SDL_nullmouse.c: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include "SDL_mouse.h" 25 | #include "../../events/SDL_events_c.h" 26 | 27 | #include "SDL_nullmouse_c.h" 28 | 29 | 30 | /* The implementation dependent data for the window manager cursor */ 31 | struct WMcursor { 32 | int unused; 33 | }; 34 | -------------------------------------------------------------------------------- /video/dummy/SDL_nullmouse_c.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #include "SDL_nullvideo.h" 25 | 26 | /* Functions to be exported */ 27 | -------------------------------------------------------------------------------- /video/dummy/SDL_nullvideo.h: -------------------------------------------------------------------------------- 1 | /* 2 | SDL - Simple DirectMedia Layer 3 | Copyright (C) 1997-2006 Sam Lantinga 4 | 5 | This library is free software; you can redistribute it and/or 6 | modify it under the terms of the GNU Lesser General Public 7 | License as published by the Free Software Foundation; either 8 | version 2.1 of the License, or (at your option) any later version. 9 | 10 | This library is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | Lesser General Public License for more details. 14 | 15 | You should have received a copy of the GNU Lesser General Public 16 | License along with this library; if not, write to the Free Software 17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 18 | 19 | Sam Lantinga 20 | slouken@libsdl.org 21 | */ 22 | #include "SDL_config.h" 23 | 24 | #ifndef _SDL_nullvideo_h 25 | #define _SDL_nullvideo_h 26 | 27 | #include "../SDL_sysvideo.h" 28 | 29 | /* Hidden "this" pointer for the video functions */ 30 | #define _THIS SDL_VideoDevice *this 31 | 32 | 33 | /* Private display data */ 34 | 35 | struct SDL_PrivateVideoData { 36 | int w, h; 37 | void *buffer; 38 | }; 39 | 40 | #endif /* _SDL_nullvideo_h */ 41 | --------------------------------------------------------------------------------