diff options
author | JP Cimalando <jpcima@users.noreply.github.com> | 2019-02-24 00:13:35 +0100 |
---|---|---|
committer | JP Cimalando <jpcima@users.noreply.github.com> | 2019-02-24 00:13:35 +0100 |
commit | c903e6df7b3dde7de714311360130a3d0219d873 (patch) | |
tree | 06f9f7212acc4f53457805a4c9e78f1d1966608d /src/chips/java_opl3.h | |
parent | 1cecfeec8bd300c848000eeb929841a3564e70ff (diff) | |
download | libADLMIDI-c903e6df7b3dde7de714311360130a3d0219d873.tar.gz libADLMIDI-c903e6df7b3dde7de714311360130a3d0219d873.tar.bz2 libADLMIDI-c903e6df7b3dde7de714311360130a3d0219d873.zip |
javaopl3 work in progress
Diffstat (limited to 'src/chips/java_opl3.h')
-rw-r--r-- | src/chips/java_opl3.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/src/chips/java_opl3.h b/src/chips/java_opl3.h new file mode 100644 index 0000000..51b5be2 --- /dev/null +++ b/src/chips/java_opl3.h @@ -0,0 +1,44 @@ +/* + * Interfaces over Yamaha OPL3 (YMF262) chip emulators + * + * Copyright (c) 2017-2019 Vitaly Novichkov (Wohlstand) + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + +#ifndef JAVA_OPL3_H +#define JAVA_OPL3_H + +#include "opl_chip_base.h" + +class JavaOPL3 final : public OPLChipBaseBufferedT<JavaOPL3> +{ + void *m_chip; +public: + JavaOPL3(); + ~JavaOPL3() override; + + bool canRunAtPcmRate() const override { return false; } + void setRate(uint32_t rate) override; + void reset() override; + void writeReg(uint16_t addr, uint8_t data) override; + void writePan(uint16_t addr, uint8_t data) override; + void nativePreGenerate() override {} + void nativePostGenerate() override {} + void nativeGenerateN(int16_t *output, size_t frames) override; + const char *emulatorName() override; +}; + +#endif // JAVA_OPL3_H |