Skip to content

Commit

Permalink
app: fix windows build
Browse files Browse the repository at this point in the history
Signed-off-by: Egon Elbre <[email protected]>
  • Loading branch information
egonelbre authored and eliasnaur committed Jul 19, 2023
1 parent ddf770b commit d62057a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/d3d11_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ type d3d11Context struct {
width, height int
}

const debug = false
const debugDirectX = false

func init() {
drivers = append(drivers, gpuAPI{
priority: 1,
initializer: func(w *window) (context, error) {
hwnd, _, _ := w.HWND()
var flags uint32
if debug {
if debugDirectX {
flags |= d3d11.CREATE_DEVICE_DEBUG
}
dev, ctx, _, err := d3d11.CreateDevice(
Expand Down Expand Up @@ -122,7 +122,7 @@ func (c *d3d11Context) Release() {
d3d11.IUnknownRelease(unsafe.Pointer(c.dev), c.dev.Vtbl.Release)
}
*c = d3d11Context{}
if debug {
if debugDirectX {
d3d11.ReportLiveObjects()
}
}
Expand Down

0 comments on commit d62057a

Please sign in to comment.