sdp transform error
See original GitHub issueI am rearranging the order of the codecs so that h264 is first but on android to ios calls im getting an encoding undefined error on one of the callbacks on RCTPeerConnection.
As I have seen in my logs, Is it because android does not have h264? @zxcpoiu @saghul
//check and replace for H264 codec
function preferH264(description) {
let newDescription = description;
let sdp = description.sdp;
let parsedSdp = transform.parse(sdp);
parsedSdp.media = parsedSdp.media.map(media => {
if(media.type === 'video') {
const baseRtp = [media.rtp.find(rtp => rtp.codec.toLowerCase() === 'h264')];
media.rtp = baseRtp.concat(media.rtp);
}
return media;
});
newDescription.sdp = transform.write(parsedSdp);
return newDescription;
}
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:6 (4 by maintainers)
Top Results From Across the Web
sdp transform parse webrtc sdp error · Issue #64 · clux/sdp-transform ...
yes, it is sdp string. maybe it is because of i change the bandwidth of the sdp. if i do not change the...
Read more >sdp-transform - npm
A simple parser/writer for the Session Description Protocol. Latest version: 2.14.1, last published: 2 years ago. Start using sdp-transform ...
Read more >How to use the sdp-transform.parse function in sdp-transform | Snyk
To help you get started, we've selected a few sdp-transform.parse examples ... res, {localSdp: sdp})) .catch((err) => { logger.error(err, 'Error replying to ...
Read more >transform package - github.com/gearghost/sdp/transform - Go ...
func Parse(sdp string) (sdpStruct *SdpStruct, err error). type SimulCastItem; type Simulcast03Struct; type SimulcastStruct; type SsrcGroupStruct ...
Read more >WebRTC SDP Parsing error with GeckoFX - Stack Overflow
Why does this occur? When invoking pc.setRemoteDescription(sessionDescription, successCallback, errorCallback); your stack is parsing the sessionDescription ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@jjdp you are adding an undefined into the rtp list in cases where the codec is not found…
One of the easiest way to see which codec it supports, is to create offer without any constraints then see the codec list in sdp in different platform.