Hi,<br>this is adressed to Frank because I think you may answer to that easily, but maybe anyone could comment on this.<br>I'm writing about the opendesktop api especially for it's blenderstuff version if there's one.<br>
So to recall about my project, I'm working on a client for Blender which could interact with several blender repositories (including <a href="http://blenderstuff.org">blenderstuff.org</a>) 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.<br>
<br>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.<br><br>looking at this for example taken from the LIST function of the online API:<br>
<pre id="line1"><<span class="start-tag">id</span>>81388</<span class="end-tag">id</span>><br> <<span class="start-tag">name</span>>Glassified</<span class="end-tag">name</span>><br></pre><pre id="line9">
<<span class="start-tag">version</span>>1.0</<span class="end-tag">version</span>><br> <<span class="start-tag">changed</span>>1212187283</<span class="end-tag">changed</span>><br> <<span class="start-tag">created</span>>1211236532</<span class="end-tag">created</span>><br>
<<span class="start-tag">typeid</span>>76</<span class="end-tag">typeid</span>><br> <<span class="start-tag">typename</span><span class="error"><span class="attribute-name">/</span></span>><br> <<span class="start-tag">language</span>></<span class="end-tag">language</span>><br>
<<span class="start-tag">user</span>>painkiller101</<span class="end-tag">user</span>><br></pre><pre id="line16"> <<span class="start-tag">downloads</span>>2431</<span class="end-tag">downloads</span>><br>
<<span class="start-tag">score</span>>92</<span class="end-tag">score</span>><br> <<span class="start-tag">comments</span>>54</<span class="end-tag">comments</span>><br> <<span class="start-tag">preview1</span>><a href="http://www.blenderstuff.org/content/preview.php?preview=1&">http://www.blenderstuff.org/content/preview.php?preview=1&</a><span class="entity">amp;</span>id=81388&<span class="entity">amp;</span>file1=81388-1.jpeg&<span class="entity">amp;</span>file2=81388-2.jpg&<span class="entity">amp;</span>file3=&<span class="entity">amp;</span>name=Glassified</<span class="end-tag">preview1</span>><br>
</pre><pre id="line20"> <<span class="start-tag">previewpic1</span>><a href="http://www.blenderstuff.org/CONTENT/content-pre1/81388-1.jpeg">http://www.blenderstuff.org/CONTENT/content-pre1/81388-1.jpeg</a></<span class="end-tag">previewpic1</span>><br>
</<span class="end-tag">entry</span>><br></pre>there seems to be 3 kinds of previews :<br>a) previewpic1<br>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)<br>
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.<br>What's the real difference between preview of class a) and previews of class c) ?<br>
<br>Looking at : <a href="http://api.kde-apps.org/V1/GET/72739">http://api.kde-apps.org/V1/GET/72739</a> with an excerpt below :<br><pre id="line1"> <<span class="start-tag">data</span>><br> <<span class="start-tag">id</span>>72739</<span class="end-tag">id</span>><br>
<<span class="start-tag">name</span>>Manslide</<span class="end-tag">name</span>><br> <<span class="start-tag">version</span>>v2.0.3</<span class="end-tag">version</span>><br></pre>...<pre id="line61">
<<span class="start-tag">comments</span>>150</<span class="end-tag">comments</span>><br> <<span class="start-tag">depend</span>>Qt 4.x</<span class="end-tag">depend</span>><br><b> <<span class="start-tag">preview1</span>><a href="http://www.KDE-Apps.org/content/preview.php?preview=1&">http://www.KDE-Apps.org/content/preview.php?preview=1&</a><span class="entity">amp;</span>id=72739&<span class="entity">amp;</span>file1=72739-1.jpg&<span class="entity">amp;</span>file2=72739-2.jpg&<span class="entity">amp;</span>file3=72739-3.jpg&<span class="entity">amp;</span>name=Manslide</<span class="end-tag">preview1</span>><br>
</b></pre><pre id="line66"><b> <<span class="start-tag">preview2</span>><a href="http://www.KDE-Apps.org/content/preview.php?preview=2&">http://www.KDE-Apps.org/content/preview.php?preview=2&</a><span class="entity">amp;</span>id=72739&<span class="entity">amp;</span>file1=72739-1.jpg&<span class="entity">amp;</span>file2=72739-2.jpg&<span class="entity">amp;</span>file3=72739-3.jpg&<span class="entity">amp;</span>name=Manslide</<span class="end-tag">preview2</span>><br>
<<span class="start-tag">preview3</span>><a href="http://www.KDE-Apps.org/content/preview.php?preview=3&">http://www.KDE-Apps.org/content/preview.php?preview=3&</a><span class="entity">amp;</span>id=72739&<span class="entity">amp;</span>file1=72739-1.jpg&<span class="entity">amp;</span>file2=72739-2.jpg&<span class="entity">amp;</span>file3=72739-3.jpg&<span class="entity">amp;</span>name=Manslide</<span class="end-tag">preview3</span>><br>
<<span class="start-tag">previewpic1</span>><a href="http://www.KDE-Apps.org/CONTENT/content-pre1/72739-1.jpg">http://www.KDE-Apps.org/CONTENT/content-pre1/72739-1.jpg</a></<span class="end-tag">previewpic1</span>><br>
</b></pre><pre id="line69"><b> <<span class="start-tag">previewpic2</span>><a href="http://www.KDE-Apps.org/CONTENT/content-pre2/72739-2.jpg">http://www.KDE-Apps.org/CONTENT/content-pre2/72739-2.jpg</a></<span class="end-tag">previewpic2</span>><br>
<<span class="start-tag">previewpic3</span>><a href="http://www.KDE-Apps.org/CONTENT/content-pre3/72739-3.jpg">http://www.KDE-Apps.org/CONTENT/content-pre3/72739-3.jpg</a></<span class="end-tag">previewpic3</span>><br>
<<span class="start-tag">smallpreviewpic1</span>><a href="http://www.KDE-Apps.org/CONTENT/content-m1/m72739-1.png">http://www.KDE-Apps.org/CONTENT/content-m1/m72739-1.png</a></<span class="end-tag">smallpreviewpic1</span>><br>
<<span class="start-tag">smallpreviewpic2</span>><a href="http://www.KDE-Apps.org/CONTENT/content-m2/m72739-2.png">http://www.KDE-Apps.org/CONTENT/content-m2/m72739-2.png</a></<span class="end-tag">smallpreviewpic2</span>><br>
<<span class="start-tag">smallpreviewpic3</span>><a href="http://www.KDE-Apps.org/CONTENT/content-m3/m72739-3.png">http://www.KDE-Apps.org/CONTENT/content-m3/m72739-3.png</a></<span class="end-tag">smallpreviewpic3</span>><br>
</b> <<span class="start-tag">downloadtype1</span>></<span class="end-tag">downloadtype1</span>><br></pre><pre id="line75"> <<span class="start-tag">downloadlink1</span>><a href="http://www.KDE-Apps.org/content/download.php?content=72739&">http://www.KDE-Apps.org/content/download.php?content=72739&</a><span class="entity">amp;</span>id=1</<span class="end-tag">downloadlink1</span>><br>
<<span class="start-tag">downloadname1</span>>Binary + Source</<span class="end-tag">downloadname1</span>><br> <<span class="start-tag">downloadsize1</span>></<span class="end-tag">downloadsize1</span>><br>
</<span class="end-tag">data</span>><br></pre>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*.<br>
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.<br>
<br>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.<br>
<br>So in short, I would propose for each items, to have direct links within the following tags:<br>- for the LIST() output : <preview1>(thumbnail) and <previewpic1>(big)<br>- 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)<br>
<br>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.<br>
<br>Jonathan<br>