In case Flash no longer exists; a copy of this site is included in the Flashpoint archive's "ultimate" collection.

Dead Code Preservation :: Archived AS3 works from wonderfl.net

forked from: forked from: forked from: ColorModeHSVSample

see http://gihyo.jp/design/feature/01/frocessing/0002
Get Adobe Flash player
by travis 03 Aug 2009
    Embed
/**
 * Copyright travis ( http://wonderfl.net/user/travis )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/yNpG
 */

// forked from musicbob88's forked from: forked from: ColorModeHSVSample
// forked from tsutaya42's forked from: ColorModeHSVSample
// forked from nutsu's ColorModeHSVSample
// see http://gihyo.jp/design/feature/01/frocessing/0002
package  
{
    import frocessing.display.F5MovieClip2D;
    
    [SWF(width=465,height=465,backgroundColor=0x000000)]
    public class ColorModeHSVSample extends F5MovieClip2D
    {
        public function ColorModeHSVSample() 
        {
            var n:int = 4;
            
            //線は描画しない
            noStroke();
            
            //HSVで色指定
            //値の範囲を,色相(0~n),彩度(0~1),明度(0~n)に指定
            colorMode( HSV, n, 1, n );
            
            for ( var i:int = 0; i <= n; i++ ) {
                for ( var j:int = 0; j <= n; j++ ) {
                    
                    //塗りの指定
                    fill( i, 1, n - j );
                    
                    //円の描画
                    var cx:Number = 33 + 40 * i;
                    var cy:Number = 33 + 40 * j;
                    circle( cx, cy, 19 );
                }
            }
        }
    }
}