Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

flex ½ØÍ¼

ÔÚflexÖÐÒ²¾­³£»áÓõ½½ØÍ¼¹¦ÄÜ£¬²¢ÇÒ½«½ØÍ¼µÄͼƬ±£´æÖÁ±¾µØ¡£Ò»Ï뵽ͼƬÄÇôÎÒÃǾÍ×ÔÈ»Ïëµ½ËûµÄ´æÔÚÐÎʽ bitmap byteArray.ËùÒÔ×ÔÈ»¾Í»áÁªÏµµ½bitmapÀàÉÏÈ¥¡£
ÏÂÃæÈÃÎÒÃÇÒ»ÆðÀ´¿´¿´¶¼ÓÐÄÄЩ·½·¨°É¡£
·½·¨Ò»£º°´ÎÒÃÇ×ÔÈ»µÄ˼·ʵÏÖ£º
ÔÚapplicationÖÐÓÐÁ½¸öÈÝÆ÷£º
<mx:Canvas id="virtour_cav" top="0" bottom="0" left="0" right="0">
  
</mx:Canvas>
<mx:Canvas right="0" top="0" width="200" height="200">
    <mx:Image id="cpImg" left="0" right="0" bottom="0" top="0"/>
</mx:Canvas>
µ±ÎÒÃǵã»÷½ØÍ¼Ê±Ö´ÐÐ
private function CaptureImage():void{
             var bd:BitmapData=getBitmapData(UIComponent(virtour_cav));
             cpImg.source= new Bitmap(bd);
}
private function getBitmapData(target:UIComponent):BitmapData{
         var bd:BitmapData= new BitmapData(target.width,target.height);
        
         var m:Matrix=new Matrix();
         bd.draw(target,m);
         return bd;
}
×îºóʹÓÃFileReference.save()·½·¨±£´æ¾Í¿ÉÒÔ¡£
fileReference.save(new Bitmap(bd),"δÃüÃû.jpg");
·½·¨¶þ£ºÖ±½ÓʹÓÃͼƬ½ØÍ¼ÀàImageSnapshotʵÏÖ
Õâ¸ö¾Í¸ü¼òµ¥ÁË¡£
private var jpgeEnc:JPEGEncoder=new JPEGEncoder();
private var fileReference:FileReference=new FileReference();
private function CaptureImage():void{
             var imgSnapshot:ImageSnapshot=ImageSnapshot.captureImage(virtour_cav,0,jpgeEnc);
             fileReference.save(imgSnapshot.data,"δÃüÃû.jpg");
}
µ«ÊÇÕâÁ½¸ö·½·¨ÊµÏÖµÄǰÌáÊÇflash ²¥·ÅÆ÷ÒªÇóÊÇ10ÒÔÉÏ
Èç¹ûÎÒÃÇÒªÓÃһЩ flash player 10 ÉϲÅÌṩµÄ¹¦ÄÜʱ£¬ÐèÒªÔÚÏîÄ¿ÊôÐÔÀïÉèÖÃһϣ¬·ñÔò»áÕÒ²»µ½´Ë·½·¨£¬±


Ïà¹ØÎĵµ£º

Flex RPC´íÎóС½á


Ò»¡¢Flex
Remoting
1.Channel definition,
mx.messaging.channels.RTMPChannel, can not be
found...£º×îаæµÄFluorinedÔÚservices-config.xmlÖÐÐÂÔöÁËRTMP Channel£¬Ö÷ÒªÊÇÓÃÀ´Åä ÖÃFlex
Messaging£¬±àÒëʱÐèÒªFDS.swcÖ§³Ö£¬µ±È»Èç¹û²»ÐèÒª´Ë¹¦ÄÜ¿ÉÒÔ×¢Ê͵ôchannel-definitionÕâ¸ö½Úµã¡£
2.RPC
Fault fault ......

flex ÏÔʾͼƬ·½Ê½

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" applicationComplete="InitApp()">
    <mx:Script>
        <![CDATA[
        ......

flex Êý×Ö

uint int Number
Flex ËÄÉáÎåÈ룺
ÕûÊýµÄËÄÉáÎåÈë·¨£¬Math.round(Ò»¸öNumberÀàÐ͵ÄÊý)
СÊýµÄÓÐ tofixed(uint) ·½·¨
ÀýÈç var   num:Number = 56.159;
                  num.tofixed(2);    ËüÊǸöS ......

Flex 4 DropDownList

Flex 4 DropDownList:
<?xml version="1.0" encoding="utf-8"?>
<!-- Simple example to demonstrate the Spark DropDownList control -->
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ