当前位置: 首页>>代码示例>>C++>>正文


C++ Shuttle::TransferDouble方法代码示例

本文整理汇总了C++中Shuttle::TransferDouble方法的典型用法代码示例。如果您正苦于以下问题:C++ Shuttle::TransferDouble方法的具体用法?C++ Shuttle::TransferDouble怎么用?C++ Shuttle::TransferDouble使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Shuttle的用法示例。


在下文中一共展示了Shuttle::TransferDouble方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: TransferParameters

bool EffectTruncSilence::TransferParameters( Shuttle & shuttle )
{
   shuttle.TransferEnum(wxT("Db"), mTruncDbChoiceIndex, Enums::NumDbChoices, Enums::GetDbChoices());
   shuttle.TransferInt(wxT("Action"), mProcessIndex, 0);
   shuttle.TransferDouble(wxT("Minimum"), mInitialAllowedSilence, 0.5);
   shuttle.TransferDouble(wxT("Truncate"), mTruncLongestAllowedSilence, 0.5);
   shuttle.TransferDouble(wxT("Compress"), mSilenceCompressPercent, 50.0);
   return true;
}
开发者ID:GYGit,项目名称:Audacity,代码行数:9,代码来源:TruncSilence.cpp

示例2: TransferParameters

bool EffectBassTreble::TransferParameters(Shuttle & shuttle)
{  
   shuttle.TransferDouble(wxT("Bass"),dB_bass,0.0);
   shuttle.TransferDouble(wxT("Treble"),dB_treble,0.0);
   shuttle.TransferDouble(wxT("Level"),dB_level,0.0);
   shuttle.TransferBool( wxT("Normalize"), mbNormalize, true );

   return true;
}
开发者ID:jeevithag,项目名称:audacity,代码行数:9,代码来源:BassTreble.cpp

示例3: TransferParameters

bool EffectNormalize::TransferParameters( Shuttle & shuttle )
{
   shuttle.TransferBool( wxT("ApplyGain"), mGain, true );
   shuttle.TransferBool( wxT("RemoveDcOffset"), mDC, true );
   shuttle.TransferDouble( wxT("Level"), mLevel, 0.0);
   shuttle.TransferBool( wxT("StereoIndependent"), mStereoInd, false );
   return true;
}
开发者ID:tuanmasterit,项目名称:audacity,代码行数:8,代码来源:Normalize.cpp

示例4: TransferParameters

bool EffectTruncSilence::TransferParameters( Shuttle & shuttle )
{  
   shuttle.TransferEnum(wxT("Db"), mTruncDbChoiceIndex, Enums::NumDbChoices, Enums::GetDbChoices());
   shuttle.TransferInt(wxT("Minimum"), mTruncInitialAllowedSilentMs, 200);
   shuttle.TransferInt(wxT("Duration"), mTruncLongestAllowedSilentMs, 1000);
   shuttle.TransferDouble(wxT("Compress"), mSilenceCompressRatio, 4.0f);
   return true;
}
开发者ID:tuanmasterit,项目名称:audacity,代码行数:8,代码来源:TruncSilence.cpp

示例5: TransferParameters

bool EffectTimeScale::TransferParameters( Shuttle & shuttle )
{
   shuttle.TransferDouble(wxT("RatePercentChangeStart"),m_RatePercentChangeStart,0.0);
   shuttle.TransferDouble(wxT("RatePercentChangeEnd"),m_RatePercentChangeEnd,0.0);
   shuttle.TransferDouble(wxT("PitchHalfStepsStart"),m_PitchHalfStepsStart,0.0);
   shuttle.TransferDouble(wxT("PitchHalfStepsEnd"),m_PitchHalfStepsEnd,0.0);
   shuttle.TransferDouble(wxT("PitchPercentChangeStart"),m_PitchPercentChangeStart,0.0);
   shuttle.TransferDouble(wxT("PitchPercentChangeEnd"),m_PitchPercentChangeEnd,0.0);
   shuttle.TransferBool(wxT("PreAnalyze"),m_PreAnalyze,false);
   return true;
}
开发者ID:Cactuslegs,项目名称:audacity-of-nope,代码行数:11,代码来源:TimeScale.cpp

示例6: TransferParameters

bool EffectAutoDuck::TransferParameters( Shuttle & shuttle )
{
   shuttle.TransferDouble(wxT("DuckAmountDb"), mDuckAmountDb,
      PARAM_DEFAULT_DUCK_AMOUNT_DB);
   shuttle.TransferDouble(wxT("InnerFadeDownLen"), mInnerFadeDownLen,
      PARAM_DEFAULT_INNER_FADE_DOWN_LEN);
   shuttle.TransferDouble(wxT("InnerFadeUpLen"), mInnerFadeUpLen,
      PARAM_DEFAULT_INNER_FADE_UP_LEN);
   shuttle.TransferDouble(wxT("OuterFadeDownLen"), mOuterFadeDownLen,
      PARAM_DEFAULT_OUTER_FADE_DOWN_LEN);
   shuttle.TransferDouble(wxT("OuterFadeUpLen"), mOuterFadeUpLen,
      PARAM_DEFAULT_OUTER_FADE_UP_LEN);
   shuttle.TransferDouble(wxT("ThresholdDb"), mThresholdDb,
      PARAM_DEFAULT_THRESHOLD_DB);
   shuttle.TransferDouble(wxT("MaximumPause"), mMaximumPause,
      PARAM_DEFAULT_MAXIMUM_PAUSE);

   return true;
}
开发者ID:Cactuslegs,项目名称:audacity-of-nope,代码行数:19,代码来源:AutoDuck.cpp

示例7: TransferParameters

bool EffectChangeSpeed::TransferParameters(Shuttle& shuttle)
{  
   shuttle.TransferDouble(wxT("Percentage"), mPercentChange, 0.0);
   return true;
}
开发者ID:Rubelislam9950,项目名称:Audacity,代码行数:5,代码来源:ChangeSpeed.cpp

示例8: TransferParameters

bool EffectChangePitch::TransferParameters( Shuttle & shuttle )
{  
   shuttle.TransferDouble(wxT("Percentage"),m_PercentChange,0.0);
   m_SemitonesChange = (12.0 * log((100.0 + m_PercentChange) / 100.0)) / log(2.0);
   return true;
}
开发者ID:ruthmagnus,项目名称:audacity,代码行数:6,代码来源:ChangePitch.cpp

示例9: TransferParameters

bool EffectNyquist::TransferParameters( Shuttle & shuttle )
{
   for (size_t i = 0; i < mControls.GetCount(); i++) {
      NyqControl *ctrl = &mControls[i];
      double d = ctrl->val;
      bool good = false;

      if (d == UNINITIALIZED_CONTROL) {
         if (ctrl->type != NYQ_CTRL_STRING) {
            if (!shuttle.mbStoreInClient) {
               d = GetCtrlValue(ctrl->valStr);
            }
         }
      }

      if (ctrl->type == NYQ_CTRL_REAL) {
         good = shuttle.TransferDouble(ctrl->var, d, 0.0);
      }
      else if (ctrl->type == NYQ_CTRL_INT) {
         int val = (int) d;
         good = shuttle.TransferInt(ctrl->var, val, 0);
         d = (double) val;
      }
      else if (ctrl->type == NYQ_CTRL_CHOICE) {
         //str is coma separated labels for each choice
         wxString str = ctrl->label;
         wxArrayString choices;
         
         while (1) {
            int ci = str.Find( ',' ); //coma index

            if (ci == -1) {
               choices.Add( str );
               break;
            }
            else {
               choices.Add(str.Left(ci));
            }
            
            str = str.Right(str.length() - ci - 1);
         }

         int cnt = choices.GetCount();
         if (choices.GetCount() > 0) {
            wxString *array = NULL;
            array = new wxString[cnt];
            for (int j = 0; j < cnt; j++ ) {
               array[j] = choices[j];
            }

            int val = (int) d;
            good = shuttle.TransferEnum(ctrl->var, val, cnt, array);
            d = (double) val;

            delete [] array;
         }
      }
      else if (ctrl->type == NYQ_CTRL_STRING) {
         good = shuttle.TransferString(ctrl->var, ctrl->valStr, wxEmptyString);
      }

      if (ctrl->type != NYQ_CTRL_STRING) {
         if (shuttle.mbStoreInClient && good) {
            ctrl->val = d;
         }
      }
   }

   return true;
}
开发者ID:tuanmasterit,项目名称:audacity,代码行数:70,代码来源:Nyquist.cpp


注:本文中的Shuttle::TransferDouble方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。