diff options
| -rw-r--r-- | DEPENDENCIES | 5 | ||||
| -rw-r--r-- | Makefile | 1 | ||||
| -rw-r--r-- | README | 23 | ||||
| -rw-r--r-- | calibrator.c | 46 | ||||
| -rw-r--r-- | config.mk | 4 | ||||
| -rw-r--r-- | crt-calibrator.1 | 36 |
6 files changed, 48 insertions, 67 deletions
diff --git a/DEPENDENCIES b/DEPENDENCIES index 07f8c1c..c9ee6a8 100644 --- a/DEPENDENCIES +++ b/DEPENDENCIES @@ -4,18 +4,15 @@ RUNTIME DEPENDENCIES: libdrm linux - BUILD DEPENDENCIES: libc libdrm linux - gcc + c99 make - INSTALL DEPENDENCIES: make coreutils - @@ -12,7 +12,6 @@ OBJ =\ HDR = common.h - all: crt-calibrator $(OBJ): $(HDR) @@ -9,7 +9,7 @@ DESCRIPTION calibrating your CRT monitors. When done, the program will print gamma-ramp information that is useful when setting the calibrations automatically. If FILE is specified, this - information is stored to that the file named FILE. + information is stored in the file named FILE. The program cannot be run from inside X, it is required that it is run from the Linux VT, otherwise known as the TTY. @@ -22,18 +22,17 @@ NOTES RATIONALE Few users have calibration hardware, and CRT monitors can - be sufficiently calibrated manually without them. However, - before crt-calibrator the best way to calibrator CRT monitors - was to have specialised test images, with colour bars and - samples. But this requires expertise, the common user will - know how to contruct these images or the best procedure for + be sufficiently calibrated manually without it. However, + before crt-calibrator the best way to calibrate CRT monitors + was to use specialised test images, with colour bars and + samples. But this requires expertise; the common user will not + know how to construct these images or the best procedure for applying the corrections. And it is tedious if you do not - find any interactive tool for change changing the settings. - The alternative why was to use test pictures that relied on - you deciding what looked most realistic rather than the - image itself telling you. But that's not all, to my knowledge, - this is actually the first program that runs outside a - display server. + find any interactive tool for changing the settings. + The alternative was to use test pictures that relied on you + deciding what looked most realistic rather than the image + itself telling you. But that is not all: to my knowledge, + this is the first program that runs outside a display server. SEE ALSO analyse-gamma(1), blueshift(1) diff --git a/calibrator.c b/calibrator.c index 9456f96..70627ed 100644 --- a/calibrator.c +++ b/calibrator.c @@ -78,7 +78,7 @@ draw_digit(framebuffer_t *restrict fb, int colour, uint32_t x, uint32_t y) * * @param crtc The CRT controller information * @param colour The intensity of the least intense colour in the seven segment display - * @param value The valud of the digit to display + * @param value The value of the digit to display */ static void gamma_digit(drm_crtc_t *restrict crtc, int colour, size_t value) @@ -139,7 +139,7 @@ draw_id(void) /** - * Draw squares used as reference when tweeking the gamma correction + * Draw squares used as reference when tweaking the gamma correction */ static void draw_gamma(void) @@ -194,8 +194,8 @@ draw_convergence(void) if (y == fb->height) y = fb->height - 1; for (x = 0; x <= fb->width; x += 16) { - if (x == fb->height) - x = fb->height - 1; + if (x == fb->width) + x = fb->width - 1; fb_draw_pixel(fb, white, x, y); } } @@ -359,7 +359,7 @@ main(int argc, char *argv[]) printf("applies filters to your monitors' colours\n"); printf("and remove any existing filters.\n"); printf("In doubt, you probably do not have any.\n"); - printf("Do not try to calibrate CRT monitors will\n"); + printf("Do not try to calibrate CRT monitors while\n"); printf("they are cold.\n"); printf("\n"); printf("You will be presented with an image on each\n"); @@ -369,7 +369,7 @@ main(int argc, char *argv[]) printf("brightness of bright colours, and the\n"); printf("brightness adjusts the brightness of dim\n"); printf("colours. All rectangles are of equals size\n"); - printf("and they should be distrint from eachother.\n"); + printf("and they should be distinct from each other.\n"); printf("There should only be a slight difference\n"); printf("between the two darkest colours for each\n"); printf("colour. The grey colour does not need to\n"); @@ -377,12 +377,12 @@ main(int argc, char *argv[]) printf("The brightness should be as high as\n"); printf("possible without the first square being\n"); printf("any other colour than black or the two first\n"); - printf("square being too distinct from eachother. The\n"); + printf("square being too distinct from each other. The\n"); printf("contrast should be as high as possible without\n"); printf("causing distortion.\n"); printf("\n"); printf("Press ENTER to continue, and ENTER again when\n"); - printf("your are done.\n"); + printf("you are done.\n"); fflush(stdout); while (getchar() != '\n'); @@ -395,14 +395,14 @@ main(int argc, char *argv[]) printf("\033[H\033[2J"); printf("An index will be displayed on each monitor.\n"); - printf("It behoves you to memorise them. They will\n"); - printf("be used in the output when descibing the\n"); + printf("It is advisable to memorise them. They will\n"); + printf("be used in the output when describing the\n"); printf("calibrations, and is the index of the monitors\n"); printf("that are used when changing monitor to\n"); printf("calibrate.\n"); printf("\n"); printf("Press ENTER to continue, and ENTER again when\n"); - printf("your are done.\n"); + printf("you are done.\n"); fflush(stdout); while (getchar() != '\n'); @@ -420,7 +420,7 @@ main(int argc, char *argv[]) printf("\033[H\033[2J"); printf("You will not be given the opportunity to.\n"); printf("calibrate your monitors' brightness and\n"); - printf("contrast using software incase your monitors\n"); + printf("contrast using software in case your monitors\n"); printf("could not be sufficiently calibrated using\n"); printf("hardware.\n"); printf("\n"); @@ -430,7 +430,7 @@ main(int argc, char *argv[]) printf("<right> switches to the next monitor (one\n"); printf("higher in index.)\n"); printf("<Up> and <down> is used to increase and\n"); - printf("descrease the settings. respectively.\n"); + printf("decrease the settings, respectively.\n"); printf("<Shift+b> is used to switch to changing the.\n"); printf("monitor's brightness and <shift+c> switches\n"); printf("to contrast.\n"); @@ -440,7 +440,7 @@ main(int argc, char *argv[]) printf("is used to switch to change all channels.\n"); printf("\n"); printf("Press ENTER to continue, and ENTER again when\n"); - printf("your are done.\n"); + printf("you are done.\n"); fflush(stdout); while (getchar() != '\n'); @@ -494,9 +494,9 @@ main(int argc, char *argv[]) printf("to calibrate the gamma correction. There will\n"); printf("be four stacks: grey, red, green and blue.\n"); printf("Each stack has three squares: the upper square\n"); - printf("shows the characterics of how the middle square\n"); + printf("shows the characteristics of how the middle square\n"); printf("will look if the gamma is too high, and the\n"); - printf("lower shows how the middile will look if the\n"); + printf("lower shows how the middle will look if the\n"); printf("gamma is too low. The middle square should\n"); printf("look like it is one single colour if the gamma\n"); printf("correction is configured correctly. You may\n"); @@ -513,14 +513,14 @@ main(int argc, char *argv[]) printf("<right> switches to the next monitor (one\n"); printf("higher in index.)\n"); printf("<Up> and <down> is used to increase and\n"); - printf("descrease the gamma. respectively.\n"); + printf("decrease the gamma, respectively.\n"); printf("<r> is used to switch to changing the red.\n"); printf("channel, <g> switches to the green channel,\n"); printf("<b> switches to the blue channel, and <a>\n"); printf("is used to switch to change all channels.\n"); printf("\n"); printf("Press ENTER to continue, and ENTER again when\n"); - printf("your are done.\n"); + printf("you are done.\n"); fflush(stdout); while (getchar() != '\n'); @@ -568,12 +568,12 @@ main(int argc, char *argv[]) printf("control panel. White dots will be printed on the\n"); printf("screens, you should try to get as many as\n"); printf("possible of them to appear as pure white dots\n"); - printf("rather than dots splitted in the red, green and\n"); + printf("rather than dots split into red, green, and\n"); printf("blue dots. On most CRT monitors this is not\n"); printf("possible to get all corners perfect.\n"); printf("\n"); printf("Press ENTER to continue, and ENTER again when\n"); - printf("your are done.\n"); + printf("you are done.\n"); fflush(stdout); while (getchar() != '\n'); @@ -585,15 +585,15 @@ main(int argc, char *argv[]) while (getchar() != '\n'); printf("\033[H\033[2J"); - printf("The final step is to calbirate the monitors' moiré\n"); - printf("cancellation. This too is done on the using the\n"); + printf("The final step is to calibrate the monitors' moiré\n"); + printf("cancellation. This is also done using the\n"); printf("monitors' control panel.\n"); printf("\n"); printf("You can use <d> and the arrow keys to change the\n"); printf("dot-pattern on the screens.\n"); printf("\n"); printf("Press ENTER to continue, and ENTER again when\n"); - printf("your are done.\n"); + printf("you are done.\n"); fflush(stdout); while (getchar() != '\n'); @@ -1,8 +1,8 @@ PREFIX = /usr MANPREFIX = $(PREFIX)/share/man -CC = cc +CC = c99 CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -CFLAGS = -std=c99 -Wall $$(pkg-config --cflags libdrm) +CFLAGS = $$(pkg-config --cflags libdrm) LDFLAGS = -lm $$(pkg-config --libs libdrm) diff --git a/crt-calibrator.1 b/crt-calibrator.1 index 4bf79c9..3fd58d1 100644 --- a/crt-calibrator.1 +++ b/crt-calibrator.1 @@ -1,4 +1,4 @@ -.TH CRT-CALIBRATOR 1 CRT-CALIBRATOR +.TH CRT-CALIBRATOR 1 CRT-CALIBRATOR CRT-CALIBRATOR .SH NAME crt-calibrator - CRT monitor calibrator utility for Linux VT .SH SYNOPSIS @@ -11,7 +11,7 @@ CRT monitors. When done, the program will print gamma-ramp information that is useful when setting the calibrations automatically. If .B FILE -is specified, this information is stored to that the file named +is specified, this information is stored in the file named .BR FILE . .PP The program cannot be run from inside @@ -27,32 +27,18 @@ with nice gamma-curves, such as CRT monitors. Not monitors with sigmoid-curves. .SH RATIONALE Few users have calibration hardware, and CRT monitors can be -sufficiently calibrated manually without them. However, before +sufficiently calibrated manually without it. However, before .B crt-calibrator -the best way to calibrator CRT monitors was to have specialised +the best way to calibrate CRT monitors was to use specialised test images, with colour bars and samples. But this requires -expertise, the common user will know how to contruct these +expertise; the common user will not know how to construct these images or the best procedure for applying the corrections. And -it is tedious if you do not find any interactive tool for change -changing the settings. The alternative why was to use test -pictures that relied on you deciding what looked most realistic -rather than the image itself telling you. But that's not all, -to my knowledge, this is actually the first program that runs -outside a display server. +it is tedious if you do not find any interactive tool for +changing the settings. The alternative was to use test pictures +that relied on you deciding what looked most realistic rather +than the image itself telling you. But that is not all: to my +knowledge, this is the first program that runs outside a +display server. .SH "SEE ALSO" .BR analyse-gamma (1), .BR blueshift (1) -.SH AUTHORS -Principal author, Mattias Andrée. See the COPYING file for the full -list of authors. -.SH LICENSE -Copyright \(co 2014 Mattias Andrée -.br -License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. -.br -This is free software: you are free to change and redistribute it. -.br -There is NO WARRANTY, to the extent permitted by law. -.SH BUGS -Please report bugs to https://codeberg.org/maandree/crt-calibrator/issues -or to m@maandree.se |
