Archive for the ‘Sharemedia’ Category

Sharemedia
Collaboration between ShareMedia and Remus Information Management

August 11th, 2009

ShareMedia and Remus information Management are two open source RCP applications which have similar features :

ShareMedia is a multi-platform photo manager. It supports several repositories such as local computer, Jabber, Picasa web or Flickr.

RIM is a free OpenSource client application for the management of information with a connection to multitude of data repositories like Flickr, Youtube or Facebook and a desktop-integration for an optimal usage for the offline management, visualization and easy accessibility of information to the user.

A few weeks ago, Tom Seidel and I decided to work on Eclipse bundles that will be shared between the two projects in order to speed up development and improve reusability of our code.

Our first goal is to define a common API which will be used by both applications and to port the existing image viewers from ShareMedia to this new API. ShareMedia has two full screen viewers including an OpenGL based one, inspired from CoverFlow from iTunes (see screencast bellow @0:55).

While these bundles are mainly targeted to ShareMedia and RIM, they can also be used in the Eclipse IDE and in any RCP application.

We now have a first implementation of the viewer API and two basic viewers. A few features are still missing and there is no background image loading so the IU may freeze a few seconds while loading large images, but it is working.

The following explains how to install the viewers in Eclipse and in an RCP application.

Installing the demo viewer into Eclipse :

The viewer has a dependency on Nebula Gallery which is not yet packaged into the feature. So you have to install the gallery widget from its update site :

http://download.eclipse.org/technology/nebula/gallery/update-N/

then install the demo viewer from ShareMedia / RIM update site :

http://smedia-rim.sourceforge.net/update/site.xml

Testing the viewer :

Select one or several image files in the package viewer / navigator view, open the context menu and select View in full screen…

viewer-fullscreen

Your monitors will fade to black and the first file will be displayed on your primary monitor. Commands are : ESC – Return to Eclipse , SPACE – Next image.

Multi-monitor setups are supported. Your secondary monitor will let you select the image to display on the primary monitor using a gallery of all items from your selection.

How to add a viewer to your application :

First, you will have to add the following bundles to your application

  • org.sharemediarim.api : the base API plugin, always required
  • org.sharemediarim.simple : the basic viewers. These are the only viewers available right now, just wait :-)
  • org.sharemediarim.viewers.adapter.file : the adapter for IFile objects. Only if you want do show eclipse resources (IFile) in the viewer.
  • org.apache.sanselan : dependency of o.s.v.adapter.file, used to read image thumbnails.
  • org.sharemedia.rim.viewers : Eclipse integration. Adds full screen action for IFile items in the context menu.

If you didn’t use the Eclipse integration, you can open the viewer from your code (usually in an action) :

1 – Create a viewer : a viewer can display images, but not necessary in full screen. It can also be hosted in a view :

IViewer viewer= new SampleViewer();

2 – Create a full screen viewer from the previous viewer. You can also provide additional viewers which will be displayed on secondary monitors.

final GenericFullScreenViewer fullScreenViewer = new GenericFullScreenViewer(new SampleViewer());

3 – Set the viewer’s input. Objects within the selection must implement IAdaptable and have an adapter to Image or IAdvancedImage. We provide a default Adapter for IFile in org.sharemediarim.viewers.adapter.file.

fullScreenViewer.setInput(structuredSelection);

4 – Register a listener to dispose the viewer on close. You can also reuse the viewer every time, and dispose it only on exit.

fullScreenViewer.addCloseListener(new Listener() {
public void handleEvent(Event event) {
viewer.dispose();
}});

5 – Finally, open the viewer :

fullScreenViewer.open();

Get involved :

If you are interested by using these viewers in your application or by creating new implementations, don’t hesitate to get in touch with us and help improve this API and viewers.

Project home page : http://sourceforge.net/projects/smedia-rim/

Issue tracker : http://www.remus-software.org/jira/browse/SMEDIARIM

Forum : http://sourceforge.net/forum/forum.php?forum_id=977188

Sharemedia
Eclipse 3.5 RC3 released : Cocoa works great

May 31st, 2009

Eclipse 3.5 RC3 is out and this release fixes the last issues (Bugs 277539 and 277437) I was seeing when running the best test suite I have, ShareMedia, on the previous 3.5 RC2 Cocoa x86_64 SWT port.

Now everything is working, even the most tricky parts such as custom widgets, Open GL with LWJGL and animations…. :-)

ShareMedia running on SWT 3.5 Cocoa x86_64

ShareMedia running on SWT 3.5 Cocoa x86_64

The new 3.5 release also brings some long-waited features on Mac OS X :

- Java 6 and 64 bits support

- Shell modified hint

Shell modified hint

Shell modified hint

- Shell sheet style

Shell sheet style

Shell sheet style

- Program icons are now returned in full size !!!! Program.findProgram("jpg").getImageData() returns beautiful 512×512 icons instead of 16×16, see the following gallery widget snippet :

Gallery Snippet on SWT 3.4

Gallery Snippet on SWT 3.4

Gallery Snippet on SWT 3.5

Gallery Snippet on SWT 3.5

UPDATE: Oh no ! this is a cocoa bug, images should still be returned in 16×16. SWT committers, please don’t fix it ! :-) I hope this will help fixing bug 181723.

These improvements make Eclipse 3.5 an absolute must for all Mac users.

The only thing I’m still missing is the Native OSX toolbar (bug 222859)

I would like to thanks all developpers who worked very hard to create this great Cocoa port in only one year and those who keep hacking to improving Eclipse UI on Mac.

Sharemedia
ShareMedia review and tutorial by Danny Gaethofs

October 1st, 2008

Danny Gaethofs wrote a weblog article about ShareMedia. Several steps are described including creating a new library, importing photos, changing metadata and uploading files to picasa web. The URL is :
http://danga.blogsome.com/2008/09/27/share-media-de-multi-platform-foto-en-video-manager/ (English and Dutch versions are available using the top-right switch on the page)

Sharemedia
ShareMedia 0.3.2 released

May 28th, 2008

ShareMedia is a photo manager based on Eclipse RCP. (open source / EPL)

Main features are :

  • Automatic file management (like in iTunes)
  • Sort and search using photos metadata
  • Standard and OpenGL photo viewers
  • Connect to Picasa, Jabber and Flickr (alpha) to share files
  • Ability to copy files between 2 accounts (Picasa/Picasa, Picasa/Flickr, Picasa/local files)
  • Plug-ins support (like all RCP applications)
  • much more…

This new release (0.3.2) includes :

  • Integrated intro content with tutorials and usefull links
  • SWT Animation Toolkit is now used to provide nice UI effects
  • Better error checking for password
  • Several bug fixes on the OpenGL viewer

For SWT/RCP developpers :
The Nebula Gallery Widget and the SAT toolkit where initially developed for this application so it is a good example on how they can be used.

Used libraries : SWT, RCP, Nebula widgets, LWJGL, DerbyDB, SmackAPI, Drew Noakes’s metadata Extractor, GData, FlickrAPI, SAT.

Screencasts :

Part 1 : Connect to a Picasa account, 3D and 2D fullscreen display

Part 2 : Download and upload photo, see metadata, create album and intelligent lists.

For the next release, I’m looking for some Java feedback. If you’re a Java developer and you already worked on the following topics, please drop a comment here.
- Writing EXIF / IPTC tags. (ShareMedia only have read support right now)
- Working with videos (creating thumbnails, playing in a SWT UI or OpenGL Canvas).

Thanks,

Sharemedia
Smooth Scrolling for the Nebula Gallery widget

February 24th, 2008

This week end, I added Smooth Scrolling for the Gallery view of ShareMedia. This is implemented using a simple class which captures the mouse wheel event and replace the standard behavior by a nice smooth movement (duration can be changed easily).

(Planeteclipse readers : video is not displayed there, just click on the title of the post to go to my blog)


ScrollingSmoother s = new ScrollingSmoother();
s.smoothControl( anyScrollableControl );

Currently, this only works on the Nebula Gallery Widget (maybe others), because fake events which are generated do not include all data required by standard SWT controls. The next step is to handle any scrollable control, and smooth scrolling even if scrollbars are used.

This class can be found here.
This is only a POC, the code is horrible but will be cleaned up soon.

UPDATE : this class currently work with the following widgets :
Shell
Canvas
StyledText

NOT working :
Tree
Table
Text

BTW : ShareMedia 0.3.1 is finally released, download it on sourceforge