Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.

GENH dsp - problems with COEFF

Featured Replies

  • Author
  • Localization

AlphaTwentyThree, posted Tue May 24, 2016 9:46 am (13672)


Hi there! I'm currently trying to get hold on different dsp headers. I'm trying to unify them into GENH headers. However I'm having problems with the decoding coefficients. I can see in the GENH section of VGMToolbox that there are different versions of coefficient, for example the split one. I have no idea what that means but I suspect this to be the cause of the fault.
The following script tries to make a GENH out of a RIFX file. It's a crude script but it does the job so far. But as I mentioned, something is wrong with the coefficients. First of all, here are some RIFX dsp samples: http://www102.zippyshare.com/v/eTHlP6tw/file.html
I suspect the coefficients to be at 0x80 and 0xaa but I could be wrong.
Here's the script for the GENH:
Code:
idstring "RIFX"

endian big
set OFFSET 0xe0
goto 0x16
get CH short
get FREQ long
goto 0x2c
get NOS long

set OFF_COEFF1 0x80
set OFF_COEFF2 0xaa

get SIZE asize
math SIZE -= OFFSET
xmath PRE_SIZE "SIZE 0xc0"
putVarChr MEMORY_FILE SIZE 0
log MEMORY_FILE 0 0

endian little

putVarChr MEMORY_FILE 0 0x484e4547 long # "GENH"
putVarChr MEMORY_FILE 4 CH long # ch
putVarChr MEMORY_FILE 8 8 long # interleave
putVarChr MEMORY_FILE 0xc FREQ long
putVarChr MEMORY_FILE 0x10 0xffffffff long
putVarChr MEMORY_FILE 0x14 NOS long # number of samples
putVarChr MEMORY_FILE 0x18 0xc long # ?
putVarChr MEMORY_FILE 0x1c 0xc0 long # stream start
putVarChr MEMORY_FILE 0x20 0xc0 long # stream start
putVarChr MEMORY_FILE 0x24 0x80 long # coeff1
putVarChr MEMORY_FILE 0x28 0xa0 long # coeff2
putVarChr MEMORY_FILE 0x2c 1 long
putVarChr MEMORY_FILE 0x34 0x80 long # coeff1
putVarChr MEMORY_FILE 0x38 0xa0 long # coeff2
putVarChr MEMORY_FILE 0x7f 0 byte
append
log MEMORY_FILE OFF_COEFF1 0x20
log MEMORY_FILE OFF_COEFF2 0x20
log MEMORY_FILE OFFSET SIZE
append
get SIZE asize MEMORY_FILE
get NAME basename
string NAME = ".genh"
log NAME 0 SIZE MEMORY_FILE


Any help is appreciated! :)
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.