Hi folks,
Is there a tool to hunt for overmagnified pictures and restore them? I mean when a JPG is originally 150 px and is rendered to 300 px in the article which is a useless enlargement and results in an ugly picture.
Or do we have any part of it, e.g. determining the size of a picture?
I think JPG is the main subject, GIFs are perhaps less involved and SVG is of course problemless.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Determing the size of a picture should be possible by using the API [1], but I do not know of a tool in the framework that does it. One of my bots works heavily on images, but I think the API [1] should help you already.
[1] http://de.wikipedia.org/w/api.php?action=query&titles=File:Test.jpg&...
Greetings DrTrigon
On 02.01.2013 16:42, Bináris wrote:
Hi folks,
Is there a tool to hunt for overmagnified pictures and restore them? I mean when a JPG is originally 150 px and is rendered to 300 px in the article which is a useless enlargement and results in an ugly picture.
Or do we have any part of it, e.g. determining the size of a picture?
I think JPG is the main subject, GIFs are perhaps less involved and SVG is of course problemless.
-- Bináris
_______________________________________________ Pywikipedia-l mailing list Pywikipedia-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/pywikipedia-l
On 2 January 2013 16:42, Bináris wikiposta@gmail.com wrote:
Or do we have any part of it, e.g. determining the size of a picture?
I think you will need to parse the parsed wikitext for this, e.g.
http://nl.wikipedia.org/w/api.php?action=parse&page=1600/1800_(locomotie...
which gives you <img alt="Locomotief 1604 "Dordrecht" van Railion te Utrecht Centraal" src="//upload.wikimedia.org/wikipedia/commons/thumb/9/9c/Railion_1604.jpg/266px-Railion_1604.jpg" width="266" height="200" srcset="//upload.wikimedia.org/wikipedia/commons/thumb/9/9c/Railion_1604.jpg/399px-Railion_1604.jpg 1.5x, //upload.wikimedia.org/wikipedia/commons/thumb/9/9c/Railion_1604.jpg/532px-Railion_1604.jpg 2x" /></a></td>\n</tr>\n<tr>\n<td align="center" colspan="3">
then you have to re-parse the URL to an image name, and get the data for that image.
Merlijn
pywikipedia-l@lists.wikimedia.org