-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add transparent index and optimize font rendering with shadows.
- Loading branch information
Showing
27 changed files
with
223 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/*! \file | ||
* \brief Transparent VGA pixel values | ||
* \details Describes the transparancy index value for various engine components. | ||
* \copyright MIT license. | ||
* \date 2024 | ||
* \author Andrew Thompson | ||
* \author Tuomas Virtanen | ||
*/ | ||
|
||
#ifndef TRANSPARENT_H | ||
#define TRANSPARENT_H | ||
|
||
// Default's. | ||
// Please do not use the default definitions in the code directly. Define a new value below instead. | ||
// This way all different transparency values are stored in one place. | ||
#define DEFAULT_TRANSPARENT_INDEX 0 | ||
#define DEFAULT_NOT_TRANSPARENT -1 | ||
|
||
// All sprites have holes, these holes need to be transparent. | ||
#define SPRITE_TRANSPARENT_INDEX DEFAULT_TRANSPARENT_INDEX | ||
|
||
// Backgrounds have no transparent pixels and need all pixels to be rendered. | ||
#define BACKGROUND_TRANSPARENT_INDEX DEFAULT_NOT_TRANSPARENT | ||
|
||
// Force an opaque menu for now. | ||
#define MENU_TRANSPARENT_INDEX DEFAULT_NOT_TRANSPARENT | ||
|
||
// Portraits have a transparancy index that needs to offset past other items in the global palette. | ||
// TODO: Should really become default. | ||
#define PORTRAIT_TRANSPARENT_INDEX 0xD0 | ||
|
||
// Portrait highlights need a special offset for transparency to not conflict with other entries in the global palette. | ||
// TODO: Should really become default. | ||
#define HIGHLIGHT_TRANSPARENT_INDEX 90 | ||
|
||
// Fonts need a transparent index that does not conflict with the lower 8 colors on the N64 otherwise there will be a | ||
// combinatorial explosion. | ||
#define FONT_TRANSPARENT_INDEX DEFAULT_TRANSPARENT_INDEX | ||
#define PCX_FONT_TRANSPARENT_INDEX DEFAULT_TRANSPARENT_INDEX | ||
|
||
// Gauges in the player select have an opaque background and are not transparent. | ||
#define GAUGE_TRANSPARENT_INDEX DEFAULT_NOT_TRANSPARENT | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.