Documentation
¶
Index ¶
- Constants
- func Draw_Tile(x, y, w, h int32, n int)
- func ImageFromFilePath(filePath string) (image.Image, error)
- func KeyCallback(w *glfw.Window, key glfw.Key, scancode int, action glfw.Action, ...)
- func Make_Plot(w, h int, user_data *Data_Info) (image.Image, error)
- func Play_Game(gs *game.GameState)
- func Pre_Render_Image(w, h int, png image.Image) uint32
- func Pre_Render_Text_Centered(w, h int, text string, c color.RGBA, fontFace font.Face) uint32
- func Visualize_Game(gs *game.GameState, driver_moves []game.Direction, move_time float32, ...)
- type Animation_State
- type Data_Info
- type Game_Driver
- type Game_Visual_State
- type Graph_Viz
- type Input_State
- type XY
- type XYData
Constants ¶
View Source
const ( W = 820 H = 820 MARGIN = 120 TILE_SIZE = 150 TILE_PADDING = 8 )
for Visulize_Game()
View Source
const NUMBER_OF_NUMBERS = 16
Variables ¶
This section is empty.
Functions ¶
func ImageFromFilePath ¶
@Todo not needed
func KeyCallback ¶
func Pre_Render_Image ¶
renders a text and loads it to the gpu, returns the texture_id
func Pre_Render_Text_Centered ¶
renders a text and loads it to the gpu, returns the texture_id
Types ¶
type Animation_State ¶
type Game_Driver ¶
type Game_Visual_State ¶
type Game_Visual_State struct { Window *glfw.Window Destroyed bool Game *game.GameState Driver *Game_Driver GameTime float64 // contains filtered or unexported fields }
func New_Game_Visual ¶
func New_Game_Visual(gs *game.GameState, driver *Game_Driver) *Game_Visual_State
the driver can be 'nil' then it is just interactable if driver is provided, we use it to play the game (for now it's just a struct that defines some variables)
func (*Game_Visual_State) Update_And_Draw ¶
func (gvc *Game_Visual_State) Update_And_Draw()
type Graph_Viz ¶
type Graph_Viz struct { UserData *Data_Info // here the data should be set/updated by the user before Update_And_Draw() Window *glfw.Window W, H int Destroyed bool Initted bool // contains filtered or unexported fields }
func (*Graph_Viz) Update_And_Draw ¶
func (gv *Graph_Viz) Update_And_Draw()
type Input_State ¶
Click to show internal directories.
Click to hide internal directories.