summaryrefslogtreecommitdiffstats
path: root/gtk/src/preset_to_string.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2008-09-11 16:12:31 +0000
committerjstebbins <[email protected]>2008-09-11 16:12:31 +0000
commit3542367d63f7fb4d443645e5a61ff60ae709382b (patch)
tree27d8b6b1add0421ffbadf290be7048d98e23ac15 /gtk/src/preset_to_string.c
parenta3a83842d26ad83b8e7a7b9dd876e8ce6af9dcb9 (diff)
LinGui: change deblock control to a slider to set deblock strength
also clean up some resource handling. delete several depricated files. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1689 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk/src/preset_to_string.c')
-rw-r--r--gtk/src/preset_to_string.c63
1 files changed, 0 insertions, 63 deletions
diff --git a/gtk/src/preset_to_string.c b/gtk/src/preset_to_string.c
deleted file mode 100644
index 4e82d4bd9..000000000
--- a/gtk/src/preset_to_string.c
+++ /dev/null
@@ -1,63 +0,0 @@
-#include <stdio.h>
-#include <string.h>
-#include <libgen.h>
-
-#define BUF_SIZE 4*65536
-
-void
-usage(char *cmd)
-{
- printf("%s\n", cmd);
- char *base = basename(cmd);
- fprintf(stderr, "Usage: %s infile [outfile]\n", base);
-}
-
-int
-main(int argc, char *argv[])
-{
- FILE *infile, *outfile;
- char in_buffer[BUF_SIZE];
- char out_buffer[2*BUF_SIZE];
-
- if (argc < 2 || argc > 3)
- {
- usage(argv[0]);
- return 1;
- }
- infile = fopen(argv[1], "r");
- if (argc < 3)
- {
- outfile = stdout;
- }
- else
- {
- outfile = fopen(argv[2], "w");
- }
- while (fgets(in_buffer, BUF_SIZE, infile) != NULL)
- {
- int ii, jj;
- int len;
- // Step on any CR LF at end of line
- len = strlen(in_buffer);
- for (jj = 0, ii = 0; ii < len; ii++)
- {
- if (in_buffer[ii] == '"')
- {
- out_buffer[jj++] = '\\';
- out_buffer[jj++] = in_buffer[ii];
- }
- else if (in_buffer[ii] == '\n' || in_buffer[ii] == '\r')
- { // Skip it
- }
- else
- {
- out_buffer[jj++] = in_buffer[ii];
- }
- }
- out_buffer[jj] = 0;
- fprintf(outfile, "\"%s\\n\"\n", out_buffer);
- }
- fclose(infile);
- fclose(outfile);
- return 0;
-}