Moving objects at runtime

Hello!
I just have started to work with Java3D (I want to create an application for medicine) and so far everything works fine, if I create a static picture or when something is automatically moving.
Now I must move some objects of my scene (e.g. a shape based on a quad array) triggered on some external user-input (pressing a button/sliding a scrollbar on the panel externally).
How can I create this movement on demand: delete old transforms and the objects and add them again with a new transform?
Thank you for any help and suggestions!

Found a solution:
TranformGroup - capability ALLOW_TRANSFORM_WRITE and change the transformGroup (not the Transform3D, which it is based on).
Thank you!

Similar Messages

  • How do I create multiple objects during runtime?

    I don't know how to create multiple objects during runtime, here's my problem:
    I get a String as input. Then I create an object called newobject. I put the object in a hashtable with the above string as key.
    Then comes the problem, in order to create a new object, I have to rerun the same class, which uses the same name (newobject) to create a 2nd object. Now my hashtable doesn't reference to my 1st object anymore...
    Is there anyway I can fill up the hashtable with different objects, and make each key point to each object it was supposed to?
    For those who want to see a bit of the program:
    public class PlayBalloon{
    public Hashtable ht = new Hashtable();
    for(){
    Balloon pB = newBalloon;
    newBalloon=new Balloon(pB);
    ht.put("Some input from user", newBalloon);
    for(){
    ht.get(s).draw;<= s=string, draw=own meth. in Balloon
    }

    I think i can see the problem that you are having. You have, in effect, duplicate keys in your hashtable - ie, two strings used as keys with the same name.
    The way that a hashtable works is as follows...
    When you ask for a value that is mapped to a key it will go through the table and return the first occurence it finds of the key you asked for. It does this by using the equals() method of whatever object the key is (in your case it is a String).
    If you cant use different Strings for your keys in your hashtable then i would consider writing an ObjectNameKey class which contains the String value that you are trying to put in the hashtable and an occurrence number/index or something to make it unique. Remember to override the equals method in your ObjectNameKey object or else the hash lookup will not work. For example
    class ObjectNameKey {
        private String name;
        private int occurence;
        public ObjectNameKey(String name, int occ) {
            this.name = name;
            this.occurence = occ;
        public String getName() {
            return name;
        public String getOccur() {
            return occurence;
        public boolean equals(Object o) {
            if (!(o instanceof ObjectNameKey)) {
                return false;
            ObjectNameKey onk = (ObjectNameKey)o;
            if (onk.getName().equals(name) && onk.getOccur() == occurence) return true;
            return false;

  • How to create a text object at runtime?

    Hi,
    I am using crystal reports for visual studio 2010 and using c# to programming.
    I need to create  a text object in a specific section like section 2. and also I need to control the text object's position and text.
    I tried to move a object like:
    reportDocument1.ReportDefinition.Sections[j].ReportObjects<i>.Left = 0x8760;
    but object's position doesn't change at all.
    How can I do these (create a text object and change a object postion)?
    Thanks

    Hi Don,
    Thank you.
    I have downloaded a RAS ( report application Server ) sample.
    The sample uses the Business Objects Enterprise XI release 2. I am using win 7 and crystal reports for vs2010. Can I use this version of crystal reports to create  a text object at runtime? If not, what is the lowest version I have to purchase to achieve what I want?
    Basicly I need following capabilities at runtime:
    1) craete text objects, line objects, image objects.
    2) change text object, line object and image object positions, sizes, values of text object. If can I like to be able to change font as well.
    3) supress objects, sections. 
    4) change section's height

  • Custom Annotation :: inject object at runtime

    I would like develop a custom annotation to inject object at runtime. The annotation will work as follows
    1. develop ValidatorClass annotation on type.
    2. If annotated on a type object will be created at runtime and injected to the object. e.g. in class A it will inject validatorimpl object to vald object/
    Please let me know how to implement that.
    package com.debopam.validate
    public interface validator{
    public String validate();
    package com.debopam.validate
    public class validatorimpl implements validator{
    public String validate(){
       return "true";
    pckage com.debopam
    public class A{
    @ValidatorClass(name="com.debopam.validate.validatorimpl")
    validator vald;
    }

    yogeshd,
    It might be that the .class file for the annotation that you are compiling against is the one you have given us the source code for above, but when you run the program, the class file for the annotation is not the same, and is one that was compiled before you added the static field.
    This can happen if your classpath is wrong. (and would explain why the problem only occurs sometimes - because it is only failing when the classpath is wrong).
    If you run the following program with the Fully qualified name of your annotation as the argument, and with the same classpath as you run your program, it can tell you where it is finding the annotation class file. Check that this is the same one that you are compiling to.
    class WhereLoaded {
        public static void main(String[] args) {
            Class theClass=null;
            if(args.length > 0) {
                try {
                    theClass=Class.forName(args[0]);
                } catch (Exception e) {
                    e.printStackTrace();
                    theClass=Object.class;
            } else {
                System.out.println(
                    "The first argument should be a fully qualified class name," +
                    " using java.lang.Object instead"
                theClass=Object.class;
            String name=theClass.getName();
            name=name.substring(name.lastIndexOf(".")+1) + ".class";
            System.out.println(name + " loaded from " + theClass.getResource(name));
    }regards
    Bruce

  • Populating a authorisation object at runtime...

    Hi,
    how to populate a authorisation object at runtime? is it possible to have a variable etc that can be populated a runtime?
    I have a object zsales_off which has different values for different users. i need to create separate roles just to have different values for sales office for different users. i would like to avoid this by having a single role with the zsales_off getting populated at runtime.
    Details steps with code will be appreciated.
    thank you.

    Hello AHP,
    i am not still very clear about the detailed steps to be carried out as i am a novice in abap.
    i have created the authorisation variable and am using it in the query. if i manually assign values for sales office in the role, it is working fine.
    i want to assign values at run time. i am confused with the process as such.
    few doubts like:
    1> the variable should be of "authorisation" processing type or "customer exit" processing type.
    2>what to use I_step=0 or I_step =1? how to use? where to use?
    3>to write a abap code or use a func module, which one? how to use.
    any example(like in my case different sales office values for diffrent users) with DETAILED STEPS & CODE would be appreciated.
    also i need to have multiple single values for each user(but not interval).
    Please help.

  • Interlace problems with moving objects using iDVD

    I had an MP4 file (created by a 3rd party) from a Hi-8 analog tape which has some interlace artifacts on moving images (left image of boy) but not too bad. When the MP4 files was imported into iMovie 11 the interlace artifacts smoothed somewhat - that was OK (right image of boy). The camera was still and the boy was moving.  Vertical lines on stationary objects are OK in all images. These are screen captures from the Mac of the mp4 played through quicktime and the same file imported into iMovie 11 and played.  I paused both to take the screen capture.
    The completed project in iMovie 11 looked OK when previewed prior to rendering. These are 20 year old videos so my expections were being met.   I rendered the project with iDVD to the hard drive first and then to a DVD with the same poor imaging result on the moving object.  I am using a new Macbook Pro I bought in early January which came with iMovie 11 and iDVD  Ver 7.1.2 (1158). Running Mac OS X 10.7.3  Macbook Pro  2.3 Ghz Corei7   8GB 1333 Mhz DDR3.
    I couldn't screen capture from the MAC DVD player screen to illustrate the poor result (got a checkerboard screen) so I took a photo of the screen and imported that (below).  The moving boy on the left is from an  iMovie 11 screen capture, the image on the right is the moving boy from the rendered DVD I paused on the Mac (and took a pic of).
    Below a close up of the poorly rendered moving boy viewed on the resultant DVD.  This translates into a horrible rendition of any quick moving object.  It happens with any moving image - i.e. a pan across a room with straight vertical lines like edges of a wall will show as serrated and poorly rendered edge. I used a trial version of the Daniusoft DVD creator with the same result!  I am at a loss on how to resolve this issue.  Any thoughts out there??
    I had previously used Pinnacle Studios on my old XP PC which worked great on other tape's Mpeg files and created great DVD's (never had an interlace problem) ... until my computer died .....  so I figured Apple and associated software should be at least equal if not a superior product.   Now I'm not too sure!

    I had an MP4 file (created by a 3rd party) from a Hi-8 analog tape which has some interlace artifacts on moving images (left image of boy) but not too bad. When the MP4 files was imported into iMovie 11 the interlace artifacts smoothed somewhat - that was OK (right image of boy). The camera was still and the boy was moving.  Vertical lines on stationary objects are OK in all images. These are screen captures from the Mac of the mp4 played through quicktime and the same file imported into iMovie 11 and played.  I paused both to take the screen capture.
    The completed project in iMovie 11 looked OK when previewed prior to rendering. These are 20 year old videos so my expections were being met.   I rendered the project with iDVD to the hard drive first and then to a DVD with the same poor imaging result on the moving object.  I am using a new Macbook Pro I bought in early January which came with iMovie 11 and iDVD  Ver 7.1.2 (1158). Running Mac OS X 10.7.3  Macbook Pro  2.3 Ghz Corei7   8GB 1333 Mhz DDR3.
    I couldn't screen capture from the MAC DVD player screen to illustrate the poor result (got a checkerboard screen) so I took a photo of the screen and imported that (below).  The moving boy on the left is from an  iMovie 11 screen capture, the image on the right is the moving boy from the rendered DVD I paused on the Mac (and took a pic of).
    Below a close up of the poorly rendered moving boy viewed on the resultant DVD.  This translates into a horrible rendition of any quick moving object.  It happens with any moving image - i.e. a pan across a room with straight vertical lines like edges of a wall will show as serrated and poorly rendered edge. I used a trial version of the Daniusoft DVD creator with the same result!  I am at a loss on how to resolve this issue.  Any thoughts out there??
    I had previously used Pinnacle Studios on my old XP PC which worked great on other tape's Mpeg files and created great DVD's (never had an interlace problem) ... until my computer died .....  so I figured Apple and associated software should be at least equal if not a superior product.   Now I'm not too sure!

  • How do I pull up the left control panel that allows you to move from text to moving objects on page?

    How do I pull up the left control panel that allows you to move from text to moving objects on page?

    Do you mean this one:
    If so, go to the Window menu and make sure that Tools is checked.

  • Positioning moving objects

    I'm getting ready to make a 2d game and wasn't sure how to draw moving objects on the screen. I've played around in the past and always had a fixed sized window and basically moved objects around on a pixel grid. I want to have a resizeable window but keep the relative size and movements of objects the same. How is this usually done? Should I just render it to the largest possible window size and then transform it to the appropriate size? Thanks in advance!

    jgould wrote:
    I'm getting ready to make a 2d game and wasn't sure how to draw moving objects on the screen. I've played around in the past and always had a fixed sized window and basically moved objects around on a pixel grid. I want to have a resizeable window but keep the relative size and movements of objects the same. How is this usually done? Should I just render it to the largest possible window size and then transform it to the appropriate size? Thanks in advance!Not sure what that means. Basically you have a couple options:
    1- Store locations by ratios, not exact coordinates. So if you want a GameObject's location to be in the direct middle of the screen, its position would be (.5, .5). Then when you go to draw that GameObject, you have to convert that position to screen coordinates. You do this simply by multiplying the ratio-coordinates by the game window's width or height.
    2- Store locations by some model coordinates. This is similar to the first method, but requires some extra translation. You would store the GameObject's location via coordinates such as (50, 50), but you would also have to keep track of how large your game window model was (for simplicity's sake, let's say it is 200 by 100):
    drawPoint( (gameObject.getX() / 200) * gamePanel.getWidth(), (gameObject.getY() / 100) * gamePanel.getHeight() );Does that make any more sense?
    Edit- I should say that there probably are a ton of other ways to do it, these are just the ways that most easily fit into my head. It's all just algebra though.
    Edited by: kevinaworkman on Nov 13, 2009 2:54 PM

  • How do you filter out moving objects in a movie?

    Hello!
    I'v searched the internet for solutions to this but I cann't find any.
    Im prittie new and I need to make a house on fire while two guys (one is me)
    will be walking away from it, towards the camera.
    I want to filter out these two guys and only apply fire and flames to the house itself!
    To do this I used Time Diffrence and tried to isolate the guy using Fast Blur and Luma Key
    but Im prittie lost.. Nothing works and I really need guidence
    Do you know a trick to use?
    I cant do greenscreening as the green background would cost a fortune..
    But isn't there anyway to filter out moving objects?

    I'm not sure that you totally get the process. This kind of shot requires at least 3 elements or plates. These three plates become three layers in After Effects. The bottom layer would be the Background Plate which is a shot of the house without any actors in the shot. The next plate would be the Effect Plate or Fire Plate which could be any shot you can get or generate through plug-ins of flames. The top layer would be your Foreground Plate or your two actors.
    Now that you know what you need you can plan your shoot. The background plate is easy. Just set the camera on a tripod and lock it off. NO zooming. No panning, No change of focus. The foreground plate is also easy. You don't have to green screen the entire set, all you need to do is to put a green screen behind your actors. I do this kind of thing all the time using a 6' X 6' (sometimes smaller) green screen (or blue or red or purple) made of fabric and stretched over a frame that I made from 1/2" EMT electrical conduit and 4 90º elbow connectors for less than $20 at Home Depot or Lowes. You get a couple of assistants to walk behind your actors holding the green screen behind them. If you need to include their feet they can be easily rotoscoped out later and you can garbage matte everything else. If it's impossible to green screen the shot then you are stuck with roto, but that's much easier in CS5 using the roto brush. If you use your show with the actors as the background plate roto is even easier because you can hide a multitude of sins by simply feathering the roto and letting the fire light wrap around the actors a bit.
    The fire plate can be purchased footage, or you could shoot a real fire against a black background, or you could create the flames using AE or even a 3D app like Blender (free) or a bunch of other apps.
    Making the shot look real requires a few tricks once you have your clean plates. Fire creates light so you've got to add lighting effects to the background plate to sell the fire. You've also got to wrap light around your actors. Look for tutorials on light wrap for this. You can really help sell the effect if you place some flickering light sources behind and to the side of your actors when you shoot the foreground (actors) plate.
    Once you get a handle on these techniques it's fairly easy to make the transition to pulling of this kind of a shot with a hand held camera (now you have to learn motion tracking). On a project I recently completed we had to put a fire in a prop fireplace while actors moved around bringing milk and cookies for Santa. It was all roto and the fire was shot at night with nothing more than a black cloth (Duvetyne) behind the fireplace grate. The final composite was 10 layers and was so totally believable that no one questions the shot.
    The layers were from top to bottom, reflection in grandmas glasses, light wrap, actors (roto of original background plate), fire flicker layer, color mask layer (more orange around fire, fire glow layer, fire layer in Add mode, second fire layer in screen mode, third fire layer Luma keyed, and finally the original plate which contained all the actors, carefully lit with flickering firelight simulated by dangling a stick with fabric cut into 1/2 inch wide strips about one foot long in front of a orange gelled light behind and to the right of  the actors.
    If I get a chance I'll post a screenshot.
    Here you go:
    Light Wrap:
    The Movie
    Part of the original render before color grading.
    Enjoy

  • Object with runtime number '0' not defined

    Hello,
    We have a problem in one step of the workflow we created for sales orders.
    The following are the errors:
    EXECUTE_METHOD_OBJECT_SYNC -> Object with runtime number '0' not defined
    EXECUTE_METHOD_BOR -> Object with runtime number '0' not defined
    EXECUTE_METHOD_BOR -> Object with runtime number '0' not defined
    Object with runtime number '0' not defined
    Message no. OL808
    We have already seen all the binds and correct.
    Thanks!
    Ariel Prebianca

    Associated message no with message 'Object with runtime number '0' not defined' is OL 808.
    Check Note 1322173 - Wrong error msg raised in BP_JOB_READ of interrupt process. It may not directly solve the issue but it will help you show correct message.

  • Blur moving object in AE CS6

    Hi:
    I need to blur a moving object:
    - The effect is only needed at some point of the video, it must appear, and then disappear, not being on screen the whole time.
    - The object is moving, and changing shape, the blur must adapt to it.
    - I've been trying to use the "Track Motion" option with Position & Rotation, then the "Analyze Forward" button, but the thing makes a mess all over, it's not following the object at all, then if You try to adjust it manually, it's only done in 1 frame, in the other frames the thing is off the object, then the "Tracking" stays on screen.
    Thanks in advance.

    Are you saying that you have something in some video that you have shot that you want blurred out? If so, you could create an adjustment layer with a mask on it over the object you want to blur and then just animate the mask over time. Now, you could use motion tracking to help that mask follow the object, but it sounds like you are having trouble with getting it to work properly. Try the tips here for doing motion tracking correctly. Alternatively, you could follow the tips on rotoscoping to make the mask animation go more quickly. Also, if you have After Effects version 12 (also known as AE CC), you can use the new mask tracker feature.

  • Lines on moving objects

    When I export DV clips from FCE I get lines appear on moving objects, (HDTV). When I export the same clip using iMovie08 it all looks smooth.
    I've tried the de-interlace, it made it worse.
    How can I get rid of the lines in FCE?

    shuggyboy1 wrote:
    ... What is the _best setting to export_ from imovie HD 6 to idvd to prevent this yet still maintain DV quality?
    .. not to export at all, that simple..
    the zillions of Export options could cause trouble.
    simply, store your iM projects in the 'Movies' folder of your Mac ...
    iDVD will 'find' them automatically and cares for itself to import..
    Plan B)
    drag'n drop the whole project from Finder to iDVD.. again: no export involved, no trouble..

  • When I render and Export there are these little lines around moving objects

    When I render and Export there are these little lines around moving objects, what are they and how do I fix it?

    The lines are caused by the video being interlaced.
    If you export to DVD they should no longer appear. However, if they don't disappear you can use the Deinterlace filter on the footage whilst in FCE.
    How are you exporting ..... QT Movie or QT Conversion ....... and what are you exporting to - the internet or DVD?

  • Video titling behind moving objects

    i recently saw a titling effect in a video, in which a motorcycle drove across the screen and as it passed a title appeared behind it. how does one create video titling behind moving objects? i have no experience in animation, so i'm guessing that the video layer is duplicated and the top layer masked, frame by frame? would an 8-point garbage matte work?

    You won't have an easy time doing this in FCP, but Motion, After Effects, or ultimately Shake, can do this a lot easier. You have to rotoscope the motorcycle, accounting for the rims, and space between the engine parts, or anywhere else where you would logically see through to the background, then duplicate that layer on top of the original, with the text in between the two layers. Depending on how long the clip is, you're in for a long haul. But if the footage is anything but DV25, clip analysis and automated keyframing might serve you well as a starting point after the initial mask is made.

  • Highlight a moving object

    Using AE CS5, how do I highlight a moving object in a scene?  I want an ellipse shape of normal brightness highlighting the moving object.  I want the rest of the scene to be around 60% brightness.
    Thanks

    These videos show some approaches to that kind of result:
    http://tv.adobe.com/watch/learn-by-video/adobe-after-effects-cs5-motion-tracking-and-rotos coping/
    http://www.video2brain.com/en/videos-1458.htm
    Start here to learn After Effects: http://adobe.ly/bjBT3P

Maybe you are looking for

  • Performance issue in query

    Hi, I have this query in my program, it’s taking so much time to execute. Can you pls look at this query and tell me whats wrong with it. ITAB which is used in for all enteries has around 3000 records.       SELECT * FROM regup              INTO CORR

  • Bridge (and mini Bridge) shows no thumbnails

    Bridge CS6 doesn't seem to work at all. The program launches fine on my Mac, but when I point it to a folder of images, I get nothing. No thumbnails or metadata. If I double click on an image (blank thumb), the image properly launches in Photoshop or

  • Firefox 4 crashes on Mac OS X 10.6.6 every time when I run any bangla site

    Generally I downloaded fonts from [http://ekushey.org/?page/osx_fonts here] here. It worked fine with previous version of firefox. But in FF4 is crashing frequently. Please give solution

  • WBS Element Populated on Asset GL Account Line Ledger 90

    Hello All, For preliminay settlement of a WBS element to an AuC asset, how do you get the WBS element to populate on the account line for the asset gl account in ledger 90? Currently, I'm working in R/3 4.7 and the WBS populates on both sides of the

  • ALV Hierarchy display: How to get rid of the bullets ?

    Hi All, I am using Web dypro ALV to display my data, and I use ALV display type hierarchy.  When I expand the parent node in my hierarchy column, I get bullets in my lower level rows in the hierarchy column( this is the standard hierarchical ALV disp