From 109a1d715dd6742d53a242849f07675653b27e84 Mon Sep 17 00:00:00 2001 From: k-m_schindler Date: Thu, 28 Feb 2013 17:09:15 +0000 Subject: new tool for the calculation of four letter tags. Some ffmpeg files need these hard-coded. Includes binaries. git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@2957 b956fd51-792f-4845-bead-9b4dfca2ff2c --- tools/DoTags/DoTags.exe | Bin 0 -> 56708 bytes tools/DoTags/DoTags.pas | 26 ++++++++++++++++++++++++++ tools/DoTags/DoTags_linux | Bin 0 -> 257319 bytes tools/DoTags/DoTags_macosx | Bin 0 -> 241992 bytes 4 files changed, 26 insertions(+) create mode 100644 tools/DoTags/DoTags.exe create mode 100644 tools/DoTags/DoTags.pas create mode 100755 tools/DoTags/DoTags_linux create mode 100755 tools/DoTags/DoTags_macosx (limited to 'tools') diff --git a/tools/DoTags/DoTags.exe b/tools/DoTags/DoTags.exe new file mode 100644 index 00000000..48ee1285 Binary files /dev/null and b/tools/DoTags/DoTags.exe differ diff --git a/tools/DoTags/DoTags.pas b/tools/DoTags/DoTags.pas new file mode 100644 index 00000000..1e18ea12 --- /dev/null +++ b/tools/DoTags/DoTags.pas @@ -0,0 +1,26 @@ +program DoTags; +var + four_letters: string; + tag: int32; +begin + writeln ('Program for the calculation of 4 letter tags, little and big endian.'); + writeln ('Enter 4 letters:'); + readln (four_letters); + while length(four_letters) <> 4 do + begin + writeln ('This were ', length(four_letters), ' letter(s). Enter exactly 4 letters:'); + readln (four_letters); + end; + tag := ord(four_letters[4]) or (ord(four_letters[3]) shl 8) or (ord(four_letters[2]) shl 16) or (ord(four_letters[1]) shl 24); + writeln ('BE-TAG: $', hexStr(tag, 8)); + tag := ord(four_letters[1]) or (ord(four_letters[2]) shl 8) or (ord(four_letters[3]) shl 16) or (ord(four_letters[4]) shl 24); + writeln ('LE-TAG: $', hexStr(tag, 8)); + if four_letters[1] = '0' then + begin + writeln ('Maybe you want a digital zero in the first position. Here you go:'); + tag := ord(four_letters[4]) or (ord(four_letters[3]) shl 8) or (ord(four_letters[2]) shl 16); + writeln ('BE-TAG: $', hexStr(tag, 8)); + tag := (ord(four_letters[2]) shl 8) or (ord(four_letters[3]) shl 16) or (ord(four_letters[4]) shl 24); + writeln ('LE-TAG: $', hexStr(tag, 8)); + end; +end. diff --git a/tools/DoTags/DoTags_linux b/tools/DoTags/DoTags_linux new file mode 100755 index 00000000..0aaea9f4 Binary files /dev/null and b/tools/DoTags/DoTags_linux differ diff --git a/tools/DoTags/DoTags_macosx b/tools/DoTags/DoTags_macosx new file mode 100755 index 00000000..8858e351 Binary files /dev/null and b/tools/DoTags/DoTags_macosx differ -- cgit v1.2.3