docontrolcode.c
来自「bf533音訊處理 使用visual audio 軟件」· C语言 代码 · 共 43 行
C
43 行
// Copyright(c) 2005 Analog Devices, Inc. All Rights Reserved.
// This software is proprietary and confidential to Analog Devices, Inc. and its licensors.
// File : $Id: //depot/Development/VisualAudio/Platforms/EZKit_BF533_Basic/2.5.0/DoControlCode.c#2 $
// Part of : VisualAudio V2.5.0
// Updated : $Date: 2006/10/12 $ by $Author: Fernando $
/* This file is the location where you should put your control code. An example control code
that uses compiled presets is given below for the SimpleWithPresets.vas example system.
*/
#include "Basic.h"
#include "VALayout1Presets.h" /* In VAGenerated/ directory */
#ifdef SIMPLE_WITH_PRESETS /* Control code for example layout "SimpleWithPresets" */
#ifndef NO_OPTIMIZE
#pragma optimize_for_space
#endif
void DoControlCode(void) {
#define SECONDS_PER_PRESET 5 /* 5 seconds for each preset */
static int nextPresetChangeTick = 0;
static int currentPreset = 0;
static int presetOffsets[] = {Layout1_PRESET_LeftChannelOnly,
Layout1_PRESET_Minus3dB,
Layout1_PRESET_RightChannelOnly};
if (Layout1.nTicks > nextPresetChangeTick) {
currentPreset = (currentPreset + 1) % (sizeof(presetOffsets)/sizeof(int));
SYS_ApplyPreset(presetOffsets[currentPreset]);
nextPresetChangeTick += (SECONDS_PER_PRESET *
(Layout1.iSampleRate/Layout1.topLevelGrouping.tickSize));
}
}
#else
void DoControlCode(void) {
}
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?