3D efect problem

Hello.
I'm new here and just start my adventure with as3.
I have a problem with a 3D effect during play a rotation of the cube.
I made a cube with sample textures and texture of the walls while playing "overlap" each other.
Source code:
function rotate(e:Event){
cube.rotationX+=0
cube.rotationY-=1
stage.addEventListener(Event.ENTER_FRAME,rotate)
Source files to download
http://www.fhu-projektor.pl/flash/cube.fla
Please help.

Flash does not sort display list z-order according to the z position, so that even if something is behind in the 3D space it appears on top if it has a higher display order index. You need to sort this out manually...
Before do this you need to re construct your cube so that it consists of 6 single MovieClips (instead of collection of nested MovieClips).
import flash.display.DisplayObjectContainer;
import flash.display.DisplayObject;
import flash.events.Event;
function rotate(e:Event) {
    cube.rotationX +=  0;
    cube.rotationY -=  1;
    try {
        sortZ(cube);
    } catch (e) {
function sortZ(container:DisplayObjectContainer):void {
    var sortArray:Array = new Array();
    var i:uint;
    var childCount:uint = container.numChildren;
    for (i = 0; i < childCount; i++) {
        var child:DisplayObject = container.getChildAt(i);
        var zLoc:Number = child.transform.getRelativeMatrix3D(stage).position.z;
        sortArray.push({displayObject:child, screenZ:zLoc});
    sortArray.sortOn("screenZ", Array.NUMERIC | Array.DESCENDING);
    for (i = 0; i < childCount; i++) {
        container.setChildIndex(sortArray[i].displayObject, i);
stage.addEventListener(Event.ENTER_FRAME,rotate);
(The credit goes to Ralph Hauwert http://unitzeroone.com/blog/?s=zsort)

Similar Messages

  • Google Services Framework message

    " The application Google Services Framework (process com. google.process.gapps) has stopped unexpectedly.  Please try again."
    I keep getting this message even when nothing is open.  When someone calls me it shows up.  When it is just sitting there it shows up.  How do get this to go away?

    @2feedthesoul, I found the following link with a potential solution for your problem. Check it out:
    The following steps are detailed on the link:
    Quick and simple solution for that bug - i have try to follow all post that i was able to find but nothing works
    brand new samsung galaxy s 19000 - android 2.2.1
    1. turn off sync - you can do just for google calendar [ this is faulty one ]
    2.go to settings->apps ->manage apps ->all
    3. find calendar storage -> clear cache -> clear
    4.find calendar sync -> clear
    5.reboot phone
    6. reeneble sync
    Simple and efective, problem gone - anyway it works for me
    Here is the link: http://www.google.pl/support/forum/p/Google%20Mobile/thread?tid=19a2949acbcf019f&hl=en
    It seems that this is one of the google apps. Some say its the Calendar sync, some say its GoogleTalk. Either ways, you can try the steps above for Calendar.
    Hope this helps!

  • P35Neo2 FIR and problem with booting

    So I have problem with booting my compie. Compie try to boot to the part of start windows, after that in case of switch into graphicis mobo going down and restarting (WinXP SP3). I think, that problem is not in PSU, cos i have 800W XILENCE (+3,3V 28A, +5V 32A, 4x+12V 20A, -12V 0,5A, 5VSB 3A), Board P35 Neo2 FIR, E7200 proc, bios 1.9 (updated). I have 5 disk and use raid function in bios. Graphic Radeon HD3650, Memory Zeppelin 4x1GB KIT 800Mhz.
    I start with change of PSU from 550W to 800W but it didnt work, previus PSU had (+3,3V 30A, +5V 32A, 2x+12V 18A, -12V 0,8A, 5VSB 3A),
    i try change memory, but no efect.
    After update bios there was standard warning about bad cheksum, after resave Bios settings it was gone, and compie boot after that.
    Any idea?
    Thanks

    So my problem is solved...but my feeling of this is not good...
    I updated BIOS from 1.9 to 1.10, reset Bios settings, after restart i pressed F2 for load standart settings and i changed in Bios only that i am using RAID and disable disket and it works...i boot my compie into windows without any problem...
    So i try change another things in Bios and my compie hangs in continous resets without booting into windows...no BSOD only restart and restart...
    After reseting Bios settings and again Load to Default it works...and run windows...
    There was only one new thing ... screen flick for the second with new screen about checking NVRAM ....this screen was not visible before (and maybe this is the problem), cos if i change something in BIOS about clocking and power management and other ones, this screen is by booting missing...and compie not run in Windows...
    Next thing what i see, that in CPU multiplication dont work multiplication 9,5 and proc used frequency 2400 (9x) (it is E7200 on 2533)
    i hope that this bios 1.10 fixed my problems...and my opinion is that P35 Neo 2 FIR is not ideal board for E7200 proc...so i m looking for another proc...and maybe another board...

  • Problem with checkbox column in matrix

    Hello.
    I have a little problem with checkbox column in matrix.
    Column is binded to the UserData.
    It has ValOn="Y", ValOff="N".
    I use C++. It is wird problem. In matrix I have 10 columns - scrollbar role and if You want see checkbox column, You must role to the right. If this column is on the screen, and I use:
    checkcell->PutChecked(VARIANT_TRUE);
    then the checkbox is cheched, and if the checkbox isn`t on the screen and I use this comment - it nothing happening.
    I tried to use ValOn="Y", PutChecked...
    The problem i solved if the column is on the screen - if the column is first in matrix or second, but if it`s last I have a big problem.
    My column with checkbox is not editable, but I tried to make it editable, check it, and then make it uneditable - the same efect.
    How can I solve it ?
    Sorry for my english.
    Kamil Wydra

    Hello Kamil,
    I am not sure about your problem, but here is an example of how to use checkbox in UI API.
    First, create the matrix with checkbox column in Screen painter, and the output is an xml file, like this. Type as 121 indicates that it is a check box.
    - <column AffectsFormMode="0" backcolor="-1" description="" disp_desc="0" editable="0" right_just="0" title="Rented" type="121" uid="Rented" val_off="N" val_on="Y" visible="1" width="41">
      <databind alias="U_RENTED" databound="1" table="@VIDS" />
      <ExtendedObject />
    Second, bind the column to table from DB. This is a bug of 2004 Screen Painter, so if you are using 2005 Screen Painter, there is no problem.
    Third, when you open the form, you can check and uncheck the cell.
    BTW, please set the editable of the column to true.
    Hope this helps,
    Nick

  • Problem in actions change before ear retro date 1.4.2011 acc to controlreco

    HI Experts,
    Got an issue while performing an action "International assignent reentry".
    One of my employee has returned from international assignement.While performing an action   "International assignent reentry"
    i am getting an error  "Change before earlist retro date 01.04.2011 according to control record ss".It is showing while updating the payroll area and personnel subarea in 0001 IT.
    We are trying to do action with the date 15.07.2011.
    In pu03  earliest pers. RA date mentioned as 01.04.2011,earliest MD change,bonus change as 15.07.2011.
    In control record ..earliriest retro accounting period as 01 2011 which is April 2011.
    Now control record is on Exit mode.
    Please advice me to resolve the problem.
    Regards,
    Sairam.

    HI
    Thanks for the reply.If we remove  the  date in earliest per. retro accounting..what are the implications.
    in pu03 ..earlist pers. RA date is maintained as 01.04.2011
    We are doing an action with efective from 15.07.2011.
    Why the system is showing an error ""change before earliest retro date  1.4.2011 acc to control record to PY area ss.""
    After deletion of date in the field of Earlist pers. RA date from puo3 ..after doing the action..shall we put the date as 01.04.2011 in the fiels.
    Please advice.
    Sairam.
    Even after deleting the  Earl. pers RA date also ..we are getting the same error.
    The payroll control record is in exit mode.
    Please advice.
    Sairam.
    Edited by: sathyasairam on Jul 18, 2011 1:54 PM

  • Problems displaying characters on the terminal

    This screenshot shows my problem.
    When i type anything in the console, it starts doing this funny efect... and, of course, is a bit confusing since somethimes you cannot see what you are typing.
    Video card is a nvidia one: Compiz fusion activated and free drivers installed (same issues happened to me with the propietary ones)
    Any ideas on how to fix it?

    Try --indirect-rendering and/or --loose-binding for compiz. I'm not too sure if these are the exact names of the options but it should be something alike.
    Last edited by kowalski (2009-08-25 08:44:18)

  • Bapi problem - again

    Sorry to all of you with probably the same problem but i can't find solution.
    Anyway i'm trying to write simple WD which will make in target system user.
    I'm using BAPI_CREATE_USER FM.
    I did everything like in ohter examples of consuming transaction FM (BAPi).
    Anyway will post some code so maybe you will finde some bugs.
    I made model with my bapi and bapi_transaction_commit of course.
    in wdDoInit of custom controler i wrote:
        Bapi_User_Create_Input input = new Bapi_User_Create_Input();
         wdContext.nodeBAPI_USER_CREATE_INPUT().bind(input);
         input.setPassword(new Bapipwd());
         input.setAddress(new Bapiaddr3());
         input.setUsername("");
            Bapi_Transaction_Commit_Input inputTrans = new Bapi_Transaction_Commit_Input();
            wdContext.nodeBAPI_TRANSACTION_COMMIT().bind(inputTrans);
         inputTrans.setWait(true);
    i wrote 2 methods for both bapi
    1st.
        try{
             wdContext.currentBAPI_USER_CREATE_INPUTElement().modelObject().execute();
              wdContext.nodeOutput().invalidate();
        catch (Exception ex){
              ex.printStackTrace();
    2nd
         try {
              wdContext.currentBAPI_TRANSACTION_COMMITElement().modelObject().execute();
              wdContext.nodeOutput().invalidate();
         } catch (Exception ex){
              ex.printStackTrace();
    View contains 4 input fields for user name, name, last name and password.
    All of them are binded to the context.
    Button create user triger code:
        try{
              wdThis.wdGetUserCreateCustController().executeBAPI_USER_CREATE_INPUT();
        catch(Exception ex){
              wdComponentAPI.getMessageManager().reportWarning(ex.toString());
        wdThis.wdGetUserCreateCustController().executeBAPI_COMMIT();
    What i'm doing wrong?
    It dosent efect target system.
    It dosen't even start fm because i try to debug it.
    PS. I'm new to WD so sorry for some stupid things.

    Hi,
    1.first check whether the BAPi is working correctly with same values which u have set it in ur web dynpro application.
    2. Check whether any exception is thrown: after executing the model use message manager to report exception.
    wdComponentAPI.getmessageManager().reportException(ex);
    or u can find the error logs in the NWA . login to NWA --> Problem management --> logs and Tracess --> log Viewer.
    Thanks and Regards

  • New problem of '' Replace with after effect composition ''

    Hi
    i'm a new user of adobe premiere pro , and i have really a big problem on it and i tired of searching about solution but with out any result , the whole problem is when i select a footage and right-clicking from the premiere timeline , the option of '' Replace with atfer effect composition '' is empty and this sentence has a Gray color wich means you can't open it .. i have  the CC demo versions for the both of atfer efect & premier , but i want to know if there is a solution for this or its normle just i have to buy the licence
    plzzz i need a solution :/

    Did you set AE as the default application for after effects projects (AEP) format?

  • JClient/ADF dynamic isAttributeUpdateable problem.

    Hi,
    JDev 10.1.2 JClient/Struts/ADF
    I have a same Entity based VO that is used by my Struts and JClient application.
    In my Entity I have a flag field that enables/disables input in other fields:
    The problem is that the JTextFields are not refreshed when the flag is changed and the the fields are not enabled or disabled.
    My question:
    What is the best method to call in the model so that the JClient panel re-reads the IsAttributeUpdateable method?
    The main problem occurs when creating a new row.
    I found a solution by calling for all fields with dynamic IsAttributeUpdateable value:
    this.populateAttribute(ADDRESS1LATIN,this.getAddress1Latin(),true,false,false);
    in the set method of the flag but I have following side efect:
    When submitting a new created row in my Struts app. with errors, the pending changes on those fields are reset on the first submit.
    On the second submit pending changes are displayed.
    I tried a JClient solution by calling:
    this.getPanelBinding().refreshControl();
    when the checkbox state is changed but it doesn't work, the previous state is recalled.
    More info:
    Entity extract:
    Entity Address:
    Flag IsInLatinLang 0/1, default is 0
    If set to 1 then following fields are enabled:
    AddressPart1Latin
    AddressPart2Latin
    public boolean isAttributeUpdateable(int index)
    switch (index)
    case ADDRESS1LATIN:
    case ADDRESS2LATIN:
    case CITYLATIN:
    case CONTACTNAMELATIN:
    case NAMELATIN:
    if (this.getIsInLatinLang().equals(Constants.NUMBER_YES))
    return true;
    else
    return false;
    Any advice will be appreciated.
    Regards
    Fred

    repost

  • Problem with ScrollingImagePanel. I can't refresh the modified image.

    Hello friends. I am new at the "Java World". At first, sorry for my bad English. Lets go:
    In my aplication I have to show a tiff image in a ScrollingImagePanel.I aplly some efects on the image, for example rotate, flip, etc.
    It is working fine, but I have problem to refresh the image in the same ScrollingImagePanel.The code compiles but I have exceptions when I run the method:
    public void atualiza(){
    if (ziboro == false){ //no image displayed yet.This part works
    ziboro = true;
    JInternalFrame teste = new JInternalFrame("teste",true,true,true,true);
    teste.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
    teste.addInternalFrameListener(this);
    teste.setLocation(10,10);
    teste.setSize(new Dimension(200,200));
    ScrollingImagePanel FlipVPanel = new ScrollingImagePanel(imagemBufa, 800, 800);
    teste.getContentPane().add(FlipVPanel);
    displayPanel.add(teste);
    teste.setVisible(true);
    teste.moveToFront();
    else{
    // here I want to refresh the modified image.This part is my problem
    teste.getContentPane().remove(FlipVPanel);
    ScrollingImagePanel FlipVPanel = new ScrollingImagePanel(imagemBufa, 800, 800);
    teste.getContentPane().add(FlipVPanel);
    teste.setVisible(true);
    teste.moveToFront();
    I think the problem is when I try to remove the ScrollingImagePanel.
    Please help me, you are my hope. If you now another solution to show images at ScrollingImagePanel and refresh the image, please send me.
    Thanks a lot people!

    The way to find out is look under project info again. If it gives you an option to switch to double layer disc, like it does with me. Then that signals that your computer can handle them. Thats what I remember reading anyway.

  • MSI VOX TV@nywhere -- Problems with blinking in down side of the window

    I write to you because i saw your site and posts on forum.
    First sorry for my bad english,but i need help...   
    I bought MSI USB TV@nywhere card yesterday, and i install
    the drivers etc, but i have problems with connection on
    COMPOSITE and S-VIDEO. When i set device to any of that two
    connections and play video form DVD component player, i got a
    picture and sound but i have some blinking (blinkering) efekt in place
    of subtitles (down bar on the MSI PVS window).
    First i have black bar on the screen,and behind is playing video, and if
    I change types to PAL-B or any other, then it starts to blink and gets me
    picture same like upper side of the window with blinking effect (name of the
    connection is blinking on that "bar" in the application window).
    on TV i have no problems, it works good.
    i download new driver but i have the same efect...
    did anybody have same problem, or you know how to make it works normaly?
    thanks for all....
    Dejan

    I write to you because i saw your site and posts on forum.
    First sorry for my bad english,but i need help...   
    I bought MSI USB TV@nywhere card yesterday, and i install
    the drivers etc, but i have problems with connection on
    COMPOSITE and S-VIDEO. When i set device to any of that two
    connections and play video form DVD component player, i got a
    picture and sound but i have some blinking (blinkering) efekt in place
    of subtitles (down bar on the MSI PVS window).
    First i have black bar on the screen,and behind is playing video, and if
    I change types to PAL-B or any other, then it starts to blink and gets me
    picture same like upper side of the window with blinking effect (name of the
    connection is blinking on that "bar" in the application window).
    on TV i have no problems, it works good.
    i download new driver but i have the same efect...
    did anybody have same problem, or you know how to make it works normaly?
    thanks for all....
    Dejan

  • Help 5th gen Ipod charging problem (I searched)

    Hello,
    I'm new here and have a rather frustrating problem.. my Ipod (30gb) is not charging. I can not charge it trough USB or AC adapter. It is just showing that it is charging and after I take it of (I have been charging it for like a week) and the battery shows almost emptj after surfing trough menues and finding a song - pushing play the battery runs out compleaty and the Ipod shuts down after that when I conect it it shows the black battery with the lightning bolt on the side.. but no efect on the charging. The interesting thing is that I brought it in service and they charded it but I cant..
    Any suggestions?
    Hp pavilion ze4900   Windows XP  

    Not Charge
    - See:      
    iPod touch: Hardware troubleshooting
    - Try another cable. Some 5G iPods were shipped with Lightning cable that were either initially defective or failed after short use.
    - Try another charging source
    - Inspect the dock connector on the iPod for bent or missing contacts, foreign material, corroded contacts, broken, missing or cracked plastic.
    - Make an appointment at the Genius Bar of an Apple store.
    Apple Retail Store - Genius Bar                          

  • WRT54gc speed problem

    hy. i've got more of a question than a problem to be honest. and i must also say i understand the technical terms in networking but i ain't that good and i'm sorry if i can't really make myself clear.
    until about 5 days ago my Internet Connection was made through a modem which was connected to the router thus having internet to 4 computers (2 LAN, 2 Wireless). during this time, my router was configured with Automatic DHCP (or something like that) and a MAC clone of my PC.during this time and after about 4 years of fidelity , my internet connection was of about 6MB => ~700kbs download.
    now, my ISP provider "upgraded" my  connection and have direct cable connection. anyway, i now have a user name & a password. i switched the connection type to PPoE but i did not change anything else. the other settings are the same: MAC clone, open ports,Wireless MAC filters.
    So here is my problem:
    -if my PC is directly connected to the internet, i can achieve an efective download speed of 10 MBs (100 Mb connection or something like that) and upload speed of 1,6 MBs (12 Mb connection)
    -if i connect through the router i can only achieve about 3 MBs download speed (only 2,5MB the other PC LAN connected -> weird i'd say).
    As far as i know, the router should allow speeds of 10 MBs for 1 PC if the other computers aren't connected or don't need internet at a given time.
    So i was wondering if this speed problem could be related to the fact that i still have the other settings (mostly the MAC clone of my PC; this is the only one i can think of that might create a problem) or it might just be hardware related (doesn't allow me better speeds or something).

    well, since yesterday, i've reseted the router and only added the user name & password provided by my ISP but still it doesn't work as it should.
    about my connection, as far as i can say, my contract with my ISP has been modified from the cable contract to a fiberlink contract, most likely the cheapest (they have 2 kinds of contracts). but even with this cheap-fiber contract, i still should have a total 10MBs download speed! yet, my exact connection is of about 3MBs DL speed total. i know this because i used for download 2 PCs and have 3MBs DL and 1,5MBs UP.
    anyway, if it help here is how i think my contract looks like:
    Maximum bandwidth in your town -> 50 Mb / s
    Maximum Internet bandwidth        -> 50 Mb / s
    Traffic with maximum bandwidth on internet -> unlimited
    is it possible that the router only uses the Internet bandwidth ??? if so, is it possible to configure it so it uses the other one too?
    or is it just hardware limitations ?
    Message Edited by dejeuro on 03-03-2010 02:39 AM

  • FC HD export problem (samples missing)

    Hi
    I have Final Cut Express HD 3.0 on a G5 1,8 Dual with OSX 10.3.9
    It all worked fine for a long time, but now, when I export a sequence, I have missing audiofiles eg not all audiofiles applied in the project are exported. I can hear my samples fine when I play the movie on the timeline... But as soon as I export the sequence, about 30% of my samples randomly don't get exported.
    What can I do? Any help would be appreciated, thank you.

    Hi Marco i had the same problem to........ still do have but what i do is exporting again and again ....... usually second time its ok. I think we have some missing link somewhere in exporting files.......usualy hapend in parts of the footage where you edit a efect transition to a footage and you poot the sound markers to lower the sound....(mix the music and voice).
    What i do is i work on project i fix all music and sound from pic and at the and i ad the picture efects....ussualy work for me......

  • I have problem with  the  creativeCloudSet-up

    hi  today  i am  try  to  install Creative Cloud  for After  Efect CC  See My  Problem

    uninstall anything cc that's been installed, clean (Use the CC Cleaner Tool to solve installation problems | CC, CS3-CS6) and retry installing.

Maybe you are looking for