{"id":754,"date":"2018-07-26T18:45:55","date_gmt":"2018-07-26T16:45:55","guid":{"rendered":"http:\/\/pythonprogramming.altervista.org\/?p=754"},"modified":"2023-04-14T21:59:26","modified_gmt":"2023-04-14T19:59:26","slug":"tkinter-a-program-start-mp4-with-ffplay","status":"publish","type":"post","link":"https:\/\/pythonprogramming.altervista.org\/tkinter-a-program-start-mp4-with-ffplay\/","title":{"rendered":"Tkinter: start mp4 with ffplay"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">FFmpeg and ffplay<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">You will need the ffmpeg free software to use the app we will make with Python and tkinter. Here is a link to the site.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/www.ffmpeg.org\/\" rel=\"noopener noreferrer\"><img loading=\"lazy\" decoding=\"async\" width=\"1253\" height=\"424\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmpeg.png\" alt=\"https:\/\/www.ffmpeg.org\/\" class=\"wp-image-786\" srcset=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmpeg.png 1253w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmpeg-320x108.png 320w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmpeg-768x260.png 768w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmpeg-960x325.png 960w\" sizes=\"auto, (max-width: 1253px) 100vw, 1253px\" \/><\/a><figcaption>The link to download https:\/\/www.ffmpeg.org\/<\/figcaption><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Ffmpeg is free, as I said, and it has a lot of support and it is very powerful.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It has a lot of option and it has a command line interface that could be a little overwhelming at first (and also further) sight. There comes Python in help to make a little GUI, with tkinter, that allows us to use it easily and suitable for out needs- This time we will create a GUI to open and start mp4 files with ffplay, icluded in ffmpeg.<\/p>\n\n\n\n<figure class=\"wp-block-embed\"><div class=\"wp-block-embed__wrapper\">\nhttps:\/\/ffmpeg.org\/documentation.html\n<\/div><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/ffmpeg.org\/documentation.html\">Documentazione su ffmpeg<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to install ffmpeg amd ffplay<\/h2>\n\n\n<p><iframe loading=\"lazy\" title=\"ffmpeg and ffplay installation\" width=\"747\" height=\"560\" src=\"https:\/\/www.youtube.com\/embed\/BNBX40NIAaM?feature=oembed&amp;enablejsapi=1\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Go to ffmpeg.org install the windows version:<\/p>\n\n\n\n<ol class=\"wp-block-list\"><li>choose the windows version<\/li><li>download the zip file<\/li><li>unzip it<\/li><li>rename the unzipped file like &#8220;ffmpeg&#8221;<\/li><li>cut the file<\/li><li>copy it in the c: directory (for example)<\/li><li>go in to the bin subfolder (where there are ffplay.exe enad ffmpeg.exe)<\/li><li>copy the path to the bin folder<\/li><li>choose system<\/li><li>choose advaced option<\/li><li>choose environment variables<\/li><li>choose path<\/li><li>choose edit<\/li><li>choose new<\/li><li>paste the path<\/li><li>press ok<\/li><li>go into the cmd<\/li><li>type ffmpeg -version<\/li><li>if appears the number of the version (and other stuff) it&#8217;s ok<\/li><li>go on to the next paragraph<\/li><\/ol>\n\n\n<div class=\"wp-block-image wp-image-787\">\n<figure class=\"aligncenter\"><img loading=\"lazy\" decoding=\"async\" width=\"717\" height=\"404\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/002.png\" alt=\"ffmpeg download\" class=\"wp-image-787\" srcset=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/002.png 717w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/002-320x180.png 320w\" sizes=\"auto, (max-width: 717px) 100vw, 717px\" \/><figcaption>ffmpeg download<\/figcaption><\/figure>\n<\/div>\n\n<div class=\"wp-block-image wp-image-788\">\n<figure class=\"aligncenter\"><img loading=\"lazy\" decoding=\"async\" width=\"672\" height=\"273\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/03.png\" alt=\"\" class=\"wp-image-788\" srcset=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/03.png 672w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/03-320x130.png 320w\" sizes=\"auto, (max-width: 672px) 100vw, 672px\" \/><figcaption>Download the version you want (the first option should be good)<\/figcaption><\/figure>\n<\/div>\n\n\n<h2 class=\"wp-block-heading\">App to start video<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Let&#8217;s create a window with the list of the mp4 in a listbox.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># use ffmplay to play the videos with tkinter\n\nimport tkinter as tk\nimport tkinter.ttk as ttk\nimport os\n\nroot = tk.Tk()\n\nlb = tk.Listbox(root)\nlb.pack()\n\nfor file in os.listdir():\n    if file.endswith(\".mp4\"):\n        lb.insert(0, file)\n\nroot.mainloop()\n<\/pre>\n\n\n<div style=\"width: 747px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-754-1\" width=\"747\" height=\"467\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmplay_1.mp4?_=1\" \/><a href=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmplay_1.mp4\">https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2018\/07\/ffmplay_1.mp4<\/a><\/video><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Let&#8217;s start the movie<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Now we add a button and an action that activate a function when the mouse button is pressed to make the selected movie start. To stop the movie press q or esc.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># use ffmplay to play the videos with tkinter\n\nimport tkinter as tk\nimport tkinter.ttk as ttk\nimport os\n\nroot = tk.Tk()\n\nlb = tk.Listbox(root)\nlb.pack()\n\n\ndef ffplay(event):\n    if lb.curselection():\n        file = lb.curselection()[0]\n        os.system(\"ffplay \" + lb.get(file))\n\n\nfor file in os.listdir():\n    if file.endswith(\".mp4\"):\n        lb.insert(0, file)\n\nbstart = ttk.Button(root, text=\"Start movie\")\nbstart.pack()\n\nbstart.bind(\"&lt;ButtonPress-1&gt;\", ffplay)\nroot.mainloop()\n<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Start an mp4 file with your default software for videos (without ffplay)<\/h2>\n\n\n\n<pre class=\"wp-block-preformatted\"># use ffmplay to play the videos with tkinter\n\nimport tkinter as tk\nimport tkinter.ttk as ttk\nimport os\n\nroot = tk.Tk()\n\nlb = tk.Listbox(root)\nlb.pack()\n\n\ndef ffplay(event):\n    if lb.curselection():\n        file = lb.curselection()[0]\n        os.startfile(lb.get(file))\n\n\nfor file in os.listdir():\n    if file.endswith(\".mp4\"):\n        lb.insert(0, file)\n\nbstart = ttk.Button(root, text=\"Start movie\")\nbstart.pack()\n\nbstart.bind(\"&lt;ButtonPress-1&gt;\", ffplay)\nroot.mainloop()\n<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Starting a video with tkvideo<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">import tkinter as tk\nfrom tkvideo import tkvideo\nimport pygame\nimport os\n\n\n\ndef get_audio(file):\n\tfrom moviepy.editor import VideoFileClip\n\n\t# Load the MP4 file\n\tvideo = VideoFileClip(file + \".mp4\")\n\n\t# Extract the audio\n\taudio = video.audio\n\n\t# Save the audio as an MP3 file\n\taudio.write_audiofile(file + \".mp3\")\n\n\ndef start(file):\n\tif not file + \".mp3\" in os.listdir(\".\"):\n\t\tget_audio(file)\n\tpygame.init()\n\tpygame.mixer.init()\n\tpygame.mixer.music.load(file + \".mp3\")\n\troot = tk.Tk()\n\t# root.geometry(\"640x480\")\n\n\tvideoPlayer = tk.Label(root)\n\tvideoPlayer.pack()\n\tvideo = tkvideo(file + \".mp4\", videoPlayer, loop=1, size=(640,480))\n\tvideo.play()\n\tpygame.mixer.music.play()\n\troot.mainloop()\n\n\nstart(\"froggo\")<\/pre>\n\n\n\t<!----- pubblicit\u00e0-------- vedi h:\\ads\\codice_di_prima.txt per il codice che era qui --------------------->\r\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script>\r\n<!-- Altervista-pythonprogramming-336X280 -->\r\n<ins class=\"adsbygoogle\"\r\n     style=\"display:block\"\r\n     data-ad-client=\"ca-pub-4189782812829764\"\r\n     data-ad-slot=\"2548661001\"\r\n     data-ad-format=\"auto\"><\/ins>\r\n<script>\r\n     (adsbygoogle = window.adsbygoogle || []).push({});\r\n<\/script>\r\n<h4>Tkinter test for students<\/h4>\r\n\r\n\r\n<script>\r\nvar title = \"Tkinter posts\";\r\n\t\tvar links = [\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-app-to-make-a-different-test-for-every-student-part-1\/\",\"Tk Test Marker I\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-testmaker-part-ii\/\",\"Tk Test Maker II\"],\t\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-tests-app-part-3\/\",\"Tk test Maker III\"]\r\n];\r\n\t\t\r\n\t<\/script>\r\n<script>\r\n\t\r\nif (typeof next2 != \"undefined\"){let next2 = 0;}\r\n\t\r\nnext2 = 0;\r\n\thtml = \"\";\/\/<b style='color:coral;font-size:1.2em'>Other posts about \" + title + \"<\/b><br>\";\r\nfor (address of links) \r\n{\r\n\r\n\tif (next2 == 1){\r\n\t\thtml += \"<div style='background:coral'>\";\r\n\t\thtml += \"Next link => <a href='\" + address[0] + \"'>\" + address[1] + \"<\/a>\";\r\n\t\thtml += \"<\/div><br>\";\r\n\t\tnext2 = 0;\r\n\t}\r\n\tif (address[0] == document.URL) {\r\n\t\tnext2 = 1;\r\n\t}\r\n}\r\n\r\nif (typeof next != \"undefined\") {let next = 0;}\r\nif (typeof addressStart != \"undefined\") {let addressStart = \"\";}\r\nnext = 0;\r\naddressStart = \"<a href='\";\r\nfor (address of links) {\r\n\tif (next == 1){\r\n\t\thtml += \">>>\" + addressStart + address[0] + \"'>\" + address[1] + \"<\/a><br>\";\r\n\t\tnext = 0;\r\n\t}\r\n\telse if (addressStart + address[0] != document.URL)\r\n\t{\r\n\t\thtml += addressStart + address[0] + \"'>\" + address[1] + \"<\/a><br>\";\r\n\t}\r\n\telse\r\n\t{\r\n\t\tnext = 1;\r\n\t\tnext_address = address[0]\r\n\t\tnext_title = address[1]\r\n\t\thtml += \"<span style='color:gray'>\" + address[1] + \"<\/span><br>\";\r\n\t}\r\n\r\n}\r\n\r\n\thtml += `<span style=\"font-size:8px\">Powered by <a href=\"https:\/\/pythonprogramming.altervista.org\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2673\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2019\/06\/altervista2.png\" alt=\"\" width=\"70\" height=\"25\" srcset=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2019\/06\/altervista2.png 156w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2019\/06\/altervista2-150x56.png 150w\" sizes=\"auto, (max-width: 70px) 100vw, 70px\" \/>pythonprogramming.altervista.org<\/a><\/span>`\r\n\thtml = \"<div style='background:yellow'>\" + html + \"<\/div>\";\r\n\tdocument.write(html)\r\n<\/script>\r\n\t\r\n\r\n<h4>Tkinter articles<\/h4>\r\n<!-- calculator with memo -->\r\n<a href=\"https:\/\/pythonprogramming.altervista.org\/free-calculator-memo-with-tkinter-support-markdown-to-html-saving-too\/\">\r\n<img decoding=\"async\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2020\/03\/calcmemopy_banner.png\" width=\"100%\"><\/a>\r\n<script>\r\nvar title = \"Tkinter posts\";\r\n\t\tvar links = [\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/?p=5719&preview=true\",\"Presentation app with SVG files\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/png-joined-in-one-pdf-files\/\",\"Join png into pdf\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/free-app-imgslide-3-1-slide-images-and-join-them-into-a-pdf\/\",\"ImageSlider 3.1\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-to-show-svg-files-svgslider-1-0\/\",\"SVGSlider 1.0\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/imageslider-3-0-tkinter-app-to-show-images-like-in-a-presentation\/\",\"ImageSlider 3.0\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-shows-an-svg-file\/\",\"SVG in tkinter\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-tests-maker-app-part-iv-add-a-menu-with-tkinter\/\",\"Add a menu with tkinter\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/free-pdf-maker-app-with-python\/\",\"tkinter make pdf\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/calcpy-2-0-the-second-and-final-part-of-calculator\/\",\"Live coding Calculator app part 2\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/split-every-page-in-a-pdf-i-a-different-pdf\/\",\"Split a pdf in different files\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/python-calculator-from-skratch-part-1-calcpy\/\",\"Calculator from skratch p.1\"], \r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/python-and-tkinter-fully-working-listbox-to-do-app-for-skratch\/\",\"Tkinter ToDo App\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/copy-and-paste-tkinter-widget-code-app\/\",\"Copy and paste app for tkinter widgets\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/calcdoc-py-a-tkinter-app-to-memorize-operations\/\",\"calcdoc.py: a great calculator memo app\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-calculator-with-memo-of-operations\/\",\"Calculator + list of operations\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-smallest-calculator-ever\/\", \"Smallest calculator\"],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/python-gui-with-tkinter-labels-with-text-and-images\/\",\"Labels with images and text\"],\r\n\t[\"https:\/\/pythonprogramming.altervista.org\/a-toolbar-for-python-with-tkinter\/\",\"Toolbar in tkinter\"],\r\n\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-grid-system-how-to-expand-a-button\/\",\"Fit Buttons to the Window\"],\r\n\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-application-launcher-python-gui\/\",\"Tkinter app Laucher\"],\r\n\t\t[\"https:\/\/pythonprogramming.altervista.org\/tkinter-and-how-to-add-an-image-to-a-button\/\", \"Image on a tkinter Button\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-imagebrowser-2-with-canvas\/\", \"Tkinter image browser 2 (canvas)\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-image-broswer\/\",\"Tkinter image browser (label)\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-to-make-pdf-fast-and-free-with-text-or-html\/\",\"Create PDF with Tkinter Text widget\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-app-to-evaluate-tests-part-1\/\",\"Tkinter App to Evaluate tests\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/simple-presentation-in-pure-python-while-you-learn-tkinter\/\",\"Presentation with Python\/tkinter\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-entry-widgets-example-make-a-shuffler-app\/\",\"Tkinter example: entry to shuffle lists\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/move-a-rectangle-with-text-inside-of-it-with-tkinter\/\",\"Moving a text with tkinter\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-and-ttk-the-option-menu-widget\/\",\"Tkinter's OptionMenu (and ttk)\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-app-to-watch-videos-with-live-coding\/\",\t\t\t\t\t\"Tkinter to watch videos\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/type-reader-app-in-python-pc-read-the-letters-you-type-tkinter\/\",\t\"Type Reader App\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/create-a-new-tkinter-widget-inputbox\/\",\t\t\t\t\t\t\t\"Create your Inputbox\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-open-a-new-window-and-just-one\/\", \t\t\t\t\t\t\"Open only one more window\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/a-simple-test-maker-with-python-and-tkinter\/\", \t\t\t\t\t\"Test maker with tkinter\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/my-personal-notepad-toggle-tkinter-fullscreen\/\",\t\t\t\t\t\"Ebook maker with tkinter\"],\r\n[\"https:\/\/pythonprogramming.altervista.org\/tkinter-and-listbox-1\/\", \t\t\t\t\t\t\t\t\t\t\t\"Tkinter & listbox 2019 - 1\"],\r\n['https:\/\/pythonprogramming.altervista.org\/tkinter-using-a-gui-graphic-user-interface-with-python-part-1\/', \t'Create a window'],\r\n['https:\/\/pythonprogramming.altervista.org\/tkinter-to-make-a-window-video-1\/', \t\t\t\t\t\t\t\t'Create a window part 2'],\r\n[\"https:\/\/pythonprogramming.altervista.org\/create-more-windows-with-tkinter\/\",\t\t\t\t\t\t\t\t\"More windows tkinter!\"],\r\n['https:\/\/pythonprogramming.altervista.org\/tkinter-part-2-binding\/', \t\t\t\t\t\t\t\t\t\t'Binding functions to key\/button '],\r\n\t\t\t[\"https:\/\/pythonprogramming.altervista.org\/all-tkinter-posts\/\",\">>>ALL TKINTER POSTS>>>\"]\r\n\t\t];\r\n\t\t\r\n\t<\/script>\r\n<script>\r\n\t\r\nif (typeof next2 != \"undefined\"){let next2 = 0;}\r\n\t\r\nnext2 = 0;\r\n\thtml = \"\";\/\/<b style='color:coral;font-size:1.2em'>Other posts about \" + title + \"<\/b><br>\";\r\nfor (address of links) \r\n{\r\n\r\n\tif (next2 == 1){\r\n\t\thtml += \"<div style='background:coral'>\";\r\n\t\thtml += \"Next link => <a href='\" + address[0] + \"'>\" + address[1] + \"<\/a>\";\r\n\t\thtml += \"<\/div><br>\";\r\n\t\tnext2 = 0;\r\n\t}\r\n\tif (address[0] == document.URL) {\r\n\t\tnext2 = 1;\r\n\t}\r\n}\r\n\r\nif (typeof next != \"undefined\") {let next = 0;}\r\nif (typeof addressStart != \"undefined\") {let addressStart = \"\";}\r\nnext = 0;\r\naddressStart = \"<a href='\";\r\nfor (address of links) {\r\n\tif (next == 1){\r\n\t\thtml += \">>>\" + addressStart + address[0] + \"'>\" + address[1] + \"<\/a><br>\";\r\n\t\tnext = 0;\r\n\t}\r\n\telse if (addressStart + address[0] != document.URL)\r\n\t{\r\n\t\thtml += addressStart + address[0] + \"'>\" + address[1] + \"<\/a><br>\";\r\n\t}\r\n\telse\r\n\t{\r\n\t\tnext = 1;\r\n\t\tnext_address = address[0]\r\n\t\tnext_title = address[1]\r\n\t\thtml += \"<span style='color:gray'>\" + address[1] + \"<\/span><br>\";\r\n\t}\r\n\r\n}\r\n\r\n\thtml += `<span style=\"font-size:8px\">Powered by <a href=\"https:\/\/pythonprogramming.altervista.org\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2673\" src=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2019\/06\/altervista2.png\" alt=\"\" width=\"70\" height=\"25\" srcset=\"https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2019\/06\/altervista2.png 156w, https:\/\/pythonprogramming.altervista.org\/wp-content\/uploads\/2019\/06\/altervista2-150x56.png 150w\" sizes=\"auto, (max-width: 70px) 100vw, 70px\" \/>pythonprogramming.altervista.org<\/a><\/span>`\r\n\thtml = \"<div style='background:yellow'>\" + html + \"<\/div>\";\r\n\tdocument.write(html)\r\n<\/script>\n","protected":false},"excerpt":{"rendered":"ffmpeg ffplay\n<a class=\"moretag\" href=\"https:\/\/pythonprogramming.altervista.org\/tkinter-a-program-start-mp4-with-ffplay\/\"> [...]<\/a>","protected":false},"author":1,"featured_media":779,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_crdt_document":"","footnotes":""},"categories":[1,417,49,178,50],"tags":[197,4,51],"class_list":["post-754","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-examples","category-ffmpeg","category-tkinter","category-utility","category-video","tag-ffmpeg","tag-python","tag-tkinter"],"avopt_banners_inside_post":true,"avopt_banners_on_page":true,"av_copy_from":"","av_sharing_message":"","av_sharing_allowed":false,"av_sharing_on":{"fb":[],"tw":[]},"av_allow_affiliate_banner":false,"av_allow_affiliate_multi_banner":false,"av_show_affiliation_buy_button":false,"av_post_rating":true,"av_have_post_rating_value":false,"av_is_artificial_intelligence_content":false,"_links":{"self":[{"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/posts\/754","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/comments?post=754"}],"version-history":[{"count":10,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/posts\/754\/revisions"}],"predecessor-version":[{"id":12570,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/posts\/754\/revisions\/12570"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/media\/779"}],"wp:attachment":[{"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/media?parent=754"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/categories?post=754"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pythonprogramming.altervista.org\/wp-json\/wp\/v2\/tags?post=754"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}