Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

怎么样混合背景音乐? #10

Open
G-Singularity opened this issue Oct 27, 2021 · 1 comment
Open

怎么样混合背景音乐? #10

G-Singularity opened this issue Oct 27, 2021 · 1 comment

Comments

@G-Singularity
Copy link

// 1. Layer 1
var url = Bundle.main.url(forResource: "video1", withExtension: "MOV")
var asset = AVAsset(url: url!)
var source = AVAssetSource(asset: asset)
source.selectedTimeRange = CMTimeRange(start: CMTime.zero, duration: asset.duration)
var timeRange = source.selectedTimeRange
let renderLayer1 = RenderLayer(timeRange: timeRange, source: source)
RenderLayer同样适用音频资源么?有没有demo展示一下?

@G-Singularity
Copy link
Author

混合背景音乐后,视频不显示了,需要设置什么参数么?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant