3 Replies Latest reply: Nov 6, 2011 4:13 PM by penael RSS

    problem with agal and Vertex

    penael

      i tried with pixel bender 3d  and hardcoding with the same result. My code for the vertex:

       

       

      var

      agalVertexSource:String="m44 vt0, va0, vc0\n"

       

       

       

       

       

       

                              "sub vt1, vt0, vc4\n" +

                               "mov op, vt1 \n"       +

                               "mov v0, va1\n";

      _context3D.setProgramConstantsFromMatrix(

      Context3DProgramType.VERTEX, 0, camTransform,

      true);

       

      _context3D.setProgramConstantsFromVector(

      Context3DProgramType.VERTEX, 4, Vector.<Number>([0.5,0.0,0,0]));

       

      All i want is a translation of the vertex (sub...) after the multiplication by a matrix (m44...). The result : the program translate the point and then multiply the result by the matrix.