Ansel 0.0
A darktable fork - bloat + design vision
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
map_locations.c File Reference
#include "common/geo.h"
#include "common/map_locations.h"
#include "common/darktable.h"
#include "common/debug.h"
#include "common/tags.h"
+ Include dependency graph for common/map_locations.c:

Functions

guint dt_map_location_new (const char *const name)
 
void dt_map_location_delete (const guint locid)
 
void dt_map_location_rename (const guint locid, const char *const name)
 
gboolean dt_map_location_name_exists (const char *const name)
 
int dt_map_location_get_images_count (const guint locid)
 
GList * dt_map_location_get_locations_by_path (const gchar *path, const gboolean remove_root)
 
GList * dt_map_location_get_locations_on_map (const dt_map_box_t *const bbox)
 
void dt_map_location_get_polygons (dt_location_draw_t *ld)
 
void dt_map_location_free_polygons (dt_location_draw_t *ld)
 
static gboolean _is_point_in_polygon (const dt_geo_map_display_point_t *pt, const gint plg_pts, const dt_geo_map_display_point_t *plp)
 
static void _free_result_item (dt_map_location_t *t, gpointer unused)
 
void dt_map_location_free_result (GList **result)
 
static gint _sort_by_path (gconstpointer a, gconstpointer b)
 
GList * dt_map_location_sort (GList *tags)
 
dt_map_location_data_tdt_map_location_get_data (const guint locid)
 
void dt_map_location_set_data (const guint locid, const dt_map_location_data_t *g)
 
GList * dt_map_location_find_locations (const int32_t imgid)
 
GList * _map_location_find_images (dt_location_draw_t *ld)
 
void dt_map_location_update_locations (const int32_t imgid, const GList *tags)
 
gboolean dt_map_location_update_images (dt_location_draw_t *ld)
 
const char * dt_map_location_data_tag_root ()
 
gboolean dt_map_location_included (const float lon, const float lat, dt_map_location_data_t *g)
 
GList * dt_map_location_convert_polygons (void *polygons, dt_map_box_t *bbox, int *nb_pts)
 

Variables

const char * location_tag = "darktable|locations"
 
const char * location_tag_prefix = "darktable|locations|"
 

Function Documentation

◆ _free_result_item()

static void _free_result_item ( dt_map_location_t t,
gpointer  unused 
)
static

◆ _is_point_in_polygon()

static gboolean _is_point_in_polygon ( const dt_geo_map_display_point_t pt,
const gint  plg_pts,
const dt_geo_map_display_point_t plp 
)
static

◆ _map_location_find_images()

◆ _sort_by_path()

static gint _sort_by_path ( gconstpointer  a,
gconstpointer  b 
)
static

References dt_map_location_t::tag.

Referenced by dt_map_location_sort().

◆ dt_map_location_convert_polygons()

GList * dt_map_location_convert_polygons ( void polygons,
dt_map_box_t bbox,
int *  nb_pts 
)

◆ dt_map_location_data_tag_root()

const char * dt_map_location_data_tag_root ( )

References location_tag.

Referenced by get_query_string(), and tree_view().

◆ dt_map_location_delete()

◆ dt_map_location_find_locations()

◆ dt_map_location_free_polygons()

◆ dt_map_location_free_result()

void dt_map_location_free_result ( GList **  result)

◆ dt_map_location_get_data()

◆ dt_map_location_get_images_count()

int dt_map_location_get_images_count ( const guint  locid)

◆ dt_map_location_get_locations_by_path()

◆ dt_map_location_get_locations_on_map()

◆ dt_map_location_get_polygons()

◆ dt_map_location_included()

gboolean dt_map_location_included ( const float  lon,
const float  lat,
dt_map_location_data_t g 
)

◆ dt_map_location_name_exists()

gboolean dt_map_location_name_exists ( const char *const  name)

◆ dt_map_location_new()

guint dt_map_location_new ( const char *const  name)

References dt_tag_new(), location_tag_prefix, and name.

Referenced by _name_editing_done().

◆ dt_map_location_rename()

void dt_map_location_rename ( const guint  locid,
const char *const  name 
)

◆ dt_map_location_set_data()

◆ dt_map_location_sort()

GList * dt_map_location_sort ( GList *  tags)

References _sort_by_path().

◆ dt_map_location_update_images()

◆ dt_map_location_update_locations()

void dt_map_location_update_locations ( const int32_t  imgid,
const GList *  tags 
)

Variable Documentation

◆ location_tag

const char* location_tag = "darktable|locations"

◆ location_tag_prefix