# VTK + Java + Mac + Swing

**URL:** https://discourse.vtk.org/t/vtk-java-mac-swing/2794
**Category:** Support
**Created:** [March 10, 2020, 5:44pm UTC](https://discourse.vtk.org/t/vtk-java-mac-swing/2794 "2020-03-10T17:44:23Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![Marco](https://discourse.vtk.org/user_avatar/discourse.vtk.org/marco/32/1461_2.png) [@Marco](https://discourse.vtk.org/u/Marco)
#### Post date: [March 19, 2020, 9:09pm UTC](https://discourse.vtk.org/t/vtk-java-mac-swing/2794/4 "2020-03-19T21:09:00Z")

</div>

Hello,

I will also need to “fight” with VTK + Java + JOGL + Swing on Mac in the upcoming weeks, so maybe I will be able to share my experience on that environment as well.

As of now, I am working with JOGL on Windows, and I am already encountering some issues unfortunately (see [Rendering/interaction issues with VTK 8.2 (Java) + JOGL on Windows](https://discourse.vtk.org/t/rendering-interaction-issues-with-vtk-8-2-java-jogl-on-windows/2781) for details).

Regarding your problem, you told that the Swing GUI will block if you launch your application with the “-XstartOnFirstThread” JVM parameter. Can you provide more details? When will the Swing GUI block? As soon as the Swing GUI shows up on screen? Will it lock forever, or what?

Please provide some more details, I will check if I have suggestions to provide.

Also, you may want to take a look at this thread:

> [@vtk8.2 build/run problems on Mac with Java](https://discourse.vtk.org/t/vtk8-2-build-run-problems-on-mac-with-java/932):
>
> I can successfully build vtk8.2 on mac. However, when I go to run the JoglConeRendering demo, I get the attached core dump. [hs\_err\_pid93111.log](https://discourse.vtk.org/uploads/default/original/1X/3cec68cd637ea2da39990ea1cc76816016fccae8.log) (77.8 KB) If I run things with the vtk8.1 prepackaged jar and libs that @Sebastien_Jourdain sent me, this works fine. So I’m confused why we’re getting a crash. I thought it might have something to do with our patching I’ve talked about in other posts, but clearly it doesn’t. For completeness, here’s the portion of the (modified) build script from t…

Not sure if this user was indeed using Swing in his application, but it looks like he was successful in having VTK 8.2 + Java + JOGL to work under macOS.

Best regards,

Marco Sambin

---

_[View the full topic](https://discourse.vtk.org/t/vtk-java-mac-swing/2794)._
