{"id":31608810,"url":"https://github.com/gcuser99/ffmpeg-vba","last_synced_at":"2025-10-06T08:24:46.208Z","repository":{"id":46332456,"uuid":"511660659","full_name":"GCuser99/ffmpeg-vba","owner":"GCuser99","description":"A wrapper for automating video/image editing with FFmpeg, written in Windows Excel VBA","archived":false,"fork":false,"pushed_at":"2024-06-18T19:30:55.000Z","size":1038,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-07-10T09:56:50.919Z","etag":null,"topics":["automation","excel","ffmpeg","ffplay","ffprobe","image","vba","video"],"latest_commit_sha":null,"homepage":"","language":"VBA","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GCuser99.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-07-07T20:08:08.000Z","updated_at":"2025-05-03T14:47:10.000Z","dependencies_parsed_at":"2022-09-23T02:13:01.119Z","dependency_job_id":"387ed850-4281-4676-a6d9-59335b96e42e","html_url":"https://github.com/GCuser99/ffmpeg-vba","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/GCuser99/ffmpeg-vba","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GCuser99%2Fffmpeg-vba","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GCuser99%2Fffmpeg-vba/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GCuser99%2Fffmpeg-vba/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GCuser99%2Fffmpeg-vba/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GCuser99","download_url":"https://codeload.github.com/GCuser99/ffmpeg-vba/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GCuser99%2Fffmpeg-vba/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278578130,"owners_count":26009739,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-06T02:00:05.630Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","excel","ffmpeg","ffplay","ffprobe","image","vba","video"],"created_at":"2025-10-06T08:24:45.171Z","updated_at":"2025-10-06T08:24:46.198Z","avatar_url":"https://github.com/GCuser99.png","language":"VBA","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Software: ffmpeg-vba v0.4\n\nThis is a wrapper for automating video/image editing with FFmpeg, written in Windows Excel VBA.\n\nSo what does this functionality have to do with MS Excel? Not much. However, if like me, you have invested in learning the VBA IDE, like to build automation templates, and want to apply that to video editing, then perhaps this media editor might be of interest. Otherwise, maybe no use at all... :-)\n\n## Features\n\n- Support for automating command line executables FFmpeg, FFprobe, and FFplay \n- Wrappers for a useful functionality subset, including common tasks like trimming, editing, overlays, filtering, re-encoding, and more\n- Convenient video file play-back for instant feedback\n- Utility support for relative file paths, VBA RGB color specification, intermediate product file deletion\n- Ability to build and run your own commands if wrapper not already provided\n\n## Setup\n\n1) Download/unzip ffmpeg-vba_v0.4.zip to a directory of your choice\n2) Download/unzip the [ffpmeg executables](https://ffmpeg.org/download.html) (ffmpeg.exe, ffprobe.exe, ffplay.exe) and place in same directory as the Excel macro file\n3) Download the sample video file called \"BigBuckBunny.mp4\" from [here](http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4) into same directory\n4) Open the excel macro file, go to VBA IDE under the Developer Tab\n5) Click on the \"examples\" standard module to browse and run examples that cover most of the functionality provided\n\n## Example Usage\n\n```vba\nSub example()\n    Dim media As New ffMpeg\n    Dim eparms As New ffEncodeSet\n    Dim txts As New ffTexts\n    \n    'uncomment and modify command below if media files are in a different loc than this Excel file\n    'media.DefaultIOPath=\"[path to your media files]\"\n    \n    'trim the input video to the desired time window\n    media.Trim \"BigBuckBunny.mp4\", \"trim.mp4\", \"1:16\", \"1:36\", True\n    \n    'reverse the trimmed result\n    media.Reverse \"trim.mp4\", \"rev.mp4\"\n    \n    'slow motion of the trimmed result\n    media.ChangeSpeed \"trim.mp4\", \"slomo.mp4\", 0.5\n    \n    'join the 3 videos produced above\n    media.Join \"trim.mp4, rev.mp4, slomo.mp4\", \"join.mp4\"\n    \n    'now use the Texts class to draw some text overlays\n    txts.MakeTexts 3\n    \n    'set some global text properties\n    txts.XLoc = 10: txts.YLoc = 10\n    txts.Font = \"arial\"\n    txts.FontSize = 48\n    \n    'set individual text properties\n    txts(1).Text = \"Trimmed Video\": txts(1).StartTime = 0: txts(1).EndTime = 20\n    txts(2).Text = \"Reversed Video\": txts(2).StartTime = 20: txts(2).EndTime = 40\n    txts(3).Text = \"Slow Motion Video\": txts(3).StartTime = 40: txts(3).EndTime = 80\n    \n    'draw the texts onto the composite video\n    media.DrawText \"join.mp4\", \"texts.mp4\", txts\n    \n    'specify a constant rate factor for encoding the final result using EncodeSet class\n    eparms.Crf = 25\n    \n    'make 3 second fade from/to black at beginning/end of video\n    media.Fade \"texts.mp4\", \"fade.mp4\", 3, 3, , eparms\n    \n    'print resulting file size to Intermediate Window\n    Debug.Print media.Probe.GetFileSize(\"fade.mp4\") 'in mb's\n    \n    'delete the intermediate file products\n    media.DeleteFiles \"trim.mp4\", \"rev.mp4\", \"slomo.mp4\", \"join.mp4\", \"texts.mp4\"\n    \n    'play the result at 50% of the video window size\n    media.Play \"fade.mp4\", , , , 0.5\nEnd Sub\n```\n```vba\nSub slideshow_example()\n    Dim media As New ffMpeg\n    Dim slides As New ffSlideShow\n    \n    'uncomment and modify command below if media files are in a different loc than this Excel file\n    'media.DefaultIOPath=\"[path to your media files]\"\n    \n    'extract images every 13.5 secs for slide show\n    For i = 1 To 44\n        media.ExtractFrame \"BigBuckBunny.mp4\", \"slide\" \u0026 Format(i, \"00\") \u0026 \".jpg\", 13.5 * (i - 1) + 1\n    Next i\n    \n    'initialize slides\n    slides.MakeSlides 44\n    \n    'set global properties for slide deck\n    slides.Duration = 2.5\n    slides.TransitionDuration = 1\n    \n    'set properties for each slide\n    For i = 1 To 44\n        slides(i).InputPath = \"slide\" \u0026 Format(i, \"00\") \u0026 \".jpg\"\n        'set a different xFade transition\n        slides(i).TransitionType = i - 1\n    Next i\n    \n    'compile into slide show video\n    media.MakeSlideShow slides, \"slideshow.mp4\"\n    \n    'delete images used with wildcard\n    media.DeleteFiles \"slide*.jpg\"\n    \n    'play the show\n    media.Play \"slideshow.mp4\", , , , 0.5\nEnd Sub\n```\n```vba\nSub overlay_example()\n    Dim ovls As New ffOverlays\n    Dim media As New ffMpeg\n    \n    'uncomment and modify command below if media files are in a different loc than this Excel file\n    'media.DefaultIOPath=\"[path to your media files]\"\n    \n    'overlays can be videos or images or a mix thereof\n    \n    'extract overlay images/videos from video\n    media.Trim \"BigBuckBunny.mp4\", \"overlay01.mp4\", 37, 47, True\n    media.Trim \"BigBuckBunny.mp4\", \"overlay02.mp4\", 67, 77, True\n    media.Trim \"BigBuckBunny.mp4\", \"overlay03.mp4\", 87, 97, True\n    \n    'initialize overlays with ffOverlay class\n    ovls.MakeOverlays 3\n    \n    'set some global overlay properties\n    ovls.XLoc = \"right-10\": ovls.YLoc = 10\n    ovls.FadeInDuration = 3: ovls.FadeOutDuration = 3\n    \n    'set individual overlay properties\n    ovls(1).InputPath = \"overlay01.mp4\"\n    ovls(1).startTime = 0: ovls(1).endTime = 10\n    ovls(1).Resize = 0.3\n    \n    ovls(2).InputPath = \"overlay02.mp4\"\n    ovls(2).startTime = 7: ovls(2).endTime = 17\n    ovls(2).Resize = 0.3\n    \n    ovls(3).InputPath = \"overlay03.mp4\"\n    ovls(3).startTime = 14: ovls(3).endTime = 24\n    ovls(3).Resize = 0.3\n    \n    'trim the input video\n    media.Trim \"BigBuckBunny.mp4\", \"trim.mp4\", 27, 52, True\n    \n    'overlay onto the \"base\" video\n    media.Overlay \"trim.mp4\", \"overlays.mp4\", ovls\n        \n    media.DeleteFiles \"trim.mp4\", \"overlay0*.mp4\"\n    \n    media.Play \"overlays.mp4\", , , , 0.5\nEnd Sub\n```\n## Collaboration\n\nIf you try this and want to report bugs or share ideas for improvement, your contribution is welcome!\n\n## Credits\n\n[VBA-JSON](https://github.com/VBA-tools/VBA-JSON) by Tim Hall, JSON converter for VBA\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgcuser99%2Fffmpeg-vba","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgcuser99%2Fffmpeg-vba","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgcuser99%2Fffmpeg-vba/lists"}