> For the complete documentation index, see [llms.txt](https://documentation.sceenic.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documentation.sceenic.co/watch-together-sdk/sscale-confluence-tutorials/web/sample-application/how-to-change-video-quality.md).

# How to change video quality

You can adjust the video quality parameters by creating controls that allow you to set specific values for the resolution and frame rate.

```javascript
let videoWidth = 320;
let videoHeight = 240;
let frameRate = 12;
...
```

```javascript
function setVideoQuality(width, height, frameRate ) {
	let constraints = {};
	if(width)
		constraints.videoWidth = width
	if(height)
		constraints.videoHeight = height
	if(frameRate)
		constraints.frameRate = frameRate
	WTSDK.Participant.setMediaQuality(constraints)
}
...
```

```javascript
function changeWidth(width){
	videoWidth = width;
	document.getElementById('width-label').innerHTML = width;
}
function changeHeight(height){
	videoHeight = height;
	document.getElementById('height-label').innerHTML = height;
}
function applyQuality () {
	WTSDK.Participant.setMediaQuality({videoWidth: videoWidth, videoHeight: videoHeight, frameRate: 12})
}
```
