1
1
mirror of https://github.com/OpenDiablo2/OpenDiablo2 synced 2024-06-30 11:05:23 +00:00
OpenDiablo2/d2core/d2render/surface.go
Ziemas b00fa58fc4
Object Highlights (#476)
* Add PushBrightness to surface

* Highlight selectable objects

Check if mapentity is selectable. (seems reasonable)
Request objects to highlight themselves is required (idk)
2020-06-27 18:58:41 -04:00

26 lines
567 B
Go

package d2render
import (
"image"
"image/color"
)
type Surface interface {
Clear(color color.Color) error
DrawRect(width, height int, color color.Color)
DrawLine(x, y int, color color.Color)
DrawText(format string, params ...interface{})
GetSize() (width, height int)
GetDepth() int
Pop()
PopN(n int)
PushColor(color color.Color)
PushCompositeMode(mode CompositeMode)
PushFilter(filter Filter)
PushTranslation(x, y int)
PushBrightness(brightness float64)
Render(surface Surface) error
ReplacePixels(pixels []byte) error
Screenshot() *image.RGBA
}