export 'audio' (imported as 'audio') was not found in '@cloudinary/url-gen/qualifiers/source'
Hello,
I want to remove the existing audio from video and want to add an overlay of audio. I'm using it in react sdk and refered using this https://cloudinary.com/documentation/video_layers#audio_overlays
there i can see
import { source } from "@cloudinary/url-gen/actions/overlay"; import { audio } from "@cloudinary/url-gen/qualifiers/source"; new CloudinaryVideo("hourglass_timer.mp4").overlay(source(audio("electronic")));
but when i'm import audio same as here then i'm getting error like
export 'audio' (imported as 'audio') was not found in '@cloudinary/url-gen/qualifiers/source' (possible exports: Source, fetch, image, subtitles, text, video)
Best Answers
-
Hey there,
Thanks for reaching out. There is a slight issue with our docs in this regard, you will use
video
and notaudio
. You should also remove the audio codec from the initial video by addingac_none
.New CloudinaryVideo(originalVideo, {cloudName: "demo"}).transcode(audioCodec("none")).overlay(source(video("electronic")));
I hope this helps, if you continue to have issues, please open a support ticket so we can help you troubleshoot.
1 -
Hi there,
No problem, you'll need to splice all videos together, then remove the audio codec and then add the audio overlay.
An example would be:
1
Answers
-
Thanks @Zachary,
This solution can work when we want to remove and place an audio on the existing video.
Is there any possibilities to remove and add audio overlay on resultant on merged video. Means not existing video but on transforming videos ?
0 -
Hi there,
I apologize but I'm confused by your question can you please share a specific example URL with a description of how you'd like to transform it?
Thanks!
0 -
Hi @Zachary,
I want to make URl like
https://res.cloudinary.com/dsxkwgopy/video/upload/fl_splice,l_video:video_2/fl_layer_apply/ac_none/l_audio:audio_1/fl_layer_apply/video_1.mp4
Here i have merged the video_2 to video_1 and then removing audio with ac_none and after i want to apply an overlay of audio audio_1.
Is this possible ?
0 -
Hi @Zachary ,
Can we remove only 5 sec of starting audio and rest will be original from this delivery URL :
0 -
Hi @vinodsnayvik. Unfortunately, such a transformation is not supported, however you could mute the audio tracks of the two videos using ac_none, and then apply the audio as a separate layer. Something like the following:
0