예제 #1
0
        public static DefineSprite buildSprite(System.String name, JPEGImage image)
        {
            TagList taglist = new TagList();

            try
            {
                DefineBits defineBits = build(image);
                taglist.defineBitsJPEG2(defineBits);

                DefineShape ds3 = ImageShapeBuilder.buildImage(defineBits, image.Width, image.Height);
                taglist.defineShape3(ds3);

                PlaceObject po2 = new PlaceObject(ds3, 1);
                po2.Matrix = new Matrix();
                // po2.setName(name);

                taglist.placeObject2(po2);
            }
            catch (System.IO.IOException ex)
            {
                //UPGRADE_TODO: The equivalent in .NET for method 'java.lang.Throwable.getMessage' may return a different value. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1043'"
                throw new System.SystemException("Error reading JPEG image " + image.Location + ". " + ex.Message);
            }
            finally
            {
                image.dispose();
            }

            return(defineSprite(name, taglist));
        }
예제 #2
0
        public static DefineBits build(JPEGImage image)
        {
            DefineBits defineBits = new DefineBits(flash.swf.TagValues_Fields.stagDefineBitsJPEG2);

            try
            {
                defineBits.data = image.Data;
            }
            finally
            {
                image.dispose();
            }

            return(defineBits);
        }
예제 #3
0
		public static DefineBits build(JPEGImage image)
		{
			DefineBits defineBits = new DefineBits(flash.swf.TagValues_Fields.stagDefineBitsJPEG2);
			
			try
			{
				defineBits.data = image.Data;
			}
			finally
			{
				image.dispose();
			}
			
			return defineBits;
		}
예제 #4
0
		public static DefineBits build(System.String name, JPEGImage image)
		{
			DefineBits defineBits = null;
			try
			{
				defineBits = build(image);
				defineBits.name = name;
			}
			catch (System.IO.IOException ex)
			{
				//UPGRADE_TODO: The equivalent in .NET for method 'java.lang.Throwable.getMessage' may return a different value. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1043'"
				throw new System.SystemException("Error reading JPEG image " + image.Location + ". " + ex.Message);
			}
			finally
			{
				image.dispose();
			}
			
			return defineBits;
		}
예제 #5
0
        public static DefineBits build(System.String name, JPEGImage image)
        {
            DefineBits defineBits = null;

            try
            {
                defineBits      = build(image);
                defineBits.name = name;
            }
            catch (System.IO.IOException ex)
            {
                //UPGRADE_TODO: The equivalent in .NET for method 'java.lang.Throwable.getMessage' may return a different value. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1043'"
                throw new System.SystemException("Error reading JPEG image " + image.Location + ". " + ex.Message);
            }
            finally
            {
                image.dispose();
            }

            return(defineBits);
        }
예제 #6
0
		public static DefineSprite buildSprite(System.String name, JPEGImage image)
		{
			TagList taglist = new TagList();
			
			try
			{
				DefineBits defineBits = build(image);
				taglist.defineBitsJPEG2(defineBits);
				
				DefineShape ds3 = ImageShapeBuilder.buildImage(defineBits, image.Width, image.Height);
				taglist.defineShape3(ds3);
				
				PlaceObject po2 = new PlaceObject(ds3, 1);
				po2.Matrix = new Matrix();
				// po2.setName(name);
				
				taglist.placeObject2(po2);
			}
			catch (System.IO.IOException ex)
			{
				//UPGRADE_TODO: The equivalent in .NET for method 'java.lang.Throwable.getMessage' may return a different value. "ms-help://MS.VSCC.v80/dv_commoner/local/redirect.htm?index='!DefaultContextWindowIndex'&keyword='jlca1043'"
				throw new System.SystemException("Error reading JPEG image " + image.Location + ". " + ex.Message);
			}
			finally
			{
				image.dispose();
			}
			
			return defineSprite(name, taglist);
		}