I got it :

package com.zwlane
{
        import flash.display.Bitmap;
        import flash.display.Sprite;

        public class MapIcon extends Sprite
        {

                [Embed(source="res.png")]
                private var mapsImg:Class;
                public function MapIcon()
                {
                        var img:Bitmap;
                        img = new mapsImg;
                        img.scaleX = 0.1;
                        img.scaleY = 0.1;
                        this.addChild(img);

                }

        }
}

then the size is 12.8X12.8!

On 5月27日, 下午1时56分, zwlane <[email protected]> wrote:
> In AS3, the code i use to generate custom icon:
>
> package com.zwlane
> {
>         import flash.display.Sprite;
>         public class MapIcon extends Sprite
>         {
>
>                 [Embed(source="res.png")]
>                 private var mapsImg:Class;
>
>                 public function MapIcon()
>                 {
>                       addChild(new mapsImg());
>                 }
>
>         }
>
> }
>
> then  i call
>
> var markerOptions:MarkerOptions = new MarkerOptions({icon: new MapIcon
> (), hasShadow: false});
>
> to display icons, but the size of res.png is 128X128, how can i set
> the size to 32X32, or 16X16?
>
> Thanks!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API For Flash" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-maps-api-for-flash?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to