// SPDX-FileCopyrightText: 2023 The Pion community <https://pion.ly>
// SPDX-License-Identifier: MIT

//go:build !js
// +build !js

package webrtc

import 

// SetRTPParameters applies provided RTPParameters the RTPReceiver's tracks.
//
// This method is part of the ORTC API. It is not
// meant to be used together with the basic WebRTC API.
//
// The amount of provided codecs must match the number of tracks on the receiver.
func ( *RTPReceiver) ( RTPParameters) {
	 := make([]interceptor.RTPHeaderExtension, 0, len(.HeaderExtensions))
	for ,  := range .HeaderExtensions {
		 = append(, interceptor.RTPHeaderExtension{ID: .ID, URI: .URI})
	}

	.mu.Lock()
	defer .mu.Unlock()

	for ,  := range .Codecs {
		 := .tracks[].track

		.tracks[].streamInfo.RTPHeaderExtensions = 

		.mu.Lock()
		.codec = 
		.params = 
		.mu.Unlock()
	}
}