This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 17 - Pages: 2 [ 1 2 | Next ] - Last Post: 14-Jan-2009 19:58 Last Post By: TomCee
TomCee

Posts: 382
Registered: 11-Jul-2005
first plugin
Posted: 13-Jan-2009 17:23
 
  Click to reply to this thread Reply
Attachment InfoWindow.java (3.6 KB)
Attachment MetaPlugin.java (1.4 KB)
Attachment MetaInfo.jar (7.5 KB)
Referring to this thread: http://jalbum.net/forum/thread.jspa?threadID=27787&start=0&tstart=0 here's my first plugin. You need jalbum 8.1.6, the java version, and the plugin is build on java 1.5.
Just place the .jar file in the jalbum programs /ext directory and (re)start jalbum. Also available are the uncompiled java files, so you can see how I messed up :)
The plugin gives an entry to the context menu (t.i. right-click) of an image in the jalbum explorer window, and will extract the metadata of an jpeg image. I'd love to hear your reactions, be it positive or negative. At least please let me know if it just works ;)

regards,
Tom
kristoffer

Posts: 46
Registered: 7-Dec-2007
Re: first plugin
Posted: 13-Jan-2009 17:32   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
I just tried it and it seems to be working fine :)
TomCee

Posts: 382
Registered: 11-Jul-2005
Re: first plugin
Posted: 13-Jan-2009 17:38   in response to: kristoffer in response to: kristoffer
 
  Click to reply to this thread Reply
ha!.....sigh of relief :D

regards,
Tom
kristoffer

Posts: 46
Registered: 7-Dec-2007
Re: first plugin
Posted: 13-Jan-2009 17:44   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
Now we just need a way to write metadata ;)
TomCee

Posts: 382
Registered: 11-Jul-2005
Re: first plugin
Posted: 13-Jan-2009 17:49   in response to: kristoffer in response to: kristoffer
 
  Click to reply to this thread Reply
well, I thought about that, but it seemed not in line with the jalbum philosofy of not altering the original file :D
And for the jpeg comment section you already did it !!!!

regards,
Tom
Dschuwi

Posts: 461
Registered: 12-Nov-2003
Re: first plugin
Posted: 13-Jan-2009 17:52   in response to: kristoffer in response to: kristoffer
 
  Click to reply to this thread Reply
kristoffer wrote:
Now we just need a way to write metadata ;)

Well, there is dedicated software for that task out there. I honestly believe Jalbum's "Comment" and "Title" features are perfectly sufficient for everyday use.
jimberry

Posts: 502
Registered: 30-Aug-2004
Re: first plugin
Posted: 13-Jan-2009 17:53   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
Hey, that's really cool, Tom.
Much more convenient than making a debug album to find out what metadata is available.
And you did it so QUICKLY!!! :D
I am looking forward to seeing what other plugins will start appearing.
Dschuwi

Posts: 461
Registered: 12-Nov-2003
Re: first plugin
Posted: 13-Jan-2009 17:58   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
Yes, it works :-)
Very useful!
It displays some IPTC fields as "Unknown Tag", however, like "Country code" (0x0264)" or "Program Version" (0x0246), which are apparently those tags not directly supported by Jalbum.
TomCee

Posts: 382
Registered: 11-Jul-2005
Re: first plugin
Posted: 13-Jan-2009 18:26   in response to: jimberry in response to: jimberry
 
  Click to reply to this thread Reply
thanks Jim! All the work was done by David and Drew N., who wrote the classes for metadata extraction, really!
If you have suggestion, I'm open for idea's! It's a lot like Sudoku's, but with more helpers available :D

regards,
Tom
TomCee

Posts: 382
Registered: 11-Jul-2005
Re: first plugin
Posted: 13-Jan-2009 18:29   in response to: Dschuwi in response to: Dschuwi
 
  Click to reply to this thread Reply
Hi HP,

it just reflects what was written in the file. Extracting the metadata in an easy way was a feature I wanted for long, and now with the excellent work of David, it is available.

regards,
Tom
Dschuwi

Posts: 461
Registered: 12-Nov-2003
Re: first plugin
Posted: 13-Jan-2009 19:55   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
TomCee wrote:
Hi HP,

it just reflects what was written in the file.


Tom,

The data are there in the file, and your code does extract them and works perfectly fine. Let me give an example:
The printout of the metadata plugin gives:
[Iptc] City - VIENNA
[Iptc] Unknown tag (0x0264) - AUT
[Iptc] Country/Primary Location - Austria

while it should be
[Iptc] City - VIENNA
[Iptc] Country Code - AUT
[Iptc] Country/Primary Location - Austria


Digging into Drew Noakes' IptcDirectory.java I found that he simply has not defined static tag values for several IPTC fields. Code like
public class IptcDirectory extends Directory
{
    public static final int TAG_COUNTRY_CODE = 0x0264;
.
.
    static
    {
        tagNameMap.put(new Integer(TAG_COUNTRY_CODE), "Country Code");
.
.

simply is not there, hence the "Unknown Tag" description

For Classic Aligned 2 I haved solved this that way that I extract those IPTC fields by their hex value using Drew's library and display the description accordingly. So I can display all the "Country Code", "Program Version", "Service ID", "Fixture ID" and so on useful :-) IPTC fields along with their name.

And I absolutey agree with you: It is like playing Sudoku. Once you've started, you can't stop anymore :-)

cheers
hp
TomCee

Posts: 382
Registered: 11-Jul-2005
Re: first plugin
Posted: 13-Jan-2009 20:39   in response to: Dschuwi in response to: Dschuwi
 
  Click to reply to this thread Reply
hi HP,

have you emailed Drew with your updates? I wouldn't mind updating the library with missing tags, but it isn't my library, and I doubt David would accept standard libraries modified by me. The metadata-extractor library is encapsualed in JAlbum. Which leads me to the question, what if we want to enclose our own libraries with the plugin, where to place them?? I know I can include a lib folder with the jar but what if we get 10 plugins each with their own library? I'd like to have Davids opinion on that.
Anyway, have you stepped over to NetBeans or Eclipse yet? It has a lot of bonusses and makes coding a lot easier :D

regards,
Tom

davidekholm

Posts: 3,579
Registered: 18-Oct-2002
Re: first plugin
Posted: 13-Jan-2009 21:39   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
Thanks for your great plugin Tom!
Drew have basically abandoned his wonderful Metadata Extractor project. The last year (at least) I've therefore maintained it somewhat, so the most current version of this library is with Jalbum. In order for you, our wonderful community, to improve this library I've extracted it from the core Jalbum project and made a separate project for it with source code and all (the final jar file goes in the "lib" folder). See this thread for all links you need in order to update the library:

http://jalbum.net/forum/thread.jspa?messageID=165143

When done, please pass me the updated files so I can include them with Jalbum! We should probably set up this project in our source code repository and refer to it from our developer section. So much to do, so little time...

Note, you need to use the version of Jalbum that requires Java.
Dschuwi

Posts: 461
Registered: 12-Nov-2003
Re: first plugin
Posted: 13-Jan-2009 22:40   in response to: TomCee in response to: TomCee
 
  Click to reply to this thread Reply
TomCee wrote:
hi HP,

have you emailed Drew with your updates?


Re David's reply - it seems to not beeing supported by Drew anymore, that what I've also found out a while ago in the Internet.

Anyway, the library works fine basically, it is just that for some values there is no static IPTC name provided. So if I find an IPTC field 0x0264 I know this is "Country Code" and simply name it "Country Code" instead of "Unkown Tag".

Anyway, have you stepped over to NetBeans or Eclipse yet? It has a lot of bonusses and makes coding a lot easier :D

Oh yes, I know I know....
No, I have tried a while ago with your very appreciated help, but I just did not have the time yet :-(
I am so familiar with Beanshell and the way it works currently.

bests
hp
TomCee

Posts: 382
Registered: 11-Jul-2005
Re: first plugin
Posted: 13-Jan-2009 22:49   in response to: Dschuwi in response to: Dschuwi
 
  Click to reply to this thread Reply
HP,

if you, or anyone else, sends me the to be updated tag info, I''l type them in the relevant java file and send it to David.

regards,
Tom
Legend
Forum admins
Helpful Answer
Correct Answer

Point your RSS reader here for a feed of the latest messages in all forums