Học Actionscript 3.0 - p 38 pot
... sp.graphics; 32 g.beginFill(0x 000 000 ); 33 g.drawRect (0, 0, 32 0, 2 40) ; 34 g.endFill(); 35 return sp; 36 } 37 38 private function createButton(xLoc:Number, labl:String, 39 func:Function):void { 40 var ... "Pause", pauseVideo); 26 createButton(2 20, "Stop", stopVideo); 27 } 28 29 private function drawBackground():MovieClip { 30 var sp:MovieClip = new M...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 7 pot
... introduced or updated by ActionScript 3. 0. Next, we start off the ActionScript 3. 0- specific material with a look at the three essential building blocks of most ActionScript objects: properties, methods, ... changed ele- ments of ActionScript with the introduction of version 3. 0. In the next chapter, we’ll discuss: • The descriptive properties, such as width, height, lo...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 15 pot
... import flash.display.MovieClip; 4 import flash.display.Graphics; 5 import flash.events.Event; 6 7 public class Box extends MovieClip { 8 9 public var color:uint = 0x 000 099; 10 11 public function ... <www.wowebook.com> Inheritance Chapter 6: OOP 1 23 14 this.graphics.drawRect (0, 0, 100 , 100 ); 15 this.graphics.endFill(); 16 17 this.addEventListener(Event.ENTER_FRAME, onLoop,...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 19 potx
... list in line 44. 34 private function onRun(evt:Event):void { 35 _yVel += _grav; 36 _xPos += _xVel; 37 _yPos += _yVel; 38 x = _xPos; 39 y = _yPos; 40 41 if (_xPos < 0 || _xPos > stage.stageWidth ... the particle. 13 public function Particle(xPos:Number= 100 , yPos:Number= 100 , 14 scale:Number=1, opacity:Number=1, 15 xVel:Number=4, yVel:Number =- 10, 16 grav:Number=1)...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 24 pot
... code. 1 var rect:Sprite = new Sprite(); 2 addChild(rect); 3 var g:Graphics = rect.graphics; 4 g.lineStyle(1, 0x 000 000 ); 5 g.beginFill(0x00FF 00, 0. 4); 6 g.drawRect (0, 0, 100 , 50) ; 7 g.endFill(); 8 ... colors:Array = [0xFF 000 0, 0x 000 000 ]; 10 var alphas:Array = [1, 1]; 11 var ratios:Array = [0, 255]; 12 13 var matrix:Matrix = new Matrix(); 14 matrix.createGradientBox( 200 ,...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 26 pot
... ds:DropShadowFilter = new DropShadowFilter(); 2 ds.blurX = 10; 3 ds.blurY = 10; 4 ds.alpha = 0. 6; 5 6 var sp:Sprite = new Sprite(); 7 var g:Graphics = sp.graphics; 8 g.lineStyle(1, 0x 000 000 ); N ... <www.wowebook.com> The BitmapData Class Chapter 9: Drawing with Pixels 229 opacity, and then 00 00FF, or blue, for the color. The result of this script is a 100 × 100 –pixel, 100...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 27 pot
... Pixels 239 9 g.beginFill(0xFFFF 00, 1); 10 g.drawRoundRect (0, 0, 200 , 50, 20) ; 11 g.endFill(); 12 13 sp.filters = [ds]; 14 addChild(sp); Because we went the simple route of using a sprite for our interactive ... noChange:ConvolutionFilter; 3 var brightness:ConvolutionFilter; 4 5 var blackArr:Array = [0, 0, 0, 6 0, 0, 0, 7 0, 0, 0] ; 8 black = new ConvolutionFilter (3,...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 30 pot
... VerdanaPlain. Figure 1 0- 4. Font Symbol Properties (CS4 pictured) Download from Wow! eBook <www.wowebook.com> Part III: Text 276 Formatting with HTML and CSS Table 1 0- 2. The CSS properties supported ... Professional CS3 or CS4 is to create a new font symbol from the Library panel’s menu, seen in Figure 1 0- 2. In the resulting Font Symbols Properties dialog—Figures 10 -3 (CS...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 35 potx
... addChild(vis); 100 - (-1 .0 * 100 ) = 200 100 - ( -0 . 5 * 100 ) = 1 50 100 - (0. 75 * 100 ) = 25 y: 100 y: 200 y: 0 Figure 1 1-9 . A few sample amplitude calculations, and where they appear in an example waveform Download ... onVisualize, 20 false, 0, true); 21 } 22 23 private function onVisualize(evt:Event):void { 24 SoundMixer.computeSpectrum(_bytes, _fft)...
Ngày tải lên: 06/07/2014, 18:20
Học Actionscript 3.0 - p 3 pot
... focused on the object-oriented programming (OOP) capa- bilities of ActionScript 3. 0, and the language’s power really shines in this area. However, embracing ActionScript 3. 0 doesn’t mean that ... ActionScript 3. 0? Chapter 1: What Is ActionScript? 5 • The Document Class. Object-oriented programming is not for every- one, but for those starting on the OOP journey, Flash offe...
Ngày tải lên: 06/07/2014, 18:20