Lines Matching defs:file
61 unsigned int capture_sample(FILE *file, unsigned int card, unsigned int device,
73 FILE *file;
86 fprintf(stderr, "Usage: %s file.wav [-D card] [-d device] [-c channels] "
91 file = fopen(argv[1], "wb");
92 if (!file) {
93 fprintf(stderr, "Unable to create file '%s'\n", argv[1]);
163 fseek(file, sizeof(struct wav_header), SEEK_SET);
167 frames = capture_sample(file, card, device, header.num_channels,
175 fseek(file, 0, SEEK_SET);
176 fwrite(&header, sizeof(struct wav_header), 1, file);
178 fclose(file);
183 unsigned int capture_sample(FILE *file, unsigned int card, unsigned int device,
223 if (fwrite(buffer, 1, size, file) != size) {