2 Replies Latest reply on Apr 13, 2010 11:42 AM by Niko Miranowicz

    Strange rendering while rotating blended objects...

    Niko Miranowicz

      Hello,

      I have a problem (I posted it also elsewhere but hoping for broader solution). I am creating a simulation application with cylindrical object representing glass which are moved around and rotated. When such glassy object is inside another while rotating the world it seems like its surface is inverting. I have prepared simplified example of this (http://zdch.amu.edu.pl/director/pr4.html, http://zdch.amu.edu.pl/director/pr4.dir) with a stack of cylinders with blend 60 that are in interposition with another cylinder. During animation, when seen at front for some short time one can notice a change (http://zdch.amu.edu.pl/director/Picture.png) half of the cylinders in the stack are in front of the big one and three steps further they are in the back while the other half of the stack appears in the front. As far as I tested it doesn't depend on the renderer. It may be reproduced with this code in two following frames and a 3dworld...

       

       

      first frame:

      on exitFrame me

        wd=sprite(2).member

        member(1).resetworld()

       

        mr=sprite(2).member.newmodelresource("mr", #cylinder, #both)

        mr.bottomRadius = 5

        mr.topRadius = 5          

        mr.height = 30

       

        mm=wd.newmodel("ml", mr)

        mm.transform.position=vector(0,0,0)

        mm.transform.scale=vector(5,5,5)

       

        ml=list()

        wd.shader[1].blend=60

       

        repeat with a=1 to 10

          ml[a]=wd.newmodel("ml"&a, mr)

          ml[a].transform.position=vector(25,a*15-100,0)

          ml[a].transform.scale=vector(5,0.5,5)

        end repeat

       

       

      end

      second frame:

      on exitFrame me   member("lab").camera(1).rotate(vector(1,0,0),#world)

      go to the frame

      end

       

      Thank you for help or comments

      Nikodem