Example #1
0
        private void ReadPictures()
        {
            if (_af != null && _af.Tag != null)
            {
                foreach (IPicture picture in _af.Tag.Pictures)
                {
                    if (picture != null)
                    {
                        try
                        {
                            MemoryStream ms  = new MemoryStream(picture.Data.Data);
                            Bitmap       bmp = new Bitmap(ms);

                            PictureInfo pi = new PictureInfo(bmp.Clone() as Bitmap, picture.Type, picture.Description, picture.MimeType);
                            ArtworkImages.Add(pi);
                        }
                        catch (Exception ex)
                        {
                            Logger.LogException(ex);
                        }
                    }
                }
            }
        }
Example #2
0
 private void btnAdd_Click(object sender, EventArgs e)
 {
     PictureInfo pi = new PictureInfo(new Bitmap(pbPicture.ErrorImage), PictureType.Other, string.Empty, "image/bmp");
     _id3ArtworkInfo.ArtworkImages.Add(pi);
     LoadPictures();
 }
Example #3
0
        private void ReadPictures()
        {
            if (_af != null && _af.Tag != null)
            {
                foreach (IPicture picture in _af.Tag.Pictures)
                {
                    if (picture != null)
                    {
                        try
                        {
                            MemoryStream ms = new MemoryStream(picture.Data.Data);
                            Bitmap bmp = new Bitmap(ms);

                            PictureInfo pi = new PictureInfo(bmp.Clone() as Bitmap, picture.Type, picture.Description, picture.MimeType);
                            ArtworkImages.Add(pi);
                        }
                        catch (Exception ex)
                        {
                            Logger.LogException(ex);
                        }
                    }
                }
            }
        }