google / model-viewer

Easily display interactive 3D models on the web and in AR!
https://modelviewer.dev
Apache License 2.0
6.76k stars 801 forks source link

V-Ray CPU render fidelity tests. #4487

Closed jasondavies closed 10 months ago

jasondavies commented 10 months ago

Fixes #4483.

google-cla[bot] commented 10 months ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

jasondavies commented 10 months ago

Unexpectedly ran into an unknown error when leaving this to run update-screenshots:

vray: Rendering khronos-Cube...Error: Offline rendering process for V-Ray failed:
    at updateScreenshots (file:///home/jason/model-viewer/packages/render-fidelity-tools/lib/workflows/update-screenshots.js:130:31)
📋 Screenshot updates concluded
npm ERR! Lifecycle script `update-screenshots` failed with error:
npm ERR! Error: command failed
npm ERR!   in workspace: @google/model-viewer-render-fidelity-tools@0.0.1
npm ERR!   at location: /home/jason/model-viewer/packages/render-fidelity-tools

It's a shame there wasn't more information provided.

jasondavies commented 10 months ago

Unclear exactly why I encountered two seemingly random failures during V-Ray execution, with no errors. Not sure if error logging could be improved (it seems fine on the model-viewer side at first glance).

jasondavies commented 10 months ago

OK, looks like the reason for the two failures was recorded in my syslog (redacted):

Sep 29 20:15:19 XXX kernel: [ 2781.311809] python[6805]: segfault at 0 ip XXX sp XXX error 4 in libcgauth.so[XXX]
...
Sep 29 21:48:58 XXX kernel: [ 8400.248403] python[11779]: segfault at 0 ip XXX sp XXX error 4 in libcgauth.so[XXX]

Seems like a V-Ray bug. I'm using appsdk-linux_qt5-release-vray_v6.10.07-20230426.

Edit: reported the issue here: ChaosGroup/vray_gltf#7

jasondavies commented 10 months ago

I've added ACES filmic tone mapping now (applied to the raw image which should be linear).

vray-golden

jasondavies commented 10 months ago

Looks like a width/height swap bug in my array handling code. Re-rendering goldens now.

jasondavies commented 10 months ago

Camera issues fixed.

jasondavies commented 10 months ago

Looks like the following scenarios have obvious issues:

Edit: fixed scenarios that have renderSkybox=true

jasondavies commented 10 months ago

Implemented renderSkybox support. I think this is ready for review.

jasondavies commented 10 months ago

I deliberately separated the third-party V-Ray code into a separate commit and marked as "submitted on behalf of a third-party" to comply with Google's CLA, but it looks like you squashed everything into one commit. I guess it's too late to change this now, but just noting this for posterity. It was also more helpful to be able to see which changes I made to the original vray_gltf in the second commit.

elalish commented 10 months ago

Thanks! Your separate commits will continue to live on in this PR, which is the easiest way to view them anyway, so no harm done.