Skip to content

MacOS XQuartz #315

@natestone

Description

@natestone

I know that X11 on MacOS is unsupported according to the documentation, but I've been trying to get FluidX3D to run with INTERACTIVE_GRAPHICS by using XQuartz. Also, it may not be worth people's time for this because OpenCL is officially deprecated on MacOS. However, it is still present in Tahoe and runs on my M1 Max MacBook Pro.

FluidX3D compiles successfully by linking in the X11 libraries installed by XQuartz.

In "makefile", I maded the following changes:

 Line 15 Linux-X11 macOS: LDFLAGS_X11 = -I/opt/X11/include -I./src/X11/include
 Line 16 Linux Android: LDFLAGS_X11 =
 Line 17 
 Line 18 Linux-X11 macOS: LDLIBS_X11 = -L/opt/X11/lib -L./src/X11/lib -lX11 -lXrandr
 Line 19 Linux Android: LDLIBS_X11 =

Note the /opt/X11/lib and /opt/X11/include linking options and moving macOS to the Linux-X11 version. The code compiles fine and will run the benchmark without issue. When running the first example that uses X11 (INTERACTIVE_GRAPHICS), I get the following error:

./bin/FluidX3D
X Error of failed request:  BadRROutput (invalid Output parameter)
  Major opcode of failed request:  142 (RANDR)
  Minor opcode of failed request:  9 (RRGetOutputInfo)
  Serial number of failed request:  13
  Current serial number in output stream:  13

I'm trying to debug those issues now, but it looks like mismatches of screen resolutions or screen setup. If anyone has any insight into what those X errors mean, I would be grateful. XQuartz functions well on Mac for forwarding X sessions from Linux, etc. So, I think there is potential here.

If you have any insight into what those errors from X11 might mean, please let me know. Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions