This forum has been archived. All content is frozen. Please use KDE Discuss instead.

searching for image by metadata

Tags: None
(comma "," separated)
koffeinfriedhof
Registered Member
Posts
608
Karma
4
OS

Re: searching for image by metadata

Sat Apr 04, 2020 10:25 pm
What I found out so far is, how the query is working. Examples taken from https://github.com/KDE/baloo/blob/master/src/lib/query.h
query.h wrote:"Fire" -> Looks for all files which contain the word "Fire"
"Fire OR water" -> Looks for files which contain either "Fire" or "Water". The capitalization of the words doesn't matter as that will be ignored internally. However, OR and AND have to be in upper case.

"artist:Coldplay" -> Look for any files with the artist "Coldplay"

"artist:(Coldplay OR Maroon5) power" -> Look for files with the artist Coldplay or Maroon5 and the word "power"
"artist:'Noah and the Whale'" -> Look for files with the artist "Noah and the Whale"
"type:Audio title:Fix" -> Look for Audio files which contains the title "Fix" in its title.

The Query Parser recognizes a large number of properties. These property names can be looked up in KFileMetaData::Property::Property. The type of the file can mentioned with the property 'type' or 'kind'.


How images are handled exactly is left for another day. I want to figure out how to find these images with only parts of the comments.
tc
Registered Member
Posts
9
Karma
0

Re: searching for image by metadata

Sat Apr 11, 2020 7:21 pm
thank you for sticking with it - I had a try at finding the relevant code in github, but got rather lost

I also took a quick look at the code in recoll out of curiosity - the documentation made it very quick for me to find the code for extracting the data from images.

At the moment, I have stopped working on the indexing and am actually adding comments to my recent photos. I do intend to return to looking at baloo ...
koffeinfriedhof
Registered Member
Posts
608
Karma
4
OS

Re: searching for image by metadata

Sun Apr 12, 2020 11:23 am
Well, I was lost too in baloo-code because of all these abstractions. I do now know a little but about how the xattr-stuff is handled, but I am to blind seeing the way the search-engine reads this. So, I have to wait until I learn to better read code and I have a good example :)


Bookmarks



Who is online

Registered users: abc72656, Bing [Bot], daret, Google [Bot], Sogou [Bot], Yahoo [Bot]