ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Rating Images
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

skippix

USA
68 Posts

Posted - Feb 07 2013 :  08:49:53  Show Profile  Reply
What property or method can I use to get a image file's star rating?



Thanks!

w2m

USA
1990 Posts

Posted - Feb 07 2013 :  09:40:50  Show Profile  Reply
Title1.Caption := 'Title: ' + iImageENIO.Params.EXIF_XPTitle;
Subject1.Caption := 'Subject: ' + iImageENIO.Params.EXIF_XPSubject;
Rating1.Caption := 'Rating: ' + IntToStr(iImageENIO.Params.EXIF_XPRating);
Comment1.Caption := Comment: ' + iImageENIO.Params.EXIF_XPComment;
Author1.Caption := Author: ' + iImageENIO.Params.EXIF_XPAuthor;
KeyWords1.Caption := Keywords: ' + iImageENIO.Params.EXIF_XPKeywords;

See the help file for details.

William Miller
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Go to Top of Page

skippix

USA
68 Posts

Posted - Feb 07 2013 :  09:46:49  Show Profile  Reply
Thanks!
Go to Top of Page

skippix

USA
68 Posts

Posted - Feb 07 2013 :  11:05:04  Show Profile  Reply
ok, tried it, and after digging through the documentation, have found that just as the name implies, that is an XP property...

what about Vista and Windows 7?

in my sample photo, using your code, the value comes up not 2, but -1
Go to Top of Page

w2m

USA
1990 Posts

Posted - Feb 07 2013 :  11:06:51  Show Profile  Reply
it also works on windows 7 and I suspect Vista as well... I have windows 7 so you will have to test on anything else.

What does windows explorer->Properties->Details tab say for the photo?

Are you calling iImageENIO.LoadFromFile(AFilename) or iImageENIO.ParamsFromFile(AFilename) before trying to access the EXIF values?

This is what I get with the latest version of ImageEn on Windows 7:

William Miller
Go to Top of Page

Uwe

284 Posts

Posted - Feb 07 2013 :  11:15:38  Show Profile  Reply
It works in Vista as well.
Go to Top of Page

skippix

USA
68 Posts

Posted - Feb 07 2013 :  11:41:23  Show Profile  Reply
i'm simply running the demo program exif.exe. i modified it to add the EXIF_XPRating property. i also modified it to use LoadFromFile instead of ParamsFromFile. it's not pulling the value.

william, where is the property browser that you're using? is that in the demos?

Go to Top of Page

w2m

USA
1990 Posts

Posted - Feb 07 2013 :  11:52:26  Show Profile  Reply
The screenshot of the application I posted is from a demo that ships with my EBook. Although I just added the XP description Tab today to the demo, to reply to your request for information.

William Miller
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Go to Top of Page

skippix

USA
68 Posts

Posted - Feb 07 2013 :  12:03:17  Show Profile  Reply
another reason to buy the book :D

which i'll do this afternoon. i won't be able to get back to this until tomorrow morning, but as soon as i can run through your code, i'll let you know what i'm finding. thanks for you help!
Go to Top of Page

w2m

USA
1990 Posts

Posted - Feb 07 2013 :  12:24:54  Show Profile  Reply
when you purchase the book, I'll send you the update that includes the star rateing....

William Miller
Go to Top of Page

skippix

USA
68 Posts

Posted - Feb 09 2013 :  10:49:14  Show Profile  Reply
[Got the book and am REALLY looking forward to putting it to use! Thanks for including the revised Image Properties demo!]

I have spent the morning testing the ImageEn properties interface via the demo developed by William; I have NOT modified the code in any way. The following outlines my testing and my results. At the bottom are links to the two image files that I used for testing.

First, produce an image with no Description properties set.

1) Check the image properties in Photoshop under File | File Info. Nothing shows (except for the copyright information).



2) Check the image properties in Windows Explorer. No Tags, no Title, no Rating.



3) Right-click the image and open the Property Browser. No properties show in the Description section of the Details tab.



4) Check the properties using the Image Properties demo application. "The image does not have details information."



Next, I used Adobe Lightroom to produce an image with with Description properties.

5) Check the image properties in Windows Explorer. There are values for Tags, Title, and Rating properties.



6) Right-click the image and open the Property Browser. Title, Subject, Rating, and Tag properties are populated.



7) Check the image properties in Photoshop under File | File Info. Document Title, Author, Description, Rating, Description Writer, and Keyword properties have values. Note: Author has a ";" instead of a ",".



8. Check the properties using the Image Properties demo application. Again, "The image does not have details information."

This is not what I would have expected.



Next, in Windows Explorer, I clicked on the Tags values and added "Ambient Lighting" to the list of tags and clicked the [Save] button.

9). In Windows Explorer, I moused over the Tags values and verified the new tag "Ambient Lighting" as in the tag values.



10) Right-click the image and open the Property Browser, click on the Details tag, mouse over the Tags values and verified that "Ambient Lighting" was in the tag values.



11) Check the image properties in Photoshop under File | File Info and verified that "Ambient Lighting" was in the tag values.



12) Check the properties using the Image Properties demo application. This time the Keyword property is populated, but the other Description properties are still blank.



Next, using the Windows Property Inspector, I changed the star rating from 3 to 4 and clicked the [Apply] button.

13) The change shows up immediately in Windows Explorer.



14) The star rating change shows up in Photoshop File Info.



15) The star rating change also shows up in the Image Properties demo application.



16) Using the Image Properties demo application, I changed the following properties: Title, Subject, Author and then clicked [Apply].



17) Right-click on the image to open the Windows property inspector, click on the Details tab, and note changes to the Subject and Comments properties.



18) In Photoshop, the File Info, the only change is a mangling of the Author. The Title and Description remain unchanged.



Here are links to the test files:
http://www.skippix.us/wp-content/uploads/2013/02/130208-Test.jpg
http://www.skippix.us/wp-content/uploads/2013/02/130208-Test-2.jpg

At this point, I would draw the following conclusions:
1) ImageEn does not read the Title, Rating, Subject(Description), Author, or Keyword properties the same manner as Windows and Photoshop.

2) This issue is a due to something inside the ImageEn code as opposed to how the code is used.

If I am wrong, please, please tell me how to use the code as is so that I can read and write these properties safely and accurately. Otherwise, I would urge you to investigate and fix these issues so that we can read and write without fear of misrepresenting, much less destroy, the data contained in the image files.

Thanks to all involved in resolving this!
Go to Top of Page

w2m

USA
1990 Posts

Posted - Feb 09 2013 :  11:33:38  Show Profile  Reply
I do not have photoshop so I can not test that.. But I did test the demo with Windows 7 explorer and I found that when an EXIF value is changed in the demo it appears the same in Explorer and when I change an EXIF value in Explorer it appears in the demo.

So far I have not been able to understand why you are getting different results between explorer and the demo.

Are you using the latest version of ImageEn?
Are you using Windows 7?

... because that is what I am using...

Start with an image with no Details.
Load the image into the demo then after you change the values and after you press the apply button, close the dialog.

49.13 KB
Then in the shelllistview right click the file name and select properties at the bottom of the popupmenu. The select the details tab to verify the details change.



28.23 KB

Here everything works as expected both when changing the details in explorer or in the demo.

This discussion is getting pretty large... if you have further discussion email me.

William Miller
Go to Top of Page

w2m

USA
1990 Posts

Posted - Feb 09 2013 :  16:43:02  Show Profile  Reply
For those following this, it turns out Adobe LightRoom saves the XP_EXIF parameters in a way that ImageEn can not read them. If the file saved with LightRoom are loaded into Windows Explorer and all the XP_EXIF values are edited and saved, ImageEn can read all of the XP_EXIF parameters in the file.

All the other EXIF parameters saved with Adobe LightRoom can be read however.

William Miller
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: