|
constexpr double | to_radians (double angle_in_degrees) noexcept |
| Converts a degree measurement to its corresponding value in radians. Radians and degrees are two ways of measuring the same thing. There are 360 degrees in a circle and \(2\pi\) radians in a circle. For example, \(90^{\circ}=\frac{\pi}{2}=1.5707964\). More...
|
|
constexpr double | to_degrees (double angle_in_radians) noexcept |
| Converts a radian measurement to its corresponding value in degrees. Radians and degrees are two ways of measuring the same thing. There are 360 degrees in a circle and \(2\pi\) radians in a circle. For example, \(90^{\circ}=\frac{\pi}{2}=1.5707964\). More...
|
|
void | clear_background () noexcept |
| Clear the background to black. More...
|
|
void | clear_background (HexColor color) noexcept |
| Clear the background to the specified HexColor. More...
|
|
void | clear_background (Color color) noexcept |
| Clear the background to the specified Color. More...
|
|
void | clear_background (double grey, double alpha=255) noexcept |
| Clear the background to a grey color. More...
|
|
void | clear_background (double red, double green, double blue, double alpha=255) noexcept |
| Clear the background to a specified RGBA color. More...
|
|
void | set_fill_color (HexColor color) noexcept |
| Sets the color used to fill shapes to the specified HexColor. More...
|
|
void | set_fill_color (Color color) noexcept |
| Sets the color used to fill shapes to the specified Color. More...
|
|
void | set_fill_color (double grey, double alpha=255) noexcept |
| Sets the color used to fill shapes to a grey. More...
|
|
void | set_fill_color (double red, double green, double blue, double alpha=255) noexcept |
| Sets the color used to fill shapes to the specified RGBA values. More...
|
|
void | no_fill () noexcept |
| Disables filling geometry. More...
|
|
void | set_outline_color (HexColor color) noexcept |
| Set the outline and lines of shapes to the specified HexColor. More...
|
|
void | set_outline_color (Color color) noexcept |
| Set the outline and lines of shapes to the specified Color. More...
|
|
void | set_outline_color (double grey, double alpha=255) noexcept |
| Set the outline and lines of shapes to a grey color. More...
|
|
void | set_outline_color (double red, double green, double blue, double alpha=255) noexcept |
| Set the outline and lines of shapes to an RGBA color. More...
|
|
void | no_outline () |
| Disables drawing the outline. More...
|
|
void | draw_ellipse (double x, double y, double width, double height=0) noexcept |
| Draws an ellipse (oval) to the screen. More...
|
|
void | draw_line (double x1, double y1, double x2, double y2) noexcept |
| Draws a line (a direct path between two points) to the screen. More...
|
|
void | draw_quad (double x1, double y1, double x2, double y2, double x3, double y3, double x4, double y4) noexcept |
| Draw a quad. More...
|
|
void | draw_rectangle (double x, double y, double width, double height=0) noexcept |
| Draws a rectangle to the screen. More...
|
|
void | draw_triangle (double x1, double y1, double x2, double y2, double x3, double y3) noexcept |
| Draw a triangle to the screen. More...
|
|
void | set_ellipse_mode (EllipseMode mode) noexcept |
| Modifies the location from which ellipses are drawn by changing the way in which parameters given to draw_ellipse() are interpreted. More...
|
|
void | set_rectangle_mode (RectMode mode) noexcept |
| Modifies the location from which rectangles are drawn by changing the way in which parameters given to draw_rectangle() are interpreted. More...
|
|
void | set_frame_of_reference (FrameOfReference frame_of_reference) noexcept |
| Change the coordinate system you would like to use when describing your primitives. More...
|
|
void | smooth_drawing () noexcept |
| Draws all geometry with smooth (anti-aliased) edges. More...
|
|
void | no_smoothing () noexcept |
| Draws all geometry with jagged (aliased) edges. More...
|
|
void | set_outline_width (double line_width) noexcept |
| Sets the width of the outline used for lines and the border around shapes. All widths are set in units of pixels. More...
|
|
void | push_settings () noexcept |
| The push_settings() function saves the current drawing style settings and transformations, while pop_settings() restores these settings. More...
|
|
void | pop_settings () noexcept |
| The pop_settings() function restores to the previous style settings and transformations, while push_settings() saves a new set these settings. More...
|
|
void | draw_text (const std::wstring &str, double x, double y) noexcept |
| Draws wide character based text to the screen. More...
|
|
void | draw_text (const std::string &str, double x, double y) noexcept |
| Draws text to the screen. More...
|
|
int | create_distance_field_bitmap_font (const std::filesystem::path &fnt_filepath) noexcept |
| Given a file path to a *.fnt file it will create a distance field bitmap font. More...
|
|
void | set_font (int font_id) noexcept |
| Changes the font type to be used when drawing text. More...
|
|
void | set_font_size (double font_size) noexcept |
| Sets the current font size. This size will be used in all subsequent calls to the draw_text() function. More...
|
|
void | set_font_fade_out_interval (double inside_distance, double outside_distance) noexcept |
| Defines the distance interval to draw font characters and how to fade them out from opaque to translucent. More...
|
|
void | set_font_backdrop_fade_out_interval (double inside_distance, double outside_distance) noexcept |
| Defines the distance interval to draw the backdrop of font characters and how to fade them out from opaque to translucent. More...
|
|
void | set_font_backdrop_offset (double texel_x, double texel_y) noexcept |
| Repositions the backdrop of the font characters. Useful for creating a custom drop shadow effect. More...
|
|
Image | capture_screenshot_to_image () |
| Captures a screenshot of the whole screen. More...
|
|
Image | capture_screenshot_to_image (int left_x, int bottom_y, int pixels_width, int pixels_height) noexcept |
| Captures a screenshot of a subsection of the screen. More...
|
|
void | draw_image (const Image &image, double x, double y) noexcept |
| Draw an entire image to the screen. More...
|
|
void | draw_image (const Image &image, double x, double y, double width, double height) noexcept |
| Draw an entire image to the screen and resize it to a custom size. More...
|
|
void | draw_image (const Image &image, double x, double y, double width, double height, int texel_x, int texel_y) noexcept |
| Draw a subsection of the image to the screen. More...
|
|
void | draw_image (const Image &image, double x, double y, double width, double height, int texel_x, int texel_y, int texel_width, int texel_height) noexcept |
| Draw a subsection of the image to the screen. More...
|
|
void | set_tint_color (HexColor color) noexcept |
| Sets the fill value for displaying images to the specified HexColor. More...
|
|
void | set_tint_color (Color color) noexcept |
| Sets the fill value for displaying textures to the specified Color. More...
|
|
void | set_tint_color (double grey, double alpha=255) noexcept |
| Sets the fill value for displaying textures to the specified grey color. More...
|
|
void | set_tint_color (double red, double green, double blue, double alpha=255) noexcept |
| Sets the fill value for displaying textures to the specified RGBA color. More...
|
|
void | no_tint () noexcept |
| Removes the current fill value for displaying images and reverts to displaying textures with their original colors. More...
|
|
void | set_image_mode (RectMode mode) noexcept |
| Modifies the location from which textures are drawn by changing the way in which parameters given to draw_image() are interpreted. More...
|
|
void | apply_scale (double scale) noexcept |
| Uniformly increases or decreases the size of a shape by expanding and contracting vertices. More...
|
|
void | apply_scale (double scale_x, double scale_y) noexcept |
| Increases or decreases the size of a shape by expanding and contracting vertices. More...
|
|
void | apply_rotate (double angle_in_radians) noexcept |
| Rotates a shape the amount specified by the angle in radians. More...
|
|
void | apply_translate (double translate_x, double translate_y) noexcept |
| Specifies an amount to displace objects within the display window. More...
|
|
void | apply_matrix (double a, double b, double c, double d, double e, double f) noexcept |
| Multiplies the current matrix by the one specified through the parameters. More...
|
|
void | begin_drawing_to_image (int image_width, int image_height, bool apply_antialiasing=true) |
| Redirect all draw command to draw to an image. More...
|
|
Image | end_drawing_to_image (bool smooth_texture=false) |
| End a session of drawing to an image. More...
|
|
std::string | to_string (MouseButtons button) noexcept |
| Convert MouseButtons enum to std::string. More...
|
|
std::string | to_string (KeyboardButtons button) noexcept |
| Convert KeboardButtons enum to std::string. More...
|
|
std::wstring | to_wstring (MouseButtons button) noexcept |
| Convert MouseButtons enum to std::wstring. More...
|
|
std::wstring | to_wstring (KeyboardButtons button) noexcept |
| Convert KeboardButtons enum to std::wstring. More...
|
|
int | get_mouse_x () noexcept |
| Get the mouse's X position relative to the currently set doodle::FrameOfReference. More...
|
|
int | get_mouse_y () noexcept |
| Get the mouse's Y position relative to the currently set doodle::FrameOfReference. More...
|
|
int | get_previous_mouse_x () noexcept |
| Get the previous mouse's X position relative to the currently set doodle::FrameOfReference. More...
|
|
int | get_previous_mouse_y () noexcept |
| Get the previous mouse's Y position relative to the currently set doodle::FrameOfReference. More...
|
|
void | set_callback_key_pressed (std::function< void(KeyboardButtons)> &&callback) noexcept |
| The provided callback function is called once every time a key is pressed. More...
|
|
void | set_callback_key_released (std::function< void(KeyboardButtons)> &&callback) noexcept |
| The provided callback function is called once every time a key is released. More...
|
|
void | set_callback_mouse_moved (std::function< void(int, int)> &&callback) noexcept |
| The provided callback function is called every time the mouse moves. More...
|
|
void | set_callback_mouse_pressed (std::function< void(MouseButtons)> &&callback) noexcept |
| The provided callback is called whenever a mouse button is pressed. More...
|
|
void | set_callback_mouse_released (std::function< void(MouseButtons)> &&callback) noexcept |
| The provided callback is called whenever a mouse button is released. More...
|
|
void | set_callback_mouse_wheel (std::function< void(int)> &&callback) noexcept |
| The provided callback is called whenever the mouse wheel is scrolled. More...
|
|
double | noise (double x, double y=0.0, double z=0.0) noexcept |
| Returns the Perlin noise value at specified coordinates. More...
|
|
void | seed_noise (unsigned long long new_seed) noexcept |
| Sets the seed value for noise(). More...
|
|
void | set_noise_detail (int perlin_octaves, double amplitude_falloff) noexcept |
| Adjusts the character and level of detail produced by the Perlin noise function. More...
|
|
void | seed_random (unsigned int seed) noexcept |
| Sets the seed value for random(). More...
|
|
double | random (double min_inclusive, double max_exclusive) noexcept |
| Return a random floating-point number within the range [min,max) More...
|
|
double | random (double max_exclusive) noexcept |
| Return a random floating-point number within the range [0,max) More...
|
|
double | random () noexcept |
| Return a random floating-point number within the range [0,1) More...
|
|
int | random (int min_inclusive, int max_exclusive) noexcept |
| Return a random integer number within the range [min,max) More...
|
|
int | random (int max_exclusive) noexcept |
| Return a random integer number within the range [0,max) More...
|
|
bool | create_window () noexcept |
| Create a default window. More...
|
|
bool | create_window (const std::string &title) noexcept |
| Create a default window with a custom window title. More...
|
|
bool | create_window (int desired_width, int desired_height) noexcept |
| Create a window with a desired screen size. More...
|
|
bool | create_window (const std::string &title, int desired_width, int desired_height) noexcept |
| Create a window with a custom window title and a desired screen size. More...
|
|
bool | create_window (const std::string &title, int desired_width, int desired_height, int screen_x, int screen_y) noexcept |
| Create a window with a custom window title and a desired screen size. More...
|
|
bool | is_window_closed () noexcept |
| Is the window closed? More...
|
|
void | update_window () noexcept |
| Update the doodle application. More...
|
|
void | close_window () noexcept |
| Programmatically close the window. More...
|
|
void | set_window_title (const std::string &new_title) noexcept |
| Set a new title for the window. More...
|
|
bool | is_full_screen () noexcept |
| Is the window a fullscreen window? More...
|
|
void | toggle_full_screen () noexcept |
| Switch back and forth between fullscreen and windowed mode. More...
|
|
void | set_callback_window_resized (std::function< void(int, int)> &&callback) noexcept |
| The provided callback function is called whenever the window is resized by the user. More...
|
|
void | set_callback_window_closed (std::function< void(void)> &&callback) noexcept |
| The provided callback function will be called when the user uses the OS to close the window. More...
|
|
void | set_callback_window_focus_changed (std::function< void(bool)> &&callback) noexcept |
| THe provided callback function will be called when the window gains or loses focus. More...
|
|
void | show_cursor (bool show_it=true) noexcept |
| This function will allow you to hide or show the mouse cursor. More...
|
|