Module prelude

Source

Re-exports§

pub use crate::GraphicsError;
pub use crate::MouseData;
pub use crate::Options;
pub use crate::System;
pub use crate::WindowScaling;
pub use winit_29 as winit;
pub use crate::dialogs::*;
pub use crate::scenes::*;
pub use crate::utilities::virtual_key_codes::*;
pub use crate::window_prefs::*;

Modules§

animated
app_prefs
changing
collection
color
conversion
coord
error
errors
file
font
format
image
jasc_palette
mutation
palette
polyline
pos
prelude
rendering
scaling
wrapper
wrapping

Macros§

coord
Create a Coord Accepts

Structs§

AnimatedIndexedImage
Series of images to play as an animation
AppPrefs
Usage
AudioEngine
The main struct of the crate.
Circle
Clip
Clip has four modes:
Color
This represents an RGBA color
Coord
Represents a 2D point
CustomLetter
Only the letter sizes you’ll use need to be set
Drawable
Represents a shape that is made of points that can be drawn either as a outline or solid
Ellipse
Graphics
IciTileset
Image
Images are a rectangle of pixels that can be manipulated and drawn on screen/saved to disk
IndexedImage
JascPalette
Line
MapExit
MapPosition
MapSize
Polygon
Shape with any number of points/line
Polyline
Preferences
Rect
Rectangle
RenderableAnimatedImage
RenderableIndexedImage
RenderableShapeCollection
RenderableWrappedImage
ShapeCollection
SoundEffect
Sound effect (although it can also be used for music) You must call SoundEffect::update or SoundEffect::update_secs with accurate values and often otherwise playback may stutter or jump
Stats
Text
TextFormat
Characters be drawn be at idx * char_width, idx * char_height
TileDescriptor
Tilemap
TilemapDataDescriptor
TilemapFile
Tileset
collection of named tiles
Timer
Used for single or repeated timed events, uses fractional seconds
Timing
Used to track time in games
Triangle
Window
Represents a window.

Enums§

AnglePosition
DrawType
FilePalette
How palette data is stored in an ICI file
FlatSide
GameUtilError
IndexedImageError
IndexedWrapper
Store static or animated images in a generic way
KeyCode
Code representing the location of a physical key
LineType
MouseButton
Describes a button of a mouse controller.
PaletteError
ParseIssue
PixelFont
PixelFont is used to set the size and positioning in pixels of text
PlayType
Positioning
Scaling
Segment
TextPos
TriangleAngleType
TriangleSideType
WrappingStrategy
Use PixelFont::px_to_cols to convert pixels to columns

Constants§

ASCII_CENT
ASCII_CHECK
ASCII_CURRENCY
ASCII_DEGREE
ASCII_ELLIPSIS
ASCII_EURO
ASCII_POUND
ASCII_YEN
BLACK
BLUE
BROWN
CYAN
DARKER_GRAY
DARK_GRAY
GB_0
Gameboy DMG-01 Background/Lightest
GB_1
GB_2
GB_3
Gameboy DMG-01 Foreground/Darkest
GREEN
LIGHTER_GRAY
LIGHT_GRAY
MAGENTA
MID_GRAY
OFF_BLACK
OFF_WHITE
ORANGE
PURPLE
RED
SUPPORTED_SYMBOLS
TRANSPARENT
WHITE
YELLOW

Traits§

ChangeColors
ColorConversion
Converts to/from RGBA and ARGB
ContainsShape
A shape counts as contained if it is fully inside
CoordIntoTextPos
CreateDrawable
InsertDrawable
InsertShape
InsertShapeBox
IntersectsContains
IntersectsShape
Lerp
NewSoundEffect
NewTextPos
OpaqueColorConversion
Converts to/from RGB
Renderable
Represents anything that Graphics can render
Shape
Tint

Functions§

calc_bounds
chr_to_code
fill
flerp
This method has to be separate and named differently because f32::lerp already exists but is unstable
get_pref_dir
inv_flerp
calculate the percent for point between self and end
measure_text
Return size in pixels for text Run text through wrapping strategy first
run
Create and run a loop using Pixels and Winit
stroke

Type Aliases§

FxHashSet
Type alias for a hash set that uses the Fx hashing algorithm.