mirror of
https://github.com/crskycode/GARbro.git
synced 2025-01-11 20:39:29 +08:00
generalized public methods interface for convenience.
This commit is contained in:
parent
44cf44f7c9
commit
1ca1a219c2
@ -199,7 +199,12 @@ namespace GameRes.Formats.Kogado
|
|||||||
|
|
||||||
public void InitQSModel()
|
public void InitQSModel()
|
||||||
{
|
{
|
||||||
m_qsm = new QSModel (257, 12, 2000, RANGECODER_INITFREQ, false);
|
InitQSModel (257, 12, 2000, RANGECODER_INITFREQ, false);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void InitQSModel (int n, int lg_totf, int rescale, int[] init, bool compress)
|
||||||
|
{
|
||||||
|
m_qsm = new QSModel (n, lg_totf, rescale, init, compress);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -235,14 +240,21 @@ namespace GameRes.Formats.Kogado
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
public uint Decode (byte[] dest, byte[] src, uint destsize, uint srcsize)
|
public uint Decode (byte[] dest, byte[] src, uint destsize, uint srcsize)
|
||||||
|
{
|
||||||
|
return Decode (dest, 0, destsize, src, 0, srcsize);
|
||||||
|
}
|
||||||
|
|
||||||
|
public uint Decode (byte[] dst, uint dst_index, uint dst_size,
|
||||||
|
byte[] src, uint src_index, uint src_size)
|
||||||
{
|
{
|
||||||
int ch, ltfreq, syfreq;
|
int ch, ltfreq, syfreq;
|
||||||
|
|
||||||
m_dwSrcIndex = m_dwDestIndex = 0;
|
m_dwSrcIndex = src_index;
|
||||||
|
m_dwDestIndex = dst_index;
|
||||||
m_pSrcBuffer = src;
|
m_pSrcBuffer = src;
|
||||||
m_pDestBuffer = dest;
|
m_pDestBuffer = dst;
|
||||||
m_dwSrcLength = srcsize;
|
m_dwSrcLength = src_size;
|
||||||
m_dwDestLength = destsize;
|
m_dwDestLength = dst_size;
|
||||||
|
|
||||||
StartDecoding();
|
StartDecoding();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user