Example #1
0
 /// <summary>
 /// Creates a new instance of the TargaImage object.
 /// </summary>
 public TargaImage()
 {
     this.objTargaFooter = new TargaFooter();
     this.objTargaHeader = new TargaHeader();
     this.objTargaExtensionArea = new TargaExtensionArea();
     this.bmpTargaImage = null;
     this.bmpImageThumbnail = null;
 }
Example #2
0
        /// <summary>
        /// Clears out all objects and resources.
        /// </summary>
        private void ClearAll()
        {
            if (this.bmpTargaImage != null)
            {
                this.bmpTargaImage.Dispose();
                this.bmpTargaImage = null;
            }
            if (this.ImageByteHandle.IsAllocated)
                this.ImageByteHandle.Free();

            if (this.ThumbnailByteHandle.IsAllocated)
                this.ThumbnailByteHandle.Free();

            this.objTargaHeader = new TargaHeader();
            this.objTargaExtensionArea = new TargaExtensionArea();
            this.objTargaFooter = new TargaFooter();
            this.eTGAFormat = TGAFormat.UNKNOWN;
            this.intStride = 0;
            this.intPadding = 0;
            this.rows.Clear();
            this.row.Clear();
            this.strFileName = string.Empty;

        }