commit e44843ea23e925e60251d5d5f047d99a49f48ddb
parent e2d4362d36b93919282aceff463242cb696e2d2d
Author: Frederic Cambus <fred@statdns.com>
Date: Fri, 19 Oct 2018 13:36:32 +0200
Ansilove now generates only one output file when -r or -R options are used
Diffstat:
2 files changed, 5 insertions(+), 16 deletions(-)
diff --git a/ansilove.1 b/ansilove.1
@@ -136,9 +136,9 @@ Use Amiga Workbench palette
.It Fl o Ar file
Specify output filename/path
.It Fl r
-Creates additional Retina @2x output file
+Creates Retina @2x output file
.It Fl R Ar factor
-Creates additional Retina output file with custom scale factor
+Creates Retina output file with custom scale factor
.It Fl s
Show SAUCE record without generating output
.It Fl v
diff --git a/src/main.c b/src/main.c
@@ -101,8 +101,8 @@ static void synopsis(void) {
" transparent render with transparent background\n"
" workbench use Amiga Workbench palette\n"
" -o file specify output filename/path\n"
- " -r creates additional Retina @2x output file\n"
- " -R factor creates additional Retina output file with custom scale factor\n"
+ " -r creates Retina @2x output file\n"
+ " -R factor creates Retina output file with custom scale factor\n"
" -s show SAUCE record without generating output\n"
" -v show version information\n"
"\n");
@@ -125,7 +125,7 @@ int main(int argc, char *argv[]) {
int getoptFlag;
char *input = NULL, *output = NULL;
- char *fileName = NULL, *retina = NULL;
+ char *fileName = NULL;
char *font = NULL;
static struct ansilove_ctx ctx;
@@ -252,13 +252,6 @@ int main(int argc, char *argv[]) {
fileName = output;
}
- if (options.retinaScaleFactor) {
- if (asprintf(&retina, "%s@%ix.png", fileName, options.retinaScaleFactor) == -1) {
- fprintf(stderr, "Memory allocation error.\n\n");
- return EXIT_FAILURE;
- }
- }
-
// default to 80x25 font if font option is not specified
if (!font) {
font = "80x25";
@@ -268,10 +261,6 @@ int main(int argc, char *argv[]) {
fprintf(stderr, "\nInput File: %s\n", input);
fprintf(stderr, "Output File: %s\n", fileName);
- if (options.retinaScaleFactor) {
- fprintf(stderr, "Retina Output File: %s\n", retina);
- }
-
// get file extension
char *fext = strrchr(input, '.');
fext = fext ? strtolower(strdup(fext)) : "";