Previous Page

by Kurausukun at 6:28 PM EST on December 12, 2016
When/if you do this quick hack, how will we be able to use it?
by richardpl at 4:17 AM EST on December 13, 2016
Can you please upload sample somewhere?

I'm one responsible for XMA1/2 support in FFmpeg.

And I welcome any patches to FFmpeg.
by bnnm at 2:43 PM EST on December 13, 2016
@Kurausukun - I meant I'll update vgmstream to play XMA, but internally it may be hack-y.

@richardpi - Samples: https://www.sendspace.com/file/4u546i

Issues I know:
- if the "fmt" chunk is found first "XMA2" is ignored (@ wavdec.c)
- "XMA2" chunk: no V3 = size 0x24 (minor variation), expects V4 = size 0x2c (@ wavdec.c)
- no XMA2 6 channel (@ wmaprodec.c)
- no RIFX/big endian
(also I'll check if various block sizes are supported)

The 6ch is the only one I can't hack into vgmstream, so it would be great if you could look into that first.

***

Also I couldn't find a XMA1 set with loop points. I'm blind, loop points are outside, or is every joshw set borked/transconverted? :S
by richardpl at 3:36 PM EST on December 13, 2016
The >2 channel in XMA1/2 is one big mess, i failed to dechiper it. Perhaps someone can explain to me how to implement it because it needs big blocks of data. I'm well aware of scripts which splits such streams into stereo files.
by Kurausukun at 6:08 PM EST on December 13, 2016
I don't know if His World actually loops in-game, so I'm not sure there are loop points in that file... I'll upload the one I've been using just in case: here.
by richardpl at 5:58 PM EST on January 18, 2017
I got multichannel XMA2 somehow working in FFmpeg.
Decoder still spills errors now and then but everything sounds fine to my ears.
by bnnm at 3:06 PM EST on January 19, 2017
Thanks, much appreciated.

I tested with vgmstream a bit and generally works fine, but there are some problems when looping/seeking.
Seems channel packets are being mixed (ex. packets from ch0 will appear in ch2, etc).

Looping works by using avformat_seek_file to 0 + avcodec_flush_buffers, and decoding again until the desired sample.

Maybe some internal state isn't being flushed?

EDIT: ah, I see you already submitted a patch!

edited 3:08 PM EST January 19, 2017
by richardpl at 8:12 AM EST on January 20, 2017
I think I fixed those channel mixing issues. Only I get some errors when decoding some xma1 multichannel files, dunno why.
by bnnm at 7:22 PM EST on January 21, 2017
It's working great now. Thanks!

For XMA1, I've seen many samples around incorrectly converted from XMA2, I wouldn't worry too much (unless you ripped them yourself...)

Previous Page
Go to Page 0 1

Search this thread

Show all threads

Reply to this thread:

User Name Tags:

bold: [b]bold[/b]
italics: [i]italics[/i]
emphasis: [em]emphasis[/em]
underline: [u]underline[/u]
small: [small]small[/small]
Link: [url=http://www.google.com]Link[/url]

[img=https://www.hcs64.com/images/mm1.png]
Password
Subject
Message

HCS Forum Index
Halley's Comet Software
forum source