denemo-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Denemo-devel] Thumbnails


From: Till Hartmann
Subject: Re: [Denemo-devel] Thumbnails
Date: Sun, 22 May 2011 12:16:11 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.17) Gecko/20110503 Lightning/1.0b2 Thunderbird/3.1.10

Am 21.05.2011 21:30, schrieb Richard Shann:
> It looks like it won't be too arduous to create thumbnails according to
> the gnome (and kde?) standard. Glib has a function
> g_compute_checksum_for_string ()
> which you use on the URI of the .denemo file. (e.g.
> "file:///home/jbloggs/mydenemofiles/mygreatwork.denemo") and with this
> as the file name you store a .png in ~/.thumbnails/normal of size
> 128x128 pixels.
> We would want the .png to be basically something created by denemo's
> print excerpt on the first three measures or so - a script could make an
> intelligent choice of how much to include so that the thumbnail was
> enough to identify the piece (we may need the larger sized thumbnails
> that the standard allows). (The \incipit in LilyPond is not this BTW).
> 
> This would have a nice consequence that folk using gnome (and kde?)
> would see these thumbnails in their file browsers when looking at
> their .denemo files.
> 
> There is then the job of displaying them in the denemo file selectors as
> you move down a list of .denemo files. Volunteers, as usual, always
> welcome:)
> 
> Richard
> 
> 
> 
> _______________________________________________
> Denemo-devel mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/denemo-devel

Am 21.05.2011 21:30, schrieb Richard Shann:
> It looks like it won't be too arduous to create thumbnails according to
> the gnome (and kde?) standard. Glib has a function
> g_compute_checksum_for_string ()
> which you use on the URI of the .denemo file. (e.g.
> "file:///home/jbloggs/mydenemofiles/mygreatwork.denemo") and with this
> as the file name you store a .png in ~/.thumbnails/normal of size
> 128x128 pixels.
> We would want the .png to be basically something created by denemo's
> print excerpt on the first three measures or so - a script could make an
> intelligent choice of how much to include so that the thumbnail was
> enough to identify the piece (we may need the larger sized thumbnails
> that the standard allows). (The \incipit in LilyPond is not this BTW).
>
> This would have a nice consequence that folk using gnome (and kde?)
> would see these thumbnails in their file browsers when looking at
> their .denemo files.
>
> There is then the job of displaying them in the denemo file selectors as
> you move down a list of .denemo files. Volunteers, as usual, always
> welcome:)
>
> Richard
>
>
>
> _______________________________________________
> Denemo-devel mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/denemo-devel

I've implemented thumbnail generation (according to the FDO spec) for
mypaint. A good description of what needs to be done can be found here:
http://jens.triq.net/thumbnail-spec/thumbsave.html
It's important to store the MTime as a PNG attribute in the thumbnail
file, so you do not unnecessarily regenerate thumbnails (which are
already up to date).
It would also make sense to store a 256x256 thumbnails, because
applications which want to use them can simply downscale them to their
needs.
If someone can point out to me how to extract the first few measures,
I'd like to try implementing them ;)

Till



reply via email to

[Prev in Thread] Current Thread [Next in Thread]