{"id":2112,"date":"2020-10-03T13:07:24","date_gmt":"2020-10-03T11:07:24","guid":{"rendered":"https:\/\/alax.info\/blog\/?p=2112"},"modified":"2020-10-03T13:07:24","modified_gmt":"2020-10-03T11:07:24","slug":"tiny-windows-box-doing-video-encoding","status":"publish","type":"post","link":"https:\/\/alax.info\/blog\/2112","title":{"rendered":"Tiny Windows box doing video encoding"},"content":{"rendered":"\n<p>The small box in the right bottom corner of the video is <a href=\"https:\/\/www.indiegogo.com\/projects\/chuwi-larkbox-world-s-smallest-4k-mini-pc\/x\/23968096#\/\">Chuwi LarkBox &#8220;World&#8217;s Smallest 4K Mini PC&#8221;<\/a>. <\/p>\n\n\n\n<p>With <a href=\"https:\/\/ark.intel.com\/content\/www\/us\/en\/ark\/products\/128989\/intel-celeron-j4105-processor-4m-cache-up-to-2-50-ghz.html\">Intel J4115 CPU<\/a> and Intel UHD Graphics 600 GPU it is running Windows 10 and is capable to render and encode video in real time.<\/p>\n\n\n\n<p>1600&#215;900@60 is a bit too heavy for it and VLC consumes pre-buffered content hitting underflow around 26th second of playback. Buggy VLC implementation for HLS client exhibiting playback artifacts (then eventually locks dead and\/or crashes completely; retroactive replay of produced content ensure the video stream itself is okay). <\/p>\n\n\n\n<figure class=\"wp-block-embed-youtube wp-block-embed is-type-video is-provider-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"Chuwi Larkbox encoding H.264 video and streaming HLS live\" width=\"1040\" height=\"585\" src=\"https:\/\/www.youtube.com\/embed\/v6BUDllKv4E?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>The small thing without excessive horsepower uncovered another bug too. <\/p>\n\n\n\n<p>The video content is prepared by Media Foundation pipeline with Intel\u00c2\u00ae Quick Sync Video H.264 Encoder MFT as GPU encoder. Once in a while encoded frame flash exhibiting lack of proper synchronization in the Intel&#8217;s MFT.<\/p>\n\n\n\n<figure class=\"wp-block-embed-youtube wp-block-embed is-type-video is-provider-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"Intel H.264 Video Encoder MFT synchronization bug\" width=\"1040\" height=\"585\" src=\"https:\/\/www.youtube.com\/embed\/cAYmPDlNbNM?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>A broken frame can look like this or otherwise and is supposedly caused by taking work item to encoding without giving a trouble to wait for scheduled GPU work completion. <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"450\" src=\"https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-800x450.png\" alt=\"\" class=\"wp-image-2113\" srcset=\"https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-800x450.png 800w, https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-320x180.png 320w, https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-768x432.png 768w, https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-1536x864.png 1536w, https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-600x338.png 600w, https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image-1040x585.png 1040w, https:\/\/alax.info\/blog\/wp-content\/uploads\/2020\/10\/image.png 1600w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/figure>\n\n\n\n<p>However it is not anything new, I wrote before about the same issue in another vendor implementation:<\/p>\n\n\n\n<figure class=\"wp-block-embed-wordpress wp-block-embed is-type-wp-embed is-provider-fooling-around\"><div class=\"wp-block-embed__wrapper\">\n<blockquote class=\"wp-embedded-content\" data-secret=\"yOZWZZus8p\"><a href=\"https:\/\/alax.info\/blog\/1886\">AMD H.264 Video Encoder MFT buggy processing of synchronization-enabled input textures<\/a><\/blockquote><iframe loading=\"lazy\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" title=\"&#8220;AMD H.264 Video Encoder MFT buggy processing of synchronization-enabled input textures&#8221; &#8212; Fooling Around\" src=\"https:\/\/alax.info\/blog\/1886\/embed#?secret=yOZWZZus8p\" data-secret=\"yOZWZZus8p\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe>\n<\/div><\/figure>\n\n\n\n<p>Adding a patch with D3D11 event query and waiting on it works the sync issue around (giving reasons to call it Intel&#8217;s bug in first place) and so the top posted video shows proper video stream.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The small box in the right bottom corner of the video is Chuwi LarkBox &#8220;World&#8217;s Smallest 4K Mini PC&#8221;. With Intel J4115 CPU and Intel UHD Graphics 600 GPU it is running Windows 10 and is capable to render and encode video in real time. 1600&#215;900@60 is a bit too heavy for it and VLC&hellip; <\/p>\n<p><a class=\"moretag\" href=\"https:\/\/alax.info\/blog\/2112\">Read the full article<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[63,609,379,578,188,424,486,610],"class_list":["post-2112","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-bug","tag-chuwi","tag-h-264","tag-hls","tag-intel","tag-media-foundation","tag-video","tag-vlc"],"_links":{"self":[{"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/posts\/2112","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/comments?post=2112"}],"version-history":[{"count":0,"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/posts\/2112\/revisions"}],"wp:attachment":[{"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/media?parent=2112"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/categories?post=2112"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/alax.info\/blog\/wp-json\/wp\/v2\/tags?post=2112"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}