# HG changeset patch # User michael # Date 1114506399 0 # Node ID db0a5e0f4db5890460912dc2207bc492f338b283 # Parent dad78387544ae4f7d53950719e044c3ca1aa3207 Adds read probe to y4m, and changes the extension to .y4m patch by (Roine Gustafsson buf_size <= sizeof(Y4M_MAGIC)) + return 0; + if (strncmp(pd->buf, Y4M_MAGIC, sizeof(Y4M_MAGIC)-1)==0) + return AVPROBE_SCORE_MAX; + else + return 0; +} + AVInputFormat yuv4mpegpipe_iformat = { "yuv4mpegpipe", "YUV4MPEG pipe format", 0, - NULL, + yuv4_probe, yuv4_read_header, yuv4_read_packet, yuv4_read_close, - .extensions = "yuv4mpeg" + .extensions = "y4m" }; int yuv4mpeg_init(void)