Comments (5)
Might be possible, however my current interest is not so much put on the quality and the changing requires works to balance the trade-offs (memory, processing time) for other users. You can folk the code and create your own to establish the quality-first MegaPixImage implementation, and if you found your achievement is to be shared to this library for other users, you can send me pull request, and hopefully I can merge it.
from ios-imagefile-megapixel.
I'm interested too...
from ios-imagefile-megapixel.
Some people suggested drawing 1/2 of the image, then 1/2 of the resized one and so on. However, it takes a lot of resources to accomplish that kind of transform. What you can do, is to resize to, say, 500px, which will produce pretty good quality image, and then set max-height of an img element to 200px or whatever your needs are.
from ios-imagefile-megapixel.
Canvas is speed-optimized and use "nearest neighbour" interpolation. You can't change that.
Use https://github.com/nodeca/pica for resize, when you need high quality. It has lanczos3 filter, best for this task.
from ios-imagefile-megapixel.
Great work, thanks puzrin!
from ios-imagefile-megapixel.
Related Issues (20)
- PNGs that have an alpha layer show up as a black box
- Rendered object size not available HOT 1
- Breaks using png file HOT 2
- Canvas Quality HOT 2
- Blob not defined in IE9 strict mode HOT 1
- doesn't work in my iPad simulator iOS 5.1 on mac HOT 1
- how can i find out when rendering of big pictures is finished HOT 1
- iOS7 front camera HOT 2
- Downscaling still fails for some images on iOS6 and iOS7 HOT 5
- Change source code for better reading/understanding HOT 1
- Orientation issue HOT 1
- Maintainer needed HOT 2
- resize from base64 HOT 2
- After re sizing an image in samsung s3 gives more size than actual HOT 2
- can not get the full image after compress the image that user toke
- blank canvas on iOS 8.. HOT 5
- I explode by this plugin :((((
- detectVerticalSquash bug for transparent PNG HOT 2
- [Enhancement] add Offset and Crop coordinates
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ios-imagefile-megapixel.