]> rtime.felk.cvut.cz Git - frescor/demo.git/blobdiff - src/recorder/ffmpeg.c
Progress in O_DIRECT handling - not completed
[frescor/demo.git] / src / recorder / ffmpeg.c
index 7c01754e603f405d81f5ff3a6ad620af335aa065..f6252571bd8e1b5dcd76a569a6428e95fdff9619 100644 (file)
@@ -3505,10 +3505,22 @@ static void opt_output_file(const char *filename)
         }
 
         /* open the file */
-        if (url_fopen(&oc->pb, filename, URL_WRONLY) < 0) {
+        if (url_fopen(&oc->pb, filename, URL_WRONLY|URL_DIRECT) < 0) {
             fprintf(stderr, "Could not open '%s'\n", filename);
             av_exit(1);
         }
+
+       if (0) {
+               int i;
+               for (i=0; i<0x81; i++) {
+                       put_le32(oc->pb, i);
+                       if (i==0x42)
+                               put_flush_packet(oc->pb);
+               }
+               url_close_buf(oc->pb);
+               url_fclose(oc->pb);
+               exit(0);
+       }
     }
 
     memset(ap, 0, sizeof(*ap));