1
2
3
4
5
6
7
8
9
10
11from pyfbsdk import *
12import os
13import tempfile
14
16
17
18lAudioSampleFile = os.path.join( gSystem.ApplicationPath, "../../OpenRealitySDK/Scenes/English.wav" )
20
21
23
24
25lAudioRenderOptions.TimeSpan = gSystem.CurrentTake.LocalTimeSpan
26
27
28lAudioRenderOptions.ChannelMode = FBAudioChannelMode.kFBAudioChannelModeStereo
29
30
31lAudioRenderOptions.BitDepthMode = FBAudioBitDepthMode.kFBAudioBitDepthMode_16
32
33
34lAudioRenderOptions.RateMode = FBAudioRateMode.kFBAudioRateMode_44100
35
36
37lAudioRenderOptions.OutputFileName = os.path.join( tempfile.gettempdir(), "Output.wav" )
38
39
41 print("File successfully saved to %s" % lAudioRenderOptions.OutputFileName)
42else:
43 print("Failed to save file: %s" % lAudioRenderOptions.OutputFileName)
FBApplication is used mainly to manage files.
Definition: pyfbsdk_generated.h:801
Used to play audio clips and access their properties.
Definition: pyfbsdk_generated.h:1545
Audio Render Options structure.
Definition: pyfbsdk_generated.h:1957
Provides access to the underlying system, and the MotionBuilder scene.
Definition: pyfbsdk_generated.h:18771