question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Possible incompatibility with JavaFx

See original GitHub issue

Not sure where this problem lies, but I’ve been experiencing a core dump crash somewhere in libfreetype when JavaFx is initialized before rendering text using canvas drawString.

Ubuntu 18.04
openjdk version "12.0.1" 2019-04-16
OpenJDK Runtime Environment Zulu12.2+3-CA (build 12.0.1+12)
OpenJDK 64-Bit Server VM Zulu12.2+3-CA (build 12.0.1+12, mixed mode, sharing)

I am trying to use skija’s text rendering functionality. However, when JavaFx is initialized before trying to render with skija, the whole repl crashes with a core dump somewhere in libfreetype.

When I do the skija text rendering first, and then initialize JavaFx, things seem to work.

I have added a demo project here: https://github.com/mjmeintjes/skija-cljfx-crash-demo

If I execute (Platform/startup #(Platform/setImplicitExit false)) before (create-image-with-text), then the JVM crashes due to a crash in native code, somewhere in libfreetype.

However, if I execute (create-image-with-text) first, then I can run the startup code and then (create-image-with-text) can successfully run.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
mjmeintjescommented, Aug 10, 2021

Thanks, 0.92.30 seems to have fixed this issue for me as well.

0reactions
tonskycommented, Aug 9, 2021

Ok, I think we fixed it in 0.92.30. The core of the problem was Freetype, which was initialized both statically (us) and dynamically (JFX). I switched it to dynamic for Linux and the problem seems to be gone. Works on my Ubuntu 20.04. Please let me know if it bugs you again.

Read more comments on GitHub >

github_iconTop Results From Across the Web

java - JavaFX CSS incompatibility - Stack Overflow
Disclaimer: I'm very new to CSS. I am attempting to draw a box with a shadow, using css, in a Java application using...
Read more >
Why JavaFX 15 matters for you - Gluon
We want to make sure we keep supporting new hardware and software, with a focus on stability and backward compatibility. Companies that invested ......
Read more >
Compatibility Guide for JDK 8 - Oracle
This document discusses types of potential incompatibilities relating to the JDK 8 release of the Java platform.
Read more >
The Challenges of a JavaFX Reboot | InfoWorld
Many of the new features introduced in JavaFX 2.0 are incompatible with JavaFX 1.3. If you are developing a new application in JavaFX,...
Read more >
JavaFX Documentation Project - GitHub Pages
ImageView is a JavaFX Node that holds an Image object. ImageView makes an image available throughout the framework. An ImageView can be added...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found