vgmrips

The forum about vgm files
It is currently 2018-12-19, 14:21:24

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Valkyrie No Densetsu
PostPosted: 2012-05-23, 15:21:22 

Staff Staff
Programmers Programmers
Musicians Musicians
Contributors Contributors
Reverse engineers Reverse engineers
Offline
User avatar

Joined: 2011-12-01, 20:20:07
Posts: 3025
Location: Germany
TitleValkyrie No Densetsu
ComposerHiroyuki Kawada
SystemNamco System 2
Sound ChipsYM2151, C140
Tracks18
Playing time31:18
Pack author2ch-H
Pack version1.00
Last Update2012-05-30



Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-12, 3:38:12 
Offline

Joined: 2018-04-12, 2:49:47
Posts: 3
The YM2151 is too quiet in several of these files. I tried to edit them myself but I can't find how to create the extra header required to set chip volumes. Is there a guide anywhere on how to do it? Do any of the tools add the header?


Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-13, 9:27:34 

Contributors Contributors
Staff Staff
Reverse engineers Reverse engineers
Offline
User avatar

Joined: 2013-07-17, 23:32:39
Posts: 342
http://vgmrips.net/forum/viewtopic.php?p=9053#p9053


Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-14, 18:04:52 
Offline

Joined: 2018-04-12, 2:49:47
Posts: 3
Excellent. I added the header and I can adjust volumes.

Now, is it a better idea to boost the YM2151 or attenuate the C140? I've seen posts about how System 2 volume is supposed to work:
Quote:
I already added an "extra header" section that allows to adjust the chip volume on a per-vgm basis in v1.70.
I just haven't written tools that write these values yet. (Currently I resize the header with vgm_ptch and overwrite a few bytes using a mini-tool.)

Anyway, I found:
- MAME Namco System 2 "default": YM2151 0.80, C140 0.75 (100%/94%)
- MAME Namco System 2 "default3": YM2151 1.00, C140 0.45 (100%/45%)
- MAME Namco System 2 "metlhawk": YM2151 0.80, C140 1.00 (100%/125%)
- MAME Namco System 21: YM2151 0.30, C140 0.50 (100%/166%)
- M1 Namco System 2: YM2151 0.80, C140 0.40 (100%/50%)
- M1 Namco System 21: YM2151 0.80, C140 0.45 (100%/56%)
This is really a mess, but I think I'll go with default values of YM2151 100% and C140 50% for the next release of VGMPlay.


I'm using Foobar2000 foo_gep to listen and it doesn't seem to have the special case of Namco System 2 volume adjustment that Valleybell put in vgmplay.

Here's my subjective observation, let me know if I got these volume levels wrong:

0x10d: 03 00 00 82 Boost YM2151 to 200%, the volume is pretty close to MAME
0x10d: 1c 00 80 00 Attenuate C140 to 50%, for some reason this sounds slightly better, maybe something with how the player is normalizing the rest of the volume?


Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-14, 20:11:08 

Contributors Contributors
Staff Staff
Reverse engineers Reverse engineers
Offline
User avatar

Joined: 2013-07-17, 23:32:39
Posts: 342
You'd write '80 80' to reduce volume by half. '80 00' sets the volume to 128 directly.

I don't think there's a "perfectly" accurate sound mix, and the OST releases were typically not recorded from the real hardware (it's noticeable from how clean the PCM sounds), so going by ear is probably best.

And the sound mix in M1 and MAME are probably based on guesswork anyway.


Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-14, 23:27:59 
Offline

Joined: 2018-04-12, 2:49:47
Posts: 3
This is what I was going from:
extraheader.xsc:

Code:
; volume example
; 80 00 = 0.50x   <-- why not 80 80?
; 80 81 = 1.50x
; 00 82 = 2.00x
; 40 83 = 3.25x


So now I'm wondering, is bit 0x0080 a flag that the volume is a multiplier?

Any recommendations for multiplier vs. absolute volume for compatibility with different VGM players?


Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-15, 0:13:38 

Staff Staff
Programmers Programmers
Musicians Musicians
Contributors Contributors
Reverse engineers Reverse engineers
Offline
User avatar

Joined: 2011-12-01, 20:20:07
Posts: 3025
Location: Germany
I'll quickly explain a few things. One important thing to know is that on x86 systems, 2-byte numbers are stored backwards. ("Little Endian" byte order) i.e. a number 0x1234 is stored as "34 12" in VGMs.
Code:
0.50x = 0x0080 = 80 00
1.50x = 0x0180 = 80 01
2.00x = 0x0200 = 00 02
3.25x = 0x0340 = 40 03

You can add 0x8000 to the actual value (0x0200 + 0x8000 = 0x8200, resulting in bytes 00 82 for the file), in order to make the volume being multiplied with whatever VGMPlay uses as "default" volume.
However, I recommend to do that only for the YM2203/2608/2610's SSG.

If you want to go the safe route, just define the volume for both chips, the YM2151 and the C140.
For YM2151 at 1.00 and C140 at 0.50, the byte sequence would be:
Code:
define 2 chips
|     YM2151        C140
v   |---------|  |---------|
02  03 00 00 01  1C 00 80 00
    ^     |---|  ^     |---|
    |     volume |     volume
    ID    0x0100 ID    0x0080


Top
 Profile  
 
 Post subject:
PostPosted: 2018-04-15, 0:54:57 

Contributors Contributors
Staff Staff
Reverse engineers Reverse engineers
Offline
User avatar

Joined: 2013-07-17, 23:32:39
Posts: 342
tcmbackwards wrote:
Code:
; volume example
; 80 00 = 0.50x   <-- why not 80 80?
; 80 81 = 1.50x
; 00 82 = 2.00x
; 40 83 = 3.25x


Sorry, that was a typo.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


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 post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group
[ Time : 0.246s | 15 Queries | GZIP : On ]