Extract some full-size raw previews without LibRaw

Not all image/x-nikon-nef will work like this,
so don't claim their MIME type.
This commit is contained in:
2023-05-23 02:09:15 +02:00
parent 0f1c61ae33
commit bb4b895cb5
4 changed files with 719 additions and 404 deletions

View File

@@ -2,6 +2,22 @@
BEGIN {
FS = ", *"
print "// Generated by tiff-tables.awk. DO NOT MODIFY."
print ""
print "#ifndef TIFF_TABLES_CONSTANTS_ONLY"
print "#include <stddef.h>"
print "#include <stdint.h>"
print ""
print "struct tiff_value {"
print "\tconst char *name;"
print "\tuint16_t value;"
print "};"
print ""
print "struct tiff_entry {"
print "\tconst char *name;"
print "\tuint16_t tag;"
print "\tstruct tiff_value *values;"
print "};"
print "#endif"
}
{
@@ -55,8 +71,10 @@ function flushvalues() {
function flushsection() {
if (section) {
flushvalues()
print "};\n\n" allvalues "static struct tiff_entry " \
print "};\n\n" allvalues "#ifndef TIFF_TABLES_CONSTANTS_ONLY"
print "static struct tiff_entry " \
sectionsnakecase "_entries[] = {" fields "\n\t{}\n};"
print "#endif"
}
}