let's try console
This commit is contained in:
parent
9cdc330a48
commit
8313d0f518
|
@ -400,6 +400,7 @@ src/engine/platform/sound/c64/wave8580_PST.cc
|
||||||
src/engine/platform/sound/c64/wave8580_P_T.cc
|
src/engine/platform/sound/c64/wave8580_P_T.cc
|
||||||
src/engine/platform/sound/c64/wave8580__ST.cc
|
src/engine/platform/sound/c64/wave8580__ST.cc
|
||||||
|
|
||||||
|
src/engine/platform/sound/c64_fp/array.cpp
|
||||||
src/engine/platform/sound/c64_fp/Dac.cpp
|
src/engine/platform/sound/c64_fp/Dac.cpp
|
||||||
src/engine/platform/sound/c64_fp/EnvelopeGenerator.cpp
|
src/engine/platform/sound/c64_fp/EnvelopeGenerator.cpp
|
||||||
src/engine/platform/sound/c64_fp/ExternalFilter.cpp
|
src/engine/platform/sound/c64_fp/ExternalFilter.cpp
|
||||||
|
@ -763,9 +764,7 @@ if (WARNINGS_ARE_ERRORS)
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (WIN32)
|
if(ANDROID AND NOT TERMUX)
|
||||||
add_executable(furnace WIN32 ${USED_SOURCES})
|
|
||||||
elseif(ANDROID AND NOT TERMUX)
|
|
||||||
add_library(furnace SHARED ${USED_SOURCES})
|
add_library(furnace SHARED ${USED_SOURCES})
|
||||||
else()
|
else()
|
||||||
add_executable(furnace ${USED_SOURCES})
|
add_executable(furnace ${USED_SOURCES})
|
||||||
|
|
26
src/engine/platform/sound/c64_fp/array.cpp
Normal file
26
src/engine/platform/sound/c64_fp/array.cpp
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
/*
|
||||||
|
* This file is part of a modification to libsidplayfp, a SID player engine.
|
||||||
|
* The applied modification fixes compilation under recent version of GCC,
|
||||||
|
* which have tougher warnings against memory access problems.
|
||||||
|
*
|
||||||
|
* Copyright (C) 2011-2014 Leandro Nini
|
||||||
|
* Copyright (C) 2023 tildearrow
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program 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 General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "array.h"
|
||||||
|
|
||||||
|
std::mutex counterOps;
|
|
@ -21,6 +21,10 @@
|
||||||
#ifndef ARRAY_H
|
#ifndef ARRAY_H
|
||||||
#define ARRAY_H
|
#define ARRAY_H
|
||||||
|
|
||||||
|
#include <mutex>
|
||||||
|
|
||||||
|
extern std::mutex counterOps;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Counter.
|
* Counter.
|
||||||
*/
|
*/
|
||||||
|
@ -59,7 +63,7 @@ public:
|
||||||
x(p.x),
|
x(p.x),
|
||||||
y(p.y) { count->increase(); }
|
y(p.y) { count->increase(); }
|
||||||
|
|
||||||
~matrix() { if (count->decrease() == 0) { delete count; delete [] data; } }
|
~matrix() { counterOps.lock(); if (count->decrease() == 0) { delete count; delete [] data; } counterOps.unlock(); }
|
||||||
|
|
||||||
unsigned int length() const { return x * y; }
|
unsigned int length() const { return x * y; }
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue