mirror of
https://github.com/photoprism/photoprism.git
synced 2026-03-02 22:57:18 -05:00
Show original image when clicking on it #518
Labels
No labels
ai
android
api
auth
awesome
bug
bug
ci
cli
config
database
declined
deprecated
docker
docs 📚
documents
duplicate
easy
enhancement
enhancement
enhancement
epic
faces
feedback wanted
frontend
hacktoberfest
help wanted
idea
in-progress
incomplete
index
invalid
ios
labels
live
live
low-priority
macos
member-feature
metadata
mobile
nas
needs-analysis
no-coding-required
no-coding-required
observability
performance
places
please-test
plus-feature
priority
pro-feature
question
raspberry-pi
raw
released
released
released
research
resolved
security
sharing
tested
tests
third-party-issue
thumbnails
upgrade
upstream-issue
ux
vector
video
waiting
won't fix
won't fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/photoprism#518
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @alexislefebvre on GitHub (Nov 20, 2020).
Originally assigned to: @lastzero on GitHub.
I use PhotoPrism with parameter
PHOTOPRISM_THUMB_SIZE: 1024to save disk space and when I open an image greater than 1024 px, I only see this thumbnail.I would appreciate that PhotoPrism return the original image, it won't cost much resource for the server or the browser.
It could be added as an option to keep current behaviour.
It would also remove the need to have big thumbnails.
@alexislefebvre commented on GitHub (Nov 20, 2020):
Related to #247
@lastzero commented on GitHub (Nov 22, 2020):
You should be able to do this by changing the config... note that browsers DON'T rotate JPEGs based on their metadata, so MANY pictures will have the wrong rotation, they will look blurry due to extremely basic resampling, and traffic will go way up when used remotely e.g. on a mobile phone.
@lastzero commented on GitHub (Nov 22, 2020):
See https://github.com/photoprism/photoprism/blob/develop/internal/api/thumbs.go#L134
@lastzero commented on GitHub (Nov 22, 2020):
Also #157
@lastzero commented on GitHub (Nov 22, 2020):
Docs: https://docs.photoprism.org/user-guide/settings/thumbnails/
@alexislefebvre commented on GitHub (Nov 22, 2020):
Thanks for the answer.
Since the line contains
c.Query("download") == "", I think it only works when downloading a photo.@lastzero commented on GitHub (Nov 22, 2020):
Only works when not downloading.
@alexislefebvre commented on GitHub (Dec 6, 2020):
Does it mean that the idea is rejected and a PR to change this would be rejected?
@lastzero commented on GitHub (Dec 6, 2020):
I closed it because this seems already possible after we had this feature request before - did you test it?
See https://github.com/photoprism/photoprism/issues/157#issuecomment-573402110
@alexislefebvre commented on GitHub (Dec 6, 2020):
With a 1024x768 image, the endpoint
/fit_2048return a 720x480 image instead of the original image.@lastzero commented on GitHub (Dec 6, 2020):
Did you set
PHOTOPRISM_THUMB_SIZE_UNCACHED&PHOTOPRISM_THUMB_SIZEto 720 in your config and restart before testing?@alexislefebvre commented on GitHub (Dec 6, 2020):
Thanks, it worked!
The doc says
PHOTOPRISM_THUMB_UNCACHEDwill cause (high memory and cpu usage) , I thought it would use the CPU to generate all thumbnails and it would break everything, and it's not the case.@alexislefebvre commented on GitHub (Dec 6, 2020):
Here's a PR to explain it in the doc: https://github.com/photoprism/photoprism-docs/pull/34
@lastzero commented on GitHub (Dec 6, 2020):
Only when it is higher than
PHOTOPRISM_THUMB_SIZE. If it is less or the same, there is no way to generate a thumb. Thus, the original is returned.@intdel commented on GitHub (Jan 3, 2021):
It is still not very clear to me. If I set PHOTOPRISM_THUMB_SIZE_UNCACHED & PHOTOPRISM_THUMB_SIZE to 720, does it not just mean that the generated thumbnail it saves is max 720 and that the generated dynamic render is max 720?
It is also not clear to me how this forces photoprism to render the picture in higher resolution when clicking on it.
@intdel commented on GitHub (Jan 3, 2021):
Ok now it makes sense. It is not very clear from the settings page that a restart is necessary :)
@vaskozl commented on GitHub (Jan 30, 2021):
So I have a 4k display, using the default
PHOTOPRISM_THUMB_SIZE: 2048, I'm generating and storing thumbnails up to 2048.Without
PHOTOPRISM_THUMB_UNCACHED: trueI see 2048px images which are lower quality than the orignal.With it, I see 4096px images, but they are slow to render even off and SSD with an overclocked RPi. Why doesn't Photoprism just show the original image instead of trying to make a minor resize to
fit_4096?The images Iphone takes are 4032x3024, after the "thumbnailing" it's still 4032x3024, but have slightly different colours.
My girlfriends Oneplus 6 takes 4608 wide photos which get resized down to 4096 (takes forever uncached). I'm comparing the 4608 and 4096 wide images on my 4k display in chromium and they look exactly the same when opened up at full size.
At the end of the day I either have to enable pre-generation up to 4096 photos and take up stupid amounts of space or otherwise wait an unacceptable amount of time performing resizing for no reason.
Even after photoprism resize to 4096 the photos still get resized down by chrome to so they can be displayed at the correct height/width in the browser window an end up being more like 3000px wide (haven't meassured exactly how much), so arguably the carefly done conversion by photoprism is utterly wasted.
I really love how quick normal thumbnails load and think that's awesome, but for full size images can we just drop the thumbnails and show the original image? It makes no sense to do anything else in terms of space and slowness and doesn't actually work as browsers end up resizing the image anyway.
@lastzero commented on GitHub (Jan 30, 2021):
As explained in the docs, you may configure photoprism to return originals. Note that, as also explained in the docs, browsers may ignore their rotation and display them upside down. Get a faster server for a better user experience. Google also doesn't run Photos on a Pi.
@vaskozl commented on GitHub (Jan 30, 2021):
I've read https://docs.photoprism.org/getting-started/config-options/ and I don't see an option to disable it?
Google doesn't use 4 cores of 2GHz to show you photos and neither does chrome when i go to view the photo directly.
My point is that resizing 4608 -> 4096, which the browser then resizes down again is pointless and wasteful. The storage of the 4096px image is also wasteful.
@lastzero commented on GitHub (Jan 30, 2021):
All commercial cloud hosting services use thumbs and pre render them. If you have other insights, please share them. Description should be in User Guide > Settings > Advanced.
@lastzero commented on GitHub (Jan 30, 2021):
@vaskozl commented on GitHub (Jan 30, 2021):
Thank you, but somehow I still can't get it work with full quality images:
With
The
fit_4096returns a 2048 large image. It doesn't return the original size.With:
It returns a 4096 image after performing the (in my opionion unneeded) resize.
I tried both of these settings before my first comment. I do love photoprism, it's just my one grip that I can't view full quality photos properly.
@alexislefebvre commented on GitHub (Jan 30, 2021):
@Vaskozl I thought I had it working, as noted in my previous comments. But I had no image as big as yours nor 4K screen, so I added an image 7328 × 3424, 3.7 MB. And the URL
fit_2048returns an 2048 × 956 image (fit_4096is not called because of my screen but calling it manually return a 4096 width image). And I don't understand why, I thought it returned the original images.My settings:
My screen has 2560 × 1440 resolution.
@lastzero commented on GitHub (Jan 30, 2021):
You need to reduce the dynamic size limit if you want originals instead of resampled images.
@vaskozl commented on GitHub (Jan 30, 2021):
Is this the intended configuration:
When I right and open an image I can see it's loaded via the fit_4096 api call which still returns a 2048px photo :/
Using photoprism
20210128.Edit, just trying the above settings now without
UNCACHED: true@lastzero commented on GitHub (Jan 30, 2021):
See https://github.com/photoprism/photoprism/issues/157 for the original feature request and discussion. It's past 1am over here and weekend anyways, so I'm taking a break now.
@alexislefebvre commented on GitHub (Jan 30, 2021):
Right, I think I did it after your comment but I may have changed it after.
I just put "Dynamic Size Limit" to 720, flushed the browser cache, and
fit_2048never return the original image, it's never greater than 2048 width. And if I disable "Dynamic Previews", it returns a 720 width image.@vaskozl commented on GitHub (Jan 30, 2021):
Got it to finally work with:
So one has to set
PHOTOPRISM_THUMB_UNCACHED=trueand also reduce thePHOTOPRISM_THUMB_SIZE_UNCACHED=2048, wasn't obvious to me at all.@lastzero Thank you and good night ;)
@alexislefebvre commented on GitHub (Jan 30, 2021):
I had it working too. I had to change
PHOTOPRISM_THUMB_SIZE_UNCACHEDfrom 7680 to 720. It looks like doing it through the Settings page was ignored.2 users and me were confused by this configuration, I'll try to improve the documentation.
@lastzero commented on GitHub (Jan 30, 2021):
Setting to 720 is not required and might result in other issues,. Use the same as static. If you then allow non pre rendered previews, the only option is to return the original. Maybe uncached might be confusing but changing the name will brake existing configs. A restart might be required when changing it in the Advanced Settings UI.