1
1
mirror of https://github.com/OpenDiablo2/OpenDiablo2 synced 2024-11-20 03:16:26 -05:00
OpenDiablo2/d2common/d2interface/renderer.go
dk 60e6fcb7ac
moving enumerations out of d2interface (#552)
* moved filter constants back to d2enum

* moving key and mouse button enums into d2enum

* moving render type enum into d2enum

* moving input even priority enums into d2enum

* moving terminal enums into d2enum
2020-07-06 21:26:08 -04:00

20 lines
596 B
Go

package d2interface
import "github.com/OpenDiablo2/OpenDiablo2/d2common/d2enum"
// Renderer interface defines the functionality of a renderer
type Renderer interface {
GetRendererName() string
SetWindowIcon(fileName string)
Run(f func(Surface) error, width, height int, title string) error
IsDrawingSkipped() bool
CreateSurface(surface Surface) (Surface, error)
NewSurface(width, height int, filter d2enum.Filter) (Surface, error)
IsFullScreen() bool
SetFullScreen(fullScreen bool)
SetVSyncEnabled(vsync bool)
GetVSyncEnabled() bool
GetCursorPos() (int, int)
CurrentFPS() float64
}