Euphoria
eu::core Namespace Reference

Namespaces

 argparse
 
 base64
 
 colorbrewer
 
 detail
 
 dot
 
 dump2d
 
 dump3d
 
 easing
 
 ecs
 
 generator
 
 markov
 
 meshes
 
 palettes
 
 raytracer
 
 textparser
 
 tracery
 

Classes

struct  Bitfield
 
struct  BufferPoint2
 
struct  BufferBuilder2
 
struct  Cache
 
struct  EditorCamera3
 
struct  CompiledCamera3
 
struct  Camera3
 
struct  CanvasLogic
 
struct  CliProgressDots
 Prints dots on the commandline for long running processes. More...
 
struct  ClosestPointCollector
 
struct  CollisionFace
 
struct  CollisionMesh
 
struct  VirtualConsole
 Provides a terminal like experience. More...
 
struct  TreeStyle
 
struct  TimetWrapper
 
struct  StructTmWrapper
 
struct  DateTime
 
struct  Decompressor
 
struct  EnumType
 Represents a dynamically loaded "enum type". More...
 
struct  EnumValue
 
struct  FpsController
 
struct  Guid
 
struct  HashedStringView
 
struct  HelpTextHover
 Determines when to display help text in a hover ui. More...
 
struct  Image
 
struct  ImageLoadResult
 
struct  Canvas
 hacky layer between something that looks like the html 'canvas rendering context 2d' and the euphoria image drawing operations https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D More...
 
struct  ImageMapAction
 
struct  Ray2Ray2Result
 
struct  Ray3AabbResult
 
struct  StepIterator
 
struct  StepIteratorCreator
 
struct  LastN
 
struct  LinePoint
 
struct  Lines
 
struct  FontData
 
struct  LoadedGlyph
 
struct  LoadedFont
 
struct  MeshPoint
 
struct  MeshFace
 
struct  MeshPart
 
struct  MaterialTexture
 
struct  Material
 
struct  Mesh
 
struct  LoadedMeshOrError
 
struct  Sortable
 
struct  SortAction
 
struct  SortBuilder
 
struct  OrbitController
 
struct  Palette
 
struct  StaticPalette
 
struct  DynamicPalette
 
struct  PoissonWorker
 
struct  BezierSegment2
 Anchor and control points. More...
 
struct  PolyBezier2
 Composite Bézier curve or polybezier. More...
 
struct  Polyline2
 Straight lines only. More...
 
struct  Value
 
struct  IntValue
 
struct  FloatValue
 
struct  Vec3fValue
 
struct  MapValue
 
struct  BucketBase10
 
struct  BucketBase16
 
struct  RandomLcg
 
struct  RandomXorShift
 
struct  Sensitivity
 
struct  Shufflebag
 
struct  Sphere
 
struct  SphereAndPosition
 
struct  SubVec
 
struct  Table
 
struct  WallCounter
 
struct  BorderSettings
 
struct  TableGenerator
 
struct  CsvParserOptions
 
struct  TextBoxStyle
 
struct  TextBox
 
struct  TextfileParser
 Parses a text file in memory. More...
 
struct  TemplateNode
 
struct  TemplateNodeString
 
struct  TemplateNodeList
 
struct  TemplateNodeScopedList
 
struct  TemplateNodeIfdef
 
struct  TemplateNodeEval
 
struct  TemplateNodeSet
 
struct  Token
 
struct  TokenReader
 
struct  Defines
 
struct  TemplateErrorList
 
struct  CompiledTextTemplate
 
struct  Tweenable
 
struct  UiText
 Represents displayed text. More...
 
struct  ReadRootImageGenerator
 
struct  Viewport
 
struct  ViewportDefinition
 

Typedefs

using KerningMap = std::map< std::pair< int, int >, float >
 
template<typename T >
using SortableList = std::vector< std::shared_ptr< Sortable< T > >>
 
using TextLine = std::vector< std::string >
 
using TextSentence = std::vector< std::string >
 
using OnSentenceFunction = std::function< void(const TextSentence &)>
 
using RandomLnuthLcg = RandomLcg< U64, std::numeric_limits< U64 >::max(), 6364136223846793005, 1442695040888963407 >
 
using RandomXorShift32 = RandomXorShift< U32, 13, 17, 5 >
 
using RandomXorShift64 = RandomXorShift< U64, 13, 17, 7 >
 
using BoolTable = Table< bool >
 
using StringTable = Table< std::string >
 
using TimePoint = std::chrono::time_point< std::chrono::steady_clock >
 

Enumerations

enum class  EditorCameraStyle3 { orbital , fps }
 
enum class  ActionWhenMissingInAlphabet { ignore , pass_through , replace }
 
enum class  Month {
  january , february , march , april ,
  may , june , july , august ,
  september , october , november , december
}
 
enum class  DstInfo { in_effect , not_in_effect , info_unavailable }
 
enum class  TimeZone { gmt , local }
 
enum class  ImageWriteFormat { png , bmp , tga , jpeg }
 
enum class  AlphaLoad { remove , keep }
 
enum class  PixelsOutside { assert , discard }
 
enum class  Grayscale {
  r , g , b , a ,
  max , gamma , linear , average
}
 
enum class  MouseButton {
  invalid , unbound , left , middle ,
  right , x1 , x2
}
 
enum class  Key {
  invalid , unbound , return_key , escape ,
  backspace , tab , space , exclaim ,
  quotedbl , hash , percent , dollar ,
  ampersand , quote , left_paren , right_paren ,
  asterix , plus , comma , minus ,
  period , slash , num_0 , num_1 ,
  num_2 , num_3 , num_4 , num_5 ,
  num_6 , num_7 , num_8 , num_9 ,
  colon , semicolon , less , equals ,
  greater , question , at , left_bracket ,
  backslash , right_bracket , caret , underscore ,
  backquote , a , b , c ,
  d , e , f , g ,
  h , i , j , k ,
  l , m , n , o ,
  p , q , r , s ,
  t , u , v , w ,
  x , y , z , capslock ,
  f1 , f2 , f3 , f4 ,
  f5 , f6 , f7 , f8 ,
  f9 , f10 , f11 , f12 ,
  print_screen , scroll_lock , pause , insert ,
  home , page_up , delete_key , end ,
  page_down , right , left , down ,
  up , numlock_clear , keypad_divide , keypad_multiply ,
  keypad_minus , keypad_plus , keypad_enter , keypad_1 ,
  keypad_2 , keypad_3 , keypad_4 , keypad_5 ,
  keypad_6 , keypad_7 , keypad_8 , keypad_9 ,
  keypad_0 , keypad_period , application , power ,
  keypad_equals , f13 , f14 , f15 ,
  f16 , f17 , f18 , f19 ,
  f20 , f21 , f22 , f23 ,
  f24 , execute , help , menu ,
  select , stop , again , undo ,
  cut , copy , paste , find ,
  mute , volume_up , volume_down , keypad_comma ,
  keypad_equals_as_400 , alt_erase , sysreq , cancel ,
  clear , prior , second_return , separator ,
  out , oper , clear_again , crsel ,
  exsel , keypad_00 , keypad_000 , thousandseparator ,
  decimalseparator , currency_unit , currency_subunit , keypad_leftparen ,
  keypad_rightparen , keypad_leftbrace , keypad_rightbrace , keypad_tab ,
  keypad_backspace , keypad_a , keypad_b , keypad_c ,
  keypad_d , keypad_e , keypad_f , keypad_xor ,
  keypad_power , keypad_percent , keypad_less , keypad_greater ,
  keypad_ampersand , keypad_double_ampersand , keypad_vertical_bar , keypad_double_verticle_bar ,
  keypad_colon , keypad_hash , keypad_space , keypad_at ,
  keypad_exclam , keypad_mem_store , keypad_mem_recall , keypad_mem_clear ,
  keypad_mem_add , keypad_mem_subtract , keypad_mem_multiply , keypad_mem_divide ,
  keypad_plus_minus , keypad_clear , keypad_clear_entry , keypad_binary ,
  keypad_octal , keypad_decimal , keypad_hexadecimal , ctrl_left ,
  shift_left , alt_left , gui_left , ctrl_right ,
  shift_right , alt_right , gui_right , mode ,
  audio_next , audio_prev , audio_stop , audio_play ,
  audio_mute , media_select , www , mail ,
  calculator , computer , ac_search , ac_home ,
  ac_back , ac_forward , ac_stop , ac_refresh ,
  ac_bookmarks , brightness_down , brightness_up , displayswitch ,
  keyboard_illum_toggle , keyboard_illum_down , keyboard_illum_up , eject ,
  sleep
}
 
enum class  WrapMode { repeat , clamp_to_edge , mirror_repeat }
 
enum class  MouseBehaviour { normal , wrap_within_window , relative_only }
 
enum class  SortStyle { ascending , descending }
 
enum class  ValueType { int_type , float_type , vec3f_type , map_type }
 
enum class  BlendMode {
  normal , lighten , darken , multiply ,
  average , add , subtract , difference ,
  negation , screen , exclusion , overlay ,
  soft_light , hard_light , color_dodge , color_burn ,
  linear_dodge , linear_burn , linear_light , vivid_light ,
  pin_light , hard_mix , reflect , glow ,
  phoenix
}
 
enum class  BorderSetupRule { always_wall , always_empty , random }
 
enum class  OutsideRule { wall , empty , mirror , wrap }
 
enum class  NeighborhoodAlgorithm { manhattan , plus , box }
 
enum class  CsvTrim { trim , dont_trim }
 
enum class  TokenType {
  text , if_def , eval , ident ,
  end , set , string , include ,
  end_of_file
}
 

Functions

std::vector< size2icollect_sizes (const std::vector< Image > &images, int padding)
 
Image draw_image (const std::vector< vec2i > &positions, const std::vector< Image > &images, const size2i &size, const Rgbi &background_color)
 
size2i pack_tight (const size2i &default_size, std::vector< vec2i > *positions, const std::vector< Image > &images, int padding)
 
std::vector< vec2ipack_image (const size2i &image_size, const std::vector< Image > &images, const std::vector< std::string > &files, int padding)
 
std::optional< Imagepack_image (const std::vector< Image > &images, const std::vector< std::string > &files, const size2i &requested_size, int padding, Rgbi background_color, bool should_pack_image)
 
std::pair< std::vector< vec2i >, size2ilay_out_in_a_grid (const std::vector< Image > &images, int padding, bool top_to_bottom)
 
Image lay_out_in_a_grid (const std::vector< Image > &images, int padding, Rgbi background_color, bool top_to_bottom)
 
std::optional< float > get_intersection (const UnitRay3f &ray, const CollisionMesh &mesh)
 
std::vector< std::string > parse_commandline (const std::string &str)
 
std::string_view get_cp437 (int c)
 
std::string_view get_random_cp437_in_utf8 (Random *random)
 
unsigned long calc_crc32 (const MemoryChunk &chunk)
 
TreeStyle determine_style ()
 
template<typename T , typename TLabelFunc , typename TFindChildrenFunc , typename TPrintFunc >
void print_hierarchy (T item, TLabelFunc label_func, TFindChildrenFunc find_children_func, TPrintFunc print_func, const TreeStyle &style=determine_style(), const std::string &a_indent="", int index=0, bool last=true)
 
std::string get_ceasar_cypher (const std::string &input, int steps, const std::string &alphabet, bool case_sensitive, ActionWhenMissingInAlphabet missing_in_alphabet, char invalid)
 
std::string get_rot13 (const std::string &input)
 
int c_month_to_int (Month month)
 
Month c_int_to_month (int m)
 
U64 c_date_time_to_int64 (const TimetWrapper &dt)
 
TimetWrapper c_int64_to_date_time (U64 total_seconds)
 
TimetWrapper to_time_t_wrapper (const StructTmWrapper &s, TimeZone timezone)
 
TimetWrapper c_int64_to_date_time (uint64_t i)
 
template<typename T , int total_bytes>
std::vector< U8to_bytes_generic (T hash)
 
std::vector< U8to_bytes (U32 hash)
 
std::vector< U8to_bytes (U64 hash)
 
std::vector< int > to_codes (U8 byte, bool msb_first)
 
std::vector< int > to_codes (const std::vector< U8 > &bytes, bool msb_first)
 
Table< int > get_drunken_bishop_result (U32 hash, int width, int height, bool msb_first, int startx, int starty)
 
Table< int > get_drunken_bishop_result (U64 hash, int width, int height, bool msb_first, int startx, int starty)
 
Table< int > get_drunken_bishop_result (const std::vector< int > &codes, int width, int height, int startx, int starty)
 
std::vector< std::string > get_ssh_characters ()
 
std::vector< std::string > render_table (const Table< int > &table, const std::vector< std::string > &characters)
 
std::string to_string (const EnumValue &v)
 
void load_enum_type (EnumType *type, io::FileSystem *fs, const io::FilePath &path)
 
bool find (const std::string &target, const std::string &search)
 
bool find (const std::string &target, const std::vector< std::string > &searches)
 
bool find (const std::vector< std::string > &targets, const std::string &search)
 
bool find (const std::vector< std::string > &targets, const std::vector< std::string > &searches)
 
constexpr U64 hash64 (const std::string_view str, U64 hash=0xcbf29ce484222325)
 
void render_retro (Image *image, U32 code)
 
void render_identicon (Image *image, U32 code)
 
void render_sprator (Image *image, U32 code, const Rgbai &foreground_color={NamedColor::white}, std::optional< Rgbai > border_color_arg=std::nullopt, const Rgbai &background_color={NamedColor::black, 0})
 
void render_sprator (std::vector< Image > *images, U32 code, const Rgbai &foreground_color={NamedColor::white}, std::optional< Rgbai > border_color_arg=std::nullopt, const Rgbai &background_color={NamedColor::black, 0})
 
int write_image_data (stbi_write_func *func, void *context, int w, int h, int comp, const void *data, ImageWriteFormat format, int jpeg_quality)
 
ImageLoadResult load_image (io::FileSystem *fs, const io::FilePath &path, AlphaLoad alpha)
 
ImageLoadResult load_image (std::shared_ptr< MemoryChunk > file_memory, const std::string &path, AlphaLoad alpha)
 
ImageLoadResult load_image (void *compressed_data, int compressed_size, const std::string &path, AlphaLoad alpha)
 
Recti on_whole_image (const Image &image)
 
void clear (Image *image, const Rgbai &color)
 
void draw_rect (Image *image, const Rgbai &color, const Recti &rect)
 
void draw_square (Image *image, const Rgbai &color, int x, int y, int size)
 
void fill_poly (Image *image, const Rgbai &color, const std::vector< vec2f > &poly)
 
void draw_circle (Image *image, const Rgb &color, const vec2i &center, float radius, float softness, float inner)
 
void draw_line_fast (Image *image, const Rgbai &color, const vec2i &from, const vec2i &to)
 
void draw_line_antialiased (Image *image, const Rgb &color, const vec2i &from, const vec2i &to)
 
void draw_line_antialiased (Image *image, const Rgb &color, const vec2f &from, const vec2f &to)
 
Rgba tint_color (const Rgba &c, const Rgb &tint)
 
Rgbai tint_color (const Rgbai &c, const Rgbai &tint)
 
void blend_image (Image *dst, const vec2i &p, const Image &src, const Rgbai &tint)
 
void draw_text (Image *image, const vec2i &start_pos, const std::string &text, const Rgbai &color, const LoadedFont &font)
 
void paste_image (Image *dest_image, const vec2i &position, const Image &source_image, BlendMode blend_mode, PixelsOutside clip)
 
void fill_triangle (Image *image, const vec2f &a, const vec2f &b, const vec2f &c, const Rgbai &color)
 
void draw_arrow (Image *image, const vec2f &from, const vec2f &to, const Rgbai &color, float size)
 
Table< char > from_image_to_string_table (const Image &img, const std::vector< ImageMapAction > &map)
 
Table< char > from_image_to_string_table_exact (const Image &img, const std::vector< ImageMapAction > &map, char missing)
 
Table< char > from_image_to_string_table (const Image &img, bool shorter, Grayscale grayscale)
 
std::vector< std::string > to_strings (const Table< char > &table)
 
Rgbai make_grayscale (Rgbai c, Grayscale grayscale)
 
void make_grayscale (Image *image, Grayscale grayscale)
 
void match_palette (Image *image, const Palette &palette)
 
template<typename C >
Image create_new_image_from (const Image &image_source, C callback)
 
void match_palette_dither (Image *image, const Palette &palette)
 
vec3f c_vec3 (const Rgb f)
 
vec3f c_vec3 (const Rgbi c)
 
vec3f c_vec3 (const Rgbai c)
 
void filter_edge_detection (Image *image, float r)
 
void filter_color_detection (Image *image, Rgb color, float r)
 
template<typename C >
void run_lut_transform (Image *image, C c)
 
void change_brightness (Image *image, int change)
 
void change_contrast (Image *image, const Angle &contrast)
 
template<typename T , typename TSortFunc >
void do_inplace_insertion_sort (std::vector< T > *pointer_to_array, TSortFunc sort_func)
 
template<typename T , typename TSortFunc >
std::vector< T > get_insertion_sorted (const std::vector< T > &array, TSortFunc sort_func)
 
template<typename T >
int default_compare_for_insertion_sort (const T &lhs, const T &rhs)
 
template<typename T >
std::vector< T > get_insertion_sorted (const std::vector< T > &array)
 
Ray3AabbResult get_intersection (const UnitRay3f &r, const Aabb &aabb)
 
float get_intersection (const UnitRay3f &r, const Plane &p)
 
Ray2Ray2Result get_intersection (const Ray2f &lhs, const Ray2f &rhs)
 
float get_distance_between (const Plane &plane, const vec3f &p)
 
vec3f get_closest_point (const Plane &plane, const vec3f &point)
 
float get_distance_between (const UnitRay3f &ray, const vec3f &point)
 
vec3f get_closest_point (const UnitRay3f &ray, const vec3f &c)
 
bool get_intersection (const Sphere &lhs, const vec3f &lhs_center, const Sphere &rhs, const vec3f &rhs_center)
 
bool contains_point (const Sphere &sphere, const vec3f &sphere_center, const vec3f &point)
 
vec3f get_closest_point (const Sphere &sphere, const vec3f &sphere_center, const vec3f &point)
 
float get_intersection (const UnitRay3f &ray, const Sphere &sphere, const vec3f &sphere_center)
 
bool contains_point (const Aabb &aabb, const vec3f &point)
 
vec3f get_closest_point (const Aabb &aabb, const vec3f &point)
 
bool is_point_in_triangle (const vec2f &a, const vec2f &b, const vec2f &c, const vec2f &p)
 
std::optional< float > get_intersection_ray_triangle (const UnitRay3f &ray, const vec3f &v0, const vec3f &v1, const vec3f &v2)
 This implements the Möller–Trumbore intersection algorithm. More...
 
template<typename T >
StepIteratorCreator< T > iterate (const T from, T to, T step=1)
 
std::string to_string (Key k)
 
Key to_key (const std::string &name)
 
std::string to_string (MouseButton button)
 
MouseButton to_mouse_button (const std::string &button)
 
template<typename T >
void shuffle (std::vector< T > *v, Random *r)
 
template<typename TGlyphs >
LoadedFont get_character_from_builtin8 (const int start_codepoint, int end_codepoint, TGlyphs glyphs)
 
LoadedFont load_characters_from_builtin13 ()
 
LoadedFont load_characters_from_builtin8 ()
 
LoadedFont get_characters_from_font (io::FileSystem *file_system, const io::FilePath &font_file, int font_size, const std::string &chars)
 
LoadedFont get_characters_from_font (std::shared_ptr< MemoryChunk > file_memory, int font_size, const std::string &chars)
 
LoadedFont get_characters_from_single_image (io::FileSystem *fs, const io::FilePath &image_file, const std::string &image_alias, float image_scale, float image_bearing_x, float image_bearing_y, float image_advance)
 
LoadedFont get_characters_from_single_image (const Image &image, const std::string &image_alias, float image_scale, float image_bearing_x, float image_bearing_y, float image_advance)
 
template<typename T >
int sort_using_less (T lhs, T rhs)
 
template<typename T , typename TSelf >
std::vector< size_t > get_sorted_indices (const std::vector< T > &data, const SortBuilder< T, TSelf > &builder)
 
std::optional< TextLineparse_line (const std::string &line)
 
std::string from_line_to_string (const TextLine &s)
 
bool parse_sentences (std::istream &data, OnSentenceFunction on_sentence)
 
std::string from_sentence_to_string (const TextSentence &s)
 
std::vector< std::optional< Recti > > pack (const size2i &container, const std::vector< size2i > &to_pack)
 
template<typename... T>
constexpr StaticPalette< sizeof...(T)> make_static_palette (const std::string_view &name, T... colors)
 
std::vector< Rgbiextract_palette_median_cut (const Image &image, int depth, bool middle_split)
 
bool is_all_inside (const Rectf &a, const vec2f &p, float r)
 
std::vector< vec2fcalc_poisson_samples (const Rectf &area, Random *random, float r, float bs, int k)
 
template<typename T , typename TSortFunc >
int get_hoare_partition (TSortFunc sort_func, std::vector< T > &array, int lo, int hi)
 
template<typename T , typename TSortFunc >
void do_inplace_quick_sort_impl (TSortFunc sort_func, std::vector< T > &array, int lo, int hi)
 
template<typename T , typename TSortFunc >
void do_inplace_quick_sort (std::vector< T > *array, TSortFunc sort_func)
 
template<typename T , typename TSortFunc >
std::vector< T > get_quick_sorted (const std::vector< T > &arr, TSortFunc sort_func)
 
template<typename T >
int default_compare_for_quicksort (const T &lhs, const T &rhs)
 
template<typename T >
std::vector< T > get_quick_sorted (const std::vector< T > &arr)
 
template<typename T , typename TIdExtractor , typename TInt >
TInt get_max (const std::vector< T > &arr)
 
template<typename T , typename TIdExtractor , typename TBucket , typename TInt >
std::vector< T > count_sort (const std::vector< T > &arr, int exp)
 
template<typename T , typename TIdExtractor , typename TBucket , typename TInt >
void do_inplace_radix_sort (std::vector< T > *arr)
 
Rgb blend (const Rgb &top, const Rgb &bottom, BlendMode mode)
 
Rgba blend (const Rgba &top, const Rgba &bottom, BlendMode mode)
 
Rgbi blend (const Rgbi &top, const Rgbi &bottom, BlendMode mode)
 
Rgbai blend (const Rgbai &top, const Rgbai &bottom, BlendMode mode)
 
template<typename T >
constexpr Shufflebag< T > create_shuffle_bag (const ranges::span< const T > &items, int amount)
 
template<typename T >
constexpr Shufflebag< T > create_shuffle_bag (const std::vector< T > &items, int amount)
 
vec3f calc_center (const std::vector< vec3f > &positions)
 
SphereAndPosition build_bounding_sphere (const std::vector< vec3f > &positions)
 
template<typename K , typename V >
std::vector< K > get_keys (const std::map< K, V > &m)
 
template<typename K >
std::vector< K > get_sorted (const std::vector< K > &k)
 
template<typename K , typename V >
std::vector< std::string > get_keys_as_strings (const std::map< K, V > &m)
 
template<typename T >
bool swap_back_and_erase_object (T what, std::vector< T > *from)
 
template<typename T , typename TFunc >
void remove_matching (std::vector< T > *v, TFunc condition)
 
template<typename T , typename TFunc >
std::vector< T >::iterator find_first (std::vector< T > &v, TFunc condition)
 
template<typename E >
constexpr std::underlying_type< E >::type base_cast (E e) noexcept
 
template<typename T >
std::vector< T > calc_column_as_vector (const Table< T > &t, typename Table< T >::Idx x)
 
template<typename T >
std::vector< T > calc_row_as_vector (const Table< T > &t, typename Table< T >::Idx y)
 
void set_white_noise (BoolTable *world, Lrud< BorderSetupRule > border_control, std::function< bool()> rng)
 
int count_walls_manhattan (const BoolTable &world, Lrud< OutsideRule > outside_rule, int cx, int cy, int step, bool include_self)
 
int count_walls_plus (const BoolTable &world, Lrud< OutsideRule > outside_rule, int cx, int cy, int step, bool include_self)
 
int count_walls_box (const BoolTable &world, Lrud< OutsideRule > outside_rule, int cx, int cy, int step, bool include_self)
 
void make_smoother (BoolTable *world, Lrud< OutsideRule > outside_rule, std::function< std::optional< bool >(bool, const WallCounter &)> smooth_function)
 
std::vector< vec2ifind_empty_blocks (const BoolTable &world)
 
std::vector< vec2ifind_flood_fill_items (const BoolTable &world, const vec2i &start, bool allow_diagonals)
 
std::vector< std::vector< vec2i > > find_empty_regions (const BoolTable &world, bool allow_diagonals)
 
Image draw (const BoolTable &world, Rgbai wall_color, Rgbai space_color, int scale, std::optional< BorderSettings > border)
 
StringTable parse_csv (const std::string &csv_data, const CsvParserOptions &options)
 
int calc_width_of_string (const std::string &t)
 
int calc_height_of_string (const std::string &t)
 
int calc_single_column_width (const StringTable &t, int c)
 
int calc_single_row_height (const StringTable &t, int r)
 
std::vector< int > calc_all_column_widths (const StringTable &table, int extra)
 
StringTable split_table_cells_on_newline (const StringTable &table, StringTable::Idx row)
 Return a new table based on row, where each cell is split at newline over many rows. More...
 
void print_table_simple (std::ostream &out, const StringTable &maintable)
 
void print_table_grid (std::ostream &out, const StringTable &maintable)
 
template<typename T >
std::vector< T > perform_table_layout (const std::vector< T > &pieces, T total_size, T zero=0)
 Calculates a table layout based on the input layout. More...
 
TextBoxStyle get_terminal_style ()
 
bool is_ident_start (char c)
 
std::string to_string (TokenType t)
 
std::vector< Tokentokenize (const std::string &content, TemplateErrorList *error, const io::FilePath &file)
 
void parse_template_list (std::shared_ptr< TemplateNodeList > *nodes, TokenReader *reader, TemplateErrorList *errors, const io::FilePath &file, bool expect_end, io::FileSystem *fs)
 
void load_from_filesystem_to_node_list (io::FileSystem *fs, const io::FilePath &path, TemplateErrorList *error, std::shared_ptr< TemplateNodeList > *nodes)
 
std::shared_ptr< TemplateNodeStringparse_text (TokenReader *reader, TemplateErrorList *, const io::FilePath &, io::FileSystem *)
 
std::shared_ptr< TemplateNodeEvalparse_eval (TokenReader *reader, TemplateErrorList *errors, const io::FilePath &file, io::FileSystem *)
 
std::shared_ptr< TemplateNodeSetparse_set (TokenReader *reader, TemplateErrorList *errors, const io::FilePath &file, io::FileSystem *)
 
std::shared_ptr< TemplateNodeIfdefparse_ifdef (TokenReader *reader, TemplateErrorList *errors, const io::FilePath &file, io::FileSystem *fs)
 
std::shared_ptr< TemplateNodeListparse_include (TokenReader *reader, TemplateErrorList *errors, const io::FilePath &file, io::FileSystem *fs)
 
TimePoint get_current_timepoint ()
 
float get_seconds_between (const TimePoint &start, const TimePoint &end)
 
float calc_tor_curve (float x, float a, float b, float c)
 A generalized curve formula. More...
 
template<typename TString , typename TOnCodepointFunc >
bool calc_utf8_to_codepoints (const TString &string, TOnCodepointFunc on_codepoint)
 
void add_default_shaders (io::FileSystem *fs, const io::DirPath &base)
 
Ray3f from_mouse_to_ray (const core::CompiledCamera3 &camera, const core::Viewport &viewport, const vec2i &position)
 
UnitRay3f from_mouse_to_unit_ray (const core::CompiledCamera3 &camera, const core::Viewport &viewport, const vec2i &position)
 
float determine_extend_scale (float scale, float height, int window_height)
 
std::vector< std::string > get_word_wrapped (const std::string &str, std::function< bool(const std::string &)> fit)
 

Variables

constexpr TreeStyle slash_style
 
constexpr TreeStyle utf8_tree_style
 
constexpr TreeStyle cross_style
 
constexpr Guid nil_guid
 
constexpr auto dawnbringer_palette
 
constexpr auto named_colors_palette
 
constexpr unsigned char bit_up = 1 << 0
 
constexpr unsigned char bit_down = 1 << 1
 
constexpr unsigned char bit_left = 1 << 2
 
constexpr unsigned char bit_right = 1 << 3
 
constexpr unsigned char bit_no_line = static_cast<unsigned char>(~(bit_up | bit_down | bit_left | bit_right))
 
constexpr TextBoxStyle utf8_straight_style
 
constexpr TextBoxStyle utf8_rounded_style
 
constexpr TextBoxStyle utf_8double_line_style
 
constexpr TextBoxStyle ascii_style
 

Typedef Documentation

◆ BoolTable

using eu::core::BoolTable = typedef Table<bool>

Definition at line 15 of file table_bool.h.

◆ KerningMap

using eu::core::KerningMap = typedef std::map<std::pair<int, int>, float>

Definition at line 47 of file loadedfont.h.

◆ OnSentenceFunction

using eu::core::OnSentenceFunction = typedef std::function<void(const TextSentence&)>

Definition at line 12 of file nlp_sentence.h.

◆ RandomLnuthLcg

using eu::core::RandomLnuthLcg = typedef RandomLcg<U64, std::numeric_limits<U64>::max() , 6364136223846793005, 1442695040888963407>

Definition at line 31 of file rng.h.

◆ RandomXorShift32

using eu::core::RandomXorShift32 = typedef RandomXorShift<U32, 13, 17, 5>

Definition at line 65 of file rng.h.

◆ RandomXorShift64

using eu::core::RandomXorShift64 = typedef RandomXorShift<U64, 13, 17, 7>

Definition at line 66 of file rng.h.

◆ SortableList

template<typename T >
using eu::core::SortableList = typedef std::vector<std::shared_ptr<Sortable<T> >>

Definition at line 36 of file multisort.h.

◆ StringTable

using eu::core::StringTable = typedef Table<std::string>

Definition at line 16 of file table_string.h.

◆ TextLine

using eu::core::TextLine = typedef std::vector<std::string>

Definition at line 11 of file nlp_line.h.

◆ TextSentence

using eu::core::TextSentence = typedef std::vector<std::string>

Definition at line 11 of file nlp_sentence.h.

◆ TimePoint

using eu::core::TimePoint = typedef std::chrono::time_point<std::chrono::steady_clock>

Definition at line 8 of file timepoint.h.

Enumeration Type Documentation

◆ ActionWhenMissingInAlphabet

Enumerator
ignore 
pass_through 
replace 

Definition at line 10 of file cypher.h.

◆ AlphaLoad

enum eu::core::AlphaLoad
strong
Enumerator
remove 
keep 

Definition at line 138 of file image.h.

◆ BlendMode

enum eu::core::BlendMode
strong
Enumerator
normal 
lighten 
darken 
multiply 
average 
add 
subtract 
difference 
negation 
screen 
exclusion 
overlay 
soft_light 
hard_light 
color_dodge 
color_burn 
linear_dodge 
linear_burn 
linear_light 
vivid_light 
pin_light 
hard_mix 
reflect 
glow 
phoenix 

Definition at line 7 of file rgb_blend.h.

◆ BorderSetupRule

Enumerator
always_wall 
always_empty 
random 

Definition at line 20 of file table_bool.h.

◆ CsvTrim

enum eu::core::CsvTrim
strong
Enumerator
trim 
dont_trim 

Definition at line 65 of file table_string.h.

◆ DstInfo

enum eu::core::DstInfo
strong
Enumerator
in_effect 
not_in_effect 
info_unavailable 

Definition at line 23 of file datetime.h.

◆ EditorCameraStyle3

Enumerator
orbital 
fps 

Definition at line 70 of file camera3.editor.h.

◆ Grayscale

enum eu::core::Grayscale
strong
Enumerator
max 
gamma 
linear 
average 

Definition at line 16 of file imagefilters.h.

◆ ImageWriteFormat

Enumerator
png 
bmp 
tga 
jpeg 

Definition at line 19 of file image.h.

◆ Key

enum eu::core::Key
strong
Enumerator
invalid 
unbound 
return_key 
escape 
backspace 
tab 
space 
exclaim 
quotedbl 
hash 
percent 
dollar 
ampersand 
quote 
left_paren 
right_paren 
asterix 
plus 
comma 
minus 
period 
slash 
num_0 
num_1 
num_2 
num_3 
num_4 
num_5 
num_6 
num_7 
num_8 
num_9 
colon 
semicolon 
less 
equals 
greater 
question 
at 
left_bracket 
backslash 
right_bracket 
caret 
underscore 
backquote 
capslock 
f1 
f2 
f3 
f4 
f5 
f6 
f7 
f8 
f9 
f10 
f11 
f12 
print_screen 
scroll_lock 
pause 
insert 
home 
page_up 
delete_key 
end 
page_down 
right 
left 
down 
up 
numlock_clear 
keypad_divide 
keypad_multiply 
keypad_minus 
keypad_plus 
keypad_enter 
keypad_1 
keypad_2 
keypad_3 
keypad_4 
keypad_5 
keypad_6 
keypad_7 
keypad_8 
keypad_9 
keypad_0 
keypad_period 
application 
power 
keypad_equals 
f13 
f14 
f15 
f16 
f17 
f18 
f19 
f20 
f21 
f22 
f23 
f24 
execute 
help 
menu 
select 
stop 
again 
undo 
cut 
copy 
paste 
find 
mute 
volume_up 
volume_down 
keypad_comma 
keypad_equals_as_400 
alt_erase 
sysreq 
cancel 
clear 
prior 
second_return 
separator 
out 
oper 
clear_again 
crsel 
exsel 
keypad_00 
keypad_000 
thousandseparator 
decimalseparator 
currency_unit 
currency_subunit 
keypad_leftparen 
keypad_rightparen 
keypad_leftbrace 
keypad_rightbrace 
keypad_tab 
keypad_backspace 
keypad_a 
keypad_b 
keypad_c 
keypad_d 
keypad_e 
keypad_f 
keypad_xor 
keypad_power 
keypad_percent 
keypad_less 
keypad_greater 
keypad_ampersand 
keypad_double_ampersand 
keypad_vertical_bar 
keypad_double_verticle_bar 
keypad_colon 
keypad_hash 
keypad_space 
keypad_at 
keypad_exclam 
keypad_mem_store 
keypad_mem_recall 
keypad_mem_clear 
keypad_mem_add 
keypad_mem_subtract 
keypad_mem_multiply 
keypad_mem_divide 
keypad_plus_minus 
keypad_clear 
keypad_clear_entry 
keypad_binary 
keypad_octal 
keypad_decimal 
keypad_hexadecimal 
ctrl_left 
shift_left 
alt_left 
gui_left 
ctrl_right 
shift_right 
alt_right 
gui_right 
mode 
audio_next 
audio_prev 
audio_stop 
audio_play 
audio_mute 
media_select 
www 
mail 
calculator 
computer 
ac_search 
ac_home 
ac_back 
ac_forward 
ac_stop 
ac_refresh 
ac_bookmarks 
brightness_down 
brightness_up 
displayswitch 
keyboard_illum_toggle 
keyboard_illum_down 
keyboard_illum_up 
eject 
sleep 

Definition at line 25 of file key.h.

◆ Month

enum eu::core::Month
strong
Enumerator
january 
february 
march 
april 
may 
june 
july 
august 
september 
october 
november 
december 

Definition at line 15 of file datetime.h.

◆ MouseBehaviour

Enumerator
normal 
wrap_within_window 
relative_only 

Definition at line 6 of file mousebehaviour.h.

◆ MouseButton

enum eu::core::MouseButton
strong
Enumerator
invalid 
unbound 
left 
middle 
right 
x1 
x2 

Definition at line 7 of file key.h.

◆ NeighborhoodAlgorithm

Enumerator
manhattan 
plus 
box 

Definition at line 84 of file table_bool.h.

◆ OutsideRule

enum eu::core::OutsideRule
strong
Enumerator
wall 
empty 
mirror 
wrap 

Definition at line 38 of file table_bool.h.

◆ PixelsOutside

Enumerator
assert 
discard 

Definition at line 81 of file image_draw.h.

◆ SortStyle

enum eu::core::SortStyle
strong
Enumerator
ascending 
descending 

Definition at line 15 of file multisort.h.

◆ TimeZone

enum eu::core::TimeZone
strong
Enumerator
gmt 
local 

Definition at line 28 of file datetime.h.

◆ TokenType

enum eu::core::TokenType
strong
Enumerator
text 
if_def 
eval 
ident 
end 
set 
string 
include 
end_of_file 

Definition at line 274 of file texttemplate.cc.

◆ ValueType

enum eu::core::ValueType
strong
Enumerator
int_type 
float_type 
vec3f_type 
map_type 

Definition at line 11 of file propertytree.h.

◆ WrapMode

enum eu::core::WrapMode
strong
Enumerator
repeat 
clamp_to_edge 
mirror_repeat 

Definition at line 23 of file mesh.h.

Function Documentation

◆ add_default_shaders()

void eu::core::add_default_shaders ( io::FileSystem fs,
const io::DirPath base 
)

Definition at line 10 of file vfs_defaultshaders.cc.

◆ base_cast()

template<typename E >
constexpr std::underlying_type<E>::type eu::core::base_cast ( e)
constexprnoexcept

Definition at line 92 of file stdutils.h.

◆ blend() [1/4]

Rgb eu::core::blend ( const Rgb top,
const Rgb bottom,
BlendMode  mode 
)

Definition at line 402 of file rgb_blend.cc.

◆ blend() [2/4]

Rgba eu::core::blend ( const Rgba top,
const Rgba bottom,
BlendMode  mode 
)

Definition at line 403 of file rgb_blend.cc.

◆ blend() [3/4]

Rgbai eu::core::blend ( const Rgbai top,
const Rgbai bottom,
BlendMode  mode 
)

Definition at line 405 of file rgb_blend.cc.

◆ blend() [4/4]

Rgbi eu::core::blend ( const Rgbi top,
const Rgbi bottom,
BlendMode  mode 
)

Definition at line 404 of file rgb_blend.cc.

◆ blend_image()

void eu::core::blend_image ( Image dst,
const vec2i p,
const Image src,
const Rgbai tint 
)

Definition at line 492 of file image_draw.cc.

◆ build_bounding_sphere()

SphereAndPosition eu::core::build_bounding_sphere ( const std::vector< vec3f > &  positions)

Definition at line 27 of file sphere.builder.cc.

◆ c_date_time_to_int64()

uint64_t eu::core::c_date_time_to_int64 ( const TimetWrapper dt)

Definition at line 282 of file datetime.cc.

◆ c_int64_to_date_time() [1/2]

TimetWrapper eu::core::c_int64_to_date_time ( U64  total_seconds)

Definition at line 293 of file datetime.cc.

◆ c_int64_to_date_time() [2/2]

TimetWrapper eu::core::c_int64_to_date_time ( uint64_t  i)

◆ c_int_to_month()

Month eu::core::c_int_to_month ( int  m)

Definition at line 26 of file datetime.cc.

◆ c_month_to_int()

int eu::core::c_month_to_int ( Month  month)

Definition at line 19 of file datetime.cc.

◆ c_vec3() [1/3]

vec3f eu::core::c_vec3 ( const Rgb  f)

Definition at line 149 of file imagefilters.cc.

◆ c_vec3() [2/3]

vec3f eu::core::c_vec3 ( const Rgbai  c)

Definition at line 161 of file imagefilters.cc.

◆ c_vec3() [3/3]

vec3f eu::core::c_vec3 ( const Rgbi  c)

Definition at line 155 of file imagefilters.cc.

◆ calc_all_column_widths()

std::vector<int> eu::core::calc_all_column_widths ( const StringTable table,
int  extra 
)

Definition at line 185 of file table_string.cc.

◆ calc_center()

vec3f eu::core::calc_center ( const std::vector< vec3f > &  positions)

Definition at line 12 of file sphere.builder.cc.

◆ calc_column_as_vector()

template<typename T >
std::vector<T> eu::core::calc_column_as_vector ( const Table< T > &  t,
typename Table< T >::Idx  x 
)

Definition at line 200 of file table.h.

◆ calc_crc32()

unsigned long eu::core::calc_crc32 ( const MemoryChunk chunk)

Definition at line 11 of file crc32.cc.

◆ calc_height_of_string()

int eu::core::calc_height_of_string ( const std::string &  t)

Definition at line 149 of file table_string.cc.

◆ calc_poisson_samples()

std::vector< vec2f > eu::core::calc_poisson_samples ( const Rectf area,
Random random,
float  r,
float  bs,
int  k 
)

Definition at line 158 of file poisson.cc.

◆ calc_row_as_vector()

template<typename T >
std::vector<T> eu::core::calc_row_as_vector ( const Table< T > &  t,
typename Table< T >::Idx  y 
)

Definition at line 213 of file table.h.

◆ calc_single_column_width()

int eu::core::calc_single_column_width ( const StringTable t,
int  c 
)

Definition at line 163 of file table_string.cc.

◆ calc_single_row_height()

int eu::core::calc_single_row_height ( const StringTable t,
int  r 
)

Definition at line 174 of file table_string.cc.

◆ calc_tor_curve()

float eu::core::calc_tor_curve ( float  x,
float  a,
float  b,
float  c 
)

A generalized curve formula.

tor curve is a generalized, parameterized curve shaping function, especially useful for easing functions and interpolation. DESMOS DEMO: https://www.desmos.com/calculator/yvbmqxxphj

Originally based on Colugo's curve editor: https://twitter.com/ColugoMusic/status/1363071439679729665?s=20 which is based off of Yann van der Cruyssen's sCurve formula: https://twitter.com/Morusque/status/1352569197499441155 which is based off of this paper: https://arxiv.org/pdf/2010.09714.pdf

tor curve expands upon this by adding a third parameter controlling the falloffs/asymptotes, for both the horizontal and vertical axes.

Author
torcado, 2021 (javascript)
madeso (c++ port)
Parameters
xthe input value, range 0-1
adefines the general slope of the curve
bdefines the midpoint location
cdefines the flatness of the curve at the midpoint/ends

Definition at line 13 of file torcurve.cc.

◆ calc_utf8_to_codepoints()

template<typename TString , typename TOnCodepointFunc >
bool eu::core::calc_utf8_to_codepoints ( const TString &  string,
TOnCodepointFunc  on_codepoint 
)

Definition at line 11 of file utf8.h.

◆ calc_width_of_string()

int eu::core::calc_width_of_string ( const std::string &  t)

Definition at line 128 of file table_string.cc.

◆ change_brightness()

void eu::core::change_brightness ( Image image,
int  change 
)

Definition at line 234 of file imagefilters.cc.

◆ change_contrast()

void eu::core::change_contrast ( Image image,
const Angle contrast 
)

Definition at line 242 of file imagefilters.cc.

◆ clear()

void eu::core::clear ( Image image,
const Rgbai color 
)

Definition at line 32 of file image_draw.cc.

◆ collect_sizes()

std::vector< size2i > eu::core::collect_sizes ( const std::vector< Image > &  images,
int  padding 
)

Definition at line 15 of file collage.cc.

◆ contains_point() [1/2]

bool eu::core::contains_point ( const Aabb aabb,
const vec3f point 
)

Definition at line 291 of file intersection.cc.

◆ contains_point() [2/2]

bool eu::core::contains_point ( const Sphere sphere,
const vec3f sphere_center,
const vec3f point 
)

Definition at line 245 of file intersection.cc.

◆ count_sort()

template<typename T , typename TIdExtractor , typename TBucket , typename TInt >
std::vector<T> eu::core::count_sort ( const std::vector< T > &  arr,
int  exp 
)

Definition at line 90 of file radix_sort.h.

◆ count_walls_box()

int eu::core::count_walls_box ( const BoolTable world,
Lrud< OutsideRule outside_rule,
int  cx,
int  cy,
int  step,
bool  include_self 
)

Definition at line 221 of file table_bool.cc.

◆ count_walls_manhattan()

int eu::core::count_walls_manhattan ( const BoolTable world,
Lrud< OutsideRule outside_rule,
int  cx,
int  cy,
int  step,
bool  include_self 
)

Definition at line 145 of file table_bool.cc.

◆ count_walls_plus()

int eu::core::count_walls_plus ( const BoolTable world,
Lrud< OutsideRule outside_rule,
int  cx,
int  cy,
int  step,
bool  include_self 
)

Definition at line 182 of file table_bool.cc.

◆ create_new_image_from()

template<typename C >
Image eu::core::create_new_image_from ( const Image image_source,
callback 
)

Definition at line 77 of file imagefilters.cc.

◆ create_shuffle_bag() [1/2]

template<typename T >
constexpr Shufflebag<T> eu::core::create_shuffle_bag ( const ranges::span< const T > &  items,
int  amount 
)
constexpr

Definition at line 68 of file shufflebag.h.

◆ create_shuffle_bag() [2/2]

template<typename T >
constexpr Shufflebag<T> eu::core::create_shuffle_bag ( const std::vector< T > &  items,
int  amount 
)
constexpr

Definition at line 83 of file shufflebag.h.

◆ default_compare_for_insertion_sort()

template<typename T >
int eu::core::default_compare_for_insertion_sort ( const T &  lhs,
const T &  rhs 
)

Definition at line 39 of file insertionsort.h.

◆ default_compare_for_quicksort()

template<typename T >
int eu::core::default_compare_for_quicksort ( const T &  lhs,
const T &  rhs 
)

Definition at line 71 of file quicksort.h.

◆ determine_extend_scale()

float eu::core::determine_extend_scale ( float  scale,
float  height,
int  window_height 
)

Definition at line 45 of file viewportdef.cc.

◆ determine_style()

TreeStyle eu::core::determine_style ( )

Definition at line 29 of file ctree.cc.

◆ do_inplace_insertion_sort()

template<typename T , typename TSortFunc >
void eu::core::do_inplace_insertion_sort ( std::vector< T > *  pointer_to_array,
TSortFunc  sort_func 
)

Definition at line 10 of file insertionsort.h.

◆ do_inplace_quick_sort()

template<typename T , typename TSortFunc >
void eu::core::do_inplace_quick_sort ( std::vector< T > *  array,
TSortFunc  sort_func 
)

Definition at line 55 of file quicksort.h.

◆ do_inplace_quick_sort_impl()

template<typename T , typename TSortFunc >
void eu::core::do_inplace_quick_sort_impl ( TSortFunc  sort_func,
std::vector< T > &  array,
int  lo,
int  hi 
)

Definition at line 43 of file quicksort.h.

◆ do_inplace_radix_sort()

template<typename T , typename TIdExtractor , typename TBucket , typename TInt >
void eu::core::do_inplace_radix_sort ( std::vector< T > *  arr)

Definition at line 127 of file radix_sort.h.

◆ draw()

Image eu::core::draw ( const BoolTable world,
Rgbai  wall_color,
Rgbai  space_color,
int  scale,
std::optional< BorderSettings border 
)

Definition at line 458 of file table_bool.cc.

◆ draw_arrow()

void eu::core::draw_arrow ( Image image,
const vec2f from,
const vec2f to,
const Rgbai color,
float  size 
)

Definition at line 647 of file image_draw.cc.

◆ draw_circle()

void eu::core::draw_circle ( Image image,
const Rgb color,
const vec2i center,
float  radius,
float  softness,
float  inner 
)

Definition at line 174 of file image_draw.cc.

◆ draw_image()

Image eu::core::draw_image ( const std::vector< vec2i > &  positions,
const std::vector< Image > &  images,
const size2i size,
const Rgbi background_color 
)

Definition at line 37 of file collage.cc.

◆ draw_line_antialiased() [1/2]

void eu::core::draw_line_antialiased ( Image image,
const Rgb color,
const vec2f from,
const vec2f to 
)

Definition at line 361 of file image_draw.cc.

◆ draw_line_antialiased() [2/2]

void eu::core::draw_line_antialiased ( Image image,
const Rgb color,
const vec2i from,
const vec2i to 
)

Definition at line 341 of file image_draw.cc.

◆ draw_line_fast()

void eu::core::draw_line_fast ( Image image,
const Rgbai color,
const vec2i from,
const vec2i to 
)

Definition at line 253 of file image_draw.cc.

◆ draw_rect()

void eu::core::draw_rect ( Image image,
const Rgbai color,
const Recti rect 
)

Definition at line 39 of file image_draw.cc.

◆ draw_square()

void eu::core::draw_square ( Image image,
const Rgbai color,
int  x,
int  y,
int  size 
)

Definition at line 67 of file image_draw.cc.

◆ draw_text()

void eu::core::draw_text ( Image image,
const vec2i start_pos,
const std::string &  text,
const Rgbai color,
const LoadedFont font 
)

Definition at line 518 of file image_draw.cc.

◆ extract_palette_median_cut()

std::vector< Rgbi > eu::core::extract_palette_median_cut ( const Image image,
int  depth,
bool  middle_split 
)

Definition at line 185 of file palette_extract.cc.

◆ fill_poly()

void eu::core::fill_poly ( Image image,
const Rgbai color,
const std::vector< vec2f > &  poly 
)

Definition at line 146 of file image_draw.cc.

◆ fill_triangle()

void eu::core::fill_triangle ( Image image,
const vec2f a,
const vec2f b,
const vec2f c,
const Rgbai color 
)

Definition at line 590 of file image_draw.cc.

◆ filter_color_detection()

void eu::core::filter_color_detection ( Image image,
Rgb  color,
float  r 
)

Definition at line 190 of file imagefilters.cc.

◆ filter_edge_detection()

void eu::core::filter_edge_detection ( Image image,
float  r 
)

Definition at line 167 of file imagefilters.cc.

◆ find() [1/4]

bool eu::core::find ( const std::string &  target,
const std::string &  search 
)

Definition at line 8 of file findstring.cc.

◆ find() [2/4]

bool eu::core::find ( const std::string &  target,
const std::vector< std::string > &  searches 
)

Definition at line 15 of file findstring.cc.

◆ find() [3/4]

bool eu::core::find ( const std::vector< std::string > &  targets,
const std::string &  search 
)

Definition at line 30 of file findstring.cc.

◆ find() [4/4]

bool eu::core::find ( const std::vector< std::string > &  targets,
const std::vector< std::string > &  searches 
)

Definition at line 45 of file findstring.cc.

◆ find_empty_blocks()

std::vector< vec2i > eu::core::find_empty_blocks ( const BoolTable world)

Definition at line 346 of file table_bool.cc.

◆ find_empty_regions()

std::vector< std::vector< vec2i > > eu::core::find_empty_regions ( const BoolTable world,
bool  allow_diagonals 
)

Definition at line 422 of file table_bool.cc.

◆ find_first()

template<typename T , typename TFunc >
std::vector<T>::iterator eu::core::find_first ( std::vector< T > &  v,
TFunc  condition 
)

Definition at line 74 of file stdutils.h.

◆ find_flood_fill_items()

std::vector< vec2i > eu::core::find_flood_fill_items ( const BoolTable world,
const vec2i start,
bool  allow_diagonals 
)

Definition at line 365 of file table_bool.cc.

◆ from_image_to_string_table() [1/2]

Table< char > eu::core::from_image_to_string_table ( const Image img,
bool  shorter,
Grayscale  grayscale 
)

Definition at line 71 of file image_to_text.cc.

◆ from_image_to_string_table() [2/2]

Table< char > eu::core::from_image_to_string_table ( const Image img,
const std::vector< ImageMapAction > &  map 
)

Definition at line 13 of file image_to_text.cc.

◆ from_image_to_string_table_exact()

Table< char > eu::core::from_image_to_string_table_exact ( const Image img,
const std::vector< ImageMapAction > &  map,
char  missing 
)

Definition at line 41 of file image_to_text.cc.

◆ from_line_to_string()

std::string eu::core::from_line_to_string ( const TextLine s)

Definition at line 17 of file nlp_line.cc.

◆ from_mouse_to_ray()

Ray3f eu::core::from_mouse_to_ray ( const core::CompiledCamera3 camera,
const core::Viewport viewport,
const vec2i position 
)

Definition at line 30 of file viewport.cc.

◆ from_mouse_to_unit_ray()

UnitRay3f eu::core::from_mouse_to_unit_ray ( const core::CompiledCamera3 camera,
const core::Viewport viewport,
const vec2i position 
)

Definition at line 47 of file viewport.cc.

◆ from_sentence_to_string()

std::string eu::core::from_sentence_to_string ( const TextSentence s)

Definition at line 208 of file nlp_sentence.cc.

◆ get_ceasar_cypher()

std::string eu::core::get_ceasar_cypher ( const std::string &  input,
int  steps,
const std::string &  alphabet,
bool  case_sensitive,
ActionWhenMissingInAlphabet  missing_in_alphabet,
char  invalid 
)

Definition at line 16 of file cypher.cc.

◆ get_character_from_builtin8()

template<typename TGlyphs >
LoadedFont eu::core::get_character_from_builtin8 ( const int  start_codepoint,
int  end_codepoint,
TGlyphs  glyphs 
)

Definition at line 192 of file loadedfont.cc.

◆ get_characters_from_font() [1/2]

LoadedFont eu::core::get_characters_from_font ( io::FileSystem file_system,
const io::FilePath font_file,
int  font_size,
const std::string &  chars 
)

Definition at line 298 of file loadedfont.cc.

◆ get_characters_from_font() [2/2]

LoadedFont eu::core::get_characters_from_font ( std::shared_ptr< MemoryChunk file_memory,
int  font_size,
const std::string &  chars 
)

Definition at line 324 of file loadedfont.cc.

◆ get_characters_from_single_image() [1/2]

LoadedFont eu::core::get_characters_from_single_image ( const Image image,
const std::string &  image_alias,
float  image_scale,
float  image_bearing_x,
float  image_bearing_y,
float  image_advance 
)

Definition at line 427 of file loadedfont.cc.

◆ get_characters_from_single_image() [2/2]

LoadedFont eu::core::get_characters_from_single_image ( io::FileSystem fs,
const io::FilePath image_file,
const std::string &  image_alias,
float  image_scale,
float  image_bearing_x,
float  image_bearing_y,
float  image_advance 
)

Definition at line 390 of file loadedfont.cc.

◆ get_closest_point() [1/4]

vec3f eu::core::get_closest_point ( const Aabb aabb,
const vec3f point 
)

Definition at line 312 of file intersection.cc.

◆ get_closest_point() [2/4]

vec3f eu::core::get_closest_point ( const Plane plane,
const vec3f point 
)

Definition at line 188 of file intersection.cc.

◆ get_closest_point() [3/4]

vec3f eu::core::get_closest_point ( const Sphere sphere,
const vec3f sphere_center,
const vec3f point 
)

Definition at line 257 of file intersection.cc.

◆ get_closest_point() [4/4]

vec3f eu::core::get_closest_point ( const UnitRay3f ray,
const vec3f c 
)

Definition at line 213 of file intersection.cc.

◆ get_cp437()

std::string_view eu::core::get_cp437 ( int  c)

Definition at line 36 of file cp437.cc.

◆ get_current_timepoint()

TimePoint eu::core::get_current_timepoint ( )

Definition at line 6 of file timepoint.cc.

◆ get_distance_between() [1/2]

float eu::core::get_distance_between ( const Plane plane,
const vec3f p 
)

Definition at line 178 of file intersection.cc.

◆ get_distance_between() [2/2]

float eu::core::get_distance_between ( const UnitRay3f ray,
const vec3f point 
)

Definition at line 200 of file intersection.cc.

◆ get_drunken_bishop_result() [1/3]

Table< int > eu::core::get_drunken_bishop_result ( const std::vector< int > &  codes,
int  width,
int  height,
int  startx,
int  starty 
)

Definition at line 121 of file drunken_bishop.cc.

◆ get_drunken_bishop_result() [2/3]

Table< int > eu::core::get_drunken_bishop_result ( U32  hash,
int  width,
int  height,
bool  msb_first,
int  startx,
int  starty 
)

Definition at line 79 of file drunken_bishop.cc.

◆ get_drunken_bishop_result() [3/3]

Table< int > eu::core::get_drunken_bishop_result ( U64  hash,
int  width,
int  height,
bool  msb_first,
int  startx,
int  starty 
)

Definition at line 100 of file drunken_bishop.cc.

◆ get_hoare_partition()

template<typename T , typename TSortFunc >
int eu::core::get_hoare_partition ( TSortFunc  sort_func,
std::vector< T > &  array,
int  lo,
int  hi 
)

Definition at line 15 of file quicksort.h.

◆ get_insertion_sorted() [1/2]

template<typename T >
std::vector<T> eu::core::get_insertion_sorted ( const std::vector< T > &  array)

Definition at line 50 of file insertionsort.h.

◆ get_insertion_sorted() [2/2]

template<typename T , typename TSortFunc >
std::vector<T> eu::core::get_insertion_sorted ( const std::vector< T > &  array,
TSortFunc  sort_func 
)

Definition at line 30 of file insertionsort.h.

◆ get_intersection() [1/6]

Ray2Ray2Result eu::core::get_intersection ( const Ray2f lhs,
const Ray2f rhs 
)

Definition at line 130 of file intersection.cc.

◆ get_intersection() [2/6]

bool eu::core::get_intersection ( const Sphere lhs,
const vec3f lhs_center,
const Sphere rhs,
const vec3f rhs_center 
)

Definition at line 232 of file intersection.cc.

◆ get_intersection() [3/6]

Ray3AabbResult eu::core::get_intersection ( const UnitRay3f r,
const Aabb aabb 
)

Definition at line 37 of file intersection.cc.

◆ get_intersection() [4/6]

float eu::core::get_intersection ( const UnitRay3f r,
const Plane p 
)

Definition at line 97 of file intersection.cc.

◆ get_intersection() [5/6]

std::optional< float > eu::core::get_intersection ( const UnitRay3f ray,
const CollisionMesh mesh 
)

Definition at line 39 of file collisionmesh.cc.

◆ get_intersection() [6/6]

float eu::core::get_intersection ( const UnitRay3f ray,
const Sphere sphere,
const vec3f sphere_center 
)

Definition at line 269 of file intersection.cc.

◆ get_intersection_ray_triangle()

std::optional< float > eu::core::get_intersection_ray_triangle ( const UnitRay3f ray,
const vec3f v0,
const vec3f v1,
const vec3f v2 
)

This implements the Möller–Trumbore intersection algorithm.

https://en.wikipedia.org/wiki/M%C3%B6ller%E2%80%93Trumbore_intersection_algorithm

Definition at line 351 of file intersection.cc.

◆ get_keys()

template<typename K , typename V >
std::vector<K> eu::core::get_keys ( const std::map< K, V > &  m)

Definition at line 13 of file stdutils.h.

◆ get_keys_as_strings()

template<typename K , typename V >
std::vector<std::string> eu::core::get_keys_as_strings ( const std::map< K, V > &  m)

Definition at line 34 of file stdutils.h.

◆ get_max()

template<typename T , typename TIdExtractor , typename TInt >
TInt eu::core::get_max ( const std::vector< T > &  arr)

Definition at line 74 of file radix_sort.h.

◆ get_quick_sorted() [1/2]

template<typename T >
std::vector<T> eu::core::get_quick_sorted ( const std::vector< T > &  arr)

Definition at line 82 of file quicksort.h.

◆ get_quick_sorted() [2/2]

template<typename T , typename TSortFunc >
std::vector<T> eu::core::get_quick_sorted ( const std::vector< T > &  arr,
TSortFunc  sort_func 
)

Definition at line 62 of file quicksort.h.

◆ get_random_cp437_in_utf8()

std::string_view eu::core::get_random_cp437_in_utf8 ( Random random)

Definition at line 43 of file cp437.cc.

◆ get_rot13()

std::string eu::core::get_rot13 ( const std::string &  input)

Definition at line 66 of file cypher.cc.

◆ get_seconds_between()

float eu::core::get_seconds_between ( const TimePoint start,
const TimePoint end 
)

Definition at line 12 of file timepoint.cc.

◆ get_sorted()

template<typename K >
std::vector<K> eu::core::get_sorted ( const std::vector< K > &  k)

Definition at line 25 of file stdutils.h.

◆ get_sorted_indices()

template<typename T , typename TSelf >
std::vector<size_t> eu::core::get_sorted_indices ( const std::vector< T > &  data,
const SortBuilder< T, TSelf > &  builder 
)

Definition at line 113 of file multisort.h.

◆ get_ssh_characters()

std::vector< std::string > eu::core::get_ssh_characters ( )

Definition at line 153 of file drunken_bishop.cc.

◆ get_terminal_style()

TextBoxStyle eu::core::get_terminal_style ( )

Definition at line 61 of file textbox.cc.

◆ get_word_wrapped()

std::vector< std::string > eu::core::get_word_wrapped ( const std::string &  str,
std::function< bool(const std::string &)>  fit 
)

Definition at line 61 of file wordwrap.cc.

◆ hash64()

constexpr U64 eu::core::hash64 ( const std::string_view  str,
U64  hash = 0xcbf29ce484222325 
)
constexpr

Definition at line 11 of file hash.h.

◆ is_all_inside()

bool eu::core::is_all_inside ( const Rectf a,
const vec2f p,
float  r 
)

Definition at line 14 of file poisson.cc.

◆ is_ident_start()

bool eu::core::is_ident_start ( char  c)

Definition at line 183 of file textfileparser.cc.

◆ is_point_in_triangle()

bool eu::core::is_point_in_triangle ( const vec2f a,
const vec2f b,
const vec2f c,
const vec2f p 
)

Definition at line 327 of file intersection.cc.

◆ iterate()

template<typename T >
StepIteratorCreator<T> eu::core::iterate ( const T  from,
to,
step = 1 
)

Definition at line 73 of file iterate.h.

◆ lay_out_in_a_grid() [1/2]

std::pair< std::vector< vec2i >, size2i > eu::core::lay_out_in_a_grid ( const std::vector< Image > &  images,
int  padding,
bool  top_to_bottom 
)

Definition at line 205 of file collage.cc.

◆ lay_out_in_a_grid() [2/2]

Image eu::core::lay_out_in_a_grid ( const std::vector< Image > &  images,
int  padding,
Rgbi  background_color,
bool  top_to_bottom 
)

Definition at line 293 of file collage.cc.

◆ load_characters_from_builtin13()

LoadedFont eu::core::load_characters_from_builtin13 ( )

Definition at line 244 of file loadedfont.cc.

◆ load_characters_from_builtin8()

LoadedFont eu::core::load_characters_from_builtin8 ( )

Definition at line 285 of file loadedfont.cc.

◆ load_enum_type()

void eu::core::load_enum_type ( EnumType type,
io::FileSystem fs,
const io::FilePath path 
)

Definition at line 182 of file enum.cc.

◆ load_from_filesystem_to_node_list()

void eu::core::load_from_filesystem_to_node_list ( io::FileSystem fs,
const io::FilePath path,
TemplateErrorList error,
std::shared_ptr< TemplateNodeList > *  nodes 
)

Definition at line 521 of file texttemplate.cc.

◆ load_image() [1/3]

ImageLoadResult eu::core::load_image ( io::FileSystem fs,
const io::FilePath path,
AlphaLoad  alpha 
)

Definition at line 295 of file image.cc.

◆ load_image() [2/3]

ImageLoadResult eu::core::load_image ( std::shared_ptr< MemoryChunk file_memory,
const std::string &  path,
AlphaLoad  alpha 
)

Definition at line 311 of file image.cc.

◆ load_image() [3/3]

ImageLoadResult eu::core::load_image ( void *  compressed_data,
int  compressed_size,
const std::string &  path,
AlphaLoad  alpha 
)

Definition at line 408 of file image.cc.

◆ make_grayscale() [1/2]

void eu::core::make_grayscale ( Image image,
Grayscale  grayscale 
)

Definition at line 56 of file imagefilters.cc.

◆ make_grayscale() [2/2]

Rgbai eu::core::make_grayscale ( Rgbai  c,
Grayscale  grayscale 
)

Definition at line 23 of file imagefilters.cc.

◆ make_smoother()

void eu::core::make_smoother ( BoolTable world,
Lrud< OutsideRule outside_rule,
std::function< std::optional< bool >(bool, const WallCounter &)>  smooth_function 
)

Definition at line 326 of file table_bool.cc.

◆ make_static_palette()

template<typename... T>
constexpr StaticPalette<sizeof...(T)> eu::core::make_static_palette ( const std::string_view &  name,
T...  colors 
)
constexpr

Definition at line 91 of file palette.h.

◆ match_palette()

void eu::core::match_palette ( Image image,
const Palette palette 
)

Definition at line 65 of file imagefilters.cc.

◆ match_palette_dither()

void eu::core::match_palette_dither ( Image image,
const Palette palette 
)

Definition at line 93 of file imagefilters.cc.

◆ on_whole_image()

Recti eu::core::on_whole_image ( const Image image)

Definition at line 21 of file image_draw.cc.

◆ pack()

std::vector< std::optional< Recti > > eu::core::pack ( const size2i container,
const std::vector< size2i > &  to_pack 
)

Definition at line 15 of file pack.cc.

◆ pack_image() [1/2]

std::vector< vec2i > eu::core::pack_image ( const size2i image_size,
const std::vector< Image > &  images,
const std::vector< std::string > &  files,
int  padding 
)

Definition at line 113 of file collage.cc.

◆ pack_image() [2/2]

std::optional< Image > eu::core::pack_image ( const std::vector< Image > &  images,
const std::vector< std::string > &  files,
const size2i requested_size,
int  padding,
Rgbi  background_color,
bool  should_pack_image 
)

Definition at line 147 of file collage.cc.

◆ pack_tight()

size2i eu::core::pack_tight ( const size2i default_size,
std::vector< vec2i > *  positions,
const std::vector< Image > &  images,
int  padding 
)

Definition at line 70 of file collage.cc.

◆ parse_commandline()

std::vector< std::string > eu::core::parse_commandline ( const std::string &  str)

Definition at line 103 of file console.cc.

◆ parse_csv()

StringTable eu::core::parse_csv ( const std::string &  csv_data,
const CsvParserOptions options 
)

Definition at line 15 of file table_string.cc.

◆ parse_eval()

std::shared_ptr<TemplateNodeEval> eu::core::parse_eval ( TokenReader reader,
TemplateErrorList errors,
const io::FilePath file,
io::FileSystem  
)

Definition at line 573 of file texttemplate.cc.

◆ parse_ifdef()

std::shared_ptr<TemplateNodeIfdef> eu::core::parse_ifdef ( TokenReader reader,
TemplateErrorList errors,
const io::FilePath file,
io::FileSystem fs 
)

Definition at line 646 of file texttemplate.cc.

◆ parse_include()

std::shared_ptr<TemplateNodeList> eu::core::parse_include ( TokenReader reader,
TemplateErrorList errors,
const io::FilePath file,
io::FileSystem fs 
)

Definition at line 677 of file texttemplate.cc.

◆ parse_line()

std::optional< TextLine > eu::core::parse_line ( const std::string &  line)

Definition at line 10 of file nlp_line.cc.

◆ parse_sentences()

bool eu::core::parse_sentences ( std::istream &  data,
OnSentenceFunction  on_sentence 
)

Definition at line 175 of file nlp_sentence.cc.

◆ parse_set()

std::shared_ptr<TemplateNodeSet> eu::core::parse_set ( TokenReader reader,
TemplateErrorList errors,
const io::FilePath file,
io::FileSystem  
)

Definition at line 602 of file texttemplate.cc.

◆ parse_template_list()

void eu::core::parse_template_list ( std::shared_ptr< TemplateNodeList > *  nodes,
TokenReader reader,
TemplateErrorList errors,
const io::FilePath file,
bool  expect_end,
io::FileSystem fs 
)

Definition at line 746 of file texttemplate.cc.

◆ parse_text()

std::shared_ptr<TemplateNodeString> eu::core::parse_text ( TokenReader reader,
TemplateErrorList ,
const io::FilePath ,
io::FileSystem  
)

Definition at line 555 of file texttemplate.cc.

◆ paste_image()

void eu::core::paste_image ( Image dest_image,
const vec2i position,
const Image source_image,
BlendMode  blend_mode,
PixelsOutside  clip 
)

Definition at line 552 of file image_draw.cc.

◆ perform_table_layout()

template<typename T >
std::vector<T> eu::core::perform_table_layout ( const std::vector< T > &  pieces,
total_size,
zero = 0 
)

Calculates a table layout based on the input layout.

Since rows and columns are handled the same, this functions only handled 1d tables.

Positive values in the array mean absolute pixel size Zero values are invalid. Negative values indicate the scaling size and the exact ration will be proportional to the rest of the scaling values.

If available size < min_size scaling areas will have "zero" and absolute areas will be resized.

Definition at line 22 of file tablelayout.h.

◆ print_hierarchy()

template<typename T , typename TLabelFunc , typename TFindChildrenFunc , typename TPrintFunc >
void eu::core::print_hierarchy ( item,
TLabelFunc  label_func,
TFindChildrenFunc  find_children_func,
TPrintFunc  print_func,
const TreeStyle style = determine_style(),
const std::string &  a_indent = "",
int  index = 0,
bool  last = true 
)

Definition at line 64 of file ctree.h.

◆ print_table_grid()

void eu::core::print_table_grid ( std::ostream &  out,
const StringTable maintable 
)

Definition at line 269 of file table_string.cc.

◆ print_table_simple()

void eu::core::print_table_simple ( std::ostream &  out,
const StringTable maintable 
)

Definition at line 214 of file table_string.cc.

◆ remove_matching()

template<typename T , typename TFunc >
void eu::core::remove_matching ( std::vector< T > *  v,
TFunc  condition 
)

Definition at line 67 of file stdutils.h.

◆ render_identicon()

void eu::core::render_identicon ( Image image,
U32  code 
)

Definition at line 117 of file hashgen.identicon.cc.

◆ render_retro()

void eu::core::render_retro ( Image image,
U32  code 
)

Definition at line 81 of file hashgen.retro.cc.

◆ render_sprator() [1/2]

void eu::core::render_sprator ( Image image,
U32  code,
const Rgbai foreground_color = {NamedColor::white},
std::optional< Rgbai border_color_arg = std::nullopt,
const Rgbai background_color = {NamedColor::black, 0} 
)

Definition at line 284 of file hashgen.sprator.cc.

◆ render_sprator() [2/2]

void eu::core::render_sprator ( std::vector< Image > *  images,
U32  code,
const Rgbai foreground_color = {NamedColor::white},
std::optional< Rgbai border_color_arg = std::nullopt,
const Rgbai background_color = {NamedColor::black, 0} 
)

Definition at line 305 of file hashgen.sprator.cc.

◆ render_table()

std::vector< std::string > eu::core::render_table ( const Table< int > &  table,
const std::vector< std::string > &  characters 
)

Definition at line 165 of file drunken_bishop.cc.

◆ run_lut_transform()

template<typename C >
void eu::core::run_lut_transform ( Image image,
c 
)

Definition at line 202 of file imagefilters.cc.

◆ set_white_noise()

void eu::core::set_white_noise ( BoolTable world,
Lrud< BorderSetupRule border_control,
std::function< bool()>  rng 
)

Definition at line 10 of file table_bool.cc.

◆ shuffle()

template<typename T >
void eu::core::shuffle ( std::vector< T > *  v,
Random r 
)

Definition at line 18 of file knuthshuffle.h.

◆ sort_using_less()

template<typename T >
int eu::core::sort_using_less ( lhs,
rhs 
)

Definition at line 59 of file multisort.h.

◆ split_table_cells_on_newline()

StringTable eu::core::split_table_cells_on_newline ( const StringTable table,
StringTable::Idx  row 
)

Return a new table based on row, where each cell is split at newline over many rows.

Definition at line 198 of file table_string.cc.

◆ swap_back_and_erase_object()

template<typename T >
bool eu::core::swap_back_and_erase_object ( what,
std::vector< T > *  from 
)

Definition at line 46 of file stdutils.h.

◆ tint_color() [1/2]

Rgba eu::core::tint_color ( const Rgba c,
const Rgb tint 
)

Definition at line 481 of file image_draw.cc.

◆ tint_color() [2/2]

Rgbai eu::core::tint_color ( const Rgbai c,
const Rgbai tint 
)

Definition at line 486 of file image_draw.cc.

◆ to_bytes() [1/2]

std::vector< U8 > eu::core::to_bytes ( U32  hash)

Definition at line 33 of file drunken_bishop.cc.

◆ to_bytes() [2/2]

std::vector< U8 > eu::core::to_bytes ( U64  hash)

Definition at line 40 of file drunken_bishop.cc.

◆ to_bytes_generic()

template<typename T , int total_bytes>
std::vector<U8> eu::core::to_bytes_generic ( hash)

Definition at line 17 of file drunken_bishop.cc.

◆ to_codes() [1/2]

std::vector< int > eu::core::to_codes ( const std::vector< U8 > &  bytes,
bool  msb_first 
)

Definition at line 63 of file drunken_bishop.cc.

◆ to_codes() [2/2]

std::vector< int > eu::core::to_codes ( U8  byte,
bool  msb_first 
)

Definition at line 47 of file drunken_bishop.cc.

◆ to_key()

Key eu::core::to_key ( const std::string &  name)

Definition at line 339 of file key.cc.

◆ to_mouse_button()

MouseButton eu::core::to_mouse_button ( const std::string &  button)

Definition at line 351 of file key.cc.

◆ to_string() [1/4]

std::string eu::core::to_string ( const EnumValue v)

Definition at line 175 of file enum.cc.

◆ to_string() [2/4]

std::string eu::core::to_string ( Key  k)

Definition at line 333 of file key.cc.

◆ to_string() [3/4]

std::string eu::core::to_string ( MouseButton  button)

Definition at line 345 of file key.cc.

◆ to_string() [4/4]

std::string eu::core::to_string ( TokenType  t)

Definition at line 287 of file texttemplate.cc.

◆ to_strings()

std::vector< std::string > eu::core::to_strings ( const Table< char > &  table)

Definition at line 93 of file image_to_text.cc.

◆ to_time_t_wrapper()

TimetWrapper eu::core::to_time_t_wrapper ( const StructTmWrapper s,
TimeZone  timezone 
)

Definition at line 473 of file datetime.cc.

◆ tokenize()

std::vector<Token> eu::core::tokenize ( const std::string &  content,
TemplateErrorList error,
const io::FilePath file 
)

Definition at line 331 of file texttemplate.cc.

◆ write_image_data()

int eu::core::write_image_data ( stbi_write_func *  func,
void *  context,
int  w,
int  h,
int  comp,
const void *  data,
ImageWriteFormat  format,
int  jpeg_quality 
)

Definition at line 203 of file image.cc.

Variable Documentation

◆ ascii_style

constexpr TextBoxStyle eu::core::ascii_style
constexpr
Initial value:
= TextBoxStyle { [](char c) {
switch (c)
{
case bit_left:
case bit_right:
case bit_left | bit_right: return "-";
case bit_up:
case bit_down:
case bit_up | bit_down: return "|";
case bit_left | bit_up: return "'";
case bit_left | bit_down: return ".";
case bit_right | bit_up: return "`";
case bit_right | bit_down: return ",";
case bit_left | bit_right | bit_up | bit_down: return "+";
default:
DIE("Invalid combination");
return "X";
}
}}
#define DIE(message)
Definition: assert.h:67
constexpr unsigned char bit_down
Definition: textbox.h:14
constexpr unsigned char bit_up
Definition: textbox.h:13
constexpr unsigned char bit_right
Definition: textbox.h:16
constexpr unsigned char bit_left
Definition: textbox.h:15

Definition at line 112 of file textbox.h.

◆ bit_down

constexpr unsigned char eu::core::bit_down = 1 << 1
constexpr

Definition at line 14 of file textbox.h.

◆ bit_left

constexpr unsigned char eu::core::bit_left = 1 << 2
constexpr

Definition at line 15 of file textbox.h.

◆ bit_no_line

constexpr unsigned char eu::core::bit_no_line = static_cast<unsigned char>(~(bit_up | bit_down | bit_left | bit_right))
constexpr

Definition at line 17 of file textbox.h.

◆ bit_right

constexpr unsigned char eu::core::bit_right = 1 << 3
constexpr

Definition at line 16 of file textbox.h.

◆ bit_up

constexpr unsigned char eu::core::bit_up = 1 << 0
constexpr

Definition at line 13 of file textbox.h.

◆ cross_style

constexpr TreeStyle eu::core::cross_style
constexpr
Initial value:
{
.t_cross = "+- ",
.l = "+- ",
.down = "| ",
.space = " ",
.include_space = false,
.root_special = false
}

Definition at line 41 of file ctree.h.

◆ dawnbringer_palette

constexpr auto eu::core::dawnbringer_palette
constexpr
Initial value:
(
"Dawnbringer",
Rgbi::from_hex(0x140C1C),
Rgbi::from_hex(0x442434),
Rgbi::from_hex(0x30346D),
Rgbi::from_hex(0x4E4A4E),
Rgbi::from_hex(0x854C30),
Rgbi::from_hex(0x346524),
Rgbi::from_hex(0xD04648),
Rgbi::from_hex(0x757161),
Rgbi::from_hex(0x597DCE),
Rgbi::from_hex(0xD27D2C),
Rgbi::from_hex(0x8595A1),
Rgbi::from_hex(0x6DAA2C),
Rgbi::from_hex(0xD2AA99),
Rgbi::from_hex(0x6DC2CA),
Rgbi::from_hex(0xDAD45E),
Rgbi::from_hex(0xDEEED6)
)
constexpr StaticPalette< sizeof...(T)> make_static_palette(const std::string_view &name, T... colors)
Definition: palette.h:92

Definition at line 145 of file palette.h.

◆ named_colors_palette

constexpr auto eu::core::named_colors_palette
constexpr

Definition at line 166 of file palette.h.

◆ nil_guid

constexpr Guid eu::core::nil_guid
constexpr
Initial value:
= Guid
{
std::array<uint8_t, 16>
{
0, 0, 0, 0,
0, 0,
0, 0,
0, 0,
0, 0, 0, 0, 0, 0
}
}

Definition at line 25 of file guid.h.

◆ slash_style

constexpr TreeStyle eu::core::slash_style
constexpr
Initial value:
=
{
.t_cross = "|-",
.l = "\\-",
.down = "| ",
.space = " ",
.include_space = true,
.root_special = true
}

Definition at line 21 of file ctree.h.

◆ utf8_rounded_style

constexpr TextBoxStyle eu::core::utf8_rounded_style
constexpr
Initial value:
= TextBoxStyle{ [](char c) {
switch (c)
{
case bit_left:
case bit_right:
case bit_left | bit_right: return "─";
case bit_up:
case bit_down:
case bit_up | bit_down: return "│";
case bit_left | bit_up: return "╯";
case bit_left | bit_down: return "╮";
case bit_right | bit_up: return "╰";
case bit_right | bit_down: return "╭";
case bit_left | bit_right | bit_up: return "┴";
case bit_left | bit_right | bit_down: return "┬";
case bit_left | bit_up | bit_down: return "┤";
case bit_right | bit_up | bit_down: return "├";
case bit_left | bit_right | bit_up | bit_down: return "┼";
default:
DIE("Invalid combination");
return "X";
}
}}

Definition at line 64 of file textbox.h.

◆ utf8_straight_style

constexpr TextBoxStyle eu::core::utf8_straight_style
constexpr
Initial value:
= TextBoxStyle{ [](char c) {
switch (c)
{
case bit_left:
case bit_right:
case bit_left | bit_right: return "─";
case bit_up:
case bit_down:
case bit_up | bit_down: return "│";
case bit_left | bit_up: return "┘";
case bit_left | bit_down: return "┐";
case bit_right | bit_up: return "└";
case bit_right | bit_down: return "┌";
case bit_left | bit_right | bit_up: return "┴";
case bit_left | bit_right | bit_down: return "┬";
case bit_left | bit_up | bit_down: return "┤";
case bit_right | bit_up | bit_down: return "├";
case bit_left | bit_right | bit_up | bit_down: return "┼";
default:
DIE("Invalid combination");
return "X";
}
}}

Definition at line 40 of file textbox.h.

◆ utf8_tree_style

constexpr TreeStyle eu::core::utf8_tree_style
constexpr
Initial value:
=
{
.t_cross = "├╴",
.l = "└╴",
.down = "│ ",
.space = " ",
.include_space = true,
.root_special = true
}

Definition at line 31 of file ctree.h.

◆ utf_8double_line_style

constexpr TextBoxStyle eu::core::utf_8double_line_style
constexpr
Initial value:
= TextBoxStyle{ [](char c) {
switch (c)
{
case bit_left:
case bit_right:
case bit_left | bit_right: return "═";
case bit_up:
case bit_down:
case bit_up | bit_down: return "║";
case bit_left | bit_up: return "╝";
case bit_left | bit_down: return "╗";
case bit_right | bit_up: return "╚";
case bit_right | bit_down: return "╔";
case bit_left | bit_right | bit_up: return "╩";
case bit_left | bit_right | bit_down: return "╦";
case bit_left | bit_up | bit_down: return "╣";
case bit_right | bit_up | bit_down: return "╠";
case bit_left | bit_right | bit_up | bit_down: return "╬";
default:
DIE("Invalid combination");
return "X";
}
}}

Definition at line 88 of file textbox.h.