summaryrefslogtreecommitdiff
path: root/src/include/util/media-thumb-db.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/util/media-thumb-db.h')
-rwxr-xr-xsrc/include/util/media-thumb-db.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/include/util/media-thumb-db.h b/src/include/util/media-thumb-db.h
index 10b08d2..bf89e94 100755
--- a/src/include/util/media-thumb-db.h
+++ b/src/include/util/media-thumb-db.h
@@ -19,7 +19,7 @@
*
*/
-
+#include <sqlite3.h>
#include "media-thumb-error.h"
#include "media-thumb-types.h"
#include "media-thumb-debug.h"
@@ -27,6 +27,15 @@
#ifndef _MEDIA_THUMB_DB_H_
#define _MEDIA_THUMB_DB_H_
+#define MEDIA_DATABASE_NAME "/opt/dbspace/.media.db"
+
+#define SELECT_PATH_FROM_UNEXTRACTED_THUMB_MEDIA "SELECT path from visual_media where thumbnail_path='' and valid=1;"
+#define SELECT_MEDIA_BY_PATH "SELECT thumbnail_path FROM visual_media WHERE path='%q';"
+#define UPDATE_THUMB_BY_PATH "UPDATE visual_media SET thumbnail_path = '%q' WHERE path='%q';"
+#define UPDATE_WH_BY_PATH "UPDATE image_meta SET width=%d,height=%d WHERE visual_uuid=(SELECT visual_uuid FROM visual_media WHERE path='%q');"
+
+sqlite3 *_media_thumb_db_get_handle();
+
int
_media_thumb_db_connect();