-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use OpenGL ES 3.0 in qemu_egl_init_ctx #35
base: master
Are you sure you want to change the base?
Conversation
Thanks for the patch! And this is probably something you may want to let him know as well here: https://gist.github.com/akihikodaki/87df4149e7ca87f18dc56807ec5a1bc5 |
The problems you see may also be because I use libangle from a few months ago. It’s possible that they’ve caught up with the metal backend. |
cdd3aca
to
8f364ec
Compare
I'm going to build this today and see if it's been improved (need 3.0 for Dolphin-emu). |
Hmmm... after manually upgrading, I'm still on OpenGL 2. |
For some reason, the patch didn't apply. Is there a way to force it to apply? |
you can test this patch with open |
I did, and it wouldn't boot anymore.
…On Tue, Sep 28, 2021 at 6:56 PM rinsuki ***@***.***> wrote:
you can test this patch with open /usr/local/Cellar/qemu-virgl/*/bin/qemu-system-(your
arch) in hex editor (like Hex Fiend <https://github.com/HexFiend/HexFiend>)
and modify 98 30 00 00 02 00 00 00 to 98 30 00 00 03 00 00 00 (98 30 00 00
= 32bit little endian int of EGL_CONTEXT_CLIENT_VERSION a.k.a. 0x3098)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALXWUYCWUTKXSCFAICE4UNLUEJB2VANCNFSM5AWR2BCA>
.
|
humm, it should work... (you can retry with btw, why you want to run Linux version of Dolphin Emulator in macOS? Dolphin Emulator already have a macOS native version (even arm64), and it works great for me. |
Oh, really? That's nice. But I do most of my work in Linux, so it
would be nice to have integration.
…On Tue, Sep 28, 2021 at 7:56 PM rinsuki ***@***.***> wrote:
humm, it should work... (you can retry with brew reinstall qemu-virgl)
btw, why you want to running Linux version of Dolphin Emulator in macOS? Dolphin Emulator already have a macOS native version (even arm64), and it works great for me.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
The hex edit should work for the `aarch64` binary compiled for the M1
chip, right?
…On Tue, Sep 28, 2021 at 7:59 PM DUO Labs ***@***.***> wrote:
Oh, really? That's nice. But I do most of my work in Linux, so it
would be nice to have integration.
On Tue, Sep 28, 2021 at 7:56 PM rinsuki ***@***.***> wrote:
>
> humm, it should work... (you can retry with brew reinstall qemu-virgl)
>
> btw, why you want to running Linux version of Dolphin Emulator in macOS? Dolphin Emulator already have a macOS native version (even arm64), and it works great for me.
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub, or unsubscribe.
|
Oh, it seems that for the M1 chip, binaries must be signed, and
editing it breaks the signature.
…On Tue, Sep 28, 2021 at 8:03 PM DUO Labs ***@***.***> wrote:
The hex edit should work for the `aarch64` binary compiled for the M1
chip, right?
On Tue, Sep 28, 2021 at 7:59 PM DUO Labs ***@***.***> wrote:
>
> Oh, really? That's nice. But I do most of my work in Linux, so it
> would be nice to have integration.
>
> On Tue, Sep 28, 2021 at 7:56 PM rinsuki ***@***.***> wrote:
> >
> > humm, it should work... (you can retry with brew reinstall qemu-virgl)
> >
> > btw, why you want to running Linux version of Dolphin Emulator in macOS? Dolphin Emulator already have a macOS native version (even arm64), and it works great for me.
> >
> > —
> > You are receiving this because you commented.
> > Reply to this email directly, view it on GitHub, or unsubscribe.
|
I resigned it, but get an error: "Abort trap: 6"
…On Tue, Sep 28, 2021 at 8:04 PM DUO Labs ***@***.***> wrote:
Oh, it seems that for the M1 chip, binaries must be signed, and
editing it breaks the signature.
On Tue, Sep 28, 2021 at 8:03 PM DUO Labs ***@***.***> wrote:
>
> The hex edit should work for the `aarch64` binary compiled for the M1
> chip, right?
>
> On Tue, Sep 28, 2021 at 7:59 PM DUO Labs ***@***.***> wrote:
> >
> > Oh, really? That's nice. But I do most of my work in Linux, so it
> > would be nice to have integration.
> >
> > On Tue, Sep 28, 2021 at 7:56 PM rinsuki ***@***.***> wrote:
> > >
> > > humm, it should work... (you can retry with brew reinstall qemu-virgl)
> > >
> > > btw, why you want to running Linux version of Dolphin Emulator in macOS? Dolphin Emulator already have a macOS native version (even arm64), and it works great for me.
> > >
> > > —
> > > You are receiving this because you commented.
> > > Reply to this email directly, view it on GitHub, or unsubscribe.
|
humm, I'm still using Intel Mac, then I can't help problem about M1 Mac... |
Although my real question was how to apply the patch, which brew doesn't
seem to be doing. If I change the file egl-helpers.c before it is compiled,
ninja just hangs forever.
…On Tue, Sep 28, 2021 at 8:24 PM rinsuki ***@***.***> wrote:
humm, I'm still using Intel Mac, then I can't help problem about M1 Mac...
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALXWUYAZSCPIHFYATOBFCO3UEJMC7ANCNFSM5AWR2BCA>
.
|
it should work, but I'm not tested. |
It fails with "patch unexpectedly ends in middle of line
Hunk #1 succeeded at 474 with fuzz 1 (offset 12 lines)".
…On Tue, Sep 28, 2021 at 8:45 PM rinsuki ***@***.***> wrote:
1. brew edit qemu-virgl
2. Add new patch section with patch
https://raw.githubusercontent.com/knazarov/homebrew-qemu-virgl/02464311b4cca56f400132f4993488f10e5928e7/Patches/qemu-usegles3-v01.diff
3. brew reinstall --build-from-source qemu-virgl
it should work, but I'm not tested.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALXWUYCEU5SVQGXPX5K57MDUEJOTPANCNFSM5AWR2BCA>
.
|
uuh sorry, diff requires LF in last line of patch. can you retry with this patch https://raw.githubusercontent.com/knazarov/homebrew-qemu-virgl/ebbc42bb0c0ce8c4604d67ad28b40603c5b62507/Patches/qemu-usegles3-v01.diff ? |
Now it says, "Hunk #1 succeeded at 474 (offset 12 lines).", but the file didn't update. |
After building, it still says OpenGL 2.1. |
what about OpenGL ES version? (OpenGL without ES and OpenGL ES is different things) |
"OpenGL ES profile version string: OpenGL ES 3.0 Mesa 21.2.1". So, I think it worked. |
currently, OpenGL 3.0 backend for OpenGL ES 3.x is not exists (gl4es only supports OpenGL 2.x). if you want to use OpenGL 3.x in VM, currently option are use and I think, for dolphin emulator, native macOS version are good choice, because it has a Metal support w/ MoltenVK. |
Yeah, but is there any way to share a MacOS window to Linux, so it could be more integrated? |
Also, |
in my knowledge, there is a no way to share macOS window to Linux in same machine. If you can accept proprietary things, Parallels or VMware Fusion may good choice because they have hardware-accelerated OpenGL Desktop in VM even M1 Mac. VMware Fusion for M1 is currently Tech Preview and free for several months (but it requires register to VMware ID), also Parallels provides free-trial. |
Yeah, I've tried Parallels, very good (even provide camera and microphone),
but the payment turned me off.
…On Tue, Sep 28, 2021 at 10:48 PM rinsuki ***@***.***> wrote:
in my knowledge, there is a no way to share macOS window to Linux in same
machine.
If you can accept proprietary things, Parallels or VMware Fusion may good
choice because they have hardware-accelerated OpenGL Desktop in VM even M1
Mac. VMware Fusion for M1 is currently Tech Preview and free for several
months (but it requires register to VMware ID), also Parallels provides
free-trial.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALXWUYGOQ2JKHJ2FXEY74FLUEJ47DANCNFSM5AWR2BCA>
.
|
Will this be merged soon? |
in ANGLE Metal backend (you can enable with
ANGLE_DEFAULT_PLATFORM=metal
), qemu-system-x86_64 shows this error:because these shaders (at https://github.com/qemu/qemu/tree/266469947161aa10b1d36843580d369d5aa38589/ui/shader ) are marked as
#version 300 es
, that means it requires OpenGL ES 3.0. but qemu_egl_init_ctx initializes EGL with OpenGL ES 2.0, then shader compile will fails.in this pull-request, modify qemu_egl_init_ctx to use OpenGL ES 3.0.
but even after this patch applied, many parts are broken and not suitable for general-use currently. e.g. Android-x86 but text and other components are gone 😝
NOTE: this pull-request not adding patches to qemu-virgl.rb because I can't get
https://raw.githubusercontent.com/knazarov/homebrew-qemu-virgl/...
URL before merge it.