cmdfx 1.0.1
Lightweight game engine for your terminal
Loading...
Searching...
No Matches
CmdFX Namespace Reference

Primary namespace for CmdFX. More...

Namespaces

namespace  Builder
 C++ wrapper for the CmdFX Builder API.
namespace  Canvas
 C++ wrapper for the CmdFX canvas.
namespace  Device
 C++ wrapper for the CmdFX Device API.
namespace  SceneEngine
 Scene Engine functions.
namespace  Screen
 C++ wrapper for the CmdFX Screen API.
namespace  Window
 C++ wrapper for the CmdFX Window API.
namespace  Engine
 A C++ wrapper around the CmdFX Physics Engine.
namespace  SpriteForces
 A C++ wrapper around Sprite forces.
namespace  Sound
 A C++ Wrapper around the sound engine declarations.

Classes

class  SpriteCostumes
 A C++ wrapper around a CmdFX_SpriteCostumes struct. More...
class  Scene
 A C++ wrapper around a CmdFX_Scene struct. More...
class  Sprite
 A C++ wrapper around a CmdFX_Sprite struct. More...
class  SpriteMass
 A C++ wrapper around a CmdFX_SpriteMass struct. More...
class  SpriteMotion
 A C++ wrapper around a CmdFX_Sprite struct for motion-related functions. More...
class  Vector
 A C++ wrapper around a CmdFX_Vector struct. More...
class  Button
 A C++ wrapper around the CmdFX_Button struct. More...
class  SceneButtons
class  Switch
 A C++ wrapper around the CmdFX_Button struct for switch buttons. More...

Functions

int getWidth (char **array)
int getWidth (char ***array)
int getHeight (char **array)
int getHeight (char ***array)
char ** createCopy (char **array)
char *** createCopy (char ***array)
int isSameSize (char **array1, char **array2)
int isSameSize (char ***array1, char ***array2)
int compare (char **array1, char **array2)
int compare (char ***array1, char ***array2)
int print (char **array)
int print (char ***array)
char ** to2DArray (std::vector< std::string > string)
 Converts a 1D vector of strings to a 2D array of characters.
char *** to3DArray (std::vector< std::vector< std::string > > string)
 Converts a 2D vector of strings to a 3D array of characters.
int resetAllCostumes ()
int getTickSpeed ()
int setTickSpeed (int tickspeed)
unsigned long currentTimeMillis ()
unsigned long long currentTimeNanos ()
void sleepMillis (unsigned long millis)
void sleepNanos (unsigned long long nanos)
double clamp (double value, double min, double max)
float clamp (float value, float min, float max)
int clamp (int value, int min, int max)
double lerp (double a, double b, double t)
float lerp (float a, float b, float t)
int lerp (int a, int b, double t)
void rgbToHsv (int rgb, double *h, double *s, double *v)
int hsvToRgb (double h, double s, double v)
int lerpColor (int rgb1, int rgb2, double t)
ThreadID launchThread (void(*func)(void *), void *arg)
int joinThread (ThreadID thread)
int detachThread (ThreadID thread)
void * getInternalMutex (int id)
int lockMutex (void *mutex)
int unlockMutex (void *mutex)
void tryLockMutex (int id)
void tryUnlockMutex (int id)
int isThreadSafeEnabled ()
int initThreadSafe ()
int destroyThreadSafe ()

Detailed Description

Primary namespace for CmdFX.

This is the main namespace for the CmdFX library. All classes and functions are defined within this namespace. The CmdFX library is designed to provide a simple and easy-to-use interface for creating graphics and animations in the terminal.

Function Documentation

◆ to2DArray()

char ** CmdFX::to2DArray ( std::vector< std::string > string)

Converts a 1D vector of strings to a 2D array of characters.

Parameters
stringThe vector of strings to convert.
Returns
char** The 2D array of characters.

◆ to3DArray()

char *** CmdFX::to3DArray ( std::vector< std::vector< std::string > > string)

Converts a 2D vector of strings to a 3D array of characters.

Parameters
stringThe vector of strings to convert.
Returns
char*** The 3D array of characters.