Chek your Permission-Policy header.
If it is set to camera=() then it will blocks access to the camera. Either you remove this header value from the response (alternatively pass empty string) or add this header with a value of camera(self) from the backend e.g. from php backend set the below header to the response.
$headers = [];
$headers['Permissions-Policy'] = 'camera=(self), microphone=(self)';
After that, verify it from the header respnonse,
Hope this will work.