diff options
author | Mattias Andrée <maandree@kth.se> | 2021-03-05 00:43:38 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2021-03-05 00:43:38 +0100 |
commit | 0ce0d8d6e0c420ccafa79e0203b928c3559a4311 (patch) | |
tree | 88e8228a93691c28811a49898abf86a96dd9d613 /libgamma_internal_parse_edid.c | |
parent | Change license + change style + misc (diff) | |
download | libgamma-0ce0d8d6e0c420ccafa79e0203b928c3559a4311.tar.gz libgamma-0ce0d8d6e0c420ccafa79e0203b928c3559a4311.tar.bz2 libgamma-0ce0d8d6e0c420ccafa79e0203b928c3559a4311.tar.xz |
Split source files, merge public header files, eliminite use gpp, rewrite makefile
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r-- | libgamma_internal_parse_edid.c (renamed from src/lib/edid.c) | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/lib/edid.c b/libgamma_internal_parse_edid.c index fc7b498..aa1b87c 100644 --- a/src/lib/edid.c +++ b/libgamma_internal_parse_edid.c @@ -1,10 +1,5 @@ /* See LICENSE file for copyright and license details. */ -#include "edid.h" - -#include "libgamma-method.h" -#include "libgamma-error.h" - -#include <stdint.h> +#include "common.h" /* @@ -26,7 +21,7 @@ * @return Non-zero on error */ int -libgamma_parse_edid(libgamma_crtc_information_t *restrict this, int32_t fields) +libgamma_internal_parse_edid(libgamma_crtc_information_t *restrict this, int32_t fields) { #define __test_version(edid, major, minor_min, minor_max)\ ((edid)[18] == (major) && (minor_min) <= (edid)[19] && (edid)[19] <= (minor_max)) @@ -79,10 +74,9 @@ libgamma_parse_edid(libgamma_crtc_information_t *restrict this, int32_t fields) /* If not error has occurred, calculate and test the checksum. It is not considered an error that the gamma characteristics is left unspecified in the EDID. */ - if (!error) { + if (!error) for (i = 0; i < this->edid_length; i++) checksum += (int)this->edid[i]; - } /* The checksum should be zero. */ if (checksum & 255) { /* Store the error in all fields that require the EDID to be parsed, |