Re: JOGL using vtkPanel on MacOS High Sierra

Sebastien Jourdain via vtkusers <[email protected]> Fri, 24 May 2019 09:02:01 -0600
Newsgroups gmane.comp.lib.vtk.user
Message-ID <CABObKxdxWGXAviQ2ZAq47inb53cLQsU_6dOVu-PUw5YXfn6byg@mail.gmail.com>
--===============1976134789==
Content-Type: multipart/alternative; boundary="000000000000346e930589a37dd7"

--000000000000346e930589a37dd7
Content-Type: text/plain; charset="UTF-8"

The PanelComponent is the "modern" implementation which allow to use
various backend (JOGL, swt, legacy) while providing a common API and much
more control on the event handling.

You might be able to fake your vtkPanel inheritance by creating an adapter
between the vtkJOGLPanelComponent and your custom rendering class.


On Fri, May 24, 2019 at 8:50 AM John L. Papp <[email protected]> wrote:

> Hello All,
>
> I've recently had to port a java wrapped VTK install to MacOSX High
> Sierra.  After extensive web searches, any Java JDK above 1.6 is missing
> some of the AWT libraries on which vtkPanel and such rely.  Instead, it
> was recommended to use JOGL.  I was able to compile VTK 8.2.0 with JOGL
> (I think) and the latest OpenJDK, which I think is version 12, but I can
> only go as high as 1.8 in the cmake input.  Anyway, the only interface
> is through vtkJoglPanelComponent and vtkJoglCanvasComponent.  There was
> talk about a vtkJoglPanel and vtkJoglCanvas that would wrap these other
> classes but these don't seem to be available in the 8.2.0 release.  I
> would like to avoid having to re-write my vtkPanel extended classes as
> I'm using a lot of the JPanel class functions that seem to be
> unavailable to the vtkJoglPanelComponent class. Is there a vtkJoglPanel
> class floating around or that just isn't the way things are done now.
> Perhaps it's as simple as replacing the renderer stored in vtkPanel with
> one from vtkJogPanelComponent, judging from what is done in in the
> JoglConeRendering example.  But, I'm not sure if this is the best way to
> do it, especially if someone else has already figured it out.  I've been
> avoiding upgrading past VTK 4.x because of these issues but am now at a
> point where it can't be helped.
>
> Thanks for any help,
>
> John
>
> --
> **************************************************************
> Dr. John Papp
> Senior Research Scientist
> CRAFT Tech.
> 6210 Kellers Church Road
> Pipersville, PA 18947
>
> Email:  [email protected]
> Phone:  (215) 766-1520
> Fax  :  (215) 766-1524
> Web  :  http://www.craft-tech.com
>
> **************************************************************
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Search the list archives at: http://markmail.org/search/?q=vtkusers
>
> Follow this link to subscribe/unsubscribe:
> https://vtk.org/mailman/listinfo/vtkusers
>

--000000000000346e930589a37dd7
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">The PanelComponent is the &quot;modern&quot; implementatio=
n which allow to use various backend (JOGL, swt, legacy) while providing a =
common API and much more control on the event handling.<div><br></div><div>=
You might be able to fake your vtkPanel inheritance by creating an adapter =
between the vtkJOGLPanelComponent and your custom rendering class.</div><di=
v><br></div></div><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"=
gmail_attr">On Fri, May 24, 2019 at 8:50 AM John L. Papp &lt;<a href=3D"mai=
lto:[email protected]">[email protected]</a>&gt; wrote:<br></div><blo=
ckquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left=
:1px solid rgb(204,204,204);padding-left:1ex">Hello All,<br>
<br>
I&#39;ve recently had to port a java wrapped VTK install to MacOSX High <br=
>
Sierra.=C2=A0 After extensive web searches, any Java JDK above 1.6 is missi=
ng <br>
some of the AWT libraries on which vtkPanel and such rely.=C2=A0 Instead, i=
t <br>
was recommended to use JOGL.=C2=A0 I was able to compile VTK 8.2.0 with JOG=
L <br>
(I think) and the latest OpenJDK, which I think is version 12, but I can <b=
r>
only go as high as 1.8 in the cmake input.=C2=A0 Anyway, the only interface=
 <br>
is through vtkJoglPanelComponent and vtkJoglCanvasComponent.=C2=A0 There wa=
s <br>
talk about a vtkJoglPanel and vtkJoglCanvas that would wrap these other <br=
>
classes but these don&#39;t seem to be available in the 8.2.0 release.=C2=
=A0 I <br>
would like to avoid having to re-write my vtkPanel extended classes as <br>
I&#39;m using a lot of the JPanel class functions that seem to be <br>
unavailable to the vtkJoglPanelComponent class. Is there a vtkJoglPanel <br=
>
class floating around or that just isn&#39;t the way things are done now.=
=C2=A0 <br>
Perhaps it&#39;s as simple as replacing the renderer stored in vtkPanel wit=
h <br>
one from vtkJogPanelComponent, judging from what is done in in the <br>
JoglConeRendering example.=C2=A0 But, I&#39;m not sure if this is the best =
way to <br>
do it, especially if someone else has already figured it out.=C2=A0 I&#39;v=
e been <br>
avoiding upgrading past VTK 4.x because of these issues but am now at a <br=
>
point where it can&#39;t be helped.<br>
<br>
Thanks for any help,<br>
<br>
John<br>
<br>
-- <br>
**************************************************************<br>
Dr. John Papp<br>
Senior Research Scientist<br>
CRAFT Tech.<br>
6210 Kellers Church Road<br>
Pipersville, PA 18947<br>
<br>
Email:=C2=A0 <a href=3D"mailto:[email protected]" target=3D"_blank">jpap=
[email protected]</a><br>
Phone:=C2=A0 (215) 766-1520<br>
Fax=C2=A0 :=C2=A0 (215) 766-1524<br>
Web=C2=A0 :=C2=A0 <a href=3D"http://www.craft-tech.com" rel=3D"noreferrer" =
target=3D"_blank">http://www.craft-tech.com</a><br>
<br>
**************************************************************<br>
<br>
_______________________________________________<br>
Powered by <a href=3D"http://www.kitware.com" rel=3D"noreferrer" target=3D"=
_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href=3D"http://www.kitware.c=
om/opensource/opensource.html" rel=3D"noreferrer" target=3D"_blank">http://=
www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href=3D"http://w=
ww.vtk.org/Wiki/VTK_FAQ" rel=3D"noreferrer" target=3D"_blank">http://www.vt=
k.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href=3D"http://markmail.org/search/?q=3Dvtk=
users" rel=3D"noreferrer" target=3D"_blank">http://markmail.org/search/?q=
=3Dvtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href=3D"https://vtk.org/mailman/listinfo/vtkusers" rel=3D"noreferrer" ta=
rget=3D"_blank">https://vtk.org/mailman/listinfo/vtkusers</a><br>
</blockquote></div>

--000000000000346e930589a37dd7--

--===============1976134789==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
https://vtk.org/mailman/listinfo/vtkusers

--===============1976134789==--