[ghns] [Inkscape-devel] inkscape community site

Jonathan-David SCHRODER myselfhimself at free.fr
Sun Jun 1 05:05:35 PDT 2008


Hi,
this is adressed to Frank because I think you may answer to that easily, but
maybe anyone could comment on this.
I'm writing about the opendesktop api especially for it's blenderstuff
version if there's one.
So to recall about my project, I'm working on a client for Blender which
could interact with several blender repositories (including blenderstuff.org)
to be able to browse for objects, fetch some and upload other to
repositories. I intend to have a central server which tries to lookup the
various repositories periodically and update its cache of (which object -
can be found where) pairs. The client queries the central servers which
looks into its cache and gives links to the client for : image previews &
details of objects, direct links to download the objects.

These days I'm listing the various attributes that each repository provides
for the objects it stores. So preview picture is something I was concerned
with.

looking at this for example taken from the LIST function of the online API:

<id>81388</id>
   <name>Glassified</name>

   <version>1.0</version>
   <changed>1212187283</changed>
   <created>1211236532</created>
   <typeid>76</typeid>
   <typename/>
   <language></language>
   <user>painkiller101</user>

   <downloads>2431</downloads>
   <score>92</score>
   <comments>54</comments>
   <preview1>http://www.blenderstuff.org/content/preview.php?preview=1&amp;id=81388&amp;file1=81388-1.jpeg&amp;file2=81388-2.jpg&amp;file3=&amp;name=Glassified</preview1>

   <previewpic1>http://www.blenderstuff.org/CONTENT/content-pre1/81388-1.jpeg</previewpic1>
  </entry>

there seems to be 3 kinds of previews :
a) previewpic1
then for the preview1 tag : there are b) thumbnails at the top and c)big
pictures in the middle (screenshots 1,2,3 from the add content online form)
Is there a standard size for those types of previews ? I can guess that
there's one fixed size for type b) but no for the others.
What's the real difference between preview of class a) and previews of class
c) ?

Looking at : http://api.kde-apps.org/V1/GET/72739 with an excerpt below :

 <data>
  <id>72739</id>
  <name>Manslide</name>
  <version>v2.0.3</version>

...

  <comments>150</comments>
  <depend>Qt 4.x</depend>
*  <preview1>http://www.KDE-Apps.org/content/preview.php?preview=1&amp;id=72739&amp;file1=72739-1.jpg&amp;file2=72739-2.jpg&amp;file3=72739-3.jpg&amp;name=Manslide</preview1>
*

*  <preview2>http://www.KDE-Apps.org/content/preview.php?preview=2&amp;id=72739&amp;file1=72739-1.jpg&amp;file2=72739-2.jpg&amp;file3=72739-3.jpg&amp;name=Manslide</preview2>
  <preview3>http://www.KDE-Apps.org/content/preview.php?preview=3&amp;id=72739&amp;file1=72739-1.jpg&amp;file2=72739-2.jpg&amp;file3=72739-3.jpg&amp;name=Manslide</preview3>
  <previewpic1>http://www.KDE-Apps.org/CONTENT/content-pre1/72739-1.jpg</previewpic1>
*

*  <previewpic2>http://www.KDE-Apps.org/CONTENT/content-pre2/72739-2.jpg</previewpic2>
  <previewpic3>http://www.KDE-Apps.org/CONTENT/content-pre3/72739-3.jpg</previewpic3>
  <smallpreviewpic1>http://www.KDE-Apps.org/CONTENT/content-m1/m72739-1.png</smallpreviewpic1>
  <smallpreviewpic2>http://www.KDE-Apps.org/CONTENT/content-m2/m72739-2.png</smallpreviewpic2>
  <smallpreviewpic3>http://www.KDE-Apps.org/CONTENT/content-m3/m72739-3.png</smallpreviewpic3>
*  <downloadtype1></downloadtype1>

  <downloadlink1>http://www.KDE-Apps.org/content/download.php?content=72739&amp;id=1</downloadlink1>
  <downloadname1>Binary + Source</downloadname1>
  <downloadsize1></downloadsize1>
 </data>

comment on the above dump : preview1,2 and 3 contain exactly the same url,
which leads to a dhtml pages with the thumbnail images as smallpreviewpic*
and the same big images as previewpic*.
The page linked in preview* elements contains items listed right after in
the xml file and parsing the html would require additional work for coders.
I can understand that some people may want to embed this html page into some
htmlview widget, so I'd suggest completely replacing the preview* tags by a
single <previewshtmlpage> which would encompass the html page url.

in the case of blender repo client usage of remote repositories, we would
like to have 1 thumbnail of fixed size (to avoid having to resize it on the
client side) per item if provided, and at least one big image (if possible
at a specific size as well) that would be showed if a user wants more
details. I wish this (1 link to thumbnail + 1 link to big image) pack
existed be in each entry elements of the xml returned by LIST(), I think
that it was the aim of preview1 and previewpic1 except that preview1 leads
to html.

So in short, I would propose for each items, to have direct links within the
following tags:
- for the LIST() output :  <preview1>(thumbnail) and <previewpic1>(big)
- for the GET() output : <preview[1-3]>(thumbnails), <previewpic[1-3]>(big),
<previewhtmlpage>(link to the dhtml page with thumbnails on top + 1 big
screenshot at a time in the bottom part)

this could break the API a very little and maybe some clients (so far I know
only khotnewstuff)... I don't know which tags khotnewstuff uses and which it
doesn't, but I doubt the url to html pages from preview[1-3] (LIST and GET
outputs)  are used by that tool.

Jonathan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freedesktop.org/archives/ghns/attachments/20080601/79e3280c/attachment.html 


More information about the ghns mailing list