I am attempting to save an image using the image.writetostream.
In the B4J Win debugger it works but when run in Raspberry Pi 3 it throws the following errors:-
Here is the code I am using
Any help greatly appreciated.
Peter V
In the B4J Win debugger it works but when run in Raspberry Pi 3 it throws the following errors:-
B4X:
main._mprint (java line: 1205)
java.lang.NoClassDefFoundError: javafx/embed/swing/SwingFXUtils
at anywheresoftware.b4j.objects.ImageViewWrapper$ImageWrapper.WriteToStream(ImageViewWrapper.java:177)
at b4j.example.main._mprint(main.java:1205)
at b4j.example.main._mm_action(main.java:1089)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:93)
at anywheresoftware.b4a.BA$2.run(BA.java:165)
at com.sun.javafx.application.PlatformImpl.lambda$null$170(PlatformImpl.java:295)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$171(PlatformImpl.java:294)
at com.sun.glass.ui.monocle.RunnableProcessor.runLoop(RunnableProcessor.java:92)
at com.sun.glass.ui.monocle.RunnableProcessor.run(RunnableP
rocessor.java:51)
at java.lang.Thread.run(Thread.java:745)
etc
... 15 more
Here is the code I am using
B4X:
Dim Bitmap1 As Image
Dim out As OutputStream
Bitmap1 = Ctx.Snapshot
out = File.OpenOutput(File.DirApp,"test.png",False)
Bitmap1.WriteToStream(out)
out.Close
Any help greatly appreciated.
Peter V