2024-07-26 17:52:33 +08:00
|
|
|
|
namespace VirtualNes.Core
|
2024-07-25 14:03:52 +08:00
|
|
|
|
{
|
|
|
|
|
public class NOISE
|
|
|
|
|
{
|
|
|
|
|
public byte[] reg = new byte[4]; // register
|
|
|
|
|
|
|
|
|
|
public byte enable; // enable
|
|
|
|
|
public byte holdnote; // holdnote
|
|
|
|
|
public byte volume; // volume
|
|
|
|
|
public byte xor_tap;
|
|
|
|
|
public int shift_reg;
|
|
|
|
|
|
|
|
|
|
// For Render
|
|
|
|
|
public int phaseacc;
|
|
|
|
|
public int freq;
|
|
|
|
|
public int len_count;
|
|
|
|
|
|
|
|
|
|
public int nowvolume;
|
|
|
|
|
public int output;
|
|
|
|
|
|
|
|
|
|
// For Envelope
|
|
|
|
|
public byte env_fixed;
|
|
|
|
|
public byte env_decay;
|
|
|
|
|
public byte env_count;
|
|
|
|
|
public byte dummy0;
|
|
|
|
|
public int env_vol;
|
|
|
|
|
|
|
|
|
|
// For sync;
|
|
|
|
|
public byte[] sync_reg = new byte[4];
|
|
|
|
|
public byte sync_output_enable;
|
|
|
|
|
public byte sync_enable;
|
|
|
|
|
public byte sync_holdnote;
|
|
|
|
|
public byte dummy1;
|
|
|
|
|
public int sync_len_count;
|
|
|
|
|
}
|
|
|
|
|
}
|