Mercurial > sdl-ios-xcode
diff src/video/ps3/SDL_ps3spe_c.h @ 3157:cce01ba54174 gsoc2009_ps3
Added comments, clean up.
author | Martin Lowinski <martin@goldtopf.org> |
---|---|
date | Thu, 27 Aug 2009 11:33:56 +0000 |
parents | 0cf7bff804ad |
children |
line wrap: on
line diff
--- a/src/video/ps3/SDL_ps3spe_c.h Fri Aug 14 15:49:44 2009 +0000 +++ b/src/video/ps3/SDL_ps3spe_c.h Thu Aug 27 11:33:56 2009 +0000 @@ -19,6 +19,31 @@ Sam Lantinga slouken@libsdl.org */ + +/* This SPE API basically provides 3 ways to run and control a program + * on the SPE: + * - Start and stop the program (keepalive=0). + * SPE_Start() will implicitly boot up the program, create a thread and run + * the context. + * SPE_Stop() will join the (terminated) thread (may block) and return. + * - Boot the program and run it (keepalive=0). + * SPE_Boot() will create a context and load the program and finally start + * the context with SPE_Start(). + * SPE_Stop() will savely end the program. + * - Boot, Run and send messages to the program (keepalive=1). + * Start the program by using one of the methods described above. When + * received the READY-message the program is in its infinite loop waiting + * for new messages. + * Every time you run the program, send SPU_START and the address of the + * according struct using SPE_SendMsg(). + * SPE_WaitForMsg() will than wait for SPU_FIN and is blocking. + * SPE_Shutdown() sends SPU_EXIT and finally stops the program. + * + * Therefor the SPE program + * - either runs once and returns + * - or runs in an infinite loop and is controlled by messages. + */ + #include "SDL_config.h" #include "spulibs/spu_common.h"