summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author AJR <ajrhacker@users.noreply.github.com>2019-09-16 23:19:42 -0400
committer AJR <ajrhacker@users.noreply.github.com>2019-09-16 23:19:51 -0400
commit40a59e3cb6182e84234e99b87186e2d477b9587c (patch)
treec48fe75830aedbc7401219de4a608844eebcc542 /src
parentd8f27b7e87f5f5f1adbf44ffc8ef603c8b9e1049 (diff)
multipcm: Saner pointer allocation (nw)
Diffstat (limited to 'src')
-rw-r--r--src/devices/sound/multipcm.cpp2
-rw-r--r--src/devices/sound/multipcm.h4
2 files changed, 2 insertions, 4 deletions
diff --git a/src/devices/sound/multipcm.cpp b/src/devices/sound/multipcm.cpp
index e3f533db186..f53c543cb89 100644
--- a/src/devices/sound/multipcm.cpp
+++ b/src/devices/sound/multipcm.cpp
@@ -259,8 +259,6 @@ void multipcm_device::lfo_init()
}
}
- m_pitch_scale_tables = std::make_unique<std::unique_ptr<int32_t[]>[]>(8);
- m_amplitude_scale_tables = std::make_unique<std::unique_ptr<int32_t[]>[]>(8);
for (int32_t table = 0; table < 8; ++table)
{
float limit = PHASE_SCALE_LIMIT[table];
diff --git a/src/devices/sound/multipcm.h b/src/devices/sound/multipcm.h
index 1072a1846ed..abfa8b7c1b9 100644
--- a/src/devices/sound/multipcm.h
+++ b/src/devices/sound/multipcm.h
@@ -107,9 +107,9 @@ private:
std::unique_ptr<int32_t[]> m_total_level_steps;
std::unique_ptr<int32_t[]> m_pitch_table;
- std::unique_ptr<std::unique_ptr<int32_t[]>[]> m_pitch_scale_tables;
+ std::unique_ptr<int32_t[]> m_pitch_scale_tables[8];
std::unique_ptr<int32_t[]> m_amplitude_table;
- std::unique_ptr<std::unique_ptr<int32_t[]>[]> m_amplitude_scale_tables;
+ std::unique_ptr<int32_t[]> m_amplitude_scale_tables[8];
uint32_t value_to_fixed(const uint32_t bits, const float value);