HQ NETWORK:   Xbox One |  Xbox 360 |  Auto Installer Deluxe |  Web Games Arcade HQ Network: 1,655 | Guests: 601 | Members: 2 


   Current Location: Forums Xbox-Hq Custom OG-Xbox Giveaway!!!   |   Hi All   |   Looking 4 DuoX3 Clone Modchips   |   FAKE AUTO INSTALLER DELUXE FOUND (THUMBS DOWN)   |   custom Hubsan h501A "SHOCK the WORLD" project   |   Conversion Scripts For All Major A/V Formats   |   XONEHQ.COM Celebrates 6,000 Subscribers on YouTube   |   New XMV Converter   |   PM Not Working   |   An Apology To All HQ Members   |   
  Home | Active Topics | CD/DVD Media | Downloads | Forums | Feedback | Games | HardDrives | Homebrew | My Profile | ModChips | Reviews | Search | SoftMods | Tutorials

Xbox Forums

Discuss all aspects of the original Xbox Console in our Interactive Xbox Forums..

Xbox-Hq.Com :: View topic - Conversion Scripts For All Major A/V Formats
Xbox-Hq.Com Forum Index -> Xbox Audio/Video Technical Discussions
Post new topic Reply to topic    
 Conversion Scripts For All Major A/V Formats View previous topic :: View next topic  
 
 
 
 
KIxxx
Xbox-HQ Member
Xbox-HQ Member




Joined: May 28, 2017
Posts: 99
Location: Canada

Post Posted: Thu Feb 01, 2018 12:24 pm   
Post subject: Conversion Scripts For All Major A/V Formats
Reply with quote
 
These are the control scripts for all the major converters Ive done. This covers XBOX ADPCM, XMU, XMV, ADW, XWMA, XMA, XM2, Decrypting XMA2, WMV, MP4, AVI, MPEG1, MPEG2, GIF, Merging video files, Screen Capture, Dumping audio, MP3, OGG, WMA, FLAC, WAVE files Very Happy

XMV (Requires FFMPEG, XBOXADPCM and XMVTool)
Code:
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged1.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged1.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\"
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged2.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged2.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged3.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged3.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\"
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged4.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged4.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged5.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged5.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\"
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged6.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged6.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged7.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged7.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\"
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged8.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged8.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged9.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged9.xmv" "Finished\"
move inputfiles\*.* finished\
FOR /F "delims=|" %%I IN ('DIR "queue\*.*" /B /O:D /S') DO SET NewestFile=%%I
move "%NewestFile%" "inputfiles\"
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 5 -preset veryslow -c:a pcm_u8 "newfiles\video.wmv"
for %%a in ("newfiles\video.wmv") do ffmpeg -i "%%a" -vn "newfiles\audio1.wav"
for %%a in ("newfiles\audio1.wav") do xbadpcmencode "%%a" "newfiles\audio.wav"
xmvtool -v "newfiles\video.wmv" -a "newfiles\audio.wav" -o Merged10.xmv
del newfiles\audio1.wav
del newfiles\audio.wav
del newfiles\video.wmv
move /-y "Merged10.xmv" "Finished\"
move inputfiles\*.* finished\
pause


XMU (requires XBOXADPCM)
Code:
for %%a in ("inputfiles\*.wav") do xbadpcmencode "%%a" "newfiles\%%~na.xmu"
pause


XMA Decrypting (Save as a .bms file and use with QuickBMS)
Code:
set BLOCKSIZE 0x10000
set XMAVERSION 2
set PARSE 1
set WRITE_UNPARSED 0

set TESTMODE 0
set TESTXMA1 0
set TEST_ADVANCED_BLOCKSIZES 0
set FREQ_DEFAULT 44100 # for files without given freq info/headerless files
set CH_DEFAULT 2 # for headerless XMA files
set ENABLE_SCAN 0
set COMMENTS 0

# supported XMA types:
# - wave header (RIFF/RIFX), big-endian & little-endian with any number of channels, wrong stream size is corrected
# - wave header with additional "xma." at the start (e.g. Fable II)
# - *.SoundNodeWave files from the UT3 engine (three types)
# - *.psb files from several XBLA games *needs some correction*
# - xma files with magic sign \x0\x0\x0\x0\x0\x0\x2\x0 (Are You Smarter Than A 5th Grader? series)
# - *.res files from Electronic Arts fbrb archives with possibly deflated XMA stream (e.g. Battlefield series)
# - xma files with "XWV " identifier (e.g. Bloody Good Time XBLA)
# - Microsoft XNA framework *.xnb files (e.g. Boulder Dash XL XBLA)
# - headerless XMA streams
# - header-reversed RIFF (e.g. Resident Evil 6)
# - FUNl header XMA2 (e.g. Men in Black: Alien Crisis)
# - Electronic Arts MUSX header (e.g. 007: Legends)
# - Quake 4 variant (XMA1)
# - Battlefield 4 variant (under construction)
# - Call of Duty: World at War variant
# - corrected XWV variant
# - *.swa, Star Wars: The Force Unleashed Xbox 360 (sound files inside the xd/xp containers)
#
# to do (not sorted by priority):
# - introduce the "-x" parameter of xma_parse (keeping the header, adjusting the channels)
#   has to be implemented for the scanning function later on (first run: plain-extract with -x & save offset/size second run: parse with -r)
# - try to determine working frequency (will need toWAV execution call)
# - transform SoundNodeWave markers to standard cue markers
# - add support for the Ubisoft XMA variant (includes multilayered files, Forge engine included)
# - for certain variants: disable TESTMODE and set specs automatically
# - auto-detection for SoundNodeWave and EA XMA (no file extension needed)
#
#
# Contents:
# ==================
# 1. Set user variables
# 2. Get/set some standards
# 3. identify XMA file type and link to according process lists
# 4. process different file types
#    4.1 RIFF/RIFX header                                  ~ processRIFF
#      4.1a get stream start and stream size from "data" section    ~ getDatastartRIFF
#      4.1b. RIFF header with codec ascii sign at offset INFO       ~ getSpecsRIFF
#      4.1c Extract RIFF cue markers                         ~ getCueRIFF
#   4.2 UT3 Engine *.SoundNodeWave (two types)                  ~ processSNW
#      4.2a Get INFO variable for RIFF header or determine variant   ~ getInfoSNW
#      4.2b Get specs from variant type                     ~ SNWVariant
#      4.2c Write SNW header to disk                        ~ getCueSNW
#   4.3 PSB header (various XBLA games)                        ~ processPSB
#   4.4 Variant from Are You Smarter Than A 5th Grader? (XBLA)      ~ process5thGraderXMA
#   4.5 Electronic Arts XMA variant (e.g. Battlefield series)      ~ processEAXMA
#      4.5a Inflate EA XMA                                 ~ parse_ea_xma
#   4.6 XWV header variant (e.g. Bloody Good Time XBLA)            ~ processXWV
#    4.7 Microsoft XNA Framework *.xnb                        ~ processXNB
#   4.8 FFIR header (RE6)                                 ~ processFFIR
#   4.9 FUNl header (e.g. Men in Black: Aien Crisis)            ~ processFUNl
#   4.10 MUSX header (e.g. 007 Legends)                        ~ processMUSX
#   4.11 Quake 4 variant                                 ~ processQ4
#   4.12 STR variant (e.g. Legens of War: Patton)               ~ processSTR
#   4.13 RAKI variant (Rayman: Legends, 2013)                  ~ processRAKI
#    4.14 Battlefield 4 variant (with 8 add. bytes at start)         ~ processBF4
#   4.15 Call of Duty: World at War variant                     ~ processSDNS
#   4.16 Star Wars: The Force Unleashed variant                  ~ processSWTFU
#   4.100 others                                       ~ processScan
#   4.Xa determmine XMA stream start                        ~ getXMAstart
#   4.Xb determine chanel count                              ~ getXMACH   
# 5. Standard functions
#   5.1 Use OFFSET and SIZE to write the raw data to memory         ~ write_raw_to_mem
#   5.2 Process the raw data from MEMORY_FILE                  ~ process_raw_data
#   5.3 Add header to MEMORY_FILE (raw data) and write to disk      ~ write_raw_xma
#   5.4 Parse call (from MEMORY_FILE to MEMORY_FILE2)            ~ parse
#   5.5 Add header in MEMORY_FILE3 and write to disk as NAME      ~ XMA

# ==================================================================================================================\\
# 1. Set user variables                                                                        ||
# ---------------------                                                                        ||
#                                                                                       ||
#      TESTMODE                                                                           ||
#      Toggles between a test run (to be applied on one file only) and the final run (with user-defined settings)   ||
#      The test run writes the following data to disk (each file is named accordingly):                     ||
#      - unparsed (only adjusted header) - one file                                                ||
#      - parsed: five different block sizes, XMA1 and XMA2 - 10 files                                    ||
#      - headerless unparsed raw data (for manual testing with xma_parse)                                 ||
#      Note: if the file is multichannel, only the first channel pair is tested.                           ||
#                                                                                       ||
#      TESTXMA1               - (de-)activates testing for XMA1 in TESTMODE                           ||
#                                                                                       ||
#      TEST_ADVANCED_BLOCKSIZES   - 0 only tests for 0x8000 and 0x10000 (most common)                        ||
#                             1 additionally tests for 0x2000, 0x4000 and 0x3000 (only rare cases)         ||
#                                                                                       ||
#      COMMENTS               - set to 1 to print information what the script is currently doing            ||
#                             (for debugging)                                                ||
#                                                                                       ||
#      WRITE_UNPARSED            - 0/1 enables/disables writing the unparsed file to disk                  ||
#                             only if TESTMODE is activated or PARSE is set to 0                     ||
#                                                                                       ||
#      FREQ_DEFAULT            - take this frequency if none is found/given                           ||
#                             (might need adjusting if the resulting files from TESTMODE are undecodable   ||
#                                                                                       ||
#      ENABLE_SCAN               - 0/1 toggles a raw scan if no known type is found                        ||
#                             use with care, this is still experimental                              ||
#                                                                                       ||
#       user-defined settings (if TESTMODE is activated, these are ignored):                               ||
#      BLOCKSIZE      - corresponds to the xma_parse -b option                                       ||
#      XMAVERSION      - 2 or 1 possible (corresponds to the xma_parse -1/2 option)                        ||
#      PARSE         - decide whether to parse or just manipulate the header to toWAV standard               ||
#                    note:   PARSE 0, CH > 2 => TESTMODE activated!                                    ||
#                        that means you should check your settings and parse all input files               ||
#                                                                                       ||
# ==============================================================================================//


# ==========================\
# 2. Get/set some standards | ---------------------------------------------------------------------------------------
# ==========================/

get BNAME basename
get FSIZE asize
set WRITEUXMA 0 # write unparsed, headerless XMA to disk (for debugging)
set RNAME "" # initialize retrieved name

# ==============================================================\
# 3. identify XMA file type and link to according process lists | ------------------------------
# ==============================================================/

# identify by 4byte string ident
getDstring IDENT 4
if IDENT == "RIFF"
   callfunction processRIFF 1
elif IDENT == "RIFX"
   # endianness is determined in getSpecsRIFF
   callfunction processRIFF 1
elif IDENT == "xma" # e.g. Fable II for Xbox 360
   set INFO 0x18
   callfunction processRIFF 1
elif IDENT == "PSB" # some XBLA games
   callfunction processPSB 1
elif IDENT == "XWV " # some XBLA games
   callfunction processXWV 1
elif IDENT == "XNBx" # Microsoft XNA Framework
   callfunction processXNB 1
elif IDENT == "FFIR" # reversed XMA (e.g. Resident Evil 6)
   set TESTMODE 0
   set PARSE 0
   callfunction processFFIR 1
elif IDENT == "FUNl"
   callfunction processFUNl 1
elif IDENT == "MUSX"
   callfunction processMUSX 1
elif IDENT == "RAKI"
   set BIAS 0
   callfunction processRAKI 1
elif IDENT == "SDNS"
   callfunction processSDNS 1
endif

# identify by extension - CHANGE THAT!!!
set CONT 0
get IDENT extension
if IDENT == "SoundNodeWave"
   set TESTMODE 0
   set BLOCKSIZE 0x8000
   set PARSE 1
   callfunction processSNW 1
   cleanexit
elif IDENT == "res"
   callfunction processEAXMA 1
   cleanexit
elif IDENT == "sps"
   callfunction processEAXMA 1
   cleanexit
elif IDENT == "sns"
   callfunction processEAXMA 1
elif IDENT == "swa"
   goto 0x50
   get TEST long
   if TEST == 0
      callfunction processSWTFU 1
      cleanexit
   endif
endif

# identify by other heuristics
goto 0
get IDENT longlong
if IDENT == 0x20000
   callfunction process5thGraderXMA 1
   cleanexit
endif
goto 0
get IDENT long
if IDENT == 0x2fa9c056 # STR with MP3 included
   print "File contains MP3 stream. Aborting."
   cleanexit
elif IDENT == 0x34000000
   callfunction processSTR 1
   cleanexit
elif IDENT == 0x09000000 # raki from error-extract of Rayman: Legends
   idstring "RAKI"
   set BIAS 4
   callfunction processRAKI 1
   cleanexit
elif IDENT == 0x0100
   goto 8
   get TEST short
   if TEST == 0x48
      callfunction processBF4 1
      cleanexit
   endif
endif
goto 6
get TEST byte
if TEST == 0xfc
   callfunction processXMAheaderless 1
   cleanexit
endif

goto 0xc
get OFFSET long
reverselong OFFSET
math OFFSET += 0x16
get FSIZE asize
if OFFSET >= FSIZE
   set CONT 1
elif OFFSET < 0
   set CONT 1
else
   goto OFFSET
   get TEST byte
   if TEST == 0xfc
      callfunction processQ4 1
      cleanexit
   else
      set CONT 1
   endif
endif

#if CONT == 1
#   if ENABLE_SCAN == 1
#      callfunction processScan 1
#   endif
#endif


# ================================\
# 4. process different file types | ---------------------------------------------------------------------------------------------
# ================================/

   # ======================\
   # 4.0 headerless XMA   |
   # ======================/
   startfunction processXMAheaderless 1
      if COMMENTS == 1
         print "processing headerless XMA"
      endif
      set OFFSET 0
      get SIZE asize
      set FREQ FREQ_DEFAULT
      set CH CH_DEFAULT
      callfunction write_raw_to_mem 1
      callfunction getXMACH 1
      callfunction process_raw_data 1
   endfunction
   
   # ======================\
   # 4.1 RIFF/RIFX header   |
   # ======================/
   startfunction processRIFF
      if COMMENTS == 1
         print "Processing header (4.1 processRIFF)"
      endif
      goto 0xc
      getDstring TEST 4
      if TEST == "XMA2"
         FindLoc OFFSET string "data" 0 ""
         math OFFSET += 4
         goto OFFSET
         get SIZE long
         math OFFSET += 4
         set TESTMODE 0
         set XMAVERSION 2
         set PARSE 1
         goto 0x20
         endian big
         get FREQ long
         endian little
         goto 0x3c
         get CH byte
      else
         callfunction getDatastartRIFF 1
         if OFFSET == 0x14
            set XMA2OFF OFFSET
            math XMA2OFF += SIZE
            goto XMA2OFF
            getDstring XMA2IDENT 4
            reverseLong SIZE # because it's reversed inif XMA2IDENT == "XMA2"
            set INFO XMA2OFF
            math INFO += 0x8
            set TESTXMA1 0
            set XMAVERSION 2
            callfunction getSpecsRIFF 1
            callfunction getCueRIFF 1
         else # no XMA2 info at end
            set INFO 0x14
            callfunction getSpecsRIFF 1
            callfunction getCueRIFF 1
         endif
      endif
      if SIZE > FSIZE
         get SIZE asize
         math SIZE -= OFFSET
      endif
      endian little
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction   
      
      # ==============================================================\
      # 4.1a get stream start and stream size from "data" section      |
      # ==============================================================/      
      startfunction getDatastartRIFF
         if COMMENTS == 1
            print "Getting stream start (4.1a)"
         endif
         goto 0
         do
            findLoc OFFSET string "data" 0 ""
            goto OFFSET
            idstring "data"
            get SIZE long
         while SIZE == 0 # skip marker section to find stream size
         math OFFSET += 0x8
            goto OFFSET
            get TEST long
            if TEST == 2 # Ubisoft header
               callfunction getXMAstart 1
               set OFFSET XOFFSET
               get SIZE asize
               math SIZE -= OFFSET
            endif
         if COMMENTS == 1
            print "data start with size %SIZE% found at %OFFSET%"
         endif
         set TEST FSIZE
         math TEST -= SIZE
         if TEST < OFFSET # wrong stream size in header
            set SIZE FSIZE
            math SIZE -= OFFSET
         endif
      endfunction
      
      # ==========================================================\
      # 4.1b. RIFF header with codec ascii sign at offset INFO   |
      # ==========================================================/
      startfunction getSpecsRIFF
         if COMMENTS == 1
            print "getting stream specs (4.1b getSpecsRIFF)"
         endif
         goto INFO
         get CODE short
         if CODE == 0x165
            math INFO += 0x10
            goto INFO
            get FREQ long
            math INFO += 0xd
            goto INFO
            get CH byte
         elif CODE == 0x166
            get CH short
            get FREQ long
         elif CODE == 0x6601 # RIFX header or big endian SNW
            endian big
            reverseLong SIZE
            get CH short
            get FREQ long
            endian little
         elif CODE == 0x104 # e.g. XMA2 with spesc at end
            endian big
            reverseLong SIZE
            math INFO += 0xc
            goto INFO
            get FREQ long
            math INFO += 0x1c
            goto INFO
            get CH byte
         elif CODE == 0x401
            endian big
            reverseLong SIZE
            math INFO += 0xc
            goto INFO
            get FREQ long
            math INFO += 0x1c
            goto INFO
            get CH byte
         else
            print "Error: No XMA code found at designated offset (%INFO%).  Aborting all operations."
            cleanexit
         endif
      endfunction
      
      # ==============================\
      # 4.1c Extract RIFF cue markers   |
      # ==============================/         
      startfunction getCueRIFF
         if COMMENTS == 1
            print "extracting marker section"
         endif
         goto 0
         if CODE == 0x6601
            endian big
         endif
         findLoc MARKERS string "cue " 0 ""
         if MARKERS != ""
            if MARKERS < OFFSET # in header
               goto MARKERS
               idstring "cue "
               get CSIZE long
               math CSIZE += 8
               append
               log MEMORY_FILE MARKERS CSIZE
               append
               math MARKERS += CSIZE
               goto MARKERS
               getDstring IDENT 4
               if IDENT == "LIST"
                  get CSIZE long
                  math CSIZE += 8
                  append
                  log MEMORY_FILE MARKERS CSIZE
                  append
               endif
               math MARKERS += 0x18
               goto MARKERS
               get RNAME string
               if RNAME != ""
                  string BNAME += "~"
                  string BNAME += RNAME
               endif
               get CSIZE asize MEMORY_FILE
               set CNAME BNAME
               string CNAME += ".XMAcue"
               log CNAME 0 CSIZE MEMORY_FILE
            else
               if COMMENTS == 1
                  print "no cue section found"
               endif
            endif
         endif
         if COMMENTS == 1
            print "no cue section found"
         endif
         endian little
      endfunction
      
   # ==============================================\
   # 4.2 UT3 Engine *.SoundNodeWave (two types)   |
   # ==============================================/
   startfunction processSNW
      if COMMENTS == 1
         print "processing UT3 XMA"
      endif
      findLoc TEST string "XMA2" 0 ""
      if TEST != ""
         print "XMA2 found"
         callfunction SNWXMA2 1
      endif
      callfunction getInfoSNW 1 # get INFO variable
      if SNWVARIANT == 0 # get stream specs, extract cue section
         set OFFSET INFO
         math OFFSET += 0x34
         callfunction getSpecsRIFF 1
         get SIZE asize
         math SIZE -= 0x10
         goto SIZE
         get TEST long
         if TEST != 0
            math SIZE += 0x10
         endif
         math SIZE -= OFFSET
         callfunction getCueSNW 1
      elif SNWVARIANT == 1
         callfunction SNWvariant 1
      endif
      callfunction write_raw_to_mem 1
      callfunction getXMAch 1
      callfunction process_raw_data 1
   endfunction
   
      # ==============================================================\
      # 4.2a Get INFO variable for RIFF header or determine variant   |
      # ==============================================================/
      startfunction getInfoSNW
         set SNWVARIANT 0
         get FSIZE asize
         goto 0x10
         callfunction getXMAstart 1
         math XOFFSET -= 0x34
         if XOFFSET <= 0
            math XOFFSET += 0x3f
            goto XOFFSET
            callfunction getXMAstart 1
            math XOFFSET -= 0x34
         endif
         goto XOFFSET
         savepos INFO
         get CODE short
         if CODE == 0x165
         elif CODE == 0x166
         elif CODE == 0x6601
         elif CODE == 0x6601
         elif CODE == 0x104
         elif CODE == 0x401
         else
            set SNWVARIANT 1
         endif
      endfunction

      # ==================================\
      # 4.2b Get specs from variant type   |
      # ==================================/
      startfunction SNWVariant
         set TESTXMA2 0
         endian big
         goto 0xa0
         get STREAMSIZE long
         if STREAMSIZE <= 0x10
            goto 0xbc
            get STREAMSIZE long
         endif
         if STREAMSIZE <= 0x10
            goto 0xd8
            get STREAMSIZE long
         endif
         get FSIZE asize
         math FSIZE -= 8
         goto FSIZE
         get TEST long
         if TEST == 0
            math FSIZE -= 8 # last 0x10 are dummy bytes
         else
            math FSIZE += 8
         endif
         set DATASTART FSIZE
         math DATASTART -= STREAMSIZE
         goto DATASTART
         get IDENT long
         if IDENT != 0x2c
            print "Error: No XMA found in file. Aborting"
            get NAME basename
            string NAME += " - VARIANT"
            get SIZE asize
            log NAME 0 SIZE
            cleanexit
         else
            get SEEKSIZE long
            math DATASTART += 0x18
            goto DATASTART
            get FREQ long
            savepos OFFSET
            math OFFSET += 0x1c
            math OFFSET += SEEKSIZE
            set SIZE FSIZE
            math SIZE -= OFFSET
            endian little
         endif
      endfunction
      
      # ==================================\
      # 4.2c Write SNW header to disk      | * needs to be converted to standard cue or smpl section *
      # ==================================/      
      startfunction getCueSNW
         goto 0
         FindLoc TEST string "Loop_Start" 0 ""
         if TEST != ""
            set CSIZE OFFSET
            math CSIZE -= 0x5c
            set NAME BNAME
            string NAME += ".SNW_head"
            log NAME 0 CSIZE
         endif
      endfunction

      # ==================================\
      # 4.2d search for XMA2 in SNW      |
      # ==================================/         
      startfunction SNWXMA2
         FindLoc OFFSET string "RIFF" 0 ""
         if OFFSET == ""
            print "Error: No XMA found in file. Aborting."
            cleanexit
         endif
         goto OFFSET
         idstring RIFF
         get SIZE long
         math SIZE += 8
         get NAME basename
         string NAME += ".xma"
         log NAME OFFSET SIZE # leave XMA2, no need to parse
      endfunction
   
   # ======================================\
   # 4.3 PSB header (various XBLA games)   | * needs some correction *
   # ======================================/
   startfunction processPSB
      if COMMENTS == 1
         print "processing PSB"
      endif
      goto 0x14
      get INFO long
      math INFO += 0x1e
      goto INFO
      get SIZE threebyte
      savepos INFO
      callfunction getSpecsRIFF 1 # see 4.1a
      savepos OFFSET
      math OFFSET += 0x2c
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   

   # ==============================================================\
   # 4.4 Variant from Are You Smarter Than A 5th Grader? (XBLA)   |
   # ==============================================================/
   startfunction process5thGraderXMA
      endian big
      goto 0x30 # specs are easily accessible
      get UNK short
      get CH short
      get FREQ long
      endian little
      set OFFSET 0x800
      get SIZE asize
      math SIZE -= OFFSET
      set BLOCKSIZE 0x8000
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   
   # ==========================================================\
   # 4.5 Electronic Arts XMA variant (e.g. Battlefield series)   |
   # ==========================================================/
   startfunction processEAXMA
      if COMMENTS == 1
         print "processing EA XMA"
      endif
      goto 0
      idstring \x48\x0\x0\xc
      endian big
      get UNK short
      get FREQ short
      get UNK long
      # get layers
         savepos MYOFF
         get DUMMY long
         set i 0
         do
            math i += 1
            get TEST short
            get DUMMY short
         while TEST == 0
         math i -= 1
         set LAYERS i
         goto MYOFF
      #####################
      set LAYERS 1 ########
      #####################
      for k = 1 <= LAYERS
         log MEMORY_FILE 0 0
         set OFFSET 0xc
         for i = 1
            goto OFFSET
            get TEST short
            if   TEST == 0x4500 # end marker, no more layers -> parse
               get SIZE asize MEMORY_FILE
               putVarChr MEMORY_FILE2 SIZE 0 long
               log MEMORY_FILE2 0 0
               set CH 2
               set XMAVERSION 2
               callfunction process_raw_data 1
               cleanexit
            endif
            get SIZE short
            math SIZE -= 0xc
            get DUMMY longlong # only when 1 layer
            savepos OFFSET
            set BIAS 0
            set ADJUST OFFSET
            math ADJUST += SIZE
            goto ADJUST
            get TEST short
            if TEST == 0x4400
            elif TEST == 0x4500
            else
               goto ADJUST
               do
                  get TEST byte
                  get DUMMY2 threebyte
                  savepos SIZE2
               while TEST != 0x44
               xmath BIAS "SIZE2 - 4 - OFFSET - SIZE"
            endif
            callfunction writeEAtoMEM 1
            #set GO i
            #math GO %= LAYERS
            #if GO == k
            #   callfunction writeEAtoMEM 1
            #elif GO == 0
            #   if k == LAYERS
            #      callfunction writeEAtoMEM 1   
            #   endif
            #endif
            math OFFSET += SIZE
            math OFFSET += BIAS
         next i
      next k
   endfunction
   
   startfunction writeEAtoMEM
      goto OFFSET
      append
         log MEMORY_FILE OFFSET SIZE
      append
      get MSIZE asize MEMORY_FILE
      math MSIZE x= 0x800
      math MSIZE -= 1
      putVarChr MEMORY_FILE MSIZE 0 # write 0 at end of block   
   endfunction
   
   # ====================================================\
   # 4.6 XWV header variant (e.g. Bloody Good Time XBLA) |
   # ====================================================/
   startfunction processXWV
      if COMMENTS == 1
         print "processing XWV XMA"
      endif
      endian big
      goto 0x10
      get OFFSET long
      get SIZE long
      goto 0x2a
      get ID byte
      if ID == 2
         set FREQ 44100
      elif ID == 1
         set FREQ 22050
      elif ID == 0
         set FREQ 32000
      else
         print "Error: Unknown frequency identifier. Aborting."
         cleanexit
      endif
      get CH byte
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction

   # ==================================\
   # 4.7 Microsoft XNA Framework *.xnb |
   # ==================================/
   startfunction processXNB
      if COMMENTS == 1
         print "process XNA Framework XMA"
      endif
      callfunction getXMAstart 1
      set OFFSET XOFFSET
      set INFO 0x47
      callfunction getSpecsRIFF 1
      get SIZE asize
      math SIZE -= 0xc
      math SIZE -= OFFSET
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ======================\
   # 4.8 FFIR header (RE6)   | * no parsing needed
   # ======================/
   startfunction processFFIR 1
      if COMMENTS == 1
         print "processing reversed header XMA"
      endif
      endian big
      goto 0x16
      get CH short
      get FREQ long
      findLoc OFFSET string atad 0 ""
      math OFFSET += 4
      goto OFFSET
      get SIZE long
      savepos OFFSET
      endian little
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ==================\
   # 4.9 FUNl header   | * e.g. Men In Black: Alien Crisis
   # ==================/
   
   startfunction processFUNl
      set TESTMODE 0
      set PARSE 1
      set BLOCKSIZE 0x8000
      if COMMENTS == 1
         print "processing FUNl header XMA2"
      endif
      set OFFSET 0x800
      goto 0x22
      get CH short
      get FREQ long
      get SIZE asize
      math SIZE -= OFFSET
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ==============\
   # 4.10 MUSX      | Electronic Arts MUSX header
   # ==============/      
      
   startfunction processMUSX
      set TESTMODE 0
      set PARSE 1
      set BLOCKSIZE 0x8000
      set OFFSET 0x800
      goto 0x40
      idstring "DATB"
      get SIZE long
      goto 0x50
      get IDENT long
      if IDENT == 6
      elif IDENT == 0xff
         get SIZE asize
         get NAME filename
         string NAME += ".pcm"
         log NAME 0 SIZE
         cleanexit
      elif IDENT == 0x1 # Activision ADPCM
         cleanexit
      else
         print "Unknown MUSX content. Aborting..."
         cleanexit
      endif
      goto 0x4c
      get FREQ long
      get DUMMY long
      goto 0x8c
      get CH long
      if CH <= 6
         set BLOCKSIZE 0x10000
      endif
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   
   # ======================\
   # 4.11 Quake 4 variant   | big endian, seek table at start
   # ======================/         
   
   startfunction processQ4
      if COMMENTS == 1
         print "prosessing Quake 4 header variant"
      endif
      set TESTMODE 0
      set XMAVERSION 1
      endian big
      goto 0x4
      get CH long
      get FREQ long
      get SEEKSIZE long
      set OFFSET SEEKSIZE
      math OFFSET += 0x10
      get SIZE asize
      math SIZE -= OFFSET
      endian little
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ====================\
   # 4.12 STR variant     |
   # ====================/
   startfunction processSTR
      goto 4
      endian big
      get CODEC short
      if CODEC != 0x166
         print "ERROR: STR variant assumed but XMA identifiert at offset 4 not found. Please contact me at XeNTaX."
         cleanexit
      endif
      get CH short
      get FREQ long
      goto 0x38
      get SEARCHSIZE long
      math SEARCHSIZE += 0x40
      set OFFSET SEARCHSIZE
      get SIZE asize
      math SIZE -= OFFSET
      set PARSE 1
      set TESTMODE 0
      set XMAVERSION 2
      set ENABLE_SCAN 0
      endian little
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ==================\
   # 4.13 RAKI variant   |  Rayman: Legends
   # ==================/      
   
   startfunction processRAKI
      endian big
      goto 0x10
      if BIAS == 4
         get OFFSET long
      endif
      get OFFSET long
      math OFFSET x= 0x800
      FindLoc OFF string "data" 0 ""
      math OFF += 0xc
      goto OFF
      get CODEC short
      get CH short
      get FREQ long
      endian little
      set BLOCKSIZE 0x10000
      get SIZE asize
      math SIZE -= OFFSET
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ==================\
   # 4.14 BF4 variant   |  Battlefield 4
   # ==================/      
   
   startfunction processBF4
      endian big
      goto 0xe
      get FREQ short
      set CH 2
      endian little
   endfunction
   
   # ==================\
   # 4.15 BF4 variant   |  Battlefield 4
   # ==================/   
   
   startfunction processSDNS
      endian big
      get DUMMY long
      get FREQ long
      get CH long
      set OFFSET 0x1000
      set BLOCKSIZE 0x8000
      get SIZE asize
      math SIZE -= OFFSET
      endian little
      callfunction write_raw_to_mem 1
      callfunction process_raw_data 1
   endfunction
   
   # ==================\
   # 4.15 SWTFU variant|  Star Wars: The Force Unleashed
   # ==================/   
   
   startfunction processSWTFU
      get TSIZE asize
      if TSIZE <= 0x810
         cleanexit
      endif
      set GETCH 0xd
      set GETFREQ 0x18
      set OFFSET 0x800
      goto 0x8
      get TEST long
      if TEST != 0
         math GETCH += 0x4
         math GETFREQ += 0x4
      endif
      goto 0x806
      get TEST byte
      if TEST != 0xfc
         math OFFSET += 0x4
      endif
      endian big
      goto GETCH
      get LAYERS byte
      if LAYERS == 3
         set CH 6
      else
         set CH ""
      endif
      goto GETFREQ
      get FREQ long
      set BLOCKSIZE 0x10000
      get SIZE asize
      math SIZE -= OFFSET
      set XMAVERSION 2
      endian little
      callfunction write_raw_to_mem 1
      if CH == ""
         callfunction getXMACH 1
      endif
      callfunction process_raw_data 1
   endfunction
   
   # ==================\
   # 4.100 Others      | * scan for possible XMA start
   # ==================/   
   
   startfunction processScan
      print "scanning for possible XMA stream starts..."
      get BNAME basename
      string BNAME += "_"
      set SCAN 1
      set SOFF 0 # search offset
      get FSIZE asize
      for s = 0
         set QUIT 0
         if SOFF < FSIZE
            goto SOFF
            callfunction getXMAstart 1
            if XOFFSET != ""
               #print "-> possible XMA start found at %XOFFSET%"
                  set NAME BNAME
                  set p s
                  math p += 1
                  string NAME += p
                  string WOFF p= "_0x%08x" XOFFSET
                  string NAME += WOFF
                  string NAME += ".rxma" # raw xma
                  get SIZE asize
                  math SIZE -= XOFFSET
                  log NAME XOFFSET SIZE
               math SOFF += XOFFSET
               math SOFF += 0x10
            else
               set QUIT 1
            endif
         else
            set QUIT 1
         endif
         if QUIT == 1
            break # quits function
         endif
      next s
   endfunction
   
   
   # ==================================\
   # 4.Xa determmine XMA stream start   |
   # ==================================/
   startfunction getXMAstart
      if COMMENTS == 1
         print "determining XMA stream start"
      endif
      for
         set CONT 1 # continue?
         FindLoc XOFFSET string \xfc 0 ""
         if XOFFSET == ""
            if SCAN == 1
               set CONT 0
            else
               print "Error: No XMA stream start found.  Aborting all operations."
               cleanexit
            endif
         endif
         if CONT == 1
            #print "0xfc found at %XOFFSET%"
            goto XOFFSET
            get DUMMY byte # 0xfc
            get TEST byte
            if TEST == 0
            elif TEST == 1
            elif TEST == 3
            else
               set CONT 0
            endif
         endif
         if CONT == 1
            math XOFFSET -= 6
            goto XOFFSET
            get TEST byte
            if TEST == 0 # no XMA start - continue testing heuristics
               set CONT 0
            endif
            get DUMMY byte
         endif
         if CONT == 1
            get TEST2 short
            if TEST2 == 0
            elif TEST2 == 1
            elif TEST2 == 0x101
            else
               set CONT 0
            endif
         endif
         if CONT == 1    # all test came back positive, so...
            break       # ... XOFFSET stays (break -> quit function)
         else
            math XOFFSET += 8 # jump after non-XMA 0xfc
         endif
         if XOFFSET >= FSIZE
            if SCAN == 1 # in case of source file scan -> just return not-found identifier
               set XOFFSET ""
               break
            else
               print "Error: No XMA stream start found.  Aborting all operations."
               cleanexit
            endif
         else
            goto XOFFSET # continue search from after last found 0xfc that was no XMA start
         endif
      next
   endfunction
   
   
   # ==================================\
   # 4.Xb determine chanel count      |
   # ==================================/   
   startfunction getXMACH # inside MEMORY_FILE!
      if COMMENTS == 1
         print "detecting channel count"
      endif
      set CHOFF 7
      goto CHOFF MEMORY_FILE
      get IDENT byte MEMORY_FILE
      if IDENT == 1
         set CH 2
      elif IDENT == 3
         set CH 1
      elif IDENT == 0 # e.g. from multichannel stream
         set CH 2
      else
         print "ERROR: Not able to auto-determine channel count! Aborting all operations."
         cleanexit
      endif
   endfunction
   
   
   
# ======================\
# 5. Standard functions | -----------------------------------------------------------------------------------------------------------
# ======================/

   # ==========================================================\
   # 5.1 Use OFFSET and SIZE to write the raw data to memory   |
   #     (not needed for EA XMA without filler blocks)         |
   # ==========================================================/
   startfunction write_raw_to_mem
      if COMMENTS == 1
         print "writing raw stream to memory (5.1 write_raw_to_mem)"
      endif
      putVarChr MEMORY_FILE SIZE 0 long
      log MEMORY_FILE 0 0
      putVarChr MEMORY_FILE2 SIZE 0 long
      log MEMORY_FILE2 0 0
      append
      log MEMORY_FILE OFFSET SIZE
      append
   endfunction
   
   # ==========================================\
   # 5.2 Process the raw data from MEMORY_FILE |
   # ==========================================/
   startfunction process_raw_data
      if COMMENTS == 1
         print "processing raw stream (5.2 process_raw_data)"
      endif
      if CH > 2
         if PARSE == 0 # that combination doesn't happen -> run in test mode instead
            set TESTMODE 1
         endif
      elif CH == ""
         callfunction getXMACH 1
      endif
      get SIZE asize MEMORY_FILE
      if TESTMODE == 1 # write all possible combinations
         get NAME basename
         string NAME += " -unparsed.uxma" # raw data without header
         log NAME 0 SIZE MEMORY_FILE
         if WRITE_UNPARSED == 1
            callfunction write_raw_xma 1 # raw data with header (determined specs)
         endif
         if PARSE == 1
            callfunction parse 1
         endif
      elif TESTMODE == 0
         if PARSE == 1
            if WRITE_UNPARSED == 1
               get NAME basename
               string NAME += ".uxma" # raw data without header
               log NAME 0 SIZE MEMORY_FILE
            endif
            callfunction parse 1
         elif PARSE == 0 # add header to raw data
            callfunction write_raw_xma 1
         endif
      endif
   endfunction
   
   # ===========================================================\
   # 5.3 Add header to MEMORY_FILE (raw data) and write to disk |
   # ===========================================================/
   startfunction write_raw_xma
      if COMMENTS == 1
         print "writing raw data from MEM to MEM2"
      endif
      get SIZE asize MEMORY_FILE # write to MEMORY_FILE2 for XMA header call
      log MEMORY_FILE2 0 SIZE MEMORY_FILE
      get NAME basename
      if TESTMODE == 1
         string NAME += " -unparsed.uxma"
      endif
      string NAME += ".xma"
      callfunction XMA 1 # add header and write to disk
   endfunction
   
   # ==================================================\
   # 5.4 Parse call (from MEMORY_FILE to MEMORY_FILE2) |
   # ==================================================/
   startfunction parse
      if COMMENTS == 1
         print "parsing"
      endif
      endian little # just to be sure ;)
      if TESTMODE == 1 # test different block sizes
         putArray 0 0 0x8000 long # TESTRUN 1
         putArray 1 0 0x10000 long # TESTRUN 2
         if TEST_ADVANCED_BLOCKSIZES == 0
            set TESTRUNS 2
         elif TEST_ADVANCED_BLOCKSIZES == 1
            putArray 2 0 0x20000 long # TESTRUN 3 (rare)
            putArray 3 0 0x40000 long # TESTRUN 4 (very rare)
            putArray 4 0 0x3000  long # TESTRUN 5 (extremely rare)
            set TESTRUNS 5
         endif
         set LOOPS 1 # only one run, no matter how many actual channels
         if TESTXMA1 == 1
            set XMATESTS 2 # test both XMA1 and XMA2
         elif TESTXMA1 == 0
            set XMATESTS 1 # only test XMA2
         endif
      elif TESTMODE == 0 # only parse all channels when TESTRUN is deactivated
         set TESTRUNS 1 # don't try blocksizes
         set THREECH 0
         if CH > 2
            if CH == 3
               set LOOPS 2
               set THREECH 1
            else # 6ch / 8ch etc.
               set LOOPS CH
               math LOOPS /= 2
            endif
            set CH 2
         else
            set LOOPS 1
         endif
         set XMATESTS 1 # use only the given XMA version
      endif
      for i = 0 < TESTRUNS # loop changes blocksize if TESTMODE is activated
         if TESTRUNS > 1 # otherwise use the user-defined blocksize
            getArray BLOCKSIZE i 0
         endif
         string BLOCKSIZE p= "%08x" BLOCKSIZE
         for l = 1 <= LOOPS # loop for channel pairs
            for x = 1 <= XMATESTS # note that this is 1 when TESTMODE or TESTXMA1 is deactivated
               set FUNCCALL string "xma_parse.exe #INPUT# -b 0x"
               string FUNCCALL += BLOCKSIZE
               string FUNCCALL += " -"
               if TESTMODE == 1
                  if TESTXMA1 == 1
                     string FUNCCALL += x # changes between 1 and 2
                  elif TESTXMA1 == 0
                     string FUNCCALL += 2 # only test XMA2
                  endif
               elif TESTMODE == 0
                  string FUNCCALL += XMAVERSION
               endif
               string FUNCCALL += " -o "
               set OFF l # changes with channel loops
               math OFF -= 1
               math OFF *= 0x800
               string OFF p= "0x%08x" OFF
               string FUNCCALL += OFF
               string FUNCCALL += " -r #OUTPUT#"
               comtype EXECUTE FUNCCALL
               log MEMORY_FILE2 0 0
               clog MEMORY_FILE2 0 SIZE SIZE MEMORY_FILE # from mem [to temp] to mem2 (mem stays)
               encryption "" ""
               #get NAME basename
               #get NAME2 basename
               #string NAME += ".mem"
               #string NAME2 += ".mem2"
               #get SIZE asize MEMORY_FILE
               #get SIZE2 asize MEMORY_FILE2
               #log NAME 0 SIZE MEMORY_FILE
               #log NAME2 0 SIZE2 MEMORY_FILE2
               set NAME BNAME
               if TESTMODE == 1 # then TESTRUNS == 5
                  string NAME += " -b 0x"
                  string NAME += BLOCKSIZE
                  string NAME += " -"
                  if TESTXMA1 == 1
                     string NAME += x
                  elif TESTXMA1 == 0
                     string NAME += 2
                  endif
               endif
               if LOOPS != 1 # multichannel file (only when TESTMODE is deactivated)
                  set NUM l
                  string NAME += "_"
                  string NAME += NUM
               endif
               string NAME += ".xma"
               get MSIZE asize MEMORY_FILE2
               if MSIZE != 0
                  if l == 2
                     if THREECH == 1
                        set CH 1
                     endif
                  endif
                  callfunction XMA 1 # add header and write to disk
               endif
            next x   # xma version loop
         next l      # channel loop
      next i         # blocksize loop
   endfunction
   
   # ==========================================================\
   # 5.5 Add header in MEMORY_FILE3 and write to disk as NAME   |
   # ==========================================================/
   startfunction XMA # variant of standard function (mem2 to mem3)
      if COMMENTS == 1
         print "adding header"
      endif
      get MSIZE asize MEMORY_FILE2
      set RIFFSIZE MSIZE
      math RIFFSIZE += 0x34
      set PRESIZE RIFFSIZE # pre-alloc
      math PRESIZE += 0x38
      putVarChr MEMORY_FILE3 PRESIZE 0
      log MEMORY_FILE3 0 0
      set MEMORY_FILE3 binary "\x52\x49\x46\x46\xb8\x59\xa7\x00\x57\x41\x56\x45\x66\x6d\x74\x20\x20\x00\x00\x00\x65\x01\x10\x00\xd6\x10\x00 \x00\x01\x00\x00\x03\xe3\x9a\x00\x00\x80\xbb\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\ x02\x02\x00\x64\x61\x74\x61\x00\x58\xa7\x00"
      putVarChr MEMORY_FILE3 0x04 RIFFSIZE long
      putVarChr MEMORY_FILE3 0x24 FREQ long
      putVarChr MEMORY_FILE3 0x31 CH byte
      putVarChr MEMORY_FILE3 0x38 MSIZE long
      append
      log MEMORY_FILE3 0 MSIZE MEMORY_FILE2
      append
      if NAME == ""
         get NAME basename
         string NAME += ".xma"
      endif
      get M3_SIZE asize MEMORY_FILE3
      log NAME 0 M3_SIZE MEMORY_FILE3
   endfunction
      
   
# ==================================================
# E-N-D    O-F    S-C-R-I-P-T
# ==================================================


XMA Converting (requires decrypted XMA and FFMPEG)
Code:
quickbms.exe -o script.bms inputfiles\
pause
MOVE /y *.xma inputfiles\
pause
@echo off
SET /P ANSWER=1.MP3  2.WAVE  3.FLAC 4.WMA 5.OGG(1/2/3/4/5)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mp3)
 if /i {%ANSWER%}=={2} (goto :wave)
 if /i {%ANSWER%}=={3} (goto :flac)
 if /i {%ANSWER%}=={4} (goto :wma)
 if /i {%ANSWER%}=={5} (goto :ogg)
 
:MP3
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn -ab 320k  "newfiles\%%~na.mp3"
pause
exit /b 0

:FLAC
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.flac"
pause
exit /b 0

:WAVE
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.wav"
pause
exit /b 0

:WMA
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.wma"
pause
exit /b 0

:OGG
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.ogg"
pause
exit /b 0


Everything Else (major audio and video formats requires FFMPEG, XWMAEncode, DShow)
Code:
@echo off
 
SET /P ANSWER=1.MP4  2.MKV  3.AVI 4.WMV 5.MPEG1 6.MPEG2 7.XMV 8.AUDIO 9.MERGE 10.CAP 11.BIK 12.GIF(1/2/3/4/5/6/7/8/9/10/11/12)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :1)
 if /i {%ANSWER%}=={2} (goto :2)
 if /i {%ANSWER%}=={3} (goto :3)
 if /i {%ANSWER%}=={4} (goto :4)
 if /i {%ANSWER%}=={5} (goto :5)
 if /i {%ANSWER%}=={6} (goto :6)
 if /i {%ANSWER%}=={7} (goto :7)
 if /i {%ANSWER%}=={8} (goto :8)
 if /i {%ANSWER%}=={9} (goto :9)
 if /i {%ANSWER%}=={10} (goto :10)
 if /i {%ANSWER%}=={11} (goto :11)
 if /i {%ANSWER%}=={12} (goto :12)


:1
SET /P ANSWER=1.Very Slow  2.Slow  3.Medium 4.Fast 5.Very Fast(1/2/3/4/5)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mp4us)
 if /i {%ANSWER%}=={2} (goto :mp4s)
 if /i {%ANSWER%}=={3} (goto :mp4m)
 if /i {%ANSWER%}=={4} (goto :mp4f)
 if /i {%ANSWER%}=={5} (goto :mp4uf)

:2
SET /P ANSWER=1.Very Slow  2.Slow  3.Medium 4.Fast 5.Very Fast(1/2/3/4/5)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mkvus)
 if /i {%ANSWER%}=={2} (goto :mkvs)
 if /i {%ANSWER%}=={3} (goto :mkvm)
 if /i {%ANSWER%}=={4} (goto :mkvf)
 if /i {%ANSWER%}=={5} (goto :mkvuf)

:3
SET /P ANSWER=1.Very Slow  2.Slow  3.Medium 4.Fast 5.Very Fast(1/2/3/4/5)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :avius)
 if /i {%ANSWER%}=={2} (goto :avis)
 if /i {%ANSWER%}=={3} (goto :avim)
 if /i {%ANSWER%}=={4} (goto :avif)
 if /i {%ANSWER%}=={5} (goto :aviuf)

:5
SET /P ANSWER=1.Very Slow  2.Slow  3.Medium 4.Fast 5.Very Fast(1/2/3/4/5)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mp1us)
 if /i {%ANSWER%}=={2} (goto :mp1s)
 if /i {%ANSWER%}=={3} (goto :mp1m)
 if /i {%ANSWER%}=={4} (goto :mp1f)
 if /i {%ANSWER%}=={5} (goto :mp1uf)

:6
SET /P ANSWER=1.Very Slow  2.Slow  3.Medium 4.Fast 5.Very Fast(1/2/3/4/5)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mp2us)
 if /i {%ANSWER%}=={2} (goto :mp2s)
 if /i {%ANSWER%}=={3} (goto :mp2m)
 if /i {%ANSWER%}=={4} (goto :mp2f)
 if /i {%ANSWER%}=={5} (goto :mp2uf)

:8
SET /P ANSWER=1.MP3  2.WAVE  3.FLAC 4.WMA 5.OGG 6.XBOX PCM 7.XWMA 8.ADW(1/2/3/4/5/6/7/8)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mp3)
 if /i {%ANSWER%}=={2} (goto :wave)
 if /i {%ANSWER%}=={3} (goto :flac)
 if /i {%ANSWER%}=={4} (goto :wma)
 if /i {%ANSWER%}=={5} (goto :ogg)
 if /i {%ANSWER%}=={6} (goto :XBOX)
 if /i {%ANSWER%}=={7} (goto :XWMA)
 if /i {%ANSWER%}=={8} (goto :ADW)
 


:mp4us
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset veryslow -crf 5 -c:a aac -b:a 128k "newfiles\%%~na.mp4"
pause
exit /b 0

:mp4s
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset slow -crf 7 -c:a aac -b:a 128k "newfiles\%%~na.mp4"
pause
exit /b 0

:mp4m
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset medium -crf 10 -c:a aac -b:a 128k "newfiles\%%~na.mp4"
pause
exit /b 0

:mp4f
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset fast -crf 15 -c:a aac -b:a 128k "newfiles\%%~na.mp4"
pause
exit /b 0

:mp4uf
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset ultrafast -crf 20 -c:a aac -b:a 128k "newfiles\%%~na.mp4"
pause
exit /b 0

:mkvus
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset veryslow -crf 5 -c:a ac3 -b:a 640k "newfiles\%%~na.mkv"
pause
exit /b 0

:mkvs
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset slow -crf 7 -c:a ac3 -b:a 640k "newfiles\%%~na.mkv"
pause
exit /b 0

:mkvm
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset medium -crf 10 -c:a ac3 -b:a 640k "newfiles\%%~na.mkv"
pause
exit /b 0

:mkvf
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset fast -crf 15 -c:a ac3 -b:a 640k "newfiles\%%~na.mkv"
pause
exit /b 0

:mkvuf
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v libx264 -preset ultrafast -crf 20 -c:a ac3 -b:a 640k "newfiles\%%~na.mkv"
pause
exit /b 0

:avius
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg4 -vtag xvid -qscale:v 1 -preset veryslow  -c:a adpcm_ima_wav "newfiles\%%~na.AVI"
pause
exit /b 0

:avis
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v dv -qscale:v 1 -preset slow -c:a pcm_s16le "newfiles\%%~na.AVI"
pause
exit /b 0

:avim
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg4 -vtag xvid -qscale:v 1 -preset medium  "newfiles\%%~na.AVI"
pause
exit /b 0

:avif
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg4 -vtag xvid -qscale:v 1 -preset fast  "newfiles\%%~na.AVI"
pause
exit /b 0

:aviuf
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg4 -vtag xvid -qscale:v 1 -preset ultrafast  "newfiles\%%~na.AVI"
pause
exit /b 0

:4
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v wmv2 -qscale:v 1 -preset veryslow -c:a pcm_u8 "newfiles\%%~na.wmv"
pause
exit /b 0

:mp1us
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg1video -preset veryslow -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp1s
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg1video -preset slow -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp1m
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg1video -preset medium -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp1f
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg1video -preset fast -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp1uf
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg1video -preset ultrafast -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp2us
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg2video -preset veryslow -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp2s
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg2video -preset slow -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp2m
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg2video -preset medium -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp2f
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg2video -preset fast -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:mp2uf
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -c:v mpeg2video -preset ultrafast -crf 20 -c:a mp2 -b:a 128k "newfiles\%%~na.mpeg"
pause
exit /b 0

:MP3
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn -ab 320k  "newfiles\%%~na.mp3"
pause
exit /b 0

:FLAC
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.flac"
pause
exit /b 0

:WAVE
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.wav"
pause
exit /b 0

:XBOX
for %%a in ("inputfiles\*.wav") do xbadpcmencode "%%a" "newfiles\%%~na.wav"
pause
exit /b 0

:XWMA
for %%a in ("inputfiles\*.wav") do xwmaencode "%%a" "newfiles\%%~na.xwma"
pause
exit /b 0

:ADW
for %%a in ("inputfiles\*.wav") do xwmaencode "%%a" "newfiles\%%~na.adw"
pause
exit /b 0

:WMA
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.wma"
pause
exit /b 0

:OGG
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -vn "newfiles\%%~na.ogg"
pause
exit /b 0

:9
SET /P ANSWER=1.VTS  2.VOB  3.MP4 4.MKV 5.WMV 6.MPEG1 7.MPEG2 8.AVI(1/2/3/4/5/6/7/8)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :mergeVTS)
 if /i {%ANSWER%}=={2} (goto :mergeVOB)
 if /i {%ANSWER%}=={3} (goto :mergeMP4)
 if /i {%ANSWER%}=={4} (goto :mergeMKV)
 if /i {%ANSWER%}=={5} (goto :mergeWMV)
 if /i {%ANSWER%}=={6} (goto :mergeMPEG1)
 if /i {%ANSWER%}=={7} (goto :mergeMPEG2)
 if /i {%ANSWER%}=={6} (goto :mergeAVI)

:mergeVTS
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.vts
pause
exit /b 0

:mergeVOB
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.vob
pause
exit /b 0

:mergeMP4
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.MP4
pause
exit /b 0

:mergeMKV
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.mkv
pause
exit /b 0

:mergeWMV
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.wmv
pause
exit /b 0

:mergeMPEG1
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.mpeg
pause
exit /b 0

:mergeMPEG2
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.mpeg
pause
exit /b 0

:mergeAVI
start mylist.txt
pause
ffmpeg -f concat -i mylist.txt -c copy mergedfile.avi
pause
exit /b 0

:7
SET /P ANSWER=1.WMV2XMV  2.WMV2XMVna  3.MERGEXMV(1/2/3)?
 echo You chose: %ANSWER%
 if /i {%ANSWER%}=={1} (goto :WMV2XMV)
 if /i {%ANSWER%}=={2} (goto :WMV2XMVna)
 if /i {%ANSWER%}=={3} (goto :mergeXMV)

:WMV2XMV
echo This will convert  WMV8 with WMA9 audio to XMV. Will convert all WMV in the inputfiles folder
pause
for %%a IN ("inputfiles\*.wmv") do xmvtool -i "%%a" -o "newfiles\%%~na.xmv"
pause
exit /b 0

:10
ffmpeg -f dshow -i video="screen-capture-recorder" -f dshow -i  audio="virtual-audio-capturer" -qscale:v 1 -preset fast output.avi
pause

:mergeXMV
echo This will merge a WMV8 and WAV to XMV. Must be named video.wmv and audio.wav. Can only do 1 at a time
pause
xmvtool -v "inputfiles\video.wmv" -a "inputfiles\audio.wav" -o Merged.xmv
pause
exit /b 0

:WMV2XMVna
echo This will convert a WMV8 to XMV with no audio
pause
for %%a IN ("inputfiles\*.wmv") do xmvtool -v "%%a" -o "newfiles\%%~na.xmv"
pause
exit /b 0

:11
echo This will convert all videos to BIK
pause
for %%a in ("inputfiles\*.*") do binkc "%%a" "newfiles\%%~na.bik" /#
pause
exit /b 0

:12
echo this will convert all videos to GIF. WARNING this will do the entire video so make sure the videos are exactly as you want the GIF
pause
for %%a in ("inputfiles\*.*") do ffmpeg -i "%%a" -b 2048k  "newfiles\%%~na.gif"
pause
exit /b 0


Enjoy and dont get to much of a headache trying to read all that Very Happy

Pre-built download links
http://www.mediafire.com/folder/1f1z1ar5jb601/Batch22b


View user's profile Send private message
 
 
 
 
forahobby
Administrator
Administrator




Joined: May 22, 2003
Posts: 22995
Location: NSW, Australia

Post Posted: Thu Feb 01, 2018 1:43 pm   
Post subject:
Reply with quote
 
thanks for sharing!
_________________
HQ Network - Xbox - Xbox 360 - Xbox One
Registered HQ Network users can access all of our websites using the one username and password.


View user's profile Send private message Send e-mail
 
 
 
 
KIxxx
Xbox-HQ Member
Xbox-HQ Member




Joined: May 28, 2017
Posts: 99
Location: Canada

Post Posted: Sat Feb 03, 2018 10:04 pm   
Post subject:
Reply with quote
 
forahobby wrote:
thanks for sharing!


No worries. Sadly my best script got nuked when I lost that WD Blue HDD. Was gonna be my retirement so to speak. NetBuilder. Was XBINS on roids meets Babylon/AID. Download everything XBOX from your desktop, certificate generator for Dropbox and Mediafire so you got the Paid Member speed not the crappy free speed and custom installer builds. You picked exactly what you wanted Gamesave or XBOXHDM or DVD installer. What dash, what mod, what emus etc and it downloaded just those things and made the installer for you, make the iso for you, pretty much everything short of wiping your rump for ya.


I


View user's profile Send private message
 
 
 
 
AdmiralShlong
Xbox-HQ Experienced
Xbox-HQ Experienced



Xbox Version: 1.1 & 360E 500
Modded: X-DU Alpha ModChip

Joined: Oct 01, 2014
Posts: 102
Location: CA, USA

Post Posted: Mon Feb 05, 2018 10:48 pm   
Post subject:
Reply with quote
 
Nice work! Any hope for a return of NetBuilder?
_________________
320GB ST3320620A 7200RPM 16MB Cache
Gellid GC-Extreme Thermal Compound
StarTech 80 Conductor U-ATA Cable
80mm Xilence Hydro Bearing Fan
X-DU Chip & Toggle Switch
Taiyo Yuden Clock Cap
Xbox 1.1 MainBoard
XBMC 3.5.3 Dash
iND-BiOS 5004
128MB RAM


View user's profile Send private message Send e-mail
 
 
 
 
KIxxx
Xbox-HQ Member
Xbox-HQ Member




Joined: May 28, 2017
Posts: 99
Location: Canada

Post Posted: Wed Feb 07, 2018 1:26 am   
Post subject:
Reply with quote
 
AdmiralShlong wrote:
Nice work! Any hope for a return of NetBuilder?


Thanks, and doubtful. This was a Java based downloader which was a first for me. NetBuilder and DRDownloader (exact same idea as NetBuilder but for modding Dead Rising games) are the only things Ive ever written in Java so its pretty much a blank for me. If it was C/C++ I would most likely remember at least parts of it. And without the downloader I can be as fancy as I like with the control script it aint gonna do anything.

If I come across an old source file on another HDD I'll certainly revisit it or else release the source so somebody else can


View user's profile Send private message
 
 
 
 
AdmiralShlong
Xbox-HQ Experienced
Xbox-HQ Experienced



Xbox Version: 1.1 & 360E 500
Modded: X-DU Alpha ModChip

Joined: Oct 01, 2014
Posts: 102
Location: CA, USA

Post Posted: Thu Feb 08, 2018 4:40 pm   
Post subject:
Reply with quote
 
That is a crying shame. In one regard did we really need another installer disc? Unfortunately the answer is yes when taking those capabilities into consideration! A build and burn installer from java, sounds like a dream. Who knows, you might go to update or look at the architecture of DRDownloader and remeber something. The electrochemical computer that is the brain works quite oddly
_________________
320GB ST3320620A 7200RPM 16MB Cache
Gellid GC-Extreme Thermal Compound
StarTech 80 Conductor U-ATA Cable
80mm Xilence Hydro Bearing Fan
X-DU Chip & Toggle Switch
Taiyo Yuden Clock Cap
Xbox 1.1 MainBoard
XBMC 3.5.3 Dash
iND-BiOS 5004
128MB RAM


View user's profile Send private message Send e-mail
 
 
 
 
SPPV
V.I.P. Lifetime




Joined: Sep 13, 2010
Posts: 2411
Location: Kamloops BC Canada

Post Posted: Thu Feb 15, 2018 1:44 pm   
Post subject:
Reply with quote
 
AdmiralShlong wrote:
That is a crying shame. In one regard did we really need another installer disc? Unfortunately the answer is yes when taking those capabilities into consideration! A build and burn installer from java, sounds like a dream. Who knows, you might go to update or look at the architecture of DRDownloader and remeber something. The electrochemical computer that is the brain works quite oddly


I found an old test build of NetBuilder, gonna see if I can run the files through a hex editor and NASM and convert it to ASM source code and continue it

Heres a link for anybody that wants to check it out. The downloader portion if I remember correct was 90% finished so most of that part will work OK Download emus, Xtras, BIOS, DLC etc, it was just the Babylon/NetBuilder portion I hadnt finished yet.

http://www.mediafire.com/file/0a516iy78kwlln7/XtrasDownloaderTEST1.7z


EDIT
Even better news
I JUST FOUND A BACKUP OF MY SOURCE CODE

So............... Very Happy


View user's profile Send private message
 
 
 
 
AdmiralShlong
Xbox-HQ Experienced
Xbox-HQ Experienced



Xbox Version: 1.1 & 360E 500
Modded: X-DU Alpha ModChip

Joined: Oct 01, 2014
Posts: 102
Location: CA, USA

Post Posted: Fri Feb 16, 2018 2:04 am   
Post subject:
Reply with quote
 
SPPV wrote:
I found an old test build of NetBuilder, gonna see if I can run the files through a hex editor and NASM and convert it to ASM source code and continue it

Heres a link for anybody that wants to check it out. The downloader portion if I remember correct was 90% finished so most of that part will work OK Download emus, Xtras, BIOS, DLC etc, it was just the Babylon/NetBuilder portion I hadnt finished yet.

http://www.mediafire.com/file/0a516iy78kwlln7/XtrasDownloaderTEST1.7z


EDIT
Even better news
I JUST FOUND A BACKUP OF MY SOURCE CODE

So............... Very Happy


Netbuilder already!?

_________________
320GB ST3320620A 7200RPM 16MB Cache
Gellid GC-Extreme Thermal Compound
StarTech 80 Conductor U-ATA Cable
80mm Xilence Hydro Bearing Fan
X-DU Chip & Toggle Switch
Taiyo Yuden Clock Cap
Xbox 1.1 MainBoard
XBMC 3.5.3 Dash
iND-BiOS 5004
128MB RAM


View user's profile Send private message Send e-mail
 
 
 
 
SPPV
V.I.P. Lifetime




Joined: Sep 13, 2010
Posts: 2411
Location: Kamloops BC Canada

Post Posted: Fri Feb 16, 2018 11:51 am   
Post subject:
Reply with quote
 
AdmiralShlong wrote:
SPPV wrote:
I found an old test build of NetBuilder, gonna see if I can run the files through a hex editor and NASM and convert it to ASM source code and continue it

Heres a link for anybody that wants to check it out. The downloader portion if I remember correct was 90% finished so most of that part will work OK Download emus, Xtras, BIOS, DLC etc, it was just the Babylon/NetBuilder portion I hadnt finished yet.

http://www.mediafire.com/file/0a516iy78kwlln7/XtrasDownloaderTEST1.7z


EDIT
Even better news
I JUST FOUND A BACKUP OF MY SOURCE CODE

So............... Very Happy


Netbuilder already!?


As I said thats just an old test build I found and is not finished. Its what was shown in the video above. Fine for doing downloads from desktop for homebrew and emus and such, but only has very limited softmod features as thats where most of the work is and I need to finish that.


View user's profile Send private message
 
 
 
 
AdmiralShlong
Xbox-HQ Experienced
Xbox-HQ Experienced



Xbox Version: 1.1 & 360E 500
Modded: X-DU Alpha ModChip

Joined: Oct 01, 2014
Posts: 102
Location: CA, USA

Post Posted: Fri Feb 16, 2018 9:46 pm   
Post subject:
Reply with quote
 
I understand it's not a final release, it's finished enough for me to make full use of. I don't need softmod tools, installers, or features in general. I do appreciate the tenacity though, keep at it!
_________________
320GB ST3320620A 7200RPM 16MB Cache
Gellid GC-Extreme Thermal Compound
StarTech 80 Conductor U-ATA Cable
80mm Xilence Hydro Bearing Fan
X-DU Chip & Toggle Switch
Taiyo Yuden Clock Cap
Xbox 1.1 MainBoard
XBMC 3.5.3 Dash
iND-BiOS 5004
128MB RAM


View user's profile Send private message Send e-mail
 
 
 
 
SPPV
V.I.P. Lifetime




Joined: Sep 13, 2010
Posts: 2411
Location: Kamloops BC Canada

Post Posted: Sat Feb 17, 2018 12:40 am   
Post subject:
Reply with quote
 
If at anytime you pick something and it just shuts down that means it was an area that I didnt finish. The Xtras for example were such an area, pretty much all the smaller ones like Atari Xtras are done but the huge 40GB ones like SNES I havent uploaded yet.


And Ive actually made significant progress on the NetBuilder portion. While I was in Vancouver I wrote what I had hoped would work to auto backup the eeprom and C drive to your PC then auto FTP/install a softmod on the XBOX. Just got home about an hour ago and tested it and we got a winner Very Happy Try and get a video of it up later today or tomorrow

Will make a new thread for Netbuilder and keep all chatter for it there since this is for AV converting scripts.


View user's profile Send private message
 
 
 
 
AdmiralShlong
Xbox-HQ Experienced
Xbox-HQ Experienced



Xbox Version: 1.1 & 360E 500
Modded: X-DU Alpha ModChip

Joined: Oct 01, 2014
Posts: 102
Location: CA, USA

Post Posted: Sat Feb 17, 2018 6:00 am   
Post subject:
Reply with quote
 
40GB of SNES roms? Alright I'll await the NB thread.
_________________
320GB ST3320620A 7200RPM 16MB Cache
Gellid GC-Extreme Thermal Compound
StarTech 80 Conductor U-ATA Cable
80mm Xilence Hydro Bearing Fan
X-DU Chip & Toggle Switch
Taiyo Yuden Clock Cap
Xbox 1.1 MainBoard
XBMC 3.5.3 Dash
iND-BiOS 5004
128MB RAM


View user's profile Send private message Send e-mail
 
Display posts from previous:   
  Post new topic  
 
  Reply to topic  
|
 All times are GMT | Page 1 of 1
Jump to:  
 

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum
 

 Members Online (2) / Guests Online (601)
Members Browsing
DeniceBatc, SPPV,

Legend
Administrator  Moderator  VIP Member  Registered User  Banned Users