Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only first image gets displayed #11

Open
danboid opened this issue Jun 13, 2018 · 5 comments
Open

Only first image gets displayed #11

danboid opened this issue Jun 13, 2018 · 5 comments

Comments

@danboid
Copy link

danboid commented Jun 13, 2018

Album isn't much use currently because it only displays the first image file dragged into its window. If you drag multiple files in at once then it only shows a thumbnail preview of one image.

Also, what is 'Write thumbnails' from the Attributes menu supposed to do? It doesn't seem to do anything. I didn't think tracker supported thumbnails yet, or at least not in the official build?

Tested under Haiku 52001 x86_64

@janus2
Copy link
Member

janus2 commented Jun 14, 2018

After a little bit of investigation seam that the problem in the 64bit version is the function DrawBitmap with the signature DrawBitmap(const BBitmap* bitmap, BRect bitmapRect, BRect viewRect). Using the version with the position works as expected. The only displayed thumbnail is a little bit cropped. When dragging a picture the bitmap is drawn correctly.

@danboid
Copy link
Author

danboid commented Jun 14, 2018

Thanks for investigating this janus2. Would you know how to fix it so it will 'just work' without having to drag every picture to make it show? Is this a Haiku issue instead of just a bug in album?

@janus2
Copy link
Member

janus2 commented Jun 14, 2018

You see the image only when you drag the thumbnail but the image in the view will still be missing. It isn't a workaround. I just point out that the image is correctly stored and displayed for further investigations.

if you need the problem fixed asap you can compile the code removing the part in the #ifdef __HAIKU__ in AlbumItem.cpp and use the code in the #else the difference is that you will not have the bilinear scaling filter on the thumbnails.

Is this a Haiku issue instead of just a bug in album?

Could be

@KevinAdams05
Copy link

Any idea what the intent was behind the part in #ifdef __HAIKU__ ?

BRect rect = fBitmap->Bounds(); owner->DrawBitmap(fBitmap, rect, rect.OffsetBySelf(pos), B_FILTER_BITMAP_BILINEAR);

It seems to work perfect without that.

@korli
Copy link
Contributor

korli commented Jul 25, 2019

here is the commit: bd5467f#diff-95f647bcc868fb132370fd2bc5065459R94

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

4 participants