fix: automatically select highest available video resolution
This commit is contained in:
		
							parent
							
								
									25ee3dd4f2
								
							
						
					
					
						commit
						64caa7e547
					
				
					 1 changed files with 6 additions and 0 deletions
				
			
		|  | @ -100,6 +100,12 @@ export default { | |||
|       if (this.stream) this.allowed = true; | ||||
|     }, | ||||
|     async assignStream() { | ||||
|       const capabilities = this.stream.getTracks()[0].getCapabilities(); | ||||
|       await this.attemptGetUserMedia({ | ||||
|         deviceId: capabilities.deviceId, | ||||
|         width: {exact: capabilities.width.max}, | ||||
|         height: {exact: capabilities.height.max} | ||||
|       }) | ||||
|       this.capturing = true; | ||||
|       this.streaming = false; | ||||
|       const {video} = this.$refs; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue