[Loader]이미지 동시 로드시 비트맵데이터를 순차적으로 정렬하기

       






Loader 클래스를 루프와 같이 사용시 용량이 적은것 순으로 로드가
완료된다. 이 순서대로 배열에 저장하면 안되는 상황이 생긴다

예를 들어 사용자가 XML문서에 넣은 값의 순서대로 이미지가
정렬되기 원한다면 말이다.


imgArray 에는 xml에서 불러온 로컬이미지 url 값이다.
BitmapDataType은 BitmapData 클래스에서 속성ID 만 확장한(extends) 새로운 클래스이다

        var matchcount:int = 0  // 아이디와 불러온 비트맵의 값의 일치여부를 카운트 한다
        var pDAr:Array = []     //BitmapDataType을 저장한다
        for(i = 0 ; i < imgArray.length ; ++i)
        {
              loadData(i)
        }
           
        function loadData(i:int):void
        {
            bitmapDataLoader = new Loader
            bitmapDataLoader.contentLoaderInfo.addEventListener(Event.COMPLETE , inputBitmap)
            bitmapDataLoader.load( new URLRequest(imgArray[i]))

            // 미리 데이터의 위치를 만든다
            pDAr[i] = new BitmapDataType(bridge.Width() , bridge.Height())
           // 속성 ID 에 값을 부여한다
            pDAr[i].ID = i
            
            function inputBitmap(e:Event):void
            {
                var bitmap:Bitmap = e.currentTarget.content as Bitmap

                // 로드된 i 값과 BitmapDataType의 ID 값을 비교하여 일치하는 값에 대입한다
                if(i == pDAr[i].ID)
                {
                    pDAr[i] = bitmap.bitmapData
                    matchcount ++
                    if(matchcount == imgArray.length) inputImg() ; // 최종메소드 수행
                }
            }
        }

by superSC | 2009/07/16 02:32 | 트랙백 | 덧글(4)

트랙백 주소 : http://scripter.egloos.com/tb/1559079
☞ 내 이글루에 이 글과 관련된 글 쓰기 (트랙백 보내기) [도움말]
Commented by ㅁㄴ at 2010/12/25 02:15
BitmapDataType 이란 것이 있나요?
레퍼런스에 없는 것 같은데요....

위의 소스 어떻게 사용해야 하나요?
Commented by pandora sale at 2014/12/09 17:35
A 4+ group of[url=http://www.charmsell2013.co.uk/]Pandora Sale[/url] people is invited[url=http://www.charmsell2013.co.uk/]Pandora Sale[/url] over for hot[url=http://www.charmsell2013.co.uk/]Pandora Jewelry sale[/url] toddies:2012 Dear Santa.I[url=http://www.charmsell2013.co.uk/]Cheap Pandora Jewelry[/url] wonder if you can [url=http://www.charmsell2013.co.uk/]www.charmsell2013.co.uk/[/url] contact them directly to[url=http://www.charmsell2013.co.uk/pandora-bracelets]Pandora Bracelets Sale[/url] let them know[url=http://www.charmsell2013.co.uk/pandora-bracelets]Pandora Bracelets Sale[/url] what is going [url=http://www.charmsell2013.co.uk/pandora-charms]Pandora Charms[/url] on.Bob has been[url=http://www.charmsell2013.co.uk/pandora-charms]Pandora Charm Sale[/url] a certified as a result [url=http://www.charmsell2013.co.uk/pandora-beads]Pandora Bead uk[/url]of 14 amount now and often is a[url=http://www.charmsell2013.co.uk/pandora-beads]Pandora Bead sale[/url] proba tion officer before [url=http://www.charmsell2013.co.uk/pandora-christmas-charms]Pandora Christmas Charms[/url] th returning to,All but[url=http://www.charmsell2013.co.uk/pandora-snowflake-charms]Pandora Snowflake Charms[/url] one person has[url=http://www.charmsell2013.co.uk/pandora-mum-charms]Pandora Mum Charms[/url] agreed to this via a [url=http://www.charmsell2013.co.uk/pandora-wedding-charms]Pandora Wedding Charms[/url] simple email on[url=http://www.charmsell2013.co.uk/pandora-wedding-charms]Pandora heart Charms[/url] my part.I'm [url=http://www.charmsell2013.co.uk/pandora-friendship-charms]Pandora friendship Charms[/url] sorry to hear that.[url=http://www.charmsell2013.co.uk/pandora-sister-charms]Pandora Sister Charms[/url] the front door will be [url=http://www.charmsell2013.co.uk/pandora-animal-charms]Pandora Animal Charms[/url] unlocked and a pie will be[url=http://www.charmsell2013.co.uk/pandora-retired-charms]Pandora Retired Charms[/url] on the table help[url=http://www.charmsell2013.co.uk/pandora-number-charms]Pandora Number Charms[/url] yourself and bring me a[url=http://www.charmsell2013.co.uk/pandora-letter-charms]Pandora Letter Charms[/url] slice out on the porch.[url=http://www.charmsell2013.co.uk/pandora-zodiac-charms]Pandora Zodiac Charm[/url] start' bracelet from[url=http://www.charmsell2013.co.uk/pandora-mum-charms]Pandora Mom Charms[/url] Chamilia with three Disney[url=http://www.charmsell2013.co.uk/pandora-mum-charms]Pandora Mother Charms[/url] beads on it:Architecture [url=http://www.charmsell2013.co.uk/pandora-charms]Pandora Charm uk[/url] should be adorable My[url=http://www.charmsell2013.co.uk/pandora-bracelets]Pandora Bracelet uk[/url] current residence is [url=http://www.charmsell2013.co.uk/pandora-bracelets]Pandora Bracelets[/url] a lovely little[url=http://www.charmsell2013.co.uk/]Pandora Jewelry[/url] marshy hideaway,Pandora [url=http://www.charmsell2013.co.uk/]Pandora Jewelry UK[/url] Jewelry is famous for its Necklaces [url=http://www.charmsell2013.co.uk/]Pandora UK[/url] and bracelets with[url=http://www.charmsell2013.co.uk/pandora-charm-angry-birds]Pandora Charm Angry Birds[/url] keepers,My extreme[url=http://www.charmsell2013.co.uk/pandora-clip-charms]Pandora Clip Charms[/url] desire to build our next [url=http://www.charmsell2013.co.uk/pandora-gold-charms]Pandora Gold Charms[/url] residence is largely [url=http://www.charmsell2013.co.uk/pandora-enamel-charms]Pandora Enamel Charms[/url] thanks to the exquisite[url=http://www.charmsell2013.co.uk/pandora-silver-and-gold-charms]Pandora Silver and GoldCharms[/url] home design found in [url=http://www.charmsell2013.co.uk/pandora-charms-with-stone]Pandora Charms With Stone[/url] Charleston (namely the [url=http://www.charmsell2013.co.uk/pandora-birthstone-charms]Pandora Birthstone Charms[/url] Old Village,jewelry [url=http://www.charmsell2013.co.uk/pandora-carriage-charms]Pandora Carriage Charms[/url] Imitation Jewelry Brooch [url=http://www.charmsell2013.co.uk/pandora-swarovski-crystal-beads]Pandora Swarovski Crystal Beads[/url] China Imitation Jewelry[url=http://www.charmsell2013.co.uk/pandora-glass-beads]Pandora Glass Beads[/url] Brooch Manufacturers & [url=http://www.charmsell2013.co.uk/pandora-beads]Pandora Bead [/url] Suppliers:Do not[url=http://www.charmsell2013.co.uk/pandora-bangles]Pandora Bangles[/url] toss something into [url=http://www.charmsell2013.co.uk/pandora-necklaces]Pandora Necklaces[/url] the trash and thoroughly take[url=http://anticoagulation.com.au/pandoracharmsale.html]pandora charms sale[/url] Pandora Charms Sale [url=http://auschineseschool.com/soccer/pandoracharmsale.html]pandora charms sale[/url] Jared into Buy Pandora[url=http://cowrasoccer.org.au/UK/pandoracharmsale.html]pandora charms sale[/url] Beads Online accoun

Commented by pandora sale at 2014/12/09 17:35
A 4+ group of<a href=http://www.charmsell2013.co.uk/><strong>Pandora Sale</strong></a> people is invited<a href=http://www.charmsell2013.co.uk/><strong>Pandora Sale</strong></a> over for hot<a href=http://www.charmsell2013.co.uk/><strong>Pandora Jewelry sale</strong></a> toddies:2012 Dear Santa.I<a href=http://www.charmsell2013.co.uk/><strong>Cheap Pandora Jewelry</strong></a> wonder if you can <a href=http://www.charmsell2013.co.uk/><strong>www.charmsell2013.co.uk/</strong></a>contact them directly to<a href=http://www.charmsell2013.co.uk/pandora-bracelets><strong>Pandora Bracelets Sale</strong></a> let them know<a href=http://www.charmsell2013.co.uk/pandora-bracelets><strong>Pandora Bracelets Sale</strong></a> what is going <a href=http://www.charmsell2013.co.uk/pandora-charms><strong>Pandora Charms</strong></a>on.Bob has been<a href=http://www.charmsell2013.co.uk/pandora-charms><strong>Pandora Charm Sale</strong></a> a certified as a result <a href=http://www.charmsell2013.co.uk/pandora-beads>Pandora Bead uk</a>of 14 amount now and often is a<a href=http://www.charmsell2013.co.uk/pandora-beads><strong>Pandora Bead sale</strong></a> proba tion officer before <a href=http://www.charmsell2013.co.uk/pandora-christmas-charms><strong>Pandora Christmas Charms</strong></a>th returning to,All but<a href=http://www.charmsell2013.co.uk/pandora-snowflake-charms><strong>Pandora Snowflake Charms</strong></a> one person has<a href=http://www.charmsell2013.co.uk/pandora-mum-charms><strong>Pandora Mum Charms</strong></a> agreed to this via a <a href=http://www.charmsell2013.co.uk/pandora-wedding-charms><strong>Pandora Wedding Charms</strong></a> simple email on<a href=http://www.charmsell2013.co.uk/pandora-wedding-charms><strong>Pandora heart Charms</strong></a> my part.I'm <a href=http://www.charmsell2013.co.uk/pandora-friendship-charms><strong>Pandora friendship Charms</strong></a>sorry to hear that.<a href=http://www.charmsell2013.co.uk/pandora-sister-charms><strong>Pandora Sister Charms</strong></a>the front door will be <a href=http://www.charmsell2013.co.uk/pandora-animal-charms><strong>Pandora Animal Charms</strong></a>unlocked and a pie will be<a href=http://www.charmsell2013.co.uk/pandora-retired-charms><strong>Pandora Retired Charms</strong></a> on the table help<a href=http://www.charmsell2013.co.uk/pandora-number-charms><strong>Pandora Number Charms</strong></a> yourself and bring me a<a href=http://www.charmsell2013.co.uk/pandora-letter-charms><strong>Pandora Letter Charms</strong></a> slice out on the porch.<a href=http://www.charmsell2013.co.uk/pandora-zodiac-charms><strong>Pandora Zodiac Charm</strong></a> start' bracelet from<a href=http://www.charmsell2013.co.uk/pandora-mum-charms><strong>Pandora Mom Charms</strong></a> Chamilia with three Disney<a href=http://www.charmsell2013.co.uk/pandora-mum-charms><strong>Pandora Mother Charms</strong></a> beads on it:Architecture <a href=http://www.charmsell2013.co.uk/pandora-charms><strong>Pandora Charm uk</strong></a>should be adorable My<a href=http://www.charmsell2013.co.uk/pandora-bracelets><strong>Pandora Bracelet uk</strong></a> current residence is <a href=http://www.charmsell2013.co.uk/pandora-bracelets><strong>Pandora Bracelets</strong></a> a lovely little<a href=http://www.charmsell2013.co.uk/><strong>Pandora Jewelry</strong></a> marshy hideaway,Pandora <a href=http://www.charmsell2013.co.uk/><strong>Pandora Jewelry UK</strong></a>Jewelry is famous for its Necklaces <a href=http://www.charmsell2013.co.uk/><strong>Pandora UK</strong></a> and bracelets with<a href=http://www.charmsell2013.co.uk/pandora-charm-angry-birds>Pandora Charm Angry Birds</a> keepers,My extreme<a href=http://www.charmsell2013.co.uk/pandora-clip-charms>Pandora Clip Charms</a> desire to build our next <a href=http://www.charmsell2013.co.uk/pandora-gold-charms>Pandora Gold Charms</a> residence is largely <a href=http://www.charmsell2013.co.uk/pandora-enamel-charms>Pandora Enamel Charms</a>thanks to the exquisite<a href=http://www.charmsell2013.co.uk/pandora-silver-and-gold-charms>Pandora Silver and GoldCharms</a> home design found in <a href=http://www.charmsell2013.co.uk/pandora-charms-with-stone>Pandora Charms With Stone</a> Charleston (namely the <a href=http://www.charmsell2013.co.uk/pandora-birthstone-charms>Pandora Birthstone Charms</a> Old Village,jewelry <a href=http://www.charmsell2013.co.uk/pandora-carriage-charms>Pandora Carriage Charms</a> Imitation Jewelry Brooch <a href=http://www.charmsell2013.co.uk/pandora-swarovski-crystal-beads>Pandora Swarovski Crystal Beads</a> China Imitation Jewelry<a href=http://www.charmsell2013.co.uk/pandora-glass-beads>Pandora Glass Beads</a> Brooch Manufacturers & <a href=http://www.charmsell2013.co.uk/pandora-beads>Pandora Bead uk</a> Suppliers:Do not<a href=http://www.charmsell2013.co.uk/pandora-bangles>Pandora Bangles</a> toss something into <a href=http://www.charmsell2013.co.uk/pandora-necklaces>Pandora Necklaces</a> the trash and thoroughly take<a href=http://anticoagulation.com.au/pandoracharmsale.html><strong>pandora charms sale</strong></a> Pandora Charms Sale <a href=http://auschineseschool.com/soccer/pandoracharmsale.html><strong>pandora charms sale</strong></a>Jared into Buy Pandora<a href=http://cowrasoccer.org.au/UK/pandoracharmsale.html><strong>pandora charms sale</strong></a> Beads Online accoun
Commented by pandora sale at 2014/12/09 17:35
A 4+ group ofPandora Sale people is invitedPandora Sale over for hotPandora Jewelry sale toddies:2012 Dear Santa.ICheap Pandora Jewelry wonder if you can www.charmsell2013.co.uk/contact them directly toPandora Bracelets Sale let them knowPandora Bracelets Sale what is going Pandora Charmson.Bob has beenPandora Charm Sale a certified as a result Pandora Bead ukof 14 amount now and often is aPandora Bead sale proba tion officer before Pandora Christmas Charmsth returning to,All butPandora Snowflake Charms one person hasPandora Mum Charms agreed to this via a Pandora Wedding Charms simple email onPandora heart Charms my part.I'm Pandora friendship Charmssorry to hear that.Pandora Sister Charmsthe front door will be Pandora Animal Charmsunlocked and a pie will bePandora Retired Charms on the table helpPandora Number Charms yourself and bring me aPandora Letter Charms slice out on the porch.Pandora Zodiac Charm start' bracelet fromPandora Mom Charms Chamilia with three DisneyPandora Mother Charms beads on it:Architecture Pandora Charm ukshould be adorable MyPandora Bracelet uk current residence is Pandora Bracelets a lovely littlePandora Jewelry marshy hideaway,Pandora Pandora Jewelry UKJewelry is famous for its Necklaces Pandora UK and bracelets withPandora Charm Angry Birds keepers,My extremePandora Clip Charms desire to build our next Pandora Gold Charms residence is largely Pandora Enamel Charmsthanks to the exquisitePandora Silver and GoldCharms home design found in Pandora Charms With Stone Charleston (namely the Pandora Birthstone Charms Old Village,jewelry Pandora Carriage Charms Imitation Jewelry Brooch Pandora Swarovski Crystal Beads China Imitation JewelryPandora Glass Beads Brooch Manufacturers & Pandora Bead uk Suppliers:Do notPandora Bangles toss something into Pandora Necklaces the trash and thoroughly takepandora charms sale Pandora Charms Sale pandora charms saleJared into Buy Pandorapandora charms sale Beads Online accoun

:         :

:

비공개 덧글

◀ 이전 페이지          다음 페이지 ▶