Renderer queueing geometry updates until OOM

Hi,
we have some quite annoying problem in a project using j3d. We issue quite some geometry changes to show processdata. It seems like these changes/updates are queued when the frame containing the canvas becomes inactive, like minimizing it or changing workspaces. We already changed the code to use async (GeometryUpdater) updates and by_ref coordinates, but that didn't help , as soon as the frame is hidden the heap memory usage increases really fast (when geometry changes happen), gc() doesn't help because all the memory is still referenced.
The heap is mainly filled up with Object[] and J3DMessage objects, which was the expected result when queueing up messages which aren't rendered.
I am just really wondering why that happens? I already digged through the j3d source but didn't have a clue, also searching the web didn't give any useful information on this point as it seems that we are the only project which uses geometrychanges that heavily.
I hope that someone can point me to the right direction (it's probably something small and stupid). I can also post some example code if my problem isn't clear.
Best regards
Georg

Hi,
have you ever got familiar with Java 3D's Behavior node? The use of a Timer isn't advisable for the desired 'task'.
"Behavior nodes provide the means for animating objects, processing keyboard and mouse inputs, reacting to movement, and enabling and processing pick events. Behavior nodes contain Java code and state variables. A Behavior node's Java code can interact with Java objects, change node values within a Java 3D scene graph, change the behavior's internal state-in general, perform any computation it wishes."
Please, run this code and inform us how it behaves.
August
import java.awt.Color;
import java.awt.GraphicsConfiguration;
import java.util.Enumeration;
import java.util.Timer;
import java.util.TimerTask;
import javax.media.j3d.*;
import javax.swing.*;
import javax.vecmath.*;
import com.sun.j3d.utils.universe.SimpleUniverse;
public class GeometryUpdateIssue extends JFrame {
    private QuadArray qa = new QuadArray(16,
                    GeometryArray.COORDINATES|GeometryArray.COLOR_3);
    private double points[] = new double[48];
    public GeometryUpdateIssue() {
        setSize(500, 500);
        setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
        BoundingSphere bounds = new BoundingSphere(new Point3d(0.0,0.0,0.0), 10.0);
        GraphicsConfiguration graphConfig = SimpleUniverse.getPreferredConfiguration();
        Canvas3D canvas3D = new Canvas3D(graphConfig);
        SimpleUniverse simpleUni = new SimpleUniverse(canvas3D);
        BranchGroup sceneGraph = new BranchGroup();
        sceneGraph.setBoundsAutoCompute(true);
        qa.setCapability(GeometryArray.ALLOW_COORDINATE_WRITE);
        Background background = new Background(new Color3f(Color.WHITE));
        background.setApplicationBounds(bounds);
        sceneGraph.addChild(background);
        for (int i : new int[]{5, 8, 14, 15, 17, 18, 20, 23, 24, 26, 27, 30, 33, 35, 36, 45}) {
                points[i] = 0.2;
        setHeight(0.5);
        Shape3D s = new Shape3D(qa);
        TransformGroup objTrans = new TransformGroup();
        objTrans.setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
        Transform3D t3d = new Transform3D();
        t3d.setTranslation(new Vector3f(0.0f, -0.4f, 0.0f));
        objTrans.setTransform(t3d);
        TransformGroup objTrans2 = new TransformGroup();
        objTrans2.setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
        Transform3D yAxis = new Transform3D();
        Alpha rotationAlpha = new Alpha(-1, 4000);
        RotationInterpolator rotator = new RotationInterpolator(
                        rotationAlpha, objTrans2, yAxis,
                        0.0f, (float) Math.PI*2.0f);
        rotator.setSchedulingBounds(bounds);
        sceneGraph.addChild(rotator);
        objTrans.addChild(objTrans2);
        objTrans2.addChild(s);
        sceneGraph.addChild(objTrans);
        GeomUpdater geomUpdater = new GeomUpdater(5);
        geomUpdater.setSchedulingBounds(bounds);
        sceneGraph.addChild(geomUpdater);
        simpleUni.addBranchGraph(sceneGraph);
        simpleUni.getViewingPlatform().setNominalViewingTransform();
        add(canvas3D);
        new Timer().scheduleAtFixedRate(new TimerTask() {
            int i = 0;
            @Override
            public void run() {
                setHeight((++i)%10/10.0);
                setHeight((++i)%10/10.0);
                setHeight((++i)%10/10.0);
                setHeight((++i)%10/10.0);
        }, 1000, 5);
    private void setHeight(double h) {
        for (int i : new int[]{7, 10, 19, 22, 31, 34, 43, 46}) {
                points[i] = h;
        qa.setCoordinates(0, points);
    private class GeomUpdater extends Behavior {
        private int i = 0;
        private WakeupOnElapsedTime elapsedTime = null;
        GeomUpdater(long milliseconds) {
            elapsedTime = new WakeupOnElapsedTime(milliseconds);
        @Override
        public void initialize() {
            this.wakeupOn(elapsedTime);
        @Override
        public void processStimulus(Enumeration criteria) {
            setHeight((++i)%10/10.0);
            setHeight((++i)%10/10.0);
            setHeight((++i)%10/10.0);
            setHeight((++i)%10/10.0);
            this.wakeupOn(elapsedTime);
    public static void main(String[] args) {
        new GeometryUpdateIssue().setVisible(true);
}

Similar Messages

  • TS4083 Is there a way or a setting my folders in Mail to automatically update across all devices? if I transfer an email to a folder for follow-up on my PC, my folder in Mail on my iPhone doesn't update until I actually go into the folder and update manua

    Is there a way (or a setting) for my individual folders in Mail to automatically update across all devices? For example, if I transfer an email to a folder for follow-up on my PC - say 10th of the following month - the same folder in Mail on my iPhone doesn't update until I actually go into the folder and update manually.  Interestingly though, if I create a new folder on any of my devices they automatically appear on the other devices so it is just the actual contents that I am referring to here.  Appreciate any help or guidance.
    Regards
    Justin

    You can turn mail off in the settings but then you can't use it for anything, including the "test" that you want to perform.
    Settings>Mail, Contacts, Calendars>Account Name>Mail>Off. That totally turns off the mail account.
    As long as mail is turned on and you launch the app, it will look for an download new mail.

  • Delay-updates-until-end-of-tx flag behavior in WLS 6.1 SP4

    Hi All!
    I'm a bit in trouble with a strange behavior with the
    <delay-updates-until-end-of-tx> tag.
    I didn't find any message about my problem here around, so I don't
    know if I missunderstand something. Has somebody had the same
    (following) experience?
    We are migrating from WLS 5.1 to WLS 6.1
    We tried do keep ejbs "as are" in 5.1, so we're talking about EJB 1.1
    on WLS 6.1: it should be allowed!
    Everything works fine, but when a session bean (SL) modifies some
    entity bean(CMP or BMP) and try to read from it in the same
    transaction, read data are NOT up to date.
    To solve this problem with WLS 5.1 we used the
    delayUpdatesUntilEndOfTx tag, and it went fine, but with WLS 6.1 it
    doesn't work, even if reading bea docs I understand it should.
    Looking at the console, flags are correctly un-setted for the entity
    beans we need, but the behavior is like if it wasn't.
    Any idea?
    Thanx in advance, Paolo.

    Hi
    Well, delay-updates-until-end-of-tx is setted tu false, so it
    shouldn't wait 'til the end, but write immediately.
    When I "read" I call finders.
    Anyhow, I went on with tests, and tried to use EJB 2.0 entity beans,
    and it works fine.
    So now I have 1.1 session bean on 2.0 entity beans well working.
    It seems that troubles are only with 1.1 entity beans on WLS 6.1.
    1.1 entities on WLS 5.1, and 2.0 entities on WLS 6.1 are ok for me.
    Maybe a bug?
    Paolo.
    "Keng-Woei Tan" <[email protected]> wrote in message news:<3eb81ca2$[email protected]>...
    Did u set delay-updates-until-end-of-tx to true or false?
    When you do a "read", are you calling get cmp fields on the same bean instancesor
    are you invoking finder methods?
    [email protected] (Paolo Bettini) wrote:
    Hi All!
    I'm a bit in trouble with a strange behavior with the
    <delay-updates-until-end-of-tx> tag.
    I didn't find any message about my problem here around, so I don't
    know if I missunderstand something. Has somebody had the same
    (following) experience?
    We are migrating from WLS 5.1 to WLS 6.1
    We tried do keep ejbs "as are" in 5.1, so we're talking about EJB 1.1
    on WLS 6.1: it should be allowed!
    Everything works fine, but when a session bean (SL) modifies some
    entity bean(CMP or BMP) and try to read from it in the same
    transaction, read data are NOT up to date.
    To solve this problem with WLS 5.1 we used the
    delayUpdatesUntilEndOfTx tag, and it went fine, but with WLS 6.1 it
    doesn't work, even if reading bea docs I understand it should.
    Looking at the console, flags are correctly un-setted for the entity
    beans we need, but the behavior is like if it wasn't.
    Any idea?
    Thanx in advance, Paolo.

  • Lync Status Not Updating Until Group is Expanded

    Hello all,
    I am having an issue that I can't seem to figure out. For the Groups view, the group doesn't seem to update a person's status when collapsed. After it is expanded, is only then the status will update and the person will go into a different group or move
    up or down the list, depending on filtering. Also if the expanded group extends past the bottom of the Lync window, those contacts don't update until seen. This also happens with the Status View as well. You need to scroll through the entire list to update
    everyone's status.
    Is this part of Lync or a bug? I am really hoping it is an issue because trying to find people after their status updates is annoying.

    Hi,
    Did you try deleting the Lync Profile. 
    Please try to delete the profile and check the presence. 
    %UserProfile%\AppData\Local\Microsoft\Office\15.0\Lync
    Is your Lync client is installed with latest Patches?
    Whenever you see a helpful reply, click on Vote As Helpful & click on Mark As Answer if a post answers your question.

  • HT5815 The most important piece of info about an update I need is how much data does it require. I am travelling and using prepaid data. I cannot even consider an update until I know how much data it will use. Please provide this information.

    The most important piece of info about an update I need is how much data does it require. I am travelling and using prepaid data. I cannot even consider an update until I know how much data it will use. Please provide this information.

    http://www.apple.com/feedback/macosx.html

  • [svn:osmf:] 10991: Fix bug FM-119, where the playhead time doesn' t get updated until after the seek has completed.

    Revision: 10991
    Author:   [email protected]
    Date:     2009-10-17 22:52:28 -0700 (Sat, 17 Oct 2009)
    Log Message:
    Fix bug FM-119, where the playhead time doesn't get updated until after the seek has completed.  The bug is actually in Flash Player (FP-1705), and the workaround is to wait until NetStream.time gets updated before dispatching the seek completion event.  This changelist also updates the unit tests and NetMocker to verify the fix.
    Ticket Links:
        http://bugs.adobe.com/jira/browse/FM-119
        http://bugs.adobe.com/jira/browse/FP-1705
    Modified Paths:
        osmf/trunk/framework/MediaFramework/org/osmf/net/NetStreamSeekableTrait.as
        osmf/trunk/framework/MediaFramework/org/osmf/traits/SeekableTrait.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/audio/TestAudioSeekableTrait.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/media/TestMediaPlayer.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/net/TestNetStreamSeekableTrait.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/traits/TestISeekable.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/traits/TestSeekableTrait.as
        osmf/trunk/libs/adobe/NetMocker/org/osmf/netmocker/MockNetStream.as
        osmf/trunk/libs/adobe/NetMockerTest/org/osmf/netmocker/TestMockNetStream.as

    Revision: 10991
    Author:   [email protected]
    Date:     2009-10-17 22:52:28 -0700 (Sat, 17 Oct 2009)
    Log Message:
    Fix bug FM-119, where the playhead time doesn't get updated until after the seek has completed.  The bug is actually in Flash Player (FP-1705), and the workaround is to wait until NetStream.time gets updated before dispatching the seek completion event.  This changelist also updates the unit tests and NetMocker to verify the fix.
    Ticket Links:
        http://bugs.adobe.com/jira/browse/FM-119
        http://bugs.adobe.com/jira/browse/FP-1705
    Modified Paths:
        osmf/trunk/framework/MediaFramework/org/osmf/net/NetStreamSeekableTrait.as
        osmf/trunk/framework/MediaFramework/org/osmf/traits/SeekableTrait.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/audio/TestAudioSeekableTrait.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/media/TestMediaPlayer.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/net/TestNetStreamSeekableTrait.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/traits/TestISeekable.as
        osmf/trunk/framework/MediaFrameworkFlexTest/org/osmf/traits/TestSeekableTrait.as
        osmf/trunk/libs/adobe/NetMocker/org/osmf/netmocker/MockNetStream.as
        osmf/trunk/libs/adobe/NetMockerTest/org/osmf/netmocker/TestMockNetStream.as

  • After deleting firefox and reinstalling it Ikeep getting a message telling me that it cant be updated until i deleate the original programme how do I get rid of that message

    after deleting firefox and reinstalling it Ikeep getting a message telling me that it cant be updated until i deleate the original programme how do I get rid of that message

    You seem to be running the latest Firefox 9.0.1 version according to the user agent in your system details list:
    *Mozilla/5.0 (Windows NT 5.1; rv:9.0.1) Gecko/20100101 Firefox/9.0.1
    Do a clean (re)install and delete the Firefox program folder (C:\Program Files\Mozilla Firefox\).
    Download a fresh Firefox copy and save the file to the desktop.
    * Firefox 9.0.x: http://www.mozilla.com/en-US/firefox/all.html
    Uninstall your current Firefox version, if possible.
    *Do NOT remove personal data when you uninstall the current version or you lose your bookmarks and other data in the profile folder.
    Remove the Firefox program folder before installing that newly downloaded copy of the Firefox installer.
    *It is important to delete the Firefox program folder to remove all the files and make sure that there are no problems with files that were leftover after uninstalling.
    * http://kb.mozillazine.org/Uninstalling_Firefox
    Your bookmarks and other profile data are stored elsewhere in the Firefox Profile Folder and won't be affected by a reinstall, but make sure that you do not select to remove personal data if you uninstall Firefox.
    *http://kb.mozillazine.org/Profile_folder_-_Firefox
    *http://kb.mozillazine.org/Profile_backup
    *http://kb.mozillazine.org/Standard_diagnostic_-_Firefox#Clean_reinstall

  • Mouse Cursor doesnt update until mouse is moved.

    I think I'm having the same problem as the person in this post:
    http://forum.java.sun.com/thread.jsp?forum=57&thread=149236
    I'm setting the mouse cursor after certain buttons in a JPanel are pushed, but the cursor image doesn't actually get updated until the mouse is moved. I tried using Toolkit.getDefaultToolkit().sync() and that didn't work. The other solution, which was to fire a mouse event to force it to update, doesn't seem to be ideal.
    Is there any other way to force the cursor image to get updated immediately, without moving the mouse?

    Hmm, I can't reproduce your problem (below is a small test example, that works fine with me) on win9x, neither with jdk1.3, nor with 1.4.
    Greetings
    Jeanette
    import javax.swing.*;
    import javax.swing.event.*;
    import java.awt.event.*;
    import java.awt.*;
    //import de.kleopatra.support.debugon.*;
    /** reported problem: cursor not immediately updated after switching
    *          only after move
    *     1.4, 1.3: not reproducible (win9x)
    *     $Id: TestCursor.java,v 1.1 2002/03/19 11:27:20 Jeanette Exp $
    public class TestCursor {
         protected JFrame frame ;
         protected Cursor current;
         protected JComponent target;
         public TestCursor() {
              frame = new JFrame("TestCursor");
              frame.setDefaultCloseOperation(frame.EXIT_ON_CLOSE);
              frame.getContentPane().add(buildMainPanel());
              frame.getContentPane().add(buildButtonPanel(), BorderLayout.SOUTH);
              frame.pack();          
              frame.setSize(300, 200);
              frame.show();
    //---------------------------helper
         protected void toggleCursor() {
              if (current == null) {
                   current = Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR);
              Cursor temp = target.getCursor();
    //          D.ebug("old cursor: ", temp);
              target.setCursor(current);
              current = temp;
    //---------------------------init ui
         protected JComponent buildMainPanel() {
              JPanel panel = new JPanel();
              panel.setPreferredSize(new Dimension(200, 100));
              panel.setBackground(Color.yellow);
              target = panel;
              return panel;
         protected JComponent buildButtonPanel() {
              JPanel panel = new JPanel();
              JButton button = new JButton("do toggle cursor");
              button.setMnemonic('d');
              frame.getRootPane().setDefaultButton(button);
              ActionListener action = new ActionListener() {
                   public void actionPerformed(ActionEvent event) {
                        toggleCursor();
              button.addActionListener(action);
              panel.add(button);
              return panel;
    //---------------------------factory methods
    //---------------------------Main
         public static void main(String[] args) {
         //     LFSwitcher.windowsLF();
              new TestCursor();
    }

  • New email on iphone 6 IOS 8 is delayed and won't update until you lauch the email app

    New email that is received on an iphone 6 (IOS 8) doesn't update # until you actually launch the email app.  At that time the new email badge updates and VIP notifications are activated.  How do I correct this so that it updates immediately as email is received.

    Hi Georgiegog,
    If you are not getting updates in Mail until you launch the app, you may want to check in Settings to make sure that Push delivery is active, as noted on this page:
    Mail settings - iPhone
    Regards,
    - Brenden

  • Fonts rendering incorrectly since update to Firefox 13.0.1

    Since I updated to Firefox 13.0.1, any website using the Helvetica Neue font is rendering an outline font instead. I do have this font installed on my computer, and cannot uninstall it as I am a graphic designer and I use it all the time. Any change we can get a fix on this?
    I just pasted one example, but even this page is doing it: https://support.mozilla.org/en-US/questions/new/desktop/d1/form?search=Fonts+rendering+incorrectly+since+update+to+Firefox+13.0.1. I also know Pinterest does it.

    There may be a problem with the Helvetica Neue font if Firefox is using another font instead.
    You can do a font test to see if you can identify corrupted font(s).
    *http://browserspy.dk/fonts-flash.php?detail=1
    You can use this extension to see which fonts are used for selected text.
    *fontinfo: https://addons.mozilla.org/firefox/addon/fontinfo/

  • HT2404 where do i log in to update ? The updates are there but it won't update until I log in somewhere. Help please

    I have two apps that need updating; iMovie and iPhoto but it won't let me update until I log in somewhere.  Can anyone point me in the right direction please? thanks in advance for your help

    /Applications/App Store.app should do the trick.

  • HT1848 want to update iPad 2 to ios6.  I am warned not to do the update until I transfer purchased items to my computer.  When I try to transfer into itunes I am warned that I will lose all the books I have on iPad.....there's lots of them.

    want to update iPad 2 to ios6.  I am warned by itunes not to do the update until I transfer purchased items (books) to my computer.  When I try to transfer into itunes I am warned that I will lose all the books I have on iPad.....there's lots of them.

    The Apple Support Communities are an international user to user technical support forum. As a man from Mexico, Spanish is my native tongue. I do not speak English very well, however, I do write in English with the aid of the Mac OS X spelling and grammar checks. I also live in a culture perhaps very very different from your own. When offering advice in the ASC, my comments are not meant to be anything more than helpful and certainly not to be taken as insults.
    To transfer the books, highlight the iPad in the iTunes Devices list and right click on the iPad's name. Choose transfer purchases.

  • HT4623 I need to update my iPad to IOS 7.0.6, because my company requires it, but they didn't approve the update until 7.1.0 was out and that is not allowed yet.  How do I resolve this issue?

    How do I update my iPad to a supseded version of IOS?
    My company requires me to use the most recent IOS version approved by corporate, flight department and the FAA.  This is never initially the same rev as the current IOS revision available from Apple for install. There is always a gap between when Apple releases the update and when its approved for us. My not infrequent dilemna is that occasionally, at least, we are not approved to update to a more recent revision to IOS, until the day of an even more recent revision release, which is of course, not yet approved for my group.
    Yet, we are required to always use the most recent company and FAA approved rev.  Where may I find a link to the (recently) outdated install file or what other process would allow compliance with my situation?

    This is a concern amoung many corporate users.  It's going to take somekind of policy change with apple.
    Enterprise support:
    Call enterprise support  (866) 752-7753  to create  a case ID number

  • In my iphone4s and  my iPad every time who I ask an update or down load an application ask me a bill account at the past I have not a problem to downloaded any application or update until one time I bought one application

    I try to downloaded any application or update to my iPhone or my iPad but asked me a billing acount. In the past any time who I asked any application or updated it was free  until one time  I bought one application with my bank debit cards once every time since then every time I want to download an application or update shows my account problem and not receive another card.

    Contact iTunes Customer Service and request assistance
    Use this Link  >  Apple  Support  iTunes Store  Contact

  • Screen wobbles and unsatisfactory rendering after last update

    After the last automatic update (which upgraded QT to 7.2 and a couple of other things), the screen rendering has deteriorated markedly.
    Moving the mouse around causes the screen to wobble by a pixel or two vertically and horizontally and the rendering of fonts (in Firefox particularly, but also system profiler and other apps) to look bad. The wobble is independent of any application and affects the dock as well as the whole screen.
    Is there anything that can be done to fix this?

    You have accidentally turned on screen zoom. Turn it off (System Preferences > Universal Access > Seeing > Zoom > Off).

Maybe you are looking for

  • Font, Video, and Images Blurry

    When I preview or even work on my project everything is blurry but when its just the picture or video is its very clear. Do I have something wrong with the size? What should I do? I just want to make a dvd of a local theater production for the cast t

  • Some Panels will not Resize

    Working on Windows XP SP2, IDCS3. A friend's paragraph panel and one other panel will not resize. All other panels function normally. We tried: - Resetting her preferences - Resetting her panels - Closing and reopening the particular 2 panels - Movin

  • Does firefox update in the background?

    I get a notice that Firefox wants to update. I click go ahead. My Webroot Secure pops up to state there is a risk of infection and denotes it as pua. something or other. Is this a real threat or is Firefox attempting a legitimate update? I just insta

  • Bachground Jobs from WF-Batch

    Hi,      In my workflow, I escaled Org path(Approver levels) using RH_STRUC_GET this function module,this step is back ground step assigned ,my doubt is if I want to see If i want to see the Approver now I mean the workitem is in which Approvers inbo

  • Adding racks/nodes to parallel data warehouse v2

    Hi, Wondering what the mechanism is for redistributing data among nodes when you add a rack to PDW V2. Recall the way mentioned to do it was backup and restore in V1 and didn't see anything new discussed on the topic at pass 2012. Thanks.