Code Monkey home page Code Monkey logo

Comments (14)

gedw99 avatar gedw99 commented on May 27, 2024 2

it works

โžœ  rajveermalviya git clone [email protected]:rajveermalviya/go-webgpu.git -b darwin-examples 
Cloning into 'go-webgpu'...
remote: Enumerating objects: 1513, done.
remote: Counting objects: 100% (139/139), done.
remote: Compressing objects: 100% (76/76), done.
remote: Total 1513 (delta 70), reused 118 (delta 60), pack-reused 1374
Receiving objects: 100% (1513/1513), 914.69 MiB | 7.06 MiB/s, done.
Resolving deltas: 100% (817/817), done.
Updating files: 100% (70/70), done.
โžœ  rajveermalviya ls
go-webgpu
โžœ  rajveermalviya cd go-webgpu 
โžœ  go-webgpu git:(darwin-examples) cd examples 
โžœ  examples git:(darwin-examples) cd triangle 
โžœ  triangle git:(darwin-examples) go build .
โžœ  triangle git:(darwin-examples) โœ— ./triangle 
[go-webgpu] [Warn] Surface does not support present mode: Mailbox, falling back to FIFO
[go-webgpu] [Warn] Surface does not support present mode: Mailbox, falling back to FIFO
[go-webgpu] [Warn] Surface does not support present mode: Mailbox, falling back to FIFO
[go-webgpu] [Warn] Surface does not support present mode: Mailbox, falling back to FIFO

Screenshot 2022-04-28 at 14 30 53

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024 1

though other examples (compute & capture) should be working.

Yes they did for me thanks.

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

https://github.com/rajveermalviya/go-webgpu/blob/main/.github/workflows/ci.yml#L25 prevents CI testing darwin ?

from go-webgpu.

rajveermalviya avatar rajveermalviya commented on May 27, 2024

I always hit "undefined: getSurfaceDescriptor" issue. See below.

yeah triangle & gio-windowing examples currently don't implement getSurfaceDescriptor for darwin (like for linux), though it can be easily implemented via SurfaceDescriptorFromMetalLayer, contributions welcome :).

though other examples (compute & capture) should be working.

prevents CI testing darwin ?

github actions runner doesn't have gpu & macos doesn't ship cpu based metal api implementation, so yeah

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

Hey @rajveermalviya

Yeah i saw the _linux.go version. and started to make _darwin version, but I could not work it out even with https://pkg.go.dev/github.com/rajveermalviya/go-webgpu/wgpu#SurfaceDescriptorFromMetalLayer. Sorry but i mostly do basic http stuff in golang.

DO you think you can write that code ?

I can test it at least locally here on my intel mac.

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

this might work for CI for Darwin and IOS, so i asked here: nektos/act#1143

from go-webgpu.

rajveermalviya avatar rajveermalviya commented on May 27, 2024

I can test it at least locally here on my intel mac.

I have created a PR #115 which adds support for glfw based triangle example.
Would appreciate if you can test it.

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

i can compile and run gio ios also if need be. If you get the gio window example working then it should work on ios i think. worth trying..

from go-webgpu.

rajveermalviya avatar rajveermalviya commented on May 27, 2024

it works

thanks for testing ๐ŸŽ‰

i can compile and run gio ios also if need be

it will first require ios builds of wgpu-native static libraries. will surely try too add them

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

cool. I can't believe you were able to code the darwin triangle without a MacOS to try it on. Impressive dude !!

from go-webgpu.

rajveermalviya avatar rajveermalviya commented on May 27, 2024

mostly thanks to zig cc's magic.
setting correct env for gopls & it provides linting in vscode.
it only goes as far as being able to build for macos on linux. still need a mac to run/test the binary.

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

thanks - i am def going to check out that link when i have a second... I heard of zig, but never had a reason to look into it deeper.

Still amazing either way.

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

hey @rajveermalviya

I just noticed there is an IOS lib now.

from go-webgpu.

gedw99 avatar gedw99 commented on May 27, 2024

Hey @rajveermalviya If you need MAC Testing again just let me know.

from go-webgpu.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.