我有这个用于IOS的cocos 2dx游戏,我想把它移植到Android.我知道我必须在android.mk中编写所有类,我做了.但我仍然有这个问题
类/场景/ itemshop/ItemShop.cpp:144:错误:未定义引用'cocos2d :: UserDefault :: GetValueForKeyPlist
这只是可怕的我不明白为什么我有这个错误,我UserDefault在android.mk中声明了类
编辑:这是一些代码:
CCUserDefault.h
/****************************************************************************
Copyright (c) 2010-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
http://www.cocos2d-x.org
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom …Run Code Online (Sandbox Code Playgroud) 我已经为如何通过添加回声效果来修改 wav 文件而苦苦挣扎了一段时间;我的应用程序可以进行音调筛选、速度和音量,但我无法添加效果。我是音频工程或类似领域的初学者。
我的主要目标是找到一种算法并创建一个函数来获取 byte[] 样本并对其进行修改。
I'm using this current code right now:
sonic = new Sonic(44100, 1);
byte samples[] = new byte[4096];
byte modifiedSamples[] = new byte[2048];
int bytesRead;
if (soundFile != null) {
sonic.setSpeed(params[0]);
sonic.setVolume(params[1]);
sonic.setPitch(params[2]);
do {
try {
bytesRead = soundFile.read(samples, 0, samples.length);
} catch (IOException e) {
e.printStackTrace();
return null;
}
if (bytesRead > 0) {
sonic.putBytes(samples, bytesRead);
} else {
sonic.flush();
}
int available = sonic.availableBytes();
if (available > 0) {
if (modifiedSamples.length < …Run Code Online (Sandbox Code Playgroud)