Batch convert BVR to MP4

ckilner
Posts: 1
Joined: Wed Dec 29, 2021 9:23 pm

Batch convert BVR to MP4

Post by ckilner »

Rightly or wrongly, I have copied a large number of .bvr files from the BlueIris file system over to a backup drive. What I would like to do now is to convert them all to mp4 so that they can be viewed outside BlueIris. Is there a way to do this?
MikeBwca
Posts: 1093
Joined: Thu Jun 20, 2019 5:39 am

Re: Batch convert BVR to MP4

Post by MikeBwca »

...
Last edited by MikeBwca on Fri Apr 05, 2024 7:15 pm, edited 1 time in total.
User avatar
Thixotropic
Posts: 744
Joined: Wed Sep 04, 2019 7:20 pm
Location: Low-Earth Orbit

Re: Batch convert BVR to MP4

Post by Thixotropic »

I've attached a converter script I wrote a while ago that uses ffmpeg. I think this will do exactly what you want.

BVRConverter.zip
(2.78 KiB) Downloaded 3266 times

1) Read the README file.

2) Modify the source and target params at the top of the script and run it. It'll convert a directory full of .BVR clips to .MP4, with selectable scaling and resolution (quality). Please let me know if you have any trouble with it.

Note that you'll need to install ffmpeg (free) for it to work.
FFMPEG can be downloaded from here: https://www.ffmpeg.org/download.html

Cheers
Blue Iris 5.x x64 | Windows 10 Pro x64 | 16GB RAM | i7-7700 3.6 GHz | 1TB HDD | 2TB RAID NAS | 9 Cameras | Almost Dual NIC | 2KVA UPS
ramaz16
Posts: 23
Joined: Sun Mar 14, 2021 4:46 pm

Re: Batch convert BVR to MP4

Post by ramaz16 »

Thixotropic wrote: Sat Jan 01, 2022 3:37 pm I've attached a converter script
Did you try to playback exported by your script MP4 in the latest BI version? I export fragments of BVR clips to MP4 using BI5.x x64 own encoder with 100% quality in H264/AAC with Zero frame latency in 2-passes. The source BVRs are from analog cam and standalone mic, they are re-encoded by BI to include date/time overlay. However, the exported MP4s won't play in BI. It shows "Install latest K-Lite codec" on screen, but once I did that, BI just shows empty framed playback window with no picture. Same MP4s are playing well in any soft video player, including Windows 10 Movies & TV. Why does one need to install K-Lite if Windows own player has no problems with these files?

For some reason, Exif Tool shows 2 tracks in this MP4 sample - may be this is the reason it doesn't play in BI after K-Lite install? Also, after installing K-Lite I got periodic monitor blackouts, so had to remove it anyway, never had need in it, as MPC-BE, VLC and such play everything.

Any suggestions, what K-Lite codec version or standalone Lav will work with BI for sure to play exported by it MP4s? Or better yet, how to link BI to the existing system codec? May be BI devs can do that for us?
User avatar
YrbkMgr
Posts: 587
Joined: Sun Nov 24, 2019 12:56 am
Location: Chicagoland

Re: Batch convert BVR to MP4

Post by YrbkMgr »

ckilner wrote: Wed Dec 29, 2021 9:26 pm Rightly or wrongly, I have copied a large number of .bvr files from the BlueIris file system over to a backup drive. What I would like to do now is to convert them all to mp4 so that they can be viewed outside BlueIris. Is there a way to do this?
Manually deleting stuff from folders like storage and alerts and such can be dicey. BI recommends against manual deletions and to rely instead on moving/deleting, etc from within the console so as to avoid corruption of the database. Ask me how I know...

It's probably best to get your arms around understanding how clips and archiving works so that you can set storage and retention parameters to manage what goes where and when, automatically. I no longer care about how many clips I have - I set it and forget it and can find what I want when I need to. Worth looking into in my view.

Since you've already manually moved the BVR's, here's what I would do... Create a new storage location in Clips and Archiving. Move your BVR's there and repair/regenerate the database. Then set retention and export policy to automatically export those BVR's to MP4.
2022-01-01_173755.JPG
2022-01-01_173755.JPG (138.84 KiB) Viewed 169216 times
  • "Whenever I take something apart to fix it and put it back together again, I end up with like six really important looking pieces left over" -Tim Allen
  • If you know what your after, you'll recognize it when you see it.
ramaz16
Posts: 23
Joined: Sun Mar 14, 2021 4:46 pm

Re: Batch convert BVR to MP4

Post by ramaz16 »

ckilner wrote: Wed Dec 29, 2021 9:26 pm I have copied a large number of .bvr files from the BlueIris file system over to a backup drive. What I would like to do now is to convert them all to mp4 so that they can be viewed outside BlueIris. Is there a way to do this?
Try adding your current drive & folder as Saved location in BI settings, and Regenerate the Clips DB. Then you can manually select all in Clips List and Batch Export to MP4 from Context Menu (Help. p.116)
User avatar
YrbkMgr
Posts: 587
Joined: Sun Nov 24, 2019 12:56 am
Location: Chicagoland

Re: Batch convert BVR to MP4

Post by YrbkMgr »

Pretty much what I said above.
  • "Whenever I take something apart to fix it and put it back together again, I end up with like six really important looking pieces left over" -Tim Allen
  • If you know what your after, you'll recognize it when you see it.
User avatar
Thixotropic
Posts: 744
Joined: Wed Sep 04, 2019 7:20 pm
Location: Low-Earth Orbit

Re: Batch convert BVR to MP4

Post by Thixotropic »

ramaz16 wrote: Sat Jan 01, 2022 8:50 pmDid you try to playback exported by your script MP4 in the latest BI version?
No, I wrote it and used it for a while for a project I was doing. Later I decided I didn't really need to export clips for what I wanted to do and I moved on to other things.

Maybe I misunderstood what you said; that is, why would I need to play the exported clips using BI?

For me the point of exporting the clips was to play them using other players on other platforms that didn't or couldn't have BI on them. (??)
Blue Iris 5.x x64 | Windows 10 Pro x64 | 16GB RAM | i7-7700 3.6 GHz | 1TB HDD | 2TB RAID NAS | 9 Cameras | Almost Dual NIC | 2KVA UPS
User avatar
YrbkMgr
Posts: 587
Joined: Sun Nov 24, 2019 12:56 am
Location: Chicagoland

Re: Batch convert BVR to MP4

Post by YrbkMgr »

Thixotropic wrote: Sun Jan 02, 2022 1:08 am For me the point of exporting the clips was to play them using other players on other platforms that didn't or couldn't have BI on them. (??)
That's my understanding as well.
  • "Whenever I take something apart to fix it and put it back together again, I end up with like six really important looking pieces left over" -Tim Allen
  • If you know what your after, you'll recognize it when you see it.
ramaz16
Posts: 23
Joined: Sun Mar 14, 2021 4:46 pm

Re: Batch convert BVR to MP4

Post by ramaz16 »

Thixotropic wrote: Sun Jan 02, 2022 1:08 am why would I need to play the exported clips using BI?
For me the point of exporting the clips was to play them using other players on other platforms. (??)
Each use case is different. Some export files to MP4 to present them as video evidence.

Anyway, BI has an embedded video player that plays several file formats quite well. It allows to speedup playback at various rates, which is very important when reviewing several clips at the end of day. This feature also helpful when playing MP4s, if it can. Generally, a video player-editor is expected to play a file it converted to another format - this is bottom line quality standard. I currently have to use 2 players: BI player for BVR and MPC-BE for MP4 to use accelerated playback. Note, that the question "why?" can not substitute the answer to my question "how?", which was asked repeatedly by users for many years. BI Help advising to install K-Lite codec is not well justified and simply doesn't work lately.
Post Reply