IMPORTANT: API Changes to the com.xith3d.userinterface package (RFC)

Hi,

I have been threatening for a while to move the userinterface package out of the core and into the toolkit for two reasons:
a) this will open it to more community development
b) it really doesn’t need to be in the core

I only realised when I tried to move the code that in fact there were references to the code in View.java and Canvas3D.java. Fortunately these were not critical and I have found a way to make it work without this coupling. Unfortunately a side-effect of this is that the API has changed (beyond just the package rename).

There are three changes you will need to make to your code if you use this package. They are detailed here: http://xith.org/SwingUIChanges

I have created an experimental build encorporating these changes: http://xith.org/download/builds/2005-09-24_experimental-swingui/Xith3D_2005-09-24_experimental-swingui.tar.gz

You will need to include the xith-tk.jar file in your classpath.

I believe that so long as you make the threechanges I have said, your code shouldwork perfectly. I will wait a few days to allow for comments before committing this change. The “Xith3DGuiTest” has been updated (and moved to the org.xith3d.test package) to reflect these changes. Prior to comitting I will update the package level javadocs to reflect the new aim of the package. There are no plans to keep the deprecate the old package, it will simply be removed.

This package needs a maintainer. If you want to take it on board, be my guest! I believe the concept is very sound, we just need someone who can commit themselves to bugfixes :slight_smile:

I hope this annoucement is a satisfactory warning to users of this package. If you have any issues with these changes please raise them in this thread ASAP.

Regards,

Will.

These changes have been applied.

More information, and a perminent record of these changes is located here: http://xith.org/SwingUIChanges

Will.

OK, I made the changes and it worked in my project.

At first I was having a problem with flickering and scaling during animation. I had the call to newFrame() after renderOnce() instead of the other way around as your instructions recommend. When I fixed that and it start working fine.

Hi,

Thanks for your feedback, I am glad it worked eventually.

That is odd regarding the newFrame business, I analysed the source code and to me it looked like it would have been called before the scene was rendered. That said, the userinterface package is not one I fully understand (partly why it is now in the toolkit). I will be interested to hear the results of others making the change. I shall amend my documentation.

Cheers,

Will.

I may have miscommunicated. Your instructions were correct. I did it wrong. When I re-read your instructions, I was able to fix. No need to correct your instructions.

Oh, I shall uncorrect them then :slight_smile:

Will.