2011-11-13 17:14:45 +01:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
|
|
|
|
namespace DSDecmp.Formats.Nitro
|
|
|
|
|
{
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// A composite format with all formats supported natively by the GBA.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public class CompositeGBAFormat : CompositeFormat
|
|
|
|
|
{
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Creates a new instance of the format composed of all native GBA compression formats.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public CompositeGBAFormat()
|
|
|
|
|
: base(new Huffman4(), new Huffman8(), new LZ10()) { }
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a short string identifying this compression format.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override string ShortFormatString
|
|
|
|
|
{
|
|
|
|
|
get { return "GBA"; }
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a short description of this compression format (used in the program usage).
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override string Description
|
|
|
|
|
{
|
|
|
|
|
get { return "All formats natively supported by the GBA."; }
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets if this format supports compressing a file.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override bool SupportsCompression
|
|
|
|
|
{
|
|
|
|
|
get { return true; }
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets the value that must be given on the command line in order to compress using this format.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override string CompressionFlag
|
|
|
|
|
{
|
|
|
|
|
get { return "gba*"; }
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// A composite format with all formats supported natively by the NDS (but not LZ-Overlay)
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public class CompositeNDSFormat : CompositeFormat
|
|
|
|
|
{
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Creates a new instance of the format composed of all native NDS compression formats.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public CompositeNDSFormat()
|
|
|
|
|
: base(new Huffman4(), new Huffman8(), new LZ10(), new LZ11()) { }
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a short string identifying this compression format.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override string ShortFormatString
|
|
|
|
|
{
|
|
|
|
|
get { return "NDS"; }
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets a short description of this compression format (used in the program usage).
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override string Description
|
|
|
|
|
{
|
|
|
|
|
get { return "All formats natively supported by the NDS."; }
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets if this format supports compressing a file.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override bool SupportsCompression
|
|
|
|
|
{
|
|
|
|
|
get { return true; }
|
|
|
|
|
}
|
|
|
|
|
|
2011-11-14 18:33:30 +01:00
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets the value that must be given on the command line in order to compress using this format.
|
|
|
|
|
/// </summary>
|
2011-11-13 17:14:45 +01:00
|
|
|
|
public override string CompressionFlag
|
|
|
|
|
{
|
|
|
|
|
get { return "nds*"; }
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|