if you check out the plan9 branch of [email protected]:plan9foundation/ebiten.git,
and you cd to examples/cursor, you can
GOOS=plan9 GOARCH=amd64 go build
you'll get a plan 9 binary.
You can run it; it won't end well. All the functions you need to implement
(48 of them) are stubbed out to panic.
This is pretty much how I port unknown Go or C code to 9: stub out the
stuff I don't know how to do with panic (or for that matter, Plan 9 to a
new architecture, or
when we ported Plan 9 code to Akaros).
Here are the functions.
internal/ui/input_plan9.go:func (u *UserInterface)
updateInputStateFromOutside(keyPressedTimes, keyReleasedTimes [KeyMax +
1]InputTime, runes []rune, touches []TouchForInput) {
internal/ui/input_plan9.go:func (u *UserInterface)
updateInputStateForFrame() error {
internal/ui/input_plan9.go:func (u *UserInterface) KeyName(key Key) string {
internal/ui/ui_plan9.go:func (g *graphicsDriverCreatorImpl) newAuto()
(graphicsdriver.Graphics, GraphicsLibrary, error) {
internal/ui/ui_plan9.go:func (g *graphicsDriverCreatorImpl) newOpenGL()
(graphicsdriver.Graphics, error) {
internal/ui/ui_plan9.go:func (*graphicsDriverCreatorImpl) newDirectX()
(graphicsdriver.Graphics, error) {
internal/ui/ui_plan9.go:func (g *graphicsDriverCreatorImpl) newMetal()
(graphicsdriver.Graphics, error) {
internal/ui/ui_plan9.go:func (*graphicsDriverCreatorImpl) newPlayStation5()
(graphicsdriver.Graphics, error) {
internal/ui/ui_plan9.go:func (u *UserInterface) SetUIView(uiview uintptr)
error {
internal/ui/ui_plan9.go:func (u *UserInterface) IsGL() (bool, error) {
internal/ui/ui_plan9.go:func dipToNativePixels(x float64, scale float64)
float64 {
internal/ui/ui_plan9.go:func dipFromNativePixels(x float64, scale float64)
float64 {
internal/ui/ui_plan9.go:func (u *UserInterface) displayInfo() (int, int,
float64, bool) {
internal/ui/ui_plan9.go:func (u *UserInterface) init() error {
internal/ui/ui_plan9.go:func (u *UserInterface) Update() error {
internal/ui/ui_plan9.go:func (u *UserInterface) SetForeground(foreground
bool) error {
internal/ui/ui_plan9.go:func (u *UserInterface) RunWithoutMainLoop(game
Game, options *RunOptions) {
internal/ui/ui_plan9.go:func (u *UserInterface) runMobile(game Game,
options *RunOptions) (err error) {
internal/ui/ui_plan9.go:func (u *UserInterface) outsideSize() (float64,
float64) {
internal/ui/ui_plan9.go:func (u *UserInterface) update() error {
internal/ui/ui_plan9.go:func (u *UserInterface)
SetOutsideSize(outsideWidth, outsideHeight float64) {
internal/ui/ui_plan9.go:func (u *UserInterface) CursorMode() CursorMode {
internal/ui/ui_plan9.go:func (u *UserInterface) SetCursorMode(mode
CursorMode) {
internal/ui/ui_plan9.go:func (u *UserInterface) CursorShape() CursorShape {
internal/ui/ui_plan9.go:func (u *UserInterface) SetCursorShape(shape
CursorShape) {
internal/ui/ui_plan9.go:func (u *UserInterface) IsFullscreen() bool {
internal/ui/ui_plan9.go:func (u *UserInterface) SetFullscreen(fullscreen
bool) {
internal/ui/ui_plan9.go:func (u *UserInterface) IsFocused() bool {
internal/ui/ui_plan9.go:func (u *UserInterface) IsRunnableOnUnfocused()
bool {
internal/ui/ui_plan9.go:func (u *UserInterface)
SetRunnableOnUnfocused(runnableOnUnfocused bool) {
internal/ui/ui_plan9.go:func (u *UserInterface) FPSMode() FPSModeType {
internal/ui/ui_plan9.go:func (u *UserInterface) SetFPSMode(mode
FPSModeType) {
internal/ui/ui_plan9.go:func (u *UserInterface)
updateExplicitRenderingModeIfNeeded(fpsMode FPSModeType) {
internal/ui/ui_plan9.go:func (u *UserInterface) readInputState(inputState
*InputState) {
internal/ui/ui_plan9.go:func (u *UserInterface) Window() Window {
internal/ui/ui_plan9.go:func (m *Monitor) Name() string {
internal/ui/ui_plan9.go:func (m *Monitor) ensureValues() monitor {
internal/ui/ui_plan9.go:func (m *Monitor) DeviceScaleFactor() float64 {
internal/ui/ui_plan9.go:func (m *Monitor) Size() (int, int) {
internal/ui/ui_plan9.go:func (u *UserInterface) AppendMonitors(mons
[]*Monitor) []*Monitor {
internal/ui/ui_plan9.go:func (u *UserInterface) Monitor() *Monitor {
internal/ui/ui_plan9.go:func (u *UserInterface)
UpdateInput(keyPressedTimes, keyReleasedTimes [KeyMax + 1]InputTime, runes
[]rune, touches []TouchForInput) {
internal/ui/ui_plan9.go:func (u *UserInterface) SetRenderer(renderer
Renderer) {
internal/ui/ui_plan9.go:func (u *UserInterface) ScheduleFrame() {
internal/ui/ui_plan9.go:func (u *UserInterface) updateIconIfNeeded() error {
internal/ui/ui_plan9.go:func IsScreenTransparentAvailable() bool {
internal/ui/ui_plan9.go:func (u *UserInterface) initOnMainThread(options
*RunOptions) error {
internal/ui/ui_plan9.go:func (u *UserInterface) loopGame() error {
On Sat, Dec 13, 2025 at 12:25 PM ron minnich <[email protected]> wrote:
> https://github.com/hajimehoshi/ebiten
>
> I'm going to take a shot at turning off all linux dependencies, which
> should remove GL dependencies, and see what's missing. But a look at the
> graphics used on other platforms said to me that it doesn't demand too much.
>
> On Fri, Dec 12, 2025 at 1:07 PM Clout Tolstoy <[email protected]>
> wrote:
>
>> npe looks like it has limited sdl2 support. That seems how you could get
>> along the fastest without having to refactor image drawing, and IO to
>> plan9 abstractions. Ebitengine requires a bit of C libraries that are
>> unavailable on plan9/9front.
>>
>> Mainly referring to this data structure
>>
>> https://github.com/hajimehoshi/ebiten/blob/7d0692124a95528ee624ab641104e7a7bf1cb4b2/internal/graphicscommand/image.go#L31
>>
>> I'm not sure which (raylib/ebiten) would feel more daunting to port
>> because of those dependencies.
>>
>> If you have a source repo of your efforts, I can try on a rpi0 or rpi4.
>>
>> Best of luck and sorry for the slight derail.
>>
>> Clout
>>
>>
>>
>>
>> On Thu, Dec 11, 2025, 8:37 PM ron minnich <[email protected]> wrote:
>>
>>> My goal, for 9, was to look into a pure Go 2D game engine, to see if it
>>> would work. This discussion spiraled off into thousands of other paths, as
>>> things on this list are wont to do :-)
>>>
>>> But I'm still wondering if the 2D game engine in Go could work. I think
>>> I'd better go look.
>>>
>>> On Thu, Dec 11, 2025 at 8:33 PM Noam Preil <[email protected]> wrote:
>>>
>>>> Fwiw if the goal is something like this on 9, raylib is likely a much
>>>> better choice. It can render entirely in software, to a framebuffer, iirc,
>>>> and is entirely in C.
>>>>
>>> *9fans <https://9fans.topicbox.com/latest>* / 9fans / see discussions
>> <https://9fans.topicbox.com/groups/9fans> + participants
>> <https://9fans.topicbox.com/groups/9fans/members> + delivery options
>> <https://9fans.topicbox.com/groups/9fans/subscription> Permalink
>> <https://9fans.topicbox.com/groups/9fans/T33e3d4a8f04a347f-Mc197848348c7bc5e495db932>
>>
------------------------------------------
9fans: 9fans
Permalink:
https://9fans.topicbox.com/groups/9fans/T33e3d4a8f04a347f-Mf117e99d783bce7790fcfcd5
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription