WebAR-rocks / WebAR.rocks.face

WebAR.rocks face detection and tracking JavaScript library
https://webar.rocks
Other
86 stars 27 forks source link

how to override default video resolution #33

Closed mohitsavani117 closed 2 years ago

mohitsavani117 commented 2 years ago

hi, i want to change the video resolution programatically

xavierjs commented 2 years ago

Hi

To ask for a higher video resoluton in the WebAR.rocks.face glasses demo, here: https://github.com/WebAR-rocks/WebAR.rocks.face/blob/9c9ffed3842785c2504bab0110fdc2546fbb7f2c/demos/VTOGlasses/main.js#L23 at the same level as NNCPath, you can add:

videoSettings: {
  idealWidth: 1280,
  idealHeight: 720
}

This property is also describe in the README of the lib. Please read it carefully: https://github.com/WebAR-rocks/WebAR.rocks.face#optional-init-arguments

xavierjs commented 2 years ago

@mohitsavani117 did it work? Can I close this issue?