/srv/irclogs.ubuntu.com/2009/06/30/#ayatana.txt

=== rickspencer3-afk is now known as rickspencer3
=== GreySim_ is now known as GreySim
SiDiMacSlow: hi08:32
SiDiI'm having blur notifications with jpg/png files with python notifications, while i just pass the path to the image and dont resize anything, any idea ? :/08:34
mptSiDi, how large is the original image?09:29
SiDimpt: 240x24009:30
macvrSiDi: anything larger than 48px doesnt display as crisp as the original09:30
SiDimacvr: its not much better at 48x48 :(09:31
macvrSiDi: i was getting blurs with 128px, i can't just imagine how a 240px would look ;p09:32
SiDiAnd album art is usually between 200x200 and 600x600. And i'm 100% sure i dont use resized pixbufs09:32
macvrif the original image is 48px , you *will* get good quality09:32
macvrSiDi: https://bugs.launchpad.net/notify-osd/+bug/36022809:33
macvrsee MacSlow's last comment09:34
macvrMacSlow: btw i didnt notice the second bug! that wasnt me :(09:34
mptmacvr, a 240*240 image should look much better than a 40*40 one (for example)09:44
macvrmpt: but when it scales down , the quality is poor , well atleast for me 09:45
SiDihttp://filebin.ca/ttttug/PythonBlurTest.tar.gz09:46
SiDimacvr: as you can see with these examples, the result is exactly the same with a 900 / 300 / 48 px image09:46
SiDithe only way to get it not blur is to make a sharp 48x48 pic on my own09:46
macvrSiDi: yes ^ , that is the only way09:47
mptmacvr, probably the thing that would most help would be a bug report containing (1) a sample image, (2) a screenshot of how Notify OSD displays it, and (3) a less-blurry resized version09:47
mpthang on there09:47
macvrmpt: this is a known issue > https://bugs.launchpad.net/notify-osd/+bug/36022809:47
mptSiDi, if you can do a better job of resizing it than Notify OSD can, that's a bug in Notify OSD09:48
macvrsee MacSlow last comment09:48
SiDimpt: i think the resizing algo isnt strong enough09:48
SiDigimp's one isnt terrible either, i explicitely resharpened the picture in gimp09:48
mptSiDi, ok, so it would help most to report a bug with the three things I listed above09:48
macvrmpt: the problem is because notify-osd sets a fixed limit of 48px , while AFAIK , the previous daemon used a max 128px for images09:49
mptSiDi, currently we're using what Gimp calls "Sinc (Lanczos3)" resizing09:50
mptIt would be cool if someone could make a table of example images (some photographic album art, some line drawings, some smaller than 48*48, etc) showing how different algorithms resize them to 48*4809:51
mptThat would help us decide if we need to switch algorithms, or use one for small images and another for large ones, or something else.09:52
SiDimpt: do you know about any other algorithms ? cause i dont :p09:52
mptSiDi, sure, Gimp lists "Linear" and "Cubic" alongside Sinc09:53
mpt(Image > Scale Image)09:53
SiDiokey09:53
SiDilet me make some pictures then09:53
mptcool, thanks09:53
macvrmpt: SiDi  the problem is mostly only for album art from music players, so setting a limit of 128px exception for those app alone should fix this09:55
mptmacvr, you mean music players should be able to send notifications with bigger images than any other app?09:55
macvryup09:55
mptI don't think that would solve the problem, it would just shift it around09:56
mpte.g. what would happen if a player sent this image <http://www.ilovethe80s.com/murrayhead_chess_1986.jpg>?09:56
mpt(album art from the Chess soundtrack)09:56
mptShould Notify OSD resize it up to 128px?09:57
SiDimacvr: its a bad approach imo09:57
macvrmpt: SiDi: the previous daemon , from usage experience , Used to be able to display small images less than 128px as is , but if it was larger than 128 px it would scale down , Maybe MacSlow has more knoledge about this09:58
macvrknowledge^09:58
mptmacvr, the version of notification-daemon in Ubuntu 8.10 had no limit on the size of images at all.09:58
mptI DoSed myself by typing "notify-send -i Screenshot.png". :-)09:58
mptbecause the bubble was larger than the screen and the close button was off-screen09:59
macvrmpt: ah i didnt know that , but a rule as i had mentioned would be a nice addition to notify-osd10:00
macvrmaybe i didnt have very large album art ;p10:00
mptmacvr, I think if we get the scaling right, the attractiveness of consistent image size for all notification bubbles will be greater than the ugliness from any remaining blurriness.10:01
mptBut we need to fix applications to not send tiny images to Notify OSD, just like we fixed them to not ask for actions without checking.10:01
macvrmpt: that is the problem , scaled down image can *never* be clear at 48px , it needs to be larger10:02
mptmacvr, I can point you to Mac OS X as a counterexample10:02
macvr;p10:02
mptNearly all the icons you see in recent Mac OS X screenshots are 512*512 originals scaled down to about 48*48.10:03
mptAnd it's the OS doing the scaling.10:03
macvrmpt: i tested notify-osd with various sizes to create icons for breathe, it never looked good10:03
mptSo, there must be some way to do it.10:03
* macvr needs to figure that out10:04
SiDimacvr: svg with an original size bigger than 48px are very very likely scaled with another algorithm, specific to svg files, btw10:08
SiDifrom my testing the best is to resize + resharpen if the image was bigger10:08
SiDipossibly sharpen's intensity depending on the original / 48px ratio10:08
SiDimpt: macvr: http://img31.imageshack.us/img31/6017/resume.png10:40
SiDiTell me for each picture which you think is best10:41
macvrSiDi: 3rd10:42
macvrSiDi: i guess you used the same rules for one column?10:42
SiDinot for the monkey10:43
macvrdo the same as the top3 rows for the monkey also10:44
SiDimeh10:47
mptSiDi, for the first three rows I'd choose 3, 1, 310:48
mptFor the last row I can barely tell any difference10:48
SiDiok so, 3 is cubic10:49
SiDi1 is no interpolation10:49
SiDirenders great with geometric forms but horribly with photos10:49
SiDii'll add a cubic monkey10:49
SiDiall the pictures were originally 900x900 except monkey, 64x6410:50
macvrSiDi: its cheating^10:50
macvrmonkey or other face of the same size should be used for good comparison10:51
SiDimpt macvr http://img141.imageshack.us/img141/6017/resume.png now featuring a cubic monkey \o/10:52
SiDimacvr: the goal is to test the algos if the picture is little, not only if it is big :P10:52
SiDiso apparently the cubic algorithm would give sharpen results10:53
macvr+110:53
mptExcept for the first column, they all look pretty good10:53
mptWhat we're wanting is to avoid it looking *bad*10:53
macvrmpt look at the monkey in the 5th column! its horrible10:54
mptin pathological cases e.g. if Notify OSD is trying to scale a 42*42 icon to 48*4810:54
macvrtoo much contrast10:54
mptIs that the Sinc/Lanczos3?10:54
SiDithe last column is lanczos + sharpen10:55
SiDithe 4th colomn for monkey is lanczos + smooth sharpen10:55
SiDithe 4th column for other pictures is lanczos10:55
macvr2nd?10:55
SiDihttp://paste.ubuntu.com/206852/10:56
macvri think cubic is best10:57
mptSo fish sharpen well but monkeys do not? :-)10:58
SiDimpt: actually the fish was 900x900 and monkey 64x64 :)10:59
SiDiwhat i wanted to show here is that the sharpen's intensity should depend on how big the image was10:59
SiDifor a good result10:59
SiDihow big the image was -> how blur the resized one will be -> how much it should be sharpened10:59
mptSo how about an image that's only ~10% larger than the target size?11:00
SiDi50x50 ?11:03
mpte.g. 55*55 down to 48*4811:04
mptThat's about the worst case, so it would be useful to tell which algorithms are best at avoiding horrible results11:04
* SiDi just made a 64x64 one :(11:05
SiDibug 39379711:05
SiDihttps://bugs.launchpad.net/notify-osd/+bug/393797 (no ubottu x.x)11:05
macvrSiDi: the description is not clear ! make the table look like your paste>http://paste.ubuntu.com/206852/11:10
SiDimacvr: happy ?11:15
macvr:)11:15
mptSiDi, macvr: Ok, here's a hypothesis: The best approach is to use Sinc/Lanczos if the original image is smaller than the target size, and to use bicubic if the original image is larger than the target size.11:19
macvrmpt: out of curiosity , why Sinc/Lanczos for the small sizes? why not all use cubic?11:21
mptmacvr, compare the cubic vs. sinc on <http://www.all-in-one.ee/~dersch/interpolator/interpolator.html> for example11:25
mptbut feel free to make some more Notify-OSD-specific examples :-)11:25
macvrah... :)11:28
macvrmpt: just a couple of hrs ago i deleted all the screenshots i had done for the icons!! :(11:29
artirI want to help with the 100 papercuts project, but I just know python :(12:51
SiDiartir find a papercut concerning a python app then :)12:55
artirmaybe there is a list with those bugs, so I was asking for that12:56
mptartir, Launchpad doesn't keep track of which languages a package is written in13:31
* MacSlow -> lunch13:34
=== MacSlow is now known as MacSlow|lunch
mptartir, but two bugs in packages I'm fairly sure are written in Python are bug 349336 and bug 37769713:53
artiri'll take a look13:53
artirthose are already taken13:54
artirwell, the first one is no13:56
artirt13:56
=== MacSlow|lunch is now known as MacSlow
macvrMacSlow: how do i exclude notify bubbles from compiz animations? they are using the tootips close animation.14:46
macvrah ! just realized i had set notifications  to use compiz same as tooltips!14:50
* macvr bangs head on the wall!14:50
* SiDi helps macvr to bang his head on the wall.14:57
* macvr grateful 14:58
MacSlowsiDi the full resolution fish image example is 2000x2000 not 900x900 as you state in the test-script's desription text15:05
MacSlowSiDi I'm redoing that comparision table with the current upstream version of notify-osd15:05
SiDiMacSlow: okies15:07
SiDiMacSlow: yes sorry, my mistake15:07
SiDiMacSlow: mind having a look at this https://bugs.launchpad.net/notify-osd/+bug/382094 ? Just let me know if its feasible, and i'll do the appropriate changes if needed15:07
macvrSiDi: your test python uses your home folder!15:09
SiDimacvr: yes its why the one in the bug report uses shell scripts instead \o/15:09
macvroh... then i need to download that one!15:10
=== rgreening_ is now known as rgreening
=== GreySim_ is now known as GreySim
jdeslipI am trying to get a new blueprint accepted into the gnome-do project.  Can anyone here have a look and give me some feedback (or leave feedback on the whiteboard) https://blueprints.launchpad.net/do/+spec/current-workspace20:43
=== GreySim is now known as AwaySim
=== jono_ is now known as jono

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!