Hi,

I wonder if anyone can help,

We have an unbranded DVR player, which outputs files by default as native:
.rmi – containing the video metadata
.rms – containing the video stream itself
.rai – containing the audio metadata
.ras – containing the audio stream itself

We need to convert these files to a common file format without using the software on the DVR, as we find that using this, the video is much lower quality, and audio is out of sync.

We have managed to convert the video file using ffmpeg and numerous commands, but are struggling with the audio. From our investigation it appears the audio is:

G.723, 8Khz, 16 bit, mono, 125kbps

We have tried a number of combinations of libraries including FFMpeg, Sox and G72x+ Decoder, but none have been able to decode the audio to play it as an MP3.

Does anyone have any advice on how we can do this so that we can write a simple script to automate the conversion? I would be very grateful for any assistance, advice or ideas.

Thank you very much for your time.

Small small world. While I can't reveal all, I traveled many times to parts east and no, such a convertor is often only from the DVR maker.

The usual workaround is to play the content on the DVR and capture it the usual way. Sometimes you encounter folk new to these DVRs and they are thinking like PC folk. Again, no. Get back to the maker to see if they created export or other tools.

Sample file attached

rproffitt, thank you for your reply. I've spoken to the company but the only tool that exists from produces a noticably lower quality video than native, and lip sync is out.

We currently capture using the video card you mention, but realtime capture is getting out of hand at the moment.

Surely, with the audio been G.723 (updated later to G.726) which is still popular with some VOIP or speech recording software, others must have had the same issue and found a way to convert similar files?

We know of some software which can do it such as 'magic audio converter', but it would continue to complicate the workflow - whereas a single script to do this would be simpler.

Thank you for your reply.

What I found was they used various chips to do such encoding/playback and was not entirely standardized. The company I travel and work for eventually had to had it reverse engineered for close to a million bucks. Now you may think that too much but when you move some 1000+ surveillience DVRs a week you see where a cheap DVR can pay off having to get custom work done.

I can't tell all but know that we have to travel to the source to get such work done or start a reverse engineer effort.

Anyone that thinks this stuff is a G.something standard is new to the game. Frankly I think that for one off situations replacing the DVR is the cheap exit.

Thanks for the information. It sounds like you certainly know the industry, but I think that our situations based on the DVR's are different in this scenario.

I think in this instance its not a hardware encode/decoding as we know of manufactorer software which allows the user to playback footage from raw files on any machine.

It's also interesting that a reasonable cheap but effective tool such as 'magic audio converter' can convert the audio. I can't imagine they've invested heavily in this, as it converts with what they declare is a G.723 format.

This is why i'm asking if anyone knows any scripts etc which can do this rather than using a commericalised piece of software. Hopefully we can find a G.723 format converter and wont have the encryption issues you've faced.

Thank you for the information though, its certainly worth us considering this.

Tell more. Up top you write "none have been able to decode" and now you write about "magic audio converter". If all you want is to automate this we've done that by using apps such as you noted (magic) and then AUTOHOTKEY to do the automation.

Post edit: Never had an "encryption" issue. Just oddly encoded stuff done by those cheap DVRs out on the market.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.