
Recherche avancée
Médias (1)
-
SPIP - plugins - embed code - Exemple
2 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
Autres articles (43)
-
Submit bugs and patches
13 avril 2011Unfortunately a software is never perfect.
If you think you have found a bug, report it using our ticket system. Please to help us to fix it by providing the following information : the browser you are using, including the exact version as precise an explanation as possible of the problem if possible, the steps taken resulting in the problem a link to the site / page in question
If you think you have solved the bug, fill in a ticket and attach to it a corrective patch.
You may also (...) -
Support audio et vidéo HTML5
10 avril 2011MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...) -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...)
Sur d’autres sites (6799)
-
H.264 muxing to MP4 from CCTV (HW) encoder using ffmpeg library in C / C++, how to fetch AVCodecContext::extradata
26 mai 2016, par DomI am trying to mux a video to mp4 file from packets received via SDK API of CCTV camera. The stream from CCTV seems to consist of packets of h264 I and P-frames only (no B-frames).
The problem is, that the file is not playable in Daum PotPlayer when I leave the AVCodecContext::extradata empty, however, I can play the file in VLC. If I feed the extra data (probably not correctly - I just copy the first 50 bytes from the packet received from the HW encoder), the file is playable in PotPlayer, but not in VLC.
I do not know, how to prepare the extradata properly.
The code below shows the muxing.
void WriteVideo()
{
AVFormatContext* formatContext = nullptr;
AVStream* stream = nullptr;
int ret = 0;
ret = avformat_alloc_output_context2(&formatContext, nullptr, "mp4", OUTPUT_V_FILE_NAME);
if (ret < 0)
{
fprintf(stderr, "Error occurred when allocating output context: %d\n", ret);
return;
}
stream = avformat_new_stream(formatContext, nullptr);
if (!stream)
{
avformat_free_context(formatContext);
formatContext = nullptr;
fprintf(stderr, "Error occurred creating new stream");
return;
}
stream->codec->codec_tag = 0;
if (formatContext->oformat->flags & AVFMT_GLOBALHEADER)
{
stream->codec->flags |= CODEC_FLAG_GLOBAL_HEADER;
}
stream->codec->codec_type = AVMEDIA_TYPE_VIDEO;
stream->codec->codec_id = AV_CODEC_ID_H264;
stream->codec->pix_fmt = AV_PIX_FMT_YUV420P;
stream->codec->bit_rate = 4096000; // 8192000; // 4096000; // 384000;
stream->codec->width = 1920; // 352
stream->codec->height = 1080; // 288
stream->codec->gop_size = 50;
AVRational tb;
tb.num = 1;
tb.den = 25;
stream->codec->time_base = tb;
//stream->codec->field_order = AVFieldOrder::AV_FIELD_UNKNOWN;
//stream->codec->color_primaries = AVColorPrimaries::AVCOL_PRI_BT470BG;
//stream->codec->color_trc = AVColorTransferCharacteristic::AVCOL_TRC_GAMMA22;
//stream->codec->colorspace = AVColorSpace::AVCOL_SPC_BT470BG;
//stream->codec->chroma_sample_location = AVChromaLocation::AVCHROMA_LOC_CENTER;
AVRational aratio;
aratio.num = 1;
aratio.den = 1;
stream->codec->sample_aspect_ratio = aratio;
// stream->codec->delay = 0;
// stream->codec->color_range = AVColorRange::AVCOL_RANGE_MPEG;
av_dump_format(formatContext, 0, formatContext->filename, 1);
if (!(formatContext->oformat->flags & AVFMT_NOFILE))
{
if (avio_open(&formatContext->pb, formatContext->filename, AVIO_FLAG_WRITE) < 0)
{
avformat_free_context(formatContext);
formatContext = nullptr;
fprintf(stderr, "Error occurred when opening output file.");
return;
}
}
avformat_write_header(formatContext, nullptr);
int frameIdx = 0;
int pts = 0;
int dts = 0;
int pkt_pos = 0;
int size = static_cast<int>(tmpRawFrameBuffer.size());
AVPacket pkt = { 0 };
av_init_packet(&pkt);
while (frameIdx < size)
{
pkt.data = tmpRawFrameBuffer[frameIdx];
pkt.size = tmpRawFrameSizes[frameIdx];
// debug purphose start
FILE* f;
char filename[MAX_PATH];
sprintf_s(filename, MAX_PATH, OUTPUT_PACKET_FILE_PATTERN_NAME, frameIdx);
auto err = fopen_s(&f, filename, "wb");
if (err != 0)
{
fprintf(stderr, "Could not open %s\n", OUTPUT_V_FILE_NAME);
exit(1);
}
fflush(stdout);
fwrite(pkt.data, 1, pkt.size, f);
fclose(f);
// debug purphose end
if (tmpRawFrameTypes[frameIdx] == VIDEO_I_FRAME)
{
pkt.flags |= AV_PKT_FLAG_KEY;
stream->codec->extradata_size = 50;
stream->codec->extradata = (uint8_t*)av_malloc(stream->codec->extradata_size);
memcpy(stream->codec->extradata, pkt.data, stream->codec->extradata_size);
}
pkt.pts = pts++;
pkt.dts = dts++;
/* rescale output packet timestamp values from codec to stream timebase */
// av_packet_rescale_ts(&pkt, stream->codec->time_base, stream->time_base);
pkt.pts = av_rescale_q(pkt.pts, stream->codec->time_base, stream->time_base);
pkt.dts = av_rescale_q(pkt.dts, stream->codec->time_base, stream->time_base);
pkt.duration = 512; // should be calculated (derived from FPS 25, and 12800)
pkt.pos = -1;
pkt.stream_index = stream->index;
auto ret = av_write_frame(formatContext, &pkt);
if (ret < 0)
{
fprintf(stderr, "Error while writing video frame: %d\n", ret);
break;
}
av_packet_unref(&pkt);
++frameIdx;
}
if (formatContext)
{
av_write_trailer(formatContext);
if (!(formatContext->oformat->flags & AVFMT_NOFILE)) avio_close(formatContext->pb); // close the output file
avformat_free_context(formatContext);
formatContext = nullptr;
}
}
</int>It seems, the packet from camera (buffered in tmpRawFrameBuffer vector) contains some headers, but I am not able to parse them, I do not understand the meaning of the header.
The first bytes of the I-frame packet looks like the dump bellow :
00 00 01 FC 02 19 F0 87 A0 23 73 41 B6 C0 01 00
00 00 00 01 67 4D 00 2A 95 A8 1E 00 89 F9 61 00
00 03 00 01 00 00 03 00 32 84 00 00 00 01 68 EE
3C 80 00 00 00 01 06 E5 01 19 80 00 00 00 01 65
B8 00 00 08 C7 B0 23 FF F7 80 EE FE 63 B6 FB F5
...The first bytes of the first P-frame :
00 00 01 FD E5 24 00 00 00 00 00 01 61 E0 22 27
FF D6 B0 D7 A4 2B 71 6B 19 C5 87 CA BB 8B BF 60
14 59 B4 00 CC BC 0F C0 9E FD 84 B5 FB C4 83 DB
5A 8B 80 FC EC D6 33 6D DE 10 96 6F 31 41 86 5C
D4 22 F9 33 48 5B CE 77 38 17 0C D6 DD C7 6C E8
...first bytes of next P-frame :
00 00 01 FD 5E 2F 00 00 00 00 00 01 61 E0 42 2F
FF E7 06 DD 3C 66 26 15 94 93 7A F1 30 8A 6D B8
AD DD 6B 0F 38 89 1D 1B 5C AC 44 6A D7 D1 21 3B
E2 29 F8 14 BB 98 1C 06 4D B6 10 BB DB B9 CA 4F
0B ED B1 A9 06 78 8C EC 06 6D 9F 4F 79 0C 35 5B
......
begining of next I-frame :
00 00 01 FC 02 19 F0 87 A2 23 73 41 75 89 01 00
00 00 00 01 67 4D 00 2A 95 A8 1E 00 89 F9 61 00
00 03 00 01 00 00 03 00 32 84 00 00 00 01 68 EE
3C 80 00 00 00 01 06 E5 01 1B 80 00 00 00 01 65
B8 00 00 0F 07 F0 7F F6 6C 69 43 0F F0 28 DF 97
...Does anybody know, how to fill correctly the extradata ? I just made a copy of first 50 bytes, but it seems, this is not correct.
Probably the headers are (AUD)(SPS)(PPS)(I-Slice)(PPS)(P-Slice)(PPS)(P-Slice) ... (AUD)(SPS)(PPS)(I-Slice) (http://stackoverflow.com/a/20686267/1699328), however, I do not know, how to extract data for the
stream->codec->extradata
I tried to get some inspiration in this post H.264 muxed to MP4 using libavformat not playing back, but I am not able to figure out what are values of spsFrameLen, ppsFrameLen and spsFrame.
The result of the muxer (first and last bytes of the mp4 file) :
00 00 00 20 66 74 79 70 69 73 6F 6D 00 00 02 00
69 73 6F 6D 69 73 6F 32 61 76 63 31 6D 70 34 31
00 00 00 08 66 72 65 65 00 26 2E 6D 6D 64 61 74
00 00 00 0D FC 02 19 F0 87 A0 23 73 41 B6 C0 01
00 00 00 00 16 67 4D 00 2A 95 A8 1E 00 89 F9 61
00 00 03 00 01 00 00 03 00 32 84 00 00 00 04 68
EE 3C 80 00 00 00 05 06 E5 01 19 80 00 01 C0 87
65 B8 00 00 08 C7 B0 23 FF F7 80 EE FE 63 B6 FB
F5 97 A8 6B 48 39 61 99 FD 99 27 41 F2 78 54 EE
D1 38 8E E8 18 DD 05 E4 BA F4 EB 69 CF 91 5C 34
...
...
...
95 B8 D8 D4 C3 AF A1 BA AC 28 F0 D4 D4 7C 48 9A
0C A6 8C 4C 98 00 00 05 1E 6D 6F 6F 76 00 00 00
6C 6D 76 68 64 00 00 00 00 00 00 00 00 00 00 00
00 00 00 03 E8 00 00 13 B0 00 01 00 00 01 00 00
00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00
00 00 00 00 00 00 00 00 00 40 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 02 00 00 04 48 74 72 61
6B 00 00 00 5C 74 6B 68 64 00 00 00 03 00 00 00
00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 13
B0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00
00 40 00 00 00 07 80 00 00 04 38 00 00 00 00 00
24 65 64 74 73 00 00 00 1C 65 6C 73 74 00 00 00
00 00 00 00 01 00 00 13 B0 00 00 00 00 00 01 00
00 00 00 03 C0 6D 64 69 61 00 00 00 20 6D 64 68
64 00 00 00 00 00 00 00 00 00 00 00 00 00 00 32
00 00 00 FC 00 55 C4 00 00 00 00 00 2D 68 64 6C
72 00 00 00 00 00 00 00 00 76 69 64 65 00 00 00
00 00 00 00 00 00 00 00 00 56 69 64 65 6F 48 61
6E 64 6C 65 72 00 00 00 03 6B 6D 69 6E 66 00 00
00 14 76 6D 68 64 00 00 00 01 00 00 00 00 00 00
00 00 00 00 00 24 64 69 6E 66 00 00 00 1C 64 72
65 66 00 00 00 00 00 00 00 01 00 00 00 0C 75 72
6C 20 00 00 00 01 00 00 03 2B 73 74 62 6C 00 00
00 93 73 74 73 64 00 00 00 00 00 00 00 01 00 00
00 83 61 76 63 31 00 00 00 00 00 00 00 01 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 07 80
04 38 00 48 00 00 00 48 00 00 00 00 00 00 00 01
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 18 FF FF 00 00 00 2D 61 76 63 43 01 4D 00 2A
FF E1 00 16 67 4D 00 2A 95 A8 1E 00 89 F9 61 00
00 03 00 01 00 00 03 00 32 84 01 00 04 68 EE 3C
80 00 00 00 18 73 74 74 73 00 00 00 00 00 00 00
01 00 00 00 7E 00 00 02 00 00 00 00 1C 73 74 73
73 00 00 00 00 00 00 00 03 00 00 00 01 00 00 00
33 00 00 00 65 00 00 00 34 73 74 73 63 00 00 00
00 00 00 00 03 00 00 00 01 00 00 00 3B 00 00 00
01 00 00 00 02 00 00 00 37 00 00 00 01 00 00 00
03 00 00 00 0C 00 00 00 01 00 00 02 0C 73 74 73
7A 00 00 00 00 00 00 00 00 00 00 00 7E 00 01 C0
C7 00 00 24 EE 00 00 2F 67 00 00 1D 83 00 00 2E
8F 00 00 30 B6 00 00 2F 44 00 00 2F 50 00 00 34
6B 00 00 30 BE 00 00 31 0C 00 00 31 E7 00 00 30
EA 00 00 31 4E 00 00 31 A8 00 00 32 21 00 00 31
E6 00 00 31 B5 00 00 31 14 00 00 31 AF 00 00 31
9D 00 00 33 60 00 00 32 11 00 00 32 4C 00 00 31
F0 00 00 32 91 00 00 43 43 00 00 44 29 00 00 44
EC 00 00 44 20 00 00 44 86 00 00 45 AD 00 00 47
47 00 00 46 9F 00 00 46 D9 00 00 47 BE 00 00 48
CD 00 00 3E 50 00 00 40 98 00 00 41 0E 00 00 40
43 00 00 41 07 00 00 41 BB 00 00 41 FF 00 00 30
5E 00 00 33 C7 00 00 34 B7 00 00 33 F1 00 00 33
0D 00 00 32 DB 00 01 89 86 00 00 3B E1 00 00 3C
55 00 00 3C 64 00 00 3C B7 00 00 3C FD 00 00 3E
54 00 00 3E C5 00 00 3E 1C 00 00 3E 94 00 00 3E
44 00 00 3E D7 00 00 3F CC 00 00 3E D6 00 00 40
00 00 00 40 4D 00 00 40 04 00 00 3F A9 00 00 40
82 00 00 41 0F 00 00 41 64 00 00 41 E5 00 00 42
1E 00 00 42 2C 00 00 42 80 00 00 42 4D 00 00 43
9F 00 00 43 DA 00 00 44 45 00 00 44 21 00 00 44
B7 00 00 45 22 00 00 45 E3 00 00 45 BF 00 00 46
18 00 00 47 4B 00 00 45 05 00 00 47 34 00 00 46
60 00 00 46 97 00 00 46 66 00 00 46 29 00 00 46
38 00 00 47 1D 00 00 47 42 00 00 47 18 00 00 47
13 00 00 46 52 00 00 47 48 00 00 46 F8 00 01 BE
E3 00 00 3F 56 00 00 3B 32 00 00 38 F8 00 00 37
56 00 00 36 2D 00 00 35 DA 00 00 34 6B 00 00 3E
BE 00 00 3E B5 00 00 3F 33 00 00 3F AC 00 00 3F
38 00 00 42 32 00 01 1B DC 00 01 80 50 00 01 14
06 00 00 C2 BB 00 00 96 12 00 00 6D EC 00 00 54
E6 00 00 3A AC 00 00 32 00 00 00 2F 0A 00 00 2D
F1 00 00 1B 7F 00 00 00 1C 73 74 63 6F 00 00 00
00 00 00 00 03 00 00 00 30 00 0F DD AB 00 1F 7D
9E 00 00 00 62 75 64 74 61 00 00 00 5A 6D 65 74
61 00 00 00 00 00 00 00 21 68 64 6C 72 00 00 00
00 00 00 00 00 6D 64 69 72 61 70 70 6C 00 00 00
00 00 00 00 00 00 00 00 00 2D 69 6C 73 74 00 00
00 25 A9 74 6F 6F 00 00 00 1D 64 61 74 61 00 00
00 01 00 00 00 00 4C 61 76 66 35 37 2E 32 33 2E
31 30 30Thanks a lot for any advices.
-
11 ways Piwik Analytics helps you to protect your visitors privacy
11 janvier 2017, par InnoCraft — CommunityAt Piwik and at InnoCraft, we think Privacy matters. From the beginning, Piwik has had a strong focus on privacy and ensures the privacy of your visitors and analytics data. As a result, Piwik has been recommended as a privacy-compliant analytics tool for example by the Independent Center for Privacy Protection in Germany (ULD) and by the Center for Data Privacy Protection in France (CNIL). In France, Piwik is the only web analytics tool that does not require Cookie Consent.
Here are some ways how you can ensure your users and visitors privacy by using Piwik.
1. You own the data
Whether you host Piwik on premise yourself, managed on premise by InnoCraft, or whether you use our Piwik cloud, when you use Piwik, YOU keep control of your data and nobody else. This also means you can decide where your data should be located physically.
2. Anonymized IP addresses
For better privacy by default, Piwik will not record the full IP address of your visitors because otherwise the browsing history could be easily tracked across several days and even across websites within the same Piwik server. Some countries even require to anonymize the IP address, considered Personally Identifiable Information (PII).
To change the IP anonymization settings go to “Administration > Privacy”. Optionally, you can use the full IP to still get for example accurate location data.
3. Delete old visitor logs
The visitor logs contain information all the collected raw data about every visitor and every action. You can configure Piwik to automatically delete logs from the database. When you delete old logs, only the real time and visitor log reports will no longer work for this old time period, all other aggregated reports will still work.
For privacy reasons, we highly recommend that you keep the detailed Piwik logs for only 3 to 6 months and delete older log data. This has one other nice side effect : it will free significant database space, which will, in turn, slightly increase performance !
4. Support Do Not Track preference
Do Not Track enables users to opt out of any tracking by websites they do not visit, including analytics services, advertising networks, and social platforms. By default, Piwik respects users preference and will not track visitors which have specified “I do not want to be tracked” in their web browsers. Get more information about DoNotTrack.
To make sure Do Not Track is respected, go to “Administration => Privacy”.
5. Include an Opt-Out Feature on your website or app
By embedding the Opt-Out feature in your website, you give your visitors the possibility to opt-out of the tracking. When you go to “Administration > Privacy”, you will be able to copy and paste an HTML Iframe code to embed the opt-out feature for example into your privacy policy page or in your ‘Legal’ page. Your users can then click on a link to opt-out.
On the Piwik Marketplace there are also some plugins available to customize the Opt-Out experience. For example AjaxOptOut and CustomOptOut.
6. Disable Live features
The Real-Time, Visitor Log and Visitor Profile features give you insights into the tracked raw data by showing you details about every visitor and every action they performed. To protect the privacy of your visitors you may decide to prevent access to such features by disabling the “Live” plugin in “Administration => Plugins”. This way only aggregated reports will be shown in your Piwik.
7. Disable fingerprinting across websites
By default, when one of your visitors visits several of your websites, Piwik will create a fingerprint for this user that will be different across the websites to increase the visitors’ privacy. You can make sure that this feature is disabled by going to “Administration => Config file” and verifying that the value of “enable_fingerprinting_across_websites” is set to zero.
8. Disable tracking cookies
Piwik uses cookies to store some information about visitors between visits. In some countries, the legislation requires websites to provide a way for users to opt-out of all tracking, in particular tracking cookies. You can disable cookies by adding one line in the Piwik Javascript code.
9. Custom development
Piwik is an open platform that lets you extend and customize the tracking, the reporting and the Piwik user interface to your needs and to protect your visitors’ privacy the way you want or need it. Learn more in the Piwik Developer Zone. You may also have a look at our Piwik Marketplace where you can find several free and premium features to extend your Piwik.
10. Transparency
By default, all information and all collected data in your Piwik server are protected and nobody can access it. However, Piwik allows you to optionally make your collected data public and you can export any Piwik report including the whole dashboard to embed it into your website. This way you can show your users exactly which information you track. When you decide to make reports public, we do our best to protect privacy and automatically hide any Personally Identifiable Information such as the Visitor Profile and we make sure to not show any Visitor IP address and the Visitor ID.
11. Privacy policy
When you use Piwik to track your visitors, we recommend to update your Privacy Policy to explain how Piwik is used and what data it gathers. We provide a Privacy Policy template for Piwik users that you can copy on your site.
Continuous privacy improvements
We are always interested in improving the privacy. If you miss any feature or have an idea on how to improve the privacy, please let us know.
More information about all the Piwik features
If you want to learn more about all the features in Piwik, have a look at our User Guides and FAQ entries.
-
ffmpeg "End mismatch 1" warning, jpeg2000 to avi
11 avril 2023, par jklebesTrying to convert a directory of jpeg2000 grayscale images to a video with ffmpeg, I get warnings


[0;36m[jpeg2000 @ 0x55d8fa1b68c0] [0m[0;33mEnd mismatch 1



(and lots of


Last message repeated <n> times
</n>


)


The command was


ffmpeg -y -r 10 -start_number 1 -i <path>/surface_30///img_000%01d.jp2 -vcodec msmpeg4 -vf scale=1920:-1 -q:v 8 <path>//surface_30///surface_30.avi
</path></path>


The output is


ffmpeg version 4.2.2 Copyright (c) 2000-2019 the FFmpeg developers
 built with gcc 7.3.0 (crosstool-NG 1.23.0.449-a04d0)
 configuration: --prefix=/home/jklebes001/miniconda3 --cc=/tmp/build/80754af9/ffmpeg_1587154242452/_build_env/bin/x86_64-conda_cos6-linux-gnu-cc --disable-doc --enable-avresample --enable-gmp --enable-hardcoded-tables --enable-libfreetype --enable-libvpx --enable-pthreads --enable-libopus --enable-postproc --enable-pic --enable-pthreads --enable-shared --enable-static --enable-version3 --enable-zlib --enable-libmp3lame --disable-nonfree --enable-gpl --enable-gnutls --disable-openssl --enable-libopenh264 --enable-libx264
 libavutil 56. 31.100 / 56. 31.100
 libavcodec 58. 54.100 / 58. 54.100
 libavformat 58. 29.100 / 58. 29.100
 libavdevice 58. 8.100 / 58. 8.100
 libavfilter 7. 57.100 / 7. 57.100
 libavresample 4. 0. 0 / 4. 0. 0
 libswscale 5. 5.100 / 5. 5.100
 libswresample 3. 5.100 / 3. 5.100
 libpostproc 55. 5.100 / 55. 5.100
[0;36m[jpeg2000 @ 0x55cb44144480] [0m[0;33mEnd mismatch 1

[0m Last message repeated 1 times
 Last message repeated 2 times
 Last message repeated 3 times



...


Last message repeated 73 times

Input #0, image2, from '<path>//surface_30///img_000%01d.jp2':

 Duration: 00:00:00.20, start: 0.000000, bitrate: N/A

 Stream #0:0: Video: jpeg2000, gray, 6737x4869, 25 tbr, 25 tbn, 25 tbc

Stream mapping:

 Stream #0:0 -> #0:0 (jpeg2000 (native) -> msmpeg4v3 (msmpeg4))

Press [q] to stop, [?] for help

[0;36m[jpeg2000 @ 0x55cb4418e200] [0m[0;33mEnd mismatch 1

[0m[0;36m[jpeg2000 @ 0x55cb441900c0] [0m[0;33mEnd mismatch 1
</path>


...


(about 600 lines of "end mismatch" and "last message repeated" cut)


...


[0m[0;36m[jpeg2000 @ 0x55cb4418e8c0] [0m[0;33mEnd mismatch 1

[0mOutput #0, avi, to '<path>/surface_30///surface_30.avi':

 Metadata:

 ISFT : Lavf58.29.100

 Stream #0:0: Video: msmpeg4v3 (msmpeg4) (MP43 / 0x3334504D), yuv420p, 1920x1388, q=2-31, 200 kb/s, 10 fps, 10 tbn, 10 tbc

 Metadata:

 encoder : Lavc58.54.100 msmpeg4

 Side data:

 cpb: bitrate max/min/avg: 0/0/200000 buffer size: 0 vbv_delay: -1

frame= 2 fps=0.8 q=8.0 size= 6kB time=00:00:00.20 bitrate= 227.1kbits/s speed=0.0844x 
frame= 5 fps=1.7 q=8.0 size= 6kB time=00:00:00.50 bitrate= 90.8kbits/s speed=0.172x 
frame= 5 fps=1.7 q=8.0 Lsize= 213kB time=00:00:00.50 bitrate=3494.7kbits/s speed=0.172x 
video:208kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 2.732246%
</path>


What is the meaning of characters like [0 ;33m here ?


I thought it might have something to do with bit depth and color format. Setting
-pix_fmt gray
had no effect, and indeed the format of the jp2 images is already detected as 8-bit gray.

The output .avi exists and seems fine.


The line was previously used on jpeg files and works fine on jpeg. With jpeg, the output has the line


Input #0, image2, from '<path>/surface_30///img_000%01d.jpeg':

 Duration: 00:00:00.16, start: 0.000000, bitrate: N/A

 Stream #0:0: Video: mjpeg (Baseline), gray(bt470bg/unknown/unknown), 6737x4869 [SAR 1:1 DAR 6737:4869], 25 tbr, 25 tbn, 25 tbc

Stream mapping:

 Stream #0:0 -> #0:0 (mjpeg (native) -> msmpeg4v3 (msmpeg4))

Press [q] to stop, [?] for help

Output #0, avi, to '<path>/surface_30///surface_30.avi':

 Metadata:

 ISFT : Lavf58.29.100

 Stream #0:0: Video: msmpeg4v3 (msmpeg4) (MP43 / 0x3334504D), yuv420p, 6737x4869 [SAR 1:1 DAR 6737:4869], q=2-31, 200 kb/s, 10 fps, 10 tbn, 10 tbc

 Metadata:

 encoder : Lavc58.54.100 msmpeg4

 Side data:

 cpb: bitrate max/min/avg: 0/0/200000 buffer size: 0 vbv_delay: -1

frame= 2 fps=0.0 q=8.0 size= 6662kB time=00:00:00.20 bitrate=272859.9kbits/s speed=0.334x 
frame= 3 fps=2.2 q=10.0 size= 10502kB time=00:00:00.30 bitrate=286764.2kbits/s speed=0.22x 
frame= 4 fps=1.9 q=12.3 size= 13574kB time=00:00:00.40 bitrate=277987.7kbits/s speed=0.19x 
frame= 4 fps=1.4 q=12.3 size= 13574kB time=00:00:00.40 bitrate=277987.7kbits/s speed=0.145x 
frame= 4 fps=1.4 q=12.3 Lsize= 13657kB time=00:00:00.40 bitrate=279702.3kbits/s speed=0.145x 
video:13652kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.041926%
</path></path>


detecting mjpeg format and similar, but more detailed format
gray(bt470bg/unknown/unknown), 6737x4869 [SAR 1:1 DAR 6737:4869].


What is the difference when switching input to jp2 ?