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


Python Red9_CoreUtils.timeIsInRange方法代码示例

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


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

示例1: getAudioInRange

# 需要导入模块: import Red9_CoreUtils [as 别名]
# 或者: from Red9_CoreUtils import timeIsInRange [as 别名]
 def getAudioInRange(self, time=(), asNodes=True, start_inRange=True, end_inRange=True):
     '''
     return any audio in the handler within a given timerange
     
     :param time: tuple, (min,max) timerange within which returned audio has 
         fall within else it's ignored.
     :param asNodes: return the data as r9Audio.AudioNodes
     :param start_inRange: check is the testRange[0] value falls fully in the baseRange
     :param end_inRange: check is the testRange[1] value falls fully in the baseRange
 
     .. note::
         if you pass in time as (None, 100) then we only validate against the end time.
         if we pass in time as (10, None) we only validate against the start time
         else we validate that testRange is fully within the times
     '''
     audio_in_range=[]
     for a in self.audioNodes:
         if r9Core.timeIsInRange(time, (a.startFrame,a.endFrame), start_inRange=start_inRange, end_inRange=end_inRange):
             audio_in_range.append(a)
     if not asNodes:
         return [a.audioNode for a in audio_in_range]
     return audio_in_range
开发者ID:satishgoda,项目名称:Red9_StudioPack,代码行数:24,代码来源:Red9_Audio.py


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