1 Reply Latest reply on Jan 5, 2009 3:17 PM by Kevin Goldsmith


    the chuck
      I'm wondering if it's possible to make use of Counters in PixelBender when used within Flash. What I'm trying to do is pass in a byteArray that is 2048 bytes long, all set to 0. what would be returned from PixelBender is the equivalent of the following for() loop's actions on the byteAr[] array:

      var byteAr:Array = new Array();
      var counter:Number = 0;
      for (var i:int = 0; i < 2048; i++)
      counter = counter + 0.04;
      if (counter > 1) { counter = counter - 1; }
      byteAr = counter;

      basically, populating a byteArray with values a fixed number of times, that increment over time, and returning it back to flash.

      Is it possible to do this?