AllenDang / giu

Cross platform rapid GUI framework for golang based on Dear ImGui.
MIT License
2.11k stars 127 forks source link

An error occurred while running the demo, why? #808

Closed farmer-simon closed 6 days ago

farmer-simon commented 6 days ago

What happend?

github.com/AllenDang/cimgui-go

C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\texture.go:15:9: undefined: TextureID C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:8:9: undefined: Vec2 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:16:9: undefined: Vec2 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:24:9: undefined: Vec2 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:32:9: undefined: Vec2 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:42:9: undefined: Vec4 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:42:21: undefined: Vec2 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:42:27: undefined: Vec4 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:52:9: undefined: Vec4 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:52:21: undefined: Vec2 C:\Users\Administrator\go\pkg\mod\github.com!allen!dang\cimgui-go@v0.0.0-20240611070805-39b5aa2438db\vector_helpers.go:52:21: too many errors

Code example

package main

import ( "fmt"

g "github.com/AllenDang/giu"

)

func onClickMe() { fmt.Println("Hello world!") }

func onImSoCute() { fmt.Println("Im sooooooo cute!!") }

func loop() { g.SingleWindow().Layout( g.Label("Hello world from giu"), g.Row( g.Button("Click Me").OnClick(onClickMe), g.Button("I'm so cute").OnClick(onImSoCute), ), ) }

func main() { wnd := g.NewMasterWindow("Hello world", 400, 200, g.MasterWindowFlagsNotResizable) wnd.Run(loop) }

To Reproduce

  1. Run my demo

Version

(latest)

OS

Windows 10

farmer-simon commented 6 days ago

resolved