Back to godoc.org
golang.org/x/exp / shiny / driver / mtldriver

Package mtldriver

v0.0.0 (0022984)
Latest Go to latest
Published: May 13, 2020 | License: BSD-3-Clause | Module: golang.org/x/exp

Overview

Package mtldriver provides a Metal driver for accessing a screen.

At this time, the Metal API is used only to present the final pixels to the screen. All rendering is performed on the CPU via the image/draw algorithms. Future work is to use mtl.Buffer, mtl.Texture, etc., and do more of the rendering work on the GPU.

Index

Package Files

func Main

func Main(f func(screen.Screen))

Main is called by the program's main function to run the graphical application.

It calls f on the Screen, possibly in a separate goroutine, as some OS- specific libraries require being on 'the main thread'. It returns when f returns.

Documentation was rendered with GOOS=darwin and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier