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

Picture quality problem #120

Closed
writer0713 opened this issue May 24, 2018 · 9 comments
Closed

Picture quality problem #120

writer0713 opened this issue May 24, 2018 · 9 comments

Comments

@writer0713
Copy link

writer0713 commented May 24, 2018

Please provide you version information :

Dependency Version
ionic2 3.6.1
angular 4.1.3
ionic-img-viewer ^2.7.2

Have you checked...

  • [v ] That npm install returns no warning ?
  • [v ] Doing a purge of your node_modules folder ?

I used your plugin and I made photo quality option as 100 when I save it.
but when the app loads pictures, the quality of pictures were so low.
Spent long time to find the causes from my logic, there was nothing wrong.
Then I changed plugin to test.
After changing plugin into 'Photo Viewer (another plugin)',
the quality of picture became so great.

In normal case, it doesn't matter.
but, some apps need to show letters on the picture (that means quality is important).

@Riron
Copy link
Owner

Riron commented May 28, 2018

The plugin does not affect the picture quality. It just displays it and the quality depends on the original picture.

If your image quality is bad, when you display it fullscreen it can look bad / pixelated.

@Riron Riron closed this as completed May 28, 2018
@ghost
Copy link

ghost commented May 29, 2018

I have a same issue when zooming the picture. Happens with good quality original .png pictures, even with .svg pictures.

@writer0713
Copy link
Author

@ptakalok yes, that's right.
@Riron you need to check it with the letters on the picture. I've already changed into another plugin, however you'd better to check it for other users.

@Riron
Copy link
Owner

Riron commented May 29, 2018

Oh okay so it's the zoom you are talking about ?
In that case I am using CSS transforms and there isn't much else I can do without affecting the performance I think. Constantly modifying height / width on mobile will probably cause junk...

@writer0713
Copy link
Author

@Riron Thank you for checking about it. I think you would better to mension about it on the Readme.md file. in my case, I had checked whole of my codes to find out the problem of picture's low quality. almost spent a half day. Anyway, thank u for making this good plugin for others :)

@murshid1988
Copy link

Hi @Riron, please take a look at #124 (comment)

@habermanm
Copy link

habermanm commented Sep 24, 2019

It seems like it's because the image is capped to 100% width and height on load. Then when it is scaled, it is that rendered image that is scaled, not the original image. If possible to modify width and height when image is pinched rather than using the scaling transform, I think it might fix the issue.

Just looked at the comment above, and seems they came to the same conclusion.

@kevingrabher
Copy link

Or perhaps start with 1000% width and height, and transform set on 1/10th
Then scale upwards from there

@habermanm
Copy link

Only issue with that is you can't use max, so you will have trouble maintaining aspect ratio and keeping image full screen.

You could set maxwidth and height to 1000% but then if the image isn't that big, it will shrink more than you want, And if you set width and height to 1000% then the image will be skewed I think.

Would probably need to use JS to read dimensions of image and screen and adjust appropriately, or allow passing of values as properties of the img element.

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

No branches or pull requests

5 participants