Documentation
¶
Index ¶
- Constants
- type Dependency
- type IsRenderer
- type ManagesCameras
- type ManagesWindow
- type ProvidesRenderables
- type ProvidesTextures
- type Renderable
- type Service
- func (s *Service) AddCamera(name string) *rl.Camera2D
- func (s *Service) CacheBudget() int
- func (s *Service) ConfigFileName() string
- func (s *Service) DefaultConfig() (cfg configFile.Config)
- func (s *Service) ExportToLua(state *lua.LState)
- func (s *Service) FlushCache(newCache *cache.Cache)
- func (s *Service) GetCamera(name string) *rl.Camera2D
- func (s *Service) GetDefaultCamera() *rl.Camera2D
- func (s *Service) GetTexture(uuid uuid.UUID, img image.Image) (texture rl.Texture2D, isNew bool)
- func (s *Service) Init(mesh servicemesh.Mesh)
- func (s *Service) IsInit() bool
- func (s *Service) LoadConfig(config *configFile.Config)
- func (s *Service) Logger() *slog.Logger
- func (s *Service) Name() string
- func (s *Service) NewRenderable() Renderable
- func (s *Service) Ready() bool
- func (s *Service) RemoveCamera(name string)
- func (s *Service) Resolution() (width, height int)
- func (s *Service) SetLogger(logger *slog.Logger)
- func (s *Service) SetWindowTitle(title string)
- func (s *Service) UnexportFromLua(state *lua.LState)
- func (s *Service) WindowSize() (width, height int)
Constants ¶
View Source
const DefaultCameraName = ""
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Dependency ¶
type Dependency = IsRenderer
type IsRenderer ¶
type IsRenderer interface { IsInit() bool ManagesWindow ManagesCameras ProvidesTextures ProvidesRenderables }
type ManagesCameras ¶
type ManagesWindow ¶
type ProvidesRenderables ¶
type ProvidesRenderables interface {
NewRenderable() Renderable
}
type ProvidesTextures ¶
type Renderable ¶
type Renderable interface { UUID() uuid.UUID Destory() ZIndex() float32 SetZIndex(float32) Position() (x, y float32) SetPosition(x, y float32) Rotation() (degrees float32) SetRotation(degrees float32) Scale() (scale float32) SetScale(scale float32) Opacity() (opacity float32) SetOpacity(opacity float32) BlendMode() (mode rl.BlendMode) SetBlendMode(mode rl.BlendMode) Texture() rl.Texture2D SetTexture(rl.Texture2D) Image() image.Image SetImage(image.Image) Enable() Disable() IsEnabled() bool // contains filtered or unexported methods }
Renderable is a thing that the renderer provides to other services, which encapsulates the necessary behavior of something that can be rendered
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) CacheBudget ¶
func (*Service) ConfigFileName ¶
func (*Service) DefaultConfig ¶
func (s *Service) DefaultConfig() (cfg configFile.Config)
func (*Service) ExportToLua ¶
func (*Service) FlushCache ¶
func (*Service) GetDefaultCamera ¶
func (*Service) GetTexture ¶
func (*Service) Init ¶
func (s *Service) Init(mesh servicemesh.Mesh)
func (*Service) LoadConfig ¶
func (s *Service) LoadConfig(config *configFile.Config)
func (*Service) NewRenderable ¶
func (s *Service) NewRenderable() Renderable
func (*Service) RemoveCamera ¶
func (*Service) Resolution ¶
func (*Service) SetWindowTitle ¶
func (*Service) UnexportFromLua ¶
func (*Service) WindowSize ¶
Click to show internal directories.
Click to hide internal directories.