Ansel 0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
location_repository.h
Go to the documentation of this file.
1/*
2 This file is part of darktable,
3 Copyright (C) 2026 Aurélien PIERRE.
4
5 darktable is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
9
10 darktable is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with darktable. If not, see <http://www.gnu.org/licenses/>.
17*/
18
34#ifndef DT_DATABASE_LOCATION_REPOSITORY_H
35#define DT_DATABASE_LOCATION_REPOSITORY_H
36
38
39#include <glib.h>
40#include <stdint.h>
41
43
52{
53 int id;
54 int shape;
55 double lon;
56 double lat;
58
60void dt_location_repository_delete(const guint locid);
61
69
80
83
93gboolean dt_location_repository_get_polygon(const guint locid, void **blob, gint *bytes);
94
102
109GList *dt_location_repository_find_images_for_location(const guint locid, const int shape);
110
113
115
116#endif // DT_DATABASE_LOCATION_REPOSITORY_H
117
118// clang-format off
119// modelines: These editor modelines have been set for all relevant files by tools/update_modelines.py
120// vim: shiftwidth=2 expandtab tabstop=2 cindent
121// kate: tab-indents: off; indent-width 2; replace-tabs on; indent-mode cstyle; remove-trailing-spaces modified;
122// clang-format on
dt_map_box_t bbox
Definition location.c:4
GList * dt_location_repository_get_in_bbox(const dt_map_box_t *const bbox)
Locations whose extent overlaps bbox.
gboolean dt_location_repository_get_polygon(const guint locid, void **blob, gint *bytes)
The raw polygon blob of locid.
GList * dt_location_repository_find_images_for_location(const guint locid, const int shape)
Images whose coordinates fall inside location locid.
GList * dt_location_repository_get_image_locations(const int32_t imgid)
Location (tag) ids currently attached to imgid. GINT_TO_POINTER list.
void dt_location_repository_set_data(const guint locid, const dt_map_location_data_t *g)
Insert or replace the geometry of locid, polygon blob included.
void dt_location_repository_delete(const guint locid)
Drop the geometry row of locid. The tag itself is the tag repository's.
GList * dt_location_repository_find_locations_for_image(const int32_t imgid)
Locations whose shape contains imgid's coordinates.
dt_map_location_data_t * dt_location_repository_get_data(const guint locid, const char *name_prefix)
The geometry of locid, if it is a real location.
One row of a geo query: an id with the position that matched.