Module: Photo annotation v4.5 (v5 beta 3)
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Version 5 beta 3 If you want to test the next version of the module you can find it attached to this post along with the latest stable version. This version uses ajax to save, delete and edit annotations eliminating the need to reload the whole page when saving, updating or deleting annotations. Please note that I have still not figured out how to disable the "show full size" link of the image when clicking on annotations or on the delete/modify areas. Therefore the beta version removes the link completely and places a little box at the upper left corner of the re-sized image allowing to view the photo in full size. About this module This module allows you to create comments on photos similar to Flickr and Facebook (see screenshots below). It can notify users when a photo is tagged and comments are added. This module is partially compatible with rWatcher's TagFaces module which means that faces/notes/annotations created with one module will be shown by the other as well (user annotations create with the Photo annotation module will however not be shown by the TagFaces module). IMPORTANT: You cannot run both modules at the same time. Codex page: http://codex.gallery2.org/Gallery3:Modules:photo_annotation Add and edit annotations [img]http://codex.gallery2.org/images/9/95/Photoannotation_add_edit.png[/img] An annotation linking to a tag [img]http://codex.gallery2.org/images/4/43/Photoannotation_tag.png[/img] An annotation with title and description [img]http://codex.gallery2.org/images/1/18/Photoannotation_note.png[/img] Features
Configuration You can configure the module by going to Login -> Admin -> Settings -> Photo annotation Version history Version 1
Version 1.1
Version 1.2
Version 2
Version 2.1
Version 3
Version 4
Version 4.1
Version 4.2
Version 4.3
Version 4.4
Version 4.5 / 5 beta 3
---
|
||||||
nivekiam
![]()
Joined: 2002-12-10
Posts: 16504 |
![]() |
|||||
EDIT (changed to the already created codex page) Is there a reason you're linking to the Navigation Carousel module in the installation instructions? |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
nivekiam wrote:
Awesome! I've created a codex page for you to update as needed as well Thanks. I already created one: http://codex.gallery2.org/Gallery3:Modules:photo_annotation sorry for that (forgot to put it in the post). --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
nivekiam wrote:
Is there a reason you're linking to the Navigation Carousel module in the installation instructions? No good one anyway ;-) Thanks for that I removed the link. --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Version 1.1 can now be downloaded from the first post. --- |
||||||
bharat
![]()
Joined: 2002-05-21
Posts: 7994 |
![]() |
|||||
Just pulled your code into gallery3-contrib. |
||||||
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
|||||
Bugs: - RTL bug(s) (with Arabic language selected): - General bug(s): http://MySite.com/gallery/gallery/PictureXX and I see the dang page. 2010-08-29 17:33:03 +03:00 --- error: exception 'Database_Exception' with message '#1060: Duplicate column name 'description' [ ALTER TABLE items_faces ADD `description` varchar(2048) default NULL ]' in /home/****/public_html/gallery/system/libraries/Database_Mysqli_Result.php:27 Stack trace: #0 /home/****/public_html/gallery/system/libraries/Database_Mysqli.php(79): Database_Mysqli_Result_Core->__construct(false, 'ALTER TABLE ite...', Object(mysqli), true) #1 /home/****/public_html/gallery/system/libraries/Database.php(272): Database_Mysqli_Core->query_execute('ALTER TABLE ite...') #2 /home/****/public_html/gallery/modules/gallery/libraries/MY_Database.php(45): Database_Core->query('ALTER TABLE ite...') #3 /home/****/public_html/gallery/modules/photoannotation/helpers/photoannotation_installer.php(55): Database->query('ALTER TABLE {it...') #4 /home/****/public_html/gallery/modules/gallery/helpers/module.php(218): photoannotation_installer::upgrade('1') #5 /home/****/public_html/gallery/modules/gallery/controllers/admin_modules.php(89): module_Core::upgrade(Array, Array) #6 /home/****/public_html/gallery/modules/gallery/controllers/admin_modules.php(51): Admin_Modules_Controller->_do_save('photoannotation') #7 /home/****/public_html/gallery/modules/gallery/controllers/admin.php(62): Admin_Modules_Controller->confirm() #8 [internal function]: Admin_Controller->__call() #9 /home/****/public_html/gallery/system/core/Kohana.php(331): ReflectionMethod->invokeArgs(Array, Array) #10 /home/****/public_html/gallery/system/core/Event.php(208): Kohana_Core::instance('modules', Array) #11 /home/****/public_html/gallery/application/Bootstrap.php(67): Event_Core::run(Object(Admin_Controller), Array) #12 /home/****/public_html/gallery/index.php(94): require('/home/****/pub...') #13 {main}
Otherwise, the module is really promising. I am excited to get it working |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi there, mamouneyya wrote:
Bugs: Ahh yes I expected there might be some problems with RTL but - sorry for that - didn't test on RTL language. I will look into this as soon as I have some time. mamouneyya wrote:
- General bug(s): Fixed (see first post) mamouneyya wrote:
(2) I activated the module and played with it for a while. After that I deactivated. Now, every time I try to activate it again nothing happens. Fixed (see first post) mamouneyya wrote:
Otherwise, the module is really promising. I am excited to get it working Thank you. Very glad to hear that. From http://gallery.menalto.com/node/90183?page=1#comment-352077 : engineer wrote:
I just download the latest gallery3 and modules in gallery3-contrib. If I enable the photo_annotation module, the video clip can't be played well, only blank in video clip area. rWatcher's TagFaces has no such problem. I prefer use the new photo annotation module cause the user interface is better. Does anyone has the same problem on playing video clip? I can't test this right now but I think it should be fixed can you try with the version attached to the first post, please? --- |
||||||
engineer
Joined: 2005-09-13
Posts: 84 |
![]() |
|||||
http://gallery.menalto.com/node/90183?page=1#comment-352077 However, I still find another strange problems. I will draw a picture to show them. |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
Uli WOWZA! Awesome work! I found a minor bug: Clicking on the "X" to delete a tag, then pressing "cancel" goes to opening up the full item. (Latest git version) Another request. My XMP module now can use either the tagfaces module (for backwards compatibility) or your great photoannotation module. However, for seamless integration, I need to add the photoannotation.php file to the helpers/ folder of your module. Would it be possible for you to just include the file in your module, saving users the need to copy the file specifically? The file is attached as a zip file (the forum won't let me attach otherwise). Again, spectacular work, and thanks! Tomek |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi all, mamouneyya wrote:
Bugs: Fixed. mamouneyya wrote:
(2) The first time you try to resize the annotation selection square, it is moved to the left side so it is get out of the photo in case you were in the middle or so. Fixed. mamouneyya wrote:
(3) The text needs to be right-aligned for RTL languages. Partially fixed. I'm not 100% happy with the result since I would prefer to have e.g. the resize edge/corner at the bottom left etc. But text should be aligned correctly now. From http://gallery.menalto.com/node/90183?page=1#comment-351728 mamouneyya wrote:
(1) Make the user able to add a tag directly from the annotate interface, instead of manually linking an already existed tag. That said, when you write a name in the Face field, Gallery automatically will add a tag using that name. That way there is no need to the drop-down tags list anymore. Implemented. mamouneyya wrote:
(2) Show the list of faces tagged in the photo below it, like Facebook way. Already implemented with 1.2 tkott wrote:
I found a minor bug: Clicking on the "X" to delete a tag, then pressing "cancel" goes to opening up the full item. (Latest git version) Fixed although not 100% ideal yet. I will look into a more "ajaxy" solution for the next version. tkott wrote:
Another request. My XMP module now can use either the tagfaces module (for backwards compatibility) or your great photoannotation module. However, for seamless integration, I need to add the photoannotation.php file to the helpers/ folder of your module. Would it be possible for you to just include the file in your module, saving users the need to copy the file specifically? The file is attached as a zip file (the forum won't let me attach otherwise). I added the file. engineer wrote:
However, I still find another strange problems. I will draw a picture to show them. OK let me know the details and I will have a look what's going on. --- |
||||||
engineer
Joined: 2005-09-13
Posts: 84 |
![]() |
|||||
@hukoeth, Finally I find the strange problem caused by Resize Protect module, not by photo annotation module. Please ignore it. Thank you for your awesome work to the great module. |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
Great work Uli! Everything works as far as I can tell!! Thanks for including my file. Tomek |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hello, engineer wrote:
Finally I find the strange problem caused by Resize Protect module, not by photo annotation module. Please ignore it. Thank you for your awesome work to the great module. Thanks for the feedback. Let me know if you see any other problems or incompatibilities. tkott wrote:
Everything works as far as I can tell!! Thanks for including my file. You're welcome. Glad to hear everything seems to be working. Thanks for testing. Uli --- |
||||||
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
|||||
WOW, this is really becoming amazing. hukoeth wrote:
Partially fixed. I'm not 100% happy with the result since I would prefer to have e.g. the resize edge/corner at the bottom left etc. But text should be aligned correctly now. It will be cool if you could implement it this way. Otherwise, I am just satisfied Some suggestions: - It's better, IMHO, to use the resize_bottom() function instead of photo_bottom() to show the face/note annotations. I know about your order module, but it is not because of the ordering. It's because I think that resize_bottom is more suitable position for such note. You can try it your-self. - I really liked the Ajaxy auto suggestions for tag names. However, it would be awesome if you can make it more user connected. For now I am thinking of: |
||||||
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
|||||
By the way, it seems that 'OK' and 'Cancel' buttons of the annotating form are not translatable. |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
mamouneyya wrote:
WOW, this is really becoming amazing. I'm glad to hear that. I will definitely try to implement this but I can't promise your when because I would like to implement one of your other suggestions first mamouneyya wrote:
- It's better, IMHO, to use the resize_bottom() function instead of photo_bottom() to show the face/note annotations. I know about your order module, but it is not because of the ordering. It's because I think that resize_bottom is more suitable position for such note. You can try it your-self. I will give it a try. The closer it is to the photo the better IMHO so I think it makes sense. mamouneyya wrote:
- I really liked the Ajaxy auto suggestions for tag names. However, it would be awesome if you can make it more user connected. For now I am thinking of: This is a very cool idea (although I will need to change a lot of tags on my gallery if I implement this). I will think of some ways how to do this. mamouneyya wrote:
(2) Add a section to the user profiles to show any photo the user annotated in. Nice idea as well. mamouneyya wrote:
By the way, it seems that 'OK' and 'Cancel' buttons of the annotating form are not translatable. Without checking: I think you're right. I will fix this with the next version. Thanks for the feedback, --- |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
Quote:
mamouneyya wrote: Personally, I'm having a hard time figuring out how this is different from having good tags, since clicking on a tag takes you to a album of pictures that tag is used in. If pictures tagged well, and with the name of the person, then you would be all set without a need to expand the module. All it takes is setting up the tags in a useful way. Am I missing something? Tomek |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi Tommek Uli --- |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
Ahh, yes. You are quite right that combining it with some sort of notification system would be difficult with just tags. What if you simply linked a tag to a username (perhaps through a profile page). Then all you would need is a call to SQL "Find all profiles which have the following tag id associated with them". Then email said profiles. You would then stick to using tags as tags, and profiles as profiles. Seems cleaner IMO. Tomek |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Sounds like a good approach I was thinking of something along these lines. For me the most important things are to keep it as simple and clean as possible and to make it configurable since I think not everyone would like to have this as default behaviour. |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi all, edit: Please find beta 2 three posts down. Please find attached to this post beta 1 of version 3 of the module. It is not completed yet and I have made many changes so there are most likely a few bugs. Please note that if you do install this version user profile pages will be overwritten and since this part is still under construction you will not be able to e.g. change your password, see your REST key etc. Here are the changes:
If you want to try it please don't forget to run the updater after uploading the new version (http://yourdomain/pathtogallery/upgrader). Please also be aware that this update will partially break the compatibility with the TagFaces module meaning that annotations with tags and notes associated will be displayed in both modules but annotations with users will only be displayed by the Photo Annotation module. Regards, --- |
||||||
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
|||||
Very nice. However, I think the tagging interface needs some work here. First, it should be clearer that you have to enter *one* of the three annotation types (user, face, note.) Second, it should be clearer that you can always enter a description, despite what type of annotation you used. As a result, the three annotation types should be grouped together, while the description field should be isolated in the bottom of the interface. Well. After some playing with 'Inspect Element' feature of Safari, I have got these results: The HTML code with the inline style attributes are: <form id="photoannotation-form" action="/~mamoun/gallery3fork2/index.php/photoannotation/save/2" method="post" style=""> <div style="background-color: #EEE; color: #4E7199; margin-bottom: 5px; padding: 6px 12px; height: 20px; "> <input type="hidden" name="csrf" value=removed for public display> <input type="hidden" name="noteid" value="1"> <input type="hidden" name="notetype" value= مستخدم: <select id="photoannotation-user-list" class="dropdown" style="float: left; width: 155px; " name="userlist"> <option value="-1">...</option> </select> </div> <strong>أو</strong> <br> <div style="background-color: #EEE; color: #4E7199; margin-bottom: 5px; padding: 6px 12px; height: 20px; "> وسم: <input id="image-annotate-tag-text" type="text" name="tagsList" style="width: 155px; float: left; " value="" autocomplete="off" class="ac_input"> <strong></strong> </div> <strong>أو</strong> <br> <div style="background-color: #EEE; color: #4E7199; padding: 6px 12px; margin-bottom: 15px; height: 20px; "> ملاحظة: <input id="image-annotate-text" type="text" name="text" style="float: left; width: 155px;" value=""> </div> الوصف (اختياريٌّ): <textarea id="image-annotate-desc" name="desc" rows="3" style="width: 240px; margin-top: 3px; "> </textarea> </form> What you think? |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi, Uli --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi all, edit: please find the latest beta in the post below Changes from beta 1:
Todo:
If you are updating from version 2 or 1 please be sure to run the updater (http://yourdomain/pathtogallery/upgrader). Thanks in advance for testing. --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hello, edit: please find version 4 beta 2 one post below. Please find attached to this post version 4 beta 1 (I had to bump the version no.). Changes from version 3 beta 2:
Please be sure to run the updater (http://yourdomain/pathtogallery/upgrader) Regards, --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hello, Here some of the changes: Hope someone can find some time to give it a try. Uli --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Version 4 RC can be downloaded from the first post. Changes from beta 2: For a full list of changes see version history in the first post. Regards, --- |
||||||
rlparadise
Joined: 2009-12-27
Posts: 65 |
![]() |
|||||
I downloaded and tested v4b2 last night. Didn't notice any major issues. On the admin page, you had two checkbox options that looked to be identical for display tags below a photo. This may already be fixed in v4RC so I will try to test again tonight. I did notice that one photo was flagged as "out of date" in my maintenance dashboard after working with annotations for a while. However, after trying to reproduce the problem a couple of different ways, I eventually just considered it an "anomaly". I'll continue to test tonight and thanks again for all of your hard work. |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
I'm glad to hear that thank you for testing. You are right about the check boxes. The first one should read "User annotations" and is not yet fixed. Thanks again, --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Version 4 final is out and can be downloaded from the first post.
For a full list of changes since version 3 please see first post. --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Please find version 4.1 attached to the first post. --- |
||||||
therat
Joined: 2009-10-08
Posts: 18 |
![]() |
|||||
Hello hukoeth, I think I found a bug with the latest experimental gallery3-3.0-rc-2-332-g3e1743b and latest photo annotation module ver. 4.1. When I switch on photo annotation module the sidebar disappears, also photo view doesn't show. When I turn it off everithing works normally. Here is what I see in the logs when trying to open an album: And here is what happening when trying to open a photo and just a blank page is showing: 2010-09-17 08:03:23 -07:00 --- error: Undefined variable: noeditablehover |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi therat, Regards, --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
therat wrote:
Hello hukoeth, Hi therat, Regards, --- |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
Hi Uli, Great improvements to the module, WOW! That's the way to write a module. I have one favor: it looks like somewhere along the line the function "add" got dropped from helpers/photoannotation.php which my module XMP looks for when adding faces. Could you add that function back in? (listed below) Thanks! Tomek
|
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
tkott wrote:
Hi Uli, Hi Tomek, If I read your code correctly you create tags if they don't exist already during the import process and you only save annotations with tags (not notes or users). Uli --- |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
That's an even better idea. Sorry I didn't see that function before. I'll take a look at your code and make sure my module calls things correctly. Thanks! Tomek |
||||||
tkott
Joined: 2010-06-07
Posts: 225 |
![]() |
|||||
Uli, My module now successfully points at your saveface function. Thanks for the heads up! Tomek |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hi Tomek, Uli --- |
||||||
therat
Joined: 2009-10-08
Posts: 18 |
![]() |
|||||
Hello Uli, On album load: On picture view load: ... And by the way I think that "Add anotation" button appeared in the photo dropdown menu. However nothing happens when I press it, no logs also. Thanks for your help, appreciated. PS. Ok, I think I found it: the "Users" block is not working together with annotation module. Sidebar shows when anotation is switched on and Users block is excluded. However "Add annotation" button still doesn't work. Error that still persists on photo view is: |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
therat wrote:
Thanks for your help, appreciated. No thank you so much for testing and reporting this (and for the error logs which make fixing really easy In any case: I fixed the reported two errors (hopefully they are the last) which should also make the add annotation button work again. You can find the updated version as usual attached to the first post. Thanks again, --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Version 4.4 is out. This is only a bugfix release addressing two issues with the JS code in IE8. The new version is attached to the first post. --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Hello, Edit: beta 2 can be found attached to the next post. Before you download please read the entire post. Changes
Please note that I have still not figured out how to disable the "show full size" link of the image when clicking on annotations or on the delete/modify areas. Therefor this version removes the link completely and places a little box at the upper left corner of the re-size allowing to view the photo in full size. Thank you in advance for testing, --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Edit: version 5 beta 3 can be found attached to the first post. The only change is a bugfix addressing the issue that the legend wouldn't show when adding the first annotation of any type to a photo. --- |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
Version 4.5 and 5 beta 3 can be found attached to the first post. Both address one bug:
Regards, --- |
||||||
therat
Joined: 2009-10-08
Posts: 18 |
![]() |
|||||
Hello Uli, Your latest fix solved my problem. Now annotation works To have better error reporting I think you should research a option introduced earlier from the developers of the gallery framework. The logs I send you are generated in <galery root>/var/log/<date>.php To enable this function I think you should create a file named <? But I might be wrong, I did that some time ago and don't remember very well ... |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
therat wrote:
Hello Uli, Great! Glad to hear. therat wrote:
To have better error reporting I think you should research a option introduced earlier from the developers of the gallery framework. The logs I send you are generated in <galery root>/var/log/<date>.php Yeah it's not that unfortunately. If I switch on full error reporting kohana just shuts down with weird errors. I did a bit of research and it seems that it's server configuration that is causing this. But thanks for the heads up on this one. Regards, --- |
||||||
mamouneyya
Joined: 2009-11-02
Posts: 337 |
![]() |
|||||
Looks like I am a little picky. I am really getting annoyed that there is no space between the resized photo and the navigation buttons anymore. It seems your plugin replaces the resized photo div to disable the full screen click. There was padding of 2.2em on top/bottom of the resized photo. Also, for some reason, sometimes the close button appears not centered (*some*times, with *some* annotation!): Thanks! |
||||||
hukoeth
Joined: 2009-03-20
Posts: 127 |
![]() |
|||||
mamouneyya wrote:
Looks like I am a little picky. Hi, Regards, --- |
||||||
clindsey
Joined: 2007-03-29
Posts: 15 |
![]() |
|||||
Hukoeth, is it possible to tag a person that isn't a Gallery user? Thanks for this great extension! |
||||||