Introduction
Introduction Statistics Contact Development Disclaimer Help
tInclude factor for linear exposure scaling - filmtools - various tools for pho…
git clone git://src.adamsgaard.dk/filmtools
Log
Files
Refs
---
commit 08c5774bdd4f60189f2f49e63b713e68758cef53
parent fdf4f540757312f4e76e5eddbd95f5c2cb9e2691
Author: Anders Damsgaard <[email protected]>
Date: Thu, 16 Jul 2020 22:38:29 +0200
Include factor for linear exposure scaling
Diffstat:
M reciprocity.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/reciprocity.c b/reciprocity.c
t@@ -46,7 +46,7 @@ usage()
int
main(int argc, char **argv)
{
- double exponent;
+ double factor, exponent;
int i, hour, min, sec, sec_equiv;
argv0 = *argv;
t@@ -65,6 +65,7 @@ main(int argc, char **argv)
if (i == LENGTH(films))
errx(3, "unknown film type");
if (strncasecmp(argv[1], films[i].name, 10) == 0) {
+ factor = films[i].factor;
exponent = films[i].exponent;
break;
}
t@@ -73,7 +74,7 @@ main(int argc, char **argv)
if (sscanf(argv[2], "%d:%d", &min, &sec) != 2)
errx(2, "could not parse time in MM:SS format");
- sec_equiv = pow(min * 60 + sec, exponent);
+ sec_equiv = factor * pow(min * 60 + sec, exponent);
sec = (int)(sec_equiv) % 60;
if ((min = (int)(sec_equiv / 60.0)) >= 60) {
hour = (int)(min/60.0);
You are viewing proxied material from mx1.adamsgaard.dk. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.