aboutsummaryrefslogtreecommitdiff
path: root/src/Scraping/ImageScraping.h
diff options
context:
space:
mode:
authorfrosty <gabriel@bwaaa.monster>2026-03-17 13:51:12 -0400
committerfrosty <gabriel@bwaaa.monster>2026-03-17 13:51:12 -0400
commitc7b95d05715a45c7790aa8a7e4b0b61bac2e4208 (patch)
treeb0b511b4cc6610949cdde5a6a220724a31c617fd /src/Scraping/ImageScraping.h
parent8c6632502ff992e80051910451421c55894ed9d8 (diff)
downloadomnisearch-c7b95d05715a45c7790aa8a7e4b0b61bac2e4208.tar.gz
fix: refactored scraping components
Diffstat (limited to 'src/Scraping/ImageScraping.h')
-rw-r--r--src/Scraping/ImageScraping.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/Scraping/ImageScraping.h b/src/Scraping/ImageScraping.h
new file mode 100644
index 0000000..d244a63
--- /dev/null
+++ b/src/Scraping/ImageScraping.h
@@ -0,0 +1,18 @@
+#ifndef IMAGESCRAPING_H
+#define IMAGESCRAPING_H
+
+#include <curl/curl.h>
+#include <libxml/HTMLparser.h>
+
+typedef struct {
+ char *thumbnail_url;
+ char *title;
+ char *page_url;
+ char *full_url;
+} ImageResult;
+
+int scrape_images(const char *query, int page, ImageResult **out_results,
+ int *out_count);
+void free_image_results(ImageResult *results, int count);
+
+#endif