LuizZak/FastBitmap

Compiling FastBitmapTest

Closed this issue · 6 comments

hi,
Glad I found your post,
issue:
The command "nuget restore "C:\FastBitmap-master\FastBitmap.sln"" exited with code 9009. FastBitmapTests

I'm using vc14, windows 2015

How to use this source?

before I use this bitmap source,
https://stackoverflow.com/questions/21751747/extract-thumbnail-for-any-file-in-windows/

I get bitmaps like this:
Bitmap ximage = GetThumbnail(file.FullName, 500, 500, ThumbnailOptions.None);

What should I declare from your fast bitmap lib?

hi,
can you just answer it can't be like that.

Hey, sorry for the delay!

The project's source distribution uses http://nuget.org/, so if you want to work on the solution you need to have it installed.

If you just need the library's functionality fast and easy you can just copy FastBitmap/FastBitmap.cs into your project and update the namespace accordingly (also don't forget to enable /unsafe compilation in the project settings!)

About your use case for thumbnailing, I'm not sure on which part you require FastBitmap on. Do you need the thumbnail generation functionality, or working with the result of the thumbnail generating function?

Do you need the thumbnail generation functionality, or working with the result of the thumbnail generating function?

hi,
I'm not sure what to say, but I only need the to copy from huge resolution for sample 3840×2160 TO 500x500

I get bitmaps like this:
Bitmap ximage = GetThumbnail(file.FullName, 500, 500, ThumbnailOptions.None);

using your FastBitmap, what should I code in the line?

thank you for the reply

This is how I used the previous function,

                Bitmap ximage = makethumbnail.GetThumbnail(file.FullName, 500, 500, makethumbnail.ThumbnailOptions.None);

                string imageKey = file.FullName;

                imageList.Images.Add(imageKey, ximage);

		string shortName = file.Name;

                dictionaryimages.Add(imageKey, ximage);

                ListViewItem item = new ListViewItem();
                item.ImageKey = imageKey;
                item.Name = shortName;
                item.Text = "_RecNum: " + ClassLabel.ToString() + " _Name: " + shortName;
                listView1.Items.Add(item);

                listmyimages.Add(new myimagelist { imagekind = file.Name, myimage = ximage, classnum = ClassLabel });

Now, I don't know how would I used from your FastBitmap,

I'm afraid FastBitmap does not support such image operations, since it operates mostly on flat memory sections and clearing/copying regions and setting individual pixels within them. Re-writing such operations manually would require writing pixels by hand, and would probably be very costly in C#, and you'd have worse performance from that.

I understand,
thank you