Skip to content

Commit

Permalink
Documentation updates
Browse files Browse the repository at this point in the history
  • Loading branch information
carstene1ns committed Oct 24, 2023
1 parent 1d1b572 commit bc63e87
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 5 deletions.
4 changes: 2 additions & 2 deletions res/unix/OpenJazz.6.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ Alireza Nejati:: Menu plasma effect
newspaz:: Bug fixes, enemy improvements
Carsten Teibes (carstene1ns)::
Maintenance, bug fixes, documentation +
Integrating the ports (Wii, 3DS, PSP, PSVita, ...) +
Integrating the ports (Wii, 3DS, PSP, PSVita, SDL2, ...) +
Additional coding (logger, CLI, ...) +
Modernizing +
UI improvements
Expand All @@ -144,4 +144,4 @@ pocketinsanity:: PocketPC port
Ricerind:: Mac OS X port
Slaanesh:: GP32 port
GPF:: Dreamcast port
Cameron Cawley (ccawley2011):: RISC OS port
Cameron Cawley (ccawley2011):: RISC OS, SDL2 port
33 changes: 30 additions & 3 deletions src/io/gfx/video.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,11 @@ bool Video::init (SetupOptions cfg) {

}


void Video::commonDeinit() {
/**
* Shared Deinitialisation code for reset() and deinit()
*
*/
void Video::commonDeinit () {
// canvas is used when scaling or built with SDL2
if (canvas != screen && canvas) {
SDL_FreeSurface(canvas);
Expand All @@ -241,7 +244,10 @@ void Video::commonDeinit() {
#endif
}


/**
* Deinitialise video output.
*
*/
void Video::deinit () {

commonDeinit();
Expand Down Expand Up @@ -729,6 +735,12 @@ void drawRect (int x, int y, int width, int height, int index) {

}

/**
* Sets the Color key of provided surface.
*
* @param surface Surface to change
* @param index Color index
*/
void enableColorKey (SDL_Surface* surface, unsigned int index) {

#if OJ_SDL2
Expand All @@ -739,6 +751,13 @@ void enableColorKey (SDL_Surface* surface, unsigned int index) {

}

/**
* Returns the Color key of provided surface.
*
* @param surface Surface to query
*
* @return color index
*/
unsigned int getColorKey (SDL_Surface* surface) {

#if OJ_SDL2
Expand All @@ -756,6 +775,14 @@ unsigned int getColorKey (SDL_Surface* surface) {

}

/**
* Sets the palette colors of provided surface.
*
* @param surface Surface to change
* @param palette Palette to copy colors from
* @param start index of first color copy
* @param length number of colors to copy
*/
void setLogicalPalette (SDL_Surface* surface, SDL_Color *palette, int start, int length) {

#if OJ_SDL2
Expand Down

0 comments on commit bc63e87

Please sign in to comment.