From 7aec4e4ce5e84367bd198b6a25cac6614372ad36 Mon Sep 17 00:00:00 2001 From: Christos Zoulas Date: Wed, 9 Jan 2019 02:59:26 +0000 Subject: [PATCH] prettier output for Garmin VPM files (Joerg Jenderek) --- magic/Magdir/audio | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/magic/Magdir/audio b/magic/Magdir/audio index b429fbb5..6ebca3cf 100644 --- a/magic/Magdir/audio +++ b/magic/Magdir/audio @@ -1,6 +1,6 @@ #------------------------------------------------------------------------------ -# $File: audio,v 1.94 2019/01/04 14:01:49 christos Exp $ +# $File: audio,v 1.95 2019/01/09 02:59:26 christos Exp $ # audio: file(1) magic for sound formats (see also "iff") # # Jan Nicolai Langfeldt (janl@ifi.uio.no), Dan Quinlan (quinlan@yggdrasil.com), @@ -744,7 +744,7 @@ # Summary: Garmin Voice Processing Module (WAVE audios) # From: Joerg Jenderek # URL: http://www.garmin.com/ -# Reference: http://turboccc.wikispaces.com/share/view/28622555 +# Reference: http://www.poi-factory.com/node/19580 # NOTE: there exist 2 other Garmin VPM formats 0 string AUDIMG # skip text files starting with string "AUDIMG" @@ -768,15 +768,25 @@ # if you select a language like german on your garmin device # you can only select voice modules with corresponding language byte ID like 1 >>18 ubyte x \b, language ID %d +# structure for phrases/sentences? +# number of voice sample in the 1st phrase? +#>>19 uleshort x \b, 0x%x samples +#>>>21 uleshort >0 \b, at 0x%4.4x +#>>>(21.s) ubequad x 0x%llx +# 2nd phrase? +#>>23 uleshort x \b, 0x%x samples +#>>>25 uleshort >0 \b, at 0x%4.4x +#>>>(25.s) ubequad x 0x%llx # pointer to 1st audio WAV sample >>16 uleshort >0 ->>>(16.s) ulelong >0 \b, at offset 0x%x +>>>(16.s) ulelong >0 \b, at 0x%x # WAV length ->>>>(16.s+4) ulelong >0 %d Bytes +# 1 space char after "bytes" to get phrase "bytes RIFF" +>>>>(16.s+4) ulelong >0 %u bytes # look for magic >>>>>(&-8.l) string RIFF # determine type by ./riff ->>>>>>&-4 indirect x \b +>>>>>>&-4 indirect x # 2 - ~ 131 WAV samples following same way # # Summary: encrypted Garmin Voice Processing Module -- 2.40.0