You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First of all thank you for your effort, this is awesome framework that make work with AVFoundation easier.
I read documents
I read open or closed issues
Secondly I have a question about muting original audio of AVAsset and add custom audio to RenderComposition? I already tried to mute videoLayer with audioConfiguration like this
var audioConfiguration = AudioConfiguration()
let volumeRampTimeRange = source.selectedTimeRange
let volumeRamp1 = VolumeRamp(startVolume: 0.0, endVolume: 0.0, timeRange: volumeRampTimeRange)
audioConfiguration.volumeRamps = [volumeRamp1]
videoLayer.audioConfiguration = audioConfiguration
and then added new renderLayer for custom audio (mp3 file) named audioLayer and passed it to render composition like this
let composition = RenderComposition()
composition.layers = [videoLayer, audioLayer]
videoLayer sound plays 1 second and then its being muted, audioLayer audio works well but no video on composition entirely it becomes black screen.
Actually I couldn't see how to manage audio files in your documentation.
Any helps will be appreciated .
The text was updated successfully, but these errors were encountered:
Update
I fixed black screen issue when I add audio layer with adjusting selectedTimeRange but still original audio of video asset playing for 1 second at start even it's muted with audioConfiguration
Hi @ruanjx ,
First of all thank you for your effort, this is awesome framework that make work with AVFoundation easier.
Secondly I have a question about muting original audio of
AVAsset
and add custom audio toRenderComposition
? I already tried to mutevideoLayer
with audioConfiguration like thisand then added new renderLayer for custom audio (mp3 file) named
audioLayer
and passed it to render composition like thisvideoLayer
sound plays 1 second and then its being muted,audioLayer
audio works well but no video on composition entirely it becomes black screen.Actually I couldn't see how to manage audio files in your documentation.
Any helps will be appreciated .
The text was updated successfully, but these errors were encountered: