How to load few objects in one sence ?Please help.

Is there any one know how to load few object into one sence ?
I have some code , It can load one object one the sence .Please any one know how to change it . Thanks so much .
-------------------------- model loading --------------
private void loadModel(String fn)
    /* Load the model from fn into the scene graph using a NCSA
       Portfolio loader. Rotate and scale it to make it easier to see.
       Store the loaded model's scene in the global loadedScene,
       and its branch group in loadedBG.
      FileWriter ofw = null;
      System.out.println( "Loading: " + fn );
      try {
        ModelLoader loader = new ModelLoader();    // the NCSA portfolio loader
        // System.out.println("Loader flags: " + loader.getFlags());
        loadedScene = loader.load(fn);             // the loaded scene
        // Rotate and scale the model
        if(loadedScene != null ) {
          loadedBG = loadedScene.getSceneGroup();    // the model's BG
          Transform3D t3d = new Transform3D();
          t3d.rotX( -Math.PI/2.0 );    // models are often on their face; fix that
          Vector3d scaleVec = calcScaleFactor(loadedBG, fn);   // scale the model
          t3d.setScale( scaleVec );
          TransformGroup tg = new TransformGroup(t3d);
          tg.addChild(loadedBG);
          sceneBG.addChild(tg);   // add (tg->loadedBG) to scene
        else
          System.out.println("Load error with: " + fn);
      catch( IOException ioe )
      { System.err.println("Could not find object file: " + fn); }
    } // end of loadModel()
  private Vector3d calcScaleFactor(BranchGroup loadedBG, String fn)
  // Scale the model based on its original bounding box size
     BoundingBox boundbox = new BoundingBox( loadedBG.getBounds() );
     // System.out.println(boundbox);
     // obtain the upper and lower coordinates of the box
     Point3d lower = new Point3d();
     boundbox.getLower( lower );
     Point3d upper = new Point3d();
     boundbox.getUpper( upper );
     // store the largest X, Y, or Z dimension and calculate a scale factor
     double max = 0.0;
     if( (upper.x - lower.x ) > max )
       max = (upper.x - lower.x );
     if( (upper.y - lower.y ) > max )
       max = (upper.y - lower.y );
     if( (upper.z - lower.z ) > max )
       max = (upper.z - lower.z );
     double scaleFactor = 10.0/max;    // 10 is half the width of the floor
     System.out.println("max dimension: " + df.format(max) +
                        "; scaleFactor: " + df.format(scaleFactor) );
     // limit the scaling so that a big model isn't scaled too much
     if( scaleFactor < 0.0005 )
         scaleFactor = 0.0005;
     return new Vector3d(scaleFactor, scaleFactor, scaleFactor);
  }  // end of calcScaleFactor()

i mean , how to load few objects in one scene. not sence ..sorry .
if u knwo how to load few objects in . please please give me some help .......Thanks so much

Similar Messages

  • I have iOS 6 on my iPhone. i have linked my contacts with facebook and yahoo, which has doubled or triplicated some of the contacts. how can i integrate them into one? please help. it is getting on my nerves. thanks :)

    I have iOS 6 on my iPhone. i have linked my contacts with facebook and yahoo, which has doubled or triplicated some of the contacts. how can i integrate them into one? please help. it is getting on my nerves. thanks

    click on the contact which you want to integrate, click the edit button scroll down u will find a option called link contacts use it to link it to the duplicate contact

  • How to create authorisation object for save button please help in abap

    how to create authorisation object for save button please help in abap

    Hi
    In general different users will be given different authorizations based on their role in the orgn.
    We create ROLES and assign the Authorization and TCODES for that role, so only that user can have access to those T Codes.
    USe SUIM and SU21 T codes for this.
    Much of the data in an R/3 system has to be protected so that unauthorized users cannot access it. Therefore the appropriate authorization is required before a user can carry out certain actions in the system. When you log on to the R/3 system, the system checks in the user master record to see which transactions you are authorized to use. An authorization check is implemented for every sensitive transaction.
    If you wish to protect a transaction that you have programmed yourself, then you must implement an authorization check.
    This means you have to allocate an authorization object in the definition of the transaction.
    For example:
    program an AUTHORITY-CHECK.
    AUTHORITY-CHECK OBJECT <authorization object>
    ID <authority field 1> FIELD <field value 1>.
    ID <authority field 2> FIELD <field value 2>.
    ID <authority-field n> FIELD <field value n>.
    The OBJECT parameter specifies the authorization object.
    The ID parameter specifies an authorization field (in the authorization object).
    The FIELD parameter specifies a value for the authorization field.
    The authorization object and its fields have to be suitable for the transaction. In most cases you will be able to use the existing authorization objects to protect your data. But new developments may require that you define new authorization objects and fields.
    http://help.sap.com/saphelp_nw04s/helpdata/en/52/67167f439b11d1896f0000e8322d00/content.htm
    To ensure that a user has the appropriate authorizations when he or she performs an action, users are subject to authorization checks.
    Authorization : An authorization enables you to perform a particular activity in the SAP System, based on a set of authorization object field values.
    You program the authorization check using the ABAP statement AUTHORITY-CHECK.
    AUTHORITY-CHECK OBJECT 'S_TRVL_BKS'
    ID 'ACTVT' FIELD '02'
    ID 'CUSTTYPE' FIELD 'B'.
    IF SY-SUBRC <> 0.
    MESSAGE E...
    ENDIF.
    'S_TRVL_BKS' is a auth. object
    ID 'ACTVT' FIELD '02' in place 2 you can put 1,2, 3 for change create or display.
    The AUTHORITY-CHECK checks whether a user has the appropriate authorization to execute a particular activity.
    This Authorization concept is somewhat linked with BASIS people.
    As a developer you may not have access to access to SU21 Transaction where you have to define, authorizations, Objects and for nthat object you assign fields and values. Another Tcode is PFCG where you can assign these authrization objects and TCodes for a  profile and that profile in turn attached to a particular user.
    Take the help of the basis Guy and create and use.
    Regards
    ANJI

  • Hi,how can i transport objects from one server to other like (Dev To Qty)

    Hi Sir/madam,
       Can u explain how can i transport objects from one server to other like (Development To Quality To Production).
    Regards,
    Vishali.

    Hi Vishali,
    Step 1: Collect all Transports(with Packages) in Transports Tab(RSA1)- CTO
    Step 2: Release the subrequests first and then the main request by pressing Truck button
    Step 3: STMS or Customized transactions
    Object Collection In Transports:
    The respective Transports should have the following objects:
    1. Base Objects -
    a. Info Area
    b. Info object catalogs
    c. Info Objects
    2. Info Providers u2013
    a. Info Cubes
    b. Multi Providers
    c. Info Sets
    d. Data Store Objects
    e. Info Cube Aggregates
    3. Transfer Rules u2013
    a. Application Components
    b. Communication Structure
    c. Data Source replica
    d. Info Packages
    e. Transfer Rules
    f. Transformations
    g. Info Source Transaction data
    h. Transfer Structure
    i. Data sources (Active version)
    j. Routines & BW Formulas used in the Transfer routines
    k. Extract Structures
    l. (Note) If the transfer structures and related objects are being transferred without preceding
    Base Objects transport (e.g. while fixing an error) it is safer to transport the related Info
    Objects as well.
    4. Update Rules u2013
    a. Update rules
    b. Routines and formulas used in Update rules
    c. DTPs
    5. Process Chains u2013
    a. Process Chains
    b. Process Chain Starter
    c. Process Variants
    d. Event u2013 Administration Chains
    6. Report Objects u2013
    a. Reports
    b. Report Objects
    c. Web Templates
    Regards,
    Suman

  • How to move database objects from one user to another user

    Could someone help how to move database objects from one user to another user
    Thanks in advance

    Thanks a lot for the reply.
    Actually I wanted to know whether there is any command to change the owner ship of the table.
    For ex table1 belongs to user1. can the owner of table1 to be changed to owner2.
    directly using an oracle command. I knew that it can be done using import and export, since the table was 200 million thought the rename command would be faster instead of import and export.
    Thanks Billy for letting me know that it is not possible using oracle query.

  • How to transport CU02 objects from one system to another?

    Hi,
    How to transport CU02 objects from one system (Development) to another (Quality)?

    You need to set up the object dependency IDOC in the partner profile.Message type is KNOMAS. The transaction to send is CLD2.

  • I installed lightroom 5 with a 30 day trial and it finished. Yesterday I installed cc and when I open LR5 I need a serial number. What do I do/how do I get one? Please help Tank you

    I installed lightroom 5 with a 30 day trial and it finished.
    Yesterday I installed cc and when I open LR5 I need a serial number.
    What do I do/how do I get one?
    Please help, Thank you.

    Your photos remain in place, the catalog you have been using will remain. After you install Lightroom from the CC, all you have to do is open your existing catalog and continue right where you left off.

  • I down loaded about 100 cds to my library and I can no longer view the downloaded artwork it's shows a black picture or blank. How can I get the artwork back? Please help! Thank you

    I downloaded about 100 cds to my library and I can no longer view the downloaded artwork it's shows a black picture or blank. How can I get the artwork back? Please help! Thank you.

    Hi- apparently I also had a similar moment of madness and thought that 'freeride games' would be fun. Well, so much for that! It added a ton of things to my tool bar, I would like to uninstall it, any suggestions for this one?
    thanks :)

  • Do you know of an app like a weekly planner/ diary that I can see and edit in my phone and my boyfriend can on his? Been looking on the app store but can't seem to find one! Please help! :)

    Do you know of an app like a weekly planner / diary that I can see and edit in my phone and my boyfriend can on his? Been looking on the app store but can't seem to find one! Please help!

    Welcome to the Apple Community.
    How about calendar, you can share calendars.

  • I am working on big project and in accidentally flatten the file and i saved it as PSD in then I exited Photoshop. the next time when i open the file it is merged on one page. please help!

    I am working on big project and in accidentally flatten the file and i saved it as PSD in then I exited Photoshop. the next time when i open the file it is merged on one page. please help!

    Flattening and merging are very similar. The main difference is merging keeps the transparent areas, whereas flattening removes all transparent areas by giving it a white background. A good example of flattening is a jpg image.
    Since you have closed the file by closing photoshop, that means that the history is now gone, no way of undoing.
    So that leaves you with two choices.
    You can either recreate the whole document.
    Or you can make selections of areas you are keeping and moving them one at a time to new layers. Keep each object on a separate layer. Then redo the area behind those objects.

  • As an elderly rookie, I don't know how to download, install, & activate this software. Please help!

    I bought this but do not know how to download, install, and activate it. Please help!

    Let's start with the basics. Adobe have a baffling number of choices.
    1. What is your computer system? For example, Windows 7, Mac OS Yosemite
    2. What exactly are you trying to download and install? If you paid for it, check your receipt for the exact name.
    3. Did you pay for it already? If so did you subscribe or get a one time purchase?

  • HT4528 I accidently put all my pics from my computer onto my phone and i have no idea how to get them off. Can u please help me?

    I accidently put all my pics from my computer onto my phone and I have no idea how to get them off. Can u please help??

    PhilipRoy wrote:
    Please see this article about transferring photos from a mobile device to a computer.
    http://support.apple.com/kb/ht4083
    Good luck Friend.
    That's not going to help.  That article is for moving photos from iOS device to computer, not for removing them.  Additionally, photos synced via iTunes cannot be manually removed from the device.  You have to use iTunes to 'unsync' them, as FoxFifth stated.
    Camera Roll pictures are the only ones that can be imported from device to computer.  Album folders cannot be moved from device to computer.

  • Hi. There is a ghost search bar on my iMac screen which flashes constantly, even during start up and shut down. How can i make this go away? Please help. x

    Hi There is a ghost search bar on my iMac that flashes continually, even during start up and shut down. How can i make this go away? Please help. x

    Please read this whole message before doing anything.
    This procedure is a test, not a solution. Don’t be disappointed when you find that nothing has changed after you complete it.
    Step 1
    The purpose of this step is to determine whether the problem is localized to your user account.
    Enable guest logins* and log in as Guest. Don't use the Safari-only “Guest User” login created by “Find My Mac.”
    While logged in as Guest, you won’t have access to any of your documents or settings. Applications will behave as if you were running them for the first time. Don’t be alarmed by this behavior; it’s normal. If you need any passwords or other personal data in order to complete the test, memorize, print, or write them down before you begin.
    Test while logged in as Guest. Same problem?
    After testing, log out of the guest account and, in your own account, disable it if you wish. Any files you created in the guest account will be deleted automatically when you log out of it.
    *Note: If you’ve activated “Find My Mac” or FileVault, then you can’t enable the Guest account. The “Guest User” login created by “Find My Mac” is not the same. Create a new account in which to test, and delete it, including its home folder, after testing.
    Step 2
    The purpose of this step is to determine whether the problem is caused by third-party system modifications that load automatically at startup or login, by a peripheral device, by a font conflict, or by corruption of the file system or of certain system caches.
    Please take this step regardless of the results of Step 1.
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards, if applicable. Start up in safe mode and log in to the account with the problem. You must hold down the shift key twice: once when you turn on the computer, and again when you log in.
    Note: If FileVault is enabled, or if a firmware password is set, or if the startup volume is a software RAID, you can’t do this. Ask for further instructions.
    Safe mode is much slower to start up and run than normal, with limited graphics performance, and some things won’t work at all, including sound output and Wi-Fi on certain models. The next normal startup may also be somewhat slow.
    The login screen appears even if you usually log in automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin.
    Test while in safe mode. Same problem?
    After testing, restart as usual (not in safe mode) and verify that you still have the problem. Post the results of Steps 1 and 2.

  • Finder (Snow Leopard 10.6.8) taking long time to load contents of any directory. Please help?

    In my macbook pro 5,2 snow leopard (10.6.8), Finder taking long time to load contents of any directory. Please help?
    I have already tried to spotlight re-indexing but it did not help. I am hardly able to work on it, almost for each directory I browse its keeps on spinning for 1min.

    Download iTunes from Apple's web site and install it.  Don't use Software Update.

  • I have bought the whole CC and it says my trial has expired. But when i go to license the software, it asks for a serial number and i dont have one. Please help.

    I have bought the whole CC and it says my trial has expired. But when i go to license the software, it asks for a serial number and i dont have one. Please help.

    Sign out from Creative Cloud and sign in again using email ID using which you had purcahsed subscription:
    https://helpx.adobe.com/creative-cloud/kb/sign-in-out-creative-cloud-desktop-app.html
    Then launch CC apps which is asking for serial number and check.
    Still asks for serial number check the hosts file for Adobe entries , if present remove it and try to activate.
    1) Right click on the Finder icon on dock and select "Go-To Folder" option.
    2) You will get a text box, type-in below mentioned command and then hit 'Return' key.
    /etc
    3) It will open the etc folder, please look for file named "hosts" and copy the same to Desktop screen.it
    4)Double click on Hosts file , it will open it with TextEdit, If present Delete Adobe entries present inside Hosts file like 127.0.0.1 activate.adobe.com.......etc
    5)Copy and paste the Hosts file back to "Etc" folder.
    When asked Authenticate with your Mac password.
    Make sure to select "Replace" option when prompted.
    Then launch CC apps which is asking for serial number and check.

Maybe you are looking for

  • Error ORA-01031: insufficient privileges when backup via DB13

    Hi expert, Currently, I have system on SuSE 10 SP2 with ECC6 and Oracle 10.2 installed. Database backup works fine when using BRTOOLS from command line. Error like this : BR0278E Command output of 'SHELL=/bin/sh /oracle/I20/920_32/bin/rman nocatalog'

  • Skype Crashes when using video connection

    Skype crashes when I attempt to use video. I can establish a voice connection with my contact, and all works fine if we are not using video. The moment I enable video in the session, Skype crashes.  This is repeatable. The other end does not need to

  • PO row status

    Hi all How is it possible to trace Purchase Order Item row status to know the SAP User who updated to manually Close Purchase Order Item Row? We would like to know such result at one listing to see all Purchase Orders and Item Rows affected by such M

  • Linker error: error LNK2001: unresolved external symbol __imp_printf

    On a newly installed compiler, Visual Studio 2013, I get some linker error: Sample program (for test): #include <stdio.h> int main () printf("Help"); return 0; I get some linker errors: Error 2 error LNK2001: unresolved external symbol __imp_printf F

  • How to use .iso files

    i have downloaded the solaris 9 zip files n unzipped them into .iso, can anyone plz help me as to what i do next ???? thank you