--- /srv/reproducible-results/rbuild-debian/r-b-build.mUSzJuWA/b1/opensubdiv_3.6.0-1_arm64.changes +++ /srv/reproducible-results/rbuild-debian/r-b-build.mUSzJuWA/b2/opensubdiv_3.6.0-1_arm64.changes ├── Files │ @@ -1,9 +1,9 @@ │ │ c9d985297a737f159ce593cbb625b0ab 153028 libdevel optional libosd-dev_3.6.0-1_arm64.deb │ - 5d5eafc6305fabae1c748779f2f7446e 31492544 doc optional libosd-doc_3.6.0-1_all.deb │ + 4e8d16f8bc3bc69b9e27e970c05e67c2 31492948 doc optional libosd-doc_3.6.0-1_all.deb │ 7d0d25c3dc120889dcb6a6c86460c869 3441888 debug optional libosdcpu3.6.0-dbgsym_3.6.0-1_arm64.deb │ 3010f305417042b95bda138f00bc238d 290472 libs optional libosdcpu3.6.0_3.6.0-1_arm64.deb │ 0d7ae88ec9aaf7da66d629da13d51c8e 530876 debug optional libosdgpu3.6.0-dbgsym_3.6.0-1_arm64.deb │ bd5dccfc524483da3f332066ade1dc91 133204 libs optional libosdgpu3.6.0_3.6.0-1_arm64.deb │ 8b6af4bbb0debb4870df5a59331a447b 11990944 debug optional opensubdiv-tools-dbgsym_3.6.0-1_arm64.deb │ 69c37aca41d450a6e21c768275210c6a 566908 graphics optional opensubdiv-tools_3.6.0-1_arm64.deb ├── libosd-doc_3.6.0-1_all.deb │ ├── file list │ │ @@ -1,3 +1,3 @@ │ │ -rw-r--r-- 0 0 0 4 2024-01-06 14:18:14.000000 debian-binary │ │ --rw-r--r-- 0 0 0 25472 2024-01-06 14:18:14.000000 control.tar.xz │ │ --rw-r--r-- 0 0 0 31466880 2024-01-06 14:18:14.000000 data.tar.xz │ │ +-rw-r--r-- 0 0 0 25488 2024-01-06 14:18:14.000000 control.tar.xz │ │ +-rw-r--r-- 0 0 0 31467268 2024-01-06 14:18:14.000000 data.tar.xz │ ├── control.tar.xz │ │ ├── control.tar │ │ │ ├── ./md5sums │ │ │ │ ├── ./md5sums │ │ │ │ │┄ Files differ │ │ │ │ ├── line order │ │ │ │ │ @@ -47,17 +47,17 @@ │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00692_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00695.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00695.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00695_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00698.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00698.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00698_source.html │ │ │ │ │ -usr/share/doc/opensubdiv/doxy_html/a00701.html │ │ │ │ │ -usr/share/doc/opensubdiv/doxy_html/a00701.js │ │ │ │ │ -usr/share/doc/opensubdiv/doxy_html/a00701_source.html │ │ │ │ │ +usr/share/doc/opensubdiv/doxy_html/a00704.html │ │ │ │ │ +usr/share/doc/opensubdiv/doxy_html/a00704.js │ │ │ │ │ +usr/share/doc/opensubdiv/doxy_html/a00704_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00707.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00707.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00707_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00710.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00710.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00710_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00713.html │ │ │ │ │ @@ -115,17 +115,17 @@ │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00770_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00773.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00773.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00773_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00776.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00776_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00779.html │ │ │ │ │ +usr/share/doc/opensubdiv/doxy_html/a00779.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00779_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00782.html │ │ │ │ │ -usr/share/doc/opensubdiv/doxy_html/a00782.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00782_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00785.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00785_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00788.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00788.js │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00788_source.html │ │ │ │ │ usr/share/doc/opensubdiv/doxy_html/a00791.html │ ├── data.tar.xz │ │ ├── data.tar │ │ │ ├── file list │ │ │ │ @@ -27,20 +27,20 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 1660 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/css/doxy.css │ │ │ │ -rw-r--r-- 0 root (0) root (0) 27698 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/css/flavor.css │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5321 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/css/pygments.css │ │ │ │ -rw-r--r-- 0 root (0) root (0) 3011 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/css/renderman-university.css │ │ │ │ -rw-r--r-- 0 root (0) root (0) 12971 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/css/rst.css │ │ │ │ -rw-r--r-- 0 root (0) root (0) 14561 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/downloads.html │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/ │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7384 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00674.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 109 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00674.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 65515 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00674_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6575 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00677.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00677.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 76686 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00677_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6575 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00674.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00674.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 76686 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00674_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7384 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00677.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 109 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00677.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 65515 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00677_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 7310 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00680.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 195 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00680.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 27166 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00680_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6557 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00683.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 78 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00683.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 35227 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00683_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 7503 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00686.html │ │ │ │ @@ -54,53 +54,53 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 40417 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00692_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6435 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00695.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00695.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 45701 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00695_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6386 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00698.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 55 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00698.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 14298 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00698_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7836 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00701.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 190 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00701.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 147346 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00701_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 8006 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00707.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 171 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00707.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 74097 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00707_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6697 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00710.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 66 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00710.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 66667 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00710_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7135 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00713.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 119 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00713.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 38038 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00713_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 9467 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00716.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 404 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00716.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 84413 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00716_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 9922 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00719.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 456 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00719.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 177058 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00719_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6562 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00722.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 64 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00722.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 19419 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00722_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7812 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00725.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 163 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00725.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 67818 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00725_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 8222 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00728.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 130 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00728.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 212260 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00728_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7335 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00731.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 111 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00731.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 167870 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00731_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6744 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00734.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 103 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00734.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 42246 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00734_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7303 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00737.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 160 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00737.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 53847 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00737_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 8123 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00740.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 314 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00740.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 50493 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00740_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 8006 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00704.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 171 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00704.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 74097 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00704_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6697 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00707.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 66 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00707.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 66667 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00707_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7836 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00710.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 190 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00710.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 147346 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00710_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 9922 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00713.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 456 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00713.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 177058 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00713_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7135 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00716.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 119 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00716.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 38038 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00716_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 9467 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00719.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 404 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00719.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 84413 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00719_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 8222 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00722.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 130 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00722.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 212260 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00722_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6562 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00725.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 64 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00725.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 19419 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00725_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7812 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00728.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 163 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00728.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 67818 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00728_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6744 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00731.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 103 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00731.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 42246 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00731_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7335 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00734.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 111 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00734.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 167870 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00734_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 8123 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00737.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 314 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00737.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 50493 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00737_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7303 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00740.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 160 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00740.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 53847 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00740_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 11426 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00743.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 1173 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00743.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 22910 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00743_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5643 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00746.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 38293 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00746_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5898 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00749.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 22112 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00749_source.html │ │ │ │ @@ -121,19 +121,19 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 130 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00770.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 135866 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00770_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6297 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00773.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 60 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00773.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 38673 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00773_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5826 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00776.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 100441 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00776_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 5835 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00779.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 89789 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00779_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6473 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00782.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 59 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00782.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 53912 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00782_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6473 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00779.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 59 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00779.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 53912 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00779_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 5835 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00782.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 89789 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00782_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5752 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00785.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 38296 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00785_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6806 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00788.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 67 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00788.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 33909 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00788_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 7124 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00791.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 115 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00791.js │ │ │ │ @@ -142,62 +142,62 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 67 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00794.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 23840 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00794_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 4477 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00797.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 10582 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00797_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6896 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00800.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 65 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00800.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 34222 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00800_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7173 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00803.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 115 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00803.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 252039 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00803_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6160 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00806.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 63 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00806.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 14082 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00806_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6160 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00803.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 63 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00803.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 14082 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00803_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7173 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00806.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 115 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00806.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 252039 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00806_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6498 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00809.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00809.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 21924 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00809_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6579 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00812.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 99 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00812.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 12708 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00812_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6451 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00815.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 79 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00815.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 25441 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00815_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6817 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00818.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 66 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00818.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 35393 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00818_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6817 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00815.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 66 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00815.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 35393 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00815_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6451 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00818.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 79 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00818.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 25441 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00818_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 7051 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00821.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 124 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00821.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 223873 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00821_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6508 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00824.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 70 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00824.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 18295 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00824_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6245 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00827.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 71 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00827.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 22525 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00827_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6591 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00830.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 101 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00830.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 12825 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00830_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6245 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00824.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 71 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00824.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 22525 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00824_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6591 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00827.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 101 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00827.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 12825 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00827_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6508 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00830.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 70 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00830.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 18295 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00830_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6357 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00833.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 70 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00833.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 22932 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00833_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6765 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00836.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 68 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00836.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 27920 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00836_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6356 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00839.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 81 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00839.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 26983 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00839_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7016 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00842.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 128 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00842.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 49760 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00842_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6409 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00845.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 73 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00845.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 22722 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00845_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 7224 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00848.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 126 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00848.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 224156 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00848_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6409 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00842.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 73 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00842.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 22722 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00842_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7224 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00845.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 126 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00845.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 224156 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00845_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 7016 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00848.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 128 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00848.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 49760 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00848_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 7198 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00851.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 121 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00851.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 239107 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00851_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6508 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00854.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 70 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00854.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 18617 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00854_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6573 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00857.html │ │ │ │ @@ -234,20 +234,20 @@ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 182424 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00887_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6369 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00890.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 68 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00890.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 19253 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00890_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6910 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00893.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 66 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00893.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 44338 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00893_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6380 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00896.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 61 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00896.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 110646 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00896_source.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 6686 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00899.html │ │ │ │ --rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00899.js │ │ │ │ --rw-r--r-- 0 root (0) root (0) 27491 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00899_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6686 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00896.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00896.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 27491 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00896_source.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 6380 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00899.html │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 61 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00899.js │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 110646 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00899_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 6374 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00902.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 69 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00902.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 20015 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00902_source.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 4658 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00905.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 71 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00905.js │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5891 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00906.html │ │ │ │ -rw-r--r-- 0 root (0) root (0) 216 2024-01-06 14:18:14.000000 ./usr/share/doc/opensubdiv/doxy_html/a00906.js │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00674.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/bfr/tessellation.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/bfr/vertexDescriptor.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,29 +90,26 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
tessellation.h File Reference
│ │ │ │ +
vertexDescriptor.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../bfr/parameterization.h"
│ │ │ │ +#include "../vtr/stackBuffer.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  Tessellation
 Encapsulates a specific tessellation pattern of a Parameterization. More...
 
class  Tessellation::Options
 Options configure a Tessellation to specify the nature of both its results and the structure of the coordinate and facet index arrays that its methods will populate. More...
class  VertexDescriptor
 Simple class used by subclasses of SurfaceFactory to describe a vertex. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -121,13 +118,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,30 +1,25 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -tessellation.h File Reference │ │ │ │ │ +vertexDescriptor.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_b_f_r_/_p_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_s_t_a_c_k_B_u_f_f_e_r_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -  Encapsulates a specific tessellation pattern of a _P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n. │ │ │ │ │ +class   _V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +  Simple class used by subclasses of _S_u_r_f_a_c_e_F_a_c_t_o_r_y to describe a vertex. │ │ │ │ │ _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s │ │ │ │ │ - _O_p_t_i_o_n_s configure a _T_e_s_s_e_l_l_a_t_i_o_n to specify the nature of both its │ │ │ │ │ -  results and the structure of the coordinate and facet index arrays that │ │ │ │ │ - its methods will populate. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _b_f_r │ │ │ │ │ - * _t_e_s_s_e_l_l_a_t_i_o_n_._h │ │ │ │ │ + * _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00674.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,3 @@ │ │ │ │ │ var a00674 = [ │ │ │ │ │ - ["Tessellation", "a00961.html", "a00961"], │ │ │ │ │ - ["Options", "a00965.html", "a00965"] │ │ │ │ │ + ["VertexDescriptor", "a00969.html", "a00969"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00674_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/bfr/tessellation.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/bfr/vertexDescriptor.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
tessellation.h
│ │ │ │ +
vertexDescriptor.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2021 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,281 +119,425 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_BFR_TESSELLATION_H
│ │ │ │ -
26#define OPENSUBDIV3_BFR_TESSELLATION_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H
│ │ │ │ +
26#define OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../bfr/parameterization.h"
│ │ │ │ +
30#include "../vtr/stackBuffer.h"
│ │ │ │
31
│ │ │ │
32namespace OpenSubdiv {
│ │ │ │
33namespace OPENSUBDIV_VERSION {
│ │ │ │
34
│ │ │ │
35namespace Bfr {
│ │ │ │
36
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
52public:
│ │ │ │ -
│ │ │ │ -
65 class Options {
│ │ │ │ -
66 public:
│ │ │ │ -
│ │ │ │ -
67 Options() : _preserveQuads(false), _facetSize4(false),
│ │ │ │ -
68 _coordStride(0), _facetStride(0) { }
│ │ │ │ -
│ │ │ │ -
69
│ │ │ │ -
72 Options & PreserveQuads(bool on);
│ │ │ │ -
74 bool PreserveQuads() const { return _preserveQuads; }
│ │ │ │ -
75
│ │ │ │ -
78 Options & SetFacetSize(int numIndices);
│ │ │ │ -
79 // @brief Return the number of indices per facet
│ │ │ │ -
80 int GetFacetSize() const { return 3 + (int)_facetSize4; }
│ │ │ │ -
81
│ │ │ │ -
83 Options & SetFacetStride(int stride);
│ │ │ │ -
85 int GetFacetStride() const { return _facetStride; }
│ │ │ │ -
86
│ │ │ │ -
88 Options & SetCoordStride(int stride);
│ │ │ │ -
90 int GetCoordStride() const { return _coordStride; }
│ │ │ │ -
91
│ │ │ │ -
92 private:
│ │ │ │ -
93 unsigned int _preserveQuads : 1;
│ │ │ │ -
94 unsigned int _facetSize4 : 1;
│ │ │ │ -
95
│ │ │ │ -
96 short _coordStride;
│ │ │ │ -
97 short _facetStride;
│ │ │ │ -
98 };
│ │ │ │ -
│ │ │ │ -
99
│ │ │ │ -
100public:
│ │ │ │ -
102
│ │ │ │ -
111
│ │ │ │ -
118 Tessellation(Parameterization const & p, int uniformRate,
│ │ │ │ -
119 Options const & options = Options());
│ │ │ │ -
120
│ │ │ │ -
158 Tessellation(Parameterization const & p, int numRates, int const rates[],
│ │ │ │ -
159 Options const & options = Options());
│ │ │ │ -
160
│ │ │ │ -
162 bool IsValid() const { return _isValid; }
│ │ │ │ -
163
│ │ │ │ -
165 Tessellation() = delete;
│ │ │ │ -
166
│ │ │ │ -
167 Tessellation(Tessellation const &) = delete;
│ │ │ │ - │ │ │ │ - │ │ │ │ -
171
│ │ │ │ -
173
│ │ │ │ -
177
│ │ │ │ -
179 Parameterization GetParameterization() const { return _param; }
│ │ │ │ -
180
│ │ │ │ -
182 int GetFaceSize() const { return _param.GetFaceSize(); }
│ │ │ │ -
183
│ │ │ │ -
185 int GetRates(int rates[]) const;
│ │ │ │ -
186
│ │ │ │ -
188 bool IsUniform() const { return _isUniform; }
│ │ │ │ -
190
│ │ │ │ -
192
│ │ │ │ +
50//
│ │ │ │ +
51// WIP - need to migrate some of these comments into Doxygen
│ │ │ │ +
52// - others will be moved to the external documentation
│ │ │ │ +
53//
│ │ │ │ +
54// It is used by subclasses of SurfaceFactory to provide a complete
│ │ │ │ +
55// topological description for each vertex of a face, i.e. invoked via
│ │ │ │ +
56// the virtual method:
│ │ │ │ +
57//
│ │ │ │ +
58// int populateFaceVertexDescriptor(Index baseFace,
│ │ │ │ +
59// int cornerVertex,
│ │ │ │ +
60// VertexDescriptor & v) const;
│ │ │ │ +
61//
│ │ │ │ +
62// Assignment of the full topology can be involved in the presence of
│ │ │ │ +
63// irregular faces, non-manifold topology or creasing around a vertex, but
│ │ │ │ +
64// many cases will be simple. For example, to specify a regular boundary
│ │ │ │ +
65// vertex of a Catmark mesh without any optional sharpness:
│ │ │ │ +
66//
│ │ │ │ +
67// int numIncidentFaces = 2;
│ │ │ │ +
68// bool vertexOnBoundary = true;
│ │ │ │ +
69//
│ │ │ │ +
70// vd.Initialize(numIncidentFaces);
│ │ │ │ +
71// vd.SetManifold(true);
│ │ │ │ +
72// vd.SetBoundary(vertexOnBoundary);
│ │ │ │ +
73// vd.ClearIncidentFaceSizes();
│ │ │ │ +
74// vd.Finalize();
│ │ │ │ +
75//
│ │ │ │ +
76// For a more general example, to assign a vertex of some valence whose
│ │ │ │ +
77// incident faces are of different sizes (e.g. required when triangles
│ │ │ │ +
78// appear around a vertex in an otherwise quad-dominant Catmark mesh):
│ │ │ │ +
79//
│ │ │ │ +
80// int numIncidentFaces = meshVertex.GetNumIncidentFaces();
│ │ │ │ +
81// bool vertexOnBoundary = meshVertex.IsBoundar();
│ │ │ │ +
82//
│ │ │ │ +
83// vd.Initialize(numIncidentFaces);
│ │ │ │ +
84// vd.SetManifold(true);
│ │ │ │ +
85// vd.SetBoundary(vertexOnBoundary);
│ │ │ │ +
86//
│ │ │ │ +
87// for (int i = 0; i < numIncidentFaces; ++i) {
│ │ │ │ +
88// vd.SetIncidentFaceSize(i, meshVertex.GetIncidentFaceSize(i));
│ │ │ │ +
89// }
│ │ │ │ +
90// vd.Finalize();
│ │ │ │ +
91//
│ │ │ │ +
92// These examples specify the incident faces as forming a manifold ring
│ │ │ │ +
93// (or half-ring) around the vertex, i.e. they can be specified as a
│ │ │ │ +
94// continuous, connected sequence in counter-clockwise order (and also
│ │ │ │ +
95// without degeneracies). In the case of a boundary vertex, the first
│ │ │ │ +
96// face must be on the leading edge of the boundary while the last is on
│ │ │ │ +
97// the trailing edge. For an interior vertex, which face is specified
│ │ │ │ +
98// first does not matter (since the set is periodic).
│ │ │ │ +
99//
│ │ │ │ +
100// In both cases, the location of the base face in this sequence -- the
│ │ │ │ +
101// face whose corner vertex is being described here -- must be specified
│ │ │ │ +
102// in the return value to populateFaceVertexDescriptor() (e.g. when a
│ │ │ │ +
103// boundary vertex has 3 incident faces, a return value of 0, 1 or 2
│ │ │ │ +
104// will indicate which is the base face).
│ │ │ │ +
105//
│ │ │ │ +
106// The corresponding methods to specify mesh control vertex indices (or
│ │ │ │ +
107// face-varying indices) complete the specification of the neighborhood:
│ │ │ │ +
108//
│ │ │ │ +
109// int getFaceCornerVertexIndices(Index baseFace, int cornerVertex,
│ │ │ │ +
110// Index vertexIndices[]) const;
│ │ │ │ +
111//
│ │ │ │ +
112// int getFaceCornerFVarValueIndices(Index baseFace, int cornerVertex,
│ │ │ │ +
113// Index fvarValueIndices[],
│ │ │ │ +
114// int fvarChannel) const;
│ │ │ │ +
115//
│ │ │ │ +
116// and are invoked by the Factory when needed.
│ │ │ │ +
117//
│ │ │ │ +
118// For each incident face, the indices for all vertices of that face are
│ │ │ │ +
119// to be specified (not the one-ring or some other subset). These indices
│ │ │ │ +
120// must also be specified in an orientation relative to the vertex, i.e.
│ │ │ │ +
121// for a vertex A and an incident face with face-vertices that may be
│ │ │ │ +
122// stored internally as {D, C, A, B}, they must be specified with A first
│ │ │ │ +
123// as {A, B, C, D}. This may seem a bit cumbersome, but it has clear
│ │ │ │ +
124// advantages when dealing with face-varying indices and unordered faces.
│ │ │ │ +
125//
│ │ │ │ +
126// More compact ways of specifying vertex indices for ordered, manifold
│ │ │ │ +
127// cases may be worth exploring in future, but face-varying indices and
│ │ │ │ +
128// non-manifold (unordered) vertices will always require such a full set,
│ │ │ │ +
129// so both methods will need to co-exist.
│ │ │ │ +
130//
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
132public:
│ │ │ │ +
133 // The full declaration must be enclosed by calls to these methods:
│ │ │ │ +
134 //
│ │ │ │ +
135 // Note that vertex valences or face sizes in excess of those defined
│ │ │ │ +
136 // in Bfr::Limits (typically 16-bits) are not valid. When specifying
│ │ │ │ +
137 // values in excess of these limits, initialization will fail and/or
│ │ │ │ +
138 // the descriptor will be marked invalid and finalization will fail.
│ │ │ │ +
139 //
│ │ │ │ +
140
│ │ │ │ +
142
│ │ │ │ +
149
│ │ │ │ +
151 bool Initialize(int numIncidentFaces);
│ │ │ │ +
152
│ │ │ │ +
154 bool Finalize();
│ │ │ │ +
155
│ │ │ │ +
157 bool IsValid() const;
│ │ │ │ +
159
│ │ │ │ +
160 //
│ │ │ │ +
161 // WIP - need to migrate these comments into Doxygen
│ │ │ │ +
162 //
│ │ │ │ +
163 // Three groups of methods describe the topology around a vertex:
│ │ │ │ +
164 // - simple properties (vertex is a boundary, manifold, etc.)
│ │ │ │ +
165 // - sizes of incident faces (constant or size for each face)
│ │ │ │ +
166 // - sharpness of the vertex and its incident edges (optional)
│ │ │ │ +
167 //
│ │ │ │ +
168
│ │ │ │ +
169 // Manifold and boundary conditions:
│ │ │ │ +
170 //
│ │ │ │ +
171 // The manifold property is a strict condition but preferred for
│ │ │ │ +
172 // efficiency and is usually available from common connected mesh
│ │ │ │ +
173 // representations. When declaring the topology as "manifold",
│ │ │ │ +
174 // the Factory assumes the following:
│ │ │ │ +
175 //
│ │ │ │ +
176 // - all incident faces are "ordered" (counter-clockwise)
│ │ │ │ +
177 // - all incident faces are consistently oriented
│ │ │ │ +
178 // - all incident edges are non-degenerate
│ │ │ │ +
179 //
│ │ │ │ +
180 // If not certain that all of these conditions are met, it is best
│ │ │ │ +
181 // to not declare manifold -- leaving the Factory to make sense of
│ │ │ │ +
182 // the set of incident faces from the face-vertex indices that are
│ │ │ │ +
183 // provided elsewhere.
│ │ │ │ +
184 //
│ │ │ │ +
185
│ │ │ │ +
187
│ │ │ │ +
191
│ │ │ │ +
193 void SetManifold(bool isManifold);
│ │ │ │ +
194
│ │ │ │ +
196 void SetBoundary(bool isOnBoundary);
│ │ │ │ +
197
│ │ │ │ +
199 void SetIncidentFaceSize(int faceIndex, int faceSize);
│ │ │ │ +
200
│ │ │ │ + │ │ │ │
203
│ │ │ │ -
205 int GetNumCoords() const { return _numInteriorPoints + _numBoundaryPoints; }
│ │ │ │ +
205 void SetVertexSharpness(float sharpness);
│ │ │ │
206
│ │ │ │ -
208 int GetCoordStride() const { return _coordStride; }
│ │ │ │ + │ │ │ │
209
│ │ │ │ -
211 int GetNumBoundaryCoords() const { return _numBoundaryPoints; }
│ │ │ │ -
212
│ │ │ │ -
214 int GetNumInteriorCoords() const { return _numInteriorPoints; }
│ │ │ │ -
215
│ │ │ │ -
218 int GetNumEdgeCoords(int edge) const { return _outerRates[edge] - 1; }
│ │ │ │ -
219
│ │ │ │ -
221 template <typename REAL>
│ │ │ │ -
222 int GetCoords(REAL coordTuples[]) const;
│ │ │ │ -
223
│ │ │ │ -
225 template <typename REAL>
│ │ │ │ -
226 int GetBoundaryCoords(REAL coordTuples[]) const;
│ │ │ │ -
227
│ │ │ │ -
229 template <typename REAL>
│ │ │ │ -
230 int GetInteriorCoords(REAL coordTuples[]) const;
│ │ │ │ -
231
│ │ │ │ -
233 template <typename REAL>
│ │ │ │ -
234 int GetVertexCoord(int vertex, REAL coordTuples[]) const;
│ │ │ │ -
235
│ │ │ │ -
238 template <typename REAL>
│ │ │ │ -
239 int GetEdgeCoords(int edge, REAL coordTuples[]) const;
│ │ │ │ -
241
│ │ │ │ -
243
│ │ │ │ -
253
│ │ │ │ -
255 int GetNumFacets() const { return _numFacets; }
│ │ │ │ -
256
│ │ │ │ -
258 int GetFacetSize() const { return _facetSize; }
│ │ │ │ -
259
│ │ │ │ -
261 int GetFacetStride() const { return _facetStride; }
│ │ │ │ -
262
│ │ │ │ -
264 int GetFacets(int facetTuples[]) const;
│ │ │ │ +
221 void SetManifoldEdgeSharpness(int edgeIndex, float edgeSharpness);
│ │ │ │ +
222
│ │ │ │ +
238 void SetIncidentFaceEdgeSharpness(int faceIndex, float leadingEdgeSharp,
│ │ │ │ +
239 float trailingEdgeSharp);
│ │ │ │ +
240
│ │ │ │ +
242 void ClearEdgeSharpness();
│ │ │ │ +
244
│ │ │ │ +
246
│ │ │ │ +
251
│ │ │ │ +
253 bool IsManifold() const;
│ │ │ │ +
254
│ │ │ │ +
256 bool IsBoundary() const;
│ │ │ │ +
257
│ │ │ │ +
259 bool HasIncidentFaceSizes() const;
│ │ │ │ +
260
│ │ │ │ +
262 int GetIncidentFaceSize(int faceIndex) const;
│ │ │ │ +
263
│ │ │ │ +
265 bool HasVertexSharpness() const;
│ │ │ │
266
│ │ │ │ -
268
│ │ │ │ -
283
│ │ │ │ -
285 void TransformFacetCoordIndices(int facetTuples[], int commonOffset);
│ │ │ │ -
286
│ │ │ │ -
289 void TransformFacetCoordIndices(int facetTuples[],
│ │ │ │ -
290 int const boundaryIndices[],
│ │ │ │ -
291 int interiorOffset);
│ │ │ │ -
292
│ │ │ │ -
294 void TransformFacetCoordIndices(int facetTuples[],
│ │ │ │ -
295 int const boundaryIndices[],
│ │ │ │ -
296 int const interiorIndices[]);
│ │ │ │ -
298
│ │ │ │ -
299private:
│ │ │ │ -
300 // Private initialization methods:
│ │ │ │ -
301 bool validateArguments(Parameterization const & p,
│ │ │ │ -
302 int nRates, int const rates[], Options const & options);
│ │ │ │ -
303
│ │ │ │ -
304 void initialize(Parameterization const & p,
│ │ │ │ -
305 int nRates, int const rates[], Options const & options);
│ │ │ │ -
306
│ │ │ │ -
307 void initializeDefaults();
│ │ │ │ -
308 int initializeRates(int nRates, int const rates[]);
│ │ │ │ -
309 void initializeInventoryForParamTri(int sumOfOuterRates);
│ │ │ │ -
310 void initializeInventoryForParamQuad(int sumOfOuterRates);
│ │ │ │ -
311 void initializeInventoryForParamQPoly(int sumOfOuterRates);
│ │ │ │ -
312
│ │ │ │ -
313private:
│ │ │ │ -
314 // Private members:
│ │ │ │ -
315 Parameterization _param;
│ │ │ │ -
316
│ │ │ │ -
317 unsigned short _isValid : 1;
│ │ │ │ -
318 unsigned short _isUniform : 1;
│ │ │ │ -
319 unsigned short _triangulate : 1;
│ │ │ │ -
320 unsigned short _singleFace : 1;
│ │ │ │ -
321 unsigned short _segmentedFace : 1;
│ │ │ │ -
322 unsigned short _triangleFan : 1;
│ │ │ │ -
323 unsigned short _splitQuad : 1;
│ │ │ │ -
324
│ │ │ │ -
325 short _facetSize;
│ │ │ │ -
326 int _facetStride;
│ │ │ │ -
327 int _coordStride;
│ │ │ │ -
328
│ │ │ │ -
329 int _numGivenRates;
│ │ │ │ -
330 int _numBoundaryPoints;
│ │ │ │ -
331 int _numInteriorPoints;
│ │ │ │ -
332 int _numFacets;
│ │ │ │ -
333
│ │ │ │ -
334 int _innerRates[2];
│ │ │ │ -
335 int* _outerRates;
│ │ │ │ -
336 int _outerRatesLocal[4];
│ │ │ │ -
337};
│ │ │ │ -
│ │ │ │ -
338
│ │ │ │ -
339//
│ │ │ │ -
340// Inline implementations:
│ │ │ │ -
341//
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
344 _preserveQuads = on;
│ │ │ │ -
345 return *this;
│ │ │ │ -
346}
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
349 _facetSize4 = (numIndices == 4);
│ │ │ │ -
350 return *this;
│ │ │ │ -
351}
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
354 _facetStride = (short) stride;
│ │ │ │ -
355 return *this;
│ │ │ │ -
356}
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
359 _coordStride = (short) stride;
│ │ │ │ -
360 return *this;
│ │ │ │ -
361}
│ │ │ │ -
│ │ │ │ -
362
│ │ │ │ -
363template <typename REAL>
│ │ │ │ -
364inline int
│ │ │ │ -
│ │ │ │ -
365Tessellation::GetVertexCoord(int vertex, REAL coord[]) const {
│ │ │ │ -
366 _param.GetVertexCoord(vertex, coord);
│ │ │ │ -
367 return 1;
│ │ │ │ -
368}
│ │ │ │ -
│ │ │ │ -
369
│ │ │ │ -
370template <typename REAL>
│ │ │ │ -
371inline int
│ │ │ │ -
│ │ │ │ -
372Tessellation::GetCoords(REAL coordTuples[]) const {
│ │ │ │ -
373 int nCoords = GetBoundaryCoords(coordTuples);
│ │ │ │ -
374 nCoords += GetInteriorCoords(coordTuples + nCoords * _coordStride);
│ │ │ │ -
375 return nCoords;
│ │ │ │ -
376}
│ │ │ │ -
│ │ │ │ -
377
│ │ │ │ -
378} // end namespace Bfr
│ │ │ │ -
379
│ │ │ │ -
380} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
381using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
382
│ │ │ │ -
383} // end namespace OpenSubdiv
│ │ │ │ -
384
│ │ │ │ -
385#endif /* OPENSUBDIV3_BFR_TESSELLATION */
│ │ │ │ +
268 float GetVertexSharpness() const;
│ │ │ │ +
269
│ │ │ │ +
271 bool HasEdgeSharpness() const;
│ │ │ │ +
272
│ │ │ │ +
274 float GetManifoldEdgeSharpness(int edgeIndex) const;
│ │ │ │ +
275
│ │ │ │ +
277 void GetIncidentFaceEdgeSharpness(int faceIndex,
│ │ │ │ +
278 float * leadingEdgeSharp, float * trailingEdgeSharp) const;
│ │ │ │ +
280
│ │ │ │ +
281protected:
│ │ │ │ +
283 friend class FaceVertex;
│ │ │ │ +
284
│ │ │ │ +
285 VertexDescriptor() { }
│ │ │ │ + │ │ │ │ +
287
│ │ │ │ +
288 typedef Vtr::internal::StackBuffer<int,8,true> IntBuffer;
│ │ │ │ +
289 typedef Vtr::internal::StackBuffer<float,16,true> FloatBuffer;
│ │ │ │ +
290
│ │ │ │ +
291 void initFaceSizes();
│ │ │ │ +
292 void initEdgeSharpness();
│ │ │ │ +
294
│ │ │ │ +
295protected:
│ │ │ │ +
297 // Member variables assigned through the above interface:
│ │ │ │ +
298 unsigned short _isValid : 1;
│ │ │ │ +
299 unsigned short _isInitialized : 1;
│ │ │ │ +
300 unsigned short _isFinalized : 1;
│ │ │ │ +
301
│ │ │ │ +
302 unsigned short _isManifold : 1;
│ │ │ │ +
303 unsigned short _isBoundary : 1;
│ │ │ │ +
304
│ │ │ │ +
305 unsigned short _hasFaceSizes : 1;
│ │ │ │ +
306 unsigned short _hasEdgeSharpness : 1;
│ │ │ │ +
307
│ │ │ │ +
308 short _numFaces;
│ │ │ │ +
309 float _vertSharpness;
│ │ │ │ +
310
│ │ │ │ +
311 FloatBuffer _faceEdgeSharpness;
│ │ │ │ +
312 IntBuffer _faceSizeOffsets;
│ │ │ │ +
314};
│ │ │ │ +
│ │ │ │ +
315
│ │ │ │ +
316//
│ │ │ │ +
317// Public inline methods for simple assignment:
│ │ │ │ +
318//
│ │ │ │ +
319inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
321 return _isValid;
│ │ │ │ +
322}
│ │ │ │ +
│ │ │ │ +
323
│ │ │ │ +
324inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
326 _isManifold = isManifold;
│ │ │ │ +
327}
│ │ │ │ +
│ │ │ │ +
328inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
330 return _isManifold;
│ │ │ │ +
331}
│ │ │ │ +
│ │ │ │ +
332
│ │ │ │ +
333inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
335 _isBoundary = isBoundary;
│ │ │ │ +
336}
│ │ │ │ +
│ │ │ │ +
337inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
339 return _isBoundary;
│ │ │ │ +
340}
│ │ │ │ +
│ │ │ │ +
341
│ │ │ │ +
342//
│ │ │ │ +
343// Public inline methods involving sizes of incident faces:
│ │ │ │ +
344//
│ │ │ │ +
345inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
347 return _hasFaceSizes;
│ │ │ │ +
348}
│ │ │ │ +
│ │ │ │ +
349inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
351 _hasFaceSizes = false;
│ │ │ │ +
352}
│ │ │ │ +
│ │ │ │ +
353
│ │ │ │ +
354inline void
│ │ │ │ +
│ │ │ │ +
355VertexDescriptor::SetIncidentFaceSize(int incFaceIndex, int faceSize) {
│ │ │ │ +
356
│ │ │ │ +
357 if (!_hasFaceSizes) initFaceSizes();
│ │ │ │ +
358
│ │ │ │ +
359 _faceSizeOffsets[incFaceIndex] = faceSize;
│ │ │ │ +
360}
│ │ │ │ +
│ │ │ │ +
361inline int
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
363
│ │ │ │ +
364 return _isFinalized ?
│ │ │ │ +
365 (_faceSizeOffsets[incFaceIndex+1] - _faceSizeOffsets[incFaceIndex]) :
│ │ │ │ +
366 _faceSizeOffsets[incFaceIndex];
│ │ │ │ +
367}
│ │ │ │ +
│ │ │ │ +
368
│ │ │ │ +
369//
│ │ │ │ +
370// Public inline methods involving vertex sharpness:
│ │ │ │ +
371//
│ │ │ │ +
372inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
374 return _vertSharpness > 0.0f;
│ │ │ │ +
375}
│ │ │ │ +
│ │ │ │ +
376inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
378 _vertSharpness = 0.0f;
│ │ │ │ +
379}
│ │ │ │ +
│ │ │ │ +
380
│ │ │ │ +
381inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
383 _vertSharpness = vertSharpness;
│ │ │ │ +
384}
│ │ │ │ +
│ │ │ │ +
385inline float
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
387 return _vertSharpness;
│ │ │ │ +
388}
│ │ │ │ +
│ │ │ │ +
389
│ │ │ │ +
390//
│ │ │ │ +
391// Public inline methods involving vertex sharpness:
│ │ │ │ +
392//
│ │ │ │ +
393inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
395 return _hasEdgeSharpness;
│ │ │ │ +
396}
│ │ │ │ +
│ │ │ │ +
397inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
399 _hasEdgeSharpness = false;
│ │ │ │ +
400}
│ │ │ │ +
│ │ │ │ +
401
│ │ │ │ +
402inline void
│ │ │ │ +
│ │ │ │ +
403VertexDescriptor::SetManifoldEdgeSharpness(int edgeIndex, float sharpness) {
│ │ │ │ +
404
│ │ │ │ +
405 if (!_hasEdgeSharpness) initEdgeSharpness();
│ │ │ │ +
406
│ │ │ │ +
407 // Assign the leading edge of the face after the edge (even index):
│ │ │ │ +
408 if (edgeIndex < _numFaces) {
│ │ │ │ +
409 _faceEdgeSharpness[2*edgeIndex] = sharpness;
│ │ │ │ +
410 }
│ │ │ │ +
411
│ │ │ │ +
412 // Assign the trailing edge of the face before the edge (odd index):
│ │ │ │ +
413 if (edgeIndex > 0) {
│ │ │ │ +
414 _faceEdgeSharpness[2*edgeIndex-1] = sharpness;
│ │ │ │ +
415 } else if (!IsBoundary()) {
│ │ │ │ +
416 _faceEdgeSharpness[2*_numFaces-1] = sharpness;
│ │ │ │ +
417 }
│ │ │ │ +
418}
│ │ │ │ +
│ │ │ │ +
419inline float
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
421
│ │ │ │ +
422 // All edges are first of the pair (even index) except last of boundary
│ │ │ │ +
423 return _faceEdgeSharpness[2*edgeIndex - (edgeIndex == _numFaces)];
│ │ │ │ +
424}
│ │ │ │ +
│ │ │ │ +
425
│ │ │ │ +
426inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
428 float leadingEdgeSharpness, float trailingEdgeSharpness) {
│ │ │ │ +
429
│ │ │ │ +
430 if (!_hasEdgeSharpness) initEdgeSharpness();
│ │ │ │ +
431
│ │ │ │ +
432 _faceEdgeSharpness[2*faceIndex ] = leadingEdgeSharpness;
│ │ │ │ +
433 _faceEdgeSharpness[2*faceIndex+1] = trailingEdgeSharpness;
│ │ │ │ +
434}
│ │ │ │ +
│ │ │ │ +
435inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
437 float * leadingEdgeSharpness, float * trailingEdgeSharpness) const {
│ │ │ │ +
438
│ │ │ │ +
439 *leadingEdgeSharpness = _faceEdgeSharpness[2*faceIndex];
│ │ │ │ +
440 *trailingEdgeSharpness = _faceEdgeSharpness[2*faceIndex+1];
│ │ │ │ +
441}
│ │ │ │ +
│ │ │ │ +
442
│ │ │ │ +
443} // end namespace Bfr
│ │ │ │ +
444
│ │ │ │ +
445} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
446using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
447} // end namespace OpenSubdiv
│ │ │ │ +
448
│ │ │ │ +
449#endif /* OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H */
│ │ │ │ │ │ │ │ -
Simple class defining the 2D parameterization of a face.
│ │ │ │ -
int GetFaceSize() const
Returns the size (number of vertices) of the corresponding face.
│ │ │ │ -
void GetVertexCoord(int vertexIndex, REAL uvCoord[2]) const
Returns the (u,v) coordinate of a given vertex.
│ │ │ │ -
Encapsulates a specific tessellation pattern of a Parameterization.
│ │ │ │ -
int GetFaceSize() const
Return the size of the face.
│ │ │ │ -
int GetNumBoundaryCoords() const
Return the number of boundary coordinates.
│ │ │ │ - │ │ │ │ -
void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], int const interiorIndices[])
Reassign all facet coordinate indices.
│ │ │ │ -
int GetCoordStride() const
Return the number of elements between each coordinate.
│ │ │ │ -
int GetNumEdgeCoords(int edge) const
Return the number of coordinates within a given edge (excluding those at its end vertices)
│ │ │ │ -
int GetInteriorCoords(REAL coordTuples[]) const
Retrieve the coordinates for the boundary.
│ │ │ │ -
int GetFacetStride() const
Return the number of elements between each facet.
│ │ │ │ -
bool IsUniform() const
Return if the pattern is uniform.
│ │ │ │ -
int GetNumCoords() const
Return the number of coordinates in the entire pattern.
│ │ │ │ -
int GetCoords(REAL coordTuples[]) const
Retrieve the coordinates for the entire pattern.
│ │ │ │ -
void TransformFacetCoordIndices(int facetTuples[], int commonOffset)
Apply a common offset to all facet coordinate indices.
│ │ │ │ -
Tessellation(Parameterization const &p, int numRates, int const rates[], Options const &options=Options())
General constructor providing multiple tessellation rates for a non-uniform tessellation.
│ │ │ │ -
Parameterization GetParameterization() const
Return the Parameterization.
│ │ │ │ -
void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], int interiorOffset)
Reassign indices of boundary coordinates while offseting those of interior coordinates.
│ │ │ │ -
int GetFacetSize() const
Return the number of indices assigned to each facet.
│ │ │ │ -
Tessellation()=delete
Default construction is unavailable.
│ │ │ │ -
Tessellation(Parameterization const &p, int uniformRate, Options const &options=Options())
Simple constructor providing a single uniform tessellation rate.
│ │ │ │ -
int GetFacets(int facetTuples[]) const
Retrieve the facet indices for the entire pattern.
│ │ │ │ -
int GetNumFacets() const
Return the number of facets in the entire pattern.
│ │ │ │ -
int GetNumInteriorCoords() const
Return the number of interior coordinates.
│ │ │ │ -
int GetVertexCoord(int vertex, REAL coordTuples[]) const
Retrieve the coordinate for a given vertex of the face.
│ │ │ │ -
int GetBoundaryCoords(REAL coordTuples[]) const
Retrieve the coordinates for the boundary.
│ │ │ │ - │ │ │ │ -
int GetRates(int rates[]) const
Retrieve the rates assigned.
│ │ │ │ -
bool IsValid() const
Return true if correctly initialized.
│ │ │ │ -
Tessellation & operator=(Tessellation const &)=delete
│ │ │ │ -
int GetEdgeCoords(int edge, REAL coordTuples[]) const
Retrieve the coordinates for a given edge of the face (excluding those at its end vertices)
│ │ │ │ -
Options configure a Tessellation to specify the nature of both its results and the structure of the c...
│ │ │ │ - │ │ │ │ -
int GetCoordStride() const
Return the stride between (u,v) pairs.
│ │ │ │ -
Options & SetFacetSize(int numIndices)
Assign the number of indices per facet (must be 3 or 4, default is 3)
│ │ │ │ -
int GetFacetStride() const
Return the stride between facets.
│ │ │ │ - │ │ │ │ -
Options & SetCoordStride(int stride)
Assign the stride between (u,v) pairs (default is 2)
│ │ │ │ -
Options & SetFacetStride(int stride)
Assign the stride between facets (default is facet size)
│ │ │ │ -
bool PreserveQuads() const
Return if preservation of quads is set.
│ │ │ │ +
Simple class used by subclasses of SurfaceFactory to describe a vertex.
│ │ │ │ +
float GetVertexSharpness() const
Return the sharpness of the vertex.
│ │ │ │ +
bool Finalize()
Terminate the sequence of specifications.
│ │ │ │ +
void SetManifold(bool isManifold)
Declare the vertex neighborhood as manifold (ordered)
│ │ │ │ +
bool Initialize(int numIncidentFaces)
Initialize specification with the number of incident faces.
│ │ │ │ +
bool IsManifold() const
Return if vertex neighborhood is manifold.
│ │ │ │ +
bool HasEdgeSharpness() const
Return if sharpness was assigned to the incident edges.
│ │ │ │ +
int GetIncidentFaceSize(int faceIndex) const
Return the size of an incident face.
│ │ │ │ +
float GetManifoldEdgeSharpness(int edgeIndex) const
Return the sharpness assigned to a manifold edge.
│ │ │ │ +
void SetIncidentFaceEdgeSharpness(int faceIndex, float leadingEdgeSharp, float trailingEdgeSharp)
Assign sharpness to the edges of an incident face.
│ │ │ │ +
bool HasVertexSharpness() const
Return if sharpness was assigned to the vertex.
│ │ │ │ +
void ClearIncidentFaceSizes()
Remove any assigned sizes of incident faces.
│ │ │ │ +
void SetVertexSharpness(float sharpness)
Assign sharpness to the vertex.
│ │ │ │ +
void ClearVertexSharpness()
Remove any sharpness assigned to the vertex.
│ │ │ │ +
void ClearEdgeSharpness()
Remove any sharpness assigned to the incident edges.
│ │ │ │ +
void GetIncidentFaceEdgeSharpness(int faceIndex, float *leadingEdgeSharp, float *trailingEdgeSharp) const
Return the sharpness assigned to edges of an incident face.
│ │ │ │ +
bool IsBoundary() const
Return if vertex neighborhood is on a boundary.
│ │ │ │ +
bool IsValid() const
Return if instance is valid.
│ │ │ │ +
bool HasIncidentFaceSizes() const
Return if the sizes of incident faces are assigned.
│ │ │ │ +
void SetBoundary(bool isOnBoundary)
Declare the vertex neighborhood as being on a boundary.
│ │ │ │ +
void SetIncidentFaceSize(int faceIndex, int faceSize)
Assign the size of an incident face.
│ │ │ │ +
void SetManifoldEdgeSharpness(int edgeIndex, float edgeSharpness)
Assign sharpness to the edge of a manifold neighborhood.
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -tessellation.h │ │ │ │ │ +vertexDescriptor.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2021 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,367 +24,446 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_BFR_TESSELLATION_H │ │ │ │ │ -26#define OPENSUBDIV3_BFR_TESSELLATION_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H │ │ │ │ │ +26#define OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../bfr/parameterization.h" │ │ │ │ │ +30#include "../vtr/stackBuffer.h" │ │ │ │ │ 31 │ │ │ │ │ 32namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ 33namespace OPENSUBDIV_VERSION { │ │ │ │ │ 34 │ │ │ │ │ 35namespace Bfr { │ │ │ │ │ 36 │ │ │ │ │ -_5_1class _T_e_s_s_e_l_l_a_t_i_o_n { │ │ │ │ │ -52public: │ │ │ │ │ -_6_5 class _O_p_t_i_o_n_s { │ │ │ │ │ -66 public: │ │ │ │ │ -_6_7 _O_p_t_i_o_n_s() : _preserveQuads(false), _facetSize4(false), │ │ │ │ │ -68 _coordStride(0), _facetStride(0) { } │ │ │ │ │ -69 │ │ │ │ │ -72 _O_p_t_i_o_n_s & _P_r_e_s_e_r_v_e_Q_u_a_d_s(bool on); │ │ │ │ │ -_7_4 bool _P_r_e_s_e_r_v_e_Q_u_a_d_s() const { return _preserveQuads; } │ │ │ │ │ -75 │ │ │ │ │ -78 _O_p_t_i_o_n_s & _S_e_t_F_a_c_e_t_S_i_z_e(int numIndices); │ │ │ │ │ -79 // @brief Return the number of indices per facet │ │ │ │ │ -_8_0 int _G_e_t_F_a_c_e_t_S_i_z_e() const { return 3 + (int)_facetSize4; } │ │ │ │ │ -81 │ │ │ │ │ -83 _O_p_t_i_o_n_s & _S_e_t_F_a_c_e_t_S_t_r_i_d_e(int stride); │ │ │ │ │ -_8_5 int _G_e_t_F_a_c_e_t_S_t_r_i_d_e() const { return _facetStride; } │ │ │ │ │ -86 │ │ │ │ │ -88 _O_p_t_i_o_n_s & _S_e_t_C_o_o_r_d_S_t_r_i_d_e(int stride); │ │ │ │ │ -_9_0 int _G_e_t_C_o_o_r_d_S_t_r_i_d_e() const { return _coordStride; } │ │ │ │ │ -91 │ │ │ │ │ -92 private: │ │ │ │ │ -93 unsigned int _preserveQuads : 1; │ │ │ │ │ -94 unsigned int _facetSize4 : 1; │ │ │ │ │ -95 │ │ │ │ │ -96 short _coordStride; │ │ │ │ │ -97 short _facetStride; │ │ │ │ │ -98 }; │ │ │ │ │ -99 │ │ │ │ │ -100public: │ │ │ │ │ -102 │ │ │ │ │ -111 │ │ │ │ │ -_1_1_8 _T_e_s_s_e_l_l_a_t_i_o_n(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, int uniformRate, │ │ │ │ │ -119 _O_p_t_i_o_n_s const & options = _O_p_t_i_o_n_s()); │ │ │ │ │ -120 │ │ │ │ │ -_1_5_8 _T_e_s_s_e_l_l_a_t_i_o_n(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, int numRates, int const rates[], │ │ │ │ │ -159 _O_p_t_i_o_n_s const & options = _O_p_t_i_o_n_s()); │ │ │ │ │ -160 │ │ │ │ │ -_1_6_2 bool _I_s_V_a_l_i_d() const { return _isValid; } │ │ │ │ │ -163 │ │ │ │ │ -_1_6_5 _T_e_s_s_e_l_l_a_t_i_o_n() = delete; │ │ │ │ │ -166 │ │ │ │ │ -_1_6_7 _T_e_s_s_e_l_l_a_t_i_o_n(_T_e_s_s_e_l_l_a_t_i_o_n const &) = delete; │ │ │ │ │ -_1_6_8 _T_e_s_s_e_l_l_a_t_i_o_n & _o_p_e_r_a_t_o_r_=(_T_e_s_s_e_l_l_a_t_i_o_n const &) = delete; │ │ │ │ │ -_1_6_9 _~_T_e_s_s_e_l_l_a_t_i_o_n(); │ │ │ │ │ -171 │ │ │ │ │ -173 │ │ │ │ │ -177 │ │ │ │ │ -_1_7_9 _P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n _G_e_t_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n() const { return _param; } │ │ │ │ │ -180 │ │ │ │ │ -_1_8_2 int _G_e_t_F_a_c_e_S_i_z_e() const { return _param._G_e_t_F_a_c_e_S_i_z_e(); } │ │ │ │ │ -183 │ │ │ │ │ -_1_8_5 int _G_e_t_R_a_t_e_s(int rates[]) const; │ │ │ │ │ -186 │ │ │ │ │ -_1_8_8 bool _I_s_U_n_i_f_o_r_m() const { return _isUniform; } │ │ │ │ │ -190 │ │ │ │ │ -192 │ │ │ │ │ +50// │ │ │ │ │ +51// WIP - need to migrate some of these comments into Doxygen │ │ │ │ │ +52// - others will be moved to the external documentation │ │ │ │ │ +53// │ │ │ │ │ +54// It is used by subclasses of SurfaceFactory to provide a complete │ │ │ │ │ +55// topological description for each vertex of a face, i.e. invoked via │ │ │ │ │ +56// the virtual method: │ │ │ │ │ +57// │ │ │ │ │ +58// int populateFaceVertexDescriptor(Index baseFace, │ │ │ │ │ +59// int cornerVertex, │ │ │ │ │ +60// VertexDescriptor & v) const; │ │ │ │ │ +61// │ │ │ │ │ +62// Assignment of the full topology can be involved in the presence of │ │ │ │ │ +63// irregular faces, non-manifold topology or creasing around a vertex, but │ │ │ │ │ +64// many cases will be simple. For example, to specify a regular boundary │ │ │ │ │ +65// vertex of a Catmark mesh without any optional sharpness: │ │ │ │ │ +66// │ │ │ │ │ +67// int numIncidentFaces = 2; │ │ │ │ │ +68// bool vertexOnBoundary = true; │ │ │ │ │ +69// │ │ │ │ │ +70// vd.Initialize(numIncidentFaces); │ │ │ │ │ +71// vd.SetManifold(true); │ │ │ │ │ +72// vd.SetBoundary(vertexOnBoundary); │ │ │ │ │ +73// vd.ClearIncidentFaceSizes(); │ │ │ │ │ +74// vd.Finalize(); │ │ │ │ │ +75// │ │ │ │ │ +76// For a more general example, to assign a vertex of some valence whose │ │ │ │ │ +77// incident faces are of different sizes (e.g. required when triangles │ │ │ │ │ +78// appear around a vertex in an otherwise quad-dominant Catmark mesh): │ │ │ │ │ +79// │ │ │ │ │ +80// int numIncidentFaces = meshVertex.GetNumIncidentFaces(); │ │ │ │ │ +81// bool vertexOnBoundary = meshVertex.IsBoundar(); │ │ │ │ │ +82// │ │ │ │ │ +83// vd.Initialize(numIncidentFaces); │ │ │ │ │ +84// vd.SetManifold(true); │ │ │ │ │ +85// vd.SetBoundary(vertexOnBoundary); │ │ │ │ │ +86// │ │ │ │ │ +87// for (int i = 0; i < numIncidentFaces; ++i) { │ │ │ │ │ +88// vd.SetIncidentFaceSize(i, meshVertex.GetIncidentFaceSize(i)); │ │ │ │ │ +89// } │ │ │ │ │ +90// vd.Finalize(); │ │ │ │ │ +91// │ │ │ │ │ +92// These examples specify the incident faces as forming a manifold ring │ │ │ │ │ +93// (or half-ring) around the vertex, i.e. they can be specified as a │ │ │ │ │ +94// continuous, connected sequence in counter-clockwise order (and also │ │ │ │ │ +95// without degeneracies). In the case of a boundary vertex, the first │ │ │ │ │ +96// face must be on the leading edge of the boundary while the last is on │ │ │ │ │ +97// the trailing edge. For an interior vertex, which face is specified │ │ │ │ │ +98// first does not matter (since the set is periodic). │ │ │ │ │ +99// │ │ │ │ │ +100// In both cases, the location of the base face in this sequence -- the │ │ │ │ │ +101// face whose corner vertex is being described here -- must be specified │ │ │ │ │ +102// in the return value to populateFaceVertexDescriptor() (e.g. when a │ │ │ │ │ +103// boundary vertex has 3 incident faces, a return value of 0, 1 or 2 │ │ │ │ │ +104// will indicate which is the base face). │ │ │ │ │ +105// │ │ │ │ │ +106// The corresponding methods to specify mesh control vertex indices (or │ │ │ │ │ +107// face-varying indices) complete the specification of the neighborhood: │ │ │ │ │ +108// │ │ │ │ │ +109// int getFaceCornerVertexIndices(Index baseFace, int cornerVertex, │ │ │ │ │ +110// Index vertexIndices[]) const; │ │ │ │ │ +111// │ │ │ │ │ +112// int getFaceCornerFVarValueIndices(Index baseFace, int cornerVertex, │ │ │ │ │ +113// Index fvarValueIndices[], │ │ │ │ │ +114// int fvarChannel) const; │ │ │ │ │ +115// │ │ │ │ │ +116// and are invoked by the Factory when needed. │ │ │ │ │ +117// │ │ │ │ │ +118// For each incident face, the indices for all vertices of that face are │ │ │ │ │ +119// to be specified (not the one-ring or some other subset). These indices │ │ │ │ │ +120// must also be specified in an orientation relative to the vertex, i.e. │ │ │ │ │ +121// for a vertex A and an incident face with face-vertices that may be │ │ │ │ │ +122// stored internally as {D, C, A, B}, they must be specified with A first │ │ │ │ │ +123// as {A, B, C, D}. This may seem a bit cumbersome, but it has clear │ │ │ │ │ +124// advantages when dealing with face-varying indices and unordered faces. │ │ │ │ │ +125// │ │ │ │ │ +126// More compact ways of specifying vertex indices for ordered, manifold │ │ │ │ │ +127// cases may be worth exploring in future, but face-varying indices and │ │ │ │ │ +128// non-manifold (unordered) vertices will always require such a full set, │ │ │ │ │ +129// so both methods will need to co-exist. │ │ │ │ │ +130// │ │ │ │ │ +_1_3_1class _V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ +132public: │ │ │ │ │ +133 // The full declaration must be enclosed by calls to these methods: │ │ │ │ │ +134 // │ │ │ │ │ +135 // Note that vertex valences or face sizes in excess of those defined │ │ │ │ │ +136 // in Bfr::Limits (typically 16-bits) are not valid. When specifying │ │ │ │ │ +137 // values in excess of these limits, initialization will fail and/or │ │ │ │ │ +138 // the descriptor will be marked invalid and finalization will fail. │ │ │ │ │ +139 // │ │ │ │ │ +140 │ │ │ │ │ +142 │ │ │ │ │ +149 │ │ │ │ │ +_1_5_1 bool _I_n_i_t_i_a_l_i_z_e(int numIncidentFaces); │ │ │ │ │ +152 │ │ │ │ │ +_1_5_4 bool _F_i_n_a_l_i_z_e(); │ │ │ │ │ +155 │ │ │ │ │ +157 bool _I_s_V_a_l_i_d() const; │ │ │ │ │ +159 │ │ │ │ │ +160 // │ │ │ │ │ +161 // WIP - need to migrate these comments into Doxygen │ │ │ │ │ +162 // │ │ │ │ │ +163 // Three groups of methods describe the topology around a vertex: │ │ │ │ │ +164 // - simple properties (vertex is a boundary, manifold, etc.) │ │ │ │ │ +165 // - sizes of incident faces (constant or size for each face) │ │ │ │ │ +166 // - sharpness of the vertex and its incident edges (optional) │ │ │ │ │ +167 // │ │ │ │ │ +168 │ │ │ │ │ +169 // Manifold and boundary conditions: │ │ │ │ │ +170 // │ │ │ │ │ +171 // The manifold property is a strict condition but preferred for │ │ │ │ │ +172 // efficiency and is usually available from common connected mesh │ │ │ │ │ +173 // representations. When declaring the topology as "manifold", │ │ │ │ │ +174 // the Factory assumes the following: │ │ │ │ │ +175 // │ │ │ │ │ +176 // - all incident faces are "ordered" (counter-clockwise) │ │ │ │ │ +177 // - all incident faces are consistently oriented │ │ │ │ │ +178 // - all incident edges are non-degenerate │ │ │ │ │ +179 // │ │ │ │ │ +180 // If not certain that all of these conditions are met, it is best │ │ │ │ │ +181 // to not declare manifold -- leaving the Factory to make sense of │ │ │ │ │ +182 // the set of incident faces from the face-vertex indices that are │ │ │ │ │ +183 // provided elsewhere. │ │ │ │ │ +184 // │ │ │ │ │ +185 │ │ │ │ │ +187 │ │ │ │ │ +191 │ │ │ │ │ +193 void _S_e_t_M_a_n_i_f_o_l_d(bool isManifold); │ │ │ │ │ +194 │ │ │ │ │ +196 void _S_e_t_B_o_u_n_d_a_r_y(bool isOnBoundary); │ │ │ │ │ +197 │ │ │ │ │ +199 void _S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int faceIndex, int faceSize); │ │ │ │ │ +200 │ │ │ │ │ +202 void _C_l_e_a_r_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s(); │ │ │ │ │ 203 │ │ │ │ │ -_2_0_5 int _G_e_t_N_u_m_C_o_o_r_d_s() const { return _numInteriorPoints + _numBoundaryPoints; │ │ │ │ │ -} │ │ │ │ │ +205 void _S_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float sharpness); │ │ │ │ │ 206 │ │ │ │ │ -_2_0_8 int _G_e_t_C_o_o_r_d_S_t_r_i_d_e() const { return _coordStride; } │ │ │ │ │ +208 void _C_l_e_a_r_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(); │ │ │ │ │ 209 │ │ │ │ │ -_2_1_1 int _G_e_t_N_u_m_B_o_u_n_d_a_r_y_C_o_o_r_d_s() const { return _numBoundaryPoints; } │ │ │ │ │ -212 │ │ │ │ │ -_2_1_4 int _G_e_t_N_u_m_I_n_t_e_r_i_o_r_C_o_o_r_d_s() const { return _numInteriorPoints; } │ │ │ │ │ -215 │ │ │ │ │ -_2_1_8 int _G_e_t_N_u_m_E_d_g_e_C_o_o_r_d_s(int edge) const { return _outerRates[edge] - 1; } │ │ │ │ │ -219 │ │ │ │ │ -221 template │ │ │ │ │ -222 int _G_e_t_C_o_o_r_d_s(REAL coordTuples[]) const; │ │ │ │ │ -223 │ │ │ │ │ -225 template │ │ │ │ │ -_2_2_6 int _G_e_t_B_o_u_n_d_a_r_y_C_o_o_r_d_s(REAL coordTuples[]) const; │ │ │ │ │ -227 │ │ │ │ │ -229 template │ │ │ │ │ -_2_3_0 int _G_e_t_I_n_t_e_r_i_o_r_C_o_o_r_d_s(REAL coordTuples[]) const; │ │ │ │ │ -231 │ │ │ │ │ -233 template │ │ │ │ │ -234 int _G_e_t_V_e_r_t_e_x_C_o_o_r_d(int vertex, REAL coordTuples[]) const; │ │ │ │ │ -235 │ │ │ │ │ -238 template │ │ │ │ │ -_2_3_9 int _G_e_t_E_d_g_e_C_o_o_r_d_s(int edge, REAL coordTuples[]) const; │ │ │ │ │ -241 │ │ │ │ │ -243 │ │ │ │ │ -253 │ │ │ │ │ -_2_5_5 int _G_e_t_N_u_m_F_a_c_e_t_s() const { return _numFacets; } │ │ │ │ │ -256 │ │ │ │ │ -_2_5_8 int _G_e_t_F_a_c_e_t_S_i_z_e() const { return _facetSize; } │ │ │ │ │ -259 │ │ │ │ │ -_2_6_1 int _G_e_t_F_a_c_e_t_S_t_r_i_d_e() const { return _facetStride; } │ │ │ │ │ -262 │ │ │ │ │ -_2_6_4 int _G_e_t_F_a_c_e_t_s(int facetTuples[]) const; │ │ │ │ │ +221 void _S_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex, float edgeSharpness); │ │ │ │ │ +222 │ │ │ │ │ +238 void _S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, float leadingEdgeSharp, │ │ │ │ │ +239 float trailingEdgeSharp); │ │ │ │ │ +240 │ │ │ │ │ +242 void _C_l_e_a_r_E_d_g_e_S_h_a_r_p_n_e_s_s(); │ │ │ │ │ +244 │ │ │ │ │ +246 │ │ │ │ │ +251 │ │ │ │ │ +253 bool _I_s_M_a_n_i_f_o_l_d() const; │ │ │ │ │ +254 │ │ │ │ │ +256 bool _I_s_B_o_u_n_d_a_r_y() const; │ │ │ │ │ +257 │ │ │ │ │ +259 bool _H_a_s_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s() const; │ │ │ │ │ +260 │ │ │ │ │ +262 int _G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int faceIndex) const; │ │ │ │ │ +263 │ │ │ │ │ +265 bool _H_a_s_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const; │ │ │ │ │ 266 │ │ │ │ │ -268 │ │ │ │ │ -283 │ │ │ │ │ -_2_8_5 void _T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s(int facetTuples[], int commonOffset); │ │ │ │ │ -286 │ │ │ │ │ -_2_8_9 void _T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s(int facetTuples[], │ │ │ │ │ -290 int const boundaryIndices[], │ │ │ │ │ -291 int interiorOffset); │ │ │ │ │ -292 │ │ │ │ │ -_2_9_4 void _T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s(int facetTuples[], │ │ │ │ │ -295 int const boundaryIndices[], │ │ │ │ │ -296 int const interiorIndices[]); │ │ │ │ │ -298 │ │ │ │ │ -299private: │ │ │ │ │ -300 // Private initialization methods: │ │ │ │ │ -301 bool validateArguments(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, │ │ │ │ │ -302 int nRates, int const rates[], _O_p_t_i_o_n_s const & options); │ │ │ │ │ -303 │ │ │ │ │ -304 void initialize(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, │ │ │ │ │ -305 int nRates, int const rates[], _O_p_t_i_o_n_s const & options); │ │ │ │ │ -306 │ │ │ │ │ -307 void initializeDefaults(); │ │ │ │ │ -308 int initializeRates(int nRates, int const rates[]); │ │ │ │ │ -309 void initializeInventoryForParamTri(int sumOfOuterRates); │ │ │ │ │ -310 void initializeInventoryForParamQuad(int sumOfOuterRates); │ │ │ │ │ -311 void initializeInventoryForParamQPoly(int sumOfOuterRates); │ │ │ │ │ -312 │ │ │ │ │ -313private: │ │ │ │ │ -314 // Private members: │ │ │ │ │ -315 _P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n _param; │ │ │ │ │ -316 │ │ │ │ │ -317 unsigned short _isValid : 1; │ │ │ │ │ -318 unsigned short _isUniform : 1; │ │ │ │ │ -319 unsigned short _triangulate : 1; │ │ │ │ │ -320 unsigned short _singleFace : 1; │ │ │ │ │ -321 unsigned short _segmentedFace : 1; │ │ │ │ │ -322 unsigned short _triangleFan : 1; │ │ │ │ │ -323 unsigned short _splitQuad : 1; │ │ │ │ │ -324 │ │ │ │ │ -325 short _facetSize; │ │ │ │ │ -326 int _facetStride; │ │ │ │ │ -327 int _coordStride; │ │ │ │ │ -328 │ │ │ │ │ -329 int _numGivenRates; │ │ │ │ │ -330 int _numBoundaryPoints; │ │ │ │ │ -331 int _numInteriorPoints; │ │ │ │ │ -332 int _numFacets; │ │ │ │ │ -333 │ │ │ │ │ -334 int _innerRates[2]; │ │ │ │ │ -335 int* _outerRates; │ │ │ │ │ -336 int _outerRatesLocal[4]; │ │ │ │ │ -337}; │ │ │ │ │ -338 │ │ │ │ │ -339// │ │ │ │ │ -340// Inline implementations: │ │ │ │ │ -341// │ │ │ │ │ -342inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ -_3_4_3_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_P_r_e_s_e_r_v_e_Q_u_a_d_s(bool on) { │ │ │ │ │ -344 _preserveQuads = on; │ │ │ │ │ -345 return *this; │ │ │ │ │ -346} │ │ │ │ │ -347inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ -_3_4_8_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_i_z_e(int numIndices) { │ │ │ │ │ -349 _facetSize4 = (numIndices == 4); │ │ │ │ │ -350 return *this; │ │ │ │ │ -351} │ │ │ │ │ -352inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ -_3_5_3_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_t_r_i_d_e(int stride) { │ │ │ │ │ -354 _facetStride = (short) stride; │ │ │ │ │ -355 return *this; │ │ │ │ │ -356} │ │ │ │ │ -357inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ -_3_5_8_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_C_o_o_r_d_S_t_r_i_d_e(int stride) { │ │ │ │ │ -359 _coordStride = (short) stride; │ │ │ │ │ -360 return *this; │ │ │ │ │ -361} │ │ │ │ │ -362 │ │ │ │ │ -363template │ │ │ │ │ -364inline int │ │ │ │ │ -_3_6_5_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_V_e_r_t_e_x_C_o_o_r_d(int vertex, REAL coord[]) const { │ │ │ │ │ -366 _param._G_e_t_V_e_r_t_e_x_C_o_o_r_d(vertex, coord); │ │ │ │ │ -367 return 1; │ │ │ │ │ -368} │ │ │ │ │ -369 │ │ │ │ │ -370template │ │ │ │ │ -371inline int │ │ │ │ │ -_3_7_2_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_C_o_o_r_d_s(REAL coordTuples[]) const { │ │ │ │ │ -373 int nCoords = _G_e_t_B_o_u_n_d_a_r_y_C_o_o_r_d_s(coordTuples); │ │ │ │ │ -374 nCoords += _G_e_t_I_n_t_e_r_i_o_r_C_o_o_r_d_s(coordTuples + nCoords * _coordStride); │ │ │ │ │ -375 return nCoords; │ │ │ │ │ -376} │ │ │ │ │ -377 │ │ │ │ │ -378} // end namespace Bfr │ │ │ │ │ -379 │ │ │ │ │ -380} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -381using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -382 │ │ │ │ │ -383} // end namespace OpenSubdiv │ │ │ │ │ -384 │ │ │ │ │ -385#endif /* OPENSUBDIV3_BFR_TESSELLATION */ │ │ │ │ │ +268 float _G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const; │ │ │ │ │ +269 │ │ │ │ │ +271 bool _H_a_s_E_d_g_e_S_h_a_r_p_n_e_s_s() const; │ │ │ │ │ +272 │ │ │ │ │ +274 float _G_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex) const; │ │ │ │ │ +275 │ │ │ │ │ +277 void _G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, │ │ │ │ │ +278 float * leadingEdgeSharp, float * trailingEdgeSharp) const; │ │ │ │ │ +280 │ │ │ │ │ +281protected: │ │ │ │ │ +283 friend class FaceVertex; │ │ │ │ │ +284 │ │ │ │ │ +285 _V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r() { } │ │ │ │ │ +286 _~_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r() { } │ │ │ │ │ +287 │ │ │ │ │ +288 typedef Vtr::internal::StackBuffer IntBuffer; │ │ │ │ │ +289 typedef Vtr::internal::StackBuffer FloatBuffer; │ │ │ │ │ +290 │ │ │ │ │ +291 void initFaceSizes(); │ │ │ │ │ +292 void initEdgeSharpness(); │ │ │ │ │ +294 │ │ │ │ │ +295protected: │ │ │ │ │ +297 // Member variables assigned through the above interface: │ │ │ │ │ +298 unsigned short _isValid : 1; │ │ │ │ │ +299 unsigned short _isInitialized : 1; │ │ │ │ │ +300 unsigned short _isFinalized : 1; │ │ │ │ │ +301 │ │ │ │ │ +302 unsigned short _isManifold : 1; │ │ │ │ │ +303 unsigned short _isBoundary : 1; │ │ │ │ │ +304 │ │ │ │ │ +305 unsigned short _hasFaceSizes : 1; │ │ │ │ │ +306 unsigned short _hasEdgeSharpness : 1; │ │ │ │ │ +307 │ │ │ │ │ +308 short _numFaces; │ │ │ │ │ +309 float _vertSharpness; │ │ │ │ │ +310 │ │ │ │ │ +311 FloatBuffer _faceEdgeSharpness; │ │ │ │ │ +312 IntBuffer _faceSizeOffsets; │ │ │ │ │ +314}; │ │ │ │ │ +315 │ │ │ │ │ +316// │ │ │ │ │ +317// Public inline methods for simple assignment: │ │ │ │ │ +318// │ │ │ │ │ +319inline bool │ │ │ │ │ +_3_2_0_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_V_a_l_i_d() const { │ │ │ │ │ +321 return _isValid; │ │ │ │ │ +322} │ │ │ │ │ +323 │ │ │ │ │ +324inline void │ │ │ │ │ +_3_2_5_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d(bool isManifold) { │ │ │ │ │ +326 _isManifold = isManifold; │ │ │ │ │ +327} │ │ │ │ │ +328inline bool │ │ │ │ │ +_3_2_9_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_M_a_n_i_f_o_l_d() const { │ │ │ │ │ +330 return _isManifold; │ │ │ │ │ +331} │ │ │ │ │ +332 │ │ │ │ │ +333inline void │ │ │ │ │ +_3_3_4_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_B_o_u_n_d_a_r_y(bool isBoundary) { │ │ │ │ │ +335 _isBoundary = isBoundary; │ │ │ │ │ +336} │ │ │ │ │ +337inline bool │ │ │ │ │ +_3_3_8_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_B_o_u_n_d_a_r_y() const { │ │ │ │ │ +339 return _isBoundary; │ │ │ │ │ +340} │ │ │ │ │ +341 │ │ │ │ │ +342// │ │ │ │ │ +343// Public inline methods involving sizes of incident faces: │ │ │ │ │ +344// │ │ │ │ │ +345inline bool │ │ │ │ │ +_3_4_6_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s() const { │ │ │ │ │ +347 return _hasFaceSizes; │ │ │ │ │ +348} │ │ │ │ │ +349inline void │ │ │ │ │ +_3_5_0_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s() { │ │ │ │ │ +351 _hasFaceSizes = false; │ │ │ │ │ +352} │ │ │ │ │ +353 │ │ │ │ │ +354inline void │ │ │ │ │ +_3_5_5_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int incFaceIndex, int faceSize) { │ │ │ │ │ +356 │ │ │ │ │ +357 if (!_hasFaceSizes) initFaceSizes(); │ │ │ │ │ +358 │ │ │ │ │ +359 _faceSizeOffsets[incFaceIndex] = faceSize; │ │ │ │ │ +360} │ │ │ │ │ +361inline int │ │ │ │ │ +_3_6_2_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int incFaceIndex) const { │ │ │ │ │ +363 │ │ │ │ │ +364 return _isFinalized ? │ │ │ │ │ +365 (_faceSizeOffsets[incFaceIndex+1] - _faceSizeOffsets[incFaceIndex]) : │ │ │ │ │ +366 _faceSizeOffsets[incFaceIndex]; │ │ │ │ │ +367} │ │ │ │ │ +368 │ │ │ │ │ +369// │ │ │ │ │ +370// Public inline methods involving vertex sharpness: │ │ │ │ │ +371// │ │ │ │ │ +372inline bool │ │ │ │ │ +_3_7_3_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const { │ │ │ │ │ +374 return _vertSharpness > 0.0f; │ │ │ │ │ +375} │ │ │ │ │ +376inline void │ │ │ │ │ +_3_7_7_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() { │ │ │ │ │ +378 _vertSharpness = 0.0f; │ │ │ │ │ +379} │ │ │ │ │ +380 │ │ │ │ │ +381inline void │ │ │ │ │ +_3_8_2_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float vertSharpness) { │ │ │ │ │ +383 _vertSharpness = vertSharpness; │ │ │ │ │ +384} │ │ │ │ │ +385inline float │ │ │ │ │ +_3_8_6_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const { │ │ │ │ │ +387 return _vertSharpness; │ │ │ │ │ +388} │ │ │ │ │ +389 │ │ │ │ │ +390// │ │ │ │ │ +391// Public inline methods involving vertex sharpness: │ │ │ │ │ +392// │ │ │ │ │ +393inline bool │ │ │ │ │ +_3_9_4_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_E_d_g_e_S_h_a_r_p_n_e_s_s() const { │ │ │ │ │ +395 return _hasEdgeSharpness; │ │ │ │ │ +396} │ │ │ │ │ +397inline void │ │ │ │ │ +_3_9_8_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_E_d_g_e_S_h_a_r_p_n_e_s_s() { │ │ │ │ │ +399 _hasEdgeSharpness = false; │ │ │ │ │ +400} │ │ │ │ │ +401 │ │ │ │ │ +402inline void │ │ │ │ │ +_4_0_3_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex, float sharpness) { │ │ │ │ │ +404 │ │ │ │ │ +405 if (!_hasEdgeSharpness) initEdgeSharpness(); │ │ │ │ │ +406 │ │ │ │ │ +407 // Assign the leading edge of the face after the edge (even index): │ │ │ │ │ +408 if (edgeIndex < _numFaces) { │ │ │ │ │ +409 _faceEdgeSharpness[2*edgeIndex] = sharpness; │ │ │ │ │ +410 } │ │ │ │ │ +411 │ │ │ │ │ +412 // Assign the trailing edge of the face before the edge (odd index): │ │ │ │ │ +413 if (edgeIndex > 0) { │ │ │ │ │ +414 _faceEdgeSharpness[2*edgeIndex-1] = sharpness; │ │ │ │ │ +415 } else if (!_I_s_B_o_u_n_d_a_r_y()) { │ │ │ │ │ +416 _faceEdgeSharpness[2*_numFaces-1] = sharpness; │ │ │ │ │ +417 } │ │ │ │ │ +418} │ │ │ │ │ +419inline float │ │ │ │ │ +_4_2_0_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex) const { │ │ │ │ │ +421 │ │ │ │ │ +422 // All edges are first of the pair (even index) except last of boundary │ │ │ │ │ +423 return _faceEdgeSharpness[2*edgeIndex - (edgeIndex == _numFaces)]; │ │ │ │ │ +424} │ │ │ │ │ +425 │ │ │ │ │ +426inline void │ │ │ │ │ +_4_2_7_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, │ │ │ │ │ +428 float leadingEdgeSharpness, float trailingEdgeSharpness) { │ │ │ │ │ +429 │ │ │ │ │ +430 if (!_hasEdgeSharpness) initEdgeSharpness(); │ │ │ │ │ +431 │ │ │ │ │ +432 _faceEdgeSharpness[2*faceIndex ] = leadingEdgeSharpness; │ │ │ │ │ +433 _faceEdgeSharpness[2*faceIndex+1] = trailingEdgeSharpness; │ │ │ │ │ +434} │ │ │ │ │ +435inline void │ │ │ │ │ +_4_3_6_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, │ │ │ │ │ +437 float * leadingEdgeSharpness, float * trailingEdgeSharpness) const { │ │ │ │ │ +438 │ │ │ │ │ +439 *leadingEdgeSharpness = _faceEdgeSharpness[2*faceIndex]; │ │ │ │ │ +440 *trailingEdgeSharpness = _faceEdgeSharpness[2*faceIndex+1]; │ │ │ │ │ +441} │ │ │ │ │ +442 │ │ │ │ │ +443} // end namespace Bfr │ │ │ │ │ +444 │ │ │ │ │ +445} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +446using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +447} // end namespace OpenSubdiv │ │ │ │ │ +448 │ │ │ │ │ +449#endif /* OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n │ │ │ │ │ -Simple class defining the 2D parameterization of a face. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_._h_:_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_:_:_G_e_t_F_a_c_e_S_i_z_e │ │ │ │ │ -int GetFaceSize() const │ │ │ │ │ -Returns the size (number of vertices) of the corresponding face. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_._h_:_1_0_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_:_:_G_e_t_V_e_r_t_e_x_C_o_o_r_d │ │ │ │ │ -void GetVertexCoord(int vertexIndex, REAL uvCoord[2]) const │ │ │ │ │ -Returns the (u,v) coordinate of a given vertex. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -Encapsulates a specific tessellation pattern of a Parameterization. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_S_i_z_e │ │ │ │ │ -int GetFaceSize() const │ │ │ │ │ -Return the size of the face. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_B_o_u_n_d_a_r_y_C_o_o_r_d_s │ │ │ │ │ -int GetNumBoundaryCoords() const │ │ │ │ │ -Return the number of boundary coordinates. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_1_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_~_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -~Tessellation() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s │ │ │ │ │ -void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], │ │ │ │ │ -int const interiorIndices[]) │ │ │ │ │ -Reassign all facet coordinate indices. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_C_o_o_r_d_S_t_r_i_d_e │ │ │ │ │ -int GetCoordStride() const │ │ │ │ │ -Return the number of elements between each coordinate. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_0_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_E_d_g_e_C_o_o_r_d_s │ │ │ │ │ -int GetNumEdgeCoords(int edge) const │ │ │ │ │ -Return the number of coordinates within a given edge (excluding those at its │ │ │ │ │ -end vertices) │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_1_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_I_n_t_e_r_i_o_r_C_o_o_r_d_s │ │ │ │ │ -int GetInteriorCoords(REAL coordTuples[]) const │ │ │ │ │ -Retrieve the coordinates for the boundary. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_t_S_t_r_i_d_e │ │ │ │ │ -int GetFacetStride() const │ │ │ │ │ -Return the number of elements between each facet. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_I_s_U_n_i_f_o_r_m │ │ │ │ │ -bool IsUniform() const │ │ │ │ │ -Return if the pattern is uniform. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_C_o_o_r_d_s │ │ │ │ │ -int GetNumCoords() const │ │ │ │ │ -Return the number of coordinates in the entire pattern. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_0_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_C_o_o_r_d_s │ │ │ │ │ -int GetCoords(REAL coordTuples[]) const │ │ │ │ │ -Retrieve the coordinates for the entire pattern. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_7_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s │ │ │ │ │ -void TransformFacetCoordIndices(int facetTuples[], int commonOffset) │ │ │ │ │ -Apply a common offset to all facet coordinate indices. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -Tessellation(Parameterization const &p, int numRates, int const rates[], │ │ │ │ │ -Options const &options=Options()) │ │ │ │ │ -General constructor providing multiple tessellation rates for a non-uniform │ │ │ │ │ -tessellation. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n │ │ │ │ │ -Parameterization GetParameterization() const │ │ │ │ │ -Return the Parameterization. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s │ │ │ │ │ -void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], │ │ │ │ │ -int interiorOffset) │ │ │ │ │ -Reassign indices of boundary coordinates while offseting those of interior │ │ │ │ │ -coordinates. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_t_S_i_z_e │ │ │ │ │ -int GetFacetSize() const │ │ │ │ │ -Return the number of indices assigned to each facet. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -Tessellation()=delete │ │ │ │ │ -Default construction is unavailable. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -Tessellation(Parameterization const &p, int uniformRate, Options const │ │ │ │ │ -&options=Options()) │ │ │ │ │ -Simple constructor providing a single uniform tessellation rate. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_t_s │ │ │ │ │ -int GetFacets(int facetTuples[]) const │ │ │ │ │ -Retrieve the facet indices for the entire pattern. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_F_a_c_e_t_s │ │ │ │ │ -int GetNumFacets() const │ │ │ │ │ -Return the number of facets in the entire pattern. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_I_n_t_e_r_i_o_r_C_o_o_r_d_s │ │ │ │ │ -int GetNumInteriorCoords() const │ │ │ │ │ -Return the number of interior coordinates. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_1_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_V_e_r_t_e_x_C_o_o_r_d │ │ │ │ │ -int GetVertexCoord(int vertex, REAL coordTuples[]) const │ │ │ │ │ -Retrieve the coordinate for a given vertex of the face. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_B_o_u_n_d_a_r_y_C_o_o_r_d_s │ │ │ │ │ -int GetBoundaryCoords(REAL coordTuples[]) const │ │ │ │ │ -Retrieve the coordinates for the boundary. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ -Tessellation(Tessellation const &)=delete │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_R_a_t_e_s │ │ │ │ │ -int GetRates(int rates[]) const │ │ │ │ │ -Retrieve the rates assigned. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_I_s_V_a_l_i_d │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +Simple class used by subclasses of SurfaceFactory to describe a vertex. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_1_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float GetVertexSharpness() const │ │ │ │ │ +Return the sharpness of the vertex. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_F_i_n_a_l_i_z_e │ │ │ │ │ +bool Finalize() │ │ │ │ │ +Terminate the sequence of specifications. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d │ │ │ │ │ +void SetManifold(bool isManifold) │ │ │ │ │ +Declare the vertex neighborhood as manifold (ordered) │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_2_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_n_i_t_i_a_l_i_z_e │ │ │ │ │ +bool Initialize(int numIncidentFaces) │ │ │ │ │ +Initialize specification with the number of incident faces. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_M_a_n_i_f_o_l_d │ │ │ │ │ +bool IsManifold() const │ │ │ │ │ +Return if vertex neighborhood is manifold. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_2_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +bool HasEdgeSharpness() const │ │ │ │ │ +Return if sharpness was assigned to the incident edges. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e │ │ │ │ │ +int GetIncidentFaceSize(int faceIndex) const │ │ │ │ │ +Return the size of an incident face. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float GetManifoldEdgeSharpness(int edgeIndex) const │ │ │ │ │ +Return the sharpness assigned to a manifold edge. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_2_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_: │ │ │ │ │ +_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +void SetIncidentFaceEdgeSharpness(int faceIndex, float leadingEdgeSharp, float │ │ │ │ │ +trailingEdgeSharp) │ │ │ │ │ +Assign sharpness to the edges of an incident face. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_2_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +bool HasVertexSharpness() const │ │ │ │ │ +Return if sharpness was assigned to the vertex. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s │ │ │ │ │ +void ClearIncidentFaceSizes() │ │ │ │ │ +Remove any assigned sizes of incident faces. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_5_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +void SetVertexSharpness(float sharpness) │ │ │ │ │ +Assign sharpness to the vertex. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +void ClearVertexSharpness() │ │ │ │ │ +Remove any sharpness assigned to the vertex. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +void ClearEdgeSharpness() │ │ │ │ │ +Remove any sharpness assigned to the incident edges. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_: │ │ │ │ │ +_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +void GetIncidentFaceEdgeSharpness(int faceIndex, float *leadingEdgeSharp, float │ │ │ │ │ +*trailingEdgeSharp) const │ │ │ │ │ +Return the sharpness assigned to edges of an incident face. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_3_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_B_o_u_n_d_a_r_y │ │ │ │ │ +bool IsBoundary() const │ │ │ │ │ +Return if vertex neighborhood is on a boundary. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_3_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_V_a_l_i_d │ │ │ │ │ bool IsValid() const │ │ │ │ │ -Return true if correctly initialized. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ │ -Tessellation & operator=(Tessellation const &)=delete │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_E_d_g_e_C_o_o_r_d_s │ │ │ │ │ -int GetEdgeCoords(int edge, REAL coordTuples[]) const │ │ │ │ │ -Retrieve the coordinates for a given edge of the face (excluding those at its │ │ │ │ │ -end vertices) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s │ │ │ │ │ -Options configure a Tessellation to specify the nature of both its results and │ │ │ │ │ -the structure of the c... │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ -Options() │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_G_e_t_C_o_o_r_d_S_t_r_i_d_e │ │ │ │ │ -int GetCoordStride() const │ │ │ │ │ -Return the stride between (u,v) pairs. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_9_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_i_z_e │ │ │ │ │ -Options & SetFacetSize(int numIndices) │ │ │ │ │ -Assign the number of indices per facet (must be 3 or 4, default is 3) │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_G_e_t_F_a_c_e_t_S_t_r_i_d_e │ │ │ │ │ -int GetFacetStride() const │ │ │ │ │ -Return the stride between facets. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_G_e_t_F_a_c_e_t_S_i_z_e │ │ │ │ │ -int GetFacetSize() const │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_C_o_o_r_d_S_t_r_i_d_e │ │ │ │ │ -Options & SetCoordStride(int stride) │ │ │ │ │ -Assign the stride between (u,v) pairs (default is 2) │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_t_r_i_d_e │ │ │ │ │ -Options & SetFacetStride(int stride) │ │ │ │ │ -Assign the stride between facets (default is facet size) │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_P_r_e_s_e_r_v_e_Q_u_a_d_s │ │ │ │ │ -bool PreserveQuads() const │ │ │ │ │ -Return if preservation of quads is set. │ │ │ │ │ -DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_7_4 │ │ │ │ │ +Return if instance is valid. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_2_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s │ │ │ │ │ +bool HasIncidentFaceSizes() const │ │ │ │ │ +Return if the sizes of incident faces are assigned. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_B_o_u_n_d_a_r_y │ │ │ │ │ +void SetBoundary(bool isOnBoundary) │ │ │ │ │ +Declare the vertex neighborhood as being on a boundary. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e │ │ │ │ │ +void SetIncidentFaceSize(int faceIndex, int faceSize) │ │ │ │ │ +Assign the size of an incident face. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +void SetManifoldEdgeSharpness(int edgeIndex, float edgeSharpness) │ │ │ │ │ +Assign sharpness to the edge of a manifold neighborhood. │ │ │ │ │ +DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_0_3 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _b_f_r │ │ │ │ │ - * _t_e_s_s_e_l_l_a_t_i_o_n_._h │ │ │ │ │ + * _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00677.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/bfr/vertexDescriptor.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/bfr/tessellation.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,26 +90,29 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
vertexDescriptor.h File Reference
│ │ │ │ +
tessellation.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../vtr/stackBuffer.h"
│ │ │ │ +#include "../bfr/parameterization.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  VertexDescriptor
 Simple class used by subclasses of SurfaceFactory to describe a vertex. More...
class  Tessellation
 Encapsulates a specific tessellation pattern of a Parameterization. More...
 
class  Tessellation::Options
 Options configure a Tessellation to specify the nature of both its results and the structure of the coordinate and facet index arrays that its methods will populate. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -118,13 +121,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,25 +1,30 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -vertexDescriptor.h File Reference │ │ │ │ │ +tessellation.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_v_t_r_/_s_t_a_c_k_B_u_f_f_e_r_._h" │ │ │ │ │ +#include "_._._/_b_f_r_/_p_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -  Simple class used by subclasses of _S_u_r_f_a_c_e_F_a_c_t_o_r_y to describe a vertex. │ │ │ │ │ +class   _T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +  Encapsulates a specific tessellation pattern of a _P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n. │ │ │ │ │ _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ +class   _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s │ │ │ │ │ + _O_p_t_i_o_n_s configure a _T_e_s_s_e_l_l_a_t_i_o_n to specify the nature of both its │ │ │ │ │ +  results and the structure of the coordinate and facet index arrays that │ │ │ │ │ + its methods will populate. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _b_f_r │ │ │ │ │ - * _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _t_e_s_s_e_l_l_a_t_i_o_n_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00677.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,4 @@ │ │ │ │ │ var a00677 = [ │ │ │ │ │ - ["VertexDescriptor", "a00969.html", "a00969"] │ │ │ │ │ + ["Tessellation", "a00961.html", "a00961"], │ │ │ │ │ + ["Options", "a00965.html", "a00965"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00677_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/bfr/vertexDescriptor.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/bfr/tessellation.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
vertexDescriptor.h
│ │ │ │ +
tessellation.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2021 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,425 +119,281 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H
│ │ │ │ -
26#define OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_BFR_TESSELLATION_H
│ │ │ │ +
26#define OPENSUBDIV3_BFR_TESSELLATION_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../vtr/stackBuffer.h"
│ │ │ │ +
30#include "../bfr/parameterization.h"
│ │ │ │
31
│ │ │ │
32namespace OpenSubdiv {
│ │ │ │
33namespace OPENSUBDIV_VERSION {
│ │ │ │
34
│ │ │ │
35namespace Bfr {
│ │ │ │
36
│ │ │ │ -
50//
│ │ │ │ -
51// WIP - need to migrate some of these comments into Doxygen
│ │ │ │ -
52// - others will be moved to the external documentation
│ │ │ │ -
53//
│ │ │ │ -
54// It is used by subclasses of SurfaceFactory to provide a complete
│ │ │ │ -
55// topological description for each vertex of a face, i.e. invoked via
│ │ │ │ -
56// the virtual method:
│ │ │ │ -
57//
│ │ │ │ -
58// int populateFaceVertexDescriptor(Index baseFace,
│ │ │ │ -
59// int cornerVertex,
│ │ │ │ -
60// VertexDescriptor & v) const;
│ │ │ │ -
61//
│ │ │ │ -
62// Assignment of the full topology can be involved in the presence of
│ │ │ │ -
63// irregular faces, non-manifold topology or creasing around a vertex, but
│ │ │ │ -
64// many cases will be simple. For example, to specify a regular boundary
│ │ │ │ -
65// vertex of a Catmark mesh without any optional sharpness:
│ │ │ │ -
66//
│ │ │ │ -
67// int numIncidentFaces = 2;
│ │ │ │ -
68// bool vertexOnBoundary = true;
│ │ │ │ -
69//
│ │ │ │ -
70// vd.Initialize(numIncidentFaces);
│ │ │ │ -
71// vd.SetManifold(true);
│ │ │ │ -
72// vd.SetBoundary(vertexOnBoundary);
│ │ │ │ -
73// vd.ClearIncidentFaceSizes();
│ │ │ │ -
74// vd.Finalize();
│ │ │ │ -
75//
│ │ │ │ -
76// For a more general example, to assign a vertex of some valence whose
│ │ │ │ -
77// incident faces are of different sizes (e.g. required when triangles
│ │ │ │ -
78// appear around a vertex in an otherwise quad-dominant Catmark mesh):
│ │ │ │ -
79//
│ │ │ │ -
80// int numIncidentFaces = meshVertex.GetNumIncidentFaces();
│ │ │ │ -
81// bool vertexOnBoundary = meshVertex.IsBoundar();
│ │ │ │ -
82//
│ │ │ │ -
83// vd.Initialize(numIncidentFaces);
│ │ │ │ -
84// vd.SetManifold(true);
│ │ │ │ -
85// vd.SetBoundary(vertexOnBoundary);
│ │ │ │ -
86//
│ │ │ │ -
87// for (int i = 0; i < numIncidentFaces; ++i) {
│ │ │ │ -
88// vd.SetIncidentFaceSize(i, meshVertex.GetIncidentFaceSize(i));
│ │ │ │ -
89// }
│ │ │ │ -
90// vd.Finalize();
│ │ │ │ -
91//
│ │ │ │ -
92// These examples specify the incident faces as forming a manifold ring
│ │ │ │ -
93// (or half-ring) around the vertex, i.e. they can be specified as a
│ │ │ │ -
94// continuous, connected sequence in counter-clockwise order (and also
│ │ │ │ -
95// without degeneracies). In the case of a boundary vertex, the first
│ │ │ │ -
96// face must be on the leading edge of the boundary while the last is on
│ │ │ │ -
97// the trailing edge. For an interior vertex, which face is specified
│ │ │ │ -
98// first does not matter (since the set is periodic).
│ │ │ │ -
99//
│ │ │ │ -
100// In both cases, the location of the base face in this sequence -- the
│ │ │ │ -
101// face whose corner vertex is being described here -- must be specified
│ │ │ │ -
102// in the return value to populateFaceVertexDescriptor() (e.g. when a
│ │ │ │ -
103// boundary vertex has 3 incident faces, a return value of 0, 1 or 2
│ │ │ │ -
104// will indicate which is the base face).
│ │ │ │ -
105//
│ │ │ │ -
106// The corresponding methods to specify mesh control vertex indices (or
│ │ │ │ -
107// face-varying indices) complete the specification of the neighborhood:
│ │ │ │ -
108//
│ │ │ │ -
109// int getFaceCornerVertexIndices(Index baseFace, int cornerVertex,
│ │ │ │ -
110// Index vertexIndices[]) const;
│ │ │ │ -
111//
│ │ │ │ -
112// int getFaceCornerFVarValueIndices(Index baseFace, int cornerVertex,
│ │ │ │ -
113// Index fvarValueIndices[],
│ │ │ │ -
114// int fvarChannel) const;
│ │ │ │ -
115//
│ │ │ │ -
116// and are invoked by the Factory when needed.
│ │ │ │ -
117//
│ │ │ │ -
118// For each incident face, the indices for all vertices of that face are
│ │ │ │ -
119// to be specified (not the one-ring or some other subset). These indices
│ │ │ │ -
120// must also be specified in an orientation relative to the vertex, i.e.
│ │ │ │ -
121// for a vertex A and an incident face with face-vertices that may be
│ │ │ │ -
122// stored internally as {D, C, A, B}, they must be specified with A first
│ │ │ │ -
123// as {A, B, C, D}. This may seem a bit cumbersome, but it has clear
│ │ │ │ -
124// advantages when dealing with face-varying indices and unordered faces.
│ │ │ │ -
125//
│ │ │ │ -
126// More compact ways of specifying vertex indices for ordered, manifold
│ │ │ │ -
127// cases may be worth exploring in future, but face-varying indices and
│ │ │ │ -
128// non-manifold (unordered) vertices will always require such a full set,
│ │ │ │ -
129// so both methods will need to co-exist.
│ │ │ │ -
130//
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
132public:
│ │ │ │ -
133 // The full declaration must be enclosed by calls to these methods:
│ │ │ │ -
134 //
│ │ │ │ -
135 // Note that vertex valences or face sizes in excess of those defined
│ │ │ │ -
136 // in Bfr::Limits (typically 16-bits) are not valid. When specifying
│ │ │ │ -
137 // values in excess of these limits, initialization will fail and/or
│ │ │ │ -
138 // the descriptor will be marked invalid and finalization will fail.
│ │ │ │ -
139 //
│ │ │ │ -
140
│ │ │ │ -
142
│ │ │ │ -
149
│ │ │ │ -
151 bool Initialize(int numIncidentFaces);
│ │ │ │ -
152
│ │ │ │ -
154 bool Finalize();
│ │ │ │ -
155
│ │ │ │ -
157 bool IsValid() const;
│ │ │ │ -
159
│ │ │ │ -
160 //
│ │ │ │ -
161 // WIP - need to migrate these comments into Doxygen
│ │ │ │ -
162 //
│ │ │ │ -
163 // Three groups of methods describe the topology around a vertex:
│ │ │ │ -
164 // - simple properties (vertex is a boundary, manifold, etc.)
│ │ │ │ -
165 // - sizes of incident faces (constant or size for each face)
│ │ │ │ -
166 // - sharpness of the vertex and its incident edges (optional)
│ │ │ │ -
167 //
│ │ │ │ -
168
│ │ │ │ -
169 // Manifold and boundary conditions:
│ │ │ │ -
170 //
│ │ │ │ -
171 // The manifold property is a strict condition but preferred for
│ │ │ │ -
172 // efficiency and is usually available from common connected mesh
│ │ │ │ -
173 // representations. When declaring the topology as "manifold",
│ │ │ │ -
174 // the Factory assumes the following:
│ │ │ │ -
175 //
│ │ │ │ -
176 // - all incident faces are "ordered" (counter-clockwise)
│ │ │ │ -
177 // - all incident faces are consistently oriented
│ │ │ │ -
178 // - all incident edges are non-degenerate
│ │ │ │ -
179 //
│ │ │ │ -
180 // If not certain that all of these conditions are met, it is best
│ │ │ │ -
181 // to not declare manifold -- leaving the Factory to make sense of
│ │ │ │ -
182 // the set of incident faces from the face-vertex indices that are
│ │ │ │ -
183 // provided elsewhere.
│ │ │ │ -
184 //
│ │ │ │ -
185
│ │ │ │ -
187
│ │ │ │ -
191
│ │ │ │ -
193 void SetManifold(bool isManifold);
│ │ │ │ -
194
│ │ │ │ -
196 void SetBoundary(bool isOnBoundary);
│ │ │ │ -
197
│ │ │ │ -
199 void SetIncidentFaceSize(int faceIndex, int faceSize);
│ │ │ │ -
200
│ │ │ │ - │ │ │ │ +
│ │ │ │ + │ │ │ │ +
52public:
│ │ │ │ +
│ │ │ │ +
65 class Options {
│ │ │ │ +
66 public:
│ │ │ │ +
│ │ │ │ +
67 Options() : _preserveQuads(false), _facetSize4(false),
│ │ │ │ +
68 _coordStride(0), _facetStride(0) { }
│ │ │ │ +
│ │ │ │ +
69
│ │ │ │ +
72 Options & PreserveQuads(bool on);
│ │ │ │ +
74 bool PreserveQuads() const { return _preserveQuads; }
│ │ │ │ +
75
│ │ │ │ +
78 Options & SetFacetSize(int numIndices);
│ │ │ │ +
79 // @brief Return the number of indices per facet
│ │ │ │ +
80 int GetFacetSize() const { return 3 + (int)_facetSize4; }
│ │ │ │ +
81
│ │ │ │ +
83 Options & SetFacetStride(int stride);
│ │ │ │ +
85 int GetFacetStride() const { return _facetStride; }
│ │ │ │ +
86
│ │ │ │ +
88 Options & SetCoordStride(int stride);
│ │ │ │ +
90 int GetCoordStride() const { return _coordStride; }
│ │ │ │ +
91
│ │ │ │ +
92 private:
│ │ │ │ +
93 unsigned int _preserveQuads : 1;
│ │ │ │ +
94 unsigned int _facetSize4 : 1;
│ │ │ │ +
95
│ │ │ │ +
96 short _coordStride;
│ │ │ │ +
97 short _facetStride;
│ │ │ │ +
98 };
│ │ │ │ +
│ │ │ │ +
99
│ │ │ │ +
100public:
│ │ │ │ +
102
│ │ │ │ +
111
│ │ │ │ +
118 Tessellation(Parameterization const & p, int uniformRate,
│ │ │ │ +
119 Options const & options = Options());
│ │ │ │ +
120
│ │ │ │ +
158 Tessellation(Parameterization const & p, int numRates, int const rates[],
│ │ │ │ +
159 Options const & options = Options());
│ │ │ │ +
160
│ │ │ │ +
162 bool IsValid() const { return _isValid; }
│ │ │ │ +
163
│ │ │ │ +
165 Tessellation() = delete;
│ │ │ │ +
166
│ │ │ │ +
167 Tessellation(Tessellation const &) = delete;
│ │ │ │ + │ │ │ │ + │ │ │ │ +
171
│ │ │ │ +
173
│ │ │ │ +
177
│ │ │ │ +
179 Parameterization GetParameterization() const { return _param; }
│ │ │ │ +
180
│ │ │ │ +
182 int GetFaceSize() const { return _param.GetFaceSize(); }
│ │ │ │ +
183
│ │ │ │ +
185 int GetRates(int rates[]) const;
│ │ │ │ +
186
│ │ │ │ +
188 bool IsUniform() const { return _isUniform; }
│ │ │ │ +
190
│ │ │ │ +
192
│ │ │ │
203
│ │ │ │ -
205 void SetVertexSharpness(float sharpness);
│ │ │ │ +
205 int GetNumCoords() const { return _numInteriorPoints + _numBoundaryPoints; }
│ │ │ │
206
│ │ │ │ - │ │ │ │ +
208 int GetCoordStride() const { return _coordStride; }
│ │ │ │
209
│ │ │ │ -
221 void SetManifoldEdgeSharpness(int edgeIndex, float edgeSharpness);
│ │ │ │ -
222
│ │ │ │ -
238 void SetIncidentFaceEdgeSharpness(int faceIndex, float leadingEdgeSharp,
│ │ │ │ -
239 float trailingEdgeSharp);
│ │ │ │ -
240
│ │ │ │ -
242 void ClearEdgeSharpness();
│ │ │ │ -
244
│ │ │ │ -
246
│ │ │ │ -
251
│ │ │ │ -
253 bool IsManifold() const;
│ │ │ │ -
254
│ │ │ │ -
256 bool IsBoundary() const;
│ │ │ │ -
257
│ │ │ │ -
259 bool HasIncidentFaceSizes() const;
│ │ │ │ -
260
│ │ │ │ -
262 int GetIncidentFaceSize(int faceIndex) const;
│ │ │ │ -
263
│ │ │ │ -
265 bool HasVertexSharpness() const;
│ │ │ │ +
211 int GetNumBoundaryCoords() const { return _numBoundaryPoints; }
│ │ │ │ +
212
│ │ │ │ +
214 int GetNumInteriorCoords() const { return _numInteriorPoints; }
│ │ │ │ +
215
│ │ │ │ +
218 int GetNumEdgeCoords(int edge) const { return _outerRates[edge] - 1; }
│ │ │ │ +
219
│ │ │ │ +
221 template <typename REAL>
│ │ │ │ +
222 int GetCoords(REAL coordTuples[]) const;
│ │ │ │ +
223
│ │ │ │ +
225 template <typename REAL>
│ │ │ │ +
226 int GetBoundaryCoords(REAL coordTuples[]) const;
│ │ │ │ +
227
│ │ │ │ +
229 template <typename REAL>
│ │ │ │ +
230 int GetInteriorCoords(REAL coordTuples[]) const;
│ │ │ │ +
231
│ │ │ │ +
233 template <typename REAL>
│ │ │ │ +
234 int GetVertexCoord(int vertex, REAL coordTuples[]) const;
│ │ │ │ +
235
│ │ │ │ +
238 template <typename REAL>
│ │ │ │ +
239 int GetEdgeCoords(int edge, REAL coordTuples[]) const;
│ │ │ │ +
241
│ │ │ │ +
243
│ │ │ │ +
253
│ │ │ │ +
255 int GetNumFacets() const { return _numFacets; }
│ │ │ │ +
256
│ │ │ │ +
258 int GetFacetSize() const { return _facetSize; }
│ │ │ │ +
259
│ │ │ │ +
261 int GetFacetStride() const { return _facetStride; }
│ │ │ │ +
262
│ │ │ │ +
264 int GetFacets(int facetTuples[]) const;
│ │ │ │
266
│ │ │ │ -
268 float GetVertexSharpness() const;
│ │ │ │ -
269
│ │ │ │ -
271 bool HasEdgeSharpness() const;
│ │ │ │ -
272
│ │ │ │ -
274 float GetManifoldEdgeSharpness(int edgeIndex) const;
│ │ │ │ -
275
│ │ │ │ -
277 void GetIncidentFaceEdgeSharpness(int faceIndex,
│ │ │ │ -
278 float * leadingEdgeSharp, float * trailingEdgeSharp) const;
│ │ │ │ -
280
│ │ │ │ -
281protected:
│ │ │ │ -
283 friend class FaceVertex;
│ │ │ │ -
284
│ │ │ │ -
285 VertexDescriptor() { }
│ │ │ │ - │ │ │ │ -
287
│ │ │ │ -
288 typedef Vtr::internal::StackBuffer<int,8,true> IntBuffer;
│ │ │ │ -
289 typedef Vtr::internal::StackBuffer<float,16,true> FloatBuffer;
│ │ │ │ -
290
│ │ │ │ -
291 void initFaceSizes();
│ │ │ │ -
292 void initEdgeSharpness();
│ │ │ │ -
294
│ │ │ │ -
295protected:
│ │ │ │ -
297 // Member variables assigned through the above interface:
│ │ │ │ -
298 unsigned short _isValid : 1;
│ │ │ │ -
299 unsigned short _isInitialized : 1;
│ │ │ │ -
300 unsigned short _isFinalized : 1;
│ │ │ │ -
301
│ │ │ │ -
302 unsigned short _isManifold : 1;
│ │ │ │ -
303 unsigned short _isBoundary : 1;
│ │ │ │ -
304
│ │ │ │ -
305 unsigned short _hasFaceSizes : 1;
│ │ │ │ -
306 unsigned short _hasEdgeSharpness : 1;
│ │ │ │ -
307
│ │ │ │ -
308 short _numFaces;
│ │ │ │ -
309 float _vertSharpness;
│ │ │ │ -
310
│ │ │ │ -
311 FloatBuffer _faceEdgeSharpness;
│ │ │ │ -
312 IntBuffer _faceSizeOffsets;
│ │ │ │ -
314};
│ │ │ │ -
│ │ │ │ -
315
│ │ │ │ -
316//
│ │ │ │ -
317// Public inline methods for simple assignment:
│ │ │ │ -
318//
│ │ │ │ -
319inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
321 return _isValid;
│ │ │ │ -
322}
│ │ │ │ -
│ │ │ │ -
323
│ │ │ │ -
324inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
326 _isManifold = isManifold;
│ │ │ │ -
327}
│ │ │ │ -
│ │ │ │ -
328inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
330 return _isManifold;
│ │ │ │ -
331}
│ │ │ │ -
│ │ │ │ -
332
│ │ │ │ -
333inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
335 _isBoundary = isBoundary;
│ │ │ │ -
336}
│ │ │ │ -
│ │ │ │ -
337inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
339 return _isBoundary;
│ │ │ │ -
340}
│ │ │ │ -
│ │ │ │ -
341
│ │ │ │ -
342//
│ │ │ │ -
343// Public inline methods involving sizes of incident faces:
│ │ │ │ -
344//
│ │ │ │ -
345inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
347 return _hasFaceSizes;
│ │ │ │ -
348}
│ │ │ │ -
│ │ │ │ -
349inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
351 _hasFaceSizes = false;
│ │ │ │ -
352}
│ │ │ │ -
│ │ │ │ -
353
│ │ │ │ -
354inline void
│ │ │ │ -
│ │ │ │ -
355VertexDescriptor::SetIncidentFaceSize(int incFaceIndex, int faceSize) {
│ │ │ │ -
356
│ │ │ │ -
357 if (!_hasFaceSizes) initFaceSizes();
│ │ │ │ -
358
│ │ │ │ -
359 _faceSizeOffsets[incFaceIndex] = faceSize;
│ │ │ │ -
360}
│ │ │ │ -
│ │ │ │ -
361inline int
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
363
│ │ │ │ -
364 return _isFinalized ?
│ │ │ │ -
365 (_faceSizeOffsets[incFaceIndex+1] - _faceSizeOffsets[incFaceIndex]) :
│ │ │ │ -
366 _faceSizeOffsets[incFaceIndex];
│ │ │ │ -
367}
│ │ │ │ -
│ │ │ │ -
368
│ │ │ │ -
369//
│ │ │ │ -
370// Public inline methods involving vertex sharpness:
│ │ │ │ -
371//
│ │ │ │ -
372inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
374 return _vertSharpness > 0.0f;
│ │ │ │ -
375}
│ │ │ │ -
│ │ │ │ -
376inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
378 _vertSharpness = 0.0f;
│ │ │ │ -
379}
│ │ │ │ -
│ │ │ │ -
380
│ │ │ │ -
381inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
383 _vertSharpness = vertSharpness;
│ │ │ │ -
384}
│ │ │ │ -
│ │ │ │ -
385inline float
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
387 return _vertSharpness;
│ │ │ │ -
388}
│ │ │ │ -
│ │ │ │ -
389
│ │ │ │ -
390//
│ │ │ │ -
391// Public inline methods involving vertex sharpness:
│ │ │ │ -
392//
│ │ │ │ -
393inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
395 return _hasEdgeSharpness;
│ │ │ │ -
396}
│ │ │ │ -
│ │ │ │ -
397inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
399 _hasEdgeSharpness = false;
│ │ │ │ -
400}
│ │ │ │ -
│ │ │ │ -
401
│ │ │ │ -
402inline void
│ │ │ │ -
│ │ │ │ -
403VertexDescriptor::SetManifoldEdgeSharpness(int edgeIndex, float sharpness) {
│ │ │ │ -
404
│ │ │ │ -
405 if (!_hasEdgeSharpness) initEdgeSharpness();
│ │ │ │ -
406
│ │ │ │ -
407 // Assign the leading edge of the face after the edge (even index):
│ │ │ │ -
408 if (edgeIndex < _numFaces) {
│ │ │ │ -
409 _faceEdgeSharpness[2*edgeIndex] = sharpness;
│ │ │ │ -
410 }
│ │ │ │ -
411
│ │ │ │ -
412 // Assign the trailing edge of the face before the edge (odd index):
│ │ │ │ -
413 if (edgeIndex > 0) {
│ │ │ │ -
414 _faceEdgeSharpness[2*edgeIndex-1] = sharpness;
│ │ │ │ -
415 } else if (!IsBoundary()) {
│ │ │ │ -
416 _faceEdgeSharpness[2*_numFaces-1] = sharpness;
│ │ │ │ -
417 }
│ │ │ │ -
418}
│ │ │ │ -
│ │ │ │ -
419inline float
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
421
│ │ │ │ -
422 // All edges are first of the pair (even index) except last of boundary
│ │ │ │ -
423 return _faceEdgeSharpness[2*edgeIndex - (edgeIndex == _numFaces)];
│ │ │ │ -
424}
│ │ │ │ -
│ │ │ │ -
425
│ │ │ │ -
426inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
428 float leadingEdgeSharpness, float trailingEdgeSharpness) {
│ │ │ │ -
429
│ │ │ │ -
430 if (!_hasEdgeSharpness) initEdgeSharpness();
│ │ │ │ -
431
│ │ │ │ -
432 _faceEdgeSharpness[2*faceIndex ] = leadingEdgeSharpness;
│ │ │ │ -
433 _faceEdgeSharpness[2*faceIndex+1] = trailingEdgeSharpness;
│ │ │ │ -
434}
│ │ │ │ -
│ │ │ │ -
435inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
437 float * leadingEdgeSharpness, float * trailingEdgeSharpness) const {
│ │ │ │ -
438
│ │ │ │ -
439 *leadingEdgeSharpness = _faceEdgeSharpness[2*faceIndex];
│ │ │ │ -
440 *trailingEdgeSharpness = _faceEdgeSharpness[2*faceIndex+1];
│ │ │ │ -
441}
│ │ │ │ -
│ │ │ │ -
442
│ │ │ │ -
443} // end namespace Bfr
│ │ │ │ -
444
│ │ │ │ -
445} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
446using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
447} // end namespace OpenSubdiv
│ │ │ │ -
448
│ │ │ │ -
449#endif /* OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H */
│ │ │ │ +
268
│ │ │ │ +
283
│ │ │ │ +
285 void TransformFacetCoordIndices(int facetTuples[], int commonOffset);
│ │ │ │ +
286
│ │ │ │ +
289 void TransformFacetCoordIndices(int facetTuples[],
│ │ │ │ +
290 int const boundaryIndices[],
│ │ │ │ +
291 int interiorOffset);
│ │ │ │ +
292
│ │ │ │ +
294 void TransformFacetCoordIndices(int facetTuples[],
│ │ │ │ +
295 int const boundaryIndices[],
│ │ │ │ +
296 int const interiorIndices[]);
│ │ │ │ +
298
│ │ │ │ +
299private:
│ │ │ │ +
300 // Private initialization methods:
│ │ │ │ +
301 bool validateArguments(Parameterization const & p,
│ │ │ │ +
302 int nRates, int const rates[], Options const & options);
│ │ │ │ +
303
│ │ │ │ +
304 void initialize(Parameterization const & p,
│ │ │ │ +
305 int nRates, int const rates[], Options const & options);
│ │ │ │ +
306
│ │ │ │ +
307 void initializeDefaults();
│ │ │ │ +
308 int initializeRates(int nRates, int const rates[]);
│ │ │ │ +
309 void initializeInventoryForParamTri(int sumOfOuterRates);
│ │ │ │ +
310 void initializeInventoryForParamQuad(int sumOfOuterRates);
│ │ │ │ +
311 void initializeInventoryForParamQPoly(int sumOfOuterRates);
│ │ │ │ +
312
│ │ │ │ +
313private:
│ │ │ │ +
314 // Private members:
│ │ │ │ +
315 Parameterization _param;
│ │ │ │ +
316
│ │ │ │ +
317 unsigned short _isValid : 1;
│ │ │ │ +
318 unsigned short _isUniform : 1;
│ │ │ │ +
319 unsigned short _triangulate : 1;
│ │ │ │ +
320 unsigned short _singleFace : 1;
│ │ │ │ +
321 unsigned short _segmentedFace : 1;
│ │ │ │ +
322 unsigned short _triangleFan : 1;
│ │ │ │ +
323 unsigned short _splitQuad : 1;
│ │ │ │ +
324
│ │ │ │ +
325 short _facetSize;
│ │ │ │ +
326 int _facetStride;
│ │ │ │ +
327 int _coordStride;
│ │ │ │ +
328
│ │ │ │ +
329 int _numGivenRates;
│ │ │ │ +
330 int _numBoundaryPoints;
│ │ │ │ +
331 int _numInteriorPoints;
│ │ │ │ +
332 int _numFacets;
│ │ │ │ +
333
│ │ │ │ +
334 int _innerRates[2];
│ │ │ │ +
335 int* _outerRates;
│ │ │ │ +
336 int _outerRatesLocal[4];
│ │ │ │ +
337};
│ │ │ │ +
│ │ │ │ +
338
│ │ │ │ +
339//
│ │ │ │ +
340// Inline implementations:
│ │ │ │ +
341//
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
344 _preserveQuads = on;
│ │ │ │ +
345 return *this;
│ │ │ │ +
346}
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
349 _facetSize4 = (numIndices == 4);
│ │ │ │ +
350 return *this;
│ │ │ │ +
351}
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
354 _facetStride = (short) stride;
│ │ │ │ +
355 return *this;
│ │ │ │ +
356}
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
359 _coordStride = (short) stride;
│ │ │ │ +
360 return *this;
│ │ │ │ +
361}
│ │ │ │ +
│ │ │ │ +
362
│ │ │ │ +
363template <typename REAL>
│ │ │ │ +
364inline int
│ │ │ │ +
│ │ │ │ +
365Tessellation::GetVertexCoord(int vertex, REAL coord[]) const {
│ │ │ │ +
366 _param.GetVertexCoord(vertex, coord);
│ │ │ │ +
367 return 1;
│ │ │ │ +
368}
│ │ │ │ +
│ │ │ │ +
369
│ │ │ │ +
370template <typename REAL>
│ │ │ │ +
371inline int
│ │ │ │ +
│ │ │ │ +
372Tessellation::GetCoords(REAL coordTuples[]) const {
│ │ │ │ +
373 int nCoords = GetBoundaryCoords(coordTuples);
│ │ │ │ +
374 nCoords += GetInteriorCoords(coordTuples + nCoords * _coordStride);
│ │ │ │ +
375 return nCoords;
│ │ │ │ +
376}
│ │ │ │ +
│ │ │ │ +
377
│ │ │ │ +
378} // end namespace Bfr
│ │ │ │ +
379
│ │ │ │ +
380} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
381using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
382
│ │ │ │ +
383} // end namespace OpenSubdiv
│ │ │ │ +
384
│ │ │ │ +
385#endif /* OPENSUBDIV3_BFR_TESSELLATION */
│ │ │ │ │ │ │ │ -
Simple class used by subclasses of SurfaceFactory to describe a vertex.
│ │ │ │ -
float GetVertexSharpness() const
Return the sharpness of the vertex.
│ │ │ │ -
bool Finalize()
Terminate the sequence of specifications.
│ │ │ │ -
void SetManifold(bool isManifold)
Declare the vertex neighborhood as manifold (ordered)
│ │ │ │ -
bool Initialize(int numIncidentFaces)
Initialize specification with the number of incident faces.
│ │ │ │ -
bool IsManifold() const
Return if vertex neighborhood is manifold.
│ │ │ │ -
bool HasEdgeSharpness() const
Return if sharpness was assigned to the incident edges.
│ │ │ │ -
int GetIncidentFaceSize(int faceIndex) const
Return the size of an incident face.
│ │ │ │ -
float GetManifoldEdgeSharpness(int edgeIndex) const
Return the sharpness assigned to a manifold edge.
│ │ │ │ -
void SetIncidentFaceEdgeSharpness(int faceIndex, float leadingEdgeSharp, float trailingEdgeSharp)
Assign sharpness to the edges of an incident face.
│ │ │ │ -
bool HasVertexSharpness() const
Return if sharpness was assigned to the vertex.
│ │ │ │ -
void ClearIncidentFaceSizes()
Remove any assigned sizes of incident faces.
│ │ │ │ -
void SetVertexSharpness(float sharpness)
Assign sharpness to the vertex.
│ │ │ │ -
void ClearVertexSharpness()
Remove any sharpness assigned to the vertex.
│ │ │ │ -
void ClearEdgeSharpness()
Remove any sharpness assigned to the incident edges.
│ │ │ │ -
void GetIncidentFaceEdgeSharpness(int faceIndex, float *leadingEdgeSharp, float *trailingEdgeSharp) const
Return the sharpness assigned to edges of an incident face.
│ │ │ │ -
bool IsBoundary() const
Return if vertex neighborhood is on a boundary.
│ │ │ │ -
bool IsValid() const
Return if instance is valid.
│ │ │ │ -
bool HasIncidentFaceSizes() const
Return if the sizes of incident faces are assigned.
│ │ │ │ -
void SetBoundary(bool isOnBoundary)
Declare the vertex neighborhood as being on a boundary.
│ │ │ │ -
void SetIncidentFaceSize(int faceIndex, int faceSize)
Assign the size of an incident face.
│ │ │ │ -
void SetManifoldEdgeSharpness(int edgeIndex, float edgeSharpness)
Assign sharpness to the edge of a manifold neighborhood.
│ │ │ │ +
Simple class defining the 2D parameterization of a face.
│ │ │ │ +
int GetFaceSize() const
Returns the size (number of vertices) of the corresponding face.
│ │ │ │ +
void GetVertexCoord(int vertexIndex, REAL uvCoord[2]) const
Returns the (u,v) coordinate of a given vertex.
│ │ │ │ +
Encapsulates a specific tessellation pattern of a Parameterization.
│ │ │ │ +
int GetFaceSize() const
Return the size of the face.
│ │ │ │ +
int GetNumBoundaryCoords() const
Return the number of boundary coordinates.
│ │ │ │ + │ │ │ │ +
void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], int const interiorIndices[])
Reassign all facet coordinate indices.
│ │ │ │ +
int GetCoordStride() const
Return the number of elements between each coordinate.
│ │ │ │ +
int GetNumEdgeCoords(int edge) const
Return the number of coordinates within a given edge (excluding those at its end vertices)
│ │ │ │ +
int GetInteriorCoords(REAL coordTuples[]) const
Retrieve the coordinates for the boundary.
│ │ │ │ +
int GetFacetStride() const
Return the number of elements between each facet.
│ │ │ │ +
bool IsUniform() const
Return if the pattern is uniform.
│ │ │ │ +
int GetNumCoords() const
Return the number of coordinates in the entire pattern.
│ │ │ │ +
int GetCoords(REAL coordTuples[]) const
Retrieve the coordinates for the entire pattern.
│ │ │ │ +
void TransformFacetCoordIndices(int facetTuples[], int commonOffset)
Apply a common offset to all facet coordinate indices.
│ │ │ │ +
Tessellation(Parameterization const &p, int numRates, int const rates[], Options const &options=Options())
General constructor providing multiple tessellation rates for a non-uniform tessellation.
│ │ │ │ +
Parameterization GetParameterization() const
Return the Parameterization.
│ │ │ │ +
void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], int interiorOffset)
Reassign indices of boundary coordinates while offseting those of interior coordinates.
│ │ │ │ +
int GetFacetSize() const
Return the number of indices assigned to each facet.
│ │ │ │ +
Tessellation()=delete
Default construction is unavailable.
│ │ │ │ +
Tessellation(Parameterization const &p, int uniformRate, Options const &options=Options())
Simple constructor providing a single uniform tessellation rate.
│ │ │ │ +
int GetFacets(int facetTuples[]) const
Retrieve the facet indices for the entire pattern.
│ │ │ │ +
int GetNumFacets() const
Return the number of facets in the entire pattern.
│ │ │ │ +
int GetNumInteriorCoords() const
Return the number of interior coordinates.
│ │ │ │ +
int GetVertexCoord(int vertex, REAL coordTuples[]) const
Retrieve the coordinate for a given vertex of the face.
│ │ │ │ +
int GetBoundaryCoords(REAL coordTuples[]) const
Retrieve the coordinates for the boundary.
│ │ │ │ + │ │ │ │ +
int GetRates(int rates[]) const
Retrieve the rates assigned.
│ │ │ │ +
bool IsValid() const
Return true if correctly initialized.
│ │ │ │ +
Tessellation & operator=(Tessellation const &)=delete
│ │ │ │ +
int GetEdgeCoords(int edge, REAL coordTuples[]) const
Retrieve the coordinates for a given edge of the face (excluding those at its end vertices)
│ │ │ │ +
Options configure a Tessellation to specify the nature of both its results and the structure of the c...
│ │ │ │ + │ │ │ │ +
int GetCoordStride() const
Return the stride between (u,v) pairs.
│ │ │ │ +
Options & SetFacetSize(int numIndices)
Assign the number of indices per facet (must be 3 or 4, default is 3)
│ │ │ │ +
int GetFacetStride() const
Return the stride between facets.
│ │ │ │ + │ │ │ │ +
Options & SetCoordStride(int stride)
Assign the stride between (u,v) pairs (default is 2)
│ │ │ │ +
Options & SetFacetStride(int stride)
Assign the stride between facets (default is facet size)
│ │ │ │ +
bool PreserveQuads() const
Return if preservation of quads is set.
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -vertexDescriptor.h │ │ │ │ │ +tessellation.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2021 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,446 +24,367 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H │ │ │ │ │ -26#define OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_BFR_TESSELLATION_H │ │ │ │ │ +26#define OPENSUBDIV3_BFR_TESSELLATION_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../vtr/stackBuffer.h" │ │ │ │ │ +30#include "../bfr/parameterization.h" │ │ │ │ │ 31 │ │ │ │ │ 32namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ 33namespace OPENSUBDIV_VERSION { │ │ │ │ │ 34 │ │ │ │ │ 35namespace Bfr { │ │ │ │ │ 36 │ │ │ │ │ -50// │ │ │ │ │ -51// WIP - need to migrate some of these comments into Doxygen │ │ │ │ │ -52// - others will be moved to the external documentation │ │ │ │ │ -53// │ │ │ │ │ -54// It is used by subclasses of SurfaceFactory to provide a complete │ │ │ │ │ -55// topological description for each vertex of a face, i.e. invoked via │ │ │ │ │ -56// the virtual method: │ │ │ │ │ -57// │ │ │ │ │ -58// int populateFaceVertexDescriptor(Index baseFace, │ │ │ │ │ -59// int cornerVertex, │ │ │ │ │ -60// VertexDescriptor & v) const; │ │ │ │ │ -61// │ │ │ │ │ -62// Assignment of the full topology can be involved in the presence of │ │ │ │ │ -63// irregular faces, non-manifold topology or creasing around a vertex, but │ │ │ │ │ -64// many cases will be simple. For example, to specify a regular boundary │ │ │ │ │ -65// vertex of a Catmark mesh without any optional sharpness: │ │ │ │ │ -66// │ │ │ │ │ -67// int numIncidentFaces = 2; │ │ │ │ │ -68// bool vertexOnBoundary = true; │ │ │ │ │ -69// │ │ │ │ │ -70// vd.Initialize(numIncidentFaces); │ │ │ │ │ -71// vd.SetManifold(true); │ │ │ │ │ -72// vd.SetBoundary(vertexOnBoundary); │ │ │ │ │ -73// vd.ClearIncidentFaceSizes(); │ │ │ │ │ -74// vd.Finalize(); │ │ │ │ │ -75// │ │ │ │ │ -76// For a more general example, to assign a vertex of some valence whose │ │ │ │ │ -77// incident faces are of different sizes (e.g. required when triangles │ │ │ │ │ -78// appear around a vertex in an otherwise quad-dominant Catmark mesh): │ │ │ │ │ -79// │ │ │ │ │ -80// int numIncidentFaces = meshVertex.GetNumIncidentFaces(); │ │ │ │ │ -81// bool vertexOnBoundary = meshVertex.IsBoundar(); │ │ │ │ │ -82// │ │ │ │ │ -83// vd.Initialize(numIncidentFaces); │ │ │ │ │ -84// vd.SetManifold(true); │ │ │ │ │ -85// vd.SetBoundary(vertexOnBoundary); │ │ │ │ │ -86// │ │ │ │ │ -87// for (int i = 0; i < numIncidentFaces; ++i) { │ │ │ │ │ -88// vd.SetIncidentFaceSize(i, meshVertex.GetIncidentFaceSize(i)); │ │ │ │ │ -89// } │ │ │ │ │ -90// vd.Finalize(); │ │ │ │ │ -91// │ │ │ │ │ -92// These examples specify the incident faces as forming a manifold ring │ │ │ │ │ -93// (or half-ring) around the vertex, i.e. they can be specified as a │ │ │ │ │ -94// continuous, connected sequence in counter-clockwise order (and also │ │ │ │ │ -95// without degeneracies). In the case of a boundary vertex, the first │ │ │ │ │ -96// face must be on the leading edge of the boundary while the last is on │ │ │ │ │ -97// the trailing edge. For an interior vertex, which face is specified │ │ │ │ │ -98// first does not matter (since the set is periodic). │ │ │ │ │ -99// │ │ │ │ │ -100// In both cases, the location of the base face in this sequence -- the │ │ │ │ │ -101// face whose corner vertex is being described here -- must be specified │ │ │ │ │ -102// in the return value to populateFaceVertexDescriptor() (e.g. when a │ │ │ │ │ -103// boundary vertex has 3 incident faces, a return value of 0, 1 or 2 │ │ │ │ │ -104// will indicate which is the base face). │ │ │ │ │ -105// │ │ │ │ │ -106// The corresponding methods to specify mesh control vertex indices (or │ │ │ │ │ -107// face-varying indices) complete the specification of the neighborhood: │ │ │ │ │ -108// │ │ │ │ │ -109// int getFaceCornerVertexIndices(Index baseFace, int cornerVertex, │ │ │ │ │ -110// Index vertexIndices[]) const; │ │ │ │ │ -111// │ │ │ │ │ -112// int getFaceCornerFVarValueIndices(Index baseFace, int cornerVertex, │ │ │ │ │ -113// Index fvarValueIndices[], │ │ │ │ │ -114// int fvarChannel) const; │ │ │ │ │ -115// │ │ │ │ │ -116// and are invoked by the Factory when needed. │ │ │ │ │ -117// │ │ │ │ │ -118// For each incident face, the indices for all vertices of that face are │ │ │ │ │ -119// to be specified (not the one-ring or some other subset). These indices │ │ │ │ │ -120// must also be specified in an orientation relative to the vertex, i.e. │ │ │ │ │ -121// for a vertex A and an incident face with face-vertices that may be │ │ │ │ │ -122// stored internally as {D, C, A, B}, they must be specified with A first │ │ │ │ │ -123// as {A, B, C, D}. This may seem a bit cumbersome, but it has clear │ │ │ │ │ -124// advantages when dealing with face-varying indices and unordered faces. │ │ │ │ │ -125// │ │ │ │ │ -126// More compact ways of specifying vertex indices for ordered, manifold │ │ │ │ │ -127// cases may be worth exploring in future, but face-varying indices and │ │ │ │ │ -128// non-manifold (unordered) vertices will always require such a full set, │ │ │ │ │ -129// so both methods will need to co-exist. │ │ │ │ │ -130// │ │ │ │ │ -_1_3_1class _V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ -132public: │ │ │ │ │ -133 // The full declaration must be enclosed by calls to these methods: │ │ │ │ │ -134 // │ │ │ │ │ -135 // Note that vertex valences or face sizes in excess of those defined │ │ │ │ │ -136 // in Bfr::Limits (typically 16-bits) are not valid. When specifying │ │ │ │ │ -137 // values in excess of these limits, initialization will fail and/or │ │ │ │ │ -138 // the descriptor will be marked invalid and finalization will fail. │ │ │ │ │ -139 // │ │ │ │ │ -140 │ │ │ │ │ -142 │ │ │ │ │ -149 │ │ │ │ │ -_1_5_1 bool _I_n_i_t_i_a_l_i_z_e(int numIncidentFaces); │ │ │ │ │ -152 │ │ │ │ │ -_1_5_4 bool _F_i_n_a_l_i_z_e(); │ │ │ │ │ -155 │ │ │ │ │ -157 bool _I_s_V_a_l_i_d() const; │ │ │ │ │ -159 │ │ │ │ │ -160 // │ │ │ │ │ -161 // WIP - need to migrate these comments into Doxygen │ │ │ │ │ -162 // │ │ │ │ │ -163 // Three groups of methods describe the topology around a vertex: │ │ │ │ │ -164 // - simple properties (vertex is a boundary, manifold, etc.) │ │ │ │ │ -165 // - sizes of incident faces (constant or size for each face) │ │ │ │ │ -166 // - sharpness of the vertex and its incident edges (optional) │ │ │ │ │ -167 // │ │ │ │ │ -168 │ │ │ │ │ -169 // Manifold and boundary conditions: │ │ │ │ │ -170 // │ │ │ │ │ -171 // The manifold property is a strict condition but preferred for │ │ │ │ │ -172 // efficiency and is usually available from common connected mesh │ │ │ │ │ -173 // representations. When declaring the topology as "manifold", │ │ │ │ │ -174 // the Factory assumes the following: │ │ │ │ │ -175 // │ │ │ │ │ -176 // - all incident faces are "ordered" (counter-clockwise) │ │ │ │ │ -177 // - all incident faces are consistently oriented │ │ │ │ │ -178 // - all incident edges are non-degenerate │ │ │ │ │ -179 // │ │ │ │ │ -180 // If not certain that all of these conditions are met, it is best │ │ │ │ │ -181 // to not declare manifold -- leaving the Factory to make sense of │ │ │ │ │ -182 // the set of incident faces from the face-vertex indices that are │ │ │ │ │ -183 // provided elsewhere. │ │ │ │ │ -184 // │ │ │ │ │ -185 │ │ │ │ │ -187 │ │ │ │ │ -191 │ │ │ │ │ -193 void _S_e_t_M_a_n_i_f_o_l_d(bool isManifold); │ │ │ │ │ -194 │ │ │ │ │ -196 void _S_e_t_B_o_u_n_d_a_r_y(bool isOnBoundary); │ │ │ │ │ -197 │ │ │ │ │ -199 void _S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int faceIndex, int faceSize); │ │ │ │ │ -200 │ │ │ │ │ -202 void _C_l_e_a_r_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s(); │ │ │ │ │ +_5_1class _T_e_s_s_e_l_l_a_t_i_o_n { │ │ │ │ │ +52public: │ │ │ │ │ +_6_5 class _O_p_t_i_o_n_s { │ │ │ │ │ +66 public: │ │ │ │ │ +_6_7 _O_p_t_i_o_n_s() : _preserveQuads(false), _facetSize4(false), │ │ │ │ │ +68 _coordStride(0), _facetStride(0) { } │ │ │ │ │ +69 │ │ │ │ │ +72 _O_p_t_i_o_n_s & _P_r_e_s_e_r_v_e_Q_u_a_d_s(bool on); │ │ │ │ │ +_7_4 bool _P_r_e_s_e_r_v_e_Q_u_a_d_s() const { return _preserveQuads; } │ │ │ │ │ +75 │ │ │ │ │ +78 _O_p_t_i_o_n_s & _S_e_t_F_a_c_e_t_S_i_z_e(int numIndices); │ │ │ │ │ +79 // @brief Return the number of indices per facet │ │ │ │ │ +_8_0 int _G_e_t_F_a_c_e_t_S_i_z_e() const { return 3 + (int)_facetSize4; } │ │ │ │ │ +81 │ │ │ │ │ +83 _O_p_t_i_o_n_s & _S_e_t_F_a_c_e_t_S_t_r_i_d_e(int stride); │ │ │ │ │ +_8_5 int _G_e_t_F_a_c_e_t_S_t_r_i_d_e() const { return _facetStride; } │ │ │ │ │ +86 │ │ │ │ │ +88 _O_p_t_i_o_n_s & _S_e_t_C_o_o_r_d_S_t_r_i_d_e(int stride); │ │ │ │ │ +_9_0 int _G_e_t_C_o_o_r_d_S_t_r_i_d_e() const { return _coordStride; } │ │ │ │ │ +91 │ │ │ │ │ +92 private: │ │ │ │ │ +93 unsigned int _preserveQuads : 1; │ │ │ │ │ +94 unsigned int _facetSize4 : 1; │ │ │ │ │ +95 │ │ │ │ │ +96 short _coordStride; │ │ │ │ │ +97 short _facetStride; │ │ │ │ │ +98 }; │ │ │ │ │ +99 │ │ │ │ │ +100public: │ │ │ │ │ +102 │ │ │ │ │ +111 │ │ │ │ │ +_1_1_8 _T_e_s_s_e_l_l_a_t_i_o_n(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, int uniformRate, │ │ │ │ │ +119 _O_p_t_i_o_n_s const & options = _O_p_t_i_o_n_s()); │ │ │ │ │ +120 │ │ │ │ │ +_1_5_8 _T_e_s_s_e_l_l_a_t_i_o_n(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, int numRates, int const rates[], │ │ │ │ │ +159 _O_p_t_i_o_n_s const & options = _O_p_t_i_o_n_s()); │ │ │ │ │ +160 │ │ │ │ │ +_1_6_2 bool _I_s_V_a_l_i_d() const { return _isValid; } │ │ │ │ │ +163 │ │ │ │ │ +_1_6_5 _T_e_s_s_e_l_l_a_t_i_o_n() = delete; │ │ │ │ │ +166 │ │ │ │ │ +_1_6_7 _T_e_s_s_e_l_l_a_t_i_o_n(_T_e_s_s_e_l_l_a_t_i_o_n const &) = delete; │ │ │ │ │ +_1_6_8 _T_e_s_s_e_l_l_a_t_i_o_n & _o_p_e_r_a_t_o_r_=(_T_e_s_s_e_l_l_a_t_i_o_n const &) = delete; │ │ │ │ │ +_1_6_9 _~_T_e_s_s_e_l_l_a_t_i_o_n(); │ │ │ │ │ +171 │ │ │ │ │ +173 │ │ │ │ │ +177 │ │ │ │ │ +_1_7_9 _P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n _G_e_t_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n() const { return _param; } │ │ │ │ │ +180 │ │ │ │ │ +_1_8_2 int _G_e_t_F_a_c_e_S_i_z_e() const { return _param._G_e_t_F_a_c_e_S_i_z_e(); } │ │ │ │ │ +183 │ │ │ │ │ +_1_8_5 int _G_e_t_R_a_t_e_s(int rates[]) const; │ │ │ │ │ +186 │ │ │ │ │ +_1_8_8 bool _I_s_U_n_i_f_o_r_m() const { return _isUniform; } │ │ │ │ │ +190 │ │ │ │ │ +192 │ │ │ │ │ 203 │ │ │ │ │ -205 void _S_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float sharpness); │ │ │ │ │ +_2_0_5 int _G_e_t_N_u_m_C_o_o_r_d_s() const { return _numInteriorPoints + _numBoundaryPoints; │ │ │ │ │ +} │ │ │ │ │ 206 │ │ │ │ │ -208 void _C_l_e_a_r_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(); │ │ │ │ │ +_2_0_8 int _G_e_t_C_o_o_r_d_S_t_r_i_d_e() const { return _coordStride; } │ │ │ │ │ 209 │ │ │ │ │ -221 void _S_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex, float edgeSharpness); │ │ │ │ │ -222 │ │ │ │ │ -238 void _S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, float leadingEdgeSharp, │ │ │ │ │ -239 float trailingEdgeSharp); │ │ │ │ │ -240 │ │ │ │ │ -242 void _C_l_e_a_r_E_d_g_e_S_h_a_r_p_n_e_s_s(); │ │ │ │ │ -244 │ │ │ │ │ -246 │ │ │ │ │ -251 │ │ │ │ │ -253 bool _I_s_M_a_n_i_f_o_l_d() const; │ │ │ │ │ -254 │ │ │ │ │ -256 bool _I_s_B_o_u_n_d_a_r_y() const; │ │ │ │ │ -257 │ │ │ │ │ -259 bool _H_a_s_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s() const; │ │ │ │ │ -260 │ │ │ │ │ -262 int _G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int faceIndex) const; │ │ │ │ │ -263 │ │ │ │ │ -265 bool _H_a_s_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const; │ │ │ │ │ +_2_1_1 int _G_e_t_N_u_m_B_o_u_n_d_a_r_y_C_o_o_r_d_s() const { return _numBoundaryPoints; } │ │ │ │ │ +212 │ │ │ │ │ +_2_1_4 int _G_e_t_N_u_m_I_n_t_e_r_i_o_r_C_o_o_r_d_s() const { return _numInteriorPoints; } │ │ │ │ │ +215 │ │ │ │ │ +_2_1_8 int _G_e_t_N_u_m_E_d_g_e_C_o_o_r_d_s(int edge) const { return _outerRates[edge] - 1; } │ │ │ │ │ +219 │ │ │ │ │ +221 template │ │ │ │ │ +222 int _G_e_t_C_o_o_r_d_s(REAL coordTuples[]) const; │ │ │ │ │ +223 │ │ │ │ │ +225 template │ │ │ │ │ +_2_2_6 int _G_e_t_B_o_u_n_d_a_r_y_C_o_o_r_d_s(REAL coordTuples[]) const; │ │ │ │ │ +227 │ │ │ │ │ +229 template │ │ │ │ │ +_2_3_0 int _G_e_t_I_n_t_e_r_i_o_r_C_o_o_r_d_s(REAL coordTuples[]) const; │ │ │ │ │ +231 │ │ │ │ │ +233 template │ │ │ │ │ +234 int _G_e_t_V_e_r_t_e_x_C_o_o_r_d(int vertex, REAL coordTuples[]) const; │ │ │ │ │ +235 │ │ │ │ │ +238 template │ │ │ │ │ +_2_3_9 int _G_e_t_E_d_g_e_C_o_o_r_d_s(int edge, REAL coordTuples[]) const; │ │ │ │ │ +241 │ │ │ │ │ +243 │ │ │ │ │ +253 │ │ │ │ │ +_2_5_5 int _G_e_t_N_u_m_F_a_c_e_t_s() const { return _numFacets; } │ │ │ │ │ +256 │ │ │ │ │ +_2_5_8 int _G_e_t_F_a_c_e_t_S_i_z_e() const { return _facetSize; } │ │ │ │ │ +259 │ │ │ │ │ +_2_6_1 int _G_e_t_F_a_c_e_t_S_t_r_i_d_e() const { return _facetStride; } │ │ │ │ │ +262 │ │ │ │ │ +_2_6_4 int _G_e_t_F_a_c_e_t_s(int facetTuples[]) const; │ │ │ │ │ 266 │ │ │ │ │ -268 float _G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const; │ │ │ │ │ -269 │ │ │ │ │ -271 bool _H_a_s_E_d_g_e_S_h_a_r_p_n_e_s_s() const; │ │ │ │ │ -272 │ │ │ │ │ -274 float _G_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex) const; │ │ │ │ │ -275 │ │ │ │ │ -277 void _G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, │ │ │ │ │ -278 float * leadingEdgeSharp, float * trailingEdgeSharp) const; │ │ │ │ │ -280 │ │ │ │ │ -281protected: │ │ │ │ │ -283 friend class FaceVertex; │ │ │ │ │ -284 │ │ │ │ │ -285 _V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r() { } │ │ │ │ │ -286 _~_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r() { } │ │ │ │ │ -287 │ │ │ │ │ -288 typedef Vtr::internal::StackBuffer IntBuffer; │ │ │ │ │ -289 typedef Vtr::internal::StackBuffer FloatBuffer; │ │ │ │ │ -290 │ │ │ │ │ -291 void initFaceSizes(); │ │ │ │ │ -292 void initEdgeSharpness(); │ │ │ │ │ -294 │ │ │ │ │ -295protected: │ │ │ │ │ -297 // Member variables assigned through the above interface: │ │ │ │ │ -298 unsigned short _isValid : 1; │ │ │ │ │ -299 unsigned short _isInitialized : 1; │ │ │ │ │ -300 unsigned short _isFinalized : 1; │ │ │ │ │ -301 │ │ │ │ │ -302 unsigned short _isManifold : 1; │ │ │ │ │ -303 unsigned short _isBoundary : 1; │ │ │ │ │ -304 │ │ │ │ │ -305 unsigned short _hasFaceSizes : 1; │ │ │ │ │ -306 unsigned short _hasEdgeSharpness : 1; │ │ │ │ │ -307 │ │ │ │ │ -308 short _numFaces; │ │ │ │ │ -309 float _vertSharpness; │ │ │ │ │ -310 │ │ │ │ │ -311 FloatBuffer _faceEdgeSharpness; │ │ │ │ │ -312 IntBuffer _faceSizeOffsets; │ │ │ │ │ -314}; │ │ │ │ │ -315 │ │ │ │ │ -316// │ │ │ │ │ -317// Public inline methods for simple assignment: │ │ │ │ │ -318// │ │ │ │ │ -319inline bool │ │ │ │ │ -_3_2_0_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_V_a_l_i_d() const { │ │ │ │ │ -321 return _isValid; │ │ │ │ │ -322} │ │ │ │ │ -323 │ │ │ │ │ -324inline void │ │ │ │ │ -_3_2_5_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d(bool isManifold) { │ │ │ │ │ -326 _isManifold = isManifold; │ │ │ │ │ -327} │ │ │ │ │ -328inline bool │ │ │ │ │ -_3_2_9_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_M_a_n_i_f_o_l_d() const { │ │ │ │ │ -330 return _isManifold; │ │ │ │ │ -331} │ │ │ │ │ -332 │ │ │ │ │ -333inline void │ │ │ │ │ -_3_3_4_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_B_o_u_n_d_a_r_y(bool isBoundary) { │ │ │ │ │ -335 _isBoundary = isBoundary; │ │ │ │ │ -336} │ │ │ │ │ -337inline bool │ │ │ │ │ -_3_3_8_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_B_o_u_n_d_a_r_y() const { │ │ │ │ │ -339 return _isBoundary; │ │ │ │ │ -340} │ │ │ │ │ -341 │ │ │ │ │ -342// │ │ │ │ │ -343// Public inline methods involving sizes of incident faces: │ │ │ │ │ -344// │ │ │ │ │ -345inline bool │ │ │ │ │ -_3_4_6_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s() const { │ │ │ │ │ -347 return _hasFaceSizes; │ │ │ │ │ -348} │ │ │ │ │ -349inline void │ │ │ │ │ -_3_5_0_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s() { │ │ │ │ │ -351 _hasFaceSizes = false; │ │ │ │ │ -352} │ │ │ │ │ -353 │ │ │ │ │ -354inline void │ │ │ │ │ -_3_5_5_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int incFaceIndex, int faceSize) { │ │ │ │ │ -356 │ │ │ │ │ -357 if (!_hasFaceSizes) initFaceSizes(); │ │ │ │ │ -358 │ │ │ │ │ -359 _faceSizeOffsets[incFaceIndex] = faceSize; │ │ │ │ │ -360} │ │ │ │ │ -361inline int │ │ │ │ │ -_3_6_2_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e(int incFaceIndex) const { │ │ │ │ │ -363 │ │ │ │ │ -364 return _isFinalized ? │ │ │ │ │ -365 (_faceSizeOffsets[incFaceIndex+1] - _faceSizeOffsets[incFaceIndex]) : │ │ │ │ │ -366 _faceSizeOffsets[incFaceIndex]; │ │ │ │ │ -367} │ │ │ │ │ -368 │ │ │ │ │ -369// │ │ │ │ │ -370// Public inline methods involving vertex sharpness: │ │ │ │ │ -371// │ │ │ │ │ -372inline bool │ │ │ │ │ -_3_7_3_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const { │ │ │ │ │ -374 return _vertSharpness > 0.0f; │ │ │ │ │ -375} │ │ │ │ │ -376inline void │ │ │ │ │ -_3_7_7_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() { │ │ │ │ │ -378 _vertSharpness = 0.0f; │ │ │ │ │ -379} │ │ │ │ │ -380 │ │ │ │ │ -381inline void │ │ │ │ │ -_3_8_2_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float vertSharpness) { │ │ │ │ │ -383 _vertSharpness = vertSharpness; │ │ │ │ │ -384} │ │ │ │ │ -385inline float │ │ │ │ │ -_3_8_6_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s() const { │ │ │ │ │ -387 return _vertSharpness; │ │ │ │ │ -388} │ │ │ │ │ -389 │ │ │ │ │ -390// │ │ │ │ │ -391// Public inline methods involving vertex sharpness: │ │ │ │ │ -392// │ │ │ │ │ -393inline bool │ │ │ │ │ -_3_9_4_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_E_d_g_e_S_h_a_r_p_n_e_s_s() const { │ │ │ │ │ -395 return _hasEdgeSharpness; │ │ │ │ │ -396} │ │ │ │ │ -397inline void │ │ │ │ │ -_3_9_8_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_E_d_g_e_S_h_a_r_p_n_e_s_s() { │ │ │ │ │ -399 _hasEdgeSharpness = false; │ │ │ │ │ -400} │ │ │ │ │ -401 │ │ │ │ │ -402inline void │ │ │ │ │ -_4_0_3_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex, float sharpness) { │ │ │ │ │ -404 │ │ │ │ │ -405 if (!_hasEdgeSharpness) initEdgeSharpness(); │ │ │ │ │ -406 │ │ │ │ │ -407 // Assign the leading edge of the face after the edge (even index): │ │ │ │ │ -408 if (edgeIndex < _numFaces) { │ │ │ │ │ -409 _faceEdgeSharpness[2*edgeIndex] = sharpness; │ │ │ │ │ -410 } │ │ │ │ │ -411 │ │ │ │ │ -412 // Assign the trailing edge of the face before the edge (odd index): │ │ │ │ │ -413 if (edgeIndex > 0) { │ │ │ │ │ -414 _faceEdgeSharpness[2*edgeIndex-1] = sharpness; │ │ │ │ │ -415 } else if (!_I_s_B_o_u_n_d_a_r_y()) { │ │ │ │ │ -416 _faceEdgeSharpness[2*_numFaces-1] = sharpness; │ │ │ │ │ -417 } │ │ │ │ │ -418} │ │ │ │ │ -419inline float │ │ │ │ │ -_4_2_0_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s(int edgeIndex) const { │ │ │ │ │ -421 │ │ │ │ │ -422 // All edges are first of the pair (even index) except last of boundary │ │ │ │ │ -423 return _faceEdgeSharpness[2*edgeIndex - (edgeIndex == _numFaces)]; │ │ │ │ │ -424} │ │ │ │ │ -425 │ │ │ │ │ -426inline void │ │ │ │ │ -_4_2_7_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, │ │ │ │ │ -428 float leadingEdgeSharpness, float trailingEdgeSharpness) { │ │ │ │ │ -429 │ │ │ │ │ -430 if (!_hasEdgeSharpness) initEdgeSharpness(); │ │ │ │ │ -431 │ │ │ │ │ -432 _faceEdgeSharpness[2*faceIndex ] = leadingEdgeSharpness; │ │ │ │ │ -433 _faceEdgeSharpness[2*faceIndex+1] = trailingEdgeSharpness; │ │ │ │ │ -434} │ │ │ │ │ -435inline void │ │ │ │ │ -_4_3_6_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s(int faceIndex, │ │ │ │ │ -437 float * leadingEdgeSharpness, float * trailingEdgeSharpness) const { │ │ │ │ │ -438 │ │ │ │ │ -439 *leadingEdgeSharpness = _faceEdgeSharpness[2*faceIndex]; │ │ │ │ │ -440 *trailingEdgeSharpness = _faceEdgeSharpness[2*faceIndex+1]; │ │ │ │ │ -441} │ │ │ │ │ -442 │ │ │ │ │ -443} // end namespace Bfr │ │ │ │ │ -444 │ │ │ │ │ -445} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -446using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -447} // end namespace OpenSubdiv │ │ │ │ │ -448 │ │ │ │ │ -449#endif /* OPENSUBDIV3_BFR_VERTEX_DESCRIPTOR_H */ │ │ │ │ │ +268 │ │ │ │ │ +283 │ │ │ │ │ +_2_8_5 void _T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s(int facetTuples[], int commonOffset); │ │ │ │ │ +286 │ │ │ │ │ +_2_8_9 void _T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s(int facetTuples[], │ │ │ │ │ +290 int const boundaryIndices[], │ │ │ │ │ +291 int interiorOffset); │ │ │ │ │ +292 │ │ │ │ │ +_2_9_4 void _T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s(int facetTuples[], │ │ │ │ │ +295 int const boundaryIndices[], │ │ │ │ │ +296 int const interiorIndices[]); │ │ │ │ │ +298 │ │ │ │ │ +299private: │ │ │ │ │ +300 // Private initialization methods: │ │ │ │ │ +301 bool validateArguments(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, │ │ │ │ │ +302 int nRates, int const rates[], _O_p_t_i_o_n_s const & options); │ │ │ │ │ +303 │ │ │ │ │ +304 void initialize(_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n const & p, │ │ │ │ │ +305 int nRates, int const rates[], _O_p_t_i_o_n_s const & options); │ │ │ │ │ +306 │ │ │ │ │ +307 void initializeDefaults(); │ │ │ │ │ +308 int initializeRates(int nRates, int const rates[]); │ │ │ │ │ +309 void initializeInventoryForParamTri(int sumOfOuterRates); │ │ │ │ │ +310 void initializeInventoryForParamQuad(int sumOfOuterRates); │ │ │ │ │ +311 void initializeInventoryForParamQPoly(int sumOfOuterRates); │ │ │ │ │ +312 │ │ │ │ │ +313private: │ │ │ │ │ +314 // Private members: │ │ │ │ │ +315 _P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n _param; │ │ │ │ │ +316 │ │ │ │ │ +317 unsigned short _isValid : 1; │ │ │ │ │ +318 unsigned short _isUniform : 1; │ │ │ │ │ +319 unsigned short _triangulate : 1; │ │ │ │ │ +320 unsigned short _singleFace : 1; │ │ │ │ │ +321 unsigned short _segmentedFace : 1; │ │ │ │ │ +322 unsigned short _triangleFan : 1; │ │ │ │ │ +323 unsigned short _splitQuad : 1; │ │ │ │ │ +324 │ │ │ │ │ +325 short _facetSize; │ │ │ │ │ +326 int _facetStride; │ │ │ │ │ +327 int _coordStride; │ │ │ │ │ +328 │ │ │ │ │ +329 int _numGivenRates; │ │ │ │ │ +330 int _numBoundaryPoints; │ │ │ │ │ +331 int _numInteriorPoints; │ │ │ │ │ +332 int _numFacets; │ │ │ │ │ +333 │ │ │ │ │ +334 int _innerRates[2]; │ │ │ │ │ +335 int* _outerRates; │ │ │ │ │ +336 int _outerRatesLocal[4]; │ │ │ │ │ +337}; │ │ │ │ │ +338 │ │ │ │ │ +339// │ │ │ │ │ +340// Inline implementations: │ │ │ │ │ +341// │ │ │ │ │ +342inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ +_3_4_3_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_P_r_e_s_e_r_v_e_Q_u_a_d_s(bool on) { │ │ │ │ │ +344 _preserveQuads = on; │ │ │ │ │ +345 return *this; │ │ │ │ │ +346} │ │ │ │ │ +347inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ +_3_4_8_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_i_z_e(int numIndices) { │ │ │ │ │ +349 _facetSize4 = (numIndices == 4); │ │ │ │ │ +350 return *this; │ │ │ │ │ +351} │ │ │ │ │ +352inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ +_3_5_3_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_t_r_i_d_e(int stride) { │ │ │ │ │ +354 _facetStride = (short) stride; │ │ │ │ │ +355 return *this; │ │ │ │ │ +356} │ │ │ │ │ +357inline _T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s & │ │ │ │ │ +_3_5_8_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_C_o_o_r_d_S_t_r_i_d_e(int stride) { │ │ │ │ │ +359 _coordStride = (short) stride; │ │ │ │ │ +360 return *this; │ │ │ │ │ +361} │ │ │ │ │ +362 │ │ │ │ │ +363template │ │ │ │ │ +364inline int │ │ │ │ │ +_3_6_5_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_V_e_r_t_e_x_C_o_o_r_d(int vertex, REAL coord[]) const { │ │ │ │ │ +366 _param._G_e_t_V_e_r_t_e_x_C_o_o_r_d(vertex, coord); │ │ │ │ │ +367 return 1; │ │ │ │ │ +368} │ │ │ │ │ +369 │ │ │ │ │ +370template │ │ │ │ │ +371inline int │ │ │ │ │ +_3_7_2_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_C_o_o_r_d_s(REAL coordTuples[]) const { │ │ │ │ │ +373 int nCoords = _G_e_t_B_o_u_n_d_a_r_y_C_o_o_r_d_s(coordTuples); │ │ │ │ │ +374 nCoords += _G_e_t_I_n_t_e_r_i_o_r_C_o_o_r_d_s(coordTuples + nCoords * _coordStride); │ │ │ │ │ +375 return nCoords; │ │ │ │ │ +376} │ │ │ │ │ +377 │ │ │ │ │ +378} // end namespace Bfr │ │ │ │ │ +379 │ │ │ │ │ +380} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +381using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +382 │ │ │ │ │ +383} // end namespace OpenSubdiv │ │ │ │ │ +384 │ │ │ │ │ +385#endif /* OPENSUBDIV3_BFR_TESSELLATION */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -Simple class used by subclasses of SurfaceFactory to describe a vertex. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_1_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float GetVertexSharpness() const │ │ │ │ │ -Return the sharpness of the vertex. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_F_i_n_a_l_i_z_e │ │ │ │ │ -bool Finalize() │ │ │ │ │ -Terminate the sequence of specifications. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d │ │ │ │ │ -void SetManifold(bool isManifold) │ │ │ │ │ -Declare the vertex neighborhood as manifold (ordered) │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_2_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_n_i_t_i_a_l_i_z_e │ │ │ │ │ -bool Initialize(int numIncidentFaces) │ │ │ │ │ -Initialize specification with the number of incident faces. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_M_a_n_i_f_o_l_d │ │ │ │ │ -bool IsManifold() const │ │ │ │ │ -Return if vertex neighborhood is manifold. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_2_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -bool HasEdgeSharpness() const │ │ │ │ │ -Return if sharpness was assigned to the incident edges. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_9_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e │ │ │ │ │ -int GetIncidentFaceSize(int faceIndex) const │ │ │ │ │ -Return the size of an incident face. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float GetManifoldEdgeSharpness(int edgeIndex) const │ │ │ │ │ -Return the sharpness assigned to a manifold edge. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_2_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_: │ │ │ │ │ -_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -void SetIncidentFaceEdgeSharpness(int faceIndex, float leadingEdgeSharp, float │ │ │ │ │ -trailingEdgeSharp) │ │ │ │ │ -Assign sharpness to the edges of an incident face. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_2_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ -bool HasVertexSharpness() const │ │ │ │ │ -Return if sharpness was assigned to the vertex. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s │ │ │ │ │ -void ClearIncidentFaceSizes() │ │ │ │ │ -Remove any assigned sizes of incident faces. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_5_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ -void SetVertexSharpness(float sharpness) │ │ │ │ │ -Assign sharpness to the vertex. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ -void ClearVertexSharpness() │ │ │ │ │ -Remove any sharpness assigned to the vertex. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_C_l_e_a_r_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -void ClearEdgeSharpness() │ │ │ │ │ -Remove any sharpness assigned to the incident edges. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_: │ │ │ │ │ -_G_e_t_I_n_c_i_d_e_n_t_F_a_c_e_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -void GetIncidentFaceEdgeSharpness(int faceIndex, float *leadingEdgeSharp, float │ │ │ │ │ -*trailingEdgeSharp) const │ │ │ │ │ -Return the sharpness assigned to edges of an incident face. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_3_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_B_o_u_n_d_a_r_y │ │ │ │ │ -bool IsBoundary() const │ │ │ │ │ -Return if vertex neighborhood is on a boundary. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_3_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_I_s_V_a_l_i_d │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n │ │ │ │ │ +Simple class defining the 2D parameterization of a face. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_._h_:_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_:_:_G_e_t_F_a_c_e_S_i_z_e │ │ │ │ │ +int GetFaceSize() const │ │ │ │ │ +Returns the size (number of vertices) of the corresponding face. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_._h_:_1_0_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n_:_:_G_e_t_V_e_r_t_e_x_C_o_o_r_d │ │ │ │ │ +void GetVertexCoord(int vertexIndex, REAL uvCoord[2]) const │ │ │ │ │ +Returns the (u,v) coordinate of a given vertex. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +Encapsulates a specific tessellation pattern of a Parameterization. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_S_i_z_e │ │ │ │ │ +int GetFaceSize() const │ │ │ │ │ +Return the size of the face. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_B_o_u_n_d_a_r_y_C_o_o_r_d_s │ │ │ │ │ +int GetNumBoundaryCoords() const │ │ │ │ │ +Return the number of boundary coordinates. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_1_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_~_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +~Tessellation() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s │ │ │ │ │ +void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], │ │ │ │ │ +int const interiorIndices[]) │ │ │ │ │ +Reassign all facet coordinate indices. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_C_o_o_r_d_S_t_r_i_d_e │ │ │ │ │ +int GetCoordStride() const │ │ │ │ │ +Return the number of elements between each coordinate. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_0_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_E_d_g_e_C_o_o_r_d_s │ │ │ │ │ +int GetNumEdgeCoords(int edge) const │ │ │ │ │ +Return the number of coordinates within a given edge (excluding those at its │ │ │ │ │ +end vertices) │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_1_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_I_n_t_e_r_i_o_r_C_o_o_r_d_s │ │ │ │ │ +int GetInteriorCoords(REAL coordTuples[]) const │ │ │ │ │ +Retrieve the coordinates for the boundary. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_t_S_t_r_i_d_e │ │ │ │ │ +int GetFacetStride() const │ │ │ │ │ +Return the number of elements between each facet. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_I_s_U_n_i_f_o_r_m │ │ │ │ │ +bool IsUniform() const │ │ │ │ │ +Return if the pattern is uniform. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_C_o_o_r_d_s │ │ │ │ │ +int GetNumCoords() const │ │ │ │ │ +Return the number of coordinates in the entire pattern. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_0_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_C_o_o_r_d_s │ │ │ │ │ +int GetCoords(REAL coordTuples[]) const │ │ │ │ │ +Retrieve the coordinates for the entire pattern. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_7_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s │ │ │ │ │ +void TransformFacetCoordIndices(int facetTuples[], int commonOffset) │ │ │ │ │ +Apply a common offset to all facet coordinate indices. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +Tessellation(Parameterization const &p, int numRates, int const rates[], │ │ │ │ │ +Options const &options=Options()) │ │ │ │ │ +General constructor providing multiple tessellation rates for a non-uniform │ │ │ │ │ +tessellation. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_P_a_r_a_m_e_t_e_r_i_z_a_t_i_o_n │ │ │ │ │ +Parameterization GetParameterization() const │ │ │ │ │ +Return the Parameterization. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_r_a_n_s_f_o_r_m_F_a_c_e_t_C_o_o_r_d_I_n_d_i_c_e_s │ │ │ │ │ +void TransformFacetCoordIndices(int facetTuples[], int const boundaryIndices[], │ │ │ │ │ +int interiorOffset) │ │ │ │ │ +Reassign indices of boundary coordinates while offseting those of interior │ │ │ │ │ +coordinates. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_t_S_i_z_e │ │ │ │ │ +int GetFacetSize() const │ │ │ │ │ +Return the number of indices assigned to each facet. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +Tessellation()=delete │ │ │ │ │ +Default construction is unavailable. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +Tessellation(Parameterization const &p, int uniformRate, Options const │ │ │ │ │ +&options=Options()) │ │ │ │ │ +Simple constructor providing a single uniform tessellation rate. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_F_a_c_e_t_s │ │ │ │ │ +int GetFacets(int facetTuples[]) const │ │ │ │ │ +Retrieve the facet indices for the entire pattern. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_F_a_c_e_t_s │ │ │ │ │ +int GetNumFacets() const │ │ │ │ │ +Return the number of facets in the entire pattern. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_N_u_m_I_n_t_e_r_i_o_r_C_o_o_r_d_s │ │ │ │ │ +int GetNumInteriorCoords() const │ │ │ │ │ +Return the number of interior coordinates. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_2_1_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_V_e_r_t_e_x_C_o_o_r_d │ │ │ │ │ +int GetVertexCoord(int vertex, REAL coordTuples[]) const │ │ │ │ │ +Retrieve the coordinate for a given vertex of the face. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_B_o_u_n_d_a_r_y_C_o_o_r_d_s │ │ │ │ │ +int GetBoundaryCoords(REAL coordTuples[]) const │ │ │ │ │ +Retrieve the coordinates for the boundary. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_T_e_s_s_e_l_l_a_t_i_o_n │ │ │ │ │ +Tessellation(Tessellation const &)=delete │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_R_a_t_e_s │ │ │ │ │ +int GetRates(int rates[]) const │ │ │ │ │ +Retrieve the rates assigned. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_I_s_V_a_l_i_d │ │ │ │ │ bool IsValid() const │ │ │ │ │ -Return if instance is valid. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_2_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_H_a_s_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e_s │ │ │ │ │ -bool HasIncidentFaceSizes() const │ │ │ │ │ -Return if the sizes of incident faces are assigned. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_B_o_u_n_d_a_r_y │ │ │ │ │ -void SetBoundary(bool isOnBoundary) │ │ │ │ │ -Declare the vertex neighborhood as being on a boundary. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_I_n_c_i_d_e_n_t_F_a_c_e_S_i_z_e │ │ │ │ │ -void SetIncidentFaceSize(int faceIndex, int faceSize) │ │ │ │ │ -Assign the size of an incident face. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_3_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_V_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_:_:_S_e_t_M_a_n_i_f_o_l_d_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -void SetManifoldEdgeSharpness(int edgeIndex, float edgeSharpness) │ │ │ │ │ -Assign sharpness to the edge of a manifold neighborhood. │ │ │ │ │ -DDeeffiinniittiioonn _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h_:_4_0_3 │ │ │ │ │ +Return true if correctly initialized. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_1_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ │ +Tessellation & operator=(Tessellation const &)=delete │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_G_e_t_E_d_g_e_C_o_o_r_d_s │ │ │ │ │ +int GetEdgeCoords(int edge, REAL coordTuples[]) const │ │ │ │ │ +Retrieve the coordinates for a given edge of the face (excluding those at its │ │ │ │ │ +end vertices) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Options configure a Tessellation to specify the nature of both its results and │ │ │ │ │ +the structure of the c... │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Options() │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_G_e_t_C_o_o_r_d_S_t_r_i_d_e │ │ │ │ │ +int GetCoordStride() const │ │ │ │ │ +Return the stride between (u,v) pairs. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_9_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_i_z_e │ │ │ │ │ +Options & SetFacetSize(int numIndices) │ │ │ │ │ +Assign the number of indices per facet (must be 3 or 4, default is 3) │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_G_e_t_F_a_c_e_t_S_t_r_i_d_e │ │ │ │ │ +int GetFacetStride() const │ │ │ │ │ +Return the stride between facets. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_G_e_t_F_a_c_e_t_S_i_z_e │ │ │ │ │ +int GetFacetSize() const │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_8_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_C_o_o_r_d_S_t_r_i_d_e │ │ │ │ │ +Options & SetCoordStride(int stride) │ │ │ │ │ +Assign the stride between (u,v) pairs (default is 2) │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_a_c_e_t_S_t_r_i_d_e │ │ │ │ │ +Options & SetFacetStride(int stride) │ │ │ │ │ +Assign the stride between facets (default is facet size) │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_3_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_B_f_r_:_:_T_e_s_s_e_l_l_a_t_i_o_n_:_:_O_p_t_i_o_n_s_:_:_P_r_e_s_e_r_v_e_Q_u_a_d_s │ │ │ │ │ +bool PreserveQuads() const │ │ │ │ │ +Return if preservation of quads is set. │ │ │ │ │ +DDeeffiinniittiioonn _t_e_s_s_e_l_l_a_t_i_o_n_._h_:_7_4 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _b_f_r │ │ │ │ │ - * _v_e_r_t_e_x_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _t_e_s_s_e_l_l_a_t_i_o_n_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00683_source.html │ │ │ │ @@ -249,15 +249,15 @@ │ │ │ │
virtual int populateFaceVertexDescriptor(Index faceIndex, int faceVertex, VertexDescriptor *vertexDescriptor) const =0
Describe the topology of incident faces around a face-vertex.
│ │ │ │
virtual bool getFaceNeighborhoodVertexIndicesIfRegular(Index faceIndex, Index vertexIndices[]) const
│ │ │ │
virtual bool getFaceNeighborhoodFVarValueIndicesIfRegular(Index faceIndex, FVarID fvarID, Index fvarValueIndices[]) const
│ │ │ │
virtual int getFaceFVarValueIndices(Index faceIndex, FVarID fvarID, Index fvarValueIndices[]) const =0
Gather the face-varying indices of the face's vertices.
│ │ │ │
virtual int getFaceVertexIndices(Index faceIndex, Index vertexIndices[]) const =0
Gather the indices of the face's vertices.
│ │ │ │
virtual bool isFaceHole(Index faceIndex) const =0
Returns if a face is a hole.
│ │ │ │
std::intptr_t FVarID
Type used to identify and specify face-varying primvars.
│ │ │ │ -
Simple class used by subclasses of SurfaceFactory to describe a vertex.
│ │ │ │ +
Simple class used by subclasses of SurfaceFactory to describe a vertex.
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
topologyRefiner.h File Reference
│ │ │ │ +
topologyLevel.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../sdc/types.h"
│ │ │ │ -#include "../sdc/options.h"
│ │ │ │ +#include "../vtr/level.h"
│ │ │ │ +#include "../vtr/refinement.h"
│ │ │ │ #include "../far/types.h"
│ │ │ │ -#include "../far/topologyLevel.h"
│ │ │ │ #include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  TopologyRefiner
 Stores topology data for a specified set of refinement options. More...
 
struct  TopologyRefiner::UniformOptions
 Uniform refinement options. More...
 
struct  TopologyRefiner::AdaptiveOptions
 Adaptive refinement options. More...
class  TopologyLevel
 An interface for accessing data in a specific level of a refined topology hierarchy. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Vtr
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,37 +1,28 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -topologyRefiner.h File Reference │ │ │ │ │ +topologyLevel.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_s_d_c_/_t_y_p_e_s_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_l_e_v_e_l_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_r_e_f_i_n_e_m_e_n_t_._h" │ │ │ │ │ #include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_L_e_v_e_l_._h" │ │ │ │ │ #include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ - class   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ -  Stores topology data for a specified set of refinement options. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -struct   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s │ │ │ │ │ -  Uniform refinement options. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -struct   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ -  Adaptive refinement options. _M_o_r_e_._._. │ │ │ │ │ +class   _T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ +  An interface for accessing data in a specific level of a refined │ │ │ │ │ + topology hierarchy. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ -namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r │ │ │ │ │ -  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_L_e_v_e_l_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00707.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,5 +1,3 @@ │ │ │ │ │ var a00707 = [ │ │ │ │ │ - ["TopologyRefiner", "a01121.html", "a01121"], │ │ │ │ │ - ["UniformOptions", "a01125.html", "a01125"], │ │ │ │ │ - ["AdaptiveOptions", "a01129.html", "a01129"] │ │ │ │ │ + ["TopologyLevel", "a01113.html", "a01113"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00707_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/topologyRefiner.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/topologyLevel.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
topologyRefiner.h
│ │ │ │ +
topologyLevel.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2014 DreamWorks Animation LLC.
│ │ │ │ +
2// Copyright 2015 DreamWorks Animation LLC.
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,305 +118,228 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_REFINER_H
│ │ │ │ -
25#define OPENSUBDIV3_FAR_TOPOLOGY_REFINER_H
│ │ │ │ +
24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H
│ │ │ │ +
25#define OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H
│ │ │ │
26
│ │ │ │
27#include "../version.h"
│ │ │ │
28
│ │ │ │ -
29#include "../sdc/types.h"
│ │ │ │ -
30#include "../sdc/options.h"
│ │ │ │ +
29#include "../vtr/level.h"
│ │ │ │ +
30#include "../vtr/refinement.h"
│ │ │ │
31#include "../far/types.h"
│ │ │ │ -
32#include "../far/topologyLevel.h"
│ │ │ │ -
33
│ │ │ │ -
34#include <vector>
│ │ │ │ -
35
│ │ │ │ -
36
│ │ │ │ -
37namespace OpenSubdiv {
│ │ │ │ -
38namespace OPENSUBDIV_VERSION {
│ │ │ │ +
32
│ │ │ │ +
33#include <vector>
│ │ │ │ +
34
│ │ │ │ +
35namespace OpenSubdiv {
│ │ │ │ +
36namespace OPENSUBDIV_VERSION {
│ │ │ │ +
37
│ │ │ │ +
38namespace Far {
│ │ │ │
39
│ │ │ │ -
40namespace Vtr { namespace internal { class SparseSelector; } }
│ │ │ │ -
41namespace Far { namespace internal { class FeatureMask; } }
│ │ │ │ -
42
│ │ │ │ -
43namespace Far {
│ │ │ │ -
44
│ │ │ │ -
45template <typename REAL> class PrimvarRefinerReal;
│ │ │ │ -
46template <class MESH> class TopologyRefinerFactory;
│ │ │ │ -
47
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
52
│ │ │ │ -
53public:
│ │ │ │ -
54
│ │ │ │ - │ │ │ │ -
57
│ │ │ │ - │ │ │ │ +
│ │ │ │ + │ │ │ │ +
50
│ │ │ │ +
51public:
│ │ │ │ +
53
│ │ │ │
60
│ │ │ │ -
62 Sdc::SchemeType GetSchemeType() const { return _subdivType; }
│ │ │ │ +
62 int GetNumVertices() const { return _level->getNumVertices(); }
│ │ │ │
63
│ │ │ │ -
65 Sdc::Options GetSchemeOptions() const { return _subdivOptions; }
│ │ │ │ +
65 int GetNumFaces() const { return _level->getNumFaces(); }
│ │ │ │
66
│ │ │ │ -
68 bool IsUniform() const { return _isUniform; }
│ │ │ │ +
68 int GetNumEdges() const { return _level->getNumEdges(); }
│ │ │ │
69
│ │ │ │ -
71 int GetNumLevels() const { return (int)_farLevels.size(); }
│ │ │ │ -
72
│ │ │ │ -
74 int GetMaxLevel() const { return _maxLevel; }
│ │ │ │ +
71 int GetNumFaceVertices() const { return _level->getNumFaceVerticesTotal(); }
│ │ │ │ +
73
│ │ │ │
75
│ │ │ │ -
77 int GetMaxValence() const { return _maxValence; }
│ │ │ │ -
78
│ │ │ │ -
80 bool HasHoles() const { return _hasHoles; }
│ │ │ │ -
81
│ │ │ │ -
83 int GetNumVerticesTotal() const { return _totalVertices; }
│ │ │ │ -
84
│ │ │ │ -
86 int GetNumEdgesTotal() const { return _totalEdges; }
│ │ │ │ -
87
│ │ │ │ -
89 int GetNumFacesTotal() const { return _totalFaces; }
│ │ │ │ -
90
│ │ │ │ -
92 int GetNumFaceVerticesTotal() const { return _totalFaceVertices; }
│ │ │ │ -
93
│ │ │ │ -
95 TopologyLevel const & GetLevel(int level) const { return _farLevels[level]; }
│ │ │ │ -
96
│ │ │ │ -
98
│ │ │ │ +
90 //
│ │ │ │ +
91
│ │ │ │ +
93 ConstIndexArray GetFaceVertices(Index f) const { return _level->getFaceVertices(f); }
│ │ │ │ +
94
│ │ │ │ +
96 ConstIndexArray GetFaceEdges(Index f) const { return _level->getFaceEdges(f); }
│ │ │ │ +
97
│ │ │ │ +
99 ConstIndexArray GetEdgeVertices(Index e) const { return _level->getEdgeVertices(e); }
│ │ │ │
100
│ │ │ │ -
101 //
│ │ │ │ -
102 // Uniform refinement
│ │ │ │ -
103 //
│ │ │ │ -
104
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
119
│ │ │ │ -
│ │ │ │ -
120 UniformOptions(int level) :
│ │ │ │ -
121 refinementLevel(level & 0xf),
│ │ │ │ - │ │ │ │ -
123 fullTopologyInLastLevel(false) { }
│ │ │ │ -
│ │ │ │ +
102 ConstIndexArray GetEdgeFaces(Index e) const { return _level->getEdgeFaces(e); }
│ │ │ │ +
103
│ │ │ │ +
105 ConstIndexArray GetVertexFaces(Index v) const { return _level->getVertexFaces(v); }
│ │ │ │ +
106
│ │ │ │ +
108 ConstIndexArray GetVertexEdges(Index v) const { return _level->getVertexEdges(v); }
│ │ │ │ +
109
│ │ │ │ +
111 ConstLocalIndexArray GetVertexFaceLocalIndices(Index v) const { return _level->getVertexFaceLocalIndices(v); }
│ │ │ │ +
112
│ │ │ │ +
114 ConstLocalIndexArray GetVertexEdgeLocalIndices(Index v) const { return _level->getVertexEdgeLocalIndices(v); }
│ │ │ │ +
115
│ │ │ │ +
117 ConstLocalIndexArray GetEdgeFaceLocalIndices(Index e) const { return _level->getEdgeFaceLocalIndices(e); }
│ │ │ │ +
118
│ │ │ │ +
120 Index FindEdge(Index v0, Index v1) const { return _level->findEdge(v0, v1); }
│ │ │ │ +
122
│ │ │ │
124
│ │ │ │ -
126 void SetRefinementLevel(int level) { refinementLevel = level & 0xf; }
│ │ │ │ -
127
│ │ │ │ -
128 unsigned int refinementLevel:4,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
134 };
│ │ │ │ -
│ │ │ │ +
126
│ │ │ │ +
128 bool IsEdgeNonManifold(Index e) const { return _level->isEdgeNonManifold(e); }
│ │ │ │ +
129
│ │ │ │ +
131 bool IsVertexNonManifold(Index v) const { return _level->isVertexNonManifold(v); }
│ │ │ │ +
132
│ │ │ │ +
134 bool IsEdgeBoundary(Index e) const { return _level->getEdgeTag(e)._boundary; }
│ │ │ │
135
│ │ │ │ - │ │ │ │ -
147
│ │ │ │ -
149 UniformOptions GetUniformOptions() const { return _uniformOptions; }
│ │ │ │ -
150
│ │ │ │ -
151 //
│ │ │ │ -
152 // Adaptive refinement
│ │ │ │ -
153 //
│ │ │ │ -
154
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
157
│ │ │ │ -
│ │ │ │ -
158 AdaptiveOptions(int level) :
│ │ │ │ -
159 isolationLevel(level & 0xf),
│ │ │ │ -
160 secondaryLevel(0xf),
│ │ │ │ - │ │ │ │ -
162 useInfSharpPatch(false),
│ │ │ │ - │ │ │ │ - │ │ │ │ -
│ │ │ │ -
165
│ │ │ │ -
167 void SetIsolationLevel(int level) { isolationLevel = level & 0xf; }
│ │ │ │ -
168
│ │ │ │ -
170 void SetSecondaryLevel(int level) { secondaryLevel = level & 0xf; }
│ │ │ │ +
137 bool IsVertexBoundary(Index v) const { return _level->getVertexTag(v)._boundary; }
│ │ │ │ +
138
│ │ │ │ +
140 bool IsVertexCorner(Index v) const { return (_level->getNumVertexFaces(v) == 1); }
│ │ │ │ +
141
│ │ │ │ +
162 bool IsVertexValenceRegular(Index v) const { return !_level->getVertexTag(v)._xordinary || IsVertexCorner(v); }
│ │ │ │ +
164
│ │ │ │ +
166
│ │ │ │
171
│ │ │ │ -
172 unsigned int isolationLevel:4;
│ │ │ │ -
174 unsigned int secondaryLevel:4;
│ │ │ │ -
176 unsigned int useSingleCreasePatch:1;
│ │ │ │ -
178 unsigned int useInfSharpPatch:1;
│ │ │ │ -
180 unsigned int considerFVarChannels:1;
│ │ │ │ - │ │ │ │ -
184 };
│ │ │ │ -
│ │ │ │ -
185
│ │ │ │ - │ │ │ │ -
193 ConstIndexArray selectedFaces = ConstIndexArray());
│ │ │ │ -
194
│ │ │ │ -
196 AdaptiveOptions GetAdaptiveOptions() const { return _adaptiveOptions; }
│ │ │ │ -
197
│ │ │ │ -
199 void Unrefine();
│ │ │ │ -
200
│ │ │ │ -
201
│ │ │ │ -
203
│ │ │ │ -
205
│ │ │ │ -
207 int GetNumFVarChannels() const;
│ │ │ │ -
208
│ │ │ │ - │ │ │ │ -
211
│ │ │ │ -
213 int GetNumFVarValuesTotal(int channel = 0) const;
│ │ │ │ -
214
│ │ │ │ -
216
│ │ │ │ -
217protected:
│ │ │ │ -
218
│ │ │ │ -
219 //
│ │ │ │ -
220 // Lower level protected methods intended strictly for internal use:
│ │ │ │ -
221 //
│ │ │ │ -
222 template <class MESH>
│ │ │ │ - │ │ │ │ - │ │ │ │ -
225 friend class PatchTableBuilder;
│ │ │ │ -
226 friend class PatchBuilder;
│ │ │ │ -
227 friend class PtexIndices;
│ │ │ │ -
228 template <typename REAL>
│ │ │ │ -
229 friend class PrimvarRefinerReal;
│ │ │ │ -
230
│ │ │ │ -
231 // Copy constructor exposed via the factory class:
│ │ │ │ - │ │ │ │ -
233
│ │ │ │ -
234public:
│ │ │ │ -
235 // Levels and Refinements available internally (avoids need for more friends)
│ │ │ │ -
236 Vtr::internal::Level & getLevel(int l) { return *_levels[l]; }
│ │ │ │ -
237 Vtr::internal::Level const & getLevel(int l) const { return *_levels[l]; }
│ │ │ │ -
238
│ │ │ │ -
239 Vtr::internal::Refinement & getRefinement(int l) { return *_refinements[l]; }
│ │ │ │ -
240 Vtr::internal::Refinement const & getRefinement(int l) const { return *_refinements[l]; }
│ │ │ │ -
241
│ │ │ │ -
242private:
│ │ │ │ -
243 // Not default constructible or copyable:
│ │ │ │ -
244 TopologyRefiner() : _uniformOptions(0), _adaptiveOptions(0) { }
│ │ │ │ -
245 TopologyRefiner & operator=(TopologyRefiner const &) { return *this; }
│ │ │ │ -
246
│ │ │ │ -
247 void selectFeatureAdaptiveComponents(Vtr::internal::SparseSelector& selector,
│ │ │ │ -
248 internal::FeatureMask const & mask,
│ │ │ │ -
249 ConstIndexArray selectedFaces);
│ │ │ │ -
250 void selectLinearIrregularFaces(Vtr::internal::SparseSelector& selector,
│ │ │ │ -
251 ConstIndexArray selectedFaces);
│ │ │ │ -
252
│ │ │ │ -
253 void initializeInventory();
│ │ │ │ -
254 void updateInventory(Vtr::internal::Level const & newLevel);
│ │ │ │ +
173 float GetEdgeSharpness(Index e) const { return _level->getEdgeSharpness(e); }
│ │ │ │ +
174
│ │ │ │ +
176 float GetVertexSharpness(Index v) const { return _level->getVertexSharpness(v); }
│ │ │ │ +
177
│ │ │ │ +
179 bool IsEdgeInfSharp(Index e) const { return _level->getEdgeTag(e)._infSharp; }
│ │ │ │ +
180
│ │ │ │ +
182 bool IsVertexInfSharp(Index v) const { return _level->getVertexTag(v)._infSharp; }
│ │ │ │ +
183
│ │ │ │ +
185 bool IsEdgeSemiSharp(Index e) const { return _level->getEdgeTag(e)._semiSharp; }
│ │ │ │ +
186
│ │ │ │ +
188 bool IsVertexSemiSharp(Index v) const { return _level->getVertexTag(v)._semiSharp; }
│ │ │ │ +
189
│ │ │ │ +
191 bool IsFaceHole(Index f) const { return _level->isFaceHole(f); }
│ │ │ │ +
192
│ │ │ │ +
194 Sdc::Crease::Rule GetVertexRule(Index v) const { return _level->getVertexRule(v); }
│ │ │ │ +
196
│ │ │ │ +
198
│ │ │ │ +
228
│ │ │ │ +
230 int GetNumFVarChannels() const { return _level->getNumFVarChannels(); }
│ │ │ │ +
231
│ │ │ │ +
234 int GetNumFVarValues(int channel = 0) const { return _level->getNumFVarValues(channel); }
│ │ │ │ +
235
│ │ │ │ +
│ │ │ │ +
237 ConstIndexArray GetFaceFVarValues(Index f, int channel = 0) const {
│ │ │ │ +
238 return _level->getFaceFVarValues(f, channel);
│ │ │ │ +
239 }
│ │ │ │ +
│ │ │ │ +
240
│ │ │ │ +
│ │ │ │ +
242 bool DoesVertexFVarTopologyMatch(Index v, int channel = 0) const {
│ │ │ │ +
243 return _level->doesVertexFVarTopologyMatch(v, channel);
│ │ │ │ +
244 }
│ │ │ │ +
│ │ │ │ +
245
│ │ │ │ +
│ │ │ │ +
247 bool DoesEdgeFVarTopologyMatch(Index e, int channel = 0) const {
│ │ │ │ +
248 return _level->doesEdgeFVarTopologyMatch(e, channel);
│ │ │ │ +
249 }
│ │ │ │ +
│ │ │ │ +
250
│ │ │ │ +
│ │ │ │ +
252 bool DoesFaceFVarTopologyMatch(Index f, int channel = 0) const {
│ │ │ │ +
253 return _level->doesFaceFVarTopologyMatch(f, channel);
│ │ │ │ +
254 }
│ │ │ │ +
│ │ │ │
255
│ │ │ │ -
256 void appendLevel(Vtr::internal::Level & newLevel);
│ │ │ │ -
257 void appendRefinement(Vtr::internal::Refinement & newRefinement);
│ │ │ │ -
258 void assembleFarLevels();
│ │ │ │ +
257
│ │ │ │
259
│ │ │ │ -
260private:
│ │ │ │ -
261
│ │ │ │ -
262 Sdc::SchemeType _subdivType;
│ │ │ │ -
263 Sdc::Options _subdivOptions;
│ │ │ │ -
264
│ │ │ │ -
265 unsigned int _isUniform : 1;
│ │ │ │ -
266 unsigned int _hasHoles : 1;
│ │ │ │ -
267 unsigned int _hasIrregFaces : 1;
│ │ │ │ -
268 unsigned int _regFaceSize : 3;
│ │ │ │ -
269 unsigned int _maxLevel : 4;
│ │ │ │ -
270
│ │ │ │ -
271 // Options assigned on refinement:
│ │ │ │ -
272 UniformOptions _uniformOptions;
│ │ │ │ -
273 AdaptiveOptions _adaptiveOptions;
│ │ │ │ -
274
│ │ │ │ -
275 // Cumulative properties of all levels:
│ │ │ │ -
276 int _totalVertices;
│ │ │ │ -
277 int _totalEdges;
│ │ │ │ -
278 int _totalFaces;
│ │ │ │ -
279 int _totalFaceVertices;
│ │ │ │ -
280 int _maxValence;
│ │ │ │ -
281
│ │ │ │ -
282 // Note the base level may be shared with another instance
│ │ │ │ -
283 bool _baseLevelOwned;
│ │ │ │ +
260
│ │ │ │ +
262 ConstIndexArray GetFaceChildFaces(Index f) const { return _refToChild->getFaceChildFaces(f); }
│ │ │ │ +
263
│ │ │ │ +
265 ConstIndexArray GetFaceChildEdges(Index f) const { return _refToChild->getFaceChildEdges(f); }
│ │ │ │ +
266
│ │ │ │ +
268 ConstIndexArray GetEdgeChildEdges(Index e) const { return _refToChild->getEdgeChildEdges(e); }
│ │ │ │ +
269
│ │ │ │ +
271 Index GetFaceChildVertex( Index f) const { return _refToChild->getFaceChildVertex(f); }
│ │ │ │ +
272
│ │ │ │ +
274 Index GetEdgeChildVertex( Index e) const { return _refToChild->getEdgeChildVertex(e); }
│ │ │ │ +
275
│ │ │ │ +
277 Index GetVertexChildVertex(Index v) const { return _refToChild->getVertexChildVertex(v); }
│ │ │ │ +
278
│ │ │ │ +
280 Index GetFaceParentFace(Index f) const { return _refToParent->getChildFaceParentFace(f); }
│ │ │ │ +
282
│ │ │ │
284
│ │ │ │ -
285 std::vector<Vtr::internal::Level *> _levels;
│ │ │ │ -
286 std::vector<Vtr::internal::Refinement *> _refinements;
│ │ │ │ -
287
│ │ │ │ -
288 std::vector<TopologyLevel> _farLevels;
│ │ │ │ -
289};
│ │ │ │ -
│ │ │ │ +
285
│ │ │ │ +
286 bool ValidateTopology() const { return _level->validateTopology(); }
│ │ │ │ +
287 void PrintTopology(bool children = true) const { _level->print((children && _refToChild) ? _refToChild : 0); }
│ │ │ │ +
289
│ │ │ │
290
│ │ │ │ -
291
│ │ │ │ -
292inline int
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
294
│ │ │ │ -
295 return _levels[0]->getNumFVarChannels();
│ │ │ │ -
296}
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
299
│ │ │ │ -
300 return _levels[0]->getFVarOptions(channel).GetFVarLinearInterpolation();
│ │ │ │ -
301}
│ │ │ │ -
│ │ │ │ -
302
│ │ │ │ -
303} // end namespace Far
│ │ │ │ -
304
│ │ │ │ -
305} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
306using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
307} // end namespace OpenSubdiv
│ │ │ │ -
308
│ │ │ │ -
309#endif /* OPENSUBDIV3_FAR_TOPOLOGY_REFINER_H */
│ │ │ │ +
291private:
│ │ │ │ +
292 friend class TopologyRefiner;
│ │ │ │ +
293
│ │ │ │ +
294 Vtr::internal::Level const * _level;
│ │ │ │ +
295 Vtr::internal::Refinement const * _refToParent;
│ │ │ │ +
296 Vtr::internal::Refinement const * _refToChild;
│ │ │ │ +
297
│ │ │ │ +
298public:
│ │ │ │ +
299 // Not intended for public use, but required by std::vector, etc...
│ │ │ │ + │ │ │ │ + │ │ │ │ +
302};
│ │ │ │ +
│ │ │ │ +
303
│ │ │ │ +
304} // end namespace Far
│ │ │ │ +
305
│ │ │ │ +
306} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
307using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
308} // end namespace OpenSubdiv
│ │ │ │ +
309
│ │ │ │ +
310#endif /* OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H */
│ │ │ │ │ │ │ │ -
Vtr::ConstIndexArray ConstIndexArray
Definition types.h:47
│ │ │ │ -
SchemeType
Enumerated type for all subdivision schemes supported by OpenSubdiv.
Definition types.h:37
│ │ │ │ -
Applies refinement operations to generic primvar data.
│ │ │ │ -
Object used to compute and query ptex face indices.
Definition ptexIndices.h:46
│ │ │ │ -
An interface for accessing data in a specific level of a refined topology hierarchy.
│ │ │ │ -
Factory for constructing TopologyRefiners from specific mesh classes.
│ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ -
TopologyRefiner(TopologyRefiner const &source)
│ │ │ │ -
int GetMaxValence() const
Returns the maximum vertex valence in all levels.
│ │ │ │ -
Vtr::internal::Level const & getLevel(int l) const
│ │ │ │ -
bool HasHoles() const
Returns true if faces have been tagged as holes.
│ │ │ │ -
int GetNumLevels() const
Returns the number of refinement levels.
│ │ │ │ -
int GetNumFVarValuesTotal(int channel=0) const
Returns the total number of face-varying values in all levels.
│ │ │ │ -
Vtr::internal::Refinement const & getRefinement(int l) const
│ │ │ │ -
Sdc::Options GetSchemeOptions() const
Returns the subdivision options.
│ │ │ │ - │ │ │ │ -
bool IsUniform() const
Returns true if uniform refinement has been applied.
│ │ │ │ -
Sdc::SchemeType GetSchemeType() const
Returns the subdivision scheme.
│ │ │ │ -
int GetMaxLevel() const
Returns the highest level of refinement.
│ │ │ │ -
TopologyRefiner(Sdc::SchemeType type, Sdc::Options options=Sdc::Options())
Constructor.
│ │ │ │ -
int GetNumEdgesTotal() const
Returns the total number of edges in all levels.
│ │ │ │ - │ │ │ │ -
int GetNumFVarChannels() const
Returns the number of face-varying channels in the tables.
│ │ │ │ -
UniformOptions GetUniformOptions() const
Returns the options specified on refinement.
│ │ │ │ -
int GetNumFacesTotal() const
Returns the total number of edges in all levels.
│ │ │ │ -
int GetNumFaceVerticesTotal() const
Returns the total number of face vertices in all levels.
│ │ │ │ -
Vtr::internal::Refinement & getRefinement(int l)
│ │ │ │ -
void RefineUniform(UniformOptions options)
Refine the topology uniformly.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
TopologyLevel const & GetLevel(int level) const
Returns a handle to access data specific to a particular level.
│ │ │ │ -
int GetNumVerticesTotal() const
Returns the total number of vertices in all levels.
│ │ │ │ -
void Unrefine()
Unrefine the topology, keeping only the base level.
│ │ │ │ -
AdaptiveOptions GetAdaptiveOptions() const
Returns the options specified on refinement.
│ │ │ │ -
Sdc::Options::FVarLinearInterpolation GetFVarLinearInterpolation(int channel=0) const
Returns the face-varying interpolation rule set for a given channel.
│ │ │ │ -
void RefineAdaptive(AdaptiveOptions options, ConstIndexArray selectedFaces=ConstIndexArray())
Feature Adaptive topology refinement.
│ │ │ │ - │ │ │ │ -
unsigned int refinementLevel
Number of refinement iterations.
│ │ │ │ - │ │ │ │ -
void SetRefinementLevel(int level)
Set uniform refinement level.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
void SetSecondaryLevel(int level)
Set secondary isolation level.
│ │ │ │ -
Private base class of Factories for constructing TopologyRefiners.
│ │ │ │ -
All supported options applying to subdivision scheme.
Definition options.h:51
│ │ │ │ - │ │ │ │ + │ │ │ │ +
An interface for accessing data in a specific level of a refined topology hierarchy.
│ │ │ │ +
Index GetFaceParentFace(Index f) const
Return the parent face (in the previous level) of a given face.
│ │ │ │ + │ │ │ │ +
bool IsVertexValenceRegular(Index v) const
Return if the valence of the vertex is regular (must be manifold)
│ │ │ │ +
float GetEdgeSharpness(Index e) const
Return the sharpness assigned a given edge.
│ │ │ │ +
bool DoesFaceFVarTopologyMatch(Index f, int channel=0) const
Return if face-varying topology around a face matches.
│ │ │ │ +
Sdc::Crease::Rule GetVertexRule(Index v) const
Return the subdivision rule assigned a given vertex specific to this level.
│ │ │ │ +
bool IsVertexCorner(Index v) const
Return if the vertex is a corner (only one incident face)
│ │ │ │ +
Index GetVertexChildVertex(Index v) const
Return the child vertex (in the next level) of a given vertex.
│ │ │ │ +
ConstLocalIndexArray GetEdgeFaceLocalIndices(Index e) const
Access the local indices of an edge with respect to its incident faces.
│ │ │ │ +
ConstIndexArray GetFaceChildEdges(Index f) const
Access the child edges (in the next level) of a given face.
│ │ │ │ +
bool DoesEdgeFVarTopologyMatch(Index e, int channel=0) const
Return if face-varying topology across the edge only matches.
│ │ │ │ + │ │ │ │ +
ConstIndexArray GetFaceVertices(Index f) const
Access the vertices incident a given face.
│ │ │ │ +
ConstIndexArray GetFaceChildFaces(Index f) const
Access the child faces (in the next level) of a given face.
│ │ │ │ +
int GetNumEdges() const
Return the number of edges in this level.
│ │ │ │ + │ │ │ │ +
bool IsEdgeNonManifold(Index e) const
Return if the edge is non-manifold.
│ │ │ │ +
bool IsFaceHole(Index f) const
Return if a given face has been tagged as a hole.
│ │ │ │ +
ConstIndexArray GetVertexEdges(Index v) const
Access the edges incident a given vertex.
│ │ │ │ +
Index GetFaceChildVertex(Index f) const
Return the child vertex (in the next level) of a given face.
│ │ │ │ +
bool DoesVertexFVarTopologyMatch(Index v, int channel=0) const
Return if face-varying topology around a vertex matches.
│ │ │ │ +
ConstIndexArray GetEdgeChildEdges(Index e) const
Access the child edges (in the next level) of a given edge.
│ │ │ │ +
bool IsEdgeInfSharp(Index e) const
Return if the edge is infinitely-sharp.
│ │ │ │ +
ConstIndexArray GetVertexFaces(Index v) const
Access the faces incident a given vertex.
│ │ │ │ +
Index FindEdge(Index v0, Index v1) const
Identify the edge matching the given vertex pair.
│ │ │ │ +
ConstLocalIndexArray GetVertexEdgeLocalIndices(Index v) const
Access the local indices of a vertex with respect to its incident edges.
│ │ │ │ +
ConstIndexArray GetFaceEdges(Index f) const
Access the edges incident a given face.
│ │ │ │ +
int GetNumFaces() const
Return the number of faces in this level.
│ │ │ │ +
bool IsVertexBoundary(Index v) const
Return if the vertex is on a boundary (at least one incident boundary edge)
│ │ │ │ +
int GetNumFVarChannels() const
Return the number of face-varying channels (should be same for all levels)
│ │ │ │ +
int GetNumVertices() const
Return the number of vertices in this level.
│ │ │ │ +
ConstIndexArray GetEdgeFaces(Index e) const
Access the faces incident a given edge.
│ │ │ │ +
ConstIndexArray GetFaceFVarValues(Index f, int channel=0) const
Access the face-varying values associated with a particular face.
│ │ │ │ +
ConstIndexArray GetEdgeVertices(Index e) const
Access the vertices incident a given edge.
│ │ │ │ +
bool IsEdgeSemiSharp(Index e) const
Return if the edge is semi-sharp.
│ │ │ │ + │ │ │ │ +
float GetVertexSharpness(Index v) const
Return the sharpness assigned a given vertex.
│ │ │ │ +
Index GetEdgeChildVertex(Index e) const
Return the child vertex (in the next level) of a given edge.
│ │ │ │ +
bool IsVertexSemiSharp(Index v) const
Return if the vertex is semi-sharp.
│ │ │ │ +
int GetNumFaceVertices() const
Return the total number of face-vertices, i.e. the sum of all vertices for all faces.
│ │ │ │ +
bool IsVertexNonManifold(Index v) const
Return if the vertex is non-manifold.
│ │ │ │ +
bool IsEdgeBoundary(Index e) const
Return if the edge is a boundary (only one incident face)
│ │ │ │ +
bool IsVertexInfSharp(Index v) const
Return if the vertex is infinitely-sharp.
│ │ │ │ +
int GetNumFVarValues(int channel=0) const
Return the total number of face-varying values in a particular channel (the upper bound of a face-var...
│ │ │ │ +
ConstLocalIndexArray GetVertexFaceLocalIndices(Index v) const
Access the local indices of a vertex with respect to its incident faces.
│ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │ + │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -topologyRefiner.h │ │ │ │ │ +topologyLevel.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2014 DreamWorks Animation LLC. │ │ │ │ │ +2// Copyright 2015 DreamWorks Animation LLC. │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,441 +23,387 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_REFINER_H │ │ │ │ │ -25#define OPENSUBDIV3_FAR_TOPOLOGY_REFINER_H │ │ │ │ │ +24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H │ │ │ │ │ +25#define OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H │ │ │ │ │ 26 │ │ │ │ │ 27#include "../version.h" │ │ │ │ │ 28 │ │ │ │ │ -29#include "../sdc/types.h" │ │ │ │ │ -30#include "../sdc/options.h" │ │ │ │ │ +29#include "../vtr/level.h" │ │ │ │ │ +30#include "../vtr/refinement.h" │ │ │ │ │ 31#include "../far/types.h" │ │ │ │ │ -32#include "../far/topologyLevel.h" │ │ │ │ │ -33 │ │ │ │ │ -34#include │ │ │ │ │ -35 │ │ │ │ │ -36 │ │ │ │ │ -37namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -38namespace OPENSUBDIV_VERSION { │ │ │ │ │ +32 │ │ │ │ │ +33#include │ │ │ │ │ +34 │ │ │ │ │ +35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +36namespace OPENSUBDIV_VERSION { │ │ │ │ │ +37 │ │ │ │ │ +38namespace Far { │ │ │ │ │ 39 │ │ │ │ │ -_4_0namespace Vtr { namespace internal { class SparseSelector; } } │ │ │ │ │ -41namespace Far { namespace internal { class FeatureMask; } } │ │ │ │ │ -42 │ │ │ │ │ -43namespace Far { │ │ │ │ │ -44 │ │ │ │ │ -45template class PrimvarRefinerReal; │ │ │ │ │ -46template class TopologyRefinerFactory; │ │ │ │ │ -47 │ │ │ │ │ -_5_1class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r { │ │ │ │ │ -52 │ │ │ │ │ -53public: │ │ │ │ │ -54 │ │ │ │ │ -_5_6 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r(_S_d_c_:_:_S_c_h_e_m_e_T_y_p_e type, _S_d_c_:_:_O_p_t_i_o_n_s options = _S_d_c_:_:_O_p_t_i_o_n_s │ │ │ │ │ -()); │ │ │ │ │ -57 │ │ │ │ │ -_5_9 _~_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r(); │ │ │ │ │ +_4_9class _T_o_p_o_l_o_g_y_L_e_v_e_l { │ │ │ │ │ +50 │ │ │ │ │ +51public: │ │ │ │ │ +53 │ │ │ │ │ 60 │ │ │ │ │ -_6_2 _S_d_c_:_:_S_c_h_e_m_e_T_y_p_e _G_e_t_S_c_h_e_m_e_T_y_p_e() const { return _subdivType; } │ │ │ │ │ +_6_2 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s() const { return _level->getNumVertices(); } │ │ │ │ │ 63 │ │ │ │ │ -_6_5 _S_d_c_:_:_O_p_t_i_o_n_s _G_e_t_S_c_h_e_m_e_O_p_t_i_o_n_s() const { return _subdivOptions; } │ │ │ │ │ +_6_5 int _G_e_t_N_u_m_F_a_c_e_s() const { return _level->getNumFaces(); } │ │ │ │ │ 66 │ │ │ │ │ -_6_8 bool _I_s_U_n_i_f_o_r_m() const { return _isUniform; } │ │ │ │ │ +_6_8 int _G_e_t_N_u_m_E_d_g_e_s() const { return _level->getNumEdges(); } │ │ │ │ │ 69 │ │ │ │ │ -_7_1 int _G_e_t_N_u_m_L_e_v_e_l_s() const { return (int)_farLevels.size(); } │ │ │ │ │ -72 │ │ │ │ │ -_7_4 int _G_e_t_M_a_x_L_e_v_e_l() const { return _maxLevel; } │ │ │ │ │ +_7_1 int _G_e_t_N_u_m_F_a_c_e_V_e_r_t_i_c_e_s() const { return _level->getNumFaceVerticesTotal(); } │ │ │ │ │ +73 │ │ │ │ │ 75 │ │ │ │ │ -_7_7 int _G_e_t_M_a_x_V_a_l_e_n_c_e() const { return _maxValence; } │ │ │ │ │ -78 │ │ │ │ │ -_8_0 bool _H_a_s_H_o_l_e_s() const { return _hasHoles; } │ │ │ │ │ -81 │ │ │ │ │ -_8_3 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s_T_o_t_a_l() const { return _totalVertices; } │ │ │ │ │ -84 │ │ │ │ │ -_8_6 int _G_e_t_N_u_m_E_d_g_e_s_T_o_t_a_l() const { return _totalEdges; } │ │ │ │ │ -87 │ │ │ │ │ -_8_9 int _G_e_t_N_u_m_F_a_c_e_s_T_o_t_a_l() const { return _totalFaces; } │ │ │ │ │ -90 │ │ │ │ │ -_9_2 int _G_e_t_N_u_m_F_a_c_e_V_e_r_t_i_c_e_s_T_o_t_a_l() const { return _totalFaceVertices; } │ │ │ │ │ -93 │ │ │ │ │ -_9_5 _T_o_p_o_l_o_g_y_L_e_v_e_l const & _G_e_t_L_e_v_e_l(int level) const { return _farLevels[level]; │ │ │ │ │ -} │ │ │ │ │ -96 │ │ │ │ │ -98 │ │ │ │ │ +90 // │ │ │ │ │ +91 │ │ │ │ │ +_9_3 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_V_e_r_t_i_c_e_s(_I_n_d_e_x f) const { return _level- │ │ │ │ │ +>getFaceVertices(f); } │ │ │ │ │ +94 │ │ │ │ │ +_9_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_E_d_g_e_s(_I_n_d_e_x f) const { return _level->getFaceEdges │ │ │ │ │ +(f); } │ │ │ │ │ +97 │ │ │ │ │ +_9_9 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_V_e_r_t_i_c_e_s(_I_n_d_e_x e) const { return _level- │ │ │ │ │ +>getEdgeVertices(e); } │ │ │ │ │ 100 │ │ │ │ │ -101 // │ │ │ │ │ -102 // Uniform refinement │ │ │ │ │ -103 // │ │ │ │ │ -104 │ │ │ │ │ -_1_1_8 struct _U_n_i_f_o_r_m_O_p_t_i_o_n_s { │ │ │ │ │ -119 │ │ │ │ │ -_1_2_0 _U_n_i_f_o_r_m_O_p_t_i_o_n_s(int level) : │ │ │ │ │ -121 _r_e_f_i_n_e_m_e_n_t_L_e_v_e_l(level & 0xf), │ │ │ │ │ -122 _o_r_d_e_r_V_e_r_t_i_c_e_s_F_r_o_m_F_a_c_e_s_F_i_r_s_t(false), │ │ │ │ │ -123 _f_u_l_l_T_o_p_o_l_o_g_y_I_n_L_a_s_t_L_e_v_e_l(false) { } │ │ │ │ │ +_1_0_2 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_F_a_c_e_s(_I_n_d_e_x e) const { return _level->getEdgeFaces │ │ │ │ │ +(e); } │ │ │ │ │ +103 │ │ │ │ │ +_1_0_5 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_F_a_c_e_s(_I_n_d_e_x v) const { return _level- │ │ │ │ │ +>getVertexFaces(v); } │ │ │ │ │ +106 │ │ │ │ │ +_1_0_8 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_E_d_g_e_s(_I_n_d_e_x v) const { return _level- │ │ │ │ │ +>getVertexEdges(v); } │ │ │ │ │ +109 │ │ │ │ │ +_1_1_1 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_I_n_d_e_x v) const { return │ │ │ │ │ +_level->getVertexFaceLocalIndices(v); } │ │ │ │ │ +112 │ │ │ │ │ +_1_1_4 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s(_I_n_d_e_x v) const { return │ │ │ │ │ +_level->getVertexEdgeLocalIndices(v); } │ │ │ │ │ +115 │ │ │ │ │ +_1_1_7 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_I_n_d_e_x e) const { return │ │ │ │ │ +_level->getEdgeFaceLocalIndices(e); } │ │ │ │ │ +118 │ │ │ │ │ +_1_2_0 _I_n_d_e_x _F_i_n_d_E_d_g_e(_I_n_d_e_x v0, _I_n_d_e_x v1) const { return _level->findEdge(v0, v1); │ │ │ │ │ +} │ │ │ │ │ +122 │ │ │ │ │ 124 │ │ │ │ │ -_1_2_6 void _S_e_t_R_e_f_i_n_e_m_e_n_t_L_e_v_e_l(int level) { _r_e_f_i_n_e_m_e_n_t_L_e_v_e_l = level & 0xf; } │ │ │ │ │ -127 │ │ │ │ │ -_1_2_8 unsigned int _r_e_f_i_n_e_m_e_n_t_L_e_v_e_l:4, │ │ │ │ │ -_1_2_9 _o_r_d_e_r_V_e_r_t_i_c_e_s_F_r_o_m_F_a_c_e_s_F_i_r_s_t:1, │ │ │ │ │ -_1_3_1 _f_u_l_l_T_o_p_o_l_o_g_y_I_n_L_a_s_t_L_e_v_e_l:1; │ │ │ │ │ -134 }; │ │ │ │ │ +126 │ │ │ │ │ +_1_2_8 bool _I_s_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d(_I_n_d_e_x e) const { return _level->isEdgeNonManifold │ │ │ │ │ +(e); } │ │ │ │ │ +129 │ │ │ │ │ +_1_3_1 bool _I_s_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d(_I_n_d_e_x v) const { return _level- │ │ │ │ │ +>isVertexNonManifold(v); } │ │ │ │ │ +132 │ │ │ │ │ +_1_3_4 bool _I_s_E_d_g_e_B_o_u_n_d_a_r_y(_I_n_d_e_x e) const { return _level->getEdgeTag │ │ │ │ │ +(e)._boundary; } │ │ │ │ │ 135 │ │ │ │ │ -_1_4_6 void _R_e_f_i_n_e_U_n_i_f_o_r_m(_U_n_i_f_o_r_m_O_p_t_i_o_n_s options); │ │ │ │ │ -147 │ │ │ │ │ -_1_4_9 _U_n_i_f_o_r_m_O_p_t_i_o_n_s _G_e_t_U_n_i_f_o_r_m_O_p_t_i_o_n_s() const { return _uniformOptions; } │ │ │ │ │ -150 │ │ │ │ │ -151 // │ │ │ │ │ -152 // Adaptive refinement │ │ │ │ │ -153 // │ │ │ │ │ -154 │ │ │ │ │ -_1_5_6 struct _A_d_a_p_t_i_v_e_O_p_t_i_o_n_s { │ │ │ │ │ -157 │ │ │ │ │ -_1_5_8 _A_d_a_p_t_i_v_e_O_p_t_i_o_n_s(int level) : │ │ │ │ │ -159 _i_s_o_l_a_t_i_o_n_L_e_v_e_l(level & 0xf), │ │ │ │ │ -160 _s_e_c_o_n_d_a_r_y_L_e_v_e_l(0xf), │ │ │ │ │ -161 _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h(false), │ │ │ │ │ -162 _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h(false), │ │ │ │ │ -163 _c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s(false), │ │ │ │ │ -164 _o_r_d_e_r_V_e_r_t_i_c_e_s_F_r_o_m_F_a_c_e_s_F_i_r_s_t(false) { } │ │ │ │ │ -165 │ │ │ │ │ -_1_6_7 void _S_e_t_I_s_o_l_a_t_i_o_n_L_e_v_e_l(int level) { _i_s_o_l_a_t_i_o_n_L_e_v_e_l = level & 0xf; } │ │ │ │ │ -168 │ │ │ │ │ -_1_7_0 void _S_e_t_S_e_c_o_n_d_a_r_y_L_e_v_e_l(int level) { _s_e_c_o_n_d_a_r_y_L_e_v_e_l = level & 0xf; } │ │ │ │ │ +_1_3_7 bool _I_s_V_e_r_t_e_x_B_o_u_n_d_a_r_y(_I_n_d_e_x v) const { return _level->getVertexTag │ │ │ │ │ +(v)._boundary; } │ │ │ │ │ +138 │ │ │ │ │ +_1_4_0 bool _I_s_V_e_r_t_e_x_C_o_r_n_e_r(_I_n_d_e_x v) const { return (_level->getNumVertexFaces(v) │ │ │ │ │ +== 1); } │ │ │ │ │ +141 │ │ │ │ │ +_1_6_2 bool _I_s_V_e_r_t_e_x_V_a_l_e_n_c_e_R_e_g_u_l_a_r(_I_n_d_e_x v) const { return !_level->getVertexTag │ │ │ │ │ +(v)._xordinary || _I_s_V_e_r_t_e_x_C_o_r_n_e_r(v); } │ │ │ │ │ +164 │ │ │ │ │ +166 │ │ │ │ │ 171 │ │ │ │ │ -_1_7_2 unsigned int _i_s_o_l_a_t_i_o_n_L_e_v_e_l:4; │ │ │ │ │ -_1_7_4 unsigned int _s_e_c_o_n_d_a_r_y_L_e_v_e_l:4; │ │ │ │ │ -_1_7_6 unsigned int _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h:1; │ │ │ │ │ -_1_7_8 unsigned int _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h:1; │ │ │ │ │ -_1_8_0 unsigned int _c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s:1; │ │ │ │ │ -_1_8_2 unsigned int _o_r_d_e_r_V_e_r_t_i_c_e_s_F_r_o_m_F_a_c_e_s_F_i_r_s_t:1; │ │ │ │ │ -184 }; │ │ │ │ │ -185 │ │ │ │ │ -_1_9_2 void _R_e_f_i_n_e_A_d_a_p_t_i_v_e(_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s options, │ │ │ │ │ -193 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y selectedFaces = _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y()); │ │ │ │ │ -194 │ │ │ │ │ -_1_9_6 _A_d_a_p_t_i_v_e_O_p_t_i_o_n_s _G_e_t_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s() const { return _adaptiveOptions; } │ │ │ │ │ -197 │ │ │ │ │ -_1_9_9 void _U_n_r_e_f_i_n_e(); │ │ │ │ │ -200 │ │ │ │ │ -201 │ │ │ │ │ -203 │ │ │ │ │ -205 │ │ │ │ │ -207 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const; │ │ │ │ │ -208 │ │ │ │ │ -210 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n _G_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n(int │ │ │ │ │ -channel = 0) const; │ │ │ │ │ -211 │ │ │ │ │ -_2_1_3 int _G_e_t_N_u_m_F_V_a_r_V_a_l_u_e_s_T_o_t_a_l(int channel = 0) const; │ │ │ │ │ -214 │ │ │ │ │ -216 │ │ │ │ │ -217protected: │ │ │ │ │ -218 │ │ │ │ │ -219 // │ │ │ │ │ -220 // Lower level protected methods intended strictly for internal use: │ │ │ │ │ -221 // │ │ │ │ │ -222 template │ │ │ │ │ -_2_2_3 friend class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y; │ │ │ │ │ -_2_2_4 friend class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e; │ │ │ │ │ -_2_2_5 friend class _P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r; │ │ │ │ │ -_2_2_6 friend class _P_a_t_c_h_B_u_i_l_d_e_r; │ │ │ │ │ -_2_2_7 friend class _P_t_e_x_I_n_d_i_c_e_s; │ │ │ │ │ -228 template │ │ │ │ │ -_2_2_9 friend class _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l; │ │ │ │ │ -230 │ │ │ │ │ -231 // Copy constructor exposed via the factory class: │ │ │ │ │ -_2_3_2 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & source); │ │ │ │ │ -233 │ │ │ │ │ -234public: │ │ │ │ │ -235 // Levels and Refinements available internally (avoids need for more │ │ │ │ │ -friends) │ │ │ │ │ -_2_3_6 Vtr::internal::Level & _g_e_t_L_e_v_e_l(int l) { return *_levels[l]; } │ │ │ │ │ -_2_3_7 Vtr::internal::Level const & _g_e_t_L_e_v_e_l(int l) const { return *_levels[l]; } │ │ │ │ │ -238 │ │ │ │ │ -_2_3_9 Vtr::internal::Refinement & _g_e_t_R_e_f_i_n_e_m_e_n_t(int l) { return *_refinements[l]; │ │ │ │ │ +_1_7_3 float _G_e_t_E_d_g_e_S_h_a_r_p_n_e_s_s(_I_n_d_e_x e) const { return _level->getEdgeSharpness(e); │ │ │ │ │ } │ │ │ │ │ -_2_4_0 Vtr::internal::Refinement const & _g_e_t_R_e_f_i_n_e_m_e_n_t(int l) const { return │ │ │ │ │ -*_refinements[l]; } │ │ │ │ │ -241 │ │ │ │ │ -242private: │ │ │ │ │ -243 // Not default constructible or copyable: │ │ │ │ │ -244 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r() : _uniformOptions(0), _adaptiveOptions(0) { } │ │ │ │ │ -245 TopologyRefiner & operator=(TopologyRefiner const &) { return *this; } │ │ │ │ │ -246 │ │ │ │ │ -247 void selectFeatureAdaptiveComponents(Vtr::internal::SparseSelector& │ │ │ │ │ -selector, │ │ │ │ │ -248 internal::FeatureMask const & mask, │ │ │ │ │ -249 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y selectedFaces); │ │ │ │ │ -250 void selectLinearIrregularFaces(Vtr::internal::SparseSelector& selector, │ │ │ │ │ -251 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y selectedFaces); │ │ │ │ │ -252 │ │ │ │ │ -253 void initializeInventory(); │ │ │ │ │ -254 void updateInventory(Vtr::internal::Level const & newLevel); │ │ │ │ │ +174 │ │ │ │ │ +_1_7_6 float _G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(_I_n_d_e_x v) const { return _level->getVertexSharpness │ │ │ │ │ +(v); } │ │ │ │ │ +177 │ │ │ │ │ +_1_7_9 bool _I_s_E_d_g_e_I_n_f_S_h_a_r_p(_I_n_d_e_x e) const { return _level->getEdgeTag │ │ │ │ │ +(e)._infSharp; } │ │ │ │ │ +180 │ │ │ │ │ +_1_8_2 bool _I_s_V_e_r_t_e_x_I_n_f_S_h_a_r_p(_I_n_d_e_x v) const { return _level->getVertexTag │ │ │ │ │ +(v)._infSharp; } │ │ │ │ │ +183 │ │ │ │ │ +_1_8_5 bool _I_s_E_d_g_e_S_e_m_i_S_h_a_r_p(_I_n_d_e_x e) const { return _level->getEdgeTag │ │ │ │ │ +(e)._semiSharp; } │ │ │ │ │ +186 │ │ │ │ │ +_1_8_8 bool _I_s_V_e_r_t_e_x_S_e_m_i_S_h_a_r_p(_I_n_d_e_x v) const { return _level->getVertexTag │ │ │ │ │ +(v)._semiSharp; } │ │ │ │ │ +189 │ │ │ │ │ +_1_9_1 bool _I_s_F_a_c_e_H_o_l_e(_I_n_d_e_x f) const { return _level->isFaceHole(f); } │ │ │ │ │ +192 │ │ │ │ │ +_1_9_4 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e _G_e_t_V_e_r_t_e_x_R_u_l_e(_I_n_d_e_x v) const { return _level- │ │ │ │ │ +>getVertexRule(v); } │ │ │ │ │ +196 │ │ │ │ │ +198 │ │ │ │ │ +228 │ │ │ │ │ +_2_3_0 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const { return _level->getNumFVarChannels(); } │ │ │ │ │ +231 │ │ │ │ │ +_2_3_4 int _G_e_t_N_u_m_F_V_a_r_V_a_l_u_e_s(int channel = 0) const { return _level- │ │ │ │ │ +>getNumFVarValues(channel); } │ │ │ │ │ +235 │ │ │ │ │ +_2_3_7 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_F_V_a_r_V_a_l_u_e_s(_I_n_d_e_x f, int channel = 0) const { │ │ │ │ │ +238 return _level->getFaceFVarValues(f, channel); │ │ │ │ │ +239 } │ │ │ │ │ +240 │ │ │ │ │ +_2_4_2 bool _D_o_e_s_V_e_r_t_e_x_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h(_I_n_d_e_x v, int channel = 0) const { │ │ │ │ │ +243 return _level->doesVertexFVarTopologyMatch(v, channel); │ │ │ │ │ +244 } │ │ │ │ │ +245 │ │ │ │ │ +_2_4_7 bool _D_o_e_s_E_d_g_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h(_I_n_d_e_x e, int channel = 0) const { │ │ │ │ │ +248 return _level->doesEdgeFVarTopologyMatch(e, channel); │ │ │ │ │ +249 } │ │ │ │ │ +250 │ │ │ │ │ +_2_5_2 bool _D_o_e_s_F_a_c_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h(_I_n_d_e_x f, int channel = 0) const { │ │ │ │ │ +253 return _level->doesFaceFVarTopologyMatch(f, channel); │ │ │ │ │ +254 } │ │ │ │ │ 255 │ │ │ │ │ -256 void appendLevel(Vtr::internal::Level & newLevel); │ │ │ │ │ -257 void appendRefinement(Vtr::internal::Refinement & newRefinement); │ │ │ │ │ -258 void assembleFarLevels(); │ │ │ │ │ +257 │ │ │ │ │ 259 │ │ │ │ │ -260private: │ │ │ │ │ -261 │ │ │ │ │ -262 _S_d_c_:_:_S_c_h_e_m_e_T_y_p_e _subdivType; │ │ │ │ │ -263 _S_d_c_:_:_O_p_t_i_o_n_s _subdivOptions; │ │ │ │ │ -264 │ │ │ │ │ -265 unsigned int _isUniform : 1; │ │ │ │ │ -266 unsigned int _hasHoles : 1; │ │ │ │ │ -267 unsigned int _hasIrregFaces : 1; │ │ │ │ │ -268 unsigned int _regFaceSize : 3; │ │ │ │ │ -269 unsigned int _maxLevel : 4; │ │ │ │ │ -270 │ │ │ │ │ -271 // Options assigned on refinement: │ │ │ │ │ -272 UniformOptions _uniformOptions; │ │ │ │ │ -273 AdaptiveOptions _adaptiveOptions; │ │ │ │ │ -274 │ │ │ │ │ -275 // Cumulative properties of all levels: │ │ │ │ │ -276 int _totalVertices; │ │ │ │ │ -277 int _totalEdges; │ │ │ │ │ -278 int _totalFaces; │ │ │ │ │ -279 int _totalFaceVertices; │ │ │ │ │ -280 int _maxValence; │ │ │ │ │ -281 │ │ │ │ │ -282 // Note the base level may be shared with another instance │ │ │ │ │ -283 bool _baseLevelOwned; │ │ │ │ │ +260 │ │ │ │ │ +_2_6_2 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_C_h_i_l_d_F_a_c_e_s(_I_n_d_e_x f) const { return _refToChild- │ │ │ │ │ +>getFaceChildFaces(f); } │ │ │ │ │ +263 │ │ │ │ │ +_2_6_5 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_C_h_i_l_d_E_d_g_e_s(_I_n_d_e_x f) const { return _refToChild- │ │ │ │ │ +>getFaceChildEdges(f); } │ │ │ │ │ +266 │ │ │ │ │ +_2_6_8 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_C_h_i_l_d_E_d_g_e_s(_I_n_d_e_x e) const { return _refToChild- │ │ │ │ │ +>getEdgeChildEdges(e); } │ │ │ │ │ +269 │ │ │ │ │ +_2_7_1 _I_n_d_e_x _G_e_t_F_a_c_e_C_h_i_l_d_V_e_r_t_e_x( _I_n_d_e_x f) const { return _refToChild- │ │ │ │ │ +>getFaceChildVertex(f); } │ │ │ │ │ +272 │ │ │ │ │ +_2_7_4 _I_n_d_e_x _G_e_t_E_d_g_e_C_h_i_l_d_V_e_r_t_e_x( _I_n_d_e_x e) const { return _refToChild- │ │ │ │ │ +>getEdgeChildVertex(e); } │ │ │ │ │ +275 │ │ │ │ │ +_2_7_7 _I_n_d_e_x _G_e_t_V_e_r_t_e_x_C_h_i_l_d_V_e_r_t_e_x(_I_n_d_e_x v) const { return _refToChild- │ │ │ │ │ +>getVertexChildVertex(v); } │ │ │ │ │ +278 │ │ │ │ │ +_2_8_0 _I_n_d_e_x _G_e_t_F_a_c_e_P_a_r_e_n_t_F_a_c_e(_I_n_d_e_x f) const { return _refToParent- │ │ │ │ │ +>getChildFaceParentFace(f); } │ │ │ │ │ +282 │ │ │ │ │ 284 │ │ │ │ │ -285 std::vector _levels; │ │ │ │ │ -286 std::vector _refinements; │ │ │ │ │ -287 │ │ │ │ │ -288 std::vector _farLevels; │ │ │ │ │ -289}; │ │ │ │ │ +285 │ │ │ │ │ +_2_8_6 bool _V_a_l_i_d_a_t_e_T_o_p_o_l_o_g_y() const { return _level->validateTopology(); } │ │ │ │ │ +_2_8_7 void _P_r_i_n_t_T_o_p_o_l_o_g_y(bool children = true) const { _level->print((children && │ │ │ │ │ +_refToChild) ? _refToChild : 0); } │ │ │ │ │ +289 │ │ │ │ │ 290 │ │ │ │ │ -291 │ │ │ │ │ -292inline int │ │ │ │ │ -_2_9_3_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const { │ │ │ │ │ -294 │ │ │ │ │ -295 return _levels[0]->getNumFVarChannels(); │ │ │ │ │ -296} │ │ │ │ │ -297inline _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ -_2_9_8_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n(int channel) const { │ │ │ │ │ -299 │ │ │ │ │ -300 return _levels[0]->getFVarOptions(channel).GetFVarLinearInterpolation(); │ │ │ │ │ -301} │ │ │ │ │ -302 │ │ │ │ │ -303} // end namespace Far │ │ │ │ │ -304 │ │ │ │ │ -305} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -306using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -307} // end namespace OpenSubdiv │ │ │ │ │ -308 │ │ │ │ │ -309#endif /* OPENSUBDIV3_FAR_TOPOLOGY_REFINER_H */ │ │ │ │ │ +291private: │ │ │ │ │ +_2_9_2 friend class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r; │ │ │ │ │ +293 │ │ │ │ │ +294 Vtr::internal::Level const * _level; │ │ │ │ │ +295 Vtr::internal::Refinement const * _refToParent; │ │ │ │ │ +296 Vtr::internal::Refinement const * _refToChild; │ │ │ │ │ +297 │ │ │ │ │ +298public: │ │ │ │ │ +299 // Not intended for public use, but required by std::vector, etc... │ │ │ │ │ +_3_0_0 _T_o_p_o_l_o_g_y_L_e_v_e_l() { } │ │ │ │ │ +_3_0_1 _~_T_o_p_o_l_o_g_y_L_e_v_e_l() { } │ │ │ │ │ +302}; │ │ │ │ │ +303 │ │ │ │ │ +304} // end namespace Far │ │ │ │ │ +305 │ │ │ │ │ +306} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +307using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +308} // end namespace OpenSubdiv │ │ │ │ │ +309 │ │ │ │ │ +310#endif /* OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ -Vtr::ConstIndexArray ConstIndexArray │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_T_y_p_e │ │ │ │ │ -SchemeType │ │ │ │ │ -Enumerated type for all subdivision schemes supported by OpenSubdiv. │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ -Applies refinement operations to generic primvar data. │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -Object used to compute and query ptex face indices. │ │ │ │ │ -DDeeffiinniittiioonn _p_t_e_x_I_n_d_i_c_e_s_._h_:_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ +Vtr::Index Index │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ An interface for accessing data in a specific level of a refined topology │ │ │ │ │ hierarchy. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y │ │ │ │ │ -Factory for constructing TopologyRefiners from specific mesh classes. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_P_a_r_e_n_t_F_a_c_e │ │ │ │ │ +Index GetFaceParentFace(Index f) const │ │ │ │ │ +Return the parent face (in the previous level) of a given face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_8_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ +TopologyLevel() │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_3_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_V_a_l_e_n_c_e_R_e_g_u_l_a_r │ │ │ │ │ +bool IsVertexValenceRegular(Index v) const │ │ │ │ │ +Return if the valence of the vertex is regular (must be manifold) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float GetEdgeSharpness(Index e) const │ │ │ │ │ +Return the sharpness assigned a given edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_D_o_e_s_F_a_c_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h │ │ │ │ │ +bool DoesFaceFVarTopologyMatch(Index f, int channel=0) const │ │ │ │ │ +Return if face-varying topology around a face matches. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_R_u_l_e │ │ │ │ │ +Sdc::Crease::Rule GetVertexRule(Index v) const │ │ │ │ │ +Return the subdivision rule assigned a given vertex specific to this level. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_C_o_r_n_e_r │ │ │ │ │ +bool IsVertexCorner(Index v) const │ │ │ │ │ +Return if the vertex is a corner (only one incident face) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_C_h_i_l_d_V_e_r_t_e_x │ │ │ │ │ +Index GetVertexChildVertex(Index v) const │ │ │ │ │ +Return the child vertex (in the next level) of a given vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +ConstLocalIndexArray GetEdgeFaceLocalIndices(Index e) const │ │ │ │ │ +Access the local indices of an edge with respect to its incident faces. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_1_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_C_h_i_l_d_E_d_g_e_s │ │ │ │ │ +ConstIndexArray GetFaceChildEdges(Index f) const │ │ │ │ │ +Access the child edges (in the next level) of a given face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_D_o_e_s_E_d_g_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h │ │ │ │ │ +bool DoesEdgeFVarTopologyMatch(Index e, int channel=0) const │ │ │ │ │ +Return if face-varying topology across the edge only matches. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_4_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_P_r_i_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ +void PrintTopology(bool children=true) const │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetFaceVertices(Index f) const │ │ │ │ │ +Access the vertices incident a given face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_C_h_i_l_d_F_a_c_e_s │ │ │ │ │ +ConstIndexArray GetFaceChildFaces(Index f) const │ │ │ │ │ +Access the child faces (in the next level) of a given face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_E_d_g_e_s │ │ │ │ │ +int GetNumEdges() const │ │ │ │ │ +Return the number of edges in this level. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_V_a_l_i_d_a_t_e_T_o_p_o_l_o_g_y │ │ │ │ │ +bool ValidateTopology() const │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d │ │ │ │ │ +bool IsEdgeNonManifold(Index e) const │ │ │ │ │ +Return if the edge is non-manifold. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_2_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_F_a_c_e_H_o_l_e │ │ │ │ │ +bool IsFaceHole(Index f) const │ │ │ │ │ +Return if a given face has been tagged as a hole. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_E_d_g_e_s │ │ │ │ │ +ConstIndexArray GetVertexEdges(Index v) const │ │ │ │ │ +Access the edges incident a given vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_0_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_C_h_i_l_d_V_e_r_t_e_x │ │ │ │ │ +Index GetFaceChildVertex(Index f) const │ │ │ │ │ +Return the child vertex (in the next level) of a given face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_D_o_e_s_V_e_r_t_e_x_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h │ │ │ │ │ +bool DoesVertexFVarTopologyMatch(Index v, int channel=0) const │ │ │ │ │ +Return if face-varying topology around a vertex matches. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_4_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_C_h_i_l_d_E_d_g_e_s │ │ │ │ │ +ConstIndexArray GetEdgeChildEdges(Index e) const │ │ │ │ │ +Access the child edges (in the next level) of a given edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_I_n_f_S_h_a_r_p │ │ │ │ │ +bool IsEdgeInfSharp(Index e) const │ │ │ │ │ +Return if the edge is infinitely-sharp. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_F_a_c_e_s │ │ │ │ │ +ConstIndexArray GetVertexFaces(Index v) const │ │ │ │ │ +Access the faces incident a given vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_0_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_F_i_n_d_E_d_g_e │ │ │ │ │ +Index FindEdge(Index v0, Index v1) const │ │ │ │ │ +Identify the edge matching the given vertex pair. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_2_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +ConstLocalIndexArray GetVertexEdgeLocalIndices(Index v) const │ │ │ │ │ +Access the local indices of a vertex with respect to its incident edges. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_1_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_E_d_g_e_s │ │ │ │ │ +ConstIndexArray GetFaceEdges(Index f) const │ │ │ │ │ +Access the edges incident a given face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_9_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_a_c_e_s │ │ │ │ │ +int GetNumFaces() const │ │ │ │ │ +Return the number of faces in this level. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_B_o_u_n_d_a_r_y │ │ │ │ │ +bool IsVertexBoundary(Index v) const │ │ │ │ │ +Return if the vertex is on a boundary (at least one incident boundary edge) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +int GetNumFVarChannels() const │ │ │ │ │ +Return the number of face-varying channels (should be same for all levels) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_3_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ +int GetNumVertices() const │ │ │ │ │ +Return the number of vertices in this level. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_F_a_c_e_s │ │ │ │ │ +ConstIndexArray GetEdgeFaces(Index e) const │ │ │ │ │ +Access the faces incident a given edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_0_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +ConstIndexArray GetFaceFVarValues(Index f, int channel=0) const │ │ │ │ │ +Access the face-varying values associated with a particular face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetEdgeVertices(Index e) const │ │ │ │ │ +Access the vertices incident a given edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_9_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_S_e_m_i_S_h_a_r_p │ │ │ │ │ +bool IsEdgeSemiSharp(Index e) const │ │ │ │ │ +Return if the edge is semi-sharp. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_~_T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ +~TopologyLevel() │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_3_0_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float GetVertexSharpness(Index v) const │ │ │ │ │ +Return the sharpness assigned a given vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_C_h_i_l_d_V_e_r_t_e_x │ │ │ │ │ +Index GetEdgeChildVertex(Index e) const │ │ │ │ │ +Return the child vertex (in the next level) of a given edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_S_e_m_i_S_h_a_r_p │ │ │ │ │ +bool IsVertexSemiSharp(Index v) const │ │ │ │ │ +Return if the vertex is semi-sharp. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_a_c_e_V_e_r_t_i_c_e_s │ │ │ │ │ +int GetNumFaceVertices() const │ │ │ │ │ +Return the total number of face-vertices, i.e. the sum of all vertices for all │ │ │ │ │ +faces. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d │ │ │ │ │ +bool IsVertexNonManifold(Index v) const │ │ │ │ │ +Return if the vertex is non-manifold. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_B_o_u_n_d_a_r_y │ │ │ │ │ +bool IsEdgeBoundary(Index e) const │ │ │ │ │ +Return if the edge is a boundary (only one incident face) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_I_n_f_S_h_a_r_p │ │ │ │ │ +bool IsVertexInfSharp(Index v) const │ │ │ │ │ +Return if the vertex is infinitely-sharp. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +int GetNumFVarValues(int channel=0) const │ │ │ │ │ +Return the total number of face-varying values in a particular channel (the │ │ │ │ │ +upper bound of a face-var... │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +ConstLocalIndexArray GetVertexFaceLocalIndices(Index v) const │ │ │ │ │ +Access the local indices of a vertex with respect to its incident faces. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_1_1 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ Stores topology data for a specified set of refinement options. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ -TopologyRefiner(TopologyRefiner const &source) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_M_a_x_V_a_l_e_n_c_e │ │ │ │ │ -int GetMaxValence() const │ │ │ │ │ -Returns the maximum vertex valence in all levels. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_g_e_t_L_e_v_e_l │ │ │ │ │ -Vtr::internal::Level const & getLevel(int l) const │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_H_a_s_H_o_l_e_s │ │ │ │ │ -bool HasHoles() const │ │ │ │ │ -Returns true if faces have been tagged as holes. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_L_e_v_e_l_s │ │ │ │ │ -int GetNumLevels() const │ │ │ │ │ -Returns the number of refinement levels. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_F_V_a_r_V_a_l_u_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumFVarValuesTotal(int channel=0) const │ │ │ │ │ -Returns the total number of face-varying values in all levels. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_g_e_t_R_e_f_i_n_e_m_e_n_t │ │ │ │ │ -Vtr::internal::Refinement const & getRefinement(int l) const │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_S_c_h_e_m_e_O_p_t_i_o_n_s │ │ │ │ │ -Sdc::Options GetSchemeOptions() const │ │ │ │ │ -Returns the subdivision options. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_g_e_t_L_e_v_e_l │ │ │ │ │ -Vtr::internal::Level & getLevel(int l) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_3_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_I_s_U_n_i_f_o_r_m │ │ │ │ │ -bool IsUniform() const │ │ │ │ │ -Returns true if uniform refinement has been applied. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_S_c_h_e_m_e_T_y_p_e │ │ │ │ │ -Sdc::SchemeType GetSchemeType() const │ │ │ │ │ -Returns the subdivision scheme. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_M_a_x_L_e_v_e_l │ │ │ │ │ -int GetMaxLevel() const │ │ │ │ │ -Returns the highest level of refinement. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ -TopologyRefiner(Sdc::SchemeType type, Sdc::Options options=Sdc::Options()) │ │ │ │ │ -Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_E_d_g_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumEdgesTotal() const │ │ │ │ │ -Returns the total number of edges in all levels. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_P_a_t_c_h_B_u_i_l_d_e_r │ │ │ │ │ -friend class PatchBuilder │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -int GetNumFVarChannels() const │ │ │ │ │ -Returns the number of face-varying channels in the tables. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_U_n_i_f_o_r_m_O_p_t_i_o_n_s │ │ │ │ │ -UniformOptions GetUniformOptions() const │ │ │ │ │ -Returns the options specified on refinement. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_F_a_c_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumFacesTotal() const │ │ │ │ │ -Returns the total number of edges in all levels. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_8_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_F_a_c_e_V_e_r_t_i_c_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumFaceVerticesTotal() const │ │ │ │ │ -Returns the total number of face vertices in all levels. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_g_e_t_R_e_f_i_n_e_m_e_n_t │ │ │ │ │ -Vtr::internal::Refinement & getRefinement(int l) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_R_e_f_i_n_e_U_n_i_f_o_r_m │ │ │ │ │ -void RefineUniform(UniformOptions options) │ │ │ │ │ -Refine the topology uniformly. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_~_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ -~TopologyRefiner() │ │ │ │ │ -Destructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r │ │ │ │ │ -friend class PatchTableBuilder │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_2_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_L_e_v_e_l │ │ │ │ │ -TopologyLevel const & GetLevel(int level) const │ │ │ │ │ -Returns a handle to access data specific to a particular level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_9_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumVerticesTotal() const │ │ │ │ │ -Returns the total number of vertices in all levels. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_r_e_f_i_n_e │ │ │ │ │ -void Unrefine() │ │ │ │ │ -Unrefine the topology, keeping only the base level. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_G_e_t_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ -AdaptiveOptions GetAdaptiveOptions() const │ │ │ │ │ -Returns the options specified on refinement. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_9_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_: │ │ │ │ │ -_G_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ -Sdc::Options::FVarLinearInterpolation GetFVarLinearInterpolation(int channel=0) │ │ │ │ │ -const │ │ │ │ │ -Returns the face-varying interpolation rule set for a given channel. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_2_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_R_e_f_i_n_e_A_d_a_p_t_i_v_e │ │ │ │ │ -void RefineAdaptive(AdaptiveOptions options, ConstIndexArray │ │ │ │ │ -selectedFaces=ConstIndexArray()) │ │ │ │ │ -Feature Adaptive topology refinement. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s │ │ │ │ │ -Uniform refinement options. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_1_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_r_e_f_i_n_e_m_e_n_t_L_e_v_e_l │ │ │ │ │ -unsigned int refinementLevel │ │ │ │ │ -Number of refinement iterations. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_2_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_o_r_d_e_r_V_e_r_t_i_c_e_s_F_r_o_m_F_a_c_e_s_F_i_r_s_t │ │ │ │ │ -unsigned int orderVerticesFromFacesFirst │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_3_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_S_e_t_R_e_f_i_n_e_m_e_n_t_L_e_v_e_l │ │ │ │ │ -void SetRefinementLevel(int level) │ │ │ │ │ -Set uniform refinement level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_f_u_l_l_T_o_p_o_l_o_g_y_I_n_L_a_s_t_L_e_v_e_l │ │ │ │ │ -unsigned int fullTopologyInLastLevel │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_U_n_i_f_o_r_m_O_p_t_i_o_n_s │ │ │ │ │ -UniformOptions(int level) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_2_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ -Adaptive refinement options. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_s_e_c_o_n_d_a_r_y_L_e_v_e_l │ │ │ │ │ -unsigned int secondaryLevel │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_o_r_d_e_r_V_e_r_t_i_c_e_s_F_r_o_m_F_a_c_e_s_F_i_r_s_t │ │ │ │ │ -unsigned int orderVerticesFromFacesFirst │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ -AdaptiveOptions(int level) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_i_s_o_l_a_t_i_o_n_L_e_v_e_l │ │ │ │ │ -unsigned int isolationLevel │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h │ │ │ │ │ -unsigned int useSingleCreasePatch │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h │ │ │ │ │ -unsigned int useInfSharpPatch │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_S_e_t_I_s_o_l_a_t_i_o_n_L_e_v_e_l │ │ │ │ │ -void SetIsolationLevel(int level) │ │ │ │ │ -Set isolation level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -unsigned int considerFVarChannels │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_S_e_t_S_e_c_o_n_d_a_r_y_L_e_v_e_l │ │ │ │ │ -void SetSecondaryLevel(int level) │ │ │ │ │ -Set secondary isolation level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e │ │ │ │ │ -Private base class of Factories for constructing TopologyRefiners. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s │ │ │ │ │ -All supported options applying to subdivision scheme. │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ -FVarLinearInterpolation │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e │ │ │ │ │ +Rule │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_L_e_v_e_l_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00710.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/topologyLevel.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/topologyRefinerFactory.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,29 +90,34 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
topologyLevel.h File Reference
│ │ │ │ +
topologyRefinerFactory.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../vtr/level.h"
│ │ │ │ -#include "../vtr/refinement.h"
│ │ │ │ -#include "../far/types.h"
│ │ │ │ -#include <vector>
│ │ │ │ +#include "../far/topologyRefiner.h"
│ │ │ │ +#include "../far/error.h"
│ │ │ │ +#include <cassert>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  TopologyLevel
 An interface for accessing data in a specific level of a refined topology hierarchy. More...
class  TopologyRefinerFactoryBase
 Private base class of Factories for constructing TopologyRefiners. More...
 
class  TopologyRefinerFactory< MESH >
 Factory for constructing TopologyRefiners from specific mesh classes. More...
 
struct  TopologyRefinerFactory< MESH >::Options
 Options related to the construction of each TopologyRefiner. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -121,13 +126,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,28 +1,34 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -topologyLevel.h File Reference │ │ │ │ │ +topologyRefinerFactory.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_v_t_r_/_l_e_v_e_l_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_r_e_f_i_n_e_m_e_n_t_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_e_r_r_o_r_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ -  An interface for accessing data in a specific level of a refined │ │ │ │ │ - topology hierarchy. _M_o_r_e_._._. │ │ │ │ │ + class   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e │ │ │ │ │ +  Private base class of Factories for constructing TopologyRefiners. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ + class   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_ _M_E_S_H_ _> │ │ │ │ │ +  Factory for constructing TopologyRefiners from specific mesh classes. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +struct   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_ _M_E_S_H_ _>_:_:_O_p_t_i_o_n_s │ │ │ │ │ +  _O_p_t_i_o_n_s related to the construction of each _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_L_e_v_e_l_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00710.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,5 @@ │ │ │ │ │ var a00710 = [ │ │ │ │ │ - ["TopologyLevel", "a01113.html", "a01113"] │ │ │ │ │ + ["TopologyRefinerFactoryBase", "a01133.html", "a01133"], │ │ │ │ │ + ["TopologyRefinerFactory< MESH >", "a01117.html", "a01117"], │ │ │ │ │ + ["Options", "a01137.html", "a01137"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00710_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/topologyLevel.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/topologyRefinerFactory.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
topologyLevel.h
│ │ │ │ +
topologyRefinerFactory.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2015 DreamWorks Animation LLC.
│ │ │ │ +
2// Copyright 2014 DreamWorks Animation LLC.
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,228 +118,698 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H
│ │ │ │ -
25#define OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H
│ │ │ │ +
24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_REFINER_FACTORY_H
│ │ │ │ +
25#define OPENSUBDIV3_FAR_TOPOLOGY_REFINER_FACTORY_H
│ │ │ │
26
│ │ │ │
27#include "../version.h"
│ │ │ │
28
│ │ │ │ -
29#include "../vtr/level.h"
│ │ │ │ -
30#include "../vtr/refinement.h"
│ │ │ │ -
31#include "../far/types.h"
│ │ │ │ -
32
│ │ │ │ -
33#include <vector>
│ │ │ │ -
34
│ │ │ │ -
35namespace OpenSubdiv {
│ │ │ │ -
36namespace OPENSUBDIV_VERSION {
│ │ │ │ -
37
│ │ │ │ -
38namespace Far {
│ │ │ │ -
39
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
50
│ │ │ │ -
51public:
│ │ │ │ -
53
│ │ │ │ -
60
│ │ │ │ -
62 int GetNumVertices() const { return _level->getNumVertices(); }
│ │ │ │ +
29#include "../far/topologyRefiner.h"
│ │ │ │ +
30#include "../far/error.h"
│ │ │ │ +
31
│ │ │ │ +
32#include <cassert>
│ │ │ │ +
33
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Far {
│ │ │ │ +
38
│ │ │ │ +
46//
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
48protected:
│ │ │ │ +
49
│ │ │ │ +
50 //
│ │ │ │ +
51 // Protected methods invoked by the subclass template to verify and process each
│ │ │ │ +
52 // stage of construction implemented by the subclass:
│ │ │ │ +
53 //
│ │ │ │ +
54 typedef Vtr::internal::Level::ValidationCallback TopologyCallback;
│ │ │ │ +
55
│ │ │ │ + │ │ │ │ +
57 static bool prepareComponentTopologyAssignment(TopologyRefiner& refiner, bool fullValidation,
│ │ │ │ +
58 TopologyCallback callback, void const * callbackData);
│ │ │ │ + │ │ │ │ + │ │ │ │ +
61};
│ │ │ │ +
│ │ │ │ +
62
│ │ │ │
63
│ │ │ │ -
65 int GetNumFaces() const { return _level->getNumFaces(); }
│ │ │ │ -
66
│ │ │ │ -
68 int GetNumEdges() const { return _level->getNumEdges(); }
│ │ │ │ -
69
│ │ │ │ -
71 int GetNumFaceVertices() const { return _level->getNumFaceVerticesTotal(); }
│ │ │ │ -
73
│ │ │ │ -
75
│ │ │ │ -
90 //
│ │ │ │ -
91
│ │ │ │ -
93 ConstIndexArray GetFaceVertices(Index f) const { return _level->getFaceVertices(f); }
│ │ │ │ -
94
│ │ │ │ -
96 ConstIndexArray GetFaceEdges(Index f) const { return _level->getFaceEdges(f); }
│ │ │ │ -
97
│ │ │ │ -
99 ConstIndexArray GetEdgeVertices(Index e) const { return _level->getEdgeVertices(e); }
│ │ │ │ -
100
│ │ │ │ -
102 ConstIndexArray GetEdgeFaces(Index e) const { return _level->getEdgeFaces(e); }
│ │ │ │ -
103
│ │ │ │ -
105 ConstIndexArray GetVertexFaces(Index v) const { return _level->getVertexFaces(v); }
│ │ │ │ -
106
│ │ │ │ -
108 ConstIndexArray GetVertexEdges(Index v) const { return _level->getVertexEdges(v); }
│ │ │ │ -
109
│ │ │ │ -
111 ConstLocalIndexArray GetVertexFaceLocalIndices(Index v) const { return _level->getVertexFaceLocalIndices(v); }
│ │ │ │ -
112
│ │ │ │ -
114 ConstLocalIndexArray GetVertexEdgeLocalIndices(Index v) const { return _level->getVertexEdgeLocalIndices(v); }
│ │ │ │ -
115
│ │ │ │ -
117 ConstLocalIndexArray GetEdgeFaceLocalIndices(Index e) const { return _level->getEdgeFaceLocalIndices(e); }
│ │ │ │ -
118
│ │ │ │ -
120 Index FindEdge(Index v0, Index v1) const { return _level->findEdge(v0, v1); }
│ │ │ │ -
122
│ │ │ │ -
124
│ │ │ │ -
126
│ │ │ │ -
128 bool IsEdgeNonManifold(Index e) const { return _level->isEdgeNonManifold(e); }
│ │ │ │ +
77template <class MESH>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
79
│ │ │ │ +
80public:
│ │ │ │ +
81
│ │ │ │ +
│ │ │ │ +
84 struct Options {
│ │ │ │ +
85
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
87 schemeType(sdcType),
│ │ │ │ +
88 schemeOptions(sdcOptions),
│ │ │ │ +
89 validateFullTopology(false) { }
│ │ │ │ +
│ │ │ │ +
90
│ │ │ │ + │ │ │ │ + │ │ │ │ +
94 unsigned int validateFullTopology : 1;
│ │ │ │ +
97 };
│ │ │ │ +
│ │ │ │ +
98
│ │ │ │ +
108 //
│ │ │ │ +
113 static TopologyRefiner* Create(MESH const& mesh, Options options = Options());
│ │ │ │ +
114
│ │ │ │ +
128 static TopologyRefiner* Create(TopologyRefiner const & baseLevel);
│ │ │ │
129
│ │ │ │ -
131 bool IsVertexNonManifold(Index v) const { return _level->isVertexNonManifold(v); }
│ │ │ │ +
130protected:
│ │ │ │ +
131 typedef Vtr::internal::Level::TopologyError TopologyError;
│ │ │ │
132
│ │ │ │ -
134 bool IsEdgeBoundary(Index e) const { return _level->getEdgeTag(e)._boundary; }
│ │ │ │ -
135
│ │ │ │ -
137 bool IsVertexBoundary(Index v) const { return _level->getVertexTag(v)._boundary; }
│ │ │ │ -
138
│ │ │ │ -
140 bool IsVertexCorner(Index v) const { return (_level->getNumVertexFaces(v) == 1); }
│ │ │ │ -
141
│ │ │ │ -
162 bool IsVertexValenceRegular(Index v) const { return !_level->getVertexTag(v)._xordinary || IsVertexCorner(v); }
│ │ │ │ -
164
│ │ │ │ -
166
│ │ │ │ -
171
│ │ │ │ -
173 float GetEdgeSharpness(Index e) const { return _level->getEdgeSharpness(e); }
│ │ │ │ -
174
│ │ │ │ -
176 float GetVertexSharpness(Index v) const { return _level->getVertexSharpness(v); }
│ │ │ │ -
177
│ │ │ │ -
179 bool IsEdgeInfSharp(Index e) const { return _level->getEdgeTag(e)._infSharp; }
│ │ │ │ -
180
│ │ │ │ -
182 bool IsVertexInfSharp(Index v) const { return _level->getVertexTag(v)._infSharp; }
│ │ │ │ -
183
│ │ │ │ -
185 bool IsEdgeSemiSharp(Index e) const { return _level->getEdgeTag(e)._semiSharp; }
│ │ │ │ -
186
│ │ │ │ -
188 bool IsVertexSemiSharp(Index v) const { return _level->getVertexTag(v)._semiSharp; }
│ │ │ │ -
189
│ │ │ │ -
191 bool IsFaceHole(Index f) const { return _level->isFaceHole(f); }
│ │ │ │ -
192
│ │ │ │ -
194 Sdc::Crease::Rule GetVertexRule(Index v) const { return _level->getVertexRule(v); }
│ │ │ │ +
134
│ │ │ │ +
149
│ │ │ │ +
151 static bool resizeComponentTopology(TopologyRefiner& newRefiner, MESH const& mesh);
│ │ │ │ +
152
│ │ │ │ +
155 static bool assignComponentTopology(TopologyRefiner& newRefiner, MESH const& mesh);
│ │ │ │ +
156
│ │ │ │ +
158 static bool assignComponentTags(TopologyRefiner& newRefiner, MESH const& mesh);
│ │ │ │ +
159
│ │ │ │ +
161 static bool assignFaceVaryingTopology(TopologyRefiner& newRefiner, MESH const& mesh);
│ │ │ │ +
162
│ │ │ │ +
164 static void reportInvalidTopology(TopologyError errCode, char const * msg, MESH const& mesh);
│ │ │ │ +
165
│ │ │ │ +
167
│ │ │ │ +
168protected:
│ │ │ │ +
170
│ │ │ │ +
187
│ │ │ │ +
189 static void setNumBaseVertices(TopologyRefiner & newRefiner, int count);
│ │ │ │ +
190
│ │ │ │ +
192 static void setNumBaseFaces(TopologyRefiner & newRefiner, int count);
│ │ │ │ +
193
│ │ │ │ +
195 static void setNumBaseEdges(TopologyRefiner & newRefiner, int count);
│ │ │ │
196
│ │ │ │ -
198
│ │ │ │ -
228
│ │ │ │ -
230 int GetNumFVarChannels() const { return _level->getNumFVarChannels(); }
│ │ │ │ -
231
│ │ │ │ -
234 int GetNumFVarValues(int channel = 0) const { return _level->getNumFVarValues(channel); }
│ │ │ │ -
235
│ │ │ │ -
│ │ │ │ -
237 ConstIndexArray GetFaceFVarValues(Index f, int channel = 0) const {
│ │ │ │ -
238 return _level->getFaceFVarValues(f, channel);
│ │ │ │ -
239 }
│ │ │ │ -
│ │ │ │ +
198 static void setNumBaseFaceVertices(TopologyRefiner & newRefiner, Index f, int count);
│ │ │ │ +
199
│ │ │ │ +
201 static void setNumBaseEdgeFaces(TopologyRefiner & newRefiner, Index e, int count);
│ │ │ │ +
202
│ │ │ │ +
204 static void setNumBaseVertexFaces(TopologyRefiner & newRefiner, Index v, int count);
│ │ │ │ +
205
│ │ │ │ +
207 static void setNumBaseVertexEdges(TopologyRefiner & newRefiner, Index v, int count);
│ │ │ │ +
208
│ │ │ │ +
209 static int getNumBaseVertices(TopologyRefiner const & newRefiner);
│ │ │ │ +
210 static int getNumBaseFaces(TopologyRefiner const & newRefiner);
│ │ │ │ +
211 static int getNumBaseEdges(TopologyRefiner const & newRefiner);
│ │ │ │ +
213
│ │ │ │ +
215
│ │ │ │ +
237
│ │ │ │ +
239 static IndexArray getBaseFaceVertices(TopologyRefiner & newRefiner, Index f);
│ │ │ │
240
│ │ │ │ -
│ │ │ │ -
242 bool DoesVertexFVarTopologyMatch(Index v, int channel = 0) const {
│ │ │ │ -
243 return _level->doesVertexFVarTopologyMatch(v, channel);
│ │ │ │ -
244 }
│ │ │ │ -
│ │ │ │ -
245
│ │ │ │ -
│ │ │ │ -
247 bool DoesEdgeFVarTopologyMatch(Index e, int channel = 0) const {
│ │ │ │ -
248 return _level->doesEdgeFVarTopologyMatch(e, channel);
│ │ │ │ -
249 }
│ │ │ │ -
│ │ │ │ -
250
│ │ │ │ -
│ │ │ │ -
252 bool DoesFaceFVarTopologyMatch(Index f, int channel = 0) const {
│ │ │ │ -
253 return _level->doesFaceFVarTopologyMatch(f, channel);
│ │ │ │ -
254 }
│ │ │ │ -
│ │ │ │ +
242 static IndexArray getBaseFaceEdges(TopologyRefiner & newRefiner, Index f);
│ │ │ │ +
243
│ │ │ │ +
245 static IndexArray getBaseEdgeVertices(TopologyRefiner & newRefiner, Index e);
│ │ │ │ +
246
│ │ │ │ +
248 static IndexArray getBaseEdgeFaces(TopologyRefiner & newRefiner, Index e);
│ │ │ │ +
249
│ │ │ │ +
251 static IndexArray getBaseVertexFaces(TopologyRefiner & newRefiner, Index v);
│ │ │ │ +
252
│ │ │ │ +
254 static IndexArray getBaseVertexEdges(TopologyRefiner & newRefiner, Index v);
│ │ │ │
255
│ │ │ │ -
257
│ │ │ │ -
259
│ │ │ │ -
260
│ │ │ │ -
262 ConstIndexArray GetFaceChildFaces(Index f) const { return _refToChild->getFaceChildFaces(f); }
│ │ │ │ -
263
│ │ │ │ -
265 ConstIndexArray GetFaceChildEdges(Index f) const { return _refToChild->getFaceChildEdges(f); }
│ │ │ │ -
266
│ │ │ │ -
268 ConstIndexArray GetEdgeChildEdges(Index e) const { return _refToChild->getEdgeChildEdges(e); }
│ │ │ │ -
269
│ │ │ │ -
271 Index GetFaceChildVertex( Index f) const { return _refToChild->getFaceChildVertex(f); }
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
262
│ │ │ │ +
264 static void populateBaseLocalIndices(TopologyRefiner & newRefiner);
│ │ │ │ +
265
│ │ │ │ +
267 static void setBaseEdgeNonManifold(TopologyRefiner & newRefiner, Index e, bool b);
│ │ │ │ +
268
│ │ │ │ +
270 static void setBaseVertexNonManifold(TopologyRefiner & newRefiner, Index v, bool b);
│ │ │ │
272
│ │ │ │ -
274 Index GetEdgeChildVertex( Index e) const { return _refToChild->getEdgeChildVertex(e); }
│ │ │ │ -
275
│ │ │ │ -
277 Index GetVertexChildVertex(Index v) const { return _refToChild->getVertexChildVertex(v); }
│ │ │ │ -
278
│ │ │ │ -
280 Index GetFaceParentFace(Index f) const { return _refToParent->getChildFaceParentFace(f); }
│ │ │ │ -
282
│ │ │ │ -
284
│ │ │ │ -
285
│ │ │ │ -
286 bool ValidateTopology() const { return _level->validateTopology(); }
│ │ │ │ -
287 void PrintTopology(bool children = true) const { _level->print((children && _refToChild) ? _refToChild : 0); }
│ │ │ │ +
274
│ │ │ │ +
283
│ │ │ │ +
285 static Index findBaseEdge(TopologyRefiner const & newRefiner, Index v0, Index v1);
│ │ │ │ +
286
│ │ │ │ +
288 static void setBaseEdgeSharpness(TopologyRefiner & newRefiner, Index e, float sharpness);
│ │ │ │
289
│ │ │ │ -
290
│ │ │ │ -
291private:
│ │ │ │ -
292 friend class TopologyRefiner;
│ │ │ │ -
293
│ │ │ │ -
294 Vtr::internal::Level const * _level;
│ │ │ │ -
295 Vtr::internal::Refinement const * _refToParent;
│ │ │ │ -
296 Vtr::internal::Refinement const * _refToChild;
│ │ │ │ -
297
│ │ │ │ -
298public:
│ │ │ │ -
299 // Not intended for public use, but required by std::vector, etc...
│ │ │ │ - │ │ │ │ - │ │ │ │ -
302};
│ │ │ │ -
│ │ │ │ -
303
│ │ │ │ -
304} // end namespace Far
│ │ │ │ -
305
│ │ │ │ -
306} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
307using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
308} // end namespace OpenSubdiv
│ │ │ │ -
309
│ │ │ │ -
310#endif /* OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H */
│ │ │ │ +
291 static void setBaseVertexSharpness(TopologyRefiner & newRefiner, Index v, float sharpness);
│ │ │ │ +
292
│ │ │ │ +
294 static void setBaseFaceHole(TopologyRefiner & newRefiner, Index f, bool isHole);
│ │ │ │ +
296
│ │ │ │ +
298
│ │ │ │ +
308
│ │ │ │ +
310 static int createBaseFVarChannel(TopologyRefiner & newRefiner, int numValues);
│ │ │ │ +
311
│ │ │ │ +
313 static int createBaseFVarChannel(TopologyRefiner & newRefiner, int numValues, Sdc::Options const& fvarOptions);
│ │ │ │ +
314
│ │ │ │ +
316 static IndexArray getBaseFaceFVarValues(TopologyRefiner & newRefiner, Index face, int channel = 0);
│ │ │ │ +
317
│ │ │ │ +
319
│ │ │ │ +
320protected:
│ │ │ │ +
321 //
│ │ │ │ +
322 // Not to be specialized:
│ │ │ │ +
323 //
│ │ │ │ +
324 static bool populateBaseLevel(TopologyRefiner& refiner, MESH const& mesh, Options options);
│ │ │ │ +
325
│ │ │ │ +
326private:
│ │ │ │ +
327 //
│ │ │ │ +
328 // An oversight in the interfaces of the error reporting function between the factory
│ │ │ │ +
329 // class and the Vtr::Level requires this adapter function to avoid warnings.
│ │ │ │ +
330 //
│ │ │ │ +
331 // The static class method requires a reference as the MESH argument, but the interface
│ │ │ │ +
332 // for Vtr::Level requires a pointer (void*). So this adapter with a MESH* argument is
│ │ │ │ +
333 // used to effectively cast the function pointer required by Vtr::Level error reporting:
│ │ │ │ +
334 //
│ │ │ │ +
335 static void reportInvalidTopologyAdapter(TopologyError errCode, char const * msg, MESH const * mesh) {
│ │ │ │ +
336 reportInvalidTopology(errCode, msg, *mesh);
│ │ │ │ +
337 }
│ │ │ │ +
338};
│ │ │ │ +
│ │ │ │ +
339
│ │ │ │ +
340
│ │ │ │ +
341//
│ │ │ │ +
342// Generic implementations:
│ │ │ │ +
343//
│ │ │ │ +
344template <class MESH>
│ │ │ │ +
345TopologyRefiner*
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
347
│ │ │ │ +
348 TopologyRefiner * refiner = new TopologyRefiner(options.schemeType, options.schemeOptions);
│ │ │ │ +
349
│ │ │ │ +
350 if (! populateBaseLevel(*refiner, mesh, options)) {
│ │ │ │ +
351 delete refiner;
│ │ │ │ +
352 return 0;
│ │ │ │ +
353 }
│ │ │ │ +
354
│ │ │ │ +
355 // Eventually want to move the Refiner's inventory initialization here. Currently it
│ │ │ │ +
356 // is handled after topology assignment, but if the inventory is to include additional
│ │ │ │ +
357 // features (e.g. holes, etc.) it is better off deferred to here.
│ │ │ │ +
358
│ │ │ │ +
359 return refiner;
│ │ │ │ +
360}
│ │ │ │ +
│ │ │ │ +
361
│ │ │ │ +
362template <class MESH>
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
365
│ │ │ │ +
366 return new TopologyRefiner(source);
│ │ │ │ +
367}
│ │ │ │ +
│ │ │ │ +
368
│ │ │ │ +
369template <class MESH>
│ │ │ │ +
370bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
372
│ │ │ │ +
373 //
│ │ │ │ +
374 // Construction of a specialized topology refiner involves four steps, each of which
│ │ │ │ +
375 // involves a method specialized for MESH followed by one that takes an action in
│ │ │ │ +
376 // response to it or in preparation for the next step.
│ │ │ │ +
377 //
│ │ │ │ +
378 // Both the specialized methods and those that follow them may find fault in the
│ │ │ │ +
379 // construction and trigger failure at any time:
│ │ │ │ +
380 //
│ │ │ │ +
381
│ │ │ │ +
382 //
│ │ │ │ +
383 // Sizing of the topology -- this is a required specialization for MESH. This defines
│ │ │ │ +
384 // an inventory of all components and their relations that is used to allocate buffers
│ │ │ │ +
385 // to be efficiently populated in the subsequent topology assignment step.
│ │ │ │ +
386 //
│ │ │ │ +
387 if (! resizeComponentTopology(refiner, mesh)) return false;
│ │ │ │ +
388 if (! prepareComponentTopologySizing(refiner)) return false;
│ │ │ │ +
389
│ │ │ │ +
390 //
│ │ │ │ +
391 // Assignment of the topology -- this is a required specialization for MESH. If edges
│ │ │ │ +
392 // are specified, all other topological relations are expected to be defined for them.
│ │ │ │ +
393 // Otherwise edges and remaining topology will be completed from the face-vertices:
│ │ │ │ +
394 //
│ │ │ │ +
395 bool validate = options.validateFullTopology;
│ │ │ │ +
396 TopologyCallback callback = reinterpret_cast<TopologyCallback>(reportInvalidTopologyAdapter);
│ │ │ │ +
397 void const * userData = &mesh;
│ │ │ │ +
398
│ │ │ │ +
399 if (! assignComponentTopology(refiner, mesh)) return false;
│ │ │ │ +
400 if (! prepareComponentTopologyAssignment(refiner, validate, callback, userData)) return false;
│ │ │ │ +
401
│ │ │ │ +
402 //
│ │ │ │ +
403 // User assigned and internal tagging of components -- an optional specialization for
│ │ │ │ +
404 // MESH. Allows the specification of sharpness values, holes, etc.
│ │ │ │ +
405 //
│ │ │ │ +
406 if (! assignComponentTags(refiner, mesh)) return false;
│ │ │ │ +
407 if (! prepareComponentTagsAndSharpness(refiner)) return false;
│ │ │ │ +
408
│ │ │ │ +
409 //
│ │ │ │ +
410 // Defining channels of face-varying primvar data -- an optional specialization for MESH.
│ │ │ │ +
411 //
│ │ │ │ +
412 if (! assignFaceVaryingTopology(refiner, mesh)) return false;
│ │ │ │ +
413 if (! prepareFaceVaryingChannels(refiner)) return false;
│ │ │ │ +
414
│ │ │ │ +
415 return true;
│ │ │ │ +
416}
│ │ │ │ +
│ │ │ │ +
417
│ │ │ │ +
418template <class MESH>
│ │ │ │ +
419inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
421 newRefiner._levels[0]->resizeFaces(count);
│ │ │ │ +
422}
│ │ │ │ +
│ │ │ │ +
423template <class MESH>
│ │ │ │ +
424inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
426 newRefiner._levels[0]->resizeEdges(count);
│ │ │ │ +
427}
│ │ │ │ +
│ │ │ │ +
428template <class MESH>
│ │ │ │ +
429inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
431 newRefiner._levels[0]->resizeVertices(count);
│ │ │ │ +
432}
│ │ │ │ +
│ │ │ │ +
433
│ │ │ │ +
434template <class MESH>
│ │ │ │ +
435inline int
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
437 return newRefiner._levels[0]->getNumFaces();
│ │ │ │ +
438}
│ │ │ │ +
│ │ │ │ +
439template <class MESH>
│ │ │ │ +
440inline int
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
442 return newRefiner._levels[0]->getNumEdges();
│ │ │ │ +
443}
│ │ │ │ +
│ │ │ │ +
444template <class MESH>
│ │ │ │ +
445inline int
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
447 return newRefiner._levels[0]->getNumVertices();
│ │ │ │ +
448}
│ │ │ │ +
│ │ │ │ +
449
│ │ │ │ +
450template <class MESH>
│ │ │ │ +
451inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
453 newRefiner._levels[0]->resizeFaceVertices(f, count);
│ │ │ │ +
454 newRefiner._hasIrregFaces = newRefiner._hasIrregFaces || (count != newRefiner._regFaceSize);
│ │ │ │ +
455}
│ │ │ │ +
│ │ │ │ +
456template <class MESH>
│ │ │ │ +
457inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
459 newRefiner._levels[0]->resizeEdgeFaces(e, count);
│ │ │ │ +
460}
│ │ │ │ +
│ │ │ │ +
461template <class MESH>
│ │ │ │ +
462inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
464 newRefiner._levels[0]->resizeVertexFaces(v, count);
│ │ │ │ +
465}
│ │ │ │ +
│ │ │ │ +
466template <class MESH>
│ │ │ │ +
467inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
469 newRefiner._levels[0]->resizeVertexEdges(v, count);
│ │ │ │ +
470}
│ │ │ │ +
│ │ │ │ +
471
│ │ │ │ +
472template <class MESH>
│ │ │ │ +
473inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
475 return newRefiner._levels[0]->getFaceVertices(f);
│ │ │ │ +
476}
│ │ │ │ +
│ │ │ │ +
477template <class MESH>
│ │ │ │ +
478inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
480 return newRefiner._levels[0]->getFaceEdges(f);
│ │ │ │ +
481}
│ │ │ │ +
│ │ │ │ +
482template <class MESH>
│ │ │ │ +
483inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
485 return newRefiner._levels[0]->getEdgeVertices(e);
│ │ │ │ +
486}
│ │ │ │ +
│ │ │ │ +
487template <class MESH>
│ │ │ │ +
488inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
490 return newRefiner._levels[0]->getEdgeFaces(e);
│ │ │ │ +
491}
│ │ │ │ +
│ │ │ │ +
492template <class MESH>
│ │ │ │ +
493inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
495 return newRefiner._levels[0]->getVertexFaces(v);
│ │ │ │ +
496}
│ │ │ │ +
│ │ │ │ +
497template <class MESH>
│ │ │ │ +
498inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
500 return newRefiner._levels[0]->getVertexEdges(v);
│ │ │ │ +
501}
│ │ │ │ +
│ │ │ │ +
502
│ │ │ │ +
503template <class MESH>
│ │ │ │ +
504inline LocalIndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
506 return newRefiner._levels[0]->getEdgeFaceLocalIndices(e);
│ │ │ │ +
507}
│ │ │ │ +
│ │ │ │ +
508template <class MESH>
│ │ │ │ +
509inline LocalIndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
511 return newRefiner._levels[0]->getVertexFaceLocalIndices(v);
│ │ │ │ +
512}
│ │ │ │ +
│ │ │ │ +
513template <class MESH>
│ │ │ │ +
514inline LocalIndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
516 return newRefiner._levels[0]->getVertexEdgeLocalIndices(v);
│ │ │ │ +
517}
│ │ │ │ +
│ │ │ │ +
518
│ │ │ │ +
519template <class MESH>
│ │ │ │ +
520inline Index
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
522 return newRefiner._levels[0]->findEdge(v0, v1);
│ │ │ │ +
523}
│ │ │ │ +
│ │ │ │ +
524
│ │ │ │ +
525template <class MESH>
│ │ │ │ +
526inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
528 newRefiner._levels[0]->populateLocalIndices();
│ │ │ │ +
529}
│ │ │ │ +
│ │ │ │ +
530
│ │ │ │ +
531template <class MESH>
│ │ │ │ +
532inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
534 newRefiner._levels[0]->setEdgeNonManifold(e, b);
│ │ │ │ +
535}
│ │ │ │ +
│ │ │ │ +
536template <class MESH>
│ │ │ │ +
537inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
539 newRefiner._levels[0]->setVertexNonManifold(v, b);
│ │ │ │ +
540}
│ │ │ │ +
│ │ │ │ +
541
│ │ │ │ +
542template <class MESH>
│ │ │ │ +
543inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
545 newRefiner._levels[0]->getEdgeSharpness(e) = s;
│ │ │ │ +
546}
│ │ │ │ +
│ │ │ │ +
547template <class MESH>
│ │ │ │ +
548inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
550 newRefiner._levels[0]->getVertexSharpness(v) = s;
│ │ │ │ +
551}
│ │ │ │ +
│ │ │ │ +
552template <class MESH>
│ │ │ │ +
553inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
555 newRefiner._levels[0]->setFaceHole(f, b);
│ │ │ │ +
556 newRefiner._hasHoles = newRefiner._hasHoles || b;
│ │ │ │ +
557}
│ │ │ │ +
│ │ │ │ +
558
│ │ │ │ +
559template <class MESH>
│ │ │ │ +
560inline int
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
562 return newRefiner._levels[0]->createFVarChannel(numValues, newRefiner._subdivOptions);
│ │ │ │ +
563}
│ │ │ │ +
│ │ │ │ +
564template <class MESH>
│ │ │ │ +
565inline int
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
567 Sdc::Options newOptions = newRefiner._subdivOptions;
│ │ │ │ + │ │ │ │ +
569 return newRefiner._levels[0]->createFVarChannel(numValues, newOptions);
│ │ │ │ +
570}
│ │ │ │ +
│ │ │ │ +
571template <class MESH>
│ │ │ │ +
572inline IndexArray
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
574 return newRefiner._levels[0]->getFaceFVarValues(face, channel);
│ │ │ │ +
575}
│ │ │ │ +
│ │ │ │ +
576
│ │ │ │ +
577
│ │ │ │ +
578template <class MESH>
│ │ │ │ +
579bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
581
│ │ │ │ + │ │ │ │ +
583 "Failure in TopologyRefinerFactory<>::resizeComponentTopology() -- no specialization provided.");
│ │ │ │ +
584
│ │ │ │ +
585 //
│ │ │ │ +
586 // Sizing the topology tables:
│ │ │ │ +
587 // This method is for determining the sizes of the various topology tables (and other
│ │ │ │ +
588 // data) associated with the mesh. Once completed, appropriate memory will be allocated
│ │ │ │ +
589 // and an additional method invoked to populate it accordingly.
│ │ │ │ +
590 //
│ │ │ │ +
591 // The following methods should be called -- first those to specify the number of faces,
│ │ │ │ +
592 // edges and vertices in the mesh:
│ │ │ │ +
593 //
│ │ │ │ +
594 // void setBaseFaceCount( TopologyRefiner& newRefiner, int count)
│ │ │ │ +
595 // void setBaseEdgeCount( TopologyRefiner& newRefiner, int count)
│ │ │ │ +
596 // void setBaseVertexCount(TopologyRefiner& newRefiner, int count)
│ │ │ │ +
597 //
│ │ │ │ +
598 // and then for each face, edge and vertex, the number of its incident components:
│ │ │ │ +
599 //
│ │ │ │ +
600 // void setBaseFaceVertexCount(TopologyRefiner& newRefiner, Index face, int count)
│ │ │ │ +
601 // void setBaseEdgeFaceCount( TopologyRefiner& newRefiner, Index edge, int count)
│ │ │ │ +
602 // void setBaseVertexFaceCount(TopologyRefiner& newRefiner, Index vertex, int count)
│ │ │ │ +
603 // void setBaseVertexEdgeCount(TopologyRefiner& newRefiner, Index vertex, int count)
│ │ │ │ +
604 //
│ │ │ │ +
605 // The count/size for a component type must be set before indices associated with that
│ │ │ │ +
606 // component type can be used.
│ │ │ │ +
607 //
│ │ │ │ +
608 // Note that it is only necessary to size 4 of the 6 supported topological relations --
│ │ │ │ +
609 // the number of edge-vertices is fixed at two per edge, and the number of face-edges is
│ │ │ │ +
610 // the same as the number of face-vertices.
│ │ │ │ +
611 //
│ │ │ │ +
612 // So a single pass through your mesh to gather up all of this sizing information will
│ │ │ │ +
613 // allow the Tables to be allocated appropriately once and avoid any dynamic resizing as
│ │ │ │ +
614 // it grows.
│ │ │ │ +
615 //
│ │ │ │ +
616 return false;
│ │ │ │ +
617}
│ │ │ │ +
│ │ │ │ +
618
│ │ │ │ +
619template <class MESH>
│ │ │ │ +
620bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
622
│ │ │ │ + │ │ │ │ +
624 "Failure in TopologyRefinerFactory<>::assignComponentTopology() -- no specialization provided.");
│ │ │ │ +
625
│ │ │ │ +
626 //
│ │ │ │ +
627 // Assigning the topology tables:
│ │ │ │ +
628 // Once the topology tables have been allocated, the six required topological
│ │ │ │ +
629 // relations can be directly populated using the following methods:
│ │ │ │ +
630 //
│ │ │ │ +
631 // IndexArray setBaseFaceVertices(TopologyRefiner& newRefiner, Index face)
│ │ │ │ +
632 // IndexArray setBaseFaceEdges(TopologyRefiner& newRefiner, Index face)
│ │ │ │ +
633 //
│ │ │ │ +
634 // IndexArray setBaseEdgeVertices(TopologyRefiner& newRefiner, Index edge)
│ │ │ │ +
635 // IndexArray setBaseEdgeFaces(TopologyRefiner& newRefiner, Index edge)
│ │ │ │ +
636 //
│ │ │ │ +
637 // IndexArray setBaseVertexEdges(TopologyRefiner& newRefiner, Index vertex)
│ │ │ │ +
638 // IndexArray setBaseVertexFaces(TopologyRefiner& newRefiner, Index vertex)
│ │ │ │ +
639 //
│ │ │ │ +
640 // For the last two relations -- the faces and edges incident a vertex -- there are
│ │ │ │ +
641 // also "local indices" that must be specified (considering doing this internally),
│ │ │ │ +
642 // where the "local index" of each incident face or edge is the index of the vertex
│ │ │ │ +
643 // within that face or edge, and so ranging from 0-3 for incident quads and 0-1 for
│ │ │ │ +
644 // incident edges. These are assigned through similarly retrieved arrays:
│ │ │ │ +
645 //
│ │ │ │ +
646 // LocalIndexArray setBaseVertexFaceLocalIndices(TopologyRefiner& newRefiner, Index vertex)
│ │ │ │ +
647 // LocalIndexArray setBaseVertexEdgeLocalIndices(TopologyRefiner& newRefiner, Index vertex)
│ │ │ │ +
648 // LocalIndexArray setBaseEdgeFaceLocalIndices( TopologyRefiner& newRefiner, Index edge)
│ │ │ │ +
649 //
│ │ │ │ +
650 // or, if the mesh is manifold, explicit assignment of these can be deferred and
│ │ │ │ +
651 // all can be determined by calling:
│ │ │ │ +
652 //
│ │ │ │ +
653 // void populateBaseLocalIndices(TopologyRefiner& newRefiner)
│ │ │ │ +
654 //
│ │ │ │ +
655 // All components are assumed to be locally manifold and ordering of components in
│ │ │ │ +
656 // the above relations is expected to be counter-clockwise.
│ │ │ │ +
657 //
│ │ │ │ +
658 // For non-manifold components, no ordering/orientation of incident components is
│ │ │ │ +
659 // assumed or required, but be sure to explicitly tag such components (vertices and
│ │ │ │ +
660 // edges) as non-manifold:
│ │ │ │ +
661 //
│ │ │ │ +
662 // void setBaseEdgeNonManifold(TopologyRefiner& newRefiner, Index edge, bool b);
│ │ │ │ +
663 //
│ │ │ │ +
664 // void setBaseVertexNonManifold(TopologyRefiner& newRefiner, Index vertex, bool b);
│ │ │ │ +
665 //
│ │ │ │ +
666 // Also consider using TopologyLevel::ValidateTopology() when debugging to ensure
│ │ │ │ +
667 // that topology has been completely and correctly specified.
│ │ │ │ +
668 //
│ │ │ │ +
669 return false;
│ │ │ │ +
670}
│ │ │ │ +
│ │ │ │ +
671
│ │ │ │ +
672template <class MESH>
│ │ │ │ +
673bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
675
│ │ │ │ +
676 //
│ │ │ │ +
677 // Optional assigning face-varying topology tables:
│ │ │ │ +
678 //
│ │ │ │ +
679 // Create independent face-varying primitive variable channels:
│ │ │ │ +
680 // int createBaseFVarChannel(TopologyRefiner& newRefiner, int numValues)
│ │ │ │ +
681 //
│ │ │ │ +
682 // For each channel, populate the face-vertex values:
│ │ │ │ +
683 // IndexArray setBaseFaceFVarValues(TopologyRefiner& newRefiner, Index face, int channel = 0)
│ │ │ │ +
684 //
│ │ │ │ +
685 return true;
│ │ │ │ +
686}
│ │ │ │ +
│ │ │ │ +
687
│ │ │ │ +
688template <class MESH>
│ │ │ │ +
689bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
691
│ │ │ │ +
692 //
│ │ │ │ +
693 // Optional tagging:
│ │ │ │ +
694 // This is where any additional feature tags -- sharpness, holes, etc. -- can be
│ │ │ │ +
695 // specified using:
│ │ │ │ +
696 //
│ │ │ │ +
697 // void setBaseEdgeSharpness(TopologyRefiner& newRefiner, Index edge, float sharpness)
│ │ │ │ +
698 // void setBaseVertexSharpness(TopologyRefiner& newRefiner, Index vertex, float sharpness)
│ │ │ │ +
699 //
│ │ │ │ +
700 // void setBaseFaceHole(TopologyRefiner& newRefiner, Index face, bool hole)
│ │ │ │ +
701 //
│ │ │ │ +
702 return true;
│ │ │ │ +
703}
│ │ │ │ +
│ │ │ │ +
704
│ │ │ │ +
705template <class MESH>
│ │ │ │ +
706void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
708 TopologyError /* errCode */, char const * /* msg */, MESH const& /* mesh */) {
│ │ │ │ +
709
│ │ │ │ +
710 //
│ │ │ │ +
711 // Optional topology validation error reporting:
│ │ │ │ +
712 // This method is called whenever the factory encounters topology validation
│ │ │ │ +
713 // errors. By default, nothing is reported
│ │ │ │ +
714 //
│ │ │ │ +
715}
│ │ │ │ +
│ │ │ │ +
716
│ │ │ │ +
717} // end namespace Far
│ │ │ │ +
718
│ │ │ │ +
719} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
720using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
721} // end namespace OpenSubdiv
│ │ │ │ +
722
│ │ │ │ +
723#endif /* OPENSUBDIV3_FAR_TOPOLOGY_REFINER_FACTORY_H */
│ │ │ │ │ │ │ │ +
void Error(ErrorType err, const char *format,...)
Sends an OSD error with a message (internal use only)
│ │ │ │ +
@ FAR_RUNTIME_ERROR
Issue a generic runtime error, but continue execution.
Definition error.h:40
│ │ │ │ │ │ │ │ -
An interface for accessing data in a specific level of a refined topology hierarchy.
│ │ │ │ -
Index GetFaceParentFace(Index f) const
Return the parent face (in the previous level) of a given face.
│ │ │ │ - │ │ │ │ -
bool IsVertexValenceRegular(Index v) const
Return if the valence of the vertex is regular (must be manifold)
│ │ │ │ -
float GetEdgeSharpness(Index e) const
Return the sharpness assigned a given edge.
│ │ │ │ -
bool DoesFaceFVarTopologyMatch(Index f, int channel=0) const
Return if face-varying topology around a face matches.
│ │ │ │ -
Sdc::Crease::Rule GetVertexRule(Index v) const
Return the subdivision rule assigned a given vertex specific to this level.
│ │ │ │ -
bool IsVertexCorner(Index v) const
Return if the vertex is a corner (only one incident face)
│ │ │ │ -
Index GetVertexChildVertex(Index v) const
Return the child vertex (in the next level) of a given vertex.
│ │ │ │ -
ConstLocalIndexArray GetEdgeFaceLocalIndices(Index e) const
Access the local indices of an edge with respect to its incident faces.
│ │ │ │ -
ConstIndexArray GetFaceChildEdges(Index f) const
Access the child edges (in the next level) of a given face.
│ │ │ │ -
bool DoesEdgeFVarTopologyMatch(Index e, int channel=0) const
Return if face-varying topology across the edge only matches.
│ │ │ │ - │ │ │ │ -
ConstIndexArray GetFaceVertices(Index f) const
Access the vertices incident a given face.
│ │ │ │ -
ConstIndexArray GetFaceChildFaces(Index f) const
Access the child faces (in the next level) of a given face.
│ │ │ │ -
int GetNumEdges() const
Return the number of edges in this level.
│ │ │ │ - │ │ │ │ -
bool IsEdgeNonManifold(Index e) const
Return if the edge is non-manifold.
│ │ │ │ -
bool IsFaceHole(Index f) const
Return if a given face has been tagged as a hole.
│ │ │ │ -
ConstIndexArray GetVertexEdges(Index v) const
Access the edges incident a given vertex.
│ │ │ │ -
Index GetFaceChildVertex(Index f) const
Return the child vertex (in the next level) of a given face.
│ │ │ │ -
bool DoesVertexFVarTopologyMatch(Index v, int channel=0) const
Return if face-varying topology around a vertex matches.
│ │ │ │ -
ConstIndexArray GetEdgeChildEdges(Index e) const
Access the child edges (in the next level) of a given edge.
│ │ │ │ -
bool IsEdgeInfSharp(Index e) const
Return if the edge is infinitely-sharp.
│ │ │ │ -
ConstIndexArray GetVertexFaces(Index v) const
Access the faces incident a given vertex.
│ │ │ │ -
Index FindEdge(Index v0, Index v1) const
Identify the edge matching the given vertex pair.
│ │ │ │ -
ConstLocalIndexArray GetVertexEdgeLocalIndices(Index v) const
Access the local indices of a vertex with respect to its incident edges.
│ │ │ │ -
ConstIndexArray GetFaceEdges(Index f) const
Access the edges incident a given face.
│ │ │ │ -
int GetNumFaces() const
Return the number of faces in this level.
│ │ │ │ -
bool IsVertexBoundary(Index v) const
Return if the vertex is on a boundary (at least one incident boundary edge)
│ │ │ │ -
int GetNumFVarChannels() const
Return the number of face-varying channels (should be same for all levels)
│ │ │ │ -
int GetNumVertices() const
Return the number of vertices in this level.
│ │ │ │ -
ConstIndexArray GetEdgeFaces(Index e) const
Access the faces incident a given edge.
│ │ │ │ -
ConstIndexArray GetFaceFVarValues(Index f, int channel=0) const
Access the face-varying values associated with a particular face.
│ │ │ │ -
ConstIndexArray GetEdgeVertices(Index e) const
Access the vertices incident a given edge.
│ │ │ │ -
bool IsEdgeSemiSharp(Index e) const
Return if the edge is semi-sharp.
│ │ │ │ - │ │ │ │ -
float GetVertexSharpness(Index v) const
Return the sharpness assigned a given vertex.
│ │ │ │ -
Index GetEdgeChildVertex(Index e) const
Return the child vertex (in the next level) of a given edge.
│ │ │ │ -
bool IsVertexSemiSharp(Index v) const
Return if the vertex is semi-sharp.
│ │ │ │ -
int GetNumFaceVertices() const
Return the total number of face-vertices, i.e. the sum of all vertices for all faces.
│ │ │ │ -
bool IsVertexNonManifold(Index v) const
Return if the vertex is non-manifold.
│ │ │ │ -
bool IsEdgeBoundary(Index e) const
Return if the edge is a boundary (only one incident face)
│ │ │ │ -
bool IsVertexInfSharp(Index v) const
Return if the vertex is infinitely-sharp.
│ │ │ │ -
int GetNumFVarValues(int channel=0) const
Return the total number of face-varying values in a particular channel (the upper bound of a face-var...
│ │ │ │ -
ConstLocalIndexArray GetVertexFaceLocalIndices(Index v) const
Access the local indices of a vertex with respect to its incident faces.
│ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ - │ │ │ │ - │ │ │ │ +
SchemeType
Enumerated type for all subdivision schemes supported by OpenSubdiv.
Definition types.h:37
│ │ │ │ + │ │ │ │ +
Factory for constructing TopologyRefiners from specific mesh classes.
│ │ │ │ +
static int getNumBaseFaces(TopologyRefiner const &newRefiner)
│ │ │ │ +
static bool assignComponentTopology(TopologyRefiner &newRefiner, MESH const &mesh)
Specify the relationships between vertices, faces, etc. ie the face-vertices, vertex-faces,...
│ │ │ │ +
static void reportInvalidTopology(TopologyError errCode, char const *msg, MESH const &mesh)
(Optional) Control run-time topology validation and error reporting
│ │ │ │ +
static LocalIndexArray getBaseVertexFaceLocalIndices(TopologyRefiner &newRefiner, Index v)
Assign the local indices of a vertex within each of its incident faces.
│ │ │ │ +
static int getNumBaseVertices(TopologyRefiner const &newRefiner)
│ │ │ │ +
static void setNumBaseEdgeFaces(TopologyRefiner &newRefiner, Index e, int count)
Specify the number of faces incident each edge.
│ │ │ │ +
static IndexArray getBaseFaceVertices(TopologyRefiner &newRefiner, Index f)
Assign the vertices incident each face.
│ │ │ │ +
static LocalIndexArray getBaseEdgeFaceLocalIndices(TopologyRefiner &newRefiner, Index e)
Assign the local indices of an edge within each of its incident faces.
│ │ │ │ +
static bool populateBaseLevel(TopologyRefiner &refiner, MESH const &mesh, Options options)
│ │ │ │ +
static void populateBaseLocalIndices(TopologyRefiner &newRefiner)
Determine all local indices by inspection (only for pure manifold meshes)
│ │ │ │ +
static bool assignComponentTags(TopologyRefiner &newRefiner, MESH const &mesh)
(Optional) Specify edge or vertex sharpness or face holes
│ │ │ │ +
static bool resizeComponentTopology(TopologyRefiner &newRefiner, MESH const &mesh)
Specify the number of vertices, faces, face-vertices, etc.
│ │ │ │ +
static void setNumBaseVertexEdges(TopologyRefiner &newRefiner, Index v, int count)
Specify the number of edges incident each vertex.
│ │ │ │ + │ │ │ │ +
static IndexArray getBaseFaceFVarValues(TopologyRefiner &newRefiner, Index face, int channel=0)
Assign the face-varying values for the corners of each face.
│ │ │ │ +
static IndexArray getBaseEdgeFaces(TopologyRefiner &newRefiner, Index e)
Assign the faces incident each edge.
│ │ │ │ +
static void setNumBaseVertexFaces(TopologyRefiner &newRefiner, Index v, int count)
Specify the number of faces incident each vertex.
│ │ │ │ +
static bool assignFaceVaryingTopology(TopologyRefiner &newRefiner, MESH const &mesh)
(Optional) Specify face-varying data per face
│ │ │ │ +
static void setBaseVertexSharpness(TopologyRefiner &newRefiner, Index v, float sharpness)
Assign a sharpness value to a given vertex.
│ │ │ │ +
static LocalIndexArray getBaseVertexEdgeLocalIndices(TopologyRefiner &newRefiner, Index v)
Assign the local indices of a vertex within each of its incident edges.
│ │ │ │ +
static IndexArray getBaseEdgeVertices(TopologyRefiner &newRefiner, Index e)
Assign the vertices incident each edge.
│ │ │ │ +
static IndexArray getBaseVertexFaces(TopologyRefiner &newRefiner, Index v)
Assign the faces incident each vertex.
│ │ │ │ +
static void setBaseVertexNonManifold(TopologyRefiner &newRefiner, Index v, bool b)
Tag a vertex as non-manifold.
│ │ │ │ +
static void setNumBaseFaces(TopologyRefiner &newRefiner, int count)
Specify the number of faces to be accommodated.
│ │ │ │ +
static IndexArray getBaseFaceEdges(TopologyRefiner &newRefiner, Index f)
Assign the edges incident each face.
│ │ │ │ +
static void setNumBaseFaceVertices(TopologyRefiner &newRefiner, Index f, int count)
Specify the number of vertices incident each face.
│ │ │ │ +
static void setBaseEdgeSharpness(TopologyRefiner &newRefiner, Index e, float sharpness)
Assign a sharpness value to a given edge.
│ │ │ │ +
static void setBaseEdgeNonManifold(TopologyRefiner &newRefiner, Index e, bool b)
Tag an edge as non-manifold.
│ │ │ │ +
static void setNumBaseEdges(TopologyRefiner &newRefiner, int count)
Specify the number of edges to be accommodated.
│ │ │ │ +
static TopologyRefiner * Create(MESH const &mesh, Options options=Options())
Instantiates a TopologyRefiner from client-provided topological representation.
│ │ │ │ +
static Index findBaseEdge(TopologyRefiner const &newRefiner, Index v0, Index v1)
Identify an edge to be assigned a sharpness value given a vertex pair.
│ │ │ │ +
static IndexArray getBaseVertexEdges(TopologyRefiner &newRefiner, Index v)
Assign the edges incident each vertex.
│ │ │ │ +
static int createBaseFVarChannel(TopologyRefiner &newRefiner, int numValues)
Create a new face-varying channel with the given number of values.
│ │ │ │ +
static int getNumBaseEdges(TopologyRefiner const &newRefiner)
│ │ │ │ +
static void setNumBaseVertices(TopologyRefiner &newRefiner, int count)
Specify the number of vertices to be accommodated.
│ │ │ │ +
static void setBaseFaceHole(TopologyRefiner &newRefiner, Index f, bool isHole)
Tag a face as a hole.
│ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │ +
Private base class of Factories for constructing TopologyRefiners.
│ │ │ │ +
static bool prepareComponentTopologyAssignment(TopologyRefiner &refiner, bool fullValidation, TopologyCallback callback, void const *callbackData)
│ │ │ │ + │ │ │ │ +
static bool prepareComponentTagsAndSharpness(TopologyRefiner &refiner)
│ │ │ │ +
static bool prepareComponentTopologySizing(TopologyRefiner &refiner)
│ │ │ │ +
static bool prepareFaceVaryingChannels(TopologyRefiner &refiner)
│ │ │ │ +
Options related to the construction of each TopologyRefiner.
│ │ │ │ +
Options(Sdc::SchemeType sdcType=Sdc::SCHEME_CATMARK, Sdc::Options sdcOptions=Sdc::Options())
│ │ │ │ + │ │ │ │ +
Sdc::SchemeType schemeType
The subdivision scheme type identifier.
│ │ │ │ + │ │ │ │ +
All supported options applying to subdivision scheme.
Definition options.h:51
│ │ │ │ +
void SetFVarLinearInterpolation(FVarLinearInterpolation b)
Set face-varying interpolation rule.
Definition options.h:98
│ │ │ │ +
FVarLinearInterpolation GetFVarLinearInterpolation() const
Get face-varying interpolation rule.
Definition options.h:95
│ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -topologyLevel.h │ │ │ │ │ +topologyRefinerFactory.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2015 DreamWorks Animation LLC. │ │ │ │ │ +2// Copyright 2014 DreamWorks Animation LLC. │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,387 +23,931 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H │ │ │ │ │ -25#define OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H │ │ │ │ │ +24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_REFINER_FACTORY_H │ │ │ │ │ +25#define OPENSUBDIV3_FAR_TOPOLOGY_REFINER_FACTORY_H │ │ │ │ │ 26 │ │ │ │ │ 27#include "../version.h" │ │ │ │ │ 28 │ │ │ │ │ -29#include "../vtr/level.h" │ │ │ │ │ -30#include "../vtr/refinement.h" │ │ │ │ │ -31#include "../far/types.h" │ │ │ │ │ -32 │ │ │ │ │ -33#include │ │ │ │ │ -34 │ │ │ │ │ -35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -36namespace OPENSUBDIV_VERSION { │ │ │ │ │ -37 │ │ │ │ │ -38namespace Far { │ │ │ │ │ -39 │ │ │ │ │ -_4_9class _T_o_p_o_l_o_g_y_L_e_v_e_l { │ │ │ │ │ -50 │ │ │ │ │ -51public: │ │ │ │ │ -53 │ │ │ │ │ -60 │ │ │ │ │ -_6_2 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s() const { return _level->getNumVertices(); } │ │ │ │ │ +29#include "../far/topologyRefiner.h" │ │ │ │ │ +30#include "../far/error.h" │ │ │ │ │ +31 │ │ │ │ │ +32#include │ │ │ │ │ +33 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Far { │ │ │ │ │ +38 │ │ │ │ │ +46// │ │ │ │ │ +_4_7class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e { │ │ │ │ │ +48protected: │ │ │ │ │ +49 │ │ │ │ │ +50 // │ │ │ │ │ +51 // Protected methods invoked by the subclass template to verify and process │ │ │ │ │ +each │ │ │ │ │ +52 // stage of construction implemented by the subclass: │ │ │ │ │ +53 // │ │ │ │ │ +_5_4 typedef Vtr::internal::Level::ValidationCallback _T_o_p_o_l_o_g_y_C_a_l_l_b_a_c_k; │ │ │ │ │ +55 │ │ │ │ │ +_5_6 static bool _p_r_e_p_a_r_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y_S_i_z_i_n_g(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& refiner); │ │ │ │ │ +_5_7 static bool _p_r_e_p_a_r_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y_A_s_s_i_g_n_m_e_n_t(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& refiner, │ │ │ │ │ +bool fullValidation, │ │ │ │ │ +58 _T_o_p_o_l_o_g_y_C_a_l_l_b_a_c_k callback, void const * callbackData); │ │ │ │ │ +_5_9 static bool _p_r_e_p_a_r_e_C_o_m_p_o_n_e_n_t_T_a_g_s_A_n_d_S_h_a_r_p_n_e_s_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& refiner); │ │ │ │ │ +_6_0 static bool _p_r_e_p_a_r_e_F_a_c_e_V_a_r_y_i_n_g_C_h_a_n_n_e_l_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& refiner); │ │ │ │ │ +61}; │ │ │ │ │ +62 │ │ │ │ │ 63 │ │ │ │ │ -_6_5 int _G_e_t_N_u_m_F_a_c_e_s() const { return _level->getNumFaces(); } │ │ │ │ │ -66 │ │ │ │ │ -_6_8 int _G_e_t_N_u_m_E_d_g_e_s() const { return _level->getNumEdges(); } │ │ │ │ │ -69 │ │ │ │ │ -_7_1 int _G_e_t_N_u_m_F_a_c_e_V_e_r_t_i_c_e_s() const { return _level->getNumFaceVerticesTotal(); } │ │ │ │ │ -73 │ │ │ │ │ -75 │ │ │ │ │ -90 // │ │ │ │ │ -91 │ │ │ │ │ -_9_3 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_V_e_r_t_i_c_e_s(_I_n_d_e_x f) const { return _level- │ │ │ │ │ ->getFaceVertices(f); } │ │ │ │ │ -94 │ │ │ │ │ -_9_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_E_d_g_e_s(_I_n_d_e_x f) const { return _level->getFaceEdges │ │ │ │ │ -(f); } │ │ │ │ │ -97 │ │ │ │ │ -_9_9 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_V_e_r_t_i_c_e_s(_I_n_d_e_x e) const { return _level- │ │ │ │ │ ->getEdgeVertices(e); } │ │ │ │ │ -100 │ │ │ │ │ -_1_0_2 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_F_a_c_e_s(_I_n_d_e_x e) const { return _level->getEdgeFaces │ │ │ │ │ -(e); } │ │ │ │ │ -103 │ │ │ │ │ -_1_0_5 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_F_a_c_e_s(_I_n_d_e_x v) const { return _level- │ │ │ │ │ ->getVertexFaces(v); } │ │ │ │ │ -106 │ │ │ │ │ -_1_0_8 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_E_d_g_e_s(_I_n_d_e_x v) const { return _level- │ │ │ │ │ ->getVertexEdges(v); } │ │ │ │ │ -109 │ │ │ │ │ -_1_1_1 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_I_n_d_e_x v) const { return │ │ │ │ │ -_level->getVertexFaceLocalIndices(v); } │ │ │ │ │ -112 │ │ │ │ │ -_1_1_4 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _G_e_t_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s(_I_n_d_e_x v) const { return │ │ │ │ │ -_level->getVertexEdgeLocalIndices(v); } │ │ │ │ │ -115 │ │ │ │ │ -_1_1_7 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_I_n_d_e_x e) const { return │ │ │ │ │ -_level->getEdgeFaceLocalIndices(e); } │ │ │ │ │ -118 │ │ │ │ │ -_1_2_0 _I_n_d_e_x _F_i_n_d_E_d_g_e(_I_n_d_e_x v0, _I_n_d_e_x v1) const { return _level->findEdge(v0, v1); │ │ │ │ │ -} │ │ │ │ │ -122 │ │ │ │ │ -124 │ │ │ │ │ -126 │ │ │ │ │ -_1_2_8 bool _I_s_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d(_I_n_d_e_x e) const { return _level->isEdgeNonManifold │ │ │ │ │ -(e); } │ │ │ │ │ +77template │ │ │ │ │ +_7_8class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y : public _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e { │ │ │ │ │ +79 │ │ │ │ │ +80public: │ │ │ │ │ +81 │ │ │ │ │ +_8_4 struct _O_p_t_i_o_n_s { │ │ │ │ │ +85 │ │ │ │ │ +_8_6 _O_p_t_i_o_n_s(_S_d_c_:_:_S_c_h_e_m_e_T_y_p_e sdcType = _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K, _S_d_c_:_:_O_p_t_i_o_n_s │ │ │ │ │ +sdcOptions = _S_d_c_:_:_O_p_t_i_o_n_s()) : │ │ │ │ │ +87 _s_c_h_e_m_e_T_y_p_e(sdcType), │ │ │ │ │ +88 _s_c_h_e_m_e_O_p_t_i_o_n_s(sdcOptions), │ │ │ │ │ +89 _v_a_l_i_d_a_t_e_F_u_l_l_T_o_p_o_l_o_g_y(false) { } │ │ │ │ │ +90 │ │ │ │ │ +_9_1 _S_d_c_:_:_S_c_h_e_m_e_T_y_p_e _s_c_h_e_m_e_T_y_p_e; │ │ │ │ │ +_9_2 _S_d_c_:_:_O_p_t_i_o_n_s _s_c_h_e_m_e_O_p_t_i_o_n_s; │ │ │ │ │ +_9_4 unsigned int _v_a_l_i_d_a_t_e_F_u_l_l_T_o_p_o_l_o_g_y : 1; │ │ │ │ │ +97 }; │ │ │ │ │ +98 │ │ │ │ │ +108 // │ │ │ │ │ +113 static _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r* _C_r_e_a_t_e(MESH const& mesh, _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s │ │ │ │ │ +()); │ │ │ │ │ +114 │ │ │ │ │ +128 static _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r* _C_r_e_a_t_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & baseLevel); │ │ │ │ │ 129 │ │ │ │ │ -_1_3_1 bool _I_s_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d(_I_n_d_e_x v) const { return _level- │ │ │ │ │ ->isVertexNonManifold(v); } │ │ │ │ │ +130protected: │ │ │ │ │ +_1_3_1 typedef Vtr::internal::Level::TopologyError _T_o_p_o_l_o_g_y_E_r_r_o_r; │ │ │ │ │ 132 │ │ │ │ │ -_1_3_4 bool _I_s_E_d_g_e_B_o_u_n_d_a_r_y(_I_n_d_e_x e) const { return _level->getEdgeTag │ │ │ │ │ -(e)._boundary; } │ │ │ │ │ -135 │ │ │ │ │ -_1_3_7 bool _I_s_V_e_r_t_e_x_B_o_u_n_d_a_r_y(_I_n_d_e_x v) const { return _level->getVertexTag │ │ │ │ │ -(v)._boundary; } │ │ │ │ │ -138 │ │ │ │ │ -_1_4_0 bool _I_s_V_e_r_t_e_x_C_o_r_n_e_r(_I_n_d_e_x v) const { return (_level->getNumVertexFaces(v) │ │ │ │ │ -== 1); } │ │ │ │ │ -141 │ │ │ │ │ -_1_6_2 bool _I_s_V_e_r_t_e_x_V_a_l_e_n_c_e_R_e_g_u_l_a_r(_I_n_d_e_x v) const { return !_level->getVertexTag │ │ │ │ │ -(v)._xordinary || _I_s_V_e_r_t_e_x_C_o_r_n_e_r(v); } │ │ │ │ │ -164 │ │ │ │ │ -166 │ │ │ │ │ -171 │ │ │ │ │ -_1_7_3 float _G_e_t_E_d_g_e_S_h_a_r_p_n_e_s_s(_I_n_d_e_x e) const { return _level->getEdgeSharpness(e); │ │ │ │ │ -} │ │ │ │ │ -174 │ │ │ │ │ -_1_7_6 float _G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(_I_n_d_e_x v) const { return _level->getVertexSharpness │ │ │ │ │ -(v); } │ │ │ │ │ -177 │ │ │ │ │ -_1_7_9 bool _I_s_E_d_g_e_I_n_f_S_h_a_r_p(_I_n_d_e_x e) const { return _level->getEdgeTag │ │ │ │ │ -(e)._infSharp; } │ │ │ │ │ -180 │ │ │ │ │ -_1_8_2 bool _I_s_V_e_r_t_e_x_I_n_f_S_h_a_r_p(_I_n_d_e_x v) const { return _level->getVertexTag │ │ │ │ │ -(v)._infSharp; } │ │ │ │ │ -183 │ │ │ │ │ -_1_8_5 bool _I_s_E_d_g_e_S_e_m_i_S_h_a_r_p(_I_n_d_e_x e) const { return _level->getEdgeTag │ │ │ │ │ -(e)._semiSharp; } │ │ │ │ │ -186 │ │ │ │ │ -_1_8_8 bool _I_s_V_e_r_t_e_x_S_e_m_i_S_h_a_r_p(_I_n_d_e_x v) const { return _level->getVertexTag │ │ │ │ │ -(v)._semiSharp; } │ │ │ │ │ -189 │ │ │ │ │ -_1_9_1 bool _I_s_F_a_c_e_H_o_l_e(_I_n_d_e_x f) const { return _level->isFaceHole(f); } │ │ │ │ │ -192 │ │ │ │ │ -_1_9_4 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e _G_e_t_V_e_r_t_e_x_R_u_l_e(_I_n_d_e_x v) const { return _level- │ │ │ │ │ ->getVertexRule(v); } │ │ │ │ │ +134 │ │ │ │ │ +149 │ │ │ │ │ +151 static bool _r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& newRefiner, MESH │ │ │ │ │ +const& mesh); │ │ │ │ │ +152 │ │ │ │ │ +155 static bool _a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& newRefiner, MESH │ │ │ │ │ +const& mesh); │ │ │ │ │ +156 │ │ │ │ │ +158 static bool _a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& newRefiner, MESH const& │ │ │ │ │ +mesh); │ │ │ │ │ +159 │ │ │ │ │ +161 static bool _a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& newRefiner, MESH │ │ │ │ │ +const& mesh); │ │ │ │ │ +162 │ │ │ │ │ +164 static void _r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y(TopologyError errCode, char const * msg, │ │ │ │ │ +MESH const& mesh); │ │ │ │ │ +165 │ │ │ │ │ +167 │ │ │ │ │ +168protected: │ │ │ │ │ +170 │ │ │ │ │ +187 │ │ │ │ │ +189 static void _s_e_t_N_u_m_B_a_s_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, int count); │ │ │ │ │ +190 │ │ │ │ │ +192 static void _s_e_t_N_u_m_B_a_s_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, int count); │ │ │ │ │ +193 │ │ │ │ │ +195 static void _s_e_t_N_u_m_B_a_s_e_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, int count); │ │ │ │ │ 196 │ │ │ │ │ -198 │ │ │ │ │ -228 │ │ │ │ │ -_2_3_0 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const { return _level->getNumFVarChannels(); } │ │ │ │ │ -231 │ │ │ │ │ -_2_3_4 int _G_e_t_N_u_m_F_V_a_r_V_a_l_u_e_s(int channel = 0) const { return _level- │ │ │ │ │ ->getNumFVarValues(channel); } │ │ │ │ │ -235 │ │ │ │ │ -_2_3_7 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_F_V_a_r_V_a_l_u_e_s(_I_n_d_e_x f, int channel = 0) const { │ │ │ │ │ -238 return _level->getFaceFVarValues(f, channel); │ │ │ │ │ -239 } │ │ │ │ │ +198 static void _s_e_t_N_u_m_B_a_s_e_F_a_c_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x f, │ │ │ │ │ +int count); │ │ │ │ │ +199 │ │ │ │ │ +201 static void _s_e_t_N_u_m_B_a_s_e_E_d_g_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x e, int │ │ │ │ │ +count); │ │ │ │ │ +202 │ │ │ │ │ +204 static void _s_e_t_N_u_m_B_a_s_e_V_e_r_t_e_x_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x v, │ │ │ │ │ +int count); │ │ │ │ │ +205 │ │ │ │ │ +207 static void _s_e_t_N_u_m_B_a_s_e_V_e_r_t_e_x_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x v, │ │ │ │ │ +int count); │ │ │ │ │ +208 │ │ │ │ │ +209 static int _g_e_t_N_u_m_B_a_s_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & newRefiner); │ │ │ │ │ +210 static int _g_e_t_N_u_m_B_a_s_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & newRefiner); │ │ │ │ │ +211 static int _g_e_t_N_u_m_B_a_s_e_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & newRefiner); │ │ │ │ │ +213 │ │ │ │ │ +215 │ │ │ │ │ +237 │ │ │ │ │ +239 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_F_a_c_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x │ │ │ │ │ +f); │ │ │ │ │ 240 │ │ │ │ │ -_2_4_2 bool _D_o_e_s_V_e_r_t_e_x_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h(_I_n_d_e_x v, int channel = 0) const { │ │ │ │ │ -243 return _level->doesVertexFVarTopologyMatch(v, channel); │ │ │ │ │ -244 } │ │ │ │ │ -245 │ │ │ │ │ -_2_4_7 bool _D_o_e_s_E_d_g_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h(_I_n_d_e_x e, int channel = 0) const { │ │ │ │ │ -248 return _level->doesEdgeFVarTopologyMatch(e, channel); │ │ │ │ │ -249 } │ │ │ │ │ -250 │ │ │ │ │ -_2_5_2 bool _D_o_e_s_F_a_c_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h(_I_n_d_e_x f, int channel = 0) const { │ │ │ │ │ -253 return _level->doesFaceFVarTopologyMatch(f, channel); │ │ │ │ │ -254 } │ │ │ │ │ +242 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_F_a_c_e_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x f); │ │ │ │ │ +243 │ │ │ │ │ +245 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_E_d_g_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x │ │ │ │ │ +e); │ │ │ │ │ +246 │ │ │ │ │ +248 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_E_d_g_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x e); │ │ │ │ │ +249 │ │ │ │ │ +251 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_V_e_r_t_e_x_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x │ │ │ │ │ +v); │ │ │ │ │ +252 │ │ │ │ │ +254 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_V_e_r_t_e_x_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x │ │ │ │ │ +v); │ │ │ │ │ 255 │ │ │ │ │ -257 │ │ │ │ │ -259 │ │ │ │ │ -260 │ │ │ │ │ -_2_6_2 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_C_h_i_l_d_F_a_c_e_s(_I_n_d_e_x f) const { return _refToChild- │ │ │ │ │ ->getFaceChildFaces(f); } │ │ │ │ │ -263 │ │ │ │ │ -_2_6_5 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_a_c_e_C_h_i_l_d_E_d_g_e_s(_I_n_d_e_x f) const { return _refToChild- │ │ │ │ │ ->getFaceChildEdges(f); } │ │ │ │ │ -266 │ │ │ │ │ -_2_6_8 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_E_d_g_e_C_h_i_l_d_E_d_g_e_s(_I_n_d_e_x e) const { return _refToChild- │ │ │ │ │ ->getEdgeChildEdges(e); } │ │ │ │ │ -269 │ │ │ │ │ -_2_7_1 _I_n_d_e_x _G_e_t_F_a_c_e_C_h_i_l_d_V_e_r_t_e_x( _I_n_d_e_x f) const { return _refToChild- │ │ │ │ │ ->getFaceChildVertex(f); } │ │ │ │ │ +257 static _L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v); │ │ │ │ │ +259 static _L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v); │ │ │ │ │ +261 static _L_o_c_a_l_I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x e); │ │ │ │ │ +262 │ │ │ │ │ +264 static void _p_o_p_u_l_a_t_e_B_a_s_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner); │ │ │ │ │ +265 │ │ │ │ │ +267 static void _s_e_t_B_a_s_e_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x e, │ │ │ │ │ +bool b); │ │ │ │ │ +268 │ │ │ │ │ +270 static void _s_e_t_B_a_s_e_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x v, │ │ │ │ │ +bool b); │ │ │ │ │ 272 │ │ │ │ │ -_2_7_4 _I_n_d_e_x _G_e_t_E_d_g_e_C_h_i_l_d_V_e_r_t_e_x( _I_n_d_e_x e) const { return _refToChild- │ │ │ │ │ ->getEdgeChildVertex(e); } │ │ │ │ │ -275 │ │ │ │ │ -_2_7_7 _I_n_d_e_x _G_e_t_V_e_r_t_e_x_C_h_i_l_d_V_e_r_t_e_x(_I_n_d_e_x v) const { return _refToChild- │ │ │ │ │ ->getVertexChildVertex(v); } │ │ │ │ │ -278 │ │ │ │ │ -_2_8_0 _I_n_d_e_x _G_e_t_F_a_c_e_P_a_r_e_n_t_F_a_c_e(_I_n_d_e_x f) const { return _refToParent- │ │ │ │ │ ->getChildFaceParentFace(f); } │ │ │ │ │ -282 │ │ │ │ │ -284 │ │ │ │ │ -285 │ │ │ │ │ -_2_8_6 bool _V_a_l_i_d_a_t_e_T_o_p_o_l_o_g_y() const { return _level->validateTopology(); } │ │ │ │ │ -_2_8_7 void _P_r_i_n_t_T_o_p_o_l_o_g_y(bool children = true) const { _level->print((children && │ │ │ │ │ -_refToChild) ? _refToChild : 0); } │ │ │ │ │ +274 │ │ │ │ │ +283 │ │ │ │ │ +285 static _I_n_d_e_x _f_i_n_d_B_a_s_e_E_d_g_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & newRefiner, _I_n_d_e_x v0, │ │ │ │ │ +_I_n_d_e_x v1); │ │ │ │ │ +286 │ │ │ │ │ +288 static void _s_e_t_B_a_s_e_E_d_g_e_S_h_a_r_p_n_e_s_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x e, │ │ │ │ │ +float sharpness); │ │ │ │ │ 289 │ │ │ │ │ -290 │ │ │ │ │ -291private: │ │ │ │ │ -_2_9_2 friend class _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r; │ │ │ │ │ -293 │ │ │ │ │ -294 Vtr::internal::Level const * _level; │ │ │ │ │ -295 Vtr::internal::Refinement const * _refToParent; │ │ │ │ │ -296 Vtr::internal::Refinement const * _refToChild; │ │ │ │ │ -297 │ │ │ │ │ -298public: │ │ │ │ │ -299 // Not intended for public use, but required by std::vector, etc... │ │ │ │ │ -_3_0_0 _T_o_p_o_l_o_g_y_L_e_v_e_l() { } │ │ │ │ │ -_3_0_1 _~_T_o_p_o_l_o_g_y_L_e_v_e_l() { } │ │ │ │ │ -302}; │ │ │ │ │ -303 │ │ │ │ │ -304} // end namespace Far │ │ │ │ │ -305 │ │ │ │ │ -306} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -307using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -308} // end namespace OpenSubdiv │ │ │ │ │ -309 │ │ │ │ │ -310#endif /* OPENSUBDIV3_FAR_TOPOLOGY_LEVEL_H */ │ │ │ │ │ +291 static void _s_e_t_B_a_s_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x v, │ │ │ │ │ +float sharpness); │ │ │ │ │ +292 │ │ │ │ │ +294 static void _s_e_t_B_a_s_e_F_a_c_e_H_o_l_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x f, bool │ │ │ │ │ +isHole); │ │ │ │ │ +296 │ │ │ │ │ +298 │ │ │ │ │ +308 │ │ │ │ │ +310 static int _c_r_e_a_t_e_B_a_s_e_F_V_a_r_C_h_a_n_n_e_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, int │ │ │ │ │ +numValues); │ │ │ │ │ +311 │ │ │ │ │ +313 static int _c_r_e_a_t_e_B_a_s_e_F_V_a_r_C_h_a_n_n_e_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, int │ │ │ │ │ +numValues, _S_d_c_:_:_O_p_t_i_o_n_s const& fvarOptions); │ │ │ │ │ +314 │ │ │ │ │ +316 static _I_n_d_e_x_A_r_r_a_y _g_e_t_B_a_s_e_F_a_c_e_F_V_a_r_V_a_l_u_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, _I_n_d_e_x │ │ │ │ │ +face, int channel = 0); │ │ │ │ │ +317 │ │ │ │ │ +319 │ │ │ │ │ +320protected: │ │ │ │ │ +321 // │ │ │ │ │ +322 // Not to be specialized: │ │ │ │ │ +323 // │ │ │ │ │ +324 static bool _p_o_p_u_l_a_t_e_B_a_s_e_L_e_v_e_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& refiner, MESH const& mesh, │ │ │ │ │ +_O_p_t_i_o_n_s options); │ │ │ │ │ +325 │ │ │ │ │ +326private: │ │ │ │ │ +327 // │ │ │ │ │ +328 // An oversight in the interfaces of the error reporting function between │ │ │ │ │ +the factory │ │ │ │ │ +329 // class and the Vtr::Level requires this adapter function to avoid │ │ │ │ │ +warnings. │ │ │ │ │ +330 // │ │ │ │ │ +331 // The static class method requires a reference as the MESH argument, but │ │ │ │ │ +the interface │ │ │ │ │ +332 // for Vtr::Level requires a pointer (void*). So this adapter with a MESH* │ │ │ │ │ +argument is │ │ │ │ │ +333 // used to effectively cast the function pointer required by Vtr::Level │ │ │ │ │ +error reporting: │ │ │ │ │ +334 // │ │ │ │ │ +335 static void reportInvalidTopologyAdapter(TopologyError errCode, char const │ │ │ │ │ +* msg, MESH const * mesh) { │ │ │ │ │ +336 _r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y(errCode, msg, *mesh); │ │ │ │ │ +337 } │ │ │ │ │ +338}; │ │ │ │ │ +339 │ │ │ │ │ +340 │ │ │ │ │ +341// │ │ │ │ │ +342// Generic implementations: │ │ │ │ │ +343// │ │ │ │ │ +344template │ │ │ │ │ +345TopologyRefiner* │ │ │ │ │ +_3_4_6_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_C_r_e_a_t_e(MESH const& mesh, _O_p_t_i_o_n_s options) { │ │ │ │ │ +347 │ │ │ │ │ +348 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r * refiner = new _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r(options._s_c_h_e_m_e_T_y_p_e, │ │ │ │ │ +options._s_c_h_e_m_e_O_p_t_i_o_n_s); │ │ │ │ │ +349 │ │ │ │ │ +350 if (! populateBaseLevel(*refiner, mesh, options)) { │ │ │ │ │ +351 delete refiner; │ │ │ │ │ +352 return 0; │ │ │ │ │ +353 } │ │ │ │ │ +354 │ │ │ │ │ +355 // Eventually want to move the Refiner's inventory initialization here. │ │ │ │ │ +Currently it │ │ │ │ │ +356 // is handled after topology assignment, but if the inventory is to include │ │ │ │ │ +additional │ │ │ │ │ +357 // features (e.g. holes, etc.) it is better off deferred to here. │ │ │ │ │ +358 │ │ │ │ │ +359 return refiner; │ │ │ │ │ +360} │ │ │ │ │ +361 │ │ │ │ │ +362template │ │ │ │ │ +363_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r* │ │ │ │ │ +_3_6_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_C_r_e_a_t_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & source) { │ │ │ │ │ +365 │ │ │ │ │ +366 return new _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r(source); │ │ │ │ │ +367} │ │ │ │ │ +368 │ │ │ │ │ +369template │ │ │ │ │ +370bool │ │ │ │ │ +_3_7_1_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_p_o_p_u_l_a_t_e_B_a_s_e_L_e_v_e_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& refiner, │ │ │ │ │ +MESH const& mesh, _O_p_t_i_o_n_s options) { │ │ │ │ │ +372 │ │ │ │ │ +373 // │ │ │ │ │ +374 // Construction of a specialized topology refiner involves four steps, each │ │ │ │ │ +of which │ │ │ │ │ +375 // involves a method specialized for MESH followed by one that takes an │ │ │ │ │ +action in │ │ │ │ │ +376 // response to it or in preparation for the next step. │ │ │ │ │ +377 // │ │ │ │ │ +378 // Both the specialized methods and those that follow them may find fault │ │ │ │ │ +in the │ │ │ │ │ +379 // construction and trigger failure at any time: │ │ │ │ │ +380 // │ │ │ │ │ +381 │ │ │ │ │ +382 // │ │ │ │ │ +383 // Sizing of the topology -- this is a required specialization for MESH. │ │ │ │ │ +This defines │ │ │ │ │ +384 // an inventory of all components and their relations that is used to │ │ │ │ │ +allocate buffers │ │ │ │ │ +385 // to be efficiently populated in the subsequent topology assignment step. │ │ │ │ │ +386 // │ │ │ │ │ +387 if (! resizeComponentTopology(refiner, mesh)) return false; │ │ │ │ │ +388 if (! prepareComponentTopologySizing(refiner)) return false; │ │ │ │ │ +389 │ │ │ │ │ +390 // │ │ │ │ │ +391 // Assignment of the topology -- this is a required specialization for │ │ │ │ │ +MESH. If edges │ │ │ │ │ +392 // are specified, all other topological relations are expected to be │ │ │ │ │ +defined for them. │ │ │ │ │ +393 // Otherwise edges and remaining topology will be completed from the face- │ │ │ │ │ +vertices: │ │ │ │ │ +394 // │ │ │ │ │ +395 bool validate = options._v_a_l_i_d_a_t_e_F_u_l_l_T_o_p_o_l_o_g_y; │ │ │ │ │ +396 _T_o_p_o_l_o_g_y_C_a_l_l_b_a_c_k callback = reinterpret_cast<_T_o_p_o_l_o_g_y_C_a_l_l_b_a_c_k> │ │ │ │ │ +(reportInvalidTopologyAdapter); │ │ │ │ │ +397 void const * userData = &mesh; │ │ │ │ │ +398 │ │ │ │ │ +399 if (! assignComponentTopology(refiner, mesh)) return false; │ │ │ │ │ +400 if (! prepareComponentTopologyAssignment(refiner, validate, callback, │ │ │ │ │ +userData)) return false; │ │ │ │ │ +401 │ │ │ │ │ +402 // │ │ │ │ │ +403 // User assigned and internal tagging of components -- an optional │ │ │ │ │ +specialization for │ │ │ │ │ +404 // MESH. Allows the specification of sharpness values, holes, etc. │ │ │ │ │ +405 // │ │ │ │ │ +406 if (! assignComponentTags(refiner, mesh)) return false; │ │ │ │ │ +407 if (! prepareComponentTagsAndSharpness(refiner)) return false; │ │ │ │ │ +408 │ │ │ │ │ +409 // │ │ │ │ │ +410 // Defining channels of face-varying primvar data -- an optional │ │ │ │ │ +specialization for MESH. │ │ │ │ │ +411 // │ │ │ │ │ +412 if (! assignFaceVaryingTopology(refiner, mesh)) return false; │ │ │ │ │ +413 if (! prepareFaceVaryingChannels(refiner)) return false; │ │ │ │ │ +414 │ │ │ │ │ +415 return true; │ │ │ │ │ +416} │ │ │ │ │ +417 │ │ │ │ │ +418template │ │ │ │ │ +419inline void │ │ │ │ │ +_4_2_0_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, │ │ │ │ │ +int count) { │ │ │ │ │ +421 newRefiner._levels[0]->resizeFaces(count); │ │ │ │ │ +422} │ │ │ │ │ +423template │ │ │ │ │ +424inline void │ │ │ │ │ +_4_2_5_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, │ │ │ │ │ +int count) { │ │ │ │ │ +426 newRefiner._levels[0]->resizeEdges(count); │ │ │ │ │ +427} │ │ │ │ │ +428template │ │ │ │ │ +429inline void │ │ │ │ │ +_4_3_0_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, int count) { │ │ │ │ │ +431 newRefiner._levels[0]->resizeVertices(count); │ │ │ │ │ +432} │ │ │ │ │ +433 │ │ │ │ │ +434template │ │ │ │ │ +435inline int │ │ │ │ │ +_4_3_6_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_N_u_m_B_a_s_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & │ │ │ │ │ +newRefiner) { │ │ │ │ │ +437 return newRefiner._levels[0]->getNumFaces(); │ │ │ │ │ +438} │ │ │ │ │ +439template │ │ │ │ │ +440inline int │ │ │ │ │ +_4_4_1_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_N_u_m_B_a_s_e_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & │ │ │ │ │ +newRefiner) { │ │ │ │ │ +442 return newRefiner._levels[0]->getNumEdges(); │ │ │ │ │ +443} │ │ │ │ │ +444template │ │ │ │ │ +445inline int │ │ │ │ │ +_4_4_6_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_N_u_m_B_a_s_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & │ │ │ │ │ +newRefiner) { │ │ │ │ │ +447 return newRefiner._levels[0]->getNumVertices(); │ │ │ │ │ +448} │ │ │ │ │ +449 │ │ │ │ │ +450template │ │ │ │ │ +451inline void │ │ │ │ │ +_4_5_2_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_F_a_c_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x f, int count) { │ │ │ │ │ +453 newRefiner._levels[0]->resizeFaceVertices(f, count); │ │ │ │ │ +454 newRefiner._hasIrregFaces = newRefiner._hasIrregFaces || (count != │ │ │ │ │ +newRefiner._regFaceSize); │ │ │ │ │ +455} │ │ │ │ │ +456template │ │ │ │ │ +457inline void │ │ │ │ │ +_4_5_8_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_E_d_g_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x e, int count) { │ │ │ │ │ +459 newRefiner._levels[0]->resizeEdgeFaces(e, count); │ │ │ │ │ +460} │ │ │ │ │ +461template │ │ │ │ │ +462inline void │ │ │ │ │ +_4_6_3_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_V_e_r_t_e_x_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v, int count) { │ │ │ │ │ +464 newRefiner._levels[0]->resizeVertexFaces(v, count); │ │ │ │ │ +465} │ │ │ │ │ +466template │ │ │ │ │ +467inline void │ │ │ │ │ +_4_6_8_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_N_u_m_B_a_s_e_V_e_r_t_e_x_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v, int count) { │ │ │ │ │ +469 newRefiner._levels[0]->resizeVertexEdges(v, count); │ │ │ │ │ +470} │ │ │ │ │ +471 │ │ │ │ │ +472template │ │ │ │ │ +473inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_4_7_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_F_a_c_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x f) { │ │ │ │ │ +475 return newRefiner._levels[0]->getFaceVertices(f); │ │ │ │ │ +476} │ │ │ │ │ +477template │ │ │ │ │ +478inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_4_7_9_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_F_a_c_e_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, │ │ │ │ │ +_I_n_d_e_x f) { │ │ │ │ │ +480 return newRefiner._levels[0]->getFaceEdges(f); │ │ │ │ │ +481} │ │ │ │ │ +482template │ │ │ │ │ +483inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_4_8_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_E_d_g_e_V_e_r_t_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x e) { │ │ │ │ │ +485 return newRefiner._levels[0]->getEdgeVertices(e); │ │ │ │ │ +486} │ │ │ │ │ +487template │ │ │ │ │ +488inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_4_8_9_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_E_d_g_e_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, │ │ │ │ │ +_I_n_d_e_x e) { │ │ │ │ │ +490 return newRefiner._levels[0]->getEdgeFaces(e); │ │ │ │ │ +491} │ │ │ │ │ +492template │ │ │ │ │ +493inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_4_9_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_V_e_r_t_e_x_F_a_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v) { │ │ │ │ │ +495 return newRefiner._levels[0]->getVertexFaces(v); │ │ │ │ │ +496} │ │ │ │ │ +497template │ │ │ │ │ +498inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_4_9_9_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_V_e_r_t_e_x_E_d_g_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v) { │ │ │ │ │ +500 return newRefiner._levels[0]->getVertexEdges(v); │ │ │ │ │ +501} │ │ │ │ │ +502 │ │ │ │ │ +503template │ │ │ │ │ +504inline _L_o_c_a_l_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_5_0_5_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x e) { │ │ │ │ │ +506 return newRefiner._levels[0]->getEdgeFaceLocalIndices(e); │ │ │ │ │ +507} │ │ │ │ │ +508template │ │ │ │ │ +509inline _L_o_c_a_l_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_5_1_0_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ +& newRefiner, _I_n_d_e_x v) { │ │ │ │ │ +511 return newRefiner._levels[0]->getVertexFaceLocalIndices(v); │ │ │ │ │ +512} │ │ │ │ │ +513template │ │ │ │ │ +514inline _L_o_c_a_l_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_5_1_5_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ +& newRefiner, _I_n_d_e_x v) { │ │ │ │ │ +516 return newRefiner._levels[0]->getVertexEdgeLocalIndices(v); │ │ │ │ │ +517} │ │ │ │ │ +518 │ │ │ │ │ +519template │ │ │ │ │ +520inline _I_n_d_e_x │ │ │ │ │ +_5_2_1_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_f_i_n_d_B_a_s_e_E_d_g_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & │ │ │ │ │ +newRefiner, _I_n_d_e_x v0, _I_n_d_e_x v1) { │ │ │ │ │ +522 return newRefiner._levels[0]->findEdge(v0, v1); │ │ │ │ │ +523} │ │ │ │ │ +524 │ │ │ │ │ +525template │ │ │ │ │ +526inline void │ │ │ │ │ +_5_2_7_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_p_o_p_u_l_a_t_e_B_a_s_e_L_o_c_a_l_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner) { │ │ │ │ │ +528 newRefiner._levels[0]->populateLocalIndices(); │ │ │ │ │ +529} │ │ │ │ │ +530 │ │ │ │ │ +531template │ │ │ │ │ +532inline void │ │ │ │ │ +_5_3_3_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_B_a_s_e_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x e, bool b) { │ │ │ │ │ +534 newRefiner._levels[0]->setEdgeNonManifold(e, b); │ │ │ │ │ +535} │ │ │ │ │ +536template │ │ │ │ │ +537inline void │ │ │ │ │ +_5_3_8_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_B_a_s_e_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v, bool b) { │ │ │ │ │ +539 newRefiner._levels[0]->setVertexNonManifold(v, b); │ │ │ │ │ +540} │ │ │ │ │ +541 │ │ │ │ │ +542template │ │ │ │ │ +543inline void │ │ │ │ │ +_5_4_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_B_a_s_e_E_d_g_e_S_h_a_r_p_n_e_s_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x e, float s) { │ │ │ │ │ +545 newRefiner._levels[0]->getEdgeSharpness(e) = s; │ │ │ │ │ +546} │ │ │ │ │ +547template │ │ │ │ │ +548inline void │ │ │ │ │ +_5_4_9_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_B_a_s_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x v, float s) { │ │ │ │ │ +550 newRefiner._levels[0]->getVertexSharpness(v) = s; │ │ │ │ │ +551} │ │ │ │ │ +552template │ │ │ │ │ +553inline void │ │ │ │ │ +_5_5_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_s_e_t_B_a_s_e_F_a_c_e_H_o_l_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & newRefiner, │ │ │ │ │ +_I_n_d_e_x f, bool b) { │ │ │ │ │ +555 newRefiner._levels[0]->setFaceHole(f, b); │ │ │ │ │ +556 newRefiner._hasHoles = newRefiner._hasHoles || b; │ │ │ │ │ +557} │ │ │ │ │ +558 │ │ │ │ │ +559template │ │ │ │ │ +560inline int │ │ │ │ │ +_5_6_1_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_c_r_e_a_t_e_B_a_s_e_F_V_a_r_C_h_a_n_n_e_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, int numValues) { │ │ │ │ │ +562 return newRefiner._levels[0]->createFVarChannel(numValues, │ │ │ │ │ +newRefiner._subdivOptions); │ │ │ │ │ +563} │ │ │ │ │ +564template │ │ │ │ │ +565inline int │ │ │ │ │ +_5_6_6_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_c_r_e_a_t_e_B_a_s_e_F_V_a_r_C_h_a_n_n_e_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, int numValues, _S_d_c_:_:_O_p_t_i_o_n_s const& fvarOptions) { │ │ │ │ │ +567 _S_d_c_:_:_O_p_t_i_o_n_s newOptions = newRefiner._subdivOptions; │ │ │ │ │ +568 newOptions._S_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ +(fvarOptions._G_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n()); │ │ │ │ │ +569 return newRefiner._levels[0]->createFVarChannel(numValues, newOptions); │ │ │ │ │ +570} │ │ │ │ │ +571template │ │ │ │ │ +572inline _I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +_5_7_3_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_g_e_t_B_a_s_e_F_a_c_e_F_V_a_r_V_a_l_u_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & │ │ │ │ │ +newRefiner, _I_n_d_e_x face, int channel) { │ │ │ │ │ +574 return newRefiner._levels[0]->getFaceFVarValues(face, channel); │ │ │ │ │ +575} │ │ │ │ │ +576 │ │ │ │ │ +577 │ │ │ │ │ +578template │ │ │ │ │ +579bool │ │ │ │ │ +_5_8_0_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& / │ │ │ │ │ +* refiner */, MESH const& /* mesh */) { │ │ │ │ │ +581 │ │ │ │ │ +582 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ +583 "Failure in TopologyRefinerFactory<>::resizeComponentTopology() -- no │ │ │ │ │ +specialization provided."); │ │ │ │ │ +584 │ │ │ │ │ +585 // │ │ │ │ │ +586 // Sizing the topology tables: │ │ │ │ │ +587 // This method is for determining the sizes of the various topology tables │ │ │ │ │ +(and other │ │ │ │ │ +588 // data) associated with the mesh. Once completed, appropriate memory will │ │ │ │ │ +be allocated │ │ │ │ │ +589 // and an additional method invoked to populate it accordingly. │ │ │ │ │ +590 // │ │ │ │ │ +591 // The following methods should be called -- first those to specify the │ │ │ │ │ +number of faces, │ │ │ │ │ +592 // edges and vertices in the mesh: │ │ │ │ │ +593 // │ │ │ │ │ +594 // void setBaseFaceCount( TopologyRefiner& newRefiner, int count) │ │ │ │ │ +595 // void setBaseEdgeCount( TopologyRefiner& newRefiner, int count) │ │ │ │ │ +596 // void setBaseVertexCount(TopologyRefiner& newRefiner, int count) │ │ │ │ │ +597 // │ │ │ │ │ +598 // and then for each face, edge and vertex, the number of its incident │ │ │ │ │ +components: │ │ │ │ │ +599 // │ │ │ │ │ +600 // void setBaseFaceVertexCount(TopologyRefiner& newRefiner, Index face, int │ │ │ │ │ +count) │ │ │ │ │ +601 // void setBaseEdgeFaceCount( TopologyRefiner& newRefiner, Index edge, int │ │ │ │ │ +count) │ │ │ │ │ +602 // void setBaseVertexFaceCount(TopologyRefiner& newRefiner, Index vertex, │ │ │ │ │ +int count) │ │ │ │ │ +603 // void setBaseVertexEdgeCount(TopologyRefiner& newRefiner, Index vertex, │ │ │ │ │ +int count) │ │ │ │ │ +604 // │ │ │ │ │ +605 // The count/size for a component type must be set before indices │ │ │ │ │ +associated with that │ │ │ │ │ +606 // component type can be used. │ │ │ │ │ +607 // │ │ │ │ │ +608 // Note that it is only necessary to size 4 of the 6 supported topological │ │ │ │ │ +relations -- │ │ │ │ │ +609 // the number of edge-vertices is fixed at two per edge, and the number of │ │ │ │ │ +face-edges is │ │ │ │ │ +610 // the same as the number of face-vertices. │ │ │ │ │ +611 // │ │ │ │ │ +612 // So a single pass through your mesh to gather up all of this sizing │ │ │ │ │ +information will │ │ │ │ │ +613 // allow the Tables to be allocated appropriately once and avoid any │ │ │ │ │ +dynamic resizing as │ │ │ │ │ +614 // it grows. │ │ │ │ │ +615 // │ │ │ │ │ +616 return false; │ │ │ │ │ +617} │ │ │ │ │ +618 │ │ │ │ │ +619template │ │ │ │ │ +620bool │ │ │ │ │ +_6_2_1_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& / │ │ │ │ │ +* refiner */, MESH const& /* mesh */) { │ │ │ │ │ +622 │ │ │ │ │ +623 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ +624 "Failure in TopologyRefinerFactory<>::assignComponentTopology() -- no │ │ │ │ │ +specialization provided."); │ │ │ │ │ +625 │ │ │ │ │ +626 // │ │ │ │ │ +627 // Assigning the topology tables: │ │ │ │ │ +628 // Once the topology tables have been allocated, the six required │ │ │ │ │ +topological │ │ │ │ │ +629 // relations can be directly populated using the following methods: │ │ │ │ │ +630 // │ │ │ │ │ +631 // IndexArray setBaseFaceVertices(TopologyRefiner& newRefiner, Index face) │ │ │ │ │ +632 // IndexArray setBaseFaceEdges(TopologyRefiner& newRefiner, Index face) │ │ │ │ │ +633 // │ │ │ │ │ +634 // IndexArray setBaseEdgeVertices(TopologyRefiner& newRefiner, Index edge) │ │ │ │ │ +635 // IndexArray setBaseEdgeFaces(TopologyRefiner& newRefiner, Index edge) │ │ │ │ │ +636 // │ │ │ │ │ +637 // IndexArray setBaseVertexEdges(TopologyRefiner& newRefiner, Index vertex) │ │ │ │ │ +638 // IndexArray setBaseVertexFaces(TopologyRefiner& newRefiner, Index vertex) │ │ │ │ │ +639 // │ │ │ │ │ +640 // For the last two relations -- the faces and edges incident a vertex - │ │ │ │ │ +- there are │ │ │ │ │ +641 // also "local indices" that must be specified (considering doing this │ │ │ │ │ +internally), │ │ │ │ │ +642 // where the "local index" of each incident face or edge is the index of │ │ │ │ │ +the vertex │ │ │ │ │ +643 // within that face or edge, and so ranging from 0-3 for incident quads and │ │ │ │ │ +0-1 for │ │ │ │ │ +644 // incident edges. These are assigned through similarly retrieved arrays: │ │ │ │ │ +645 // │ │ │ │ │ +646 // LocalIndexArray setBaseVertexFaceLocalIndices(TopologyRefiner& │ │ │ │ │ +newRefiner, Index vertex) │ │ │ │ │ +647 // LocalIndexArray setBaseVertexEdgeLocalIndices(TopologyRefiner& │ │ │ │ │ +newRefiner, Index vertex) │ │ │ │ │ +648 // LocalIndexArray setBaseEdgeFaceLocalIndices( TopologyRefiner& │ │ │ │ │ +newRefiner, Index edge) │ │ │ │ │ +649 // │ │ │ │ │ +650 // or, if the mesh is manifold, explicit assignment of these can be │ │ │ │ │ +deferred and │ │ │ │ │ +651 // all can be determined by calling: │ │ │ │ │ +652 // │ │ │ │ │ +653 // void populateBaseLocalIndices(TopologyRefiner& newRefiner) │ │ │ │ │ +654 // │ │ │ │ │ +655 // All components are assumed to be locally manifold and ordering of │ │ │ │ │ +components in │ │ │ │ │ +656 // the above relations is expected to be counter-clockwise. │ │ │ │ │ +657 // │ │ │ │ │ +658 // For non-manifold components, no ordering/orientation of incident │ │ │ │ │ +components is │ │ │ │ │ +659 // assumed or required, but be sure to explicitly tag such components │ │ │ │ │ +(vertices and │ │ │ │ │ +660 // edges) as non-manifold: │ │ │ │ │ +661 // │ │ │ │ │ +662 // void setBaseEdgeNonManifold(TopologyRefiner& newRefiner, Index edge, │ │ │ │ │ +bool b); │ │ │ │ │ +663 // │ │ │ │ │ +664 // void setBaseVertexNonManifold(TopologyRefiner& newRefiner, Index vertex, │ │ │ │ │ +bool b); │ │ │ │ │ +665 // │ │ │ │ │ +666 // Also consider using TopologyLevel::ValidateTopology() when debugging to │ │ │ │ │ +ensure │ │ │ │ │ +667 // that topology has been completely and correctly specified. │ │ │ │ │ +668 // │ │ │ │ │ +669 return false; │ │ │ │ │ +670} │ │ │ │ │ +671 │ │ │ │ │ +672template │ │ │ │ │ +673bool │ │ │ │ │ +_6_7_4_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& / │ │ │ │ │ +* refiner */, MESH const& /* mesh */) { │ │ │ │ │ +675 │ │ │ │ │ +676 // │ │ │ │ │ +677 // Optional assigning face-varying topology tables: │ │ │ │ │ +678 // │ │ │ │ │ +679 // Create independent face-varying primitive variable channels: │ │ │ │ │ +680 // int createBaseFVarChannel(TopologyRefiner& newRefiner, int numValues) │ │ │ │ │ +681 // │ │ │ │ │ +682 // For each channel, populate the face-vertex values: │ │ │ │ │ +683 // IndexArray setBaseFaceFVarValues(TopologyRefiner& newRefiner, Index │ │ │ │ │ +face, int channel = 0) │ │ │ │ │ +684 // │ │ │ │ │ +685 return true; │ │ │ │ │ +686} │ │ │ │ │ +687 │ │ │ │ │ +688template │ │ │ │ │ +689bool │ │ │ │ │ +_6_9_0_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r& / │ │ │ │ │ +* refiner */, MESH const& /* mesh */) { │ │ │ │ │ +691 │ │ │ │ │ +692 // │ │ │ │ │ +693 // Optional tagging: │ │ │ │ │ +694 // This is where any additional feature tags -- sharpness, holes, etc. - │ │ │ │ │ +- can be │ │ │ │ │ +695 // specified using: │ │ │ │ │ +696 // │ │ │ │ │ +697 // void setBaseEdgeSharpness(TopologyRefiner& newRefiner, Index edge, float │ │ │ │ │ +sharpness) │ │ │ │ │ +698 // void setBaseVertexSharpness(TopologyRefiner& newRefiner, Index vertex, │ │ │ │ │ +float sharpness) │ │ │ │ │ +699 // │ │ │ │ │ +700 // void setBaseFaceHole(TopologyRefiner& newRefiner, Index face, bool hole) │ │ │ │ │ +701 // │ │ │ │ │ +702 return true; │ │ │ │ │ +703} │ │ │ │ │ +704 │ │ │ │ │ +705template │ │ │ │ │ +706void │ │ │ │ │ +_7_0_7_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_M_E_S_H_>_:_:_r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y( │ │ │ │ │ +708 TopologyError /* errCode */, char const * /* msg */, MESH const& /* mesh */ │ │ │ │ │ +) { │ │ │ │ │ +709 │ │ │ │ │ +710 // │ │ │ │ │ +711 // Optional topology validation error reporting: │ │ │ │ │ +712 // This method is called whenever the factory encounters topology │ │ │ │ │ +validation │ │ │ │ │ +713 // errors. By default, nothing is reported │ │ │ │ │ +714 // │ │ │ │ │ +715} │ │ │ │ │ +716 │ │ │ │ │ +717} // end namespace Far │ │ │ │ │ +718 │ │ │ │ │ +719} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +720using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +721} // end namespace OpenSubdiv │ │ │ │ │ +722 │ │ │ │ │ +723#endif /* OPENSUBDIV3_FAR_TOPOLOGY_REFINER_FACTORY_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_E_r_r_o_r │ │ │ │ │ +void Error(ErrorType err, const char *format,...) │ │ │ │ │ +Sends an OSD error with a message (internal use only) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R │ │ │ │ │ +@ FAR_RUNTIME_ERROR │ │ │ │ │ +Issue a generic runtime error, but continue execution. │ │ │ │ │ +DDeeffiinniittiioonn _e_r_r_o_r_._h_:_4_0 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ Vtr::Index Index │ │ │ │ │ DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ -An interface for accessing data in a specific level of a refined topology │ │ │ │ │ -hierarchy. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_P_a_r_e_n_t_F_a_c_e │ │ │ │ │ -Index GetFaceParentFace(Index f) const │ │ │ │ │ -Return the parent face (in the previous level) of a given face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ -TopologyLevel() │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_3_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_V_a_l_e_n_c_e_R_e_g_u_l_a_r │ │ │ │ │ -bool IsVertexValenceRegular(Index v) const │ │ │ │ │ -Return if the valence of the vertex is regular (must be manifold) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float GetEdgeSharpness(Index e) const │ │ │ │ │ -Return the sharpness assigned a given edge. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_D_o_e_s_F_a_c_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h │ │ │ │ │ -bool DoesFaceFVarTopologyMatch(Index f, int channel=0) const │ │ │ │ │ -Return if face-varying topology around a face matches. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_R_u_l_e │ │ │ │ │ -Sdc::Crease::Rule GetVertexRule(Index v) const │ │ │ │ │ -Return the subdivision rule assigned a given vertex specific to this level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_9_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_C_o_r_n_e_r │ │ │ │ │ -bool IsVertexCorner(Index v) const │ │ │ │ │ -Return if the vertex is a corner (only one incident face) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_C_h_i_l_d_V_e_r_t_e_x │ │ │ │ │ -Index GetVertexChildVertex(Index v) const │ │ │ │ │ -Return the child vertex (in the next level) of a given vertex. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ -ConstLocalIndexArray GetEdgeFaceLocalIndices(Index e) const │ │ │ │ │ -Access the local indices of an edge with respect to its incident faces. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_1_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_C_h_i_l_d_E_d_g_e_s │ │ │ │ │ -ConstIndexArray GetFaceChildEdges(Index f) const │ │ │ │ │ -Access the child edges (in the next level) of a given face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_D_o_e_s_E_d_g_e_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h │ │ │ │ │ -bool DoesEdgeFVarTopologyMatch(Index e, int channel=0) const │ │ │ │ │ -Return if face-varying topology across the edge only matches. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_P_r_i_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ -void PrintTopology(bool children=true) const │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetFaceVertices(Index f) const │ │ │ │ │ -Access the vertices incident a given face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_C_h_i_l_d_F_a_c_e_s │ │ │ │ │ -ConstIndexArray GetFaceChildFaces(Index f) const │ │ │ │ │ -Access the child faces (in the next level) of a given face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_E_d_g_e_s │ │ │ │ │ -int GetNumEdges() const │ │ │ │ │ -Return the number of edges in this level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_V_a_l_i_d_a_t_e_T_o_p_o_l_o_g_y │ │ │ │ │ -bool ValidateTopology() const │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d │ │ │ │ │ -bool IsEdgeNonManifold(Index e) const │ │ │ │ │ -Return if the edge is non-manifold. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_2_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_F_a_c_e_H_o_l_e │ │ │ │ │ -bool IsFaceHole(Index f) const │ │ │ │ │ -Return if a given face has been tagged as a hole. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_9_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_E_d_g_e_s │ │ │ │ │ -ConstIndexArray GetVertexEdges(Index v) const │ │ │ │ │ -Access the edges incident a given vertex. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_0_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_C_h_i_l_d_V_e_r_t_e_x │ │ │ │ │ -Index GetFaceChildVertex(Index f) const │ │ │ │ │ -Return the child vertex (in the next level) of a given face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_D_o_e_s_V_e_r_t_e_x_F_V_a_r_T_o_p_o_l_o_g_y_M_a_t_c_h │ │ │ │ │ -bool DoesVertexFVarTopologyMatch(Index v, int channel=0) const │ │ │ │ │ -Return if face-varying topology around a vertex matches. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_4_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_C_h_i_l_d_E_d_g_e_s │ │ │ │ │ -ConstIndexArray GetEdgeChildEdges(Index e) const │ │ │ │ │ -Access the child edges (in the next level) of a given edge. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_I_n_f_S_h_a_r_p │ │ │ │ │ -bool IsEdgeInfSharp(Index e) const │ │ │ │ │ -Return if the edge is infinitely-sharp. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_F_a_c_e_s │ │ │ │ │ -ConstIndexArray GetVertexFaces(Index v) const │ │ │ │ │ -Access the faces incident a given vertex. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_0_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_F_i_n_d_E_d_g_e │ │ │ │ │ -Index FindEdge(Index v0, Index v1) const │ │ │ │ │ -Identify the edge matching the given vertex pair. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_2_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ -ConstLocalIndexArray GetVertexEdgeLocalIndices(Index v) const │ │ │ │ │ -Access the local indices of a vertex with respect to its incident edges. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_1_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_E_d_g_e_s │ │ │ │ │ -ConstIndexArray GetFaceEdges(Index f) const │ │ │ │ │ -Access the edges incident a given face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_9_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_a_c_e_s │ │ │ │ │ -int GetNumFaces() const │ │ │ │ │ -Return the number of faces in this level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_B_o_u_n_d_a_r_y │ │ │ │ │ -bool IsVertexBoundary(Index v) const │ │ │ │ │ -Return if the vertex is on a boundary (at least one incident boundary edge) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -int GetNumFVarChannels() const │ │ │ │ │ -Return the number of face-varying channels (should be same for all levels) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_3_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ -int GetNumVertices() const │ │ │ │ │ -Return the number of vertices in this level. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_F_a_c_e_s │ │ │ │ │ -ConstIndexArray GetEdgeFaces(Index e) const │ │ │ │ │ -Access the faces incident a given edge. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_0_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_F_a_c_e_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ -ConstIndexArray GetFaceFVarValues(Index f, int channel=0) const │ │ │ │ │ -Access the face-varying values associated with a particular face. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetEdgeVertices(Index e) const │ │ │ │ │ -Access the vertices incident a given edge. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_9_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_S_e_m_i_S_h_a_r_p │ │ │ │ │ -bool IsEdgeSemiSharp(Index e) const │ │ │ │ │ -Return if the edge is semi-sharp. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_~_T_o_p_o_l_o_g_y_L_e_v_e_l │ │ │ │ │ -~TopologyLevel() │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_3_0_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float GetVertexSharpness(Index v) const │ │ │ │ │ -Return the sharpness assigned a given vertex. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_E_d_g_e_C_h_i_l_d_V_e_r_t_e_x │ │ │ │ │ -Index GetEdgeChildVertex(Index e) const │ │ │ │ │ -Return the child vertex (in the next level) of a given edge. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_S_e_m_i_S_h_a_r_p │ │ │ │ │ -bool IsVertexSemiSharp(Index v) const │ │ │ │ │ -Return if the vertex is semi-sharp. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_a_c_e_V_e_r_t_i_c_e_s │ │ │ │ │ -int GetNumFaceVertices() const │ │ │ │ │ -Return the total number of face-vertices, i.e. the sum of all vertices for all │ │ │ │ │ -faces. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d │ │ │ │ │ -bool IsVertexNonManifold(Index v) const │ │ │ │ │ -Return if the vertex is non-manifold. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_E_d_g_e_B_o_u_n_d_a_r_y │ │ │ │ │ -bool IsEdgeBoundary(Index e) const │ │ │ │ │ -Return if the edge is a boundary (only one incident face) │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_I_s_V_e_r_t_e_x_I_n_f_S_h_a_r_p │ │ │ │ │ -bool IsVertexInfSharp(Index v) const │ │ │ │ │ -Return if the vertex is infinitely-sharp. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_N_u_m_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ -int GetNumFVarValues(int channel=0) const │ │ │ │ │ -Return the total number of face-varying values in a particular channel (the │ │ │ │ │ -upper bound of a face-var... │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_2_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_L_e_v_e_l_:_:_G_e_t_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ -ConstLocalIndexArray GetVertexFaceLocalIndices(Index v) const │ │ │ │ │ -Access the local indices of a vertex with respect to its incident faces. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_L_e_v_e_l_._h_:_1_1_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_T_y_p_e │ │ │ │ │ +SchemeType │ │ │ │ │ +Enumerated type for all subdivision schemes supported by OpenSubdiv. │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K │ │ │ │ │ +@ SCHEME_CATMARK │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y │ │ │ │ │ +Factory for constructing TopologyRefiners from specific mesh classes. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_N_u_m_B_a_s_e_F_a_c_e_s │ │ │ │ │ +static int getNumBaseFaces(TopologyRefiner const &newRefiner) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_3_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ +static bool assignComponentTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ +&mesh) │ │ │ │ │ +Specify the relationships between vertices, faces, etc. ie the face-vertices, │ │ │ │ │ +vertex-faces,... │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y │ │ │ │ │ +static void reportInvalidTopology(TopologyError errCode, char const *msg, MESH │ │ │ │ │ +const &mesh) │ │ │ │ │ +(Optional) Control run-time topology validation and error reporting │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_7_0_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_g_e_t_B_a_s_e_V_e_r_t_e_x_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +static LocalIndexArray getBaseVertexFaceLocalIndices(TopologyRefiner │ │ │ │ │ +&newRefiner, Index v) │ │ │ │ │ +Assign the local indices of a vertex within each of its incident faces. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_1_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_N_u_m_B_a_s_e_V_e_r_t_i_c_e_s │ │ │ │ │ +static int getNumBaseVertices(TopologyRefiner const &newRefiner) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_N_u_m_B_a_s_e_E_d_g_e_F_a_c_e_s │ │ │ │ │ +static void setNumBaseEdgeFaces(TopologyRefiner &newRefiner, Index e, int │ │ │ │ │ +count) │ │ │ │ │ +Specify the number of faces incident each edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_g_e_t_B_a_s_e_F_a_c_e_V_e_r_t_i_c_e_s │ │ │ │ │ +static IndexArray getBaseFaceVertices(TopologyRefiner &newRefiner, Index f) │ │ │ │ │ +Assign the vertices incident each face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_g_e_t_B_a_s_e_E_d_g_e_F_a_c_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +static LocalIndexArray getBaseEdgeFaceLocalIndices(TopologyRefiner &newRefiner, │ │ │ │ │ +Index e) │ │ │ │ │ +Assign the local indices of an edge within each of its incident faces. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_0_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_p_o_p_u_l_a_t_e_B_a_s_e_L_e_v_e_l │ │ │ │ │ +static bool populateBaseLevel(TopologyRefiner &refiner, MESH const &mesh, │ │ │ │ │ +Options options) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_3_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_p_o_p_u_l_a_t_e_B_a_s_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +static void populateBaseLocalIndices(TopologyRefiner &newRefiner) │ │ │ │ │ +Determine all local indices by inspection (only for pure manifold meshes) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_2_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s │ │ │ │ │ +static bool assignComponentTags(TopologyRefiner &newRefiner, MESH const &mesh) │ │ │ │ │ +(Optional) Specify edge or vertex sharpness or face holes │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_9_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ +static bool resizeComponentTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ +&mesh) │ │ │ │ │ +Specify the number of vertices, faces, face-vertices, etc. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_8_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_N_u_m_B_a_s_e_V_e_r_t_e_x_E_d_g_e_s │ │ │ │ │ +static void setNumBaseVertexEdges(TopologyRefiner &newRefiner, Index v, int │ │ │ │ │ +count) │ │ │ │ │ +Specify the number of edges incident each vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_T_o_p_o_l_o_g_y_E_r_r_o_r │ │ │ │ │ +Vtr::internal::Level::TopologyError TopologyError │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_1_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_g_e_t_B_a_s_e_F_a_c_e_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +static IndexArray getBaseFaceFVarValues(TopologyRefiner &newRefiner, Index │ │ │ │ │ +face, int channel=0) │ │ │ │ │ +Assign the face-varying values for the corners of each face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_B_a_s_e_E_d_g_e_F_a_c_e_s │ │ │ │ │ +static IndexArray getBaseEdgeFaces(TopologyRefiner &newRefiner, Index e) │ │ │ │ │ +Assign the faces incident each edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_8_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_N_u_m_B_a_s_e_V_e_r_t_e_x_F_a_c_e_s │ │ │ │ │ +static void setNumBaseVertexFaces(TopologyRefiner &newRefiner, Index v, int │ │ │ │ │ +count) │ │ │ │ │ +Specify the number of faces incident each vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y │ │ │ │ │ +static bool assignFaceVaryingTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ +&mesh) │ │ │ │ │ +(Optional) Specify face-varying data per face │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_B_a_s_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +static void setBaseVertexSharpness(TopologyRefiner &newRefiner, Index v, float │ │ │ │ │ +sharpness) │ │ │ │ │ +Assign a sharpness value to a given vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_g_e_t_B_a_s_e_V_e_r_t_e_x_E_d_g_e_L_o_c_a_l_I_n_d_i_c_e_s │ │ │ │ │ +static LocalIndexArray getBaseVertexEdgeLocalIndices(TopologyRefiner │ │ │ │ │ +&newRefiner, Index v) │ │ │ │ │ +Assign the local indices of a vertex within each of its incident edges. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_1_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_g_e_t_B_a_s_e_E_d_g_e_V_e_r_t_i_c_e_s │ │ │ │ │ +static IndexArray getBaseEdgeVertices(TopologyRefiner &newRefiner, Index e) │ │ │ │ │ +Assign the vertices incident each edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_B_a_s_e_V_e_r_t_e_x_F_a_c_e_s │ │ │ │ │ +static IndexArray getBaseVertexFaces(TopologyRefiner &newRefiner, Index v) │ │ │ │ │ +Assign the faces incident each vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_B_a_s_e_V_e_r_t_e_x_N_o_n_M_a_n_i_f_o_l_d │ │ │ │ │ +static void setBaseVertexNonManifold(TopologyRefiner &newRefiner, Index v, bool │ │ │ │ │ +b) │ │ │ │ │ +Tag a vertex as non-manifold. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_3_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_s_e_t_N_u_m_B_a_s_e_F_a_c_e_s │ │ │ │ │ +static void setNumBaseFaces(TopologyRefiner &newRefiner, int count) │ │ │ │ │ +Specify the number of faces to be accommodated. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_2_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_B_a_s_e_F_a_c_e_E_d_g_e_s │ │ │ │ │ +static IndexArray getBaseFaceEdges(TopologyRefiner &newRefiner, Index f) │ │ │ │ │ +Assign the edges incident each face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_N_u_m_B_a_s_e_F_a_c_e_V_e_r_t_i_c_e_s │ │ │ │ │ +static void setNumBaseFaceVertices(TopologyRefiner &newRefiner, Index f, int │ │ │ │ │ +count) │ │ │ │ │ +Specify the number of vertices incident each face. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_B_a_s_e_E_d_g_e_S_h_a_r_p_n_e_s_s │ │ │ │ │ +static void setBaseEdgeSharpness(TopologyRefiner &newRefiner, Index e, float │ │ │ │ │ +sharpness) │ │ │ │ │ +Assign a sharpness value to a given edge. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_s_e_t_B_a_s_e_E_d_g_e_N_o_n_M_a_n_i_f_o_l_d │ │ │ │ │ +static void setBaseEdgeNonManifold(TopologyRefiner &newRefiner, Index e, bool │ │ │ │ │ +b) │ │ │ │ │ +Tag an edge as non-manifold. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_3_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_s_e_t_N_u_m_B_a_s_e_E_d_g_e_s │ │ │ │ │ +static void setNumBaseEdges(TopologyRefiner &newRefiner, int count) │ │ │ │ │ +Specify the number of edges to be accommodated. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_2_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ +static TopologyRefiner * Create(MESH const &mesh, Options options=Options()) │ │ │ │ │ +Instantiates a TopologyRefiner from client-provided topological representation. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_3_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_f_i_n_d_B_a_s_e_E_d_g_e │ │ │ │ │ +static Index findBaseEdge(TopologyRefiner const &newRefiner, Index v0, Index │ │ │ │ │ +v1) │ │ │ │ │ +Identify an edge to be assigned a sharpness value given a vertex pair. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_B_a_s_e_V_e_r_t_e_x_E_d_g_e_s │ │ │ │ │ +static IndexArray getBaseVertexEdges(TopologyRefiner &newRefiner, Index v) │ │ │ │ │ +Assign the edges incident each vertex. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_9_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_c_r_e_a_t_e_B_a_s_e_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │ +static int createBaseFVarChannel(TopologyRefiner &newRefiner, int numValues) │ │ │ │ │ +Create a new face-varying channel with the given number of values. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_g_e_t_N_u_m_B_a_s_e_E_d_g_e_s │ │ │ │ │ +static int getNumBaseEdges(TopologyRefiner const &newRefiner) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_s_e_t_N_u_m_B_a_s_e_V_e_r_t_i_c_e_s │ │ │ │ │ +static void setNumBaseVertices(TopologyRefiner &newRefiner, int count) │ │ │ │ │ +Specify the number of vertices to be accommodated. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_3_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_s_e_t_B_a_s_e_F_a_c_e_H_o_l_e │ │ │ │ │ +static void setBaseFaceHole(TopologyRefiner &newRefiner, Index f, bool isHole) │ │ │ │ │ +Tag a face as a hole. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_5_4 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ Stores topology data for a specified set of refinement options. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e │ │ │ │ │ -Rule │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ -DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e │ │ │ │ │ +Private base class of Factories for constructing TopologyRefiners. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_4_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e_:_: │ │ │ │ │ +_p_r_e_p_a_r_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y_A_s_s_i_g_n_m_e_n_t │ │ │ │ │ +static bool prepareComponentTopologyAssignment(TopologyRefiner &refiner, bool │ │ │ │ │ +fullValidation, TopologyCallback callback, void const *callbackData) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e_:_: │ │ │ │ │ +_T_o_p_o_l_o_g_y_C_a_l_l_b_a_c_k │ │ │ │ │ +Vtr::internal::Level::ValidationCallback TopologyCallback │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e_:_: │ │ │ │ │ +_p_r_e_p_a_r_e_C_o_m_p_o_n_e_n_t_T_a_g_s_A_n_d_S_h_a_r_p_n_e_s_s │ │ │ │ │ +static bool prepareComponentTagsAndSharpness(TopologyRefiner &refiner) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e_:_: │ │ │ │ │ +_p_r_e_p_a_r_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y_S_i_z_i_n_g │ │ │ │ │ +static bool prepareComponentTopologySizing(TopologyRefiner &refiner) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e_:_: │ │ │ │ │ +_p_r_e_p_a_r_e_F_a_c_e_V_a_r_y_i_n_g_C_h_a_n_n_e_l_s │ │ │ │ │ +static bool prepareFaceVaryingChannels(TopologyRefiner &refiner) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Options related to the construction of each TopologyRefiner. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Options(Sdc::SchemeType sdcType=Sdc::SCHEME_CATMARK, Sdc::Options │ │ │ │ │ +sdcOptions=Sdc::Options()) │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_s_c_h_e_m_e_O_p_t_i_o_n_s │ │ │ │ │ +Sdc::Options schemeOptions │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_s_c_h_e_m_e_T_y_p_e │ │ │ │ │ +Sdc::SchemeType schemeType │ │ │ │ │ +The subdivision scheme type identifier. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_v_a_l_i_d_a_t_e_F_u_l_l_T_o_p_o_l_o_g_y │ │ │ │ │ +unsigned int validateFullTopology │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s │ │ │ │ │ +All supported options applying to subdivision scheme. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_S_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ +void SetFVarLinearInterpolation(FVarLinearInterpolation b) │ │ │ │ │ +Set face-varying interpolation rule. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_G_e_t_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ +FVarLinearInterpolation GetFVarLinearInterpolation() const │ │ │ │ │ +Get face-varying interpolation rule. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_9_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_A_r_r_a_y │ │ │ │ │ +DDeeffiinniittiioonn _a_r_r_a_y_._h_:_1_0_5 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_L_e_v_e_l_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00713.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/topologyDescriptor.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/stencilTable.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,31 +90,51 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
topologyDescriptor.h File Reference
│ │ │ │ +
stencilTable.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/topologyRefiner.h"
│ │ │ │ -#include "../far/topologyRefinerFactory.h"
│ │ │ │ -#include "../far/error.h"
│ │ │ │ +#include "../far/types.h"
│ │ │ │ #include <cassert>
│ │ │ │ +#include <cstring>
│ │ │ │ +#include <vector>
│ │ │ │ +#include <iostream>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  TopologyDescriptor
 A simple reference to raw topology data for use with TopologyRefinerFactory. More...
class  StencilReal< REAL >
 Vertex stencil descriptor. More...
 
struct  TopologyDescriptor::FVarChannel
class  Stencil
 Vertex stencil class wrapping the template for compatibility. More...
 
class  StencilTableReal< REAL >
 Table of subdivision stencils. More...
 
class  StencilTable
 Stencil table class wrapping the template for compatibility. More...
 
class  LimitStencilReal< REAL >
 Limit point stencil descriptor. More...
 
class  LimitStencil
 Limit point stencil class wrapping the template for compatibility. More...
 
class  LimitStencilTableReal< REAL >
 Table of limit subdivision stencils. More...
 
class  LimitStencilTable
 Limit stencil table class wrapping the template for compatibility. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -123,13 +143,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,30 +1,51 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -topologyDescriptor.h File Reference │ │ │ │ │ +stencilTable.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_e_r_r_o_r_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ #include │ │ │ │ │ +#include │ │ │ │ │ +#include │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -struct   _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -  A simple reference to raw topology data for use with │ │ │ │ │ - _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y. _M_o_r_e_._._. │ │ │ │ │ +class   _S_t_e_n_c_i_l_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  Vertex stencil descriptor. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -struct   _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │ +class   _S_t_e_n_c_i_l │ │ │ │ │ +  Vertex stencil class wrapping the template for compatibility. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  Table of subdivision stencils. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +  _S_t_e_n_c_i_l table class wrapping the template for compatibility. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  Limit point stencil descriptor. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ +  Limit point stencil class wrapping the template for compatibility. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  Table of limit subdivision stencils. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +  Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _s_t_e_n_c_i_l_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00713.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,10 @@ │ │ │ │ │ var a00713 = [ │ │ │ │ │ - ["TopologyDescriptor", "a01105.html", "a01105"], │ │ │ │ │ - ["FVarChannel", "a01109.html", "a01109"] │ │ │ │ │ + ["StencilReal< REAL >", "a01053.html", "a01053"], │ │ │ │ │ + ["Stencil", "a01057.html", "a01057"], │ │ │ │ │ + ["StencilTableReal< REAL >", "a01061.html", "a01061"], │ │ │ │ │ + ["StencilTable", "a01065.html", "a01065"], │ │ │ │ │ + ["LimitStencilReal< REAL >", "a01069.html", "a01069"], │ │ │ │ │ + ["LimitStencil", "a01073.html", "a01073"], │ │ │ │ │ + ["LimitStencilTableReal< REAL >", "a01077.html", "a01077"], │ │ │ │ │ + ["LimitStencilTable", "a01081.html", "a01081"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00713_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/topologyDescriptor.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/stencilTable.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
topologyDescriptor.h
│ │ │ │ +
stencilTable.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2014 DreamWorks Animation LLC.
│ │ │ │ +
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,146 +118,893 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H
│ │ │ │ -
25#define OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H
│ │ │ │ -
26
│ │ │ │ -
27#include "../version.h"
│ │ │ │ -
28
│ │ │ │ -
29#include "../far/topologyRefiner.h"
│ │ │ │ -
30#include "../far/topologyRefinerFactory.h"
│ │ │ │ -
31#include "../far/error.h"
│ │ │ │ -
32
│ │ │ │ -
33#include <cassert>
│ │ │ │ -
34
│ │ │ │ -
35namespace OpenSubdiv {
│ │ │ │ -
36namespace OPENSUBDIV_VERSION {
│ │ │ │ -
37
│ │ │ │ -
38namespace Far {
│ │ │ │ +
24
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_STENCILTABLE_H
│ │ │ │ +
27
│ │ │ │ +
28#include "../version.h"
│ │ │ │ +
29
│ │ │ │ +
30#include "../far/types.h"
│ │ │ │ +
31
│ │ │ │ +
32#include <cassert>
│ │ │ │ +
33#include <cstring>
│ │ │ │ +
34#include <vector>
│ │ │ │ +
35#include <iostream>
│ │ │ │ +
36
│ │ │ │ +
37namespace OpenSubdiv {
│ │ │ │ +
38namespace OPENSUBDIV_VERSION {
│ │ │ │
39
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
50
│ │ │ │ - │ │ │ │ - │ │ │ │ -
53
│ │ │ │ -
54 int const * numVertsPerFace;
│ │ │ │ - │ │ │ │ -
56
│ │ │ │ - │ │ │ │ - │ │ │ │ -
59 float const * creaseWeights;
│ │ │ │ -
60
│ │ │ │ - │ │ │ │ - │ │ │ │ -
63 float const * cornerWeights;
│ │ │ │ -
64
│ │ │ │ - │ │ │ │ - │ │ │ │ -
67
│ │ │ │ - │ │ │ │ +
40namespace Far {
│ │ │ │ +
41
│ │ │ │ +
42// Forward declarations for friends:
│ │ │ │ +
43class PatchTableBuilder;
│ │ │ │ +
44
│ │ │ │ +
45template <typename REAL> class StencilTableFactoryReal;
│ │ │ │ +
46template <typename REAL> class LimitStencilTableFactoryReal;
│ │ │ │ +
47
│ │ │ │ +
52template <typename REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
54public:
│ │ │ │ +
55
│ │ │ │ + │ │ │ │ +
58
│ │ │ │ +
│ │ │ │ +
67 StencilReal(int * size, Index * indices, REAL * weights)
│ │ │ │ +
68 : _size(size), _indices(indices), _weights(weights) { }
│ │ │ │ +
│ │ │ │
69
│ │ │ │ -
70 // Face-varying data channel -- value indices correspond to vertex indices,
│ │ │ │ -
71 // i.e. one for every vertex of every face:
│ │ │ │ -
72 //
│ │ │ │ -
│ │ │ │ -
73 struct FVarChannel {
│ │ │ │ -
74
│ │ │ │ - │ │ │ │ - │ │ │ │ -
77
│ │ │ │ - │ │ │ │ -
79 };
│ │ │ │ -
│ │ │ │ -
80
│ │ │ │ - │ │ │ │ - │ │ │ │ -
83
│ │ │ │ - │ │ │ │ -
85};
│ │ │ │ +
│ │ │ │ +
71 StencilReal(StencilReal const & other) {
│ │ │ │ +
72 _size = other._size;
│ │ │ │ +
73 _indices = other._indices;
│ │ │ │ +
74 _weights = other._weights;
│ │ │ │ +
75 }
│ │ │ │ +
│ │ │ │ +
76
│ │ │ │ +
│ │ │ │ +
78 int GetSize() const {
│ │ │ │ +
79 return *_size;
│ │ │ │ +
80 }
│ │ │ │ +
│ │ │ │ +
81
│ │ │ │ +
│ │ │ │ +
83 int * GetSizePtr() const {
│ │ │ │ +
84 return _size;
│ │ │ │ +
85 }
│ │ │ │
│ │ │ │
86
│ │ │ │ -
87
│ │ │ │ -
88//
│ │ │ │ -
89// Forward declarations of required TopologyRefinerFactory<TopologyDescriptor>
│ │ │ │ -
90// specializations (defined internally):
│ │ │ │ -
91//
│ │ │ │ -
92// @cond EXCLUDE_DOXYGEN
│ │ │ │ -
93
│ │ │ │ -
94template <>
│ │ │ │ -
95bool
│ │ │ │ - │ │ │ │ -
97 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ -
98
│ │ │ │ -
99template <>
│ │ │ │ -
100bool
│ │ │ │ - │ │ │ │ -
102 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ -
103
│ │ │ │ -
104template <>
│ │ │ │ -
105bool
│ │ │ │ - │ │ │ │ -
107 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ +
│ │ │ │ +
88 Index const * GetVertexIndices() const {
│ │ │ │ +
89 return _indices;
│ │ │ │ +
90 }
│ │ │ │ +
│ │ │ │ +
91
│ │ │ │ +
│ │ │ │ +
93 REAL const * GetWeights() const {
│ │ │ │ +
94 return _weights;
│ │ │ │ +
95 }
│ │ │ │ +
│ │ │ │ +
96
│ │ │ │ +
98 void Next() {
│ │ │ │ +
99 int stride = *_size;
│ │ │ │ +
100 ++_size;
│ │ │ │ +
101 _indices += stride;
│ │ │ │ +
102 _weights += stride;
│ │ │ │ +
103 }
│ │ │ │ +
104
│ │ │ │ +
105protected:
│ │ │ │ +
106 friend class StencilTableFactoryReal<REAL>;
│ │ │ │ +
107 friend class LimitStencilTableFactoryReal<REAL>;
│ │ │ │
108
│ │ │ │ -
109template <>
│ │ │ │ -
110bool
│ │ │ │ - │ │ │ │ -
112 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ +
109 int * _size;
│ │ │ │ + │ │ │ │ +
111 REAL * _weights;
│ │ │ │ +
112};
│ │ │ │ +
│ │ │ │
113
│ │ │ │ -
114template <>
│ │ │ │ -
115void
│ │ │ │ - │ │ │ │ -
117 TopologyError errCode, char const * msg, TopologyDescriptor const & desc);
│ │ │ │ -
118
│ │ │ │ -
119// @endcond
│ │ │ │ -
120
│ │ │ │ -
121} // end namespace Far
│ │ │ │ -
122
│ │ │ │ -
123} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
124using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
125} // end namespace OpenSubdiv
│ │ │ │ +
│ │ │ │ +
116class Stencil : public StencilReal<float> {
│ │ │ │ +
117protected:
│ │ │ │ + │ │ │ │ +
119
│ │ │ │ +
120public:
│ │ │ │ + │ │ │ │ +
122 Stencil(BaseStencil const & other) : BaseStencil(other) { }
│ │ │ │ +
│ │ │ │ +
123 Stencil(int * size, Index * indices, float * weights)
│ │ │ │ +
124 : BaseStencil(size, indices, weights) { }
│ │ │ │ +
│ │ │ │ +
125};
│ │ │ │ +
│ │ │ │
126
│ │ │ │ -
127#endif /* OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H */
│ │ │ │ +
127
│ │ │ │ +
140template <typename REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
142protected:
│ │ │ │ +
143 StencilTableReal(int numControlVerts,
│ │ │ │ +
144 std::vector<int> const& offsets,
│ │ │ │ +
145 std::vector<int> const& sizes,
│ │ │ │ +
146 std::vector<int> const& sources,
│ │ │ │ +
147 std::vector<REAL> const& weights,
│ │ │ │ +
148 bool includeCoarseVerts,
│ │ │ │ +
149 size_t firstOffset);
│ │ │ │ +
150
│ │ │ │ +
151public:
│ │ │ │ +
152
│ │ │ │ +
153 virtual ~StencilTableReal() {};
│ │ │ │ +
154
│ │ │ │ +
│ │ │ │ +
156 int GetNumStencils() const {
│ │ │ │ +
157 return (int)_sizes.size();
│ │ │ │ +
158 }
│ │ │ │ +
│ │ │ │ +
159
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
162 return _numControlVertices;
│ │ │ │ +
163 }
│ │ │ │ +
│ │ │ │ +
164
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
167
│ │ │ │ +
│ │ │ │ +
169 std::vector<int> const & GetSizes() const {
│ │ │ │ +
170 return _sizes;
│ │ │ │ +
171 }
│ │ │ │ +
│ │ │ │ +
172
│ │ │ │ +
│ │ │ │ +
174 std::vector<Index> const & GetOffsets() const {
│ │ │ │ +
175 return _offsets;
│ │ │ │ +
176 }
│ │ │ │ +
│ │ │ │ +
177
│ │ │ │ +
│ │ │ │ +
179 std::vector<Index> const & GetControlIndices() const {
│ │ │ │ +
180 return _indices;
│ │ │ │ +
181 }
│ │ │ │ +
│ │ │ │ +
182
│ │ │ │ +
│ │ │ │ +
184 std::vector<REAL> const & GetWeights() const {
│ │ │ │ +
185 return _weights;
│ │ │ │ +
186 }
│ │ │ │ +
│ │ │ │ +
187
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
190
│ │ │ │ +
204 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
205 void UpdateValues(T const &srcValues, U &dstValues, Index start=-1, Index end=-1) const {
│ │ │ │ +
206 this->update(srcValues, dstValues, _weights, start, end);
│ │ │ │ +
207 }
│ │ │ │ +
│ │ │ │ +
208
│ │ │ │ +
209 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
210 void UpdateValues(T1 const &srcBase, int numBase, T2 const &srcRef,
│ │ │ │ +
211 U &dstValues, Index start=-1, Index end=-1) const {
│ │ │ │ +
212 this->update(srcBase, numBase, srcRef, dstValues, _weights, start, end);
│ │ │ │ +
213 }
│ │ │ │ +
│ │ │ │ +
214
│ │ │ │ +
215 // Pointer interface for backward compatibility
│ │ │ │ +
216 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
217 void UpdateValues(T const *src, U *dst, Index start=-1, Index end=-1) const {
│ │ │ │ +
218 this->update(src, dst, _weights, start, end);
│ │ │ │ +
219 }
│ │ │ │ +
│ │ │ │ +
220 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
221 void UpdateValues(T1 const *srcBase, int numBase, T2 const *srcRef,
│ │ │ │ +
222 U *dst, Index start=-1, Index end=-1) const {
│ │ │ │ +
223 this->update(srcBase, numBase, srcRef, dst, _weights, start, end);
│ │ │ │ +
224 }
│ │ │ │ +
│ │ │ │ +
225
│ │ │ │ +
227 void Clear();
│ │ │ │ +
228
│ │ │ │ +
229protected:
│ │ │ │ +
230
│ │ │ │ +
231 // Update values by applying cached stencil weights to new control values
│ │ │ │ +
232 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
233 void update( T const &srcValues, U &dstValues,
│ │ │ │ +
234 std::vector<REAL> const & valueWeights, Index start, Index end) const;
│ │ │ │ +
235 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
236 void update( T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues,
│ │ │ │ +
237 std::vector<REAL> const & valueWeights, Index start, Index end) const;
│ │ │ │ +
238
│ │ │ │ +
239 // Populate the offsets table from the stencil sizes in _sizes (factory helper)
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
241
│ │ │ │ +
242 // Resize the table arrays (factory helper)
│ │ │ │ +
│ │ │ │ +
243 void resize(int nstencils, int nelems);
│ │ │ │ +
244
│ │ │ │ +
245 // Reserves the table arrays (factory helper)
│ │ │ │ +
│ │ │ │ +
246 void reserve(int nstencils, int nelems);
│ │ │ │ +
247
│ │ │ │ +
248 // Reallocates the table arrays to remove excess capacity (factory helper)
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
250
│ │ │ │ +
251 // Performs any final operations on internal tables (factory helper)
│ │ │ │ +
│ │ │ │ +
252 void finalize();
│ │ │ │ +
253
│ │ │ │ +
254protected:
│ │ │ │ + │ │ │ │ +
256 StencilTableReal(int numControlVerts)
│ │ │ │ +
257 : _numControlVertices(numControlVerts)
│ │ │ │ +
258 { }
│ │ │ │ +
259
│ │ │ │ +
260 friend class StencilTableFactoryReal<REAL>;
│ │ │ │ + │ │ │ │ +
262
│ │ │ │ +
263 int _numControlVertices; // number of control vertices
│ │ │ │ +
264
│ │ │ │ +
265 std::vector<int> _sizes; // number of coefficients for each stencil
│ │ │ │ +
266 std::vector<Index> _offsets, // offset to the start of each stencil
│ │ │ │ +
267 _indices; // indices of contributing coarse vertices
│ │ │ │ +
268 std::vector<REAL> _weights; // stencil weight coefficients
│ │ │ │ +
269};
│ │ │ │ +
270
│ │ │ │ +
│ │ │ │ +
273class StencilTable : public StencilTableReal<float> {
│ │ │ │ +
274protected:
│ │ │ │ + │ │ │ │ +
276
│ │ │ │ +
277public:
│ │ │ │ +
│ │ │ │ +
278 Stencil GetStencil(Index index) const {
│ │ │ │ +
279 return Stencil(BaseTable::GetStencil(index));
│ │ │ │ +
280 }
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
281 Stencil operator[] (Index index) const {
│ │ │ │ +
282 return Stencil(BaseTable::GetStencil(index));
│ │ │ │ +
283 }
│ │ │ │ +
│ │ │ │ +
284
│ │ │ │ +
285protected:
│ │ │ │ + │ │ │ │ +
287 StencilTable(int numControlVerts) : BaseTable(numControlVerts) { }
│ │ │ │ +
│ │ │ │ +
288 StencilTable(int numControlVerts,
│ │ │ │ +
289 std::vector<int> const& offsets,
│ │ │ │ +
290 std::vector<int> const& sizes,
│ │ │ │ +
291 std::vector<int> const& sources,
│ │ │ │ +
292 std::vector<float> const& weights,
│ │ │ │ +
293 bool includeCoarseVerts,
│ │ │ │ +
294 size_t firstOffset)
│ │ │ │ +
295 : BaseTable(numControlVerts, offsets,
│ │ │ │ +
296 sizes, sources, weights, includeCoarseVerts, firstOffset) { }
│ │ │ │ +
│ │ │ │ +
297};
│ │ │ │ +
│ │ │ │ +
298
│ │ │ │ +
299
│ │ │ │ +
302template <typename REAL>
│ │ │ │ +
│ │ │ │ +
303class LimitStencilReal : public StencilReal<REAL> {
│ │ │ │ +
304public:
│ │ │ │ +
305
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
325 Index * indices,
│ │ │ │ +
326 REAL * weights,
│ │ │ │ +
327 REAL * duWeights=0,
│ │ │ │ +
328 REAL * dvWeights=0,
│ │ │ │ +
329 REAL * duuWeights=0,
│ │ │ │ +
330 REAL * duvWeights=0,
│ │ │ │ +
331 REAL * dvvWeights=0)
│ │ │ │ +
332 : StencilReal<REAL>(size, indices, weights),
│ │ │ │ +
333 _duWeights(duWeights),
│ │ │ │ +
334 _dvWeights(dvWeights),
│ │ │ │ +
335 _duuWeights(duuWeights),
│ │ │ │ +
336 _duvWeights(duvWeights),
│ │ │ │ +
337 _dvvWeights(dvvWeights) {
│ │ │ │ +
338 }
│ │ │ │ +
│ │ │ │ +
339
│ │ │ │ +
│ │ │ │ +
341 REAL const * GetDuWeights() const {
│ │ │ │ +
342 return _duWeights;
│ │ │ │ +
343 }
│ │ │ │ +
│ │ │ │ +
344
│ │ │ │ +
│ │ │ │ +
346 REAL const * GetDvWeights() const {
│ │ │ │ +
347 return _dvWeights;
│ │ │ │ +
348 }
│ │ │ │ +
│ │ │ │ +
349
│ │ │ │ +
│ │ │ │ +
351 REAL const * GetDuuWeights() const {
│ │ │ │ +
352 return _duuWeights;
│ │ │ │ +
353 }
│ │ │ │ +
│ │ │ │ +
354
│ │ │ │ +
│ │ │ │ +
356 REAL const * GetDuvWeights() const {
│ │ │ │ +
357 return _duvWeights;
│ │ │ │ +
358 }
│ │ │ │ +
│ │ │ │ +
359
│ │ │ │ +
│ │ │ │ +
361 REAL const * GetDvvWeights() const {
│ │ │ │ +
362 return _dvvWeights;
│ │ │ │ +
363 }
│ │ │ │ +
│ │ │ │ +
364
│ │ │ │ +
366 void Next() {
│ │ │ │ +
367 int stride = *this->_size;
│ │ │ │ +
368 ++this->_size;
│ │ │ │ +
369 this->_indices += stride;
│ │ │ │ +
370 this->_weights += stride;
│ │ │ │ +
371 if (_duWeights) _duWeights += stride;
│ │ │ │ +
372 if (_dvWeights) _dvWeights += stride;
│ │ │ │ +
373 if (_duuWeights) _duuWeights += stride;
│ │ │ │ +
374 if (_duvWeights) _duvWeights += stride;
│ │ │ │ +
375 if (_dvvWeights) _dvvWeights += stride;
│ │ │ │ +
376 }
│ │ │ │ +
377
│ │ │ │ +
378private:
│ │ │ │ +
379
│ │ │ │ +
380 friend class StencilTableFactoryReal<REAL>;
│ │ │ │ +
381 friend class LimitStencilTableFactoryReal<REAL>;
│ │ │ │ +
382
│ │ │ │ +
383 REAL * _duWeights, // pointer to stencil u derivative limit weights
│ │ │ │ +
384 * _dvWeights, // pointer to stencil v derivative limit weights
│ │ │ │ +
385 * _duuWeights, // pointer to stencil uu derivative limit weights
│ │ │ │ +
386 * _duvWeights, // pointer to stencil uv derivative limit weights
│ │ │ │ +
387 * _dvvWeights; // pointer to stencil vv derivative limit weights
│ │ │ │ +
388};
│ │ │ │ +
│ │ │ │ +
389
│ │ │ │ +
│ │ │ │ +
392class LimitStencil : public LimitStencilReal<float> {
│ │ │ │ +
393protected:
│ │ │ │ + │ │ │ │ +
395
│ │ │ │ +
396public:
│ │ │ │ +
397 LimitStencil(BaseStencil const & other) : BaseStencil(other) { }
│ │ │ │ +
│ │ │ │ +
398 LimitStencil(int* size, Index * indices, float * weights,
│ │ │ │ +
399 float * duWeights=0, float * dvWeights=0,
│ │ │ │ +
400 float * duuWeights=0, float * duvWeights=0, float * dvvWeights=0)
│ │ │ │ +
401 : BaseStencil(size, indices, weights,
│ │ │ │ +
402 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights) { }
│ │ │ │ +
│ │ │ │ +
403};
│ │ │ │ +
│ │ │ │ +
404
│ │ │ │ +
405
│ │ │ │ +
408template <typename REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
410protected:
│ │ │ │ + │ │ │ │ +
412 int numControlVerts,
│ │ │ │ +
413 std::vector<int> const& offsets,
│ │ │ │ +
414 std::vector<int> const& sizes,
│ │ │ │ +
415 std::vector<int> const& sources,
│ │ │ │ +
416 std::vector<REAL> const& weights,
│ │ │ │ +
417 std::vector<REAL> const& duWeights,
│ │ │ │ +
418 std::vector<REAL> const& dvWeights,
│ │ │ │ +
419 std::vector<REAL> const& duuWeights,
│ │ │ │ +
420 std::vector<REAL> const& duvWeights,
│ │ │ │ +
421 std::vector<REAL> const& dvvWeights,
│ │ │ │ +
422 bool includeCoarseVerts,
│ │ │ │ +
423 size_t firstOffset);
│ │ │ │ +
424
│ │ │ │ +
425public:
│ │ │ │ +
426
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
429
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
432
│ │ │ │ +
│ │ │ │ +
434 std::vector<REAL> const & GetDuWeights() const {
│ │ │ │ +
435 return _duWeights;
│ │ │ │ +
436 }
│ │ │ │ +
│ │ │ │ +
437
│ │ │ │ +
│ │ │ │ +
439 std::vector<REAL> const & GetDvWeights() const {
│ │ │ │ +
440 return _dvWeights;
│ │ │ │ +
441 }
│ │ │ │ +
│ │ │ │ +
442
│ │ │ │ +
│ │ │ │ +
444 std::vector<REAL> const & GetDuuWeights() const {
│ │ │ │ +
445 return _duuWeights;
│ │ │ │ +
446 }
│ │ │ │ +
│ │ │ │ +
447
│ │ │ │ +
│ │ │ │ +
449 std::vector<REAL> const & GetDuvWeights() const {
│ │ │ │ +
450 return _duvWeights;
│ │ │ │ +
451 }
│ │ │ │ +
│ │ │ │ +
452
│ │ │ │ +
│ │ │ │ +
454 std::vector<REAL> const & GetDvvWeights() const {
│ │ │ │ +
455 return _dvvWeights;
│ │ │ │ +
456 }
│ │ │ │ +
│ │ │ │ +
457
│ │ │ │ +
475 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
476 void UpdateDerivs(T const & srcValues, U & uderivs, U & vderivs,
│ │ │ │ +
477 int start=-1, int end=-1) const {
│ │ │ │ +
478
│ │ │ │ +
479 this->update(srcValues, uderivs, _duWeights, start, end);
│ │ │ │ +
480 this->update(srcValues, vderivs, _dvWeights, start, end);
│ │ │ │ +
481 }
│ │ │ │ +
│ │ │ │ +
482
│ │ │ │ +
483 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
484 void UpdateDerivs(T1 const & srcBase, int numBase, T2 const & srcRef,
│ │ │ │ +
485 U & uderivs, U & vderivs, int start=-1, int end=-1) const {
│ │ │ │ +
486
│ │ │ │ +
487 this->update(srcBase, numBase, srcRef, uderivs, _duWeights, start, end);
│ │ │ │ +
488 this->update(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end);
│ │ │ │ +
489 }
│ │ │ │ +
│ │ │ │ +
490
│ │ │ │ +
491 // Pointer interface for backward compatibility
│ │ │ │ +
492 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
493 void UpdateDerivs(T const *src, U *uderivs, U *vderivs,
│ │ │ │ +
494 int start=-1, int end=-1) const {
│ │ │ │ +
495
│ │ │ │ +
496 this->update(src, uderivs, _duWeights, start, end);
│ │ │ │ +
497 this->update(src, vderivs, _dvWeights, start, end);
│ │ │ │ +
498 }
│ │ │ │ +
│ │ │ │ +
499 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
500 void UpdateDerivs(T1 const *srcBase, int numBase, T2 const *srcRef,
│ │ │ │ +
501 U *uderivs, U *vderivs, int start=-1, int end=-1) const {
│ │ │ │ +
502
│ │ │ │ +
503 this->update(srcBase, numBase, srcRef, uderivs, _duWeights, start, end);
│ │ │ │ +
504 this->update(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end);
│ │ │ │ +
505 }
│ │ │ │ +
│ │ │ │ +
506
│ │ │ │ +
527 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
528 void Update2ndDerivs(T const & srcValues,
│ │ │ │ +
529 U & uuderivs, U & uvderivs, U & vvderivs,
│ │ │ │ +
530 int start=-1, int end=-1) const {
│ │ │ │ +
531
│ │ │ │ +
532 this->update(srcValues, uuderivs, _duuWeights, start, end);
│ │ │ │ +
533 this->update(srcValues, uvderivs, _duvWeights, start, end);
│ │ │ │ +
534 this->update(srcValues, vvderivs, _dvvWeights, start, end);
│ │ │ │ +
535 }
│ │ │ │ +
│ │ │ │ +
536
│ │ │ │ +
537 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
538 void Update2ndDerivs(T1 const & srcBase, int numBase, T2 const & srcRef,
│ │ │ │ +
539 U & uuderivs, U & uvderivs, U & vvderivs, int start=-1, int end=-1) const {
│ │ │ │ +
540
│ │ │ │ +
541 this->update(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end);
│ │ │ │ +
542 this->update(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end);
│ │ │ │ +
543 this->update(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end);
│ │ │ │ +
544 }
│ │ │ │ +
│ │ │ │ +
545
│ │ │ │ +
546 // Pointer interface for backward compatibility
│ │ │ │ +
547 template <class T, class U>
│ │ │ │ +
│ │ │ │ +
548 void Update2ndDerivs(T const *src, T *uuderivs, U *uvderivs, U *vvderivs,
│ │ │ │ +
549 int start=-1, int end=-1) const {
│ │ │ │ +
550
│ │ │ │ +
551 this->update(src, uuderivs, _duuWeights, start, end);
│ │ │ │ +
552 this->update(src, uvderivs, _duvWeights, start, end);
│ │ │ │ +
553 this->update(src, vvderivs, _dvvWeights, start, end);
│ │ │ │ +
554 }
│ │ │ │ +
│ │ │ │ +
555 template <class T1, class T2, class U>
│ │ │ │ +
│ │ │ │ +
556 void Update2ndDerivs(T1 const *srcBase, int numBase, T2 const *srcRef,
│ │ │ │ +
557 U *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const {
│ │ │ │ +
558
│ │ │ │ +
559 this->update(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end);
│ │ │ │ +
560 this->update(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end);
│ │ │ │ +
561 this->update(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end);
│ │ │ │ +
562 }
│ │ │ │ +
│ │ │ │ +
563
│ │ │ │ +
565 void Clear();
│ │ │ │ +
566
│ │ │ │ +
567private:
│ │ │ │ +
568 friend class LimitStencilTableFactoryReal<REAL>;
│ │ │ │ +
569
│ │ │ │ +
570 // Resize the table arrays (factory helper)
│ │ │ │ +
571 void resize(int nstencils, int nelems);
│ │ │ │ +
572
│ │ │ │ +
573private:
│ │ │ │ +
574 std::vector<REAL> _duWeights, // u derivative limit stencil weights
│ │ │ │ +
575 _dvWeights, // v derivative limit stencil weights
│ │ │ │ +
576 _duuWeights, // uu derivative limit stencil weights
│ │ │ │ +
577 _duvWeights, // uv derivative limit stencil weights
│ │ │ │ +
578 _dvvWeights; // vv derivative limit stencil weights
│ │ │ │ +
579};
│ │ │ │ +
580
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
584protected:
│ │ │ │ + │ │ │ │ +
586
│ │ │ │ +
587public:
│ │ │ │ +
│ │ │ │ + │ │ │ │ + │ │ │ │ +
590 }
│ │ │ │ +
│ │ │ │ +
│ │ │ │ + │ │ │ │ + │ │ │ │ +
593 }
│ │ │ │ +
│ │ │ │ +
594
│ │ │ │ +
595protected:
│ │ │ │ +
│ │ │ │ +
596 LimitStencilTable(int numControlVerts,
│ │ │ │ +
597 std::vector<int> const& offsets,
│ │ │ │ +
598 std::vector<int> const& sizes,
│ │ │ │ +
599 std::vector<int> const& sources,
│ │ │ │ +
600 std::vector<float> const& weights,
│ │ │ │ +
601 std::vector<float> const& duWeights,
│ │ │ │ +
602 std::vector<float> const& dvWeights,
│ │ │ │ +
603 std::vector<float> const& duuWeights,
│ │ │ │ +
604 std::vector<float> const& duvWeights,
│ │ │ │ +
605 std::vector<float> const& dvvWeights,
│ │ │ │ +
606 bool includeCoarseVerts,
│ │ │ │ +
607 size_t firstOffset)
│ │ │ │ +
608 : BaseTable(numControlVerts,
│ │ │ │ +
609 offsets, sizes, sources, weights,
│ │ │ │ +
610 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights,
│ │ │ │ +
611 includeCoarseVerts, firstOffset) { }
│ │ │ │ +
│ │ │ │ +
612};
│ │ │ │ +
│ │ │ │ +
613
│ │ │ │ +
614
│ │ │ │ +
615// Update values by applying cached stencil weights to new control values
│ │ │ │ +
616template <typename REAL>
│ │ │ │ +
617template <class T1, class T2, class U> void
│ │ │ │ +
│ │ │ │ +
618StencilTableReal<REAL>::update(T1 const &srcBase, int numBase,
│ │ │ │ +
619 T2 const &srcRef, U &dstValues,
│ │ │ │ +
620 std::vector<REAL> const &valueWeights, Index start, Index end) const {
│ │ │ │ +
621
│ │ │ │ +
622 int const * sizes = &_sizes.at(0);
│ │ │ │ +
623 Index const * indices = &_indices.at(0);
│ │ │ │ +
624 REAL const * weights = &valueWeights.at(0);
│ │ │ │ +
625
│ │ │ │ +
626 if (start > 0) {
│ │ │ │ +
627 assert(start < (Index)_offsets.size());
│ │ │ │ +
628 sizes += start;
│ │ │ │ +
629 indices += _offsets[start];
│ │ │ │ +
630 weights += _offsets[start];
│ │ │ │ +
631 } else {
│ │ │ │ +
632 start = 0;
│ │ │ │ +
633 }
│ │ │ │ +
634
│ │ │ │ +
635 int nstencils = ((end < start) ? GetNumStencils() : end) - start;
│ │ │ │ +
636
│ │ │ │ +
637 for (int i = 0; i < nstencils; ++i, ++sizes) {
│ │ │ │ +
638 dstValues[start + i].Clear();
│ │ │ │ +
639 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) {
│ │ │ │ +
640 if (*indices < numBase) {
│ │ │ │ +
641 dstValues[start + i].AddWithWeight(srcBase[*indices], *weights);
│ │ │ │ +
642 } else {
│ │ │ │ +
643 dstValues[start + i].AddWithWeight(srcRef[*indices - numBase], *weights);
│ │ │ │ +
644 }
│ │ │ │ +
645 }
│ │ │ │ +
646 }
│ │ │ │ +
647}
│ │ │ │ +
│ │ │ │ +
648template <typename REAL>
│ │ │ │ +
649template <class T, class U> void
│ │ │ │ +
│ │ │ │ +
650StencilTableReal<REAL>::update(T const &srcValues, U &dstValues,
│ │ │ │ +
651 std::vector<REAL> const &valueWeights, Index start, Index end) const {
│ │ │ │ +
652
│ │ │ │ +
653 int const * sizes = &_sizes.at(0);
│ │ │ │ +
654 Index const * indices = &_indices.at(0);
│ │ │ │ +
655 REAL const * weights = &valueWeights.at(0);
│ │ │ │ +
656
│ │ │ │ +
657 if (start > 0) {
│ │ │ │ +
658 assert(start < (Index)_offsets.size());
│ │ │ │ +
659 sizes += start;
│ │ │ │ +
660 indices += _offsets[start];
│ │ │ │ +
661 weights += _offsets[start];
│ │ │ │ +
662 } else {
│ │ │ │ +
663 start = 0;
│ │ │ │ +
664 }
│ │ │ │ +
665
│ │ │ │ +
666 int nstencils = ((end < start) ? GetNumStencils() : end) - start;
│ │ │ │ +
667
│ │ │ │ +
668 for (int i = 0; i < nstencils; ++i, ++sizes) {
│ │ │ │ +
669 dstValues[start + i].Clear();
│ │ │ │ +
670 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) {
│ │ │ │ +
671 dstValues[start + i].AddWithWeight(srcValues[*indices], *weights);
│ │ │ │ +
672 }
│ │ │ │ +
673 }
│ │ │ │ +
674}
│ │ │ │ +
│ │ │ │ +
675
│ │ │ │ +
676template <typename REAL>
│ │ │ │ +
677inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
679 Index offset=0;
│ │ │ │ +
680 int noffsets = (int)_sizes.size();
│ │ │ │ +
681 _offsets.resize(noffsets);
│ │ │ │ +
682 for (int i=0; i<(int)_sizes.size(); ++i ) {
│ │ │ │ +
683 _offsets[i]=offset;
│ │ │ │ +
684 offset+=_sizes[i];
│ │ │ │ +
685 }
│ │ │ │ +
686}
│ │ │ │ +
│ │ │ │ +
687
│ │ │ │ +
688template <typename REAL>
│ │ │ │ +
689inline void
│ │ │ │ +
│ │ │ │ +
690StencilTableReal<REAL>::resize(int nstencils, int nelems) {
│ │ │ │ +
691 _sizes.resize(nstencils);
│ │ │ │ +
692 _indices.resize(nelems);
│ │ │ │ +
693 _weights.resize(nelems);
│ │ │ │ +
694}
│ │ │ │ +
│ │ │ │ +
695
│ │ │ │ +
696template <typename REAL>
│ │ │ │ +
697inline void
│ │ │ │ +
│ │ │ │ +
698StencilTableReal<REAL>::reserve(int nstencils, int nelems) {
│ │ │ │ +
699 _sizes.reserve(nstencils);
│ │ │ │ +
700 _indices.reserve(nelems);
│ │ │ │ +
701 _weights.reserve(nelems);
│ │ │ │ +
702}
│ │ │ │ +
│ │ │ │ +
703
│ │ │ │ +
704template <typename REAL>
│ │ │ │ +
705inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
707 std::vector<int>(_sizes).swap(_sizes);
│ │ │ │ +
708 std::vector<Index>(_indices).swap(_indices);
│ │ │ │ +
709 std::vector<REAL>(_weights).swap(_weights);
│ │ │ │ +
710}
│ │ │ │ +
│ │ │ │ +
711
│ │ │ │ +
712template <typename REAL>
│ │ │ │ +
713inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
715 shrinkToFit();
│ │ │ │ +
716 generateOffsets();
│ │ │ │ +
717}
│ │ │ │ +
│ │ │ │ +
718
│ │ │ │ +
719// Returns a Stencil at index i in the table
│ │ │ │ +
720template <typename REAL>
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
723 assert((! _offsets.empty()) && i<(int)_offsets.size());
│ │ │ │ +
724
│ │ │ │ +
725 Index ofs = _offsets[i];
│ │ │ │ +
726
│ │ │ │ +
727 return StencilReal<REAL>(const_cast<int*>(&_sizes[i]),
│ │ │ │ +
728 const_cast<Index*>(&_indices[ofs]),
│ │ │ │ +
729 const_cast<REAL*>(&_weights[ofs]));
│ │ │ │ +
730}
│ │ │ │ +
│ │ │ │ +
731
│ │ │ │ +
732template <typename REAL>
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
735 return GetStencil(index);
│ │ │ │ +
736}
│ │ │ │ +
│ │ │ │ +
737
│ │ │ │ +
738template <typename REAL>
│ │ │ │ +
739inline void
│ │ │ │ +
740LimitStencilTableReal<REAL>::resize(int nstencils, int nelems) {
│ │ │ │ +
741 StencilTableReal<REAL>::resize(nstencils, nelems);
│ │ │ │ +
742 _duWeights.resize(nelems);
│ │ │ │ +
743 _dvWeights.resize(nelems);
│ │ │ │ +
744}
│ │ │ │ +
745
│ │ │ │ +
746// Returns a LimitStencil at index i in the table
│ │ │ │ +
747template <typename REAL>
│ │ │ │ +
748inline LimitStencilReal<REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
750 assert((! this->GetOffsets().empty()) && i<(int)this->GetOffsets().size());
│ │ │ │ +
751
│ │ │ │ +
752 Index ofs = this->GetOffsets()[i];
│ │ │ │ +
753
│ │ │ │ +
754 if (!_duWeights.empty() && !_dvWeights.empty() &&
│ │ │ │ +
755 !_duuWeights.empty() && !_duvWeights.empty() && !_dvvWeights.empty()) {
│ │ │ │ + │ │ │ │ +
757 const_cast<int *>(&this->GetSizes()[i]),
│ │ │ │ +
758 const_cast<Index *>(&this->GetControlIndices()[ofs]),
│ │ │ │ +
759 const_cast<REAL *>(&this->GetWeights()[ofs]),
│ │ │ │ +
760 const_cast<REAL *>(&GetDuWeights()[ofs]),
│ │ │ │ +
761 const_cast<REAL *>(&GetDvWeights()[ofs]),
│ │ │ │ +
762 const_cast<REAL *>(&GetDuuWeights()[ofs]),
│ │ │ │ +
763 const_cast<REAL *>(&GetDuvWeights()[ofs]),
│ │ │ │ +
764 const_cast<REAL *>(&GetDvvWeights()[ofs]) );
│ │ │ │ +
765 } else if (!_duWeights.empty() && !_dvWeights.empty()) {
│ │ │ │ + │ │ │ │ +
767 const_cast<int *>(&this->GetSizes()[i]),
│ │ │ │ +
768 const_cast<Index *>(&this->GetControlIndices()[ofs]),
│ │ │ │ +
769 const_cast<REAL *>(&this->GetWeights()[ofs]),
│ │ │ │ +
770 const_cast<REAL *>(&GetDuWeights()[ofs]),
│ │ │ │ +
771 const_cast<REAL *>(&GetDvWeights()[ofs]) );
│ │ │ │ +
772 } else {
│ │ │ │ + │ │ │ │ +
774 const_cast<int *>(&this->GetSizes()[i]),
│ │ │ │ +
775 const_cast<Index *>(&this->GetControlIndices()[ofs]),
│ │ │ │ +
776 const_cast<REAL *>(&this->GetWeights()[ofs]) );
│ │ │ │ +
777 }
│ │ │ │ +
778}
│ │ │ │ +
│ │ │ │ +
779
│ │ │ │ +
780template <typename REAL>
│ │ │ │ + │ │ │ │ +
│ │ │ │ + │ │ │ │ +
783 return GetLimitStencil(index);
│ │ │ │ +
784}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
785
│ │ │ │ +
786} // end namespace Far
│ │ │ │ +
787
│ │ │ │ +
788} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
789using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
790
│ │ │ │ +
791} // end namespace OpenSubdiv
│ │ │ │ +
792
│ │ │ │ +
793#endif // OPENSUBDIV3_FAR_STENCILTABLE_H
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ -
A simple reference to raw topology data for use with TopologyRefinerFactory.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
static bool assignComponentTopology(TopologyRefiner &newRefiner, MESH const &mesh)
Specify the relationships between vertices, faces, etc. ie the face-vertices, vertex-faces,...
│ │ │ │ -
static void reportInvalidTopology(TopologyError errCode, char const *msg, MESH const &mesh)
(Optional) Control run-time topology validation and error reporting
│ │ │ │ -
static bool assignComponentTags(TopologyRefiner &newRefiner, MESH const &mesh)
(Optional) Specify edge or vertex sharpness or face holes
│ │ │ │ -
static bool resizeComponentTopology(TopologyRefiner &newRefiner, MESH const &mesh)
Specify the number of vertices, faces, face-vertices, etc.
│ │ │ │ -
static bool assignFaceVaryingTopology(TopologyRefiner &newRefiner, MESH const &mesh)
(Optional) Specify face-varying data per face
│ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
StencilReal(int *size, Index *indices, REAL *weights)
Constructor.
│ │ │ │ +
void Next()
Advance to the next stencil in the table.
│ │ │ │ +
StencilReal(StencilReal const &other)
Copy constructor.
│ │ │ │ + │ │ │ │ +
Index const * GetVertexIndices() const
Returns the control vertices' indices.
│ │ │ │ +
int GetSize() const
Returns the size of the stencil.
│ │ │ │ + │ │ │ │ +
int * GetSizePtr() const
Returns the size of the stencil as a pointer.
│ │ │ │ +
REAL const * GetWeights() const
Returns the interpolation weights.
│ │ │ │ +
Vertex stencil class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ +
Stencil(int *size, Index *indices, float *weights)
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
int GetNumControlVertices() const
Returns the number of control vertices indexed in the table.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
void update(T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues, std::vector< REAL > const &valueWeights, Index start, Index end) const
│ │ │ │ +
void UpdateValues(T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues, Index start=-1, Index end=-1) const
│ │ │ │ +
std::vector< Index > const & GetControlIndices() const
Returns the indices of the control vertices.
│ │ │ │ + │ │ │ │ +
StencilReal< REAL > operator[](Index index) const
Returns the stencil at index i in the table.
│ │ │ │ + │ │ │ │ +
void update(T const &srcValues, U &dstValues, std::vector< REAL > const &valueWeights, Index start, Index end) const
│ │ │ │ +
std::vector< int > const & GetSizes() const
Returns the number of control vertices of each stencil in the table.
│ │ │ │ +
int GetNumStencils() const
Returns the number of stencils in the table.
│ │ │ │ + │ │ │ │ +
std::vector< Index > const & GetOffsets() const
Returns the offset to a given stencil (factory may leave empty)
│ │ │ │ +
StencilReal< REAL > GetStencil(Index i) const
Returns a Stencil at index i in the table.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
void Clear()
Clears the stencils from the table.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
std::vector< REAL > const & GetWeights() const
Returns the stencil interpolation weights.
│ │ │ │ +
void UpdateValues(T1 const *srcBase, int numBase, T2 const *srcRef, U *dst, Index start=-1, Index end=-1) const
│ │ │ │ +
StencilTableReal(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< REAL > const &weights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
void UpdateValues(T const *src, U *dst, Index start=-1, Index end=-1) const
│ │ │ │ +
void UpdateValues(T const &srcValues, U &dstValues, Index start=-1, Index end=-1) const
Updates point values based on the control values.
│ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
StencilTable(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< float > const &weights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
REAL const * GetDuvWeights() const
Returns the uv derivative weights.
│ │ │ │ +
REAL const * GetDvWeights() const
Returns the v derivative weights.
│ │ │ │ +
void Next()
Advance to the next stencil in the table.
│ │ │ │ +
REAL const * GetDvvWeights() const
Returns the vv derivative weights.
│ │ │ │ +
LimitStencilReal(int *size, Index *indices, REAL *weights, REAL *duWeights=0, REAL *dvWeights=0, REAL *duuWeights=0, REAL *duvWeights=0, REAL *dvvWeights=0)
Constructor.
│ │ │ │ +
REAL const * GetDuWeights() const
Returns the u derivative weights.
│ │ │ │ +
REAL const * GetDuuWeights() const
Returns the uu derivative weights.
│ │ │ │ +
Limit point stencil class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
LimitStencil(int *size, Index *indices, float *weights, float *duWeights=0, float *dvWeights=0, float *duuWeights=0, float *duvWeights=0, float *dvvWeights=0)
│ │ │ │ + │ │ │ │ +
std::vector< REAL > const & GetDuuWeights() const
Returns the 'uu' derivative stencil interpolation weights.
│ │ │ │ +
LimitStencilReal< REAL > operator[](Index index) const
Returns the limit stencil at index i in the table.
│ │ │ │ +
std::vector< REAL > const & GetDvvWeights() const
Returns the 'vv' derivative stencil interpolation weights.
│ │ │ │ +
void UpdateDerivs(T const *src, U *uderivs, U *vderivs, int start=-1, int end=-1) const
│ │ │ │ +
void Update2ndDerivs(T const *src, T *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const
│ │ │ │ +
std::vector< REAL > const & GetDvWeights() const
Returns the 'v' derivative stencil interpolation weights.
│ │ │ │ +
void Update2ndDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const
│ │ │ │ +
void UpdateDerivs(T const &srcValues, U &uderivs, U &vderivs, int start=-1, int end=-1) const
Updates derivative values based on the control values.
│ │ │ │ +
LimitStencilReal< REAL > GetLimitStencil(Index i) const
Returns a LimitStencil at index i in the table.
│ │ │ │ +
LimitStencilTableReal(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< REAL > const &weights, std::vector< REAL > const &duWeights, std::vector< REAL > const &dvWeights, std::vector< REAL > const &duuWeights, std::vector< REAL > const &duvWeights, std::vector< REAL > const &dvvWeights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ +
void Update2ndDerivs(T const &srcValues, U &uuderivs, U &uvderivs, U &vvderivs, int start=-1, int end=-1) const
Updates 2nd derivative values based on the control values.
│ │ │ │ +
std::vector< REAL > const & GetDuWeights() const
Returns the 'u' derivative stencil interpolation weights.
│ │ │ │ +
void Clear()
Clears the stencils from the table.
│ │ │ │ +
void Update2ndDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U &uuderivs, U &uvderivs, U &vvderivs, int start=-1, int end=-1) const
│ │ │ │ +
std::vector< REAL > const & GetDuvWeights() const
Returns the 'uv' derivative stencil interpolation weights.
│ │ │ │ +
void UpdateDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U &uderivs, U &vderivs, int start=-1, int end=-1) const
│ │ │ │ +
void UpdateDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U *uderivs, U *vderivs, int start=-1, int end=-1) const
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
LimitStencilTable(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< float > const &weights, std::vector< float > const &duWeights, std::vector< float > const &dvWeights, std::vector< float > const &duuWeights, std::vector< float > const &duvWeights, std::vector< float > const &dvvWeights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ + │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -topologyDescriptor.h │ │ │ │ │ +stencilTable.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2014 DreamWorks Animation LLC. │ │ │ │ │ +2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,208 +23,991 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H │ │ │ │ │ -25#define OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H │ │ │ │ │ -26 │ │ │ │ │ -27#include "../version.h" │ │ │ │ │ -28 │ │ │ │ │ -29#include "../far/topologyRefiner.h" │ │ │ │ │ -30#include "../far/topologyRefinerFactory.h" │ │ │ │ │ -31#include "../far/error.h" │ │ │ │ │ -32 │ │ │ │ │ -33#include │ │ │ │ │ -34 │ │ │ │ │ -35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -36namespace OPENSUBDIV_VERSION { │ │ │ │ │ -37 │ │ │ │ │ -38namespace Far { │ │ │ │ │ +24 │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_STENCILTABLE_H │ │ │ │ │ +27 │ │ │ │ │ +28#include "../version.h" │ │ │ │ │ +29 │ │ │ │ │ +30#include "../far/types.h" │ │ │ │ │ +31 │ │ │ │ │ +32#include │ │ │ │ │ +33#include │ │ │ │ │ +34#include │ │ │ │ │ +35#include │ │ │ │ │ +36 │ │ │ │ │ +37namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +38namespace OPENSUBDIV_VERSION { │ │ │ │ │ 39 │ │ │ │ │ -_4_9struct _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ -50 │ │ │ │ │ -_5_1 int _n_u_m_V_e_r_t_i_c_e_s, │ │ │ │ │ -_5_2 _n_u_m_F_a_c_e_s; │ │ │ │ │ -53 │ │ │ │ │ -_5_4 int const * _n_u_m_V_e_r_t_s_P_e_r_F_a_c_e; │ │ │ │ │ -_5_5 _I_n_d_e_x const * _v_e_r_t_I_n_d_i_c_e_s_P_e_r_F_a_c_e; │ │ │ │ │ -56 │ │ │ │ │ -_5_7 int _n_u_m_C_r_e_a_s_e_s; │ │ │ │ │ -_5_8 _I_n_d_e_x const * _c_r_e_a_s_e_V_e_r_t_e_x_I_n_d_e_x_P_a_i_r_s; │ │ │ │ │ -_5_9 float const * _c_r_e_a_s_e_W_e_i_g_h_t_s; │ │ │ │ │ -60 │ │ │ │ │ -_6_1 int _n_u_m_C_o_r_n_e_r_s; │ │ │ │ │ -_6_2 _I_n_d_e_x const * _c_o_r_n_e_r_V_e_r_t_e_x_I_n_d_i_c_e_s; │ │ │ │ │ -_6_3 float const * _c_o_r_n_e_r_W_e_i_g_h_t_s; │ │ │ │ │ -64 │ │ │ │ │ -_6_5 int _n_u_m_H_o_l_e_s; │ │ │ │ │ -_6_6 _I_n_d_e_x const * _h_o_l_e_I_n_d_i_c_e_s; │ │ │ │ │ -67 │ │ │ │ │ -_6_8 bool _i_s_L_e_f_t_H_a_n_d_e_d; │ │ │ │ │ +40namespace Far { │ │ │ │ │ +41 │ │ │ │ │ +42// Forward declarations for friends: │ │ │ │ │ +43class PatchTableBuilder; │ │ │ │ │ +44 │ │ │ │ │ +45template class StencilTableFactoryReal; │ │ │ │ │ +46template class LimitStencilTableFactoryReal; │ │ │ │ │ +47 │ │ │ │ │ +52template │ │ │ │ │ +_5_3class _S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ +54public: │ │ │ │ │ +55 │ │ │ │ │ +_5_7 _S_t_e_n_c_i_l_R_e_a_l() {} │ │ │ │ │ +58 │ │ │ │ │ +_6_7 _S_t_e_n_c_i_l_R_e_a_l(int * size, _I_n_d_e_x * indices, REAL * weights) │ │ │ │ │ +68 : ___s_i_z_e(size), ___i_n_d_i_c_e_s(indices), ___w_e_i_g_h_t_s(weights) { } │ │ │ │ │ 69 │ │ │ │ │ -70 // Face-varying data channel -- value indices correspond to vertex indices, │ │ │ │ │ -71 // i.e. one for every vertex of every face: │ │ │ │ │ -72 // │ │ │ │ │ -_7_3 struct _F_V_a_r_C_h_a_n_n_e_l { │ │ │ │ │ -74 │ │ │ │ │ -_7_5 int _n_u_m_V_a_l_u_e_s; │ │ │ │ │ -_7_6 _I_n_d_e_x const * _v_a_l_u_e_I_n_d_i_c_e_s; │ │ │ │ │ -77 │ │ │ │ │ -_7_8 _F_V_a_r_C_h_a_n_n_e_l() : _n_u_m_V_a_l_u_e_s(0), _v_a_l_u_e_I_n_d_i_c_e_s(0) { } │ │ │ │ │ -79 }; │ │ │ │ │ -80 │ │ │ │ │ -_8_1 int _n_u_m_F_V_a_r_C_h_a_n_n_e_l_s; │ │ │ │ │ -_8_2 _F_V_a_r_C_h_a_n_n_e_l const * _f_v_a_r_C_h_a_n_n_e_l_s; │ │ │ │ │ -83 │ │ │ │ │ -_8_4 _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r(); │ │ │ │ │ -85}; │ │ │ │ │ +_7_1 _S_t_e_n_c_i_l_R_e_a_l(_S_t_e_n_c_i_l_R_e_a_l const & other) { │ │ │ │ │ +72 ___s_i_z_e = other.___s_i_z_e; │ │ │ │ │ +73 ___i_n_d_i_c_e_s = other.___i_n_d_i_c_e_s; │ │ │ │ │ +74 ___w_e_i_g_h_t_s = other.___w_e_i_g_h_t_s; │ │ │ │ │ +75 } │ │ │ │ │ +76 │ │ │ │ │ +_7_8 int _G_e_t_S_i_z_e() const { │ │ │ │ │ +79 return *___s_i_z_e; │ │ │ │ │ +80 } │ │ │ │ │ +81 │ │ │ │ │ +_8_3 int * _G_e_t_S_i_z_e_P_t_r() const { │ │ │ │ │ +84 return ___s_i_z_e; │ │ │ │ │ +85 } │ │ │ │ │ 86 │ │ │ │ │ -87 │ │ │ │ │ -88// │ │ │ │ │ -89// Forward declarations of required │ │ │ │ │ -TopologyRefinerFactory │ │ │ │ │ -90// specializations (defined internally): │ │ │ │ │ -91// │ │ │ │ │ -92// @cond EXCLUDE_DOXYGEN │ │ │ │ │ -93 │ │ │ │ │ -94template <> │ │ │ │ │ -95bool │ │ │ │ │ -96_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y( │ │ │ │ │ -97 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ -98 │ │ │ │ │ -99template <> │ │ │ │ │ -100bool │ │ │ │ │ -101_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y( │ │ │ │ │ -102 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ -103 │ │ │ │ │ -104template <> │ │ │ │ │ -105bool │ │ │ │ │ -106_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s( │ │ │ │ │ -107 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ +_8_8 _I_n_d_e_x const * _G_e_t_V_e_r_t_e_x_I_n_d_i_c_e_s() const { │ │ │ │ │ +89 return ___i_n_d_i_c_e_s; │ │ │ │ │ +90 } │ │ │ │ │ +91 │ │ │ │ │ +_9_3 REAL const * _G_e_t_W_e_i_g_h_t_s() const { │ │ │ │ │ +94 return ___w_e_i_g_h_t_s; │ │ │ │ │ +95 } │ │ │ │ │ +96 │ │ │ │ │ +_9_8 void _N_e_x_t() { │ │ │ │ │ +99 int stride = *___s_i_z_e; │ │ │ │ │ +100 ++___s_i_z_e; │ │ │ │ │ +101 ___i_n_d_i_c_e_s += stride; │ │ │ │ │ +102 ___w_e_i_g_h_t_s += stride; │ │ │ │ │ +103 } │ │ │ │ │ +104 │ │ │ │ │ +105protected: │ │ │ │ │ +106 friend class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ +107 friend class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ 108 │ │ │ │ │ -109template <> │ │ │ │ │ -110bool │ │ │ │ │ -111_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y( │ │ │ │ │ -112 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ +_1_0_9 int * ___s_i_z_e; │ │ │ │ │ +_1_1_0 _I_n_d_e_x * ___i_n_d_i_c_e_s; │ │ │ │ │ +_1_1_1 REAL * ___w_e_i_g_h_t_s; │ │ │ │ │ +112}; │ │ │ │ │ 113 │ │ │ │ │ -114template <> │ │ │ │ │ -115void │ │ │ │ │ -116_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y( │ │ │ │ │ -117 TopologyError errCode, char const * msg, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ -118 │ │ │ │ │ -119// @endcond │ │ │ │ │ -120 │ │ │ │ │ -121} // end namespace Far │ │ │ │ │ -122 │ │ │ │ │ -123} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -124using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -125} // end namespace OpenSubdiv │ │ │ │ │ +_1_1_6class _S_t_e_n_c_i_l : public _S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ +117protected: │ │ │ │ │ +_1_1_8 typedef _S_t_e_n_c_i_l_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_S_t_e_n_c_i_l; │ │ │ │ │ +119 │ │ │ │ │ +120public: │ │ │ │ │ +_1_2_1 _S_t_e_n_c_i_l() : _B_a_s_e_S_t_e_n_c_i_l() { } │ │ │ │ │ +_1_2_2 _S_t_e_n_c_i_l(_B_a_s_e_S_t_e_n_c_i_l const & other) : _B_a_s_e_S_t_e_n_c_i_l(other) { } │ │ │ │ │ +_1_2_3 _S_t_e_n_c_i_l(int * size, _I_n_d_e_x * indices, float * weights) │ │ │ │ │ +124 : _B_a_s_e_S_t_e_n_c_i_l(size, indices, weights) { } │ │ │ │ │ +125}; │ │ │ │ │ 126 │ │ │ │ │ -127#endif /* OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H */ │ │ │ │ │ +127 │ │ │ │ │ +140template │ │ │ │ │ +_1_4_1class _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ +142protected: │ │ │ │ │ +_1_4_3 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l(int numControlVerts, │ │ │ │ │ +144 std::vector const& offsets, │ │ │ │ │ +145 std::vector const& sizes, │ │ │ │ │ +146 std::vector const& sources, │ │ │ │ │ +147 std::vector const& weights, │ │ │ │ │ +148 bool includeCoarseVerts, │ │ │ │ │ +149 size_t firstOffset); │ │ │ │ │ +150 │ │ │ │ │ +151public: │ │ │ │ │ +152 │ │ │ │ │ +_1_5_3 virtual _~_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l() {}; │ │ │ │ │ +154 │ │ │ │ │ +_1_5_6 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { │ │ │ │ │ +157 return (int)___s_i_z_e_s.size(); │ │ │ │ │ +158 } │ │ │ │ │ +159 │ │ │ │ │ +_1_6_1 int _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s() const { │ │ │ │ │ +162 return ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s; │ │ │ │ │ +163 } │ │ │ │ │ +164 │ │ │ │ │ +_1_6_6 _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _G_e_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const; │ │ │ │ │ +167 │ │ │ │ │ +_1_6_9 std::vector const & _G_e_t_S_i_z_e_s() const { │ │ │ │ │ +170 return ___s_i_z_e_s; │ │ │ │ │ +171 } │ │ │ │ │ +172 │ │ │ │ │ +_1_7_4 std::vector const & _G_e_t_O_f_f_s_e_t_s() const { │ │ │ │ │ +175 return ___o_f_f_s_e_t_s; │ │ │ │ │ +176 } │ │ │ │ │ +177 │ │ │ │ │ +_1_7_9 std::vector const & _G_e_t_C_o_n_t_r_o_l_I_n_d_i_c_e_s() const { │ │ │ │ │ +180 return ___i_n_d_i_c_e_s; │ │ │ │ │ +181 } │ │ │ │ │ +182 │ │ │ │ │ +_1_8_4 std::vector const & _G_e_t_W_e_i_g_h_t_s() const { │ │ │ │ │ +185 return ___w_e_i_g_h_t_s; │ │ │ │ │ +186 } │ │ │ │ │ +187 │ │ │ │ │ +_1_8_9 _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const; │ │ │ │ │ +190 │ │ │ │ │ +204 template │ │ │ │ │ +_2_0_5 void _U_p_d_a_t_e_V_a_l_u_e_s(T const &srcValues, U &dstValues, _I_n_d_e_x start=-1, _I_n_d_e_x │ │ │ │ │ +end=-1) const { │ │ │ │ │ +206 this->_u_p_d_a_t_e(srcValues, dstValues, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ +207 } │ │ │ │ │ +208 │ │ │ │ │ +209 template │ │ │ │ │ +_2_1_0 void _U_p_d_a_t_e_V_a_l_u_e_s(T1 const &srcBase, int numBase, T2 const &srcRef, │ │ │ │ │ +211 U &dstValues, _I_n_d_e_x start=-1, _I_n_d_e_x end=-1) const { │ │ │ │ │ +212 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, dstValues, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ +213 } │ │ │ │ │ +214 │ │ │ │ │ +215 // Pointer interface for backward compatibility │ │ │ │ │ +216 template │ │ │ │ │ +_2_1_7 void _U_p_d_a_t_e_V_a_l_u_e_s(T const *src, U *dst, _I_n_d_e_x start=-1, _I_n_d_e_x end=-1) const │ │ │ │ │ +{ │ │ │ │ │ +218 this->_u_p_d_a_t_e(src, dst, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ +219 } │ │ │ │ │ +220 template │ │ │ │ │ +_2_2_1 void _U_p_d_a_t_e_V_a_l_u_e_s(T1 const *srcBase, int numBase, T2 const *srcRef, │ │ │ │ │ +222 U *dst, _I_n_d_e_x start=-1, _I_n_d_e_x end=-1) const { │ │ │ │ │ +223 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, dst, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ +224 } │ │ │ │ │ +225 │ │ │ │ │ +_2_2_7 void _C_l_e_a_r(); │ │ │ │ │ +228 │ │ │ │ │ +229protected: │ │ │ │ │ +230 │ │ │ │ │ +231 // Update values by applying cached stencil weights to new control values │ │ │ │ │ +232 template │ │ │ │ │ +_2_3_3 void _u_p_d_a_t_e( T const &srcValues, U &dstValues, │ │ │ │ │ +234 std::vector const & valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const; │ │ │ │ │ +235 template │ │ │ │ │ +_2_3_6 void _u_p_d_a_t_e( T1 const &srcBase, int numBase, T2 const &srcRef, U │ │ │ │ │ +&dstValues, │ │ │ │ │ +237 std::vector const & valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const; │ │ │ │ │ +238 │ │ │ │ │ +239 // Populate the offsets table from the stencil sizes in _sizes (factory │ │ │ │ │ +helper) │ │ │ │ │ +_2_4_0 void _g_e_n_e_r_a_t_e_O_f_f_s_e_t_s(); │ │ │ │ │ +241 │ │ │ │ │ +242 // Resize the table arrays (factory helper) │ │ │ │ │ +_2_4_3 void _r_e_s_i_z_e(int nstencils, int nelems); │ │ │ │ │ +244 │ │ │ │ │ +245 // Reserves the table arrays (factory helper) │ │ │ │ │ +_2_4_6 void _r_e_s_e_r_v_e(int nstencils, int nelems); │ │ │ │ │ +247 │ │ │ │ │ +248 // Reallocates the table arrays to remove excess capacity (factory helper) │ │ │ │ │ +_2_4_9 void _s_h_r_i_n_k_T_o_F_i_t(); │ │ │ │ │ +250 │ │ │ │ │ +251 // Performs any final operations on internal tables (factory helper) │ │ │ │ │ +_2_5_2 void _f_i_n_a_l_i_z_e(); │ │ │ │ │ +253 │ │ │ │ │ +254protected: │ │ │ │ │ +_2_5_5 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l() : ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(0) {} │ │ │ │ │ +_2_5_6 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l(int numControlVerts) │ │ │ │ │ +257 : ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(numControlVerts) │ │ │ │ │ +258 { } │ │ │ │ │ +259 │ │ │ │ │ +260 friend class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ +_2_6_1 friend class _F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r; │ │ │ │ │ +262 │ │ │ │ │ +_2_6_3 int ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s; // number of control vertices │ │ │ │ │ +264 │ │ │ │ │ +_2_6_5 std::vector ___s_i_z_e_s; // number of coefficients for each stencil │ │ │ │ │ +_2_6_6 std::vector ___o_f_f_s_e_t_s, // offset to the start of each stencil │ │ │ │ │ +_2_6_7 ___i_n_d_i_c_e_s; // indices of contributing coarse vertices │ │ │ │ │ +_2_6_8 std::vector ___w_e_i_g_h_t_s; // stencil weight coefficients │ │ │ │ │ +269}; │ │ │ │ │ +270 │ │ │ │ │ +_2_7_3class _S_t_e_n_c_i_l_T_a_b_l_e : public _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ +274protected: │ │ │ │ │ +_2_7_5 typedef _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ +276 │ │ │ │ │ +277public: │ │ │ │ │ +_2_7_8 _S_t_e_n_c_i_l _G_e_t_S_t_e_n_c_i_l(_I_n_d_e_x index) const { │ │ │ │ │ +279 return _S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ +280 } │ │ │ │ │ +_2_8_1 _S_t_e_n_c_i_l _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ +282 return _S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ +283 } │ │ │ │ │ +284 │ │ │ │ │ +285protected: │ │ │ │ │ +_2_8_6 _S_t_e_n_c_i_l_T_a_b_l_e() : _B_a_s_e_T_a_b_l_e() { } │ │ │ │ │ +_2_8_7 _S_t_e_n_c_i_l_T_a_b_l_e(int numControlVerts) : _B_a_s_e_T_a_b_l_e(numControlVerts) { } │ │ │ │ │ +_2_8_8 _S_t_e_n_c_i_l_T_a_b_l_e(int numControlVerts, │ │ │ │ │ +289 std::vector const& offsets, │ │ │ │ │ +290 std::vector const& sizes, │ │ │ │ │ +291 std::vector const& sources, │ │ │ │ │ +292 std::vector const& weights, │ │ │ │ │ +293 bool includeCoarseVerts, │ │ │ │ │ +294 size_t firstOffset) │ │ │ │ │ +295 : _B_a_s_e_T_a_b_l_e(numControlVerts, offsets, │ │ │ │ │ +296 sizes, sources, weights, includeCoarseVerts, firstOffset) { } │ │ │ │ │ +297}; │ │ │ │ │ +298 │ │ │ │ │ +299 │ │ │ │ │ +302template │ │ │ │ │ +_3_0_3class _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l : public _S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ +304public: │ │ │ │ │ +305 │ │ │ │ │ +_3_2_4 _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l( int* size, │ │ │ │ │ +325 _I_n_d_e_x * indices, │ │ │ │ │ +326 REAL * weights, │ │ │ │ │ +327 REAL * duWeights=0, │ │ │ │ │ +328 REAL * dvWeights=0, │ │ │ │ │ +329 REAL * duuWeights=0, │ │ │ │ │ +330 REAL * duvWeights=0, │ │ │ │ │ +331 REAL * dvvWeights=0) │ │ │ │ │ +332 : _S_t_e_n_c_i_l_R_e_a_l(size, indices, weights), │ │ │ │ │ +333 _duWeights(duWeights), │ │ │ │ │ +334 _dvWeights(dvWeights), │ │ │ │ │ +335 _duuWeights(duuWeights), │ │ │ │ │ +336 _duvWeights(duvWeights), │ │ │ │ │ +337 _dvvWeights(dvvWeights) { │ │ │ │ │ +338 } │ │ │ │ │ +339 │ │ │ │ │ +_3_4_1 REAL const * _G_e_t_D_u_W_e_i_g_h_t_s() const { │ │ │ │ │ +342 return _duWeights; │ │ │ │ │ +343 } │ │ │ │ │ +344 │ │ │ │ │ +_3_4_6 REAL const * _G_e_t_D_v_W_e_i_g_h_t_s() const { │ │ │ │ │ +347 return _dvWeights; │ │ │ │ │ +348 } │ │ │ │ │ +349 │ │ │ │ │ +_3_5_1 REAL const * _G_e_t_D_u_u_W_e_i_g_h_t_s() const { │ │ │ │ │ +352 return _duuWeights; │ │ │ │ │ +353 } │ │ │ │ │ +354 │ │ │ │ │ +_3_5_6 REAL const * _G_e_t_D_u_v_W_e_i_g_h_t_s() const { │ │ │ │ │ +357 return _duvWeights; │ │ │ │ │ +358 } │ │ │ │ │ +359 │ │ │ │ │ +_3_6_1 REAL const * _G_e_t_D_v_v_W_e_i_g_h_t_s() const { │ │ │ │ │ +362 return _dvvWeights; │ │ │ │ │ +363 } │ │ │ │ │ +364 │ │ │ │ │ +_3_6_6 void _N_e_x_t() { │ │ │ │ │ +367 int stride = *this->___s_i_z_e; │ │ │ │ │ +368 ++this->___s_i_z_e; │ │ │ │ │ +369 this->___i_n_d_i_c_e_s += stride; │ │ │ │ │ +370 this->___w_e_i_g_h_t_s += stride; │ │ │ │ │ +371 if (_duWeights) _duWeights += stride; │ │ │ │ │ +372 if (_dvWeights) _dvWeights += stride; │ │ │ │ │ +373 if (_duuWeights) _duuWeights += stride; │ │ │ │ │ +374 if (_duvWeights) _duvWeights += stride; │ │ │ │ │ +375 if (_dvvWeights) _dvvWeights += stride; │ │ │ │ │ +376 } │ │ │ │ │ +377 │ │ │ │ │ +378private: │ │ │ │ │ +379 │ │ │ │ │ +380 friend class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ +381 friend class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ +382 │ │ │ │ │ +383 REAL * _duWeights, // pointer to stencil u derivative limit weights │ │ │ │ │ +384 * _dvWeights, // pointer to stencil v derivative limit weights │ │ │ │ │ +385 * _duuWeights, // pointer to stencil uu derivative limit weights │ │ │ │ │ +386 * _duvWeights, // pointer to stencil uv derivative limit weights │ │ │ │ │ +387 * _dvvWeights; // pointer to stencil vv derivative limit weights │ │ │ │ │ +388}; │ │ │ │ │ +389 │ │ │ │ │ +_3_9_2class _L_i_m_i_t_S_t_e_n_c_i_l : public _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ +393protected: │ │ │ │ │ +_3_9_4 typedef _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_S_t_e_n_c_i_l; │ │ │ │ │ +395 │ │ │ │ │ +396public: │ │ │ │ │ +_3_9_7 _L_i_m_i_t_S_t_e_n_c_i_l(_B_a_s_e_S_t_e_n_c_i_l const & other) : _B_a_s_e_S_t_e_n_c_i_l(other) { } │ │ │ │ │ +_3_9_8 _L_i_m_i_t_S_t_e_n_c_i_l(int* size, _I_n_d_e_x * indices, float * weights, │ │ │ │ │ +399 float * duWeights=0, float * dvWeights=0, │ │ │ │ │ +400 float * duuWeights=0, float * duvWeights=0, float * dvvWeights=0) │ │ │ │ │ +401 : _B_a_s_e_S_t_e_n_c_i_l(size, indices, weights, │ │ │ │ │ +402 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights) { } │ │ │ │ │ +403}; │ │ │ │ │ +404 │ │ │ │ │ +405 │ │ │ │ │ +408template │ │ │ │ │ +_4_0_9class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l : public _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ +410protected: │ │ │ │ │ +_4_1_1 _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l( │ │ │ │ │ +412 int numControlVerts, │ │ │ │ │ +413 std::vector const& offsets, │ │ │ │ │ +414 std::vector const& sizes, │ │ │ │ │ +415 std::vector const& sources, │ │ │ │ │ +416 std::vector const& weights, │ │ │ │ │ +417 std::vector const& duWeights, │ │ │ │ │ +418 std::vector const& dvWeights, │ │ │ │ │ +419 std::vector const& duuWeights, │ │ │ │ │ +420 std::vector const& duvWeights, │ │ │ │ │ +421 std::vector const& dvvWeights, │ │ │ │ │ +422 bool includeCoarseVerts, │ │ │ │ │ +423 size_t firstOffset); │ │ │ │ │ +424 │ │ │ │ │ +425public: │ │ │ │ │ +426 │ │ │ │ │ +_4_2_8 _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const; │ │ │ │ │ +429 │ │ │ │ │ +_4_3_1 _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const; │ │ │ │ │ +432 │ │ │ │ │ +_4_3_4 std::vector const & _G_e_t_D_u_W_e_i_g_h_t_s() const { │ │ │ │ │ +435 return _duWeights; │ │ │ │ │ +436 } │ │ │ │ │ +437 │ │ │ │ │ +_4_3_9 std::vector const & _G_e_t_D_v_W_e_i_g_h_t_s() const { │ │ │ │ │ +440 return _dvWeights; │ │ │ │ │ +441 } │ │ │ │ │ +442 │ │ │ │ │ +_4_4_4 std::vector const & _G_e_t_D_u_u_W_e_i_g_h_t_s() const { │ │ │ │ │ +445 return _duuWeights; │ │ │ │ │ +446 } │ │ │ │ │ +447 │ │ │ │ │ +_4_4_9 std::vector const & _G_e_t_D_u_v_W_e_i_g_h_t_s() const { │ │ │ │ │ +450 return _duvWeights; │ │ │ │ │ +451 } │ │ │ │ │ +452 │ │ │ │ │ +_4_5_4 std::vector const & _G_e_t_D_v_v_W_e_i_g_h_t_s() const { │ │ │ │ │ +455 return _dvvWeights; │ │ │ │ │ +456 } │ │ │ │ │ +457 │ │ │ │ │ +475 template │ │ │ │ │ +_4_7_6 void _U_p_d_a_t_e_D_e_r_i_v_s(T const & srcValues, U & uderivs, U & vderivs, │ │ │ │ │ +477 int start=-1, int end=-1) const { │ │ │ │ │ +478 │ │ │ │ │ +479 this->_u_p_d_a_t_e(srcValues, uderivs, _duWeights, start, end); │ │ │ │ │ +480 this->_u_p_d_a_t_e(srcValues, vderivs, _dvWeights, start, end); │ │ │ │ │ +481 } │ │ │ │ │ +482 │ │ │ │ │ +483 template │ │ │ │ │ +_4_8_4 void _U_p_d_a_t_e_D_e_r_i_v_s(T1 const & srcBase, int numBase, T2 const & srcRef, │ │ │ │ │ +485 U & uderivs, U & vderivs, int start=-1, int end=-1) const { │ │ │ │ │ +486 │ │ │ │ │ +487 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uderivs, _duWeights, start, end); │ │ │ │ │ +488 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end); │ │ │ │ │ +489 } │ │ │ │ │ +490 │ │ │ │ │ +491 // Pointer interface for backward compatibility │ │ │ │ │ +492 template │ │ │ │ │ +_4_9_3 void _U_p_d_a_t_e_D_e_r_i_v_s(T const *src, U *uderivs, U *vderivs, │ │ │ │ │ +494 int start=-1, int end=-1) const { │ │ │ │ │ +495 │ │ │ │ │ +496 this->_u_p_d_a_t_e(src, uderivs, _duWeights, start, end); │ │ │ │ │ +497 this->_u_p_d_a_t_e(src, vderivs, _dvWeights, start, end); │ │ │ │ │ +498 } │ │ │ │ │ +499 template │ │ │ │ │ +_5_0_0 void _U_p_d_a_t_e_D_e_r_i_v_s(T1 const *srcBase, int numBase, T2 const *srcRef, │ │ │ │ │ +501 U *uderivs, U *vderivs, int start=-1, int end=-1) const { │ │ │ │ │ +502 │ │ │ │ │ +503 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uderivs, _duWeights, start, end); │ │ │ │ │ +504 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end); │ │ │ │ │ +505 } │ │ │ │ │ +506 │ │ │ │ │ +527 template │ │ │ │ │ +_5_2_8 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T const & srcValues, │ │ │ │ │ +529 U & uuderivs, U & uvderivs, U & vvderivs, │ │ │ │ │ +530 int start=-1, int end=-1) const { │ │ │ │ │ +531 │ │ │ │ │ +532 this->_u_p_d_a_t_e(srcValues, uuderivs, _duuWeights, start, end); │ │ │ │ │ +533 this->_u_p_d_a_t_e(srcValues, uvderivs, _duvWeights, start, end); │ │ │ │ │ +534 this->_u_p_d_a_t_e(srcValues, vvderivs, _dvvWeights, start, end); │ │ │ │ │ +535 } │ │ │ │ │ +536 │ │ │ │ │ +537 template │ │ │ │ │ +_5_3_8 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T1 const & srcBase, int numBase, T2 const & srcRef, │ │ │ │ │ +539 U & uuderivs, U & uvderivs, U & vvderivs, int start=-1, int end=-1) const { │ │ │ │ │ +540 │ │ │ │ │ +541 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end); │ │ │ │ │ +542 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end); │ │ │ │ │ +543 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end); │ │ │ │ │ +544 } │ │ │ │ │ +545 │ │ │ │ │ +546 // Pointer interface for backward compatibility │ │ │ │ │ +547 template │ │ │ │ │ +_5_4_8 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T const *src, T *uuderivs, U *uvderivs, U *vvderivs, │ │ │ │ │ +549 int start=-1, int end=-1) const { │ │ │ │ │ +550 │ │ │ │ │ +551 this->_u_p_d_a_t_e(src, uuderivs, _duuWeights, start, end); │ │ │ │ │ +552 this->_u_p_d_a_t_e(src, uvderivs, _duvWeights, start, end); │ │ │ │ │ +553 this->_u_p_d_a_t_e(src, vvderivs, _dvvWeights, start, end); │ │ │ │ │ +554 } │ │ │ │ │ +555 template │ │ │ │ │ +_5_5_6 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T1 const *srcBase, int numBase, T2 const *srcRef, │ │ │ │ │ +557 U *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const { │ │ │ │ │ +558 │ │ │ │ │ +559 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end); │ │ │ │ │ +560 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end); │ │ │ │ │ +561 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end); │ │ │ │ │ +562 } │ │ │ │ │ +563 │ │ │ │ │ +_5_6_5 void _C_l_e_a_r(); │ │ │ │ │ +566 │ │ │ │ │ +567private: │ │ │ │ │ +568 friend class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ +569 │ │ │ │ │ +570 // Resize the table arrays (factory helper) │ │ │ │ │ +571 void resize(int nstencils, int nelems); │ │ │ │ │ +572 │ │ │ │ │ +573private: │ │ │ │ │ +574 std::vector _duWeights, // u derivative limit stencil weights │ │ │ │ │ +575 _dvWeights, // v derivative limit stencil weights │ │ │ │ │ +576 _duuWeights, // uu derivative limit stencil weights │ │ │ │ │ +577 _duvWeights, // uv derivative limit stencil weights │ │ │ │ │ +578 _dvvWeights; // vv derivative limit stencil weights │ │ │ │ │ +579}; │ │ │ │ │ +580 │ │ │ │ │ +_5_8_3class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e : public _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ +584protected: │ │ │ │ │ +_5_8_5 typedef _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ +586 │ │ │ │ │ +587public: │ │ │ │ │ +_5_8_8 _L_i_m_i_t_S_t_e_n_c_i_l _G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(_I_n_d_e_x index) const { │ │ │ │ │ +589 return _L_i_m_i_t_S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ +590 } │ │ │ │ │ +_5_9_1 _L_i_m_i_t_S_t_e_n_c_i_l _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ +592 return _L_i_m_i_t_S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ +593 } │ │ │ │ │ +594 │ │ │ │ │ +595protected: │ │ │ │ │ +_5_9_6 _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e(int numControlVerts, │ │ │ │ │ +597 std::vector const& offsets, │ │ │ │ │ +598 std::vector const& sizes, │ │ │ │ │ +599 std::vector const& sources, │ │ │ │ │ +600 std::vector const& weights, │ │ │ │ │ +601 std::vector const& duWeights, │ │ │ │ │ +602 std::vector const& dvWeights, │ │ │ │ │ +603 std::vector const& duuWeights, │ │ │ │ │ +604 std::vector const& duvWeights, │ │ │ │ │ +605 std::vector const& dvvWeights, │ │ │ │ │ +606 bool includeCoarseVerts, │ │ │ │ │ +607 size_t firstOffset) │ │ │ │ │ +608 : _B_a_s_e_T_a_b_l_e(numControlVerts, │ │ │ │ │ +609 offsets, sizes, sources, weights, │ │ │ │ │ +610 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights, │ │ │ │ │ +611 includeCoarseVerts, firstOffset) { } │ │ │ │ │ +612}; │ │ │ │ │ +613 │ │ │ │ │ +614 │ │ │ │ │ +615// Update values by applying cached stencil weights to new control values │ │ │ │ │ +616template │ │ │ │ │ +617template void │ │ │ │ │ +_6_1_8_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_u_p_d_a_t_e(T1 const &srcBase, int numBase, │ │ │ │ │ +619 T2 const &srcRef, U &dstValues, │ │ │ │ │ +620 std::vector const &valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const { │ │ │ │ │ +621 │ │ │ │ │ +622 int const * sizes = &_sizes.at(0); │ │ │ │ │ +623 _I_n_d_e_x const * indices = &_indices.at(0); │ │ │ │ │ +624 REAL const * weights = &valueWeights.at(0); │ │ │ │ │ +625 │ │ │ │ │ +626 if (start > 0) { │ │ │ │ │ +627 assert(start < (_I_n_d_e_x)_offsets.size()); │ │ │ │ │ +628 sizes += start; │ │ │ │ │ +629 indices += _offsets[start]; │ │ │ │ │ +630 weights += _offsets[start]; │ │ │ │ │ +631 } else { │ │ │ │ │ +632 start = 0; │ │ │ │ │ +633 } │ │ │ │ │ +634 │ │ │ │ │ +635 int nstencils = ((end < start) ? GetNumStencils() : end) - start; │ │ │ │ │ +636 │ │ │ │ │ +637 for (int i = 0; i < nstencils; ++i, ++sizes) { │ │ │ │ │ +638 dstValues[start + i].Clear(); │ │ │ │ │ +639 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) { │ │ │ │ │ +640 if (*indices < numBase) { │ │ │ │ │ +641 dstValues[start + i].AddWithWeight(srcBase[*indices], *weights); │ │ │ │ │ +642 } else { │ │ │ │ │ +643 dstValues[start + i].AddWithWeight(srcRef[*indices - numBase], *weights); │ │ │ │ │ +644 } │ │ │ │ │ +645 } │ │ │ │ │ +646 } │ │ │ │ │ +647} │ │ │ │ │ +648template │ │ │ │ │ +649template void │ │ │ │ │ +_6_5_0_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_u_p_d_a_t_e(T const &srcValues, U &dstValues, │ │ │ │ │ +651 std::vector const &valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const { │ │ │ │ │ +652 │ │ │ │ │ +653 int const * sizes = &_sizes.at(0); │ │ │ │ │ +654 _I_n_d_e_x const * indices = &_indices.at(0); │ │ │ │ │ +655 REAL const * weights = &valueWeights.at(0); │ │ │ │ │ +656 │ │ │ │ │ +657 if (start > 0) { │ │ │ │ │ +658 assert(start < (_I_n_d_e_x)_offsets.size()); │ │ │ │ │ +659 sizes += start; │ │ │ │ │ +660 indices += _offsets[start]; │ │ │ │ │ +661 weights += _offsets[start]; │ │ │ │ │ +662 } else { │ │ │ │ │ +663 start = 0; │ │ │ │ │ +664 } │ │ │ │ │ +665 │ │ │ │ │ +666 int nstencils = ((end < start) ? GetNumStencils() : end) - start; │ │ │ │ │ +667 │ │ │ │ │ +668 for (int i = 0; i < nstencils; ++i, ++sizes) { │ │ │ │ │ +669 dstValues[start + i].Clear(); │ │ │ │ │ +670 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) { │ │ │ │ │ +671 dstValues[start + i].AddWithWeight(srcValues[*indices], *weights); │ │ │ │ │ +672 } │ │ │ │ │ +673 } │ │ │ │ │ +674} │ │ │ │ │ +675 │ │ │ │ │ +676template │ │ │ │ │ +677inline void │ │ │ │ │ +_6_7_8_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_g_e_n_e_r_a_t_e_O_f_f_s_e_t_s() { │ │ │ │ │ +679 _I_n_d_e_x offset=0; │ │ │ │ │ +680 int noffsets = (int)_sizes.size(); │ │ │ │ │ +681 _offsets.resize(noffsets); │ │ │ │ │ +682 for (int i=0; i<(int)_sizes.size(); ++i ) { │ │ │ │ │ +683 _offsets[i]=offset; │ │ │ │ │ +684 offset+=_sizes[i]; │ │ │ │ │ +685 } │ │ │ │ │ +686} │ │ │ │ │ +687 │ │ │ │ │ +688template │ │ │ │ │ +689inline void │ │ │ │ │ +_6_9_0_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_i_z_e(int nstencils, int nelems) { │ │ │ │ │ +691 _sizes.resize(nstencils); │ │ │ │ │ +692 _indices.resize(nelems); │ │ │ │ │ +693 _weights.resize(nelems); │ │ │ │ │ +694} │ │ │ │ │ +695 │ │ │ │ │ +696template │ │ │ │ │ +697inline void │ │ │ │ │ +_6_9_8_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_e_r_v_e(int nstencils, int nelems) { │ │ │ │ │ +699 _sizes.reserve(nstencils); │ │ │ │ │ +700 _indices.reserve(nelems); │ │ │ │ │ +701 _weights.reserve(nelems); │ │ │ │ │ +702} │ │ │ │ │ +703 │ │ │ │ │ +704template │ │ │ │ │ +705inline void │ │ │ │ │ +_7_0_6_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_s_h_r_i_n_k_T_o_F_i_t() { │ │ │ │ │ +707 std::vector(_sizes).swap(_sizes); │ │ │ │ │ +708 std::vector(_indices).swap(_indices); │ │ │ │ │ +709 std::vector(_weights).swap(_weights); │ │ │ │ │ +710} │ │ │ │ │ +711 │ │ │ │ │ +712template │ │ │ │ │ +713inline void │ │ │ │ │ +_7_1_4_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_f_i_n_a_l_i_z_e() { │ │ │ │ │ +715 shrinkToFit(); │ │ │ │ │ +716 generateOffsets(); │ │ │ │ │ +717} │ │ │ │ │ +718 │ │ │ │ │ +719// Returns a Stencil at index i in the table │ │ │ │ │ +720template │ │ │ │ │ +721inline _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> │ │ │ │ │ +_7_2_2_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_G_e_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const { │ │ │ │ │ +723 assert((! _offsets.empty()) && i<(int)_offsets.size()); │ │ │ │ │ +724 │ │ │ │ │ +725 _I_n_d_e_x ofs = _offsets[i]; │ │ │ │ │ +726 │ │ │ │ │ +727 return _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>(const_cast(&_sizes[i]), │ │ │ │ │ +728 const_cast<_I_n_d_e_x*>(&_indices[ofs]), │ │ │ │ │ +729 const_cast(&_weights[ofs])); │ │ │ │ │ +730} │ │ │ │ │ +731 │ │ │ │ │ +732template │ │ │ │ │ +733inline _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> │ │ │ │ │ +_7_3_4_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ +735 return GetStencil(index); │ │ │ │ │ +736} │ │ │ │ │ +737 │ │ │ │ │ +738template │ │ │ │ │ +739inline void │ │ │ │ │ +740_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_i_z_e(int nstencils, int nelems) { │ │ │ │ │ +741 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_i_z_e(nstencils, nelems); │ │ │ │ │ +742 _duWeights.resize(nelems); │ │ │ │ │ +743 _dvWeights.resize(nelems); │ │ │ │ │ +744} │ │ │ │ │ +745 │ │ │ │ │ +746// Returns a LimitStencil at index i in the table │ │ │ │ │ +747template │ │ │ │ │ +748inline LimitStencilReal │ │ │ │ │ +_7_4_9_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const { │ │ │ │ │ +750 assert((! this->GetOffsets().empty()) && i<(int)this->GetOffsets().size()); │ │ │ │ │ +751 │ │ │ │ │ +752 _I_n_d_e_x ofs = this->GetOffsets()[i]; │ │ │ │ │ +753 │ │ │ │ │ +754 if (!_duWeights.empty() && !_dvWeights.empty() && │ │ │ │ │ +755 !_duuWeights.empty() && !_duvWeights.empty() && !_dvvWeights.empty()) { │ │ │ │ │ +756 return _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>( │ │ │ │ │ +757 const_cast(&this->GetSizes()[i]), │ │ │ │ │ +758 const_cast<_I_n_d_e_x *>(&this->GetControlIndices()[ofs]), │ │ │ │ │ +759 const_cast(&this->GetWeights()[ofs]), │ │ │ │ │ +760 const_cast(&GetDuWeights()[ofs]), │ │ │ │ │ +761 const_cast(&GetDvWeights()[ofs]), │ │ │ │ │ +762 const_cast(&GetDuuWeights()[ofs]), │ │ │ │ │ +763 const_cast(&GetDuvWeights()[ofs]), │ │ │ │ │ +764 const_cast(&GetDvvWeights()[ofs]) ); │ │ │ │ │ +765 } else if (!_duWeights.empty() && !_dvWeights.empty()) { │ │ │ │ │ +766 return _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>( │ │ │ │ │ +767 const_cast(&this->GetSizes()[i]), │ │ │ │ │ +768 const_cast<_I_n_d_e_x *>(&this->GetControlIndices()[ofs]), │ │ │ │ │ +769 const_cast(&this->GetWeights()[ofs]), │ │ │ │ │ +770 const_cast(&GetDuWeights()[ofs]), │ │ │ │ │ +771 const_cast(&GetDvWeights()[ofs]) ); │ │ │ │ │ +772 } else { │ │ │ │ │ +773 return _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>( │ │ │ │ │ +774 const_cast(&this->GetSizes()[i]), │ │ │ │ │ +775 const_cast<_I_n_d_e_x *>(&this->GetControlIndices()[ofs]), │ │ │ │ │ +776 const_cast(&this->GetWeights()[ofs]) ); │ │ │ │ │ +777 } │ │ │ │ │ +778} │ │ │ │ │ +779 │ │ │ │ │ +780template │ │ │ │ │ +781inline _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> │ │ │ │ │ +_7_8_2_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ +783 return GetLimitStencil(index); │ │ │ │ │ +784} │ │ │ │ │ +785 │ │ │ │ │ +786} // end namespace Far │ │ │ │ │ +787 │ │ │ │ │ +788} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +789using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +790 │ │ │ │ │ +791} // end namespace OpenSubdiv │ │ │ │ │ +792 │ │ │ │ │ +793#endif // OPENSUBDIV3_FAR_STENCILTABLE_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ Vtr::Index Index │ │ │ │ │ DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -A simple reference to raw topology data for use with TopologyRefinerFactory. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_f_v_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -FVarChannel const * fvarChannels │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ -int numVertices │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_o_r_n_e_r_V_e_r_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -Index const * cornerVertexIndices │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_v_e_r_t_I_n_d_i_c_e_s_P_e_r_F_a_c_e │ │ │ │ │ -Index const * vertIndicesPerFace │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_r_e_a_s_e_V_e_r_t_e_x_I_n_d_e_x_P_a_i_r_s │ │ │ │ │ -Index const * creaseVertexIndexPairs │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_h_o_l_e_I_n_d_i_c_e_s │ │ │ │ │ -Index const * holeIndices │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_F_a_c_e_s │ │ │ │ │ -int numFaces │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_C_o_r_n_e_r_s │ │ │ │ │ -int numCorners │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_o_r_n_e_r_W_e_i_g_h_t_s │ │ │ │ │ -float const * cornerWeights │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_i_s_L_e_f_t_H_a_n_d_e_d │ │ │ │ │ -bool isLeftHanded │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_V_e_r_t_s_P_e_r_F_a_c_e │ │ │ │ │ -int const * numVertsPerFace │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -TopologyDescriptor() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_r_e_a_s_e_W_e_i_g_h_t_s │ │ │ │ │ -float const * creaseWeights │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_C_r_e_a_s_e_s │ │ │ │ │ -int numCreases │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_H_o_l_e_s │ │ │ │ │ -int numHoles │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -int numFVarChannels │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l_:_: │ │ │ │ │ -_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │ -FVarChannel() │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l_:_: │ │ │ │ │ -_v_a_l_u_e_I_n_d_i_c_e_s │ │ │ │ │ -Index const * valueIndices │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l_:_:_n_u_m_V_a_l_u_e_s │ │ │ │ │ -int numValues │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ -static bool assignComponentTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ -&mesh) │ │ │ │ │ -Specify the relationships between vertices, faces, etc. ie the face-vertices, │ │ │ │ │ -vertex-faces,... │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_2_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y │ │ │ │ │ -static void reportInvalidTopology(TopologyError errCode, char const *msg, MESH │ │ │ │ │ -const &mesh) │ │ │ │ │ -(Optional) Control run-time topology validation and error reporting │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_7_0_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s │ │ │ │ │ -static bool assignComponentTags(TopologyRefiner &newRefiner, MESH const &mesh) │ │ │ │ │ -(Optional) Specify edge or vertex sharpness or face holes │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_9_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ -static bool resizeComponentTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ -&mesh) │ │ │ │ │ -Specify the number of vertices, faces, face-vertices, etc. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y │ │ │ │ │ -static bool assignFaceVaryingTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ -&mesh) │ │ │ │ │ -(Optional) Specify face-varying data per face │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ -Stores topology data for a specified set of refinement options. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ +A specialized factory for StencilTable. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ +A specialized factory for LimitStencilTable. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ +Vertex stencil descriptor. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ +StencilReal() │ │ │ │ │ +Default constructor. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:___s_i_z_e │ │ │ │ │ +int * _size │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_0_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ +StencilReal(int *size, Index *indices, REAL *weights) │ │ │ │ │ +Constructor. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_N_e_x_t │ │ │ │ │ +void Next() │ │ │ │ │ +Advance to the next stencil in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ +StencilReal(StencilReal const &other) │ │ │ │ │ +Copy constructor. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:___i_n_d_i_c_e_s │ │ │ │ │ +Index * _indices │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_V_e_r_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ +Index const * GetVertexIndices() const │ │ │ │ │ +Returns the control vertices' indices. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_S_i_z_e │ │ │ │ │ +int GetSize() const │ │ │ │ │ +Returns the size of the stencil. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:___w_e_i_g_h_t_s │ │ │ │ │ +REAL * _weights │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_S_i_z_e_P_t_r │ │ │ │ │ +int * GetSizePtr() const │ │ │ │ │ +Returns the size of the stencil as a pointer. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_W_e_i_g_h_t_s │ │ │ │ │ +REAL const * GetWeights() const │ │ │ │ │ +Returns the interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l │ │ │ │ │ +Vertex stencil class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_S_t_e_n_c_i_l │ │ │ │ │ +Stencil(BaseStencil const &other) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_2_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_S_t_e_n_c_i_l │ │ │ │ │ +Stencil(int *size, Index *indices, float *weights) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_2_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_B_a_s_e_S_t_e_n_c_i_l │ │ │ │ │ +StencilReal< float > BaseStencil │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_S_t_e_n_c_i_l │ │ │ │ │ +Stencil() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +Table of subdivision stencils. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ +int GetNumControlVertices() const │ │ │ │ │ +Returns the number of control vertices indexed in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___s_i_z_e_s │ │ │ │ │ +std::vector< int > _sizes │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r │ │ │ │ │ +friend class Far::PatchTableBuilder │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_u_p_d_a_t_e │ │ │ │ │ +void update(T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues, │ │ │ │ │ +std::vector< REAL > const &valueWeights, Index start, Index end) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_1_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ +void UpdateValues(T1 const &srcBase, int numBase, T2 const &srcRef, U │ │ │ │ │ +&dstValues, Index start=-1, Index end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_1_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_C_o_n_t_r_o_l_I_n_d_i_c_e_s │ │ │ │ │ +std::vector< Index > const & GetControlIndices() const │ │ │ │ │ +Returns the indices of the control vertices. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_f_i_n_a_l_i_z_e │ │ │ │ │ +void finalize() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_1_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ +StencilReal< REAL > operator[](Index index) const │ │ │ │ │ +Returns the stencil at index i in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ +int _numControlVertices │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_u_p_d_a_t_e │ │ │ │ │ +void update(T const &srcValues, U &dstValues, std::vector< REAL > const │ │ │ │ │ +&valueWeights, Index start, Index end) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_5_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_S_i_z_e_s │ │ │ │ │ +std::vector< int > const & GetSizes() const │ │ │ │ │ +Returns the number of control vertices of each stencil in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ +int GetNumStencils() const │ │ │ │ │ +Returns the number of stencils in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_~_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +virtual ~StencilTableReal() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_O_f_f_s_e_t_s │ │ │ │ │ +std::vector< Index > const & GetOffsets() const │ │ │ │ │ +Returns the offset to a given stencil (factory may leave empty) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_S_t_e_n_c_i_l │ │ │ │ │ +StencilReal< REAL > GetStencil(Index i) const │ │ │ │ │ +Returns a Stencil at index i in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_2_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_s_h_r_i_n_k_T_o_F_i_t │ │ │ │ │ +void shrinkToFit() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_0_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_g_e_n_e_r_a_t_e_O_f_f_s_e_t_s │ │ │ │ │ +void generateOffsets() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_C_l_e_a_r │ │ │ │ │ +void Clear() │ │ │ │ │ +Clears the stencils from the table. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___o_f_f_s_e_t_s │ │ │ │ │ +std::vector< Index > _offsets │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___w_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > _weights │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_r_e_s_i_z_e │ │ │ │ │ +void resize(int nstencils, int nelems) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_9_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_W_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > const & GetWeights() const │ │ │ │ │ +Returns the stencil interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ +void UpdateValues(T1 const *srcBase, int numBase, T2 const *srcRef, U *dst, │ │ │ │ │ +Index start=-1, Index end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +StencilTableReal(int numControlVerts, std::vector< int > const &offsets, std:: │ │ │ │ │ +vector< int > const &sizes, std::vector< int > const &sources, std::vector< │ │ │ │ │ +REAL > const &weights, bool includeCoarseVerts, size_t firstOffset) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___i_n_d_i_c_e_s │ │ │ │ │ +std::vector< Index > _indices │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +StencilTableReal() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_r_e_s_e_r_v_e │ │ │ │ │ +void reserve(int nstencils, int nelems) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ +void UpdateValues(T const *src, U *dst, Index start=-1, Index end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_1_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ +void UpdateValues(T const &srcValues, U &dstValues, Index start=-1, Index end=- │ │ │ │ │ +1) const │ │ │ │ │ +Updates point values based on the control values. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_0_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTable(int numControlVerts, std::vector< int > const &offsets, std:: │ │ │ │ │ +vector< int > const &sizes, std::vector< int > const &sources, std::vector< │ │ │ │ │ +float > const &weights, bool includeCoarseVerts, size_t firstOffset) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTable(int numControlVerts) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_B_a_s_e_T_a_b_l_e │ │ │ │ │ +StencilTableReal< float > BaseTable │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_S_t_e_n_c_i_l │ │ │ │ │ +Stencil GetStencil(Index index) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ +Stencil operator[](Index index) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTable() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ +Limit point stencil descriptor. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_0_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s │ │ │ │ │ +REAL const * GetDuvWeights() const │ │ │ │ │ +Returns the uv derivative weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_v_W_e_i_g_h_t_s │ │ │ │ │ +REAL const * GetDvWeights() const │ │ │ │ │ +Returns the v derivative weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_N_e_x_t │ │ │ │ │ +void Next() │ │ │ │ │ +Advance to the next stencil in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s │ │ │ │ │ +REAL const * GetDvvWeights() const │ │ │ │ │ +Returns the vv derivative weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ +LimitStencilReal(int *size, Index *indices, REAL *weights, REAL *duWeights=0, │ │ │ │ │ +REAL *dvWeights=0, REAL *duuWeights=0, REAL *duvWeights=0, REAL *dvvWeights=0) │ │ │ │ │ +Constructor. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_2_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_u_W_e_i_g_h_t_s │ │ │ │ │ +REAL const * GetDuWeights() const │ │ │ │ │ +Returns the u derivative weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s │ │ │ │ │ +REAL const * GetDuuWeights() const │ │ │ │ │ +Returns the uu derivative weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ +Limit point stencil class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_:_:_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ +LimitStencil(BaseStencil const &other) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_:_:_B_a_s_e_S_t_e_n_c_i_l │ │ │ │ │ +LimitStencilReal< float > BaseStencil │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_:_:_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ +LimitStencil(int *size, Index *indices, float *weights, float *duWeights=0, │ │ │ │ │ +float *dvWeights=0, float *duuWeights=0, float *duvWeights=0, float │ │ │ │ │ +*dvvWeights=0) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +Table of limit subdivision stencils. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_0_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > const & GetDuuWeights() const │ │ │ │ │ +Returns the 'uu' derivative stencil interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ +LimitStencilReal< REAL > operator[](Index index) const │ │ │ │ │ +Returns the limit stencil at index i in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > const & GetDvvWeights() const │ │ │ │ │ +Returns the 'vv' derivative stencil interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ +void UpdateDerivs(T const *src, U *uderivs, U *vderivs, int start=-1, int end=- │ │ │ │ │ +1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ +void Update2ndDerivs(T const *src, T *uuderivs, U *uvderivs, U *vvderivs, int │ │ │ │ │ +start=-1, int end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_v_W_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > const & GetDvWeights() const │ │ │ │ │ +Returns the 'v' derivative stencil interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ +void Update2ndDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U │ │ │ │ │ +*uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ +void UpdateDerivs(T const &srcValues, U &uderivs, U &vderivs, int start=-1, int │ │ │ │ │ +end=-1) const │ │ │ │ │ +Updates derivative values based on the control values. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ +LimitStencilReal< REAL > GetLimitStencil(Index i) const │ │ │ │ │ +Returns a LimitStencil at index i in the table. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_: │ │ │ │ │ +_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +LimitStencilTableReal(int numControlVerts, std::vector< int > const &offsets, │ │ │ │ │ +std::vector< int > const &sizes, std::vector< int > const &sources, std:: │ │ │ │ │ +vector< REAL > const &weights, std::vector< REAL > const &duWeights, std:: │ │ │ │ │ +vector< REAL > const &dvWeights, std::vector< REAL > const &duuWeights, std:: │ │ │ │ │ +vector< REAL > const &duvWeights, std::vector< REAL > const &dvvWeights, bool │ │ │ │ │ +includeCoarseVerts, size_t firstOffset) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ +void Update2ndDerivs(T const &srcValues, U &uuderivs, U &uvderivs, U &vvderivs, │ │ │ │ │ +int start=-1, int end=-1) const │ │ │ │ │ +Updates 2nd derivative values based on the control values. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_2_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_u_W_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > const & GetDuWeights() const │ │ │ │ │ +Returns the 'u' derivative stencil interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_C_l_e_a_r │ │ │ │ │ +void Clear() │ │ │ │ │ +Clears the stencils from the table. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ +void Update2ndDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U │ │ │ │ │ +&uuderivs, U &uvderivs, U &vvderivs, int start=-1, int end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_3_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s │ │ │ │ │ +std::vector< REAL > const & GetDuvWeights() const │ │ │ │ │ +Returns the 'uv' derivative stencil interpolation weights. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ +void UpdateDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U &uderivs, │ │ │ │ │ +U &vderivs, int start=-1, int end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ +void UpdateDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U *uderivs, │ │ │ │ │ +U *vderivs, int start=-1, int end=-1) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_B_a_s_e_T_a_b_l_e │ │ │ │ │ +LimitStencilTableReal< float > BaseTable │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ +LimitStencil GetLimitStencil(Index index) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +LimitStencilTable(int numControlVerts, std::vector< int > const &offsets, std:: │ │ │ │ │ +vector< int > const &sizes, std::vector< int > const &sources, std::vector< │ │ │ │ │ +float > const &weights, std::vector< float > const &duWeights, std::vector< │ │ │ │ │ +float > const &dvWeights, std::vector< float > const &duuWeights, std::vector< │ │ │ │ │ +float > const &duvWeights, std::vector< float > const &dvvWeights, bool │ │ │ │ │ +includeCoarseVerts, size_t firstOffset) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_9_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ +LimitStencil operator[](Index index) const │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_9_1 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _s_t_e_n_c_i_l_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00716.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/stencilTableFactory.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/topologyDescriptor.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,43 +90,31 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
stencilTableFactory.h File Reference
│ │ │ │ +
topologyDescriptor.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ -#include <vector>
│ │ │ │ +#include "../far/topologyRefiner.h"
│ │ │ │ +#include "../far/topologyRefinerFactory.h"
│ │ │ │ +#include "../far/error.h"
│ │ │ │ +#include <cassert>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  StencilTableFactoryReal< REAL >
 A specialized factory for StencilTable. More...
struct  TopologyDescriptor
 A simple reference to raw topology data for use with TopologyRefinerFactory. More...
 
struct  StencilTableFactoryReal< REAL >::Options
 
class  LimitStencilTableFactoryReal< REAL >
 A specialized factory for LimitStencilTable. More...
 
struct  LimitStencilTableFactoryReal< REAL >::Options
 
struct  LimitStencilTableFactoryReal< REAL >::LocationArray
 Descriptor for limit surface locations. More...
 
class  StencilTableFactory
 Stencil table factory class wrapping the template for compatibility. More...
 
class  LimitStencilTableFactory
 Stencil table factory class wrapping the template for compatibility. More...
struct  TopologyDescriptor::FVarChannel
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -135,13 +123,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,43 +1,30 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -stencilTableFactory.h File Reference │ │ │ │ │ +topologyDescriptor.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_e_r_r_o_r_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ - class   _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  A specialized factory for _S_t_e_n_c_i_l_T_a_b_l_e. _M_o_r_e_._._. │ │ │ │ │ +struct   _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +  A simple reference to raw topology data for use with │ │ │ │ │ + _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -struct   _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _>_:_:_O_p_t_i_o_n_s │ │ │ │ │ -  │ │ │ │ │ - class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  A specialized factory for _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -struct   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _>_:_:_O_p_t_i_o_n_s │ │ │ │ │ -  │ │ │ │ │ -struct   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _>_:_:_L_o_c_a_t_i_o_n_A_r_r_a_y │ │ │ │ │ -  Descriptor for limit surface locations. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ - class   _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ -  _S_t_e_n_c_i_l table factory class wrapping the template for compatibility. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ - class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ -  _S_t_e_n_c_i_l table factory class wrapping the template for compatibility. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ +struct   _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00716.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,9 +1,4 @@ │ │ │ │ │ var a00716 = [ │ │ │ │ │ - ["StencilTableFactoryReal< REAL >", "a01045.html", "a01045"], │ │ │ │ │ - ["Options", "a01085.html", "a01085"], │ │ │ │ │ - ["LimitStencilTableFactoryReal< REAL >", "a01049.html", "a01049"], │ │ │ │ │ - ["Options", "a01089.html", "a01089"], │ │ │ │ │ - ["LocationArray", "a01093.html", "a01093"], │ │ │ │ │ - ["StencilTableFactory", "a01097.html", null], │ │ │ │ │ - ["LimitStencilTableFactory", "a01101.html", null] │ │ │ │ │ + ["TopologyDescriptor", "a01105.html", "a01105"], │ │ │ │ │ + ["FVarChannel", "a01109.html", "a01109"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00716_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/stencilTableFactory.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/topologyDescriptor.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
stencilTableFactory.h
│ │ │ │ +
topologyDescriptor.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2013 Pixar
│ │ │ │ +
2// Copyright 2014 DreamWorks Animation LLC.
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,358 +118,146 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H
│ │ │ │ -
27
│ │ │ │ -
28#include "../version.h"
│ │ │ │ -
29
│ │ │ │ -
30#include "../far/patchTable.h"
│ │ │ │ -
31
│ │ │ │ -
32#include <vector>
│ │ │ │ -
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Far {
│ │ │ │ -
38
│ │ │ │ -
39class TopologyRefiner;
│ │ │ │ -
40
│ │ │ │ -
41template <typename REAL> class StencilReal;
│ │ │ │ -
42template <typename REAL> class StencilTableReal;
│ │ │ │ -
43
│ │ │ │ -
44template <typename REAL> class LimitStencilReal;
│ │ │ │ -
45template <typename REAL> class LimitStencilTableReal;
│ │ │ │ -
46
│ │ │ │ -
47
│ │ │ │ -
50template <typename REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
52
│ │ │ │ -
53public:
│ │ │ │ -
54
│ │ │ │ -
│ │ │ │ -
55 enum Mode {
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
59 };
│ │ │ │ -
│ │ │ │ +
24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H
│ │ │ │ +
25#define OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H
│ │ │ │ +
26
│ │ │ │ +
27#include "../version.h"
│ │ │ │ +
28
│ │ │ │ +
29#include "../far/topologyRefiner.h"
│ │ │ │ +
30#include "../far/topologyRefinerFactory.h"
│ │ │ │ +
31#include "../far/error.h"
│ │ │ │ +
32
│ │ │ │ +
33#include <cassert>
│ │ │ │ +
34
│ │ │ │ +
35namespace OpenSubdiv {
│ │ │ │ +
36namespace OPENSUBDIV_VERSION {
│ │ │ │ +
37
│ │ │ │ +
38namespace Far {
│ │ │ │ +
39
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
50
│ │ │ │ + │ │ │ │ + │ │ │ │ +
53
│ │ │ │ +
54 int const * numVertsPerFace;
│ │ │ │ + │ │ │ │ +
56
│ │ │ │ + │ │ │ │ + │ │ │ │ +
59 float const * creaseWeights;
│ │ │ │
60
│ │ │ │ -
│ │ │ │ -
61 struct Options {
│ │ │ │ -
62
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
64 generateOffsets(false),
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
68 maxLevel(10),
│ │ │ │ -
69 fvarChannel(0) { }
│ │ │ │ -
│ │ │ │ -
70
│ │ │ │ -
71 unsigned int interpolationMode : 2,
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
79 unsigned int fvarChannel;
│ │ │ │ -
81 };
│ │ │ │ -
│ │ │ │ -
82
│ │ │ │ - │ │ │ │ -
95 TopologyRefiner const & refiner, Options options = Options());
│ │ │ │ -
96
│ │ │ │ -
97
│ │ │ │ - │ │ │ │ -
111 int numTables, StencilTableReal<REAL> const ** tables);
│ │ │ │ -
112
│ │ │ │ + │ │ │ │ + │ │ │ │ +
63 float const * cornerWeights;
│ │ │ │ +
64
│ │ │ │ + │ │ │ │ + │ │ │ │ +
67
│ │ │ │ + │ │ │ │ +
69
│ │ │ │ +
70 // Face-varying data channel -- value indices correspond to vertex indices,
│ │ │ │ +
71 // i.e. one for every vertex of every face:
│ │ │ │ +
72 //
│ │ │ │ +
│ │ │ │ +
73 struct FVarChannel {
│ │ │ │ +
74
│ │ │ │ + │ │ │ │ + │ │ │ │ +
77
│ │ │ │ + │ │ │ │ +
79 };
│ │ │ │ +
│ │ │ │ +
80
│ │ │ │ + │ │ │ │ + │ │ │ │ +
83
│ │ │ │ + │ │ │ │ +
85};
│ │ │ │ +
│ │ │ │ +
86
│ │ │ │ +
87
│ │ │ │ +
88//
│ │ │ │ +
89// Forward declarations of required TopologyRefinerFactory<TopologyDescriptor>
│ │ │ │ +
90// specializations (defined internally):
│ │ │ │ +
91//
│ │ │ │ +
92// @cond EXCLUDE_DOXYGEN
│ │ │ │ +
93
│ │ │ │ +
94template <>
│ │ │ │ +
95bool
│ │ │ │ + │ │ │ │ +
97 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ +
98
│ │ │ │ +
99template <>
│ │ │ │ +
100bool
│ │ │ │ + │ │ │ │ +
102 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ +
103
│ │ │ │ +
104template <>
│ │ │ │ +
105bool
│ │ │ │ + │ │ │ │ +
107 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │ +
108
│ │ │ │ +
109template <>
│ │ │ │ +
110bool
│ │ │ │ + │ │ │ │ +
112 TopologyRefiner & refiner, TopologyDescriptor const & desc);
│ │ │ │
113
│ │ │ │ - │ │ │ │ -
129 TopologyRefiner const &refiner,
│ │ │ │ -
130 StencilTableReal<REAL> const *baseStencilTable,
│ │ │ │ -
131 StencilTableReal<REAL> const *localPointStencilTable,
│ │ │ │ -
132 bool factorize = true);
│ │ │ │ -
133
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
149 TopologyRefiner const &refiner,
│ │ │ │ -
150 StencilTableReal<REAL> const *baseStencilTable,
│ │ │ │ -
151 StencilTableReal<REAL> const *localPointStencilTable,
│ │ │ │ -
152 bool factorize = true) {
│ │ │ │ - │ │ │ │ -
154 refiner, baseStencilTable, localPointStencilTable, factorize);
│ │ │ │ -
155 }
│ │ │ │ -
│ │ │ │ -
156
│ │ │ │ - │ │ │ │ -
175 TopologyRefiner const &refiner,
│ │ │ │ -
176 StencilTableReal<REAL> const *baseStencilTable,
│ │ │ │ -
177 StencilTableReal<REAL> const *localPointStencilTable,
│ │ │ │ -
178 int channel = 0,
│ │ │ │ -
179 bool factorize = true);
│ │ │ │ -
180
│ │ │ │ -
181private:
│ │ │ │ -
182
│ │ │ │ -
183 // Generate stencils for the coarse control-vertices (single weight = 1.0f)
│ │ │ │ -
184 static void generateControlVertStencils(
│ │ │ │ -
185 int numControlVerts,
│ │ │ │ -
186 StencilReal<REAL> & dst);
│ │ │ │ -
187
│ │ │ │ -
188 // Internal method to splice local point stencils
│ │ │ │ -
189 static StencilTableReal<REAL> const * appendLocalPointStencilTable(
│ │ │ │ -
190 TopologyRefiner const &refiner,
│ │ │ │ -
191 StencilTableReal<REAL> const * baseStencilTable,
│ │ │ │ -
192 StencilTableReal<REAL> const * localPointStencilTable,
│ │ │ │ -
193 int channel,
│ │ │ │ -
194 bool factorize);
│ │ │ │ -
195};
│ │ │ │ -
│ │ │ │ -
196
│ │ │ │ -
208template <typename REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
210
│ │ │ │ -
211public:
│ │ │ │ -
212
│ │ │ │ -
│ │ │ │ -
213 enum Mode {
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
217 };
│ │ │ │ -
│ │ │ │ -
218
│ │ │ │ -
│ │ │ │ -
219 struct Options {
│ │ │ │ -
220
│ │ │ │ -
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
224 fvarChannel(0) { }
│ │ │ │ -
│ │ │ │ -
225
│ │ │ │ -
226 unsigned int interpolationMode : 2,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
229 unsigned int fvarChannel;
│ │ │ │ -
230 };
│ │ │ │ -
│ │ │ │ -
231
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
234
│ │ │ │ -
235 LocationArray() : ptexIdx(-1), numLocations(0), s(0), t(0) { }
│ │ │ │ -
236
│ │ │ │ - │ │ │ │ - │ │ │ │ -
239
│ │ │ │ -
240 REAL const * s,
│ │ │ │ -
241 * t;
│ │ │ │ -
242 };
│ │ │ │ -
│ │ │ │ -
243
│ │ │ │ -
244 typedef std::vector<LocationArray> LocationArrayVec;
│ │ │ │ -
245
│ │ │ │ - │ │ │ │ -
270 TopologyRefiner const & refiner,
│ │ │ │ -
271 LocationArrayVec const & locationArrays,
│ │ │ │ -
272 StencilTableReal<REAL> const * cvStencils = 0,
│ │ │ │ -
273 PatchTable const * patchTable = 0,
│ │ │ │ -
274 Options options = Options());
│ │ │ │ -
275
│ │ │ │ -
276};
│ │ │ │ -
│ │ │ │ -
277
│ │ │ │ -
278
│ │ │ │ -
279//
│ │ │ │ -
280// Public wrapper classes for the templates
│ │ │ │ -
281//
│ │ │ │ -
282class Stencil;
│ │ │ │ -
283class StencilTable;
│ │ │ │ -
284
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
288private:
│ │ │ │ - │ │ │ │ - │ │ │ │ -
291
│ │ │ │ -
292public:
│ │ │ │ -
│ │ │ │ -
293 static StencilTable const * Create(
│ │ │ │ -
294 TopologyRefiner const & refiner, Options options = Options()) {
│ │ │ │ -
295
│ │ │ │ -
296 return static_cast<StencilTable const *>(
│ │ │ │ -
297 BaseFactory::Create(refiner, options));
│ │ │ │ -
298 }
│ │ │ │ -
│ │ │ │ -
299
│ │ │ │ -
│ │ │ │ -
300 static StencilTable const * Create(
│ │ │ │ -
301 int numTables, StencilTable const ** tables) {
│ │ │ │ -
302
│ │ │ │ -
303 return static_cast<StencilTable const *>(
│ │ │ │ -
304 BaseFactory::Create(numTables,
│ │ │ │ -
305 reinterpret_cast<BaseTable const **>(tables)));
│ │ │ │ -
306 }
│ │ │ │ -
│ │ │ │ -
307
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
309 TopologyRefiner const &refiner,
│ │ │ │ -
310 StencilTable const *baseStencilTable,
│ │ │ │ -
311 StencilTable const *localPointStencilTable,
│ │ │ │ -
312 bool factorize = true) {
│ │ │ │ -
313
│ │ │ │ -
314 return static_cast<StencilTable const *>(
│ │ │ │ - │ │ │ │ -
316 static_cast<BaseTable const *>(baseStencilTable),
│ │ │ │ -
317 static_cast<BaseTable const *>(localPointStencilTable),
│ │ │ │ -
318 factorize));
│ │ │ │ -
319 }
│ │ │ │ -
│ │ │ │ -
320
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
322 TopologyRefiner const &refiner,
│ │ │ │ -
323 StencilTable const *baseStencilTable,
│ │ │ │ -
324 StencilTable const *localPointStencilTable,
│ │ │ │ -
325 bool factorize = true) {
│ │ │ │ -
326
│ │ │ │ -
327 return static_cast<StencilTable const *>(
│ │ │ │ - │ │ │ │ -
329 static_cast<BaseTable const *>(baseStencilTable),
│ │ │ │ -
330 static_cast<BaseTable const *>(localPointStencilTable),
│ │ │ │ -
331 factorize));
│ │ │ │ -
332 }
│ │ │ │ -
│ │ │ │ -
333
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
335 TopologyRefiner const &refiner,
│ │ │ │ -
336 StencilTable const *baseStencilTable,
│ │ │ │ -
337 StencilTable const *localPointStencilTable,
│ │ │ │ -
338 int channel = 0,
│ │ │ │ -
339 bool factorize = true) {
│ │ │ │ -
340
│ │ │ │ -
341 return static_cast<StencilTable const *>(
│ │ │ │ - │ │ │ │ -
343 static_cast<BaseTable const *>(baseStencilTable),
│ │ │ │ -
344 static_cast<BaseTable const *>(localPointStencilTable),
│ │ │ │ -
345 channel, factorize));
│ │ │ │ -
346 }
│ │ │ │ -
│ │ │ │ -
347};
│ │ │ │ -
│ │ │ │ -
348
│ │ │ │ -
349class LimitStencil;
│ │ │ │ -
350class LimitStencilTable;
│ │ │ │ -
351
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
355private:
│ │ │ │ - │ │ │ │ - │ │ │ │ -
358
│ │ │ │ -
359public:
│ │ │ │ -
│ │ │ │ -
360 static LimitStencilTable const * Create(
│ │ │ │ -
361 TopologyRefiner const & refiner,
│ │ │ │ -
362 LocationArrayVec const & locationArrays,
│ │ │ │ -
363 StencilTable const * cvStencils = 0,
│ │ │ │ -
364 PatchTable const * patchTable = 0,
│ │ │ │ -
365 Options options = Options()) {
│ │ │ │ -
366
│ │ │ │ -
367 return static_cast<LimitStencilTable const *>(
│ │ │ │ - │ │ │ │ -
369 refiner,
│ │ │ │ -
370 locationArrays,
│ │ │ │ -
371 static_cast<BaseTable const *>(cvStencils),
│ │ │ │ -
372 patchTable,
│ │ │ │ -
373 options));
│ │ │ │ -
374 }
│ │ │ │ -
│ │ │ │ -
375};
│ │ │ │ -
│ │ │ │ -
376
│ │ │ │ -
377} // end namespace Far
│ │ │ │ -
378
│ │ │ │ -
379} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
380using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
381
│ │ │ │ -
382} // end namespace OpenSubdiv
│ │ │ │ -
383
│ │ │ │ -
384#endif // OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H
│ │ │ │ +
114template <>
│ │ │ │ +
115void
│ │ │ │ + │ │ │ │ +
117 TopologyError errCode, char const * msg, TopologyDescriptor const & desc);
│ │ │ │ +
118
│ │ │ │ +
119// @endcond
│ │ │ │ +
120
│ │ │ │ +
121} // end namespace Far
│ │ │ │ +
122
│ │ │ │ +
123} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
124using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
125} // end namespace OpenSubdiv
│ │ │ │ +
126
│ │ │ │ +
127#endif /* OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H */
│ │ │ │ │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ - │ │ │ │ -
static StencilTableReal< REAL > const * Create(TopologyRefiner const &refiner, Options options=Options())
Instantiates StencilTable from TopologyRefiner that have been refined uniformly or adaptively.
│ │ │ │ -
static StencilTableReal< REAL > const * AppendLocalPointStencilTableFaceVarying(TopologyRefiner const &refiner, StencilTableReal< REAL > const *baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, int channel=0, bool factorize=true)
Utility function for stencil splicing for local point face-varying stencils.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
static StencilTableReal< REAL > const * AppendLocalPointStencilTableVarying(TopologyRefiner const &refiner, StencilTableReal< REAL > const *baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool factorize=true)
Utility function for stencil splicing for local point varying stencils.
│ │ │ │ -
static StencilTableReal< REAL > const * AppendLocalPointStencilTable(TopologyRefiner const &refiner, StencilTableReal< REAL > const *baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool factorize=true)
Utility function for stencil splicing for local point stencils.
│ │ │ │ -
static StencilTableReal< REAL > const * Create(int numTables, StencilTableReal< REAL > const **tables)
Instantiates StencilTable by concatenating an array of existing stencil tables.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
static LimitStencilTableReal< REAL > const * Create(TopologyRefiner const &refiner, LocationArrayVec const &locationArrays, StencilTableReal< REAL > const *cvStencils=0, PatchTable const *patchTable=0, Options options=Options())
Instantiates LimitStencilTable from a TopologyRefiner that has been refined either uniformly or adapt...
│ │ │ │ - │ │ │ │ -
Vertex stencil class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
unsigned int generateIntermediateLevels
vertices at all levels or highest only
│ │ │ │ -
unsigned int generateControlVerts
generate stencils for control-vertices
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
unsigned int generate2ndDerivatives
Generate weights for 2nd derivatives.
│ │ │ │ -
unsigned int generate1stDerivatives
Generate weights for 1st derivatives.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
Stencil table factory class wrapping the template for compatibility.
│ │ │ │ -
static StencilTable const * AppendLocalPointStencilTableVarying(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, bool factorize=true)
│ │ │ │ -
static StencilTable const * Create(TopologyRefiner const &refiner, Options options=Options())
│ │ │ │ -
static StencilTable const * AppendLocalPointStencilTableFaceVarying(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, int channel=0, bool factorize=true)
│ │ │ │ -
static StencilTable const * AppendLocalPointStencilTable(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, bool factorize=true)
│ │ │ │ -
static StencilTable const * Create(int numTables, StencilTable const **tables)
│ │ │ │ -
Stencil table factory class wrapping the template for compatibility.
│ │ │ │ -
static LimitStencilTable const * Create(TopologyRefiner const &refiner, LocationArrayVec const &locationArrays, StencilTable const *cvStencils=0, PatchTable const *patchTable=0, Options options=Options())
│ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ + │ │ │ │ +
A simple reference to raw topology data for use with TopologyRefinerFactory.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
static bool assignComponentTopology(TopologyRefiner &newRefiner, MESH const &mesh)
Specify the relationships between vertices, faces, etc. ie the face-vertices, vertex-faces,...
│ │ │ │ +
static void reportInvalidTopology(TopologyError errCode, char const *msg, MESH const &mesh)
(Optional) Control run-time topology validation and error reporting
│ │ │ │ +
static bool assignComponentTags(TopologyRefiner &newRefiner, MESH const &mesh)
(Optional) Specify edge or vertex sharpness or face holes
│ │ │ │ +
static bool resizeComponentTopology(TopologyRefiner &newRefiner, MESH const &mesh)
Specify the number of vertices, faces, face-vertices, etc.
│ │ │ │ +
static bool assignFaceVaryingTopology(TopologyRefiner &newRefiner, MESH const &mesh)
(Optional) Specify face-varying data per face
│ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -stencilTableFactory.h │ │ │ │ │ +topologyDescriptor.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2013 Pixar │ │ │ │ │ +2// Copyright 2014 DreamWorks Animation LLC. │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,498 +23,208 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H │ │ │ │ │ -27 │ │ │ │ │ -28#include "../version.h" │ │ │ │ │ -29 │ │ │ │ │ -30#include "../far/patchTable.h" │ │ │ │ │ -31 │ │ │ │ │ -32#include │ │ │ │ │ -33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Far { │ │ │ │ │ -38 │ │ │ │ │ -39class TopologyRefiner; │ │ │ │ │ -40 │ │ │ │ │ -41template class StencilReal; │ │ │ │ │ -42template class StencilTableReal; │ │ │ │ │ -43 │ │ │ │ │ -44template class LimitStencilReal; │ │ │ │ │ -45template class LimitStencilTableReal; │ │ │ │ │ -46 │ │ │ │ │ -47 │ │ │ │ │ -50template │ │ │ │ │ -_5_1class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l { │ │ │ │ │ -52 │ │ │ │ │ -53public: │ │ │ │ │ -54 │ │ │ │ │ -_5_5 enum _M_o_d_e { │ │ │ │ │ -_5_6 _I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X=0, │ │ │ │ │ -_5_7 _I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G, │ │ │ │ │ -58 _I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ -_5_9 }; │ │ │ │ │ +24#ifndef OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H │ │ │ │ │ +25#define OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H │ │ │ │ │ +26 │ │ │ │ │ +27#include "../version.h" │ │ │ │ │ +28 │ │ │ │ │ +29#include "../far/topologyRefiner.h" │ │ │ │ │ +30#include "../far/topologyRefinerFactory.h" │ │ │ │ │ +31#include "../far/error.h" │ │ │ │ │ +32 │ │ │ │ │ +33#include │ │ │ │ │ +34 │ │ │ │ │ +35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +36namespace OPENSUBDIV_VERSION { │ │ │ │ │ +37 │ │ │ │ │ +38namespace Far { │ │ │ │ │ +39 │ │ │ │ │ +_4_9struct _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ +50 │ │ │ │ │ +_5_1 int _n_u_m_V_e_r_t_i_c_e_s, │ │ │ │ │ +_5_2 _n_u_m_F_a_c_e_s; │ │ │ │ │ +53 │ │ │ │ │ +_5_4 int const * _n_u_m_V_e_r_t_s_P_e_r_F_a_c_e; │ │ │ │ │ +_5_5 _I_n_d_e_x const * _v_e_r_t_I_n_d_i_c_e_s_P_e_r_F_a_c_e; │ │ │ │ │ +56 │ │ │ │ │ +_5_7 int _n_u_m_C_r_e_a_s_e_s; │ │ │ │ │ +_5_8 _I_n_d_e_x const * _c_r_e_a_s_e_V_e_r_t_e_x_I_n_d_e_x_P_a_i_r_s; │ │ │ │ │ +_5_9 float const * _c_r_e_a_s_e_W_e_i_g_h_t_s; │ │ │ │ │ 60 │ │ │ │ │ -_6_1 struct _O_p_t_i_o_n_s { │ │ │ │ │ -62 │ │ │ │ │ -_6_3 _O_p_t_i_o_n_s() : _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e(_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X), │ │ │ │ │ -64 _g_e_n_e_r_a_t_e_O_f_f_s_e_t_s(false), │ │ │ │ │ -65 _g_e_n_e_r_a_t_e_C_o_n_t_r_o_l_V_e_r_t_s(false), │ │ │ │ │ -66 _g_e_n_e_r_a_t_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s(true), │ │ │ │ │ -67 _f_a_c_t_o_r_i_z_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s(true), │ │ │ │ │ -68 _m_a_x_L_e_v_e_l(10), │ │ │ │ │ -69 _f_v_a_r_C_h_a_n_n_e_l(0) { } │ │ │ │ │ -70 │ │ │ │ │ -_7_1 unsigned int _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e : 2, │ │ │ │ │ -_7_2 _g_e_n_e_r_a_t_e_O_f_f_s_e_t_s : 1, │ │ │ │ │ -_7_3 _g_e_n_e_r_a_t_e_C_o_n_t_r_o_l_V_e_r_t_s : 1, │ │ │ │ │ -_7_4 _g_e_n_e_r_a_t_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s : 1, │ │ │ │ │ -_7_5 _f_a_c_t_o_r_i_z_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s : 1, │ │ │ │ │ -_7_8 _m_a_x_L_e_v_e_l : 4; │ │ │ │ │ -_7_9 unsigned int _f_v_a_r_C_h_a_n_n_e_l; │ │ │ │ │ -81 }; │ │ │ │ │ -82 │ │ │ │ │ -_9_4 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _C_r_e_a_t_e( │ │ │ │ │ -95 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s()); │ │ │ │ │ -96 │ │ │ │ │ -97 │ │ │ │ │ -_1_1_0 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _C_r_e_a_t_e( │ │ │ │ │ -111 int numTables, _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const ** tables); │ │ │ │ │ -112 │ │ │ │ │ +_6_1 int _n_u_m_C_o_r_n_e_r_s; │ │ │ │ │ +_6_2 _I_n_d_e_x const * _c_o_r_n_e_r_V_e_r_t_e_x_I_n_d_i_c_e_s; │ │ │ │ │ +_6_3 float const * _c_o_r_n_e_r_W_e_i_g_h_t_s; │ │ │ │ │ +64 │ │ │ │ │ +_6_5 int _n_u_m_H_o_l_e_s; │ │ │ │ │ +_6_6 _I_n_d_e_x const * _h_o_l_e_I_n_d_i_c_e_s; │ │ │ │ │ +67 │ │ │ │ │ +_6_8 bool _i_s_L_e_f_t_H_a_n_d_e_d; │ │ │ │ │ +69 │ │ │ │ │ +70 // Face-varying data channel -- value indices correspond to vertex indices, │ │ │ │ │ +71 // i.e. one for every vertex of every face: │ │ │ │ │ +72 // │ │ │ │ │ +_7_3 struct _F_V_a_r_C_h_a_n_n_e_l { │ │ │ │ │ +74 │ │ │ │ │ +_7_5 int _n_u_m_V_a_l_u_e_s; │ │ │ │ │ +_7_6 _I_n_d_e_x const * _v_a_l_u_e_I_n_d_i_c_e_s; │ │ │ │ │ +77 │ │ │ │ │ +_7_8 _F_V_a_r_C_h_a_n_n_e_l() : _n_u_m_V_a_l_u_e_s(0), _v_a_l_u_e_I_n_d_i_c_e_s(0) { } │ │ │ │ │ +79 }; │ │ │ │ │ +80 │ │ │ │ │ +_8_1 int _n_u_m_F_V_a_r_C_h_a_n_n_e_l_s; │ │ │ │ │ +_8_2 _F_V_a_r_C_h_a_n_n_e_l const * _f_v_a_r_C_h_a_n_n_e_l_s; │ │ │ │ │ +83 │ │ │ │ │ +_8_4 _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r(); │ │ │ │ │ +85}; │ │ │ │ │ +86 │ │ │ │ │ +87 │ │ │ │ │ +88// │ │ │ │ │ +89// Forward declarations of required │ │ │ │ │ +TopologyRefinerFactory │ │ │ │ │ +90// specializations (defined internally): │ │ │ │ │ +91// │ │ │ │ │ +92// @cond EXCLUDE_DOXYGEN │ │ │ │ │ +93 │ │ │ │ │ +94template <> │ │ │ │ │ +95bool │ │ │ │ │ +96_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y( │ │ │ │ │ +97 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ +98 │ │ │ │ │ +99template <> │ │ │ │ │ +100bool │ │ │ │ │ +101_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y( │ │ │ │ │ +102 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ +103 │ │ │ │ │ +104template <> │ │ │ │ │ +105bool │ │ │ │ │ +106_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s( │ │ │ │ │ +107 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ +108 │ │ │ │ │ +109template <> │ │ │ │ │ +110bool │ │ │ │ │ +111_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y( │ │ │ │ │ +112 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r & refiner, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ 113 │ │ │ │ │ -_1_2_8 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e( │ │ │ │ │ -129 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -130 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *baseStencilTable, │ │ │ │ │ -131 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *localPointStencilTable, │ │ │ │ │ -132 bool factorize = true); │ │ │ │ │ -133 │ │ │ │ │ -_1_4_8 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g( │ │ │ │ │ -149 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -150 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *baseStencilTable, │ │ │ │ │ -151 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *localPointStencilTable, │ │ │ │ │ -152 bool factorize = true) { │ │ │ │ │ -153 return _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e( │ │ │ │ │ -154 refiner, baseStencilTable, localPointStencilTable, factorize); │ │ │ │ │ -155 } │ │ │ │ │ -156 │ │ │ │ │ -_1_7_4 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -175 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -176 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *baseStencilTable, │ │ │ │ │ -177 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *localPointStencilTable, │ │ │ │ │ -178 int channel = 0, │ │ │ │ │ -179 bool factorize = true); │ │ │ │ │ -180 │ │ │ │ │ -181private: │ │ │ │ │ -182 │ │ │ │ │ -183 // Generate stencils for the coarse control-vertices (single weight = 1.0f) │ │ │ │ │ -184 static void generateControlVertStencils( │ │ │ │ │ -185 int numControlVerts, │ │ │ │ │ -186 _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> & dst); │ │ │ │ │ -187 │ │ │ │ │ -188 // Internal method to splice local point stencils │ │ │ │ │ -189 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * appendLocalPointStencilTable( │ │ │ │ │ -190 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -191 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * baseStencilTable, │ │ │ │ │ -192 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * localPointStencilTable, │ │ │ │ │ -193 int channel, │ │ │ │ │ -194 bool factorize); │ │ │ │ │ -195}; │ │ │ │ │ -196 │ │ │ │ │ -208template │ │ │ │ │ -_2_0_9class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l { │ │ │ │ │ -210 │ │ │ │ │ -211public: │ │ │ │ │ -212 │ │ │ │ │ -_2_1_3 enum _M_o_d_e { │ │ │ │ │ -_2_1_4 _I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X=0, │ │ │ │ │ -_2_1_5 _I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G, │ │ │ │ │ -216 _I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ -_2_1_7 }; │ │ │ │ │ -218 │ │ │ │ │ -_2_1_9 struct _O_p_t_i_o_n_s { │ │ │ │ │ -220 │ │ │ │ │ -_2_2_1 _O_p_t_i_o_n_s() : _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e(_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X), │ │ │ │ │ -222 _g_e_n_e_r_a_t_e_1_s_t_D_e_r_i_v_a_t_i_v_e_s(true), │ │ │ │ │ -223 _g_e_n_e_r_a_t_e_2_n_d_D_e_r_i_v_a_t_i_v_e_s(false), │ │ │ │ │ -224 _f_v_a_r_C_h_a_n_n_e_l(0) { } │ │ │ │ │ -225 │ │ │ │ │ -_2_2_6 unsigned int _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e : 2, │ │ │ │ │ -_2_2_7 _g_e_n_e_r_a_t_e_1_s_t_D_e_r_i_v_a_t_i_v_e_s : 1, │ │ │ │ │ -_2_2_8 _g_e_n_e_r_a_t_e_2_n_d_D_e_r_i_v_a_t_i_v_e_s : 1; │ │ │ │ │ -_2_2_9 unsigned int _f_v_a_r_C_h_a_n_n_e_l; │ │ │ │ │ -230 }; │ │ │ │ │ -231 │ │ │ │ │ -_2_3_3 struct _L_o_c_a_t_i_o_n_A_r_r_a_y { │ │ │ │ │ -234 │ │ │ │ │ -_2_3_5 _L_o_c_a_t_i_o_n_A_r_r_a_y() : _p_t_e_x_I_d_x(-1), _n_u_m_L_o_c_a_t_i_o_n_s(0), _s(0), _t(0) { } │ │ │ │ │ -236 │ │ │ │ │ -_2_3_7 int _p_t_e_x_I_d_x, │ │ │ │ │ -_2_3_8 _n_u_m_L_o_c_a_t_i_o_n_s; │ │ │ │ │ -239 │ │ │ │ │ -_2_4_0 REAL const * _s, │ │ │ │ │ -_2_4_1 * _t; │ │ │ │ │ -242 }; │ │ │ │ │ -243 │ │ │ │ │ -_2_4_4 typedef std::vector _L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c; │ │ │ │ │ -245 │ │ │ │ │ -_2_6_9 static _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _C_r_e_a_t_e( │ │ │ │ │ -270 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, │ │ │ │ │ -271 _L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c const & locationArrays, │ │ │ │ │ -272 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * cvStencils = 0, │ │ │ │ │ -273 _P_a_t_c_h_T_a_b_l_e const * patchTable = 0, │ │ │ │ │ -274 _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s()); │ │ │ │ │ -275 │ │ │ │ │ -276}; │ │ │ │ │ -277 │ │ │ │ │ -278 │ │ │ │ │ -279// │ │ │ │ │ -280// Public wrapper classes for the templates │ │ │ │ │ -281// │ │ │ │ │ -282class _S_t_e_n_c_i_l; │ │ │ │ │ -283class _S_t_e_n_c_i_l_T_a_b_l_e; │ │ │ │ │ -284 │ │ │ │ │ -_2_8_7class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y : public _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l { │ │ │ │ │ -288private: │ │ │ │ │ -289 typedef _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_F_a_c_t_o_r_y; │ │ │ │ │ -290 typedef _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ -291 │ │ │ │ │ -292public: │ │ │ │ │ -_2_9_3 static _S_t_e_n_c_i_l_T_a_b_l_e const * _C_r_e_a_t_e( │ │ │ │ │ -294 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, Options options = Options()) { │ │ │ │ │ -295 │ │ │ │ │ -296 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -297 _B_a_s_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e(refiner, options)); │ │ │ │ │ -298 } │ │ │ │ │ -299 │ │ │ │ │ -_3_0_0 static _S_t_e_n_c_i_l_T_a_b_l_e const * _C_r_e_a_t_e( │ │ │ │ │ -301 int numTables, _S_t_e_n_c_i_l_T_a_b_l_e const ** tables) { │ │ │ │ │ -302 │ │ │ │ │ -303 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -304 _B_a_s_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e(numTables, │ │ │ │ │ -305 reinterpret_cast<_B_a_s_e_T_a_b_l_e const **>(tables))); │ │ │ │ │ -306 } │ │ │ │ │ -307 │ │ │ │ │ -_3_0_8 static _S_t_e_n_c_i_l_T_a_b_l_e const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e( │ │ │ │ │ -309 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -310 _S_t_e_n_c_i_l_T_a_b_l_e const *baseStencilTable, │ │ │ │ │ -311 _S_t_e_n_c_i_l_T_a_b_l_e const *localPointStencilTable, │ │ │ │ │ -312 bool factorize = true) { │ │ │ │ │ -313 │ │ │ │ │ -314 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -315 _B_a_s_e_F_a_c_t_o_r_y_:_:_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e(refiner, │ │ │ │ │ -316 static_cast<_B_a_s_e_T_a_b_l_e const *>(baseStencilTable), │ │ │ │ │ -317 static_cast<_B_a_s_e_T_a_b_l_e const *>(localPointStencilTable), │ │ │ │ │ -318 factorize)); │ │ │ │ │ -319 } │ │ │ │ │ -320 │ │ │ │ │ -_3_2_1 static _S_t_e_n_c_i_l_T_a_b_l_e const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g( │ │ │ │ │ -322 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -323 _S_t_e_n_c_i_l_T_a_b_l_e const *baseStencilTable, │ │ │ │ │ -324 _S_t_e_n_c_i_l_T_a_b_l_e const *localPointStencilTable, │ │ │ │ │ -325 bool factorize = true) { │ │ │ │ │ -326 │ │ │ │ │ -327 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -328 _B_a_s_e_F_a_c_t_o_r_y_:_:_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g(refiner, │ │ │ │ │ -329 static_cast<_B_a_s_e_T_a_b_l_e const *>(baseStencilTable), │ │ │ │ │ -330 static_cast<_B_a_s_e_T_a_b_l_e const *>(localPointStencilTable), │ │ │ │ │ -331 factorize)); │ │ │ │ │ -332 } │ │ │ │ │ -333 │ │ │ │ │ -_3_3_4 static _S_t_e_n_c_i_l_T_a_b_l_e const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -335 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -336 _S_t_e_n_c_i_l_T_a_b_l_e const *baseStencilTable, │ │ │ │ │ -337 _S_t_e_n_c_i_l_T_a_b_l_e const *localPointStencilTable, │ │ │ │ │ -338 int channel = 0, │ │ │ │ │ -339 bool factorize = true) { │ │ │ │ │ -340 │ │ │ │ │ -341 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -342 _B_a_s_e_F_a_c_t_o_r_y_:_:_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g(refiner, │ │ │ │ │ -343 static_cast<_B_a_s_e_T_a_b_l_e const *>(baseStencilTable), │ │ │ │ │ -344 static_cast<_B_a_s_e_T_a_b_l_e const *>(localPointStencilTable), │ │ │ │ │ -345 channel, factorize)); │ │ │ │ │ -346 } │ │ │ │ │ -347}; │ │ │ │ │ -348 │ │ │ │ │ -349class LimitStencil; │ │ │ │ │ -350class LimitStencilTable; │ │ │ │ │ -351 │ │ │ │ │ -_3_5_4class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y : public _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ -{ │ │ │ │ │ -355private: │ │ │ │ │ -356 typedef _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_F_a_c_t_o_r_y; │ │ │ │ │ -357 typedef _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ -358 │ │ │ │ │ -359public: │ │ │ │ │ -_3_6_0 static _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const * _C_r_e_a_t_e( │ │ │ │ │ -361 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, │ │ │ │ │ -362 _L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c const & locationArrays, │ │ │ │ │ -363 _S_t_e_n_c_i_l_T_a_b_l_e const * cvStencils = 0, │ │ │ │ │ -364 _P_a_t_c_h_T_a_b_l_e const * patchTable = 0, │ │ │ │ │ -365 Options options = Options()) { │ │ │ │ │ -366 │ │ │ │ │ -367 return static_cast<_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -368 _B_a_s_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e( │ │ │ │ │ -369 refiner, │ │ │ │ │ -370 locationArrays, │ │ │ │ │ -371 static_cast<_B_a_s_e_T_a_b_l_e const *>(cvStencils), │ │ │ │ │ -372 patchTable, │ │ │ │ │ -373 options)); │ │ │ │ │ -374 } │ │ │ │ │ -375}; │ │ │ │ │ -376 │ │ │ │ │ -377} // end namespace Far │ │ │ │ │ -378 │ │ │ │ │ -379} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -380using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -381 │ │ │ │ │ -382} // end namespace OpenSubdiv │ │ │ │ │ -383 │ │ │ │ │ -384#endif // OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H │ │ │ │ │ +114template <> │ │ │ │ │ +115void │ │ │ │ │ +116_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_>_:_:_r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y( │ │ │ │ │ +117 TopologyError errCode, char const * msg, _T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r const & desc); │ │ │ │ │ +118 │ │ │ │ │ +119// @endcond │ │ │ │ │ +120 │ │ │ │ │ +121} // end namespace Far │ │ │ │ │ +122 │ │ │ │ │ +123} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +124using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +125} // end namespace OpenSubdiv │ │ │ │ │ +126 │ │ │ │ │ +127#endif /* OPENSUBDIV3_FAR_TOPOLOGY_DESCRIPTOR_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -Container for arrays of parametric patches. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ -A specialized factory for StencilTable. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_C_r_e_a_t_e │ │ │ │ │ -static StencilTableReal< REAL > const * Create(TopologyRefiner const &refiner, │ │ │ │ │ -Options options=Options()) │ │ │ │ │ -Instantiates StencilTable from TopologyRefiner that have been refined uniformly │ │ │ │ │ -or adaptively. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static StencilTableReal< REAL > const * AppendLocalPointStencilTableFaceVarying │ │ │ │ │ -(TopologyRefiner const &refiner, StencilTableReal< REAL > const │ │ │ │ │ -*baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, int │ │ │ │ │ -channel=0, bool factorize=true) │ │ │ │ │ -Utility function for stencil splicing for local point face-varying stencils. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_M_o_d_e │ │ │ │ │ -Mode │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ -@ INTERPOLATE_FACE_VARYING │ │ │ │ │ -face-varying primvar stencils │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G │ │ │ │ │ -@ INTERPOLATE_VARYING │ │ │ │ │ -varying primvar stencils │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X │ │ │ │ │ -@ INTERPOLATE_VERTEX │ │ │ │ │ -vertex primvar stencils │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g │ │ │ │ │ -static StencilTableReal< REAL > const * AppendLocalPointStencilTableVarying │ │ │ │ │ -(TopologyRefiner const &refiner, StencilTableReal< REAL > const │ │ │ │ │ -*baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool │ │ │ │ │ -factorize=true) │ │ │ │ │ -Utility function for stencil splicing for local point varying stencils. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -static StencilTableReal< REAL > const * AppendLocalPointStencilTable │ │ │ │ │ -(TopologyRefiner const &refiner, StencilTableReal< REAL > const │ │ │ │ │ -*baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool │ │ │ │ │ -factorize=true) │ │ │ │ │ -Utility function for stencil splicing for local point stencils. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_C_r_e_a_t_e │ │ │ │ │ -static StencilTableReal< REAL > const * Create(int numTables, StencilTableReal< │ │ │ │ │ -REAL > const **tables) │ │ │ │ │ -Instantiates StencilTable by concatenating an array of existing stencil tables. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ -A specialized factory for LimitStencilTable. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_M_o_d_e │ │ │ │ │ -Mode │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ -@ INTERPOLATE_FACE_VARYING │ │ │ │ │ -face-varying primvar stencils │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G │ │ │ │ │ -@ INTERPOLATE_VARYING │ │ │ │ │ -varying primvar stencils │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X │ │ │ │ │ -@ INTERPOLATE_VERTEX │ │ │ │ │ -vertex primvar stencils │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c │ │ │ │ │ -std::vector< LocationArray > LocationArrayVec │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_C_r_e_a_t_e │ │ │ │ │ -static LimitStencilTableReal< REAL > const * Create(TopologyRefiner const │ │ │ │ │ -&refiner, LocationArrayVec const &locationArrays, StencilTableReal< REAL > │ │ │ │ │ -const *cvStencils=0, PatchTable const *patchTable=0, Options options=Options()) │ │ │ │ │ -Instantiates LimitStencilTable from a TopologyRefiner that has been refined │ │ │ │ │ -either uniformly or adapt... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ -Vertex stencil descriptor. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l │ │ │ │ │ -Vertex stencil class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -Table of subdivision stencils. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -Table of limit subdivision stencils. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_0_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_f_a_c_t_o_r_i_z_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s │ │ │ │ │ -unsigned int factorizeIntermediateLevels │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_:_m_a_x_L_e_v_e_l │ │ │ │ │ -unsigned int maxLevel │ │ │ │ │ -generate stencils up to 'maxLevel' │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ -Options() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s │ │ │ │ │ -unsigned int generateIntermediateLevels │ │ │ │ │ -vertices at all levels or highest only │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_C_o_n_t_r_o_l_V_e_r_t_s │ │ │ │ │ -unsigned int generateControlVerts │ │ │ │ │ -generate stencils for control-vertices │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_O_f_f_s_e_t_s │ │ │ │ │ -unsigned int generateOffsets │ │ │ │ │ -populate optional "_offsets" field │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_f_v_a_r_C_h_a_n_n_e_l │ │ │ │ │ -unsigned int fvarChannel │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e │ │ │ │ │ -unsigned int interpolationMode │ │ │ │ │ -interpolation mode │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_O_p_t_i_o_n_s │ │ │ │ │ -Options() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_f_v_a_r_C_h_a_n_n_e_l │ │ │ │ │ -unsigned int fvarChannel │ │ │ │ │ -face-varying channel to use │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e │ │ │ │ │ -unsigned int interpolationMode │ │ │ │ │ -interpolation mode │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_2_n_d_D_e_r_i_v_a_t_i_v_e_s │ │ │ │ │ -unsigned int generate2ndDerivatives │ │ │ │ │ -Generate weights for 2nd derivatives. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_1_s_t_D_e_r_i_v_a_t_i_v_e_s │ │ │ │ │ -unsigned int generate1stDerivatives │ │ │ │ │ -Generate weights for 1st derivatives. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y │ │ │ │ │ -Descriptor for limit surface locations. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_t │ │ │ │ │ -REAL const * t │ │ │ │ │ -array of v coordinates │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_s │ │ │ │ │ -REAL const * s │ │ │ │ │ -array of u coordinates │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_L_o_c_a_t_i_o_n_A_r_r_a_y │ │ │ │ │ -LocationArray() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_n_u_m_L_o_c_a_t_i_o_n_s │ │ │ │ │ -int numLocations │ │ │ │ │ -number of (u,v) coordinates in the array │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ -_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_p_t_e_x_I_d_x │ │ │ │ │ -int ptexIdx │ │ │ │ │ -ptex face index │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ -Stencil table factory class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g │ │ │ │ │ -static StencilTable const * AppendLocalPointStencilTableVarying(TopologyRefiner │ │ │ │ │ -const &refiner, StencilTable const *baseStencilTable, StencilTable const │ │ │ │ │ -*localPointStencilTable, bool factorize=true) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_2_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ -static StencilTable const * Create(TopologyRefiner const &refiner, Options │ │ │ │ │ -options=Options()) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static StencilTable const * AppendLocalPointStencilTableFaceVarying │ │ │ │ │ -(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, │ │ │ │ │ -StencilTable const *localPointStencilTable, int channel=0, bool factorize=true) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_: │ │ │ │ │ -_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -static StencilTable const * AppendLocalPointStencilTable(TopologyRefiner const │ │ │ │ │ -&refiner, StencilTable const *baseStencilTable, StencilTable const │ │ │ │ │ -*localPointStencilTable, bool factorize=true) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_0_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ -static StencilTable const * Create(int numTables, StencilTable const **tables) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ -Stencil table factory class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ -static LimitStencilTable const * Create(TopologyRefiner const &refiner, │ │ │ │ │ -LocationArrayVec const &locationArrays, StencilTable const *cvStencils=0, │ │ │ │ │ -PatchTable const *patchTable=0, Options options=Options()) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ +Vtr::Index Index │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +A simple reference to raw topology data for use with TopologyRefinerFactory. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_f_v_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +FVarChannel const * fvarChannels │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ +int numVertices │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_o_r_n_e_r_V_e_r_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ +Index const * cornerVertexIndices │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_v_e_r_t_I_n_d_i_c_e_s_P_e_r_F_a_c_e │ │ │ │ │ +Index const * vertIndicesPerFace │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_r_e_a_s_e_V_e_r_t_e_x_I_n_d_e_x_P_a_i_r_s │ │ │ │ │ +Index const * creaseVertexIndexPairs │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_h_o_l_e_I_n_d_i_c_e_s │ │ │ │ │ +Index const * holeIndices │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_F_a_c_e_s │ │ │ │ │ +int numFaces │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_C_o_r_n_e_r_s │ │ │ │ │ +int numCorners │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_o_r_n_e_r_W_e_i_g_h_t_s │ │ │ │ │ +float const * cornerWeights │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_i_s_L_e_f_t_H_a_n_d_e_d │ │ │ │ │ +bool isLeftHanded │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_V_e_r_t_s_P_e_r_F_a_c_e │ │ │ │ │ +int const * numVertsPerFace │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +TopologyDescriptor() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_c_r_e_a_s_e_W_e_i_g_h_t_s │ │ │ │ │ +float const * creaseWeights │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_C_r_e_a_s_e_s │ │ │ │ │ +int numCreases │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_5_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_H_o_l_e_s │ │ │ │ │ +int numHoles │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_n_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +int numFVarChannels │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l_:_: │ │ │ │ │ +_F_V_a_r_C_h_a_n_n_e_l │ │ │ │ │ +FVarChannel() │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l_:_: │ │ │ │ │ +_v_a_l_u_e_I_n_d_i_c_e_s │ │ │ │ │ +Index const * valueIndices │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_:_:_F_V_a_r_C_h_a_n_n_e_l_:_:_n_u_m_V_a_l_u_e_s │ │ │ │ │ +int numValues │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h_:_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ +static bool assignComponentTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ +&mesh) │ │ │ │ │ +Specify the relationships between vertices, faces, etc. ie the face-vertices, │ │ │ │ │ +vertex-faces,... │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_r_e_p_o_r_t_I_n_v_a_l_i_d_T_o_p_o_l_o_g_y │ │ │ │ │ +static void reportInvalidTopology(TopologyError errCode, char const *msg, MESH │ │ │ │ │ +const &mesh) │ │ │ │ │ +(Optional) Control run-time topology validation and error reporting │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_7_0_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_a_s_s_i_g_n_C_o_m_p_o_n_e_n_t_T_a_g_s │ │ │ │ │ +static bool assignComponentTags(TopologyRefiner &newRefiner, MESH const &mesh) │ │ │ │ │ +(Optional) Specify edge or vertex sharpness or face holes │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_9_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_r_e_s_i_z_e_C_o_m_p_o_n_e_n_t_T_o_p_o_l_o_g_y │ │ │ │ │ +static bool resizeComponentTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ +&mesh) │ │ │ │ │ +Specify the number of vertices, faces, face-vertices, etc. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_5_8_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_a_s_s_i_g_n_F_a_c_e_V_a_r_y_i_n_g_T_o_p_o_l_o_g_y │ │ │ │ │ +static bool assignFaceVaryingTopology(TopologyRefiner &newRefiner, MESH const │ │ │ │ │ +&mesh) │ │ │ │ │ +(Optional) Specify face-varying data per face │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h_:_6_7_4 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ Stores topology data for a specified set of refinement options. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00719.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/stencilTable.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/stencilTableFactory.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,51 +90,43 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
stencilTable.h File Reference
│ │ │ │ +
stencilTableFactory.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/types.h"
│ │ │ │ -#include <cassert>
│ │ │ │ -#include <cstring>
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │ #include <vector>
│ │ │ │ -#include <iostream>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  StencilReal< REAL >
 Vertex stencil descriptor. More...
class  StencilTableFactoryReal< REAL >
 A specialized factory for StencilTable. More...
 
class  Stencil
 Vertex stencil class wrapping the template for compatibility. More...
struct  StencilTableFactoryReal< REAL >::Options
 
class  StencilTableReal< REAL >
 Table of subdivision stencils. More...
class  LimitStencilTableFactoryReal< REAL >
 A specialized factory for LimitStencilTable. More...
 
class  StencilTable
 Stencil table class wrapping the template for compatibility. More...
struct  LimitStencilTableFactoryReal< REAL >::Options
 
class  LimitStencilReal< REAL >
 Limit point stencil descriptor. More...
struct  LimitStencilTableFactoryReal< REAL >::LocationArray
 Descriptor for limit surface locations. More...
 
class  LimitStencil
 Limit point stencil class wrapping the template for compatibility. More...
class  StencilTableFactory
 Stencil table factory class wrapping the template for compatibility. More...
 
class  LimitStencilTableReal< REAL >
 Table of limit subdivision stencils. More...
 
class  LimitStencilTable
 Limit stencil table class wrapping the template for compatibility. More...
class  LimitStencilTableFactory
 Stencil table factory class wrapping the template for compatibility. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -143,13 +135,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,51 +1,43 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -stencilTable.h File Reference │ │ │ │ │ +stencilTableFactory.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ -#include │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ #include │ │ │ │ │ -#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _S_t_e_n_c_i_l_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  Vertex stencil descriptor. _M_o_r_e_._._. │ │ │ │ │ + class   _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  A specialized factory for _S_t_e_n_c_i_l_T_a_b_l_e. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _S_t_e_n_c_i_l │ │ │ │ │ -  Vertex stencil class wrapping the template for compatibility. _M_o_r_e_._._. │ │ │ │ │ +struct   _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _>_:_:_O_p_t_i_o_n_s │ │ │ │ │   │ │ │ │ │ -class   _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  Table of subdivision stencils. _M_o_r_e_._._. │ │ │ │ │ + class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  A specialized factory for _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -  _S_t_e_n_c_i_l table class wrapping the template for compatibility. _M_o_r_e_._._. │ │ │ │ │ +struct   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _>_:_:_O_p_t_i_o_n_s │ │ │ │ │   │ │ │ │ │ -class   _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  Limit point stencil descriptor. _M_o_r_e_._._. │ │ │ │ │ +struct   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_ _R_E_A_L_ _>_:_:_L_o_c_a_t_i_o_n_A_r_r_a_y │ │ │ │ │ +  Descriptor for limit surface locations. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ -  Limit point stencil class wrapping the template for compatibility. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ + class   _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ +  _S_t_e_n_c_i_l table factory class wrapping the template for compatibility. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  Table of limit subdivision stencils. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -  Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ + class   _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ +  _S_t_e_n_c_i_l table factory class wrapping the template for compatibility. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _s_t_e_n_c_i_l_T_a_b_l_e_._h │ │ │ │ │ + * _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00719.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,10 +1,9 @@ │ │ │ │ │ var a00719 = [ │ │ │ │ │ - ["StencilReal< REAL >", "a01053.html", "a01053"], │ │ │ │ │ - ["Stencil", "a01057.html", "a01057"], │ │ │ │ │ - ["StencilTableReal< REAL >", "a01061.html", "a01061"], │ │ │ │ │ - ["StencilTable", "a01065.html", "a01065"], │ │ │ │ │ - ["LimitStencilReal< REAL >", "a01069.html", "a01069"], │ │ │ │ │ - ["LimitStencil", "a01073.html", "a01073"], │ │ │ │ │ - ["LimitStencilTableReal< REAL >", "a01077.html", "a01077"], │ │ │ │ │ - ["LimitStencilTable", "a01081.html", "a01081"] │ │ │ │ │ + ["StencilTableFactoryReal< REAL >", "a01045.html", "a01045"], │ │ │ │ │ + ["Options", "a01085.html", "a01085"], │ │ │ │ │ + ["LimitStencilTableFactoryReal< REAL >", "a01049.html", "a01049"], │ │ │ │ │ + ["Options", "a01089.html", "a01089"], │ │ │ │ │ + ["LocationArray", "a01093.html", "a01093"], │ │ │ │ │ + ["StencilTableFactory", "a01097.html", null], │ │ │ │ │ + ["LimitStencilTableFactory", "a01101.html", null] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00719_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/stencilTable.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/stencilTableFactory.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
stencilTable.h
│ │ │ │ +
stencilTableFactory.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,892 +119,357 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_STENCILTABLE_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../far/types.h"
│ │ │ │ +
30#include "../far/patchTable.h"
│ │ │ │
31
│ │ │ │ -
32#include <cassert>
│ │ │ │ -
33#include <cstring>
│ │ │ │ -
34#include <vector>
│ │ │ │ -
35#include <iostream>
│ │ │ │ +
32#include <vector>
│ │ │ │ +
33
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │
36
│ │ │ │ -
37namespace OpenSubdiv {
│ │ │ │ -
38namespace OPENSUBDIV_VERSION {
│ │ │ │ -
39
│ │ │ │ -
40namespace Far {
│ │ │ │ -
41
│ │ │ │ -
42// Forward declarations for friends:
│ │ │ │ -
43class PatchTableBuilder;
│ │ │ │ -
44
│ │ │ │ -
45template <typename REAL> class StencilTableFactoryReal;
│ │ │ │ -
46template <typename REAL> class LimitStencilTableFactoryReal;
│ │ │ │ +
37namespace Far {
│ │ │ │ +
38
│ │ │ │ +
39class TopologyRefiner;
│ │ │ │ +
40
│ │ │ │ +
41template <typename REAL> class StencilReal;
│ │ │ │ +
42template <typename REAL> class StencilTableReal;
│ │ │ │ +
43
│ │ │ │ +
44template <typename REAL> class LimitStencilReal;
│ │ │ │ +
45template <typename REAL> class LimitStencilTableReal;
│ │ │ │ +
46
│ │ │ │
47
│ │ │ │ -
52template <typename REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
54public:
│ │ │ │ -
55
│ │ │ │ - │ │ │ │ -
58
│ │ │ │ -
│ │ │ │ -
67 StencilReal(int * size, Index * indices, REAL * weights)
│ │ │ │ -
68 : _size(size), _indices(indices), _weights(weights) { }
│ │ │ │ -
│ │ │ │ -
69
│ │ │ │ -
│ │ │ │ -
71 StencilReal(StencilReal const & other) {
│ │ │ │ -
72 _size = other._size;
│ │ │ │ -
73 _indices = other._indices;
│ │ │ │ -
74 _weights = other._weights;
│ │ │ │ -
75 }
│ │ │ │ -
│ │ │ │ -
76
│ │ │ │ -
│ │ │ │ -
78 int GetSize() const {
│ │ │ │ -
79 return *_size;
│ │ │ │ -
80 }
│ │ │ │ -
│ │ │ │ -
81
│ │ │ │ -
│ │ │ │ -
83 int * GetSizePtr() const {
│ │ │ │ -
84 return _size;
│ │ │ │ -
85 }
│ │ │ │ -
│ │ │ │ -
86
│ │ │ │ -
│ │ │ │ -
88 Index const * GetVertexIndices() const {
│ │ │ │ -
89 return _indices;
│ │ │ │ -
90 }
│ │ │ │ -
│ │ │ │ -
91
│ │ │ │ -
│ │ │ │ -
93 REAL const * GetWeights() const {
│ │ │ │ -
94 return _weights;
│ │ │ │ -
95 }
│ │ │ │ -
│ │ │ │ +
50template <typename REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
52
│ │ │ │ +
53public:
│ │ │ │ +
54
│ │ │ │ +
│ │ │ │ +
55 enum Mode {
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
59 };
│ │ │ │ +
│ │ │ │ +
60
│ │ │ │ +
│ │ │ │ +
61 struct Options {
│ │ │ │ +
62
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
64 generateOffsets(false),
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
68 maxLevel(10),
│ │ │ │ +
69 fvarChannel(0) { }
│ │ │ │ +
│ │ │ │ +
70
│ │ │ │ +
71 unsigned int interpolationMode : 2,
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
79 unsigned int fvarChannel;
│ │ │ │ +
81 };
│ │ │ │ +
│ │ │ │ +
82
│ │ │ │ + │ │ │ │ +
95 TopologyRefiner const & refiner, Options options = Options());
│ │ │ │
96
│ │ │ │ -
98 void Next() {
│ │ │ │ -
99 int stride = *_size;
│ │ │ │ -
100 ++_size;
│ │ │ │ -
101 _indices += stride;
│ │ │ │ -
102 _weights += stride;
│ │ │ │ -
103 }
│ │ │ │ -
104
│ │ │ │ -
105protected:
│ │ │ │ -
106 friend class StencilTableFactoryReal<REAL>;
│ │ │ │ -
107 friend class LimitStencilTableFactoryReal<REAL>;
│ │ │ │ -
108
│ │ │ │ -
109 int * _size;
│ │ │ │ - │ │ │ │ -
111 REAL * _weights;
│ │ │ │ -
112};
│ │ │ │ -
│ │ │ │ +
97
│ │ │ │ + │ │ │ │ +
111 int numTables, StencilTableReal<REAL> const ** tables);
│ │ │ │ +
112
│ │ │ │
113
│ │ │ │ -
│ │ │ │ -
116class Stencil : public StencilReal<float> {
│ │ │ │ -
117protected:
│ │ │ │ - │ │ │ │ -
119
│ │ │ │ -
120public:
│ │ │ │ - │ │ │ │ -
122 Stencil(BaseStencil const & other) : BaseStencil(other) { }
│ │ │ │ -
│ │ │ │ -
123 Stencil(int * size, Index * indices, float * weights)
│ │ │ │ -
124 : BaseStencil(size, indices, weights) { }
│ │ │ │ -
│ │ │ │ -
125};
│ │ │ │ -
│ │ │ │ -
126
│ │ │ │ -
127
│ │ │ │ -
140template <typename REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
142protected:
│ │ │ │ -
143 StencilTableReal(int numControlVerts,
│ │ │ │ -
144 std::vector<int> const& offsets,
│ │ │ │ -
145 std::vector<int> const& sizes,
│ │ │ │ -
146 std::vector<int> const& sources,
│ │ │ │ -
147 std::vector<REAL> const& weights,
│ │ │ │ -
148 bool includeCoarseVerts,
│ │ │ │ -
149 size_t firstOffset);
│ │ │ │ -
150
│ │ │ │ -
151public:
│ │ │ │ -
152
│ │ │ │ -
153 virtual ~StencilTableReal() {};
│ │ │ │ -
154
│ │ │ │ -
│ │ │ │ -
156 int GetNumStencils() const {
│ │ │ │ -
157 return (int)_sizes.size();
│ │ │ │ -
158 }
│ │ │ │ -
│ │ │ │ -
159
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
162 return _numControlVertices;
│ │ │ │ -
163 }
│ │ │ │ -
│ │ │ │ -
164
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
167
│ │ │ │ -
│ │ │ │ -
169 std::vector<int> const & GetSizes() const {
│ │ │ │ -
170 return _sizes;
│ │ │ │ -
171 }
│ │ │ │ -
│ │ │ │ -
172
│ │ │ │ -
│ │ │ │ -
174 std::vector<Index> const & GetOffsets() const {
│ │ │ │ -
175 return _offsets;
│ │ │ │ -
176 }
│ │ │ │ -
│ │ │ │ -
177
│ │ │ │ -
│ │ │ │ -
179 std::vector<Index> const & GetControlIndices() const {
│ │ │ │ -
180 return _indices;
│ │ │ │ -
181 }
│ │ │ │ -
│ │ │ │ + │ │ │ │ +
129 TopologyRefiner const &refiner,
│ │ │ │ +
130 StencilTableReal<REAL> const *baseStencilTable,
│ │ │ │ +
131 StencilTableReal<REAL> const *localPointStencilTable,
│ │ │ │ +
132 bool factorize = true);
│ │ │ │ +
133
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
149 TopologyRefiner const &refiner,
│ │ │ │ +
150 StencilTableReal<REAL> const *baseStencilTable,
│ │ │ │ +
151 StencilTableReal<REAL> const *localPointStencilTable,
│ │ │ │ +
152 bool factorize = true) {
│ │ │ │ + │ │ │ │ +
154 refiner, baseStencilTable, localPointStencilTable, factorize);
│ │ │ │ +
155 }
│ │ │ │ +
│ │ │ │ +
156
│ │ │ │ + │ │ │ │ +
175 TopologyRefiner const &refiner,
│ │ │ │ +
176 StencilTableReal<REAL> const *baseStencilTable,
│ │ │ │ +
177 StencilTableReal<REAL> const *localPointStencilTable,
│ │ │ │ +
178 int channel = 0,
│ │ │ │ +
179 bool factorize = true);
│ │ │ │ +
180
│ │ │ │ +
181private:
│ │ │ │
182
│ │ │ │ -
│ │ │ │ -
184 std::vector<REAL> const & GetWeights() const {
│ │ │ │ -
185 return _weights;
│ │ │ │ -
186 }
│ │ │ │ -
│ │ │ │ +
183 // Generate stencils for the coarse control-vertices (single weight = 1.0f)
│ │ │ │ +
184 static void generateControlVertStencils(
│ │ │ │ +
185 int numControlVerts,
│ │ │ │ +
186 StencilReal<REAL> & dst);
│ │ │ │
187
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
190
│ │ │ │ -
204 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
205 void UpdateValues(T const &srcValues, U &dstValues, Index start=-1, Index end=-1) const {
│ │ │ │ -
206 this->update(srcValues, dstValues, _weights, start, end);
│ │ │ │ -
207 }
│ │ │ │ -
│ │ │ │ -
208
│ │ │ │ -
209 template <class T1, class T2, class U>
│ │ │ │ -
│ │ │ │ -
210 void UpdateValues(T1 const &srcBase, int numBase, T2 const &srcRef,
│ │ │ │ -
211 U &dstValues, Index start=-1, Index end=-1) const {
│ │ │ │ -
212 this->update(srcBase, numBase, srcRef, dstValues, _weights, start, end);
│ │ │ │ -
213 }
│ │ │ │ -
│ │ │ │ -
214
│ │ │ │ -
215 // Pointer interface for backward compatibility
│ │ │ │ -
216 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
217 void UpdateValues(T const *src, U *dst, Index start=-1, Index end=-1) const {
│ │ │ │ -
218 this->update(src, dst, _weights, start, end);
│ │ │ │ -
219 }
│ │ │ │ -
│ │ │ │ -
220 template <class T1, class T2, class U>
│ │ │ │ +
188 // Internal method to splice local point stencils
│ │ │ │ +
189 static StencilTableReal<REAL> const * appendLocalPointStencilTable(
│ │ │ │ +
190 TopologyRefiner const &refiner,
│ │ │ │ +
191 StencilTableReal<REAL> const * baseStencilTable,
│ │ │ │ +
192 StencilTableReal<REAL> const * localPointStencilTable,
│ │ │ │ +
193 int channel,
│ │ │ │ +
194 bool factorize);
│ │ │ │ +
195};
│ │ │ │ +
│ │ │ │ +
196
│ │ │ │ +
208template <typename REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
210
│ │ │ │ +
211public:
│ │ │ │ +
212
│ │ │ │ +
│ │ │ │ +
213 enum Mode {
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
217 };
│ │ │ │ +
│ │ │ │ +
218
│ │ │ │ +
│ │ │ │ +
219 struct Options {
│ │ │ │ +
220
│ │ │ │
│ │ │ │ -
221 void UpdateValues(T1 const *srcBase, int numBase, T2 const *srcRef,
│ │ │ │ -
222 U *dst, Index start=-1, Index end=-1) const {
│ │ │ │ -
223 this->update(srcBase, numBase, srcRef, dst, _weights, start, end);
│ │ │ │ -
224 }
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
224 fvarChannel(0) { }
│ │ │ │
│ │ │ │
225
│ │ │ │ -
227 void Clear();
│ │ │ │ -
228
│ │ │ │ -
229protected:
│ │ │ │ -
230
│ │ │ │ -
231 // Update values by applying cached stencil weights to new control values
│ │ │ │ -
232 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
233 void update( T const &srcValues, U &dstValues,
│ │ │ │ -
234 std::vector<REAL> const & valueWeights, Index start, Index end) const;
│ │ │ │ -
235 template <class T1, class T2, class U>
│ │ │ │ -
│ │ │ │ -
236 void update( T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues,
│ │ │ │ -
237 std::vector<REAL> const & valueWeights, Index start, Index end) const;
│ │ │ │ -
238
│ │ │ │ -
239 // Populate the offsets table from the stencil sizes in _sizes (factory helper)
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
241
│ │ │ │ -
242 // Resize the table arrays (factory helper)
│ │ │ │ -
│ │ │ │ -
243 void resize(int nstencils, int nelems);
│ │ │ │ -
244
│ │ │ │ -
245 // Reserves the table arrays (factory helper)
│ │ │ │ -
│ │ │ │ -
246 void reserve(int nstencils, int nelems);
│ │ │ │ -
247
│ │ │ │ -
248 // Reallocates the table arrays to remove excess capacity (factory helper)
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
250
│ │ │ │ -
251 // Performs any final operations on internal tables (factory helper)
│ │ │ │ -
│ │ │ │ -
252 void finalize();
│ │ │ │ -
253
│ │ │ │ -
254protected:
│ │ │ │ - │ │ │ │ -
256 StencilTableReal(int numControlVerts)
│ │ │ │ -
257 : _numControlVertices(numControlVerts)
│ │ │ │ -
258 { }
│ │ │ │ -
259
│ │ │ │ -
260 friend class StencilTableFactoryReal<REAL>;
│ │ │ │ - │ │ │ │ -
262
│ │ │ │ -
263 int _numControlVertices; // number of control vertices
│ │ │ │ -
264
│ │ │ │ -
265 std::vector<int> _sizes; // number of coefficients for each stencil
│ │ │ │ -
266 std::vector<Index> _offsets, // offset to the start of each stencil
│ │ │ │ -
267 _indices; // indices of contributing coarse vertices
│ │ │ │ -
268 std::vector<REAL> _weights; // stencil weight coefficients
│ │ │ │ -
269};
│ │ │ │ -
270
│ │ │ │ -
│ │ │ │ -
273class StencilTable : public StencilTableReal<float> {
│ │ │ │ -
274protected:
│ │ │ │ - │ │ │ │ -
276
│ │ │ │ -
277public:
│ │ │ │ -
│ │ │ │ -
278 Stencil GetStencil(Index index) const {
│ │ │ │ -
279 return Stencil(BaseTable::GetStencil(index));
│ │ │ │ -
280 }
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
281 Stencil operator[] (Index index) const {
│ │ │ │ -
282 return Stencil(BaseTable::GetStencil(index));
│ │ │ │ -
283 }
│ │ │ │ -
│ │ │ │ +
226 unsigned int interpolationMode : 2,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
229 unsigned int fvarChannel;
│ │ │ │ +
230 };
│ │ │ │ +
│ │ │ │ +
231
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
234
│ │ │ │ +
235 LocationArray() : ptexIdx(-1), numLocations(0), s(0), t(0) { }
│ │ │ │ +
236
│ │ │ │ + │ │ │ │ + │ │ │ │ +
239
│ │ │ │ +
240 REAL const * s,
│ │ │ │ +
241 * t;
│ │ │ │ +
242 };
│ │ │ │ +
│ │ │ │ +
243
│ │ │ │ +
244 typedef std::vector<LocationArray> LocationArrayVec;
│ │ │ │ +
245
│ │ │ │ + │ │ │ │ +
270 TopologyRefiner const & refiner,
│ │ │ │ +
271 LocationArrayVec const & locationArrays,
│ │ │ │ +
272 StencilTableReal<REAL> const * cvStencils = 0,
│ │ │ │ +
273 PatchTable const * patchTable = 0,
│ │ │ │ +
274 Options options = Options());
│ │ │ │ +
275
│ │ │ │ +
276};
│ │ │ │ +
│ │ │ │ +
277
│ │ │ │ +
278
│ │ │ │ +
279//
│ │ │ │ +
280// Public wrapper classes for the templates
│ │ │ │ +
281//
│ │ │ │ +
282class Stencil;
│ │ │ │ +
283class StencilTable;
│ │ │ │
284
│ │ │ │ -
285protected:
│ │ │ │ - │ │ │ │ -
287 StencilTable(int numControlVerts) : BaseTable(numControlVerts) { }
│ │ │ │ -
│ │ │ │ -
288 StencilTable(int numControlVerts,
│ │ │ │ -
289 std::vector<int> const& offsets,
│ │ │ │ -
290 std::vector<int> const& sizes,
│ │ │ │ -
291 std::vector<int> const& sources,
│ │ │ │ -
292 std::vector<float> const& weights,
│ │ │ │ -
293 bool includeCoarseVerts,
│ │ │ │ -
294 size_t firstOffset)
│ │ │ │ -
295 : BaseTable(numControlVerts, offsets,
│ │ │ │ -
296 sizes, sources, weights, includeCoarseVerts, firstOffset) { }
│ │ │ │ -
│ │ │ │ -
297};
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
288private:
│ │ │ │ + │ │ │ │ + │ │ │ │ +
291
│ │ │ │ +
292public:
│ │ │ │ +
│ │ │ │ +
293 static StencilTable const * Create(
│ │ │ │ +
294 TopologyRefiner const & refiner, Options options = Options()) {
│ │ │ │ +
295
│ │ │ │ +
296 return static_cast<StencilTable const *>(
│ │ │ │ +
297 BaseFactory::Create(refiner, options));
│ │ │ │ +
298 }
│ │ │ │
│ │ │ │ -
298
│ │ │ │
299
│ │ │ │ -
302template <typename REAL>
│ │ │ │ -
│ │ │ │ -
303class LimitStencilReal : public StencilReal<REAL> {
│ │ │ │ -
304public:
│ │ │ │ -
305
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
325 Index * indices,
│ │ │ │ -
326 REAL * weights,
│ │ │ │ -
327 REAL * duWeights=0,
│ │ │ │ -
328 REAL * dvWeights=0,
│ │ │ │ -
329 REAL * duuWeights=0,
│ │ │ │ -
330 REAL * duvWeights=0,
│ │ │ │ -
331 REAL * dvvWeights=0)
│ │ │ │ -
332 : StencilReal<REAL>(size, indices, weights),
│ │ │ │ -
333 _duWeights(duWeights),
│ │ │ │ -
334 _dvWeights(dvWeights),
│ │ │ │ -
335 _duuWeights(duuWeights),
│ │ │ │ -
336 _duvWeights(duvWeights),
│ │ │ │ -
337 _dvvWeights(dvvWeights) {
│ │ │ │ -
338 }
│ │ │ │ -
│ │ │ │ -
339
│ │ │ │ -
│ │ │ │ -
341 REAL const * GetDuWeights() const {
│ │ │ │ -
342 return _duWeights;
│ │ │ │ -
343 }
│ │ │ │ -
│ │ │ │ -
344
│ │ │ │ -
│ │ │ │ -
346 REAL const * GetDvWeights() const {
│ │ │ │ -
347 return _dvWeights;
│ │ │ │ -
348 }
│ │ │ │ -
│ │ │ │ -
349
│ │ │ │ -
│ │ │ │ -
351 REAL const * GetDuuWeights() const {
│ │ │ │ -
352 return _duuWeights;
│ │ │ │ -
353 }
│ │ │ │ -
│ │ │ │ -
354
│ │ │ │ -
│ │ │ │ -
356 REAL const * GetDuvWeights() const {
│ │ │ │ -
357 return _duvWeights;
│ │ │ │ -
358 }
│ │ │ │ -
│ │ │ │ -
359
│ │ │ │ -
│ │ │ │ -
361 REAL const * GetDvvWeights() const {
│ │ │ │ -
362 return _dvvWeights;
│ │ │ │ -
363 }
│ │ │ │ -
│ │ │ │ -
364
│ │ │ │ -
366 void Next() {
│ │ │ │ -
367 int stride = *this->_size;
│ │ │ │ -
368 ++this->_size;
│ │ │ │ -
369 this->_indices += stride;
│ │ │ │ -
370 this->_weights += stride;
│ │ │ │ -
371 if (_duWeights) _duWeights += stride;
│ │ │ │ -
372 if (_dvWeights) _dvWeights += stride;
│ │ │ │ -
373 if (_duuWeights) _duuWeights += stride;
│ │ │ │ -
374 if (_duvWeights) _duvWeights += stride;
│ │ │ │ -
375 if (_dvvWeights) _dvvWeights += stride;
│ │ │ │ -
376 }
│ │ │ │ -
377
│ │ │ │ -
378private:
│ │ │ │ -
379
│ │ │ │ -
380 friend class StencilTableFactoryReal<REAL>;
│ │ │ │ -
381 friend class LimitStencilTableFactoryReal<REAL>;
│ │ │ │ -
382
│ │ │ │ -
383 REAL * _duWeights, // pointer to stencil u derivative limit weights
│ │ │ │ -
384 * _dvWeights, // pointer to stencil v derivative limit weights
│ │ │ │ -
385 * _duuWeights, // pointer to stencil uu derivative limit weights
│ │ │ │ -
386 * _duvWeights, // pointer to stencil uv derivative limit weights
│ │ │ │ -
387 * _dvvWeights; // pointer to stencil vv derivative limit weights
│ │ │ │ -
388};
│ │ │ │ -
│ │ │ │ -
389
│ │ │ │ -
│ │ │ │ -
392class LimitStencil : public LimitStencilReal<float> {
│ │ │ │ -
393protected:
│ │ │ │ - │ │ │ │ -
395
│ │ │ │ -
396public:
│ │ │ │ -
397 LimitStencil(BaseStencil const & other) : BaseStencil(other) { }
│ │ │ │ -
│ │ │ │ -
398 LimitStencil(int* size, Index * indices, float * weights,
│ │ │ │ -
399 float * duWeights=0, float * dvWeights=0,
│ │ │ │ -
400 float * duuWeights=0, float * duvWeights=0, float * dvvWeights=0)
│ │ │ │ -
401 : BaseStencil(size, indices, weights,
│ │ │ │ -
402 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights) { }
│ │ │ │ -
│ │ │ │ -
403};
│ │ │ │ -
│ │ │ │ -
404
│ │ │ │ -
405
│ │ │ │ -
408template <typename REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
410protected:
│ │ │ │ - │ │ │ │ -
412 int numControlVerts,
│ │ │ │ -
413 std::vector<int> const& offsets,
│ │ │ │ -
414 std::vector<int> const& sizes,
│ │ │ │ -
415 std::vector<int> const& sources,
│ │ │ │ -
416 std::vector<REAL> const& weights,
│ │ │ │ -
417 std::vector<REAL> const& duWeights,
│ │ │ │ -
418 std::vector<REAL> const& dvWeights,
│ │ │ │ -
419 std::vector<REAL> const& duuWeights,
│ │ │ │ -
420 std::vector<REAL> const& duvWeights,
│ │ │ │ -
421 std::vector<REAL> const& dvvWeights,
│ │ │ │ -
422 bool includeCoarseVerts,
│ │ │ │ -
423 size_t firstOffset);
│ │ │ │ -
424
│ │ │ │ -
425public:
│ │ │ │ -
426
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
429
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
432
│ │ │ │ -
│ │ │ │ -
434 std::vector<REAL> const & GetDuWeights() const {
│ │ │ │ -
435 return _duWeights;
│ │ │ │ -
436 }
│ │ │ │ -
│ │ │ │ -
437
│ │ │ │ -
│ │ │ │ -
439 std::vector<REAL> const & GetDvWeights() const {
│ │ │ │ -
440 return _dvWeights;
│ │ │ │ -
441 }
│ │ │ │ -
│ │ │ │ -
442
│ │ │ │ -
│ │ │ │ -
444 std::vector<REAL> const & GetDuuWeights() const {
│ │ │ │ -
445 return _duuWeights;
│ │ │ │ -
446 }
│ │ │ │ -
│ │ │ │ -
447
│ │ │ │ -
│ │ │ │ -
449 std::vector<REAL> const & GetDuvWeights() const {
│ │ │ │ -
450 return _duvWeights;
│ │ │ │ -
451 }
│ │ │ │ -
│ │ │ │ -
452
│ │ │ │ -
│ │ │ │ -
454 std::vector<REAL> const & GetDvvWeights() const {
│ │ │ │ -
455 return _dvvWeights;
│ │ │ │ -
456 }
│ │ │ │ -
│ │ │ │ -
457
│ │ │ │ -
475 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
476 void UpdateDerivs(T const & srcValues, U & uderivs, U & vderivs,
│ │ │ │ -
477 int start=-1, int end=-1) const {
│ │ │ │ -
478
│ │ │ │ -
479 this->update(srcValues, uderivs, _duWeights, start, end);
│ │ │ │ -
480 this->update(srcValues, vderivs, _dvWeights, start, end);
│ │ │ │ -
481 }
│ │ │ │ -
│ │ │ │ -
482
│ │ │ │ -
483 template <class T1, class T2, class U>
│ │ │ │ -
│ │ │ │ -
484 void UpdateDerivs(T1 const & srcBase, int numBase, T2 const & srcRef,
│ │ │ │ -
485 U & uderivs, U & vderivs, int start=-1, int end=-1) const {
│ │ │ │ -
486
│ │ │ │ -
487 this->update(srcBase, numBase, srcRef, uderivs, _duWeights, start, end);
│ │ │ │ -
488 this->update(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end);
│ │ │ │ -
489 }
│ │ │ │ -
│ │ │ │ -
490
│ │ │ │ -
491 // Pointer interface for backward compatibility
│ │ │ │ -
492 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
493 void UpdateDerivs(T const *src, U *uderivs, U *vderivs,
│ │ │ │ -
494 int start=-1, int end=-1) const {
│ │ │ │ -
495
│ │ │ │ -
496 this->update(src, uderivs, _duWeights, start, end);
│ │ │ │ -
497 this->update(src, vderivs, _dvWeights, start, end);
│ │ │ │ -
498 }
│ │ │ │ -
│ │ │ │ -
499 template <class T1, class T2, class U>
│ │ │ │ -
│ │ │ │ -
500 void UpdateDerivs(T1 const *srcBase, int numBase, T2 const *srcRef,
│ │ │ │ -
501 U *uderivs, U *vderivs, int start=-1, int end=-1) const {
│ │ │ │ -
502
│ │ │ │ -
503 this->update(srcBase, numBase, srcRef, uderivs, _duWeights, start, end);
│ │ │ │ -
504 this->update(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end);
│ │ │ │ -
505 }
│ │ │ │ -
│ │ │ │ -
506
│ │ │ │ -
527 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
528 void Update2ndDerivs(T const & srcValues,
│ │ │ │ -
529 U & uuderivs, U & uvderivs, U & vvderivs,
│ │ │ │ -
530 int start=-1, int end=-1) const {
│ │ │ │ -
531
│ │ │ │ -
532 this->update(srcValues, uuderivs, _duuWeights, start, end);
│ │ │ │ -
533 this->update(srcValues, uvderivs, _duvWeights, start, end);
│ │ │ │ -
534 this->update(srcValues, vvderivs, _dvvWeights, start, end);
│ │ │ │ -
535 }
│ │ │ │ -
│ │ │ │ -
536
│ │ │ │ -
537 template <class T1, class T2, class U>
│ │ │ │ -
│ │ │ │ -
538 void Update2ndDerivs(T1 const & srcBase, int numBase, T2 const & srcRef,
│ │ │ │ -
539 U & uuderivs, U & uvderivs, U & vvderivs, int start=-1, int end=-1) const {
│ │ │ │ -
540
│ │ │ │ -
541 this->update(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end);
│ │ │ │ -
542 this->update(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end);
│ │ │ │ -
543 this->update(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end);
│ │ │ │ -
544 }
│ │ │ │ -
│ │ │ │ -
545
│ │ │ │ -
546 // Pointer interface for backward compatibility
│ │ │ │ -
547 template <class T, class U>
│ │ │ │ -
│ │ │ │ -
548 void Update2ndDerivs(T const *src, T *uuderivs, U *uvderivs, U *vvderivs,
│ │ │ │ -
549 int start=-1, int end=-1) const {
│ │ │ │ -
550
│ │ │ │ -
551 this->update(src, uuderivs, _duuWeights, start, end);
│ │ │ │ -
552 this->update(src, uvderivs, _duvWeights, start, end);
│ │ │ │ -
553 this->update(src, vvderivs, _dvvWeights, start, end);
│ │ │ │ -
554 }
│ │ │ │ -
│ │ │ │ -
555 template <class T1, class T2, class U>
│ │ │ │ -
│ │ │ │ -
556 void Update2ndDerivs(T1 const *srcBase, int numBase, T2 const *srcRef,
│ │ │ │ -
557 U *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const {
│ │ │ │ -
558
│ │ │ │ -
559 this->update(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end);
│ │ │ │ -
560 this->update(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end);
│ │ │ │ -
561 this->update(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end);
│ │ │ │ -
562 }
│ │ │ │ -
│ │ │ │ -
563
│ │ │ │ -
565 void Clear();
│ │ │ │ -
566
│ │ │ │ -
567private:
│ │ │ │ -
568 friend class LimitStencilTableFactoryReal<REAL>;
│ │ │ │ -
569
│ │ │ │ -
570 // Resize the table arrays (factory helper)
│ │ │ │ -
571 void resize(int nstencils, int nelems);
│ │ │ │ -
572
│ │ │ │ -
573private:
│ │ │ │ -
574 std::vector<REAL> _duWeights, // u derivative limit stencil weights
│ │ │ │ -
575 _dvWeights, // v derivative limit stencil weights
│ │ │ │ -
576 _duuWeights, // uu derivative limit stencil weights
│ │ │ │ -
577 _duvWeights, // uv derivative limit stencil weights
│ │ │ │ -
578 _dvvWeights; // vv derivative limit stencil weights
│ │ │ │ -
579};
│ │ │ │ -
580
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
584protected:
│ │ │ │ - │ │ │ │ -
586
│ │ │ │ -
587public:
│ │ │ │ -
│ │ │ │ - │ │ │ │ - │ │ │ │ -
590 }
│ │ │ │ -
│ │ │ │ -
│ │ │ │ - │ │ │ │ - │ │ │ │ -
593 }
│ │ │ │ -
│ │ │ │ -
594
│ │ │ │ -
595protected:
│ │ │ │ -
│ │ │ │ -
596 LimitStencilTable(int numControlVerts,
│ │ │ │ -
597 std::vector<int> const& offsets,
│ │ │ │ -
598 std::vector<int> const& sizes,
│ │ │ │ -
599 std::vector<int> const& sources,
│ │ │ │ -
600 std::vector<float> const& weights,
│ │ │ │ -
601 std::vector<float> const& duWeights,
│ │ │ │ -
602 std::vector<float> const& dvWeights,
│ │ │ │ -
603 std::vector<float> const& duuWeights,
│ │ │ │ -
604 std::vector<float> const& duvWeights,
│ │ │ │ -
605 std::vector<float> const& dvvWeights,
│ │ │ │ -
606 bool includeCoarseVerts,
│ │ │ │ -
607 size_t firstOffset)
│ │ │ │ -
608 : BaseTable(numControlVerts,
│ │ │ │ -
609 offsets, sizes, sources, weights,
│ │ │ │ -
610 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights,
│ │ │ │ -
611 includeCoarseVerts, firstOffset) { }
│ │ │ │ -
│ │ │ │ -
612};
│ │ │ │ -
│ │ │ │ -
613
│ │ │ │ -
614
│ │ │ │ -
615// Update values by applying cached stencil weights to new control values
│ │ │ │ -
616template <typename REAL>
│ │ │ │ -
617template <class T1, class T2, class U> void
│ │ │ │ -
│ │ │ │ -
618StencilTableReal<REAL>::update(T1 const &srcBase, int numBase,
│ │ │ │ -
619 T2 const &srcRef, U &dstValues,
│ │ │ │ -
620 std::vector<REAL> const &valueWeights, Index start, Index end) const {
│ │ │ │ -
621
│ │ │ │ -
622 int const * sizes = &_sizes.at(0);
│ │ │ │ -
623 Index const * indices = &_indices.at(0);
│ │ │ │ -
624 REAL const * weights = &valueWeights.at(0);
│ │ │ │ -
625
│ │ │ │ -
626 if (start > 0) {
│ │ │ │ -
627 assert(start < (Index)_offsets.size());
│ │ │ │ -
628 sizes += start;
│ │ │ │ -
629 indices += _offsets[start];
│ │ │ │ -
630 weights += _offsets[start];
│ │ │ │ -
631 } else {
│ │ │ │ -
632 start = 0;
│ │ │ │ -
633 }
│ │ │ │ -
634
│ │ │ │ -
635 int nstencils = ((end < start) ? GetNumStencils() : end) - start;
│ │ │ │ -
636
│ │ │ │ -
637 for (int i = 0; i < nstencils; ++i, ++sizes) {
│ │ │ │ -
638 dstValues[start + i].Clear();
│ │ │ │ -
639 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) {
│ │ │ │ -
640 if (*indices < numBase) {
│ │ │ │ -
641 dstValues[start + i].AddWithWeight(srcBase[*indices], *weights);
│ │ │ │ -
642 } else {
│ │ │ │ -
643 dstValues[start + i].AddWithWeight(srcRef[*indices - numBase], *weights);
│ │ │ │ -
644 }
│ │ │ │ -
645 }
│ │ │ │ -
646 }
│ │ │ │ -
647}
│ │ │ │ -
│ │ │ │ -
648template <typename REAL>
│ │ │ │ -
649template <class T, class U> void
│ │ │ │ -
│ │ │ │ -
650StencilTableReal<REAL>::update(T const &srcValues, U &dstValues,
│ │ │ │ -
651 std::vector<REAL> const &valueWeights, Index start, Index end) const {
│ │ │ │ -
652
│ │ │ │ -
653 int const * sizes = &_sizes.at(0);
│ │ │ │ -
654 Index const * indices = &_indices.at(0);
│ │ │ │ -
655 REAL const * weights = &valueWeights.at(0);
│ │ │ │ -
656
│ │ │ │ -
657 if (start > 0) {
│ │ │ │ -
658 assert(start < (Index)_offsets.size());
│ │ │ │ -
659 sizes += start;
│ │ │ │ -
660 indices += _offsets[start];
│ │ │ │ -
661 weights += _offsets[start];
│ │ │ │ -
662 } else {
│ │ │ │ -
663 start = 0;
│ │ │ │ -
664 }
│ │ │ │ -
665
│ │ │ │ -
666 int nstencils = ((end < start) ? GetNumStencils() : end) - start;
│ │ │ │ -
667
│ │ │ │ -
668 for (int i = 0; i < nstencils; ++i, ++sizes) {
│ │ │ │ -
669 dstValues[start + i].Clear();
│ │ │ │ -
670 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) {
│ │ │ │ -
671 dstValues[start + i].AddWithWeight(srcValues[*indices], *weights);
│ │ │ │ -
672 }
│ │ │ │ -
673 }
│ │ │ │ -
674}
│ │ │ │ -
│ │ │ │ -
675
│ │ │ │ -
676template <typename REAL>
│ │ │ │ -
677inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
679 Index offset=0;
│ │ │ │ -
680 int noffsets = (int)_sizes.size();
│ │ │ │ -
681 _offsets.resize(noffsets);
│ │ │ │ -
682 for (int i=0; i<(int)_sizes.size(); ++i ) {
│ │ │ │ -
683 _offsets[i]=offset;
│ │ │ │ -
684 offset+=_sizes[i];
│ │ │ │ -
685 }
│ │ │ │ -
686}
│ │ │ │ -
│ │ │ │ -
687
│ │ │ │ -
688template <typename REAL>
│ │ │ │ -
689inline void
│ │ │ │ -
│ │ │ │ -
690StencilTableReal<REAL>::resize(int nstencils, int nelems) {
│ │ │ │ -
691 _sizes.resize(nstencils);
│ │ │ │ -
692 _indices.resize(nelems);
│ │ │ │ -
693 _weights.resize(nelems);
│ │ │ │ -
694}
│ │ │ │ -
│ │ │ │ -
695
│ │ │ │ -
696template <typename REAL>
│ │ │ │ -
697inline void
│ │ │ │ -
│ │ │ │ -
698StencilTableReal<REAL>::reserve(int nstencils, int nelems) {
│ │ │ │ -
699 _sizes.reserve(nstencils);
│ │ │ │ -
700 _indices.reserve(nelems);
│ │ │ │ -
701 _weights.reserve(nelems);
│ │ │ │ -
702}
│ │ │ │ -
│ │ │ │ -
703
│ │ │ │ -
704template <typename REAL>
│ │ │ │ -
705inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
707 std::vector<int>(_sizes).swap(_sizes);
│ │ │ │ -
708 std::vector<Index>(_indices).swap(_indices);
│ │ │ │ -
709 std::vector<REAL>(_weights).swap(_weights);
│ │ │ │ -
710}
│ │ │ │ -
│ │ │ │ -
711
│ │ │ │ -
712template <typename REAL>
│ │ │ │ -
713inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
715 shrinkToFit();
│ │ │ │ -
716 generateOffsets();
│ │ │ │ -
717}
│ │ │ │ -
│ │ │ │ -
718
│ │ │ │ -
719// Returns a Stencil at index i in the table
│ │ │ │ -
720template <typename REAL>
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
723 assert((! _offsets.empty()) && i<(int)_offsets.size());
│ │ │ │ -
724
│ │ │ │ -
725 Index ofs = _offsets[i];
│ │ │ │ -
726
│ │ │ │ -
727 return StencilReal<REAL>(const_cast<int*>(&_sizes[i]),
│ │ │ │ -
728 const_cast<Index*>(&_indices[ofs]),
│ │ │ │ -
729 const_cast<REAL*>(&_weights[ofs]));
│ │ │ │ -
730}
│ │ │ │ -
│ │ │ │ -
731
│ │ │ │ -
732template <typename REAL>
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
735 return GetStencil(index);
│ │ │ │ -
736}
│ │ │ │ -
│ │ │ │ -
737
│ │ │ │ -
738template <typename REAL>
│ │ │ │ -
739inline void
│ │ │ │ -
740LimitStencilTableReal<REAL>::resize(int nstencils, int nelems) {
│ │ │ │ -
741 StencilTableReal<REAL>::resize(nstencils, nelems);
│ │ │ │ -
742 _duWeights.resize(nelems);
│ │ │ │ -
743 _dvWeights.resize(nelems);
│ │ │ │ -
744}
│ │ │ │ -
745
│ │ │ │ -
746// Returns a LimitStencil at index i in the table
│ │ │ │ -
747template <typename REAL>
│ │ │ │ -
748inline LimitStencilReal<REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
750 assert((! this->GetOffsets().empty()) && i<(int)this->GetOffsets().size());
│ │ │ │ -
751
│ │ │ │ -
752 Index ofs = this->GetOffsets()[i];
│ │ │ │ -
753
│ │ │ │ -
754 if (!_duWeights.empty() && !_dvWeights.empty() &&
│ │ │ │ -
755 !_duuWeights.empty() && !_duvWeights.empty() && !_dvvWeights.empty()) {
│ │ │ │ - │ │ │ │ -
757 const_cast<int *>(&this->GetSizes()[i]),
│ │ │ │ -
758 const_cast<Index *>(&this->GetControlIndices()[ofs]),
│ │ │ │ -
759 const_cast<REAL *>(&this->GetWeights()[ofs]),
│ │ │ │ -
760 const_cast<REAL *>(&GetDuWeights()[ofs]),
│ │ │ │ -
761 const_cast<REAL *>(&GetDvWeights()[ofs]),
│ │ │ │ -
762 const_cast<REAL *>(&GetDuuWeights()[ofs]),
│ │ │ │ -
763 const_cast<REAL *>(&GetDuvWeights()[ofs]),
│ │ │ │ -
764 const_cast<REAL *>(&GetDvvWeights()[ofs]) );
│ │ │ │ -
765 } else if (!_duWeights.empty() && !_dvWeights.empty()) {
│ │ │ │ - │ │ │ │ -
767 const_cast<int *>(&this->GetSizes()[i]),
│ │ │ │ -
768 const_cast<Index *>(&this->GetControlIndices()[ofs]),
│ │ │ │ -
769 const_cast<REAL *>(&this->GetWeights()[ofs]),
│ │ │ │ -
770 const_cast<REAL *>(&GetDuWeights()[ofs]),
│ │ │ │ -
771 const_cast<REAL *>(&GetDvWeights()[ofs]) );
│ │ │ │ -
772 } else {
│ │ │ │ - │ │ │ │ -
774 const_cast<int *>(&this->GetSizes()[i]),
│ │ │ │ -
775 const_cast<Index *>(&this->GetControlIndices()[ofs]),
│ │ │ │ -
776 const_cast<REAL *>(&this->GetWeights()[ofs]) );
│ │ │ │ -
777 }
│ │ │ │ -
778}
│ │ │ │ -
│ │ │ │ -
779
│ │ │ │ -
780template <typename REAL>
│ │ │ │ - │ │ │ │ -
│ │ │ │ - │ │ │ │ -
783 return GetLimitStencil(index);
│ │ │ │ -
784}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
785
│ │ │ │ -
786} // end namespace Far
│ │ │ │ -
787
│ │ │ │ -
788} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
789using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
790
│ │ │ │ -
791} // end namespace OpenSubdiv
│ │ │ │ -
792
│ │ │ │ -
793#endif // OPENSUBDIV3_FAR_STENCILTABLE_H
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ +
│ │ │ │ +
300 static StencilTable const * Create(
│ │ │ │ +
301 int numTables, StencilTable const ** tables) {
│ │ │ │ +
302
│ │ │ │ +
303 return static_cast<StencilTable const *>(
│ │ │ │ +
304 BaseFactory::Create(numTables,
│ │ │ │ +
305 reinterpret_cast<BaseTable const **>(tables)));
│ │ │ │ +
306 }
│ │ │ │ +
│ │ │ │ +
307
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
309 TopologyRefiner const &refiner,
│ │ │ │ +
310 StencilTable const *baseStencilTable,
│ │ │ │ +
311 StencilTable const *localPointStencilTable,
│ │ │ │ +
312 bool factorize = true) {
│ │ │ │ +
313
│ │ │ │ +
314 return static_cast<StencilTable const *>(
│ │ │ │ + │ │ │ │ +
316 static_cast<BaseTable const *>(baseStencilTable),
│ │ │ │ +
317 static_cast<BaseTable const *>(localPointStencilTable),
│ │ │ │ +
318 factorize));
│ │ │ │ +
319 }
│ │ │ │ +
│ │ │ │ +
320
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
322 TopologyRefiner const &refiner,
│ │ │ │ +
323 StencilTable const *baseStencilTable,
│ │ │ │ +
324 StencilTable const *localPointStencilTable,
│ │ │ │ +
325 bool factorize = true) {
│ │ │ │ +
326
│ │ │ │ +
327 return static_cast<StencilTable const *>(
│ │ │ │ + │ │ │ │ +
329 static_cast<BaseTable const *>(baseStencilTable),
│ │ │ │ +
330 static_cast<BaseTable const *>(localPointStencilTable),
│ │ │ │ +
331 factorize));
│ │ │ │ +
332 }
│ │ │ │ +
│ │ │ │ +
333
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
335 TopologyRefiner const &refiner,
│ │ │ │ +
336 StencilTable const *baseStencilTable,
│ │ │ │ +
337 StencilTable const *localPointStencilTable,
│ │ │ │ +
338 int channel = 0,
│ │ │ │ +
339 bool factorize = true) {
│ │ │ │ +
340
│ │ │ │ +
341 return static_cast<StencilTable const *>(
│ │ │ │ + │ │ │ │ +
343 static_cast<BaseTable const *>(baseStencilTable),
│ │ │ │ +
344 static_cast<BaseTable const *>(localPointStencilTable),
│ │ │ │ +
345 channel, factorize));
│ │ │ │ +
346 }
│ │ │ │ +
│ │ │ │ +
347};
│ │ │ │ +
│ │ │ │ +
348
│ │ │ │ +
349class LimitStencil;
│ │ │ │ +
350class LimitStencilTable;
│ │ │ │ +
351
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
355private:
│ │ │ │ + │ │ │ │ + │ │ │ │ +
358
│ │ │ │ +
359public:
│ │ │ │ +
│ │ │ │ +
360 static LimitStencilTable const * Create(
│ │ │ │ +
361 TopologyRefiner const & refiner,
│ │ │ │ +
362 LocationArrayVec const & locationArrays,
│ │ │ │ +
363 StencilTable const * cvStencils = 0,
│ │ │ │ +
364 PatchTable const * patchTable = 0,
│ │ │ │ +
365 Options options = Options()) {
│ │ │ │ +
366
│ │ │ │ +
367 return static_cast<LimitStencilTable const *>(
│ │ │ │ + │ │ │ │ +
369 refiner,
│ │ │ │ +
370 locationArrays,
│ │ │ │ +
371 static_cast<BaseTable const *>(cvStencils),
│ │ │ │ +
372 patchTable,
│ │ │ │ +
373 options));
│ │ │ │ +
374 }
│ │ │ │ +
│ │ │ │ +
375};
│ │ │ │ +
│ │ │ │ +
376
│ │ │ │ +
377} // end namespace Far
│ │ │ │ +
378
│ │ │ │ +
379} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
380using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
381
│ │ │ │ +
382} // end namespace OpenSubdiv
│ │ │ │ +
383
│ │ │ │ +
384#endif // OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
StencilReal(int *size, Index *indices, REAL *weights)
Constructor.
│ │ │ │ -
void Next()
Advance to the next stencil in the table.
│ │ │ │ -
StencilReal(StencilReal const &other)
Copy constructor.
│ │ │ │ - │ │ │ │ -
Index const * GetVertexIndices() const
Returns the control vertices' indices.
│ │ │ │ -
int GetSize() const
Returns the size of the stencil.
│ │ │ │ - │ │ │ │ -
int * GetSizePtr() const
Returns the size of the stencil as a pointer.
│ │ │ │ -
REAL const * GetWeights() const
Returns the interpolation weights.
│ │ │ │ -
Vertex stencil class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ -
Stencil(int *size, Index *indices, float *weights)
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
int GetNumControlVertices() const
Returns the number of control vertices indexed in the table.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
void update(T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues, std::vector< REAL > const &valueWeights, Index start, Index end) const
│ │ │ │ -
void UpdateValues(T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues, Index start=-1, Index end=-1) const
│ │ │ │ -
std::vector< Index > const & GetControlIndices() const
Returns the indices of the control vertices.
│ │ │ │ - │ │ │ │ -
StencilReal< REAL > operator[](Index index) const
Returns the stencil at index i in the table.
│ │ │ │ - │ │ │ │ -
void update(T const &srcValues, U &dstValues, std::vector< REAL > const &valueWeights, Index start, Index end) const
│ │ │ │ -
std::vector< int > const & GetSizes() const
Returns the number of control vertices of each stencil in the table.
│ │ │ │ -
int GetNumStencils() const
Returns the number of stencils in the table.
│ │ │ │ - │ │ │ │ -
std::vector< Index > const & GetOffsets() const
Returns the offset to a given stencil (factory may leave empty)
│ │ │ │ -
StencilReal< REAL > GetStencil(Index i) const
Returns a Stencil at index i in the table.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
void Clear()
Clears the stencils from the table.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
std::vector< REAL > const & GetWeights() const
Returns the stencil interpolation weights.
│ │ │ │ -
void UpdateValues(T1 const *srcBase, int numBase, T2 const *srcRef, U *dst, Index start=-1, Index end=-1) const
│ │ │ │ -
StencilTableReal(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< REAL > const &weights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
void UpdateValues(T const *src, U *dst, Index start=-1, Index end=-1) const
│ │ │ │ -
void UpdateValues(T const &srcValues, U &dstValues, Index start=-1, Index end=-1) const
Updates point values based on the control values.
│ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
StencilTable(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< float > const &weights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
REAL const * GetDuvWeights() const
Returns the uv derivative weights.
│ │ │ │ -
REAL const * GetDvWeights() const
Returns the v derivative weights.
│ │ │ │ -
void Next()
Advance to the next stencil in the table.
│ │ │ │ -
REAL const * GetDvvWeights() const
Returns the vv derivative weights.
│ │ │ │ -
LimitStencilReal(int *size, Index *indices, REAL *weights, REAL *duWeights=0, REAL *dvWeights=0, REAL *duuWeights=0, REAL *duvWeights=0, REAL *dvvWeights=0)
Constructor.
│ │ │ │ -
REAL const * GetDuWeights() const
Returns the u derivative weights.
│ │ │ │ -
REAL const * GetDuuWeights() const
Returns the uu derivative weights.
│ │ │ │ -
Limit point stencil class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
LimitStencil(int *size, Index *indices, float *weights, float *duWeights=0, float *dvWeights=0, float *duuWeights=0, float *duvWeights=0, float *dvvWeights=0)
│ │ │ │ - │ │ │ │ -
std::vector< REAL > const & GetDuuWeights() const
Returns the 'uu' derivative stencil interpolation weights.
│ │ │ │ -
LimitStencilReal< REAL > operator[](Index index) const
Returns the limit stencil at index i in the table.
│ │ │ │ -
std::vector< REAL > const & GetDvvWeights() const
Returns the 'vv' derivative stencil interpolation weights.
│ │ │ │ -
void UpdateDerivs(T const *src, U *uderivs, U *vderivs, int start=-1, int end=-1) const
│ │ │ │ -
void Update2ndDerivs(T const *src, T *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const
│ │ │ │ -
std::vector< REAL > const & GetDvWeights() const
Returns the 'v' derivative stencil interpolation weights.
│ │ │ │ -
void Update2ndDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const
│ │ │ │ -
void UpdateDerivs(T const &srcValues, U &uderivs, U &vderivs, int start=-1, int end=-1) const
Updates derivative values based on the control values.
│ │ │ │ -
LimitStencilReal< REAL > GetLimitStencil(Index i) const
Returns a LimitStencil at index i in the table.
│ │ │ │ -
LimitStencilTableReal(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< REAL > const &weights, std::vector< REAL > const &duWeights, std::vector< REAL > const &dvWeights, std::vector< REAL > const &duuWeights, std::vector< REAL > const &duvWeights, std::vector< REAL > const &dvvWeights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ -
void Update2ndDerivs(T const &srcValues, U &uuderivs, U &uvderivs, U &vvderivs, int start=-1, int end=-1) const
Updates 2nd derivative values based on the control values.
│ │ │ │ -
std::vector< REAL > const & GetDuWeights() const
Returns the 'u' derivative stencil interpolation weights.
│ │ │ │ -
void Clear()
Clears the stencils from the table.
│ │ │ │ -
void Update2ndDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U &uuderivs, U &uvderivs, U &vvderivs, int start=-1, int end=-1) const
│ │ │ │ -
std::vector< REAL > const & GetDuvWeights() const
Returns the 'uv' derivative stencil interpolation weights.
│ │ │ │ -
void UpdateDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U &uderivs, U &vderivs, int start=-1, int end=-1) const
│ │ │ │ -
void UpdateDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U *uderivs, U *vderivs, int start=-1, int end=-1) const
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
LimitStencilTable(int numControlVerts, std::vector< int > const &offsets, std::vector< int > const &sizes, std::vector< int > const &sources, std::vector< float > const &weights, std::vector< float > const &duWeights, std::vector< float > const &dvWeights, std::vector< float > const &duuWeights, std::vector< float > const &duvWeights, std::vector< float > const &dvvWeights, bool includeCoarseVerts, size_t firstOffset)
│ │ │ │ - │ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ + │ │ │ │ +
static StencilTableReal< REAL > const * Create(TopologyRefiner const &refiner, Options options=Options())
Instantiates StencilTable from TopologyRefiner that have been refined uniformly or adaptively.
│ │ │ │ +
static StencilTableReal< REAL > const * AppendLocalPointStencilTableFaceVarying(TopologyRefiner const &refiner, StencilTableReal< REAL > const *baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, int channel=0, bool factorize=true)
Utility function for stencil splicing for local point face-varying stencils.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
static StencilTableReal< REAL > const * AppendLocalPointStencilTableVarying(TopologyRefiner const &refiner, StencilTableReal< REAL > const *baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool factorize=true)
Utility function for stencil splicing for local point varying stencils.
│ │ │ │ +
static StencilTableReal< REAL > const * AppendLocalPointStencilTable(TopologyRefiner const &refiner, StencilTableReal< REAL > const *baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool factorize=true)
Utility function for stencil splicing for local point stencils.
│ │ │ │ +
static StencilTableReal< REAL > const * Create(int numTables, StencilTableReal< REAL > const **tables)
Instantiates StencilTable by concatenating an array of existing stencil tables.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
static LimitStencilTableReal< REAL > const * Create(TopologyRefiner const &refiner, LocationArrayVec const &locationArrays, StencilTableReal< REAL > const *cvStencils=0, PatchTable const *patchTable=0, Options options=Options())
Instantiates LimitStencilTable from a TopologyRefiner that has been refined either uniformly or adapt...
│ │ │ │ + │ │ │ │ +
Vertex stencil class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
unsigned int generateIntermediateLevels
vertices at all levels or highest only
│ │ │ │ +
unsigned int generateControlVerts
generate stencils for control-vertices
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
unsigned int generate2ndDerivatives
Generate weights for 2nd derivatives.
│ │ │ │ +
unsigned int generate1stDerivatives
Generate weights for 1st derivatives.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
Stencil table factory class wrapping the template for compatibility.
│ │ │ │ +
static StencilTable const * AppendLocalPointStencilTableVarying(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, bool factorize=true)
│ │ │ │ +
static StencilTable const * Create(TopologyRefiner const &refiner, Options options=Options())
│ │ │ │ +
static StencilTable const * AppendLocalPointStencilTableFaceVarying(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, int channel=0, bool factorize=true)
│ │ │ │ +
static StencilTable const * AppendLocalPointStencilTable(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, bool factorize=true)
│ │ │ │ +
static StencilTable const * Create(int numTables, StencilTable const **tables)
│ │ │ │ +
Stencil table factory class wrapping the template for compatibility.
│ │ │ │ +
static LimitStencilTable const * Create(TopologyRefiner const &refiner, LocationArrayVec const &locationArrays, StencilTable const *cvStencils=0, PatchTable const *patchTable=0, Options options=Options())
│ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -stencilTable.h │ │ │ │ │ +stencilTableFactory.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,990 +24,497 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_STENCILTABLE_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../far/types.h" │ │ │ │ │ +30#include "../far/patchTable.h" │ │ │ │ │ 31 │ │ │ │ │ -32#include │ │ │ │ │ -33#include │ │ │ │ │ -34#include │ │ │ │ │ -35#include │ │ │ │ │ +32#include │ │ │ │ │ +33 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ 36 │ │ │ │ │ -37namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -38namespace OPENSUBDIV_VERSION { │ │ │ │ │ -39 │ │ │ │ │ -40namespace Far { │ │ │ │ │ -41 │ │ │ │ │ -42// Forward declarations for friends: │ │ │ │ │ -43class PatchTableBuilder; │ │ │ │ │ -44 │ │ │ │ │ -45template class StencilTableFactoryReal; │ │ │ │ │ -46template class LimitStencilTableFactoryReal; │ │ │ │ │ +37namespace Far { │ │ │ │ │ +38 │ │ │ │ │ +39class TopologyRefiner; │ │ │ │ │ +40 │ │ │ │ │ +41template class StencilReal; │ │ │ │ │ +42template class StencilTableReal; │ │ │ │ │ +43 │ │ │ │ │ +44template class LimitStencilReal; │ │ │ │ │ +45template class LimitStencilTableReal; │ │ │ │ │ +46 │ │ │ │ │ 47 │ │ │ │ │ -52template │ │ │ │ │ -_5_3class _S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ -54public: │ │ │ │ │ -55 │ │ │ │ │ -_5_7 _S_t_e_n_c_i_l_R_e_a_l() {} │ │ │ │ │ -58 │ │ │ │ │ -_6_7 _S_t_e_n_c_i_l_R_e_a_l(int * size, _I_n_d_e_x * indices, REAL * weights) │ │ │ │ │ -68 : ___s_i_z_e(size), ___i_n_d_i_c_e_s(indices), ___w_e_i_g_h_t_s(weights) { } │ │ │ │ │ -69 │ │ │ │ │ -_7_1 _S_t_e_n_c_i_l_R_e_a_l(_S_t_e_n_c_i_l_R_e_a_l const & other) { │ │ │ │ │ -72 ___s_i_z_e = other.___s_i_z_e; │ │ │ │ │ -73 ___i_n_d_i_c_e_s = other.___i_n_d_i_c_e_s; │ │ │ │ │ -74 ___w_e_i_g_h_t_s = other.___w_e_i_g_h_t_s; │ │ │ │ │ -75 } │ │ │ │ │ -76 │ │ │ │ │ -_7_8 int _G_e_t_S_i_z_e() const { │ │ │ │ │ -79 return *___s_i_z_e; │ │ │ │ │ -80 } │ │ │ │ │ -81 │ │ │ │ │ -_8_3 int * _G_e_t_S_i_z_e_P_t_r() const { │ │ │ │ │ -84 return ___s_i_z_e; │ │ │ │ │ -85 } │ │ │ │ │ -86 │ │ │ │ │ -_8_8 _I_n_d_e_x const * _G_e_t_V_e_r_t_e_x_I_n_d_i_c_e_s() const { │ │ │ │ │ -89 return ___i_n_d_i_c_e_s; │ │ │ │ │ -90 } │ │ │ │ │ -91 │ │ │ │ │ -_9_3 REAL const * _G_e_t_W_e_i_g_h_t_s() const { │ │ │ │ │ -94 return ___w_e_i_g_h_t_s; │ │ │ │ │ -95 } │ │ │ │ │ +50template │ │ │ │ │ +_5_1class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l { │ │ │ │ │ +52 │ │ │ │ │ +53public: │ │ │ │ │ +54 │ │ │ │ │ +_5_5 enum _M_o_d_e { │ │ │ │ │ +_5_6 _I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X=0, │ │ │ │ │ +_5_7 _I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G, │ │ │ │ │ +58 _I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ +_5_9 }; │ │ │ │ │ +60 │ │ │ │ │ +_6_1 struct _O_p_t_i_o_n_s { │ │ │ │ │ +62 │ │ │ │ │ +_6_3 _O_p_t_i_o_n_s() : _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e(_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X), │ │ │ │ │ +64 _g_e_n_e_r_a_t_e_O_f_f_s_e_t_s(false), │ │ │ │ │ +65 _g_e_n_e_r_a_t_e_C_o_n_t_r_o_l_V_e_r_t_s(false), │ │ │ │ │ +66 _g_e_n_e_r_a_t_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s(true), │ │ │ │ │ +67 _f_a_c_t_o_r_i_z_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s(true), │ │ │ │ │ +68 _m_a_x_L_e_v_e_l(10), │ │ │ │ │ +69 _f_v_a_r_C_h_a_n_n_e_l(0) { } │ │ │ │ │ +70 │ │ │ │ │ +_7_1 unsigned int _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e : 2, │ │ │ │ │ +_7_2 _g_e_n_e_r_a_t_e_O_f_f_s_e_t_s : 1, │ │ │ │ │ +_7_3 _g_e_n_e_r_a_t_e_C_o_n_t_r_o_l_V_e_r_t_s : 1, │ │ │ │ │ +_7_4 _g_e_n_e_r_a_t_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s : 1, │ │ │ │ │ +_7_5 _f_a_c_t_o_r_i_z_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s : 1, │ │ │ │ │ +_7_8 _m_a_x_L_e_v_e_l : 4; │ │ │ │ │ +_7_9 unsigned int _f_v_a_r_C_h_a_n_n_e_l; │ │ │ │ │ +81 }; │ │ │ │ │ +82 │ │ │ │ │ +_9_4 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _C_r_e_a_t_e( │ │ │ │ │ +95 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s()); │ │ │ │ │ 96 │ │ │ │ │ -_9_8 void _N_e_x_t() { │ │ │ │ │ -99 int stride = *___s_i_z_e; │ │ │ │ │ -100 ++___s_i_z_e; │ │ │ │ │ -101 ___i_n_d_i_c_e_s += stride; │ │ │ │ │ -102 ___w_e_i_g_h_t_s += stride; │ │ │ │ │ -103 } │ │ │ │ │ -104 │ │ │ │ │ -105protected: │ │ │ │ │ -106 friend class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ -107 friend class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ -108 │ │ │ │ │ -_1_0_9 int * ___s_i_z_e; │ │ │ │ │ -_1_1_0 _I_n_d_e_x * ___i_n_d_i_c_e_s; │ │ │ │ │ -_1_1_1 REAL * ___w_e_i_g_h_t_s; │ │ │ │ │ -112}; │ │ │ │ │ +97 │ │ │ │ │ +_1_1_0 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _C_r_e_a_t_e( │ │ │ │ │ +111 int numTables, _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const ** tables); │ │ │ │ │ +112 │ │ │ │ │ 113 │ │ │ │ │ -_1_1_6class _S_t_e_n_c_i_l : public _S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ -117protected: │ │ │ │ │ -_1_1_8 typedef _S_t_e_n_c_i_l_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_S_t_e_n_c_i_l; │ │ │ │ │ -119 │ │ │ │ │ -120public: │ │ │ │ │ -_1_2_1 _S_t_e_n_c_i_l() : _B_a_s_e_S_t_e_n_c_i_l() { } │ │ │ │ │ -_1_2_2 _S_t_e_n_c_i_l(_B_a_s_e_S_t_e_n_c_i_l const & other) : _B_a_s_e_S_t_e_n_c_i_l(other) { } │ │ │ │ │ -_1_2_3 _S_t_e_n_c_i_l(int * size, _I_n_d_e_x * indices, float * weights) │ │ │ │ │ -124 : _B_a_s_e_S_t_e_n_c_i_l(size, indices, weights) { } │ │ │ │ │ -125}; │ │ │ │ │ -126 │ │ │ │ │ -127 │ │ │ │ │ -140template │ │ │ │ │ -_1_4_1class _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ -142protected: │ │ │ │ │ -_1_4_3 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l(int numControlVerts, │ │ │ │ │ -144 std::vector const& offsets, │ │ │ │ │ -145 std::vector const& sizes, │ │ │ │ │ -146 std::vector const& sources, │ │ │ │ │ -147 std::vector const& weights, │ │ │ │ │ -148 bool includeCoarseVerts, │ │ │ │ │ -149 size_t firstOffset); │ │ │ │ │ -150 │ │ │ │ │ -151public: │ │ │ │ │ -152 │ │ │ │ │ -_1_5_3 virtual _~_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l() {}; │ │ │ │ │ -154 │ │ │ │ │ -_1_5_6 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { │ │ │ │ │ -157 return (int)___s_i_z_e_s.size(); │ │ │ │ │ -158 } │ │ │ │ │ -159 │ │ │ │ │ -_1_6_1 int _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s() const { │ │ │ │ │ -162 return ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s; │ │ │ │ │ -163 } │ │ │ │ │ -164 │ │ │ │ │ -_1_6_6 _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _G_e_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const; │ │ │ │ │ -167 │ │ │ │ │ -_1_6_9 std::vector const & _G_e_t_S_i_z_e_s() const { │ │ │ │ │ -170 return ___s_i_z_e_s; │ │ │ │ │ -171 } │ │ │ │ │ -172 │ │ │ │ │ -_1_7_4 std::vector const & _G_e_t_O_f_f_s_e_t_s() const { │ │ │ │ │ -175 return ___o_f_f_s_e_t_s; │ │ │ │ │ -176 } │ │ │ │ │ -177 │ │ │ │ │ -_1_7_9 std::vector const & _G_e_t_C_o_n_t_r_o_l_I_n_d_i_c_e_s() const { │ │ │ │ │ -180 return ___i_n_d_i_c_e_s; │ │ │ │ │ -181 } │ │ │ │ │ +_1_2_8 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e( │ │ │ │ │ +129 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +130 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *baseStencilTable, │ │ │ │ │ +131 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *localPointStencilTable, │ │ │ │ │ +132 bool factorize = true); │ │ │ │ │ +133 │ │ │ │ │ +_1_4_8 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g( │ │ │ │ │ +149 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +150 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *baseStencilTable, │ │ │ │ │ +151 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *localPointStencilTable, │ │ │ │ │ +152 bool factorize = true) { │ │ │ │ │ +153 return _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e( │ │ │ │ │ +154 refiner, baseStencilTable, localPointStencilTable, factorize); │ │ │ │ │ +155 } │ │ │ │ │ +156 │ │ │ │ │ +_1_7_4 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +175 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +176 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *baseStencilTable, │ │ │ │ │ +177 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *localPointStencilTable, │ │ │ │ │ +178 int channel = 0, │ │ │ │ │ +179 bool factorize = true); │ │ │ │ │ +180 │ │ │ │ │ +181private: │ │ │ │ │ 182 │ │ │ │ │ -_1_8_4 std::vector const & _G_e_t_W_e_i_g_h_t_s() const { │ │ │ │ │ -185 return ___w_e_i_g_h_t_s; │ │ │ │ │ -186 } │ │ │ │ │ +183 // Generate stencils for the coarse control-vertices (single weight = 1.0f) │ │ │ │ │ +184 static void generateControlVertStencils( │ │ │ │ │ +185 int numControlVerts, │ │ │ │ │ +186 _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> & dst); │ │ │ │ │ 187 │ │ │ │ │ -_1_8_9 _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const; │ │ │ │ │ -190 │ │ │ │ │ -204 template │ │ │ │ │ -_2_0_5 void _U_p_d_a_t_e_V_a_l_u_e_s(T const &srcValues, U &dstValues, _I_n_d_e_x start=-1, _I_n_d_e_x │ │ │ │ │ -end=-1) const { │ │ │ │ │ -206 this->_u_p_d_a_t_e(srcValues, dstValues, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ -207 } │ │ │ │ │ -208 │ │ │ │ │ -209 template │ │ │ │ │ -_2_1_0 void _U_p_d_a_t_e_V_a_l_u_e_s(T1 const &srcBase, int numBase, T2 const &srcRef, │ │ │ │ │ -211 U &dstValues, _I_n_d_e_x start=-1, _I_n_d_e_x end=-1) const { │ │ │ │ │ -212 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, dstValues, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ -213 } │ │ │ │ │ -214 │ │ │ │ │ -215 // Pointer interface for backward compatibility │ │ │ │ │ -216 template │ │ │ │ │ -_2_1_7 void _U_p_d_a_t_e_V_a_l_u_e_s(T const *src, U *dst, _I_n_d_e_x start=-1, _I_n_d_e_x end=-1) const │ │ │ │ │ -{ │ │ │ │ │ -218 this->_u_p_d_a_t_e(src, dst, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ -219 } │ │ │ │ │ -220 template │ │ │ │ │ -_2_2_1 void _U_p_d_a_t_e_V_a_l_u_e_s(T1 const *srcBase, int numBase, T2 const *srcRef, │ │ │ │ │ -222 U *dst, _I_n_d_e_x start=-1, _I_n_d_e_x end=-1) const { │ │ │ │ │ -223 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, dst, ___w_e_i_g_h_t_s, start, end); │ │ │ │ │ -224 } │ │ │ │ │ +188 // Internal method to splice local point stencils │ │ │ │ │ +189 static _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * appendLocalPointStencilTable( │ │ │ │ │ +190 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +191 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * baseStencilTable, │ │ │ │ │ +192 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * localPointStencilTable, │ │ │ │ │ +193 int channel, │ │ │ │ │ +194 bool factorize); │ │ │ │ │ +195}; │ │ │ │ │ +196 │ │ │ │ │ +208template │ │ │ │ │ +_2_0_9class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l { │ │ │ │ │ +210 │ │ │ │ │ +211public: │ │ │ │ │ +212 │ │ │ │ │ +_2_1_3 enum _M_o_d_e { │ │ │ │ │ +_2_1_4 _I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X=0, │ │ │ │ │ +_2_1_5 _I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G, │ │ │ │ │ +216 _I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ +_2_1_7 }; │ │ │ │ │ +218 │ │ │ │ │ +_2_1_9 struct _O_p_t_i_o_n_s { │ │ │ │ │ +220 │ │ │ │ │ +_2_2_1 _O_p_t_i_o_n_s() : _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e(_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X), │ │ │ │ │ +222 _g_e_n_e_r_a_t_e_1_s_t_D_e_r_i_v_a_t_i_v_e_s(true), │ │ │ │ │ +223 _g_e_n_e_r_a_t_e_2_n_d_D_e_r_i_v_a_t_i_v_e_s(false), │ │ │ │ │ +224 _f_v_a_r_C_h_a_n_n_e_l(0) { } │ │ │ │ │ 225 │ │ │ │ │ -_2_2_7 void _C_l_e_a_r(); │ │ │ │ │ -228 │ │ │ │ │ -229protected: │ │ │ │ │ -230 │ │ │ │ │ -231 // Update values by applying cached stencil weights to new control values │ │ │ │ │ -232 template │ │ │ │ │ -_2_3_3 void _u_p_d_a_t_e( T const &srcValues, U &dstValues, │ │ │ │ │ -234 std::vector const & valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const; │ │ │ │ │ -235 template │ │ │ │ │ -_2_3_6 void _u_p_d_a_t_e( T1 const &srcBase, int numBase, T2 const &srcRef, U │ │ │ │ │ -&dstValues, │ │ │ │ │ -237 std::vector const & valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const; │ │ │ │ │ -238 │ │ │ │ │ -239 // Populate the offsets table from the stencil sizes in _sizes (factory │ │ │ │ │ -helper) │ │ │ │ │ -_2_4_0 void _g_e_n_e_r_a_t_e_O_f_f_s_e_t_s(); │ │ │ │ │ -241 │ │ │ │ │ -242 // Resize the table arrays (factory helper) │ │ │ │ │ -_2_4_3 void _r_e_s_i_z_e(int nstencils, int nelems); │ │ │ │ │ -244 │ │ │ │ │ -245 // Reserves the table arrays (factory helper) │ │ │ │ │ -_2_4_6 void _r_e_s_e_r_v_e(int nstencils, int nelems); │ │ │ │ │ -247 │ │ │ │ │ -248 // Reallocates the table arrays to remove excess capacity (factory helper) │ │ │ │ │ -_2_4_9 void _s_h_r_i_n_k_T_o_F_i_t(); │ │ │ │ │ -250 │ │ │ │ │ -251 // Performs any final operations on internal tables (factory helper) │ │ │ │ │ -_2_5_2 void _f_i_n_a_l_i_z_e(); │ │ │ │ │ -253 │ │ │ │ │ -254protected: │ │ │ │ │ -_2_5_5 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l() : ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(0) {} │ │ │ │ │ -_2_5_6 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l(int numControlVerts) │ │ │ │ │ -257 : ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(numControlVerts) │ │ │ │ │ -258 { } │ │ │ │ │ -259 │ │ │ │ │ -260 friend class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ -_2_6_1 friend class _F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r; │ │ │ │ │ -262 │ │ │ │ │ -_2_6_3 int ___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s; // number of control vertices │ │ │ │ │ -264 │ │ │ │ │ -_2_6_5 std::vector ___s_i_z_e_s; // number of coefficients for each stencil │ │ │ │ │ -_2_6_6 std::vector ___o_f_f_s_e_t_s, // offset to the start of each stencil │ │ │ │ │ -_2_6_7 ___i_n_d_i_c_e_s; // indices of contributing coarse vertices │ │ │ │ │ -_2_6_8 std::vector ___w_e_i_g_h_t_s; // stencil weight coefficients │ │ │ │ │ -269}; │ │ │ │ │ -270 │ │ │ │ │ -_2_7_3class _S_t_e_n_c_i_l_T_a_b_l_e : public _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ -274protected: │ │ │ │ │ -_2_7_5 typedef _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ -276 │ │ │ │ │ -277public: │ │ │ │ │ -_2_7_8 _S_t_e_n_c_i_l _G_e_t_S_t_e_n_c_i_l(_I_n_d_e_x index) const { │ │ │ │ │ -279 return _S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ -280 } │ │ │ │ │ -_2_8_1 _S_t_e_n_c_i_l _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ -282 return _S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ -283 } │ │ │ │ │ +_2_2_6 unsigned int _i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e : 2, │ │ │ │ │ +_2_2_7 _g_e_n_e_r_a_t_e_1_s_t_D_e_r_i_v_a_t_i_v_e_s : 1, │ │ │ │ │ +_2_2_8 _g_e_n_e_r_a_t_e_2_n_d_D_e_r_i_v_a_t_i_v_e_s : 1; │ │ │ │ │ +_2_2_9 unsigned int _f_v_a_r_C_h_a_n_n_e_l; │ │ │ │ │ +230 }; │ │ │ │ │ +231 │ │ │ │ │ +_2_3_3 struct _L_o_c_a_t_i_o_n_A_r_r_a_y { │ │ │ │ │ +234 │ │ │ │ │ +_2_3_5 _L_o_c_a_t_i_o_n_A_r_r_a_y() : _p_t_e_x_I_d_x(-1), _n_u_m_L_o_c_a_t_i_o_n_s(0), _s(0), _t(0) { } │ │ │ │ │ +236 │ │ │ │ │ +_2_3_7 int _p_t_e_x_I_d_x, │ │ │ │ │ +_2_3_8 _n_u_m_L_o_c_a_t_i_o_n_s; │ │ │ │ │ +239 │ │ │ │ │ +_2_4_0 REAL const * _s, │ │ │ │ │ +_2_4_1 * _t; │ │ │ │ │ +242 }; │ │ │ │ │ +243 │ │ │ │ │ +_2_4_4 typedef std::vector _L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c; │ │ │ │ │ +245 │ │ │ │ │ +_2_6_9 static _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _C_r_e_a_t_e( │ │ │ │ │ +270 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, │ │ │ │ │ +271 _L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c const & locationArrays, │ │ │ │ │ +272 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * cvStencils = 0, │ │ │ │ │ +273 _P_a_t_c_h_T_a_b_l_e const * patchTable = 0, │ │ │ │ │ +274 _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s()); │ │ │ │ │ +275 │ │ │ │ │ +276}; │ │ │ │ │ +277 │ │ │ │ │ +278 │ │ │ │ │ +279// │ │ │ │ │ +280// Public wrapper classes for the templates │ │ │ │ │ +281// │ │ │ │ │ +282class _S_t_e_n_c_i_l; │ │ │ │ │ +283class _S_t_e_n_c_i_l_T_a_b_l_e; │ │ │ │ │ 284 │ │ │ │ │ -285protected: │ │ │ │ │ -_2_8_6 _S_t_e_n_c_i_l_T_a_b_l_e() : _B_a_s_e_T_a_b_l_e() { } │ │ │ │ │ -_2_8_7 _S_t_e_n_c_i_l_T_a_b_l_e(int numControlVerts) : _B_a_s_e_T_a_b_l_e(numControlVerts) { } │ │ │ │ │ -_2_8_8 _S_t_e_n_c_i_l_T_a_b_l_e(int numControlVerts, │ │ │ │ │ -289 std::vector const& offsets, │ │ │ │ │ -290 std::vector const& sizes, │ │ │ │ │ -291 std::vector const& sources, │ │ │ │ │ -292 std::vector const& weights, │ │ │ │ │ -293 bool includeCoarseVerts, │ │ │ │ │ -294 size_t firstOffset) │ │ │ │ │ -295 : _B_a_s_e_T_a_b_l_e(numControlVerts, offsets, │ │ │ │ │ -296 sizes, sources, weights, includeCoarseVerts, firstOffset) { } │ │ │ │ │ -297}; │ │ │ │ │ -298 │ │ │ │ │ +_2_8_7class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y : public _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l { │ │ │ │ │ +288private: │ │ │ │ │ +289 typedef _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_F_a_c_t_o_r_y; │ │ │ │ │ +290 typedef _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ +291 │ │ │ │ │ +292public: │ │ │ │ │ +_2_9_3 static _S_t_e_n_c_i_l_T_a_b_l_e const * _C_r_e_a_t_e( │ │ │ │ │ +294 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, Options options = Options()) { │ │ │ │ │ +295 │ │ │ │ │ +296 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +297 _B_a_s_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e(refiner, options)); │ │ │ │ │ +298 } │ │ │ │ │ 299 │ │ │ │ │ -302template │ │ │ │ │ -_3_0_3class _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l : public _S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ -304public: │ │ │ │ │ -305 │ │ │ │ │ -_3_2_4 _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l( int* size, │ │ │ │ │ -325 _I_n_d_e_x * indices, │ │ │ │ │ -326 REAL * weights, │ │ │ │ │ -327 REAL * duWeights=0, │ │ │ │ │ -328 REAL * dvWeights=0, │ │ │ │ │ -329 REAL * duuWeights=0, │ │ │ │ │ -330 REAL * duvWeights=0, │ │ │ │ │ -331 REAL * dvvWeights=0) │ │ │ │ │ -332 : _S_t_e_n_c_i_l_R_e_a_l(size, indices, weights), │ │ │ │ │ -333 _duWeights(duWeights), │ │ │ │ │ -334 _dvWeights(dvWeights), │ │ │ │ │ -335 _duuWeights(duuWeights), │ │ │ │ │ -336 _duvWeights(duvWeights), │ │ │ │ │ -337 _dvvWeights(dvvWeights) { │ │ │ │ │ -338 } │ │ │ │ │ -339 │ │ │ │ │ -_3_4_1 REAL const * _G_e_t_D_u_W_e_i_g_h_t_s() const { │ │ │ │ │ -342 return _duWeights; │ │ │ │ │ -343 } │ │ │ │ │ -344 │ │ │ │ │ -_3_4_6 REAL const * _G_e_t_D_v_W_e_i_g_h_t_s() const { │ │ │ │ │ -347 return _dvWeights; │ │ │ │ │ -348 } │ │ │ │ │ -349 │ │ │ │ │ -_3_5_1 REAL const * _G_e_t_D_u_u_W_e_i_g_h_t_s() const { │ │ │ │ │ -352 return _duuWeights; │ │ │ │ │ -353 } │ │ │ │ │ -354 │ │ │ │ │ -_3_5_6 REAL const * _G_e_t_D_u_v_W_e_i_g_h_t_s() const { │ │ │ │ │ -357 return _duvWeights; │ │ │ │ │ -358 } │ │ │ │ │ -359 │ │ │ │ │ -_3_6_1 REAL const * _G_e_t_D_v_v_W_e_i_g_h_t_s() const { │ │ │ │ │ -362 return _dvvWeights; │ │ │ │ │ -363 } │ │ │ │ │ -364 │ │ │ │ │ -_3_6_6 void _N_e_x_t() { │ │ │ │ │ -367 int stride = *this->___s_i_z_e; │ │ │ │ │ -368 ++this->___s_i_z_e; │ │ │ │ │ -369 this->___i_n_d_i_c_e_s += stride; │ │ │ │ │ -370 this->___w_e_i_g_h_t_s += stride; │ │ │ │ │ -371 if (_duWeights) _duWeights += stride; │ │ │ │ │ -372 if (_dvWeights) _dvWeights += stride; │ │ │ │ │ -373 if (_duuWeights) _duuWeights += stride; │ │ │ │ │ -374 if (_duvWeights) _duvWeights += stride; │ │ │ │ │ -375 if (_dvvWeights) _dvvWeights += stride; │ │ │ │ │ -376 } │ │ │ │ │ -377 │ │ │ │ │ -378private: │ │ │ │ │ -379 │ │ │ │ │ -380 friend class _S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ -381 friend class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ -382 │ │ │ │ │ -383 REAL * _duWeights, // pointer to stencil u derivative limit weights │ │ │ │ │ -384 * _dvWeights, // pointer to stencil v derivative limit weights │ │ │ │ │ -385 * _duuWeights, // pointer to stencil uu derivative limit weights │ │ │ │ │ -386 * _duvWeights, // pointer to stencil uv derivative limit weights │ │ │ │ │ -387 * _dvvWeights; // pointer to stencil vv derivative limit weights │ │ │ │ │ -388}; │ │ │ │ │ -389 │ │ │ │ │ -_3_9_2class _L_i_m_i_t_S_t_e_n_c_i_l : public _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l { │ │ │ │ │ -393protected: │ │ │ │ │ -_3_9_4 typedef _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_S_t_e_n_c_i_l; │ │ │ │ │ -395 │ │ │ │ │ -396public: │ │ │ │ │ -_3_9_7 _L_i_m_i_t_S_t_e_n_c_i_l(_B_a_s_e_S_t_e_n_c_i_l const & other) : _B_a_s_e_S_t_e_n_c_i_l(other) { } │ │ │ │ │ -_3_9_8 _L_i_m_i_t_S_t_e_n_c_i_l(int* size, _I_n_d_e_x * indices, float * weights, │ │ │ │ │ -399 float * duWeights=0, float * dvWeights=0, │ │ │ │ │ -400 float * duuWeights=0, float * duvWeights=0, float * dvvWeights=0) │ │ │ │ │ -401 : _B_a_s_e_S_t_e_n_c_i_l(size, indices, weights, │ │ │ │ │ -402 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights) { } │ │ │ │ │ -403}; │ │ │ │ │ -404 │ │ │ │ │ -405 │ │ │ │ │ -408template │ │ │ │ │ -_4_0_9class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l : public _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ -410protected: │ │ │ │ │ -_4_1_1 _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l( │ │ │ │ │ -412 int numControlVerts, │ │ │ │ │ -413 std::vector const& offsets, │ │ │ │ │ -414 std::vector const& sizes, │ │ │ │ │ -415 std::vector const& sources, │ │ │ │ │ -416 std::vector const& weights, │ │ │ │ │ -417 std::vector const& duWeights, │ │ │ │ │ -418 std::vector const& dvWeights, │ │ │ │ │ -419 std::vector const& duuWeights, │ │ │ │ │ -420 std::vector const& duvWeights, │ │ │ │ │ -421 std::vector const& dvvWeights, │ │ │ │ │ -422 bool includeCoarseVerts, │ │ │ │ │ -423 size_t firstOffset); │ │ │ │ │ -424 │ │ │ │ │ -425public: │ │ │ │ │ -426 │ │ │ │ │ -_4_2_8 _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const; │ │ │ │ │ -429 │ │ │ │ │ -_4_3_1 _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const; │ │ │ │ │ -432 │ │ │ │ │ -_4_3_4 std::vector const & _G_e_t_D_u_W_e_i_g_h_t_s() const { │ │ │ │ │ -435 return _duWeights; │ │ │ │ │ -436 } │ │ │ │ │ -437 │ │ │ │ │ -_4_3_9 std::vector const & _G_e_t_D_v_W_e_i_g_h_t_s() const { │ │ │ │ │ -440 return _dvWeights; │ │ │ │ │ -441 } │ │ │ │ │ -442 │ │ │ │ │ -_4_4_4 std::vector const & _G_e_t_D_u_u_W_e_i_g_h_t_s() const { │ │ │ │ │ -445 return _duuWeights; │ │ │ │ │ -446 } │ │ │ │ │ -447 │ │ │ │ │ -_4_4_9 std::vector const & _G_e_t_D_u_v_W_e_i_g_h_t_s() const { │ │ │ │ │ -450 return _duvWeights; │ │ │ │ │ -451 } │ │ │ │ │ -452 │ │ │ │ │ -_4_5_4 std::vector const & _G_e_t_D_v_v_W_e_i_g_h_t_s() const { │ │ │ │ │ -455 return _dvvWeights; │ │ │ │ │ -456 } │ │ │ │ │ -457 │ │ │ │ │ -475 template │ │ │ │ │ -_4_7_6 void _U_p_d_a_t_e_D_e_r_i_v_s(T const & srcValues, U & uderivs, U & vderivs, │ │ │ │ │ -477 int start=-1, int end=-1) const { │ │ │ │ │ -478 │ │ │ │ │ -479 this->_u_p_d_a_t_e(srcValues, uderivs, _duWeights, start, end); │ │ │ │ │ -480 this->_u_p_d_a_t_e(srcValues, vderivs, _dvWeights, start, end); │ │ │ │ │ -481 } │ │ │ │ │ -482 │ │ │ │ │ -483 template │ │ │ │ │ -_4_8_4 void _U_p_d_a_t_e_D_e_r_i_v_s(T1 const & srcBase, int numBase, T2 const & srcRef, │ │ │ │ │ -485 U & uderivs, U & vderivs, int start=-1, int end=-1) const { │ │ │ │ │ -486 │ │ │ │ │ -487 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uderivs, _duWeights, start, end); │ │ │ │ │ -488 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end); │ │ │ │ │ -489 } │ │ │ │ │ -490 │ │ │ │ │ -491 // Pointer interface for backward compatibility │ │ │ │ │ -492 template │ │ │ │ │ -_4_9_3 void _U_p_d_a_t_e_D_e_r_i_v_s(T const *src, U *uderivs, U *vderivs, │ │ │ │ │ -494 int start=-1, int end=-1) const { │ │ │ │ │ -495 │ │ │ │ │ -496 this->_u_p_d_a_t_e(src, uderivs, _duWeights, start, end); │ │ │ │ │ -497 this->_u_p_d_a_t_e(src, vderivs, _dvWeights, start, end); │ │ │ │ │ -498 } │ │ │ │ │ -499 template │ │ │ │ │ -_5_0_0 void _U_p_d_a_t_e_D_e_r_i_v_s(T1 const *srcBase, int numBase, T2 const *srcRef, │ │ │ │ │ -501 U *uderivs, U *vderivs, int start=-1, int end=-1) const { │ │ │ │ │ -502 │ │ │ │ │ -503 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uderivs, _duWeights, start, end); │ │ │ │ │ -504 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vderivs, _dvWeights, start, end); │ │ │ │ │ -505 } │ │ │ │ │ -506 │ │ │ │ │ -527 template │ │ │ │ │ -_5_2_8 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T const & srcValues, │ │ │ │ │ -529 U & uuderivs, U & uvderivs, U & vvderivs, │ │ │ │ │ -530 int start=-1, int end=-1) const { │ │ │ │ │ -531 │ │ │ │ │ -532 this->_u_p_d_a_t_e(srcValues, uuderivs, _duuWeights, start, end); │ │ │ │ │ -533 this->_u_p_d_a_t_e(srcValues, uvderivs, _duvWeights, start, end); │ │ │ │ │ -534 this->_u_p_d_a_t_e(srcValues, vvderivs, _dvvWeights, start, end); │ │ │ │ │ -535 } │ │ │ │ │ -536 │ │ │ │ │ -537 template │ │ │ │ │ -_5_3_8 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T1 const & srcBase, int numBase, T2 const & srcRef, │ │ │ │ │ -539 U & uuderivs, U & uvderivs, U & vvderivs, int start=-1, int end=-1) const { │ │ │ │ │ -540 │ │ │ │ │ -541 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end); │ │ │ │ │ -542 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end); │ │ │ │ │ -543 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end); │ │ │ │ │ -544 } │ │ │ │ │ -545 │ │ │ │ │ -546 // Pointer interface for backward compatibility │ │ │ │ │ -547 template │ │ │ │ │ -_5_4_8 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T const *src, T *uuderivs, U *uvderivs, U *vvderivs, │ │ │ │ │ -549 int start=-1, int end=-1) const { │ │ │ │ │ -550 │ │ │ │ │ -551 this->_u_p_d_a_t_e(src, uuderivs, _duuWeights, start, end); │ │ │ │ │ -552 this->_u_p_d_a_t_e(src, uvderivs, _duvWeights, start, end); │ │ │ │ │ -553 this->_u_p_d_a_t_e(src, vvderivs, _dvvWeights, start, end); │ │ │ │ │ -554 } │ │ │ │ │ -555 template │ │ │ │ │ -_5_5_6 void _U_p_d_a_t_e_2_n_d_D_e_r_i_v_s(T1 const *srcBase, int numBase, T2 const *srcRef, │ │ │ │ │ -557 U *uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const { │ │ │ │ │ -558 │ │ │ │ │ -559 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uuderivs, _duuWeights, start, end); │ │ │ │ │ -560 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, uvderivs, _duvWeights, start, end); │ │ │ │ │ -561 this->_u_p_d_a_t_e(srcBase, numBase, srcRef, vvderivs, _dvvWeights, start, end); │ │ │ │ │ -562 } │ │ │ │ │ -563 │ │ │ │ │ -_5_6_5 void _C_l_e_a_r(); │ │ │ │ │ -566 │ │ │ │ │ -567private: │ │ │ │ │ -568 friend class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l; │ │ │ │ │ -569 │ │ │ │ │ -570 // Resize the table arrays (factory helper) │ │ │ │ │ -571 void resize(int nstencils, int nelems); │ │ │ │ │ -572 │ │ │ │ │ -573private: │ │ │ │ │ -574 std::vector _duWeights, // u derivative limit stencil weights │ │ │ │ │ -575 _dvWeights, // v derivative limit stencil weights │ │ │ │ │ -576 _duuWeights, // uu derivative limit stencil weights │ │ │ │ │ -577 _duvWeights, // uv derivative limit stencil weights │ │ │ │ │ -578 _dvvWeights; // vv derivative limit stencil weights │ │ │ │ │ -579}; │ │ │ │ │ -580 │ │ │ │ │ -_5_8_3class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e : public _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l { │ │ │ │ │ -584protected: │ │ │ │ │ -_5_8_5 typedef _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ -586 │ │ │ │ │ -587public: │ │ │ │ │ -_5_8_8 _L_i_m_i_t_S_t_e_n_c_i_l _G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(_I_n_d_e_x index) const { │ │ │ │ │ -589 return _L_i_m_i_t_S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ -590 } │ │ │ │ │ -_5_9_1 _L_i_m_i_t_S_t_e_n_c_i_l _o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ -592 return _L_i_m_i_t_S_t_e_n_c_i_l(_B_a_s_e_T_a_b_l_e_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(index)); │ │ │ │ │ -593 } │ │ │ │ │ -594 │ │ │ │ │ -595protected: │ │ │ │ │ -_5_9_6 _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e(int numControlVerts, │ │ │ │ │ -597 std::vector const& offsets, │ │ │ │ │ -598 std::vector const& sizes, │ │ │ │ │ -599 std::vector const& sources, │ │ │ │ │ -600 std::vector const& weights, │ │ │ │ │ -601 std::vector const& duWeights, │ │ │ │ │ -602 std::vector const& dvWeights, │ │ │ │ │ -603 std::vector const& duuWeights, │ │ │ │ │ -604 std::vector const& duvWeights, │ │ │ │ │ -605 std::vector const& dvvWeights, │ │ │ │ │ -606 bool includeCoarseVerts, │ │ │ │ │ -607 size_t firstOffset) │ │ │ │ │ -608 : _B_a_s_e_T_a_b_l_e(numControlVerts, │ │ │ │ │ -609 offsets, sizes, sources, weights, │ │ │ │ │ -610 duWeights, dvWeights, duuWeights, duvWeights, dvvWeights, │ │ │ │ │ -611 includeCoarseVerts, firstOffset) { } │ │ │ │ │ -612}; │ │ │ │ │ -613 │ │ │ │ │ -614 │ │ │ │ │ -615// Update values by applying cached stencil weights to new control values │ │ │ │ │ -616template │ │ │ │ │ -617template void │ │ │ │ │ -_6_1_8_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_u_p_d_a_t_e(T1 const &srcBase, int numBase, │ │ │ │ │ -619 T2 const &srcRef, U &dstValues, │ │ │ │ │ -620 std::vector const &valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const { │ │ │ │ │ -621 │ │ │ │ │ -622 int const * sizes = &_sizes.at(0); │ │ │ │ │ -623 _I_n_d_e_x const * indices = &_indices.at(0); │ │ │ │ │ -624 REAL const * weights = &valueWeights.at(0); │ │ │ │ │ -625 │ │ │ │ │ -626 if (start > 0) { │ │ │ │ │ -627 assert(start < (_I_n_d_e_x)_offsets.size()); │ │ │ │ │ -628 sizes += start; │ │ │ │ │ -629 indices += _offsets[start]; │ │ │ │ │ -630 weights += _offsets[start]; │ │ │ │ │ -631 } else { │ │ │ │ │ -632 start = 0; │ │ │ │ │ -633 } │ │ │ │ │ -634 │ │ │ │ │ -635 int nstencils = ((end < start) ? GetNumStencils() : end) - start; │ │ │ │ │ -636 │ │ │ │ │ -637 for (int i = 0; i < nstencils; ++i, ++sizes) { │ │ │ │ │ -638 dstValues[start + i].Clear(); │ │ │ │ │ -639 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) { │ │ │ │ │ -640 if (*indices < numBase) { │ │ │ │ │ -641 dstValues[start + i].AddWithWeight(srcBase[*indices], *weights); │ │ │ │ │ -642 } else { │ │ │ │ │ -643 dstValues[start + i].AddWithWeight(srcRef[*indices - numBase], *weights); │ │ │ │ │ -644 } │ │ │ │ │ -645 } │ │ │ │ │ -646 } │ │ │ │ │ -647} │ │ │ │ │ -648template │ │ │ │ │ -649template void │ │ │ │ │ -_6_5_0_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_u_p_d_a_t_e(T const &srcValues, U &dstValues, │ │ │ │ │ -651 std::vector const &valueWeights, _I_n_d_e_x start, _I_n_d_e_x end) const { │ │ │ │ │ -652 │ │ │ │ │ -653 int const * sizes = &_sizes.at(0); │ │ │ │ │ -654 _I_n_d_e_x const * indices = &_indices.at(0); │ │ │ │ │ -655 REAL const * weights = &valueWeights.at(0); │ │ │ │ │ -656 │ │ │ │ │ -657 if (start > 0) { │ │ │ │ │ -658 assert(start < (_I_n_d_e_x)_offsets.size()); │ │ │ │ │ -659 sizes += start; │ │ │ │ │ -660 indices += _offsets[start]; │ │ │ │ │ -661 weights += _offsets[start]; │ │ │ │ │ -662 } else { │ │ │ │ │ -663 start = 0; │ │ │ │ │ -664 } │ │ │ │ │ -665 │ │ │ │ │ -666 int nstencils = ((end < start) ? GetNumStencils() : end) - start; │ │ │ │ │ -667 │ │ │ │ │ -668 for (int i = 0; i < nstencils; ++i, ++sizes) { │ │ │ │ │ -669 dstValues[start + i].Clear(); │ │ │ │ │ -670 for (int j = 0; j < *sizes; ++j, ++indices, ++weights) { │ │ │ │ │ -671 dstValues[start + i].AddWithWeight(srcValues[*indices], *weights); │ │ │ │ │ -672 } │ │ │ │ │ -673 } │ │ │ │ │ -674} │ │ │ │ │ -675 │ │ │ │ │ -676template │ │ │ │ │ -677inline void │ │ │ │ │ -_6_7_8_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_g_e_n_e_r_a_t_e_O_f_f_s_e_t_s() { │ │ │ │ │ -679 _I_n_d_e_x offset=0; │ │ │ │ │ -680 int noffsets = (int)_sizes.size(); │ │ │ │ │ -681 _offsets.resize(noffsets); │ │ │ │ │ -682 for (int i=0; i<(int)_sizes.size(); ++i ) { │ │ │ │ │ -683 _offsets[i]=offset; │ │ │ │ │ -684 offset+=_sizes[i]; │ │ │ │ │ -685 } │ │ │ │ │ -686} │ │ │ │ │ -687 │ │ │ │ │ -688template │ │ │ │ │ -689inline void │ │ │ │ │ -_6_9_0_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_i_z_e(int nstencils, int nelems) { │ │ │ │ │ -691 _sizes.resize(nstencils); │ │ │ │ │ -692 _indices.resize(nelems); │ │ │ │ │ -693 _weights.resize(nelems); │ │ │ │ │ -694} │ │ │ │ │ -695 │ │ │ │ │ -696template │ │ │ │ │ -697inline void │ │ │ │ │ -_6_9_8_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_e_r_v_e(int nstencils, int nelems) { │ │ │ │ │ -699 _sizes.reserve(nstencils); │ │ │ │ │ -700 _indices.reserve(nelems); │ │ │ │ │ -701 _weights.reserve(nelems); │ │ │ │ │ -702} │ │ │ │ │ -703 │ │ │ │ │ -704template │ │ │ │ │ -705inline void │ │ │ │ │ -_7_0_6_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_s_h_r_i_n_k_T_o_F_i_t() { │ │ │ │ │ -707 std::vector(_sizes).swap(_sizes); │ │ │ │ │ -708 std::vector(_indices).swap(_indices); │ │ │ │ │ -709 std::vector(_weights).swap(_weights); │ │ │ │ │ -710} │ │ │ │ │ -711 │ │ │ │ │ -712template │ │ │ │ │ -713inline void │ │ │ │ │ -_7_1_4_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_f_i_n_a_l_i_z_e() { │ │ │ │ │ -715 shrinkToFit(); │ │ │ │ │ -716 generateOffsets(); │ │ │ │ │ -717} │ │ │ │ │ -718 │ │ │ │ │ -719// Returns a Stencil at index i in the table │ │ │ │ │ -720template │ │ │ │ │ -721inline _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> │ │ │ │ │ -_7_2_2_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_G_e_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const { │ │ │ │ │ -723 assert((! _offsets.empty()) && i<(int)_offsets.size()); │ │ │ │ │ -724 │ │ │ │ │ -725 _I_n_d_e_x ofs = _offsets[i]; │ │ │ │ │ -726 │ │ │ │ │ -727 return _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>(const_cast(&_sizes[i]), │ │ │ │ │ -728 const_cast<_I_n_d_e_x*>(&_indices[ofs]), │ │ │ │ │ -729 const_cast(&_weights[ofs])); │ │ │ │ │ -730} │ │ │ │ │ -731 │ │ │ │ │ -732template │ │ │ │ │ -733inline _S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> │ │ │ │ │ -_7_3_4_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ -735 return GetStencil(index); │ │ │ │ │ -736} │ │ │ │ │ -737 │ │ │ │ │ -738template │ │ │ │ │ -739inline void │ │ │ │ │ -740_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_i_z_e(int nstencils, int nelems) { │ │ │ │ │ -741 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_r_e_s_i_z_e(nstencils, nelems); │ │ │ │ │ -742 _duWeights.resize(nelems); │ │ │ │ │ -743 _dvWeights.resize(nelems); │ │ │ │ │ -744} │ │ │ │ │ -745 │ │ │ │ │ -746// Returns a LimitStencil at index i in the table │ │ │ │ │ -747template │ │ │ │ │ -748inline LimitStencilReal │ │ │ │ │ -_7_4_9_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l(_I_n_d_e_x i) const { │ │ │ │ │ -750 assert((! this->GetOffsets().empty()) && i<(int)this->GetOffsets().size()); │ │ │ │ │ -751 │ │ │ │ │ -752 _I_n_d_e_x ofs = this->GetOffsets()[i]; │ │ │ │ │ -753 │ │ │ │ │ -754 if (!_duWeights.empty() && !_dvWeights.empty() && │ │ │ │ │ -755 !_duuWeights.empty() && !_duvWeights.empty() && !_dvvWeights.empty()) { │ │ │ │ │ -756 return _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>( │ │ │ │ │ -757 const_cast(&this->GetSizes()[i]), │ │ │ │ │ -758 const_cast<_I_n_d_e_x *>(&this->GetControlIndices()[ofs]), │ │ │ │ │ -759 const_cast(&this->GetWeights()[ofs]), │ │ │ │ │ -760 const_cast(&GetDuWeights()[ofs]), │ │ │ │ │ -761 const_cast(&GetDvWeights()[ofs]), │ │ │ │ │ -762 const_cast(&GetDuuWeights()[ofs]), │ │ │ │ │ -763 const_cast(&GetDuvWeights()[ofs]), │ │ │ │ │ -764 const_cast(&GetDvvWeights()[ofs]) ); │ │ │ │ │ -765 } else if (!_duWeights.empty() && !_dvWeights.empty()) { │ │ │ │ │ -766 return _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>( │ │ │ │ │ -767 const_cast(&this->GetSizes()[i]), │ │ │ │ │ -768 const_cast<_I_n_d_e_x *>(&this->GetControlIndices()[ofs]), │ │ │ │ │ -769 const_cast(&this->GetWeights()[ofs]), │ │ │ │ │ -770 const_cast(&GetDuWeights()[ofs]), │ │ │ │ │ -771 const_cast(&GetDvWeights()[ofs]) ); │ │ │ │ │ -772 } else { │ │ │ │ │ -773 return _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_>( │ │ │ │ │ -774 const_cast(&this->GetSizes()[i]), │ │ │ │ │ -775 const_cast<_I_n_d_e_x *>(&this->GetControlIndices()[ofs]), │ │ │ │ │ -776 const_cast(&this->GetWeights()[ofs]) ); │ │ │ │ │ -777 } │ │ │ │ │ -778} │ │ │ │ │ -779 │ │ │ │ │ -780template │ │ │ │ │ -781inline _L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_<_R_E_A_L_> │ │ │ │ │ -_7_8_2_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_>_:_:_o_p_e_r_a_t_o_r_[_]_ (_I_n_d_e_x index) const { │ │ │ │ │ -783 return GetLimitStencil(index); │ │ │ │ │ -784} │ │ │ │ │ -785 │ │ │ │ │ -786} // end namespace Far │ │ │ │ │ -787 │ │ │ │ │ -788} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -789using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -790 │ │ │ │ │ -791} // end namespace OpenSubdiv │ │ │ │ │ -792 │ │ │ │ │ -793#endif // OPENSUBDIV3_FAR_STENCILTABLE_H │ │ │ │ │ +_3_0_0 static _S_t_e_n_c_i_l_T_a_b_l_e const * _C_r_e_a_t_e( │ │ │ │ │ +301 int numTables, _S_t_e_n_c_i_l_T_a_b_l_e const ** tables) { │ │ │ │ │ +302 │ │ │ │ │ +303 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +304 _B_a_s_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e(numTables, │ │ │ │ │ +305 reinterpret_cast<_B_a_s_e_T_a_b_l_e const **>(tables))); │ │ │ │ │ +306 } │ │ │ │ │ +307 │ │ │ │ │ +_3_0_8 static _S_t_e_n_c_i_l_T_a_b_l_e const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e( │ │ │ │ │ +309 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +310 _S_t_e_n_c_i_l_T_a_b_l_e const *baseStencilTable, │ │ │ │ │ +311 _S_t_e_n_c_i_l_T_a_b_l_e const *localPointStencilTable, │ │ │ │ │ +312 bool factorize = true) { │ │ │ │ │ +313 │ │ │ │ │ +314 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +315 _B_a_s_e_F_a_c_t_o_r_y_:_:_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e(refiner, │ │ │ │ │ +316 static_cast<_B_a_s_e_T_a_b_l_e const *>(baseStencilTable), │ │ │ │ │ +317 static_cast<_B_a_s_e_T_a_b_l_e const *>(localPointStencilTable), │ │ │ │ │ +318 factorize)); │ │ │ │ │ +319 } │ │ │ │ │ +320 │ │ │ │ │ +_3_2_1 static _S_t_e_n_c_i_l_T_a_b_l_e const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g( │ │ │ │ │ +322 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +323 _S_t_e_n_c_i_l_T_a_b_l_e const *baseStencilTable, │ │ │ │ │ +324 _S_t_e_n_c_i_l_T_a_b_l_e const *localPointStencilTable, │ │ │ │ │ +325 bool factorize = true) { │ │ │ │ │ +326 │ │ │ │ │ +327 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +328 _B_a_s_e_F_a_c_t_o_r_y_:_:_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g(refiner, │ │ │ │ │ +329 static_cast<_B_a_s_e_T_a_b_l_e const *>(baseStencilTable), │ │ │ │ │ +330 static_cast<_B_a_s_e_T_a_b_l_e const *>(localPointStencilTable), │ │ │ │ │ +331 factorize)); │ │ │ │ │ +332 } │ │ │ │ │ +333 │ │ │ │ │ +_3_3_4 static _S_t_e_n_c_i_l_T_a_b_l_e const * _A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +335 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +336 _S_t_e_n_c_i_l_T_a_b_l_e const *baseStencilTable, │ │ │ │ │ +337 _S_t_e_n_c_i_l_T_a_b_l_e const *localPointStencilTable, │ │ │ │ │ +338 int channel = 0, │ │ │ │ │ +339 bool factorize = true) { │ │ │ │ │ +340 │ │ │ │ │ +341 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +342 _B_a_s_e_F_a_c_t_o_r_y_:_:_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g(refiner, │ │ │ │ │ +343 static_cast<_B_a_s_e_T_a_b_l_e const *>(baseStencilTable), │ │ │ │ │ +344 static_cast<_B_a_s_e_T_a_b_l_e const *>(localPointStencilTable), │ │ │ │ │ +345 channel, factorize)); │ │ │ │ │ +346 } │ │ │ │ │ +347}; │ │ │ │ │ +348 │ │ │ │ │ +349class LimitStencil; │ │ │ │ │ +350class LimitStencilTable; │ │ │ │ │ +351 │ │ │ │ │ +_3_5_4class _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y : public _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ +{ │ │ │ │ │ +355private: │ │ │ │ │ +356 typedef _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_F_a_c_t_o_r_y; │ │ │ │ │ +357 typedef _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_f_l_o_a_t_> _B_a_s_e_T_a_b_l_e; │ │ │ │ │ +358 │ │ │ │ │ +359public: │ │ │ │ │ +_3_6_0 static _L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const * _C_r_e_a_t_e( │ │ │ │ │ +361 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, │ │ │ │ │ +362 _L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c const & locationArrays, │ │ │ │ │ +363 _S_t_e_n_c_i_l_T_a_b_l_e const * cvStencils = 0, │ │ │ │ │ +364 _P_a_t_c_h_T_a_b_l_e const * patchTable = 0, │ │ │ │ │ +365 Options options = Options()) { │ │ │ │ │ +366 │ │ │ │ │ +367 return static_cast<_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +368 _B_a_s_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e( │ │ │ │ │ +369 refiner, │ │ │ │ │ +370 locationArrays, │ │ │ │ │ +371 static_cast<_B_a_s_e_T_a_b_l_e const *>(cvStencils), │ │ │ │ │ +372 patchTable, │ │ │ │ │ +373 options)); │ │ │ │ │ +374 } │ │ │ │ │ +375}; │ │ │ │ │ +376 │ │ │ │ │ +377} // end namespace Far │ │ │ │ │ +378 │ │ │ │ │ +379} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +380using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +381 │ │ │ │ │ +382} // end namespace OpenSubdiv │ │ │ │ │ +383 │ │ │ │ │ +384#endif // OPENSUBDIV3_FAR_STENCILTABLE_FACTORY_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ -Vtr::Index Index │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +Container for arrays of parametric patches. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ A specialized factory for StencilTable. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_C_r_e_a_t_e │ │ │ │ │ +static StencilTableReal< REAL > const * Create(TopologyRefiner const &refiner, │ │ │ │ │ +Options options=Options()) │ │ │ │ │ +Instantiates StencilTable from TopologyRefiner that have been refined uniformly │ │ │ │ │ +or adaptively. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static StencilTableReal< REAL > const * AppendLocalPointStencilTableFaceVarying │ │ │ │ │ +(TopologyRefiner const &refiner, StencilTableReal< REAL > const │ │ │ │ │ +*baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, int │ │ │ │ │ +channel=0, bool factorize=true) │ │ │ │ │ +Utility function for stencil splicing for local point face-varying stencils. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_M_o_d_e │ │ │ │ │ +Mode │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ +@ INTERPOLATE_FACE_VARYING │ │ │ │ │ +face-varying primvar stencils │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G │ │ │ │ │ +@ INTERPOLATE_VARYING │ │ │ │ │ +varying primvar stencils │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X │ │ │ │ │ +@ INTERPOLATE_VERTEX │ │ │ │ │ +vertex primvar stencils │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g │ │ │ │ │ +static StencilTableReal< REAL > const * AppendLocalPointStencilTableVarying │ │ │ │ │ +(TopologyRefiner const &refiner, StencilTableReal< REAL > const │ │ │ │ │ +*baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool │ │ │ │ │ +factorize=true) │ │ │ │ │ +Utility function for stencil splicing for local point varying stencils. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +static StencilTableReal< REAL > const * AppendLocalPointStencilTable │ │ │ │ │ +(TopologyRefiner const &refiner, StencilTableReal< REAL > const │ │ │ │ │ +*baseStencilTable, StencilTableReal< REAL > const *localPointStencilTable, bool │ │ │ │ │ +factorize=true) │ │ │ │ │ +Utility function for stencil splicing for local point stencils. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_C_r_e_a_t_e │ │ │ │ │ +static StencilTableReal< REAL > const * Create(int numTables, StencilTableReal< │ │ │ │ │ +REAL > const **tables) │ │ │ │ │ +Instantiates StencilTable by concatenating an array of existing stencil tables. │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l │ │ │ │ │ A specialized factory for LimitStencilTable. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_M_o_d_e │ │ │ │ │ +Mode │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_I_N_T_E_R_P_O_L_A_T_E___F_A_C_E___V_A_R_Y_I_N_G │ │ │ │ │ +@ INTERPOLATE_FACE_VARYING │ │ │ │ │ +face-varying primvar stencils │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_I_N_T_E_R_P_O_L_A_T_E___V_A_R_Y_I_N_G │ │ │ │ │ +@ INTERPOLATE_VARYING │ │ │ │ │ +varying primvar stencils │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_I_N_T_E_R_P_O_L_A_T_E___V_E_R_T_E_X │ │ │ │ │ +@ INTERPOLATE_VERTEX │ │ │ │ │ +vertex primvar stencils │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y_V_e_c │ │ │ │ │ +std::vector< LocationArray > LocationArrayVec │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_C_r_e_a_t_e │ │ │ │ │ +static LimitStencilTableReal< REAL > const * Create(TopologyRefiner const │ │ │ │ │ +&refiner, LocationArrayVec const &locationArrays, StencilTableReal< REAL > │ │ │ │ │ +const *cvStencils=0, PatchTable const *patchTable=0, Options options=Options()) │ │ │ │ │ +Instantiates LimitStencilTable from a TopologyRefiner that has been refined │ │ │ │ │ +either uniformly or adapt... │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ Vertex stencil descriptor. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ -StencilReal() │ │ │ │ │ -Default constructor. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:___s_i_z_e │ │ │ │ │ -int * _size │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_0_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ -StencilReal(int *size, Index *indices, REAL *weights) │ │ │ │ │ -Constructor. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_N_e_x_t │ │ │ │ │ -void Next() │ │ │ │ │ -Advance to the next stencil in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ -StencilReal(StencilReal const &other) │ │ │ │ │ -Copy constructor. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:___i_n_d_i_c_e_s │ │ │ │ │ -Index * _indices │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_V_e_r_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -Index const * GetVertexIndices() const │ │ │ │ │ -Returns the control vertices' indices. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_S_i_z_e │ │ │ │ │ -int GetSize() const │ │ │ │ │ -Returns the size of the stencil. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:___w_e_i_g_h_t_s │ │ │ │ │ -REAL * _weights │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_S_i_z_e_P_t_r │ │ │ │ │ -int * GetSizePtr() const │ │ │ │ │ -Returns the size of the stencil as a pointer. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_W_e_i_g_h_t_s │ │ │ │ │ -REAL const * GetWeights() const │ │ │ │ │ -Returns the interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_9_3 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l │ │ │ │ │ Vertex stencil class wrapping the template for compatibility. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_S_t_e_n_c_i_l │ │ │ │ │ -Stencil(BaseStencil const &other) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_2_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_S_t_e_n_c_i_l │ │ │ │ │ -Stencil(int *size, Index *indices, float *weights) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_2_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_B_a_s_e_S_t_e_n_c_i_l │ │ │ │ │ -StencilReal< float > BaseStencil │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_1_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_:_:_S_t_e_n_c_i_l │ │ │ │ │ -Stencil() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_2_1 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ Table of subdivision stencils. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ -int GetNumControlVertices() const │ │ │ │ │ -Returns the number of control vertices indexed in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___s_i_z_e_s │ │ │ │ │ -std::vector< int > _sizes │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r │ │ │ │ │ -friend class Far::PatchTableBuilder │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_u_p_d_a_t_e │ │ │ │ │ -void update(T1 const &srcBase, int numBase, T2 const &srcRef, U &dstValues, │ │ │ │ │ -std::vector< REAL > const &valueWeights, Index start, Index end) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_1_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ -void UpdateValues(T1 const &srcBase, int numBase, T2 const &srcRef, U │ │ │ │ │ -&dstValues, Index start=-1, Index end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_1_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_C_o_n_t_r_o_l_I_n_d_i_c_e_s │ │ │ │ │ -std::vector< Index > const & GetControlIndices() const │ │ │ │ │ -Returns the indices of the control vertices. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_f_i_n_a_l_i_z_e │ │ │ │ │ -void finalize() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_1_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ -StencilReal< REAL > operator[](Index index) const │ │ │ │ │ -Returns the stencil at index i in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___n_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ -int _numControlVertices │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_u_p_d_a_t_e │ │ │ │ │ -void update(T const &srcValues, U &dstValues, std::vector< REAL > const │ │ │ │ │ -&valueWeights, Index start, Index end) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_5_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_S_i_z_e_s │ │ │ │ │ -std::vector< int > const & GetSizes() const │ │ │ │ │ -Returns the number of control vertices of each stencil in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ -int GetNumStencils() const │ │ │ │ │ -Returns the number of stencils in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_~_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -virtual ~StencilTableReal() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_O_f_f_s_e_t_s │ │ │ │ │ -std::vector< Index > const & GetOffsets() const │ │ │ │ │ -Returns the offset to a given stencil (factory may leave empty) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_S_t_e_n_c_i_l │ │ │ │ │ -StencilReal< REAL > GetStencil(Index i) const │ │ │ │ │ -Returns a Stencil at index i in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_2_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_s_h_r_i_n_k_T_o_F_i_t │ │ │ │ │ -void shrinkToFit() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_0_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_g_e_n_e_r_a_t_e_O_f_f_s_e_t_s │ │ │ │ │ -void generateOffsets() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_C_l_e_a_r │ │ │ │ │ -void Clear() │ │ │ │ │ -Clears the stencils from the table. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___o_f_f_s_e_t_s │ │ │ │ │ -std::vector< Index > _offsets │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___w_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > _weights │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_r_e_s_i_z_e │ │ │ │ │ -void resize(int nstencils, int nelems) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_9_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_W_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > const & GetWeights() const │ │ │ │ │ -Returns the stencil interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_8_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ -void UpdateValues(T1 const *srcBase, int numBase, T2 const *srcRef, U *dst, │ │ │ │ │ -Index start=-1, Index end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_2_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -StencilTableReal(int numControlVerts, std::vector< int > const &offsets, std:: │ │ │ │ │ -vector< int > const &sizes, std::vector< int > const &sources, std::vector< │ │ │ │ │ -REAL > const &weights, bool includeCoarseVerts, size_t firstOffset) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:___i_n_d_i_c_e_s │ │ │ │ │ -std::vector< Index > _indices │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -StencilTableReal() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_r_e_s_e_r_v_e │ │ │ │ │ -void reserve(int nstencils, int nelems) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_6_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ -void UpdateValues(T const *src, U *dst, Index start=-1, Index end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_1_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_V_a_l_u_e_s │ │ │ │ │ -void UpdateValues(T const &srcValues, U &dstValues, Index start=-1, Index end=- │ │ │ │ │ -1) const │ │ │ │ │ -Updates point values based on the control values. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_0_5 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ Stencil table class wrapping the template for compatibility. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTable(int numControlVerts, std::vector< int > const &offsets, std:: │ │ │ │ │ -vector< int > const &sizes, std::vector< int > const &sources, std::vector< │ │ │ │ │ -float > const &weights, bool includeCoarseVerts, size_t firstOffset) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTable(int numControlVerts) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_B_a_s_e_T_a_b_l_e │ │ │ │ │ -StencilTableReal< float > BaseTable │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_S_t_e_n_c_i_l │ │ │ │ │ -Stencil GetStencil(Index index) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ -Stencil operator[](Index index) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTable() │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ -Limit point stencil descriptor. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_0_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s │ │ │ │ │ -REAL const * GetDuvWeights() const │ │ │ │ │ -Returns the uv derivative weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_v_W_e_i_g_h_t_s │ │ │ │ │ -REAL const * GetDvWeights() const │ │ │ │ │ -Returns the v derivative weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_N_e_x_t │ │ │ │ │ -void Next() │ │ │ │ │ -Advance to the next stencil in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_6_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s │ │ │ │ │ -REAL const * GetDvvWeights() const │ │ │ │ │ -Returns the vv derivative weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l │ │ │ │ │ -LimitStencilReal(int *size, Index *indices, REAL *weights, REAL *duWeights=0, │ │ │ │ │ -REAL *dvWeights=0, REAL *duuWeights=0, REAL *duvWeights=0, REAL *dvvWeights=0) │ │ │ │ │ -Constructor. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_2_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_u_W_e_i_g_h_t_s │ │ │ │ │ -REAL const * GetDuWeights() const │ │ │ │ │ -Returns the u derivative weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_R_e_a_l_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s │ │ │ │ │ -REAL const * GetDuuWeights() const │ │ │ │ │ -Returns the uu derivative weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ -Limit point stencil class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_:_:_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ -LimitStencil(BaseStencil const &other) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_:_:_B_a_s_e_S_t_e_n_c_i_l │ │ │ │ │ -LimitStencilReal< float > BaseStencil │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_:_:_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ -LimitStencil(int *size, Index *indices, float *weights, float *duWeights=0, │ │ │ │ │ -float *dvWeights=0, float *duuWeights=0, float *duvWeights=0, float │ │ │ │ │ -*dvvWeights=0) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_3_9_8 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ Table of limit subdivision stencils. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_0_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > const & GetDuuWeights() const │ │ │ │ │ -Returns the 'uu' derivative stencil interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ -LimitStencilReal< REAL > operator[](Index index) const │ │ │ │ │ -Returns the limit stencil at index i in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > const & GetDvvWeights() const │ │ │ │ │ -Returns the 'vv' derivative stencil interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ -void UpdateDerivs(T const *src, U *uderivs, U *vderivs, int start=-1, int end=- │ │ │ │ │ -1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ -void Update2ndDerivs(T const *src, T *uuderivs, U *uvderivs, U *vvderivs, int │ │ │ │ │ -start=-1, int end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_v_W_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > const & GetDvWeights() const │ │ │ │ │ -Returns the 'v' derivative stencil interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ -void Update2ndDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U │ │ │ │ │ -*uuderivs, U *uvderivs, U *vvderivs, int start=-1, int end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ -void UpdateDerivs(T const &srcValues, U &uderivs, U &vderivs, int start=-1, int │ │ │ │ │ -end=-1) const │ │ │ │ │ -Updates derivative values based on the control values. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ -LimitStencilReal< REAL > GetLimitStencil(Index i) const │ │ │ │ │ -Returns a LimitStencil at index i in the table. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_7_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_: │ │ │ │ │ -_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -LimitStencilTableReal(int numControlVerts, std::vector< int > const &offsets, │ │ │ │ │ -std::vector< int > const &sizes, std::vector< int > const &sources, std:: │ │ │ │ │ -vector< REAL > const &weights, std::vector< REAL > const &duWeights, std:: │ │ │ │ │ -vector< REAL > const &dvWeights, std::vector< REAL > const &duuWeights, std:: │ │ │ │ │ -vector< REAL > const &duvWeights, std::vector< REAL > const &dvvWeights, bool │ │ │ │ │ -includeCoarseVerts, size_t firstOffset) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ -void Update2ndDerivs(T const &srcValues, U &uuderivs, U &uvderivs, U &vvderivs, │ │ │ │ │ -int start=-1, int end=-1) const │ │ │ │ │ -Updates 2nd derivative values based on the control values. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_2_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_u_W_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > const & GetDuWeights() const │ │ │ │ │ -Returns the 'u' derivative stencil interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_C_l_e_a_r │ │ │ │ │ -void Clear() │ │ │ │ │ -Clears the stencils from the table. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_2_n_d_D_e_r_i_v_s │ │ │ │ │ -void Update2ndDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U │ │ │ │ │ -&uuderivs, U &uvderivs, U &vvderivs, int start=-1, int end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_3_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s │ │ │ │ │ -std::vector< REAL > const & GetDuvWeights() const │ │ │ │ │ -Returns the 'uv' derivative stencil interpolation weights. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ -void UpdateDerivs(T1 const &srcBase, int numBase, T2 const &srcRef, U &uderivs, │ │ │ │ │ -U &vderivs, int start=-1, int end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_4_8_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_:_:_U_p_d_a_t_e_D_e_r_i_v_s │ │ │ │ │ -void UpdateDerivs(T1 const *srcBase, int numBase, T2 const *srcRef, U *uderivs, │ │ │ │ │ -U *vderivs, int start=-1, int end=-1) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_0_0 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_B_a_s_e_T_a_b_l_e │ │ │ │ │ -LimitStencilTableReal< float > BaseTable │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_L_i_m_i_t_S_t_e_n_c_i_l │ │ │ │ │ -LimitStencil GetLimitStencil(Index index) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -LimitStencilTable(int numControlVerts, std::vector< int > const &offsets, std:: │ │ │ │ │ -vector< int > const &sizes, std::vector< int > const &sources, std::vector< │ │ │ │ │ -float > const &weights, std::vector< float > const &duWeights, std::vector< │ │ │ │ │ -float > const &dvWeights, std::vector< float > const &duuWeights, std::vector< │ │ │ │ │ -float > const &duvWeights, std::vector< float > const &dvvWeights, bool │ │ │ │ │ -includeCoarseVerts, size_t firstOffset) │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_9_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ │ -LimitStencil operator[](Index index) const │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_f_a_c_t_o_r_i_z_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s │ │ │ │ │ +unsigned int factorizeIntermediateLevels │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_:_m_a_x_L_e_v_e_l │ │ │ │ │ +unsigned int maxLevel │ │ │ │ │ +generate stencils up to 'maxLevel' │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Options() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_I_n_t_e_r_m_e_d_i_a_t_e_L_e_v_e_l_s │ │ │ │ │ +unsigned int generateIntermediateLevels │ │ │ │ │ +vertices at all levels or highest only │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_C_o_n_t_r_o_l_V_e_r_t_s │ │ │ │ │ +unsigned int generateControlVerts │ │ │ │ │ +generate stencils for control-vertices │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_O_f_f_s_e_t_s │ │ │ │ │ +unsigned int generateOffsets │ │ │ │ │ +populate optional "_offsets" field │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_f_v_a_r_C_h_a_n_n_e_l │ │ │ │ │ +unsigned int fvarChannel │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e │ │ │ │ │ +unsigned int interpolationMode │ │ │ │ │ +interpolation mode │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_1_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_O_p_t_i_o_n_s │ │ │ │ │ +Options() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_f_v_a_r_C_h_a_n_n_e_l │ │ │ │ │ +unsigned int fvarChannel │ │ │ │ │ +face-varying channel to use │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_i_n_t_e_r_p_o_l_a_t_i_o_n_M_o_d_e │ │ │ │ │ +unsigned int interpolationMode │ │ │ │ │ +interpolation mode │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_2_n_d_D_e_r_i_v_a_t_i_v_e_s │ │ │ │ │ +unsigned int generate2ndDerivatives │ │ │ │ │ +Generate weights for 2nd derivatives. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_1_s_t_D_e_r_i_v_a_t_i_v_e_s │ │ │ │ │ +unsigned int generate1stDerivatives │ │ │ │ │ +Generate weights for 1st derivatives. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_2_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y │ │ │ │ │ +Descriptor for limit surface locations. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_t │ │ │ │ │ +REAL const * t │ │ │ │ │ +array of v coordinates │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_s │ │ │ │ │ +REAL const * s │ │ │ │ │ +array of u coordinates │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_L_o_c_a_t_i_o_n_A_r_r_a_y │ │ │ │ │ +LocationArray() │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_n_u_m_L_o_c_a_t_i_o_n_s │ │ │ │ │ +int numLocations │ │ │ │ │ +number of (u,v) coordinates in the array │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_R_e_a_l_:_: │ │ │ │ │ +_L_o_c_a_t_i_o_n_A_r_r_a_y_:_:_p_t_e_x_I_d_x │ │ │ │ │ +int ptexIdx │ │ │ │ │ +ptex face index │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ +Stencil table factory class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_V_a_r_y_i_n_g │ │ │ │ │ +static StencilTable const * AppendLocalPointStencilTableVarying(TopologyRefiner │ │ │ │ │ +const &refiner, StencilTable const *baseStencilTable, StencilTable const │ │ │ │ │ +*localPointStencilTable, bool factorize=true) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ +static StencilTable const * Create(TopologyRefiner const &refiner, Options │ │ │ │ │ +options=Options()) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static StencilTable const * AppendLocalPointStencilTableFaceVarying │ │ │ │ │ +(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, │ │ │ │ │ +StencilTable const *localPointStencilTable, int channel=0, bool factorize=true) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_: │ │ │ │ │ +_A_p_p_e_n_d_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +static StencilTable const * AppendLocalPointStencilTable(TopologyRefiner const │ │ │ │ │ +&refiner, StencilTable const *baseStencilTable, StencilTable const │ │ │ │ │ +*localPointStencilTable, bool factorize=true) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_0_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ +static StencilTable const * Create(int numTables, StencilTable const **tables) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ +Stencil table factory class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ +static LimitStencilTable const * Create(TopologyRefiner const &refiner, │ │ │ │ │ +LocationArrayVec const &locationArrays, StencilTable const *cvStencils=0, │ │ │ │ │ +PatchTable const *patchTable=0, Options options=Options()) │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_3_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ +Stores topology data for a specified set of refinement options. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _s_t_e_n_c_i_l_T_a_b_l_e_._h │ │ │ │ │ + * _s_t_e_n_c_i_l_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00722.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/ptexIndices.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/primvarRefiner.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,28 +90,43 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
ptexIndices.h File Reference
│ │ │ │ +
primvarRefiner.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/topologyRefiner.h"
│ │ │ │ +#include "../sdc/types.h"
│ │ │ │ +#include "../sdc/options.h"
│ │ │ │ +#include "../sdc/bilinearScheme.h"
│ │ │ │ +#include "../sdc/catmarkScheme.h"
│ │ │ │ +#include "../sdc/loopScheme.h"
│ │ │ │ +#include "../vtr/level.h"
│ │ │ │ +#include "../vtr/fvarLevel.h"
│ │ │ │ +#include "../vtr/refinement.h"
│ │ │ │ +#include "../vtr/fvarRefinement.h"
│ │ │ │ +#include "../vtr/stackBuffer.h"
│ │ │ │ +#include "../vtr/componentInterfaces.h"
│ │ │ │ #include "../far/types.h"
│ │ │ │ -#include <vector>
│ │ │ │ +#include "../far/error.h"
│ │ │ │ +#include "../far/topologyLevel.h"
│ │ │ │ +#include "../far/topologyRefiner.h"
│ │ │ │ +#include <cassert>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PtexIndices
 Object used to compute and query ptex face indices. More...
class  PrimvarRefinerReal< REAL >
 Applies refinement operations to generic primvar data. More...
 
class  PrimvarRefiner
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -120,13 +135,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,26 +1,41 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -ptexIndices.h File Reference │ │ │ │ │ +primvarRefiner.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_t_y_p_e_s_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_b_i_l_i_n_e_a_r_S_c_h_e_m_e_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_c_a_t_m_a_r_k_S_c_h_e_m_e_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_l_o_o_p_S_c_h_e_m_e_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_l_e_v_e_l_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_f_v_a_r_L_e_v_e_l_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_r_e_f_i_n_e_m_e_n_t_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_f_v_a_r_R_e_f_i_n_e_m_e_n_t_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_s_t_a_c_k_B_u_f_f_e_r_._h" │ │ │ │ │ +#include "_._._/_v_t_r_/_c_o_m_p_o_n_e_n_t_I_n_t_e_r_f_a_c_e_s_._h" │ │ │ │ │ #include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_e_r_r_o_r_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_L_e_v_e_l_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -  Object used to compute and query ptex face indices. _M_o_r_e_._._. │ │ │ │ │ +class   _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ +  Applies refinement operations to generic primvar data. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _P_r_i_m_v_a_r_R_e_f_i_n_e_r │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_t_e_x_I_n_d_i_c_e_s_._h │ │ │ │ │ + * _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00722.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,4 @@ │ │ │ │ │ var a00722 = [ │ │ │ │ │ - ["PtexIndices", "a01041.html", "a01041"] │ │ │ │ │ + ["PrimvarRefinerReal< REAL >", "a01029.html", "a01029"], │ │ │ │ │ + ["PrimvarRefiner", "a01037.html", "a01037"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00722_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/ptexIndices.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/primvarRefiner.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
ptexIndices.h
│ │ │ │ +
primvarRefiner.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2015 Pixar
│ │ │ │ +
2// Copyright 2015 DreamWorks Animation LLC.
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,81 +118,1233 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_FAR_PTEX_INDICES_H
│ │ │ │ -
25#define OPENSUBDIV3_FAR_PTEX_INDICES_H
│ │ │ │ +
24#ifndef OPENSUBDIV3_FAR_PRIMVAR_REFINER_H
│ │ │ │ +
25#define OPENSUBDIV3_FAR_PRIMVAR_REFINER_H
│ │ │ │
26
│ │ │ │
27#include "../version.h"
│ │ │ │
28
│ │ │ │ -
29#include "../far/topologyRefiner.h"
│ │ │ │ -
30#include "../far/types.h"
│ │ │ │ -
31
│ │ │ │ -
32#include <vector>
│ │ │ │ -
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Far {
│ │ │ │ -
38
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
47
│ │ │ │ -
48public:
│ │ │ │ +
29#include "../sdc/types.h"
│ │ │ │ +
30#include "../sdc/options.h"
│ │ │ │ +
31#include "../sdc/bilinearScheme.h"
│ │ │ │ +
32#include "../sdc/catmarkScheme.h"
│ │ │ │ +
33#include "../sdc/loopScheme.h"
│ │ │ │ +
34#include "../vtr/level.h"
│ │ │ │ +
35#include "../vtr/fvarLevel.h"
│ │ │ │ +
36#include "../vtr/refinement.h"
│ │ │ │ +
37#include "../vtr/fvarRefinement.h"
│ │ │ │ +
38#include "../vtr/stackBuffer.h"
│ │ │ │ +
39#include "../vtr/componentInterfaces.h"
│ │ │ │ +
40#include "../far/types.h"
│ │ │ │ +
41#include "../far/error.h"
│ │ │ │ +
42#include "../far/topologyLevel.h"
│ │ │ │ +
43#include "../far/topologyRefiner.h"
│ │ │ │ +
44
│ │ │ │ +
45#include <cassert>
│ │ │ │ +
46
│ │ │ │ +
47namespace OpenSubdiv {
│ │ │ │ +
48namespace OPENSUBDIV_VERSION {
│ │ │ │
49
│ │ │ │ - │ │ │ │ -
52
│ │ │ │ - │ │ │ │ -
55
│ │ │ │ +
50namespace Far {
│ │ │ │ +
51
│ │ │ │ +
55template <typename REAL>
│ │ │ │ +
│ │ │ │ + │ │ │ │
57
│ │ │ │ -
60
│ │ │ │ -
63 int GetNumFaces() const;
│ │ │ │ -
64
│ │ │ │ -
67 int GetFaceId(Index f) const;
│ │ │ │ -
68
│ │ │ │ - │ │ │ │ -
84 TopologyRefiner const &refiner,
│ │ │ │ -
85 int face, int quadrant,
│ │ │ │ -
86 int adjFaces[4], int adjEdges[4]) const;
│ │ │ │ -
87
│ │ │ │ -
89
│ │ │ │ -
90private:
│ │ │ │ -
91
│ │ │ │ -
92 void initializePtexIndices(TopologyRefiner const &refiner);
│ │ │ │ -
93
│ │ │ │ -
94private:
│ │ │ │ -
95
│ │ │ │ -
96 std::vector<Index> _ptexIndices;
│ │ │ │ -
97};
│ │ │ │ -
│ │ │ │ -
98
│ │ │ │ -
99
│ │ │ │ -
100} // end namespace Far
│ │ │ │ -
101
│ │ │ │ -
102} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
103using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
104} // end namespace OpenSubdiv
│ │ │ │ -
105
│ │ │ │ -
106#endif /* OPENSUBDIV3_FAR_PTEX_INDICES_H */
│ │ │ │ +
58public:
│ │ │ │ +
59 PrimvarRefinerReal(TopologyRefiner const & refiner) : _refiner(refiner) { }
│ │ │ │ + │ │ │ │ +
61
│ │ │ │ +
62 TopologyRefiner const & GetTopologyRefiner() const { return _refiner; }
│ │ │ │ +
63
│ │ │ │ +
65
│ │ │ │ +
100
│ │ │ │ +
│ │ │ │ +
113 template <class T, class U> void Interpolate(int level, T const & src, U & dst) const;
│ │ │ │ +
114
│ │ │ │ +
│ │ │ │ +
130 template <class T, class U> void InterpolateVarying(int level, T const & src, U & dst) const;
│ │ │ │ +
131
│ │ │ │ +
│ │ │ │ +
148 template <class T, class U> void InterpolateFaceUniform(int level, T const & src, U & dst) const;
│ │ │ │ +
149
│ │ │ │ +
│ │ │ │ +
161 template <class T, class U> void InterpolateFaceVarying(int level, T const & src, U & dst, int channel = 0) const;
│ │ │ │ +
162
│ │ │ │ +
163
│ │ │ │ +
│ │ │ │ +
175 template <class T, class U> void Limit(T const & src, U & dstPos) const;
│ │ │ │ +
176
│ │ │ │ +
177 template <class T, class U, class U1, class U2>
│ │ │ │ +
│ │ │ │ +
178 void Limit(T const & src, U & dstPos, U1 & dstTan1, U2 & dstTan2) const;
│ │ │ │ +
179
│ │ │ │ +
│ │ │ │ +
180 template <class T, class U> void LimitFaceVarying(T const & src, U & dst, int channel = 0) const;
│ │ │ │ +
181
│ │ │ │ +
183
│ │ │ │ +
184private:
│ │ │ │ +
185 typedef REAL Weight;
│ │ │ │ +
186
│ │ │ │ +
187 // Non-copyable:
│ │ │ │ +
188 PrimvarRefinerReal(PrimvarRefinerReal const & src) : _refiner(src._refiner) { }
│ │ │ │ +
189 PrimvarRefinerReal & operator=(PrimvarRefinerReal const &) { return *this; }
│ │ │ │ +
190
│ │ │ │ +
191 template <Sdc::SchemeType SCHEME, class T, class U> void interpFromFaces(int, T const &, U &) const;
│ │ │ │ +
192 template <Sdc::SchemeType SCHEME, class T, class U> void interpFromEdges(int, T const &, U &) const;
│ │ │ │ +
193 template <Sdc::SchemeType SCHEME, class T, class U> void interpFromVerts(int, T const &, U &) const;
│ │ │ │ +
194
│ │ │ │ +
195 template <Sdc::SchemeType SCHEME, class T, class U> void interpFVarFromFaces(int, T const &, U &, int) const;
│ │ │ │ +
196 template <Sdc::SchemeType SCHEME, class T, class U> void interpFVarFromEdges(int, T const &, U &, int) const;
│ │ │ │ +
197 template <Sdc::SchemeType SCHEME, class T, class U> void interpFVarFromVerts(int, T const &, U &, int) const;
│ │ │ │ +
198
│ │ │ │ +
199 template <Sdc::SchemeType SCHEME, class T, class U, class U1, class U2>
│ │ │ │ +
200 void limit(T const & src, U & pos, U1 * tan1, U2 * tan2) const;
│ │ │ │ +
201
│ │ │ │ +
202 template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
203 void limitFVar(T const & src, U & dst, int channel) const;
│ │ │ │ +
204
│ │ │ │ +
205private:
│ │ │ │ +
206 TopologyRefiner const & _refiner;
│ │ │ │ +
207
│ │ │ │ +
208private:
│ │ │ │ +
209 //
│ │ │ │ +
210 // Local class to fulfill interface for <typename MASK> in the Scheme mask queries:
│ │ │ │ +
211 //
│ │ │ │ +
212 class Mask {
│ │ │ │ +
213 public:
│ │ │ │ +
214 typedef REAL Weight; // Also part of the expected interface
│ │ │ │ +
215
│ │ │ │ +
216 public:
│ │ │ │ +
217 Mask(Weight* v, Weight* e, Weight* f) :
│ │ │ │ +
218 _vertWeights(v), _edgeWeights(e), _faceWeights(f),
│ │ │ │ +
219 _vertCount(0), _edgeCount(0), _faceCount(0),
│ │ │ │ +
220 _faceWeightsForFaceCenters(false)
│ │ │ │ +
221 { }
│ │ │ │ +
222
│ │ │ │ +
223 ~Mask() { }
│ │ │ │ +
224
│ │ │ │ +
225 public: // Generic interface expected of <typename MASK>:
│ │ │ │ +
226 int GetNumVertexWeights() const { return _vertCount; }
│ │ │ │ +
227 int GetNumEdgeWeights() const { return _edgeCount; }
│ │ │ │ +
228 int GetNumFaceWeights() const { return _faceCount; }
│ │ │ │ +
229
│ │ │ │ +
230 void SetNumVertexWeights(int count) { _vertCount = count; }
│ │ │ │ +
231 void SetNumEdgeWeights( int count) { _edgeCount = count; }
│ │ │ │ +
232 void SetNumFaceWeights( int count) { _faceCount = count; }
│ │ │ │ +
233
│ │ │ │ +
234 Weight const& VertexWeight(int index) const { return _vertWeights[index]; }
│ │ │ │ +
235 Weight const& EdgeWeight( int index) const { return _edgeWeights[index]; }
│ │ │ │ +
236 Weight const& FaceWeight( int index) const { return _faceWeights[index]; }
│ │ │ │ +
237
│ │ │ │ +
238 Weight& VertexWeight(int index) { return _vertWeights[index]; }
│ │ │ │ +
239 Weight& EdgeWeight( int index) { return _edgeWeights[index]; }
│ │ │ │ +
240 Weight& FaceWeight( int index) { return _faceWeights[index]; }
│ │ │ │ +
241
│ │ │ │ +
242 bool AreFaceWeightsForFaceCenters() const { return _faceWeightsForFaceCenters; }
│ │ │ │ +
243 void SetFaceWeightsForFaceCenters(bool on) { _faceWeightsForFaceCenters = on; }
│ │ │ │ +
244
│ │ │ │ +
245 private:
│ │ │ │ +
246 Weight* _vertWeights;
│ │ │ │ +
247 Weight* _edgeWeights;
│ │ │ │ +
248 Weight* _faceWeights;
│ │ │ │ +
249
│ │ │ │ +
250 int _vertCount;
│ │ │ │ +
251 int _edgeCount;
│ │ │ │ +
252 int _faceCount;
│ │ │ │ +
253
│ │ │ │ +
254 bool _faceWeightsForFaceCenters;
│ │ │ │ +
255 };
│ │ │ │ +
256};
│ │ │ │ +
257
│ │ │ │ +
258
│ │ │ │ +
259//
│ │ │ │ +
260// Public entry points to the methods. Queries of the scheme type and its
│ │ │ │ +
261// use as a template parameter in subsequent implementation will be factored
│ │ │ │ +
262// out of a later release:
│ │ │ │ +
263//
│ │ │ │ +
264template <typename REAL>
│ │ │ │ +
265template <class T, class U>
│ │ │ │ +
266inline void
│ │ │ │ +
│ │ │ │ +
267PrimvarRefinerReal<REAL>::Interpolate(int level, T const & src, U & dst) const {
│ │ │ │ +
268
│ │ │ │ +
269 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ +
270
│ │ │ │ +
271 switch (_refiner._subdivType) {
│ │ │ │ + │ │ │ │ +
273 interpFromFaces<Sdc::SCHEME_CATMARK>(level, src, dst);
│ │ │ │ +
274 interpFromEdges<Sdc::SCHEME_CATMARK>(level, src, dst);
│ │ │ │ +
275 interpFromVerts<Sdc::SCHEME_CATMARK>(level, src, dst);
│ │ │ │ +
276 break;
│ │ │ │ +
277 case Sdc::SCHEME_LOOP:
│ │ │ │ +
278 interpFromFaces<Sdc::SCHEME_LOOP>(level, src, dst);
│ │ │ │ +
279 interpFromEdges<Sdc::SCHEME_LOOP>(level, src, dst);
│ │ │ │ +
280 interpFromVerts<Sdc::SCHEME_LOOP>(level, src, dst);
│ │ │ │ +
281 break;
│ │ │ │ + │ │ │ │ +
283 interpFromFaces<Sdc::SCHEME_BILINEAR>(level, src, dst);
│ │ │ │ +
284 interpFromEdges<Sdc::SCHEME_BILINEAR>(level, src, dst);
│ │ │ │ +
285 interpFromVerts<Sdc::SCHEME_BILINEAR>(level, src, dst);
│ │ │ │ +
286 break;
│ │ │ │ +
287 }
│ │ │ │ +
288}
│ │ │ │ +
│ │ │ │ +
289
│ │ │ │ +
290template <typename REAL>
│ │ │ │ +
291template <class T, class U>
│ │ │ │ +
292inline void
│ │ │ │ +
│ │ │ │ +
293PrimvarRefinerReal<REAL>::InterpolateFaceVarying(int level, T const & src, U & dst, int channel) const {
│ │ │ │ +
294
│ │ │ │ +
295 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ +
296
│ │ │ │ +
297 switch (_refiner._subdivType) {
│ │ │ │ + │ │ │ │ +
299 interpFVarFromFaces<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
│ │ │ │ +
300 interpFVarFromEdges<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
│ │ │ │ +
301 interpFVarFromVerts<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
│ │ │ │ +
302 break;
│ │ │ │ +
303 case Sdc::SCHEME_LOOP:
│ │ │ │ +
304 interpFVarFromFaces<Sdc::SCHEME_LOOP>(level, src, dst, channel);
│ │ │ │ +
305 interpFVarFromEdges<Sdc::SCHEME_LOOP>(level, src, dst, channel);
│ │ │ │ +
306 interpFVarFromVerts<Sdc::SCHEME_LOOP>(level, src, dst, channel);
│ │ │ │ +
307 break;
│ │ │ │ + │ │ │ │ +
309 interpFVarFromFaces<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
│ │ │ │ +
310 interpFVarFromEdges<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
│ │ │ │ +
311 interpFVarFromVerts<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
│ │ │ │ +
312 break;
│ │ │ │ +
313 }
│ │ │ │ +
314}
│ │ │ │ +
│ │ │ │ +
315
│ │ │ │ +
316template <typename REAL>
│ │ │ │ +
317template <class T, class U>
│ │ │ │ +
318inline void
│ │ │ │ +
│ │ │ │ +
319PrimvarRefinerReal<REAL>::Limit(T const & src, U & dst) const {
│ │ │ │ +
320
│ │ │ │ +
321 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == 0) {
│ │ │ │ + │ │ │ │ +
323 "Failure in PrimvarRefiner::Limit() -- "
│ │ │ │ +
324 "last level of refinement does not include full topology.");
│ │ │ │ +
325 return;
│ │ │ │ +
326 }
│ │ │ │ +
327
│ │ │ │ +
328 switch (_refiner._subdivType) {
│ │ │ │ + │ │ │ │ +
330 limit<Sdc::SCHEME_CATMARK>(src, dst, (U*)0, (U*)0);
│ │ │ │ +
331 break;
│ │ │ │ +
332 case Sdc::SCHEME_LOOP:
│ │ │ │ +
333 limit<Sdc::SCHEME_LOOP>(src, dst, (U*)0, (U*)0);
│ │ │ │ +
334 break;
│ │ │ │ + │ │ │ │ +
336 limit<Sdc::SCHEME_BILINEAR>(src, dst, (U*)0, (U*)0);
│ │ │ │ +
337 break;
│ │ │ │ +
338 }
│ │ │ │ +
339}
│ │ │ │ +
│ │ │ │ +
340
│ │ │ │ +
341template <typename REAL>
│ │ │ │ +
342template <class T, class U, class U1, class U2>
│ │ │ │ +
343inline void
│ │ │ │ +
│ │ │ │ +
344PrimvarRefinerReal<REAL>::Limit(T const & src, U & dstPos, U1 & dstTan1, U2 & dstTan2) const {
│ │ │ │ +
345
│ │ │ │ +
346 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == 0) {
│ │ │ │ + │ │ │ │ +
348 "Failure in PrimvarRefiner::Limit() -- "
│ │ │ │ +
349 "last level of refinement does not include full topology.");
│ │ │ │ +
350 return;
│ │ │ │ +
351 }
│ │ │ │ +
352
│ │ │ │ +
353 switch (_refiner._subdivType) {
│ │ │ │ + │ │ │ │ +
355 limit<Sdc::SCHEME_CATMARK>(src, dstPos, &dstTan1, &dstTan2);
│ │ │ │ +
356 break;
│ │ │ │ +
357 case Sdc::SCHEME_LOOP:
│ │ │ │ +
358 limit<Sdc::SCHEME_LOOP>(src, dstPos, &dstTan1, &dstTan2);
│ │ │ │ +
359 break;
│ │ │ │ + │ │ │ │ +
361 limit<Sdc::SCHEME_BILINEAR>(src, dstPos, &dstTan1, &dstTan2);
│ │ │ │ +
362 break;
│ │ │ │ +
363 }
│ │ │ │ +
364}
│ │ │ │ +
│ │ │ │ +
365
│ │ │ │ +
366template <typename REAL>
│ │ │ │ +
367template <class T, class U>
│ │ │ │ +
368inline void
│ │ │ │ +
│ │ │ │ +
369PrimvarRefinerReal<REAL>::LimitFaceVarying(T const & src, U & dst, int channel) const {
│ │ │ │ +
370
│ │ │ │ +
371 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == 0) {
│ │ │ │ + │ │ │ │ +
373 "Failure in PrimvarRefiner::LimitFaceVarying() -- "
│ │ │ │ +
374 "last level of refinement does not include full topology.");
│ │ │ │ +
375 return;
│ │ │ │ +
376 }
│ │ │ │ +
377
│ │ │ │ +
378 switch (_refiner._subdivType) {
│ │ │ │ + │ │ │ │ +
380 limitFVar<Sdc::SCHEME_CATMARK>(src, dst, channel);
│ │ │ │ +
381 break;
│ │ │ │ +
382 case Sdc::SCHEME_LOOP:
│ │ │ │ +
383 limitFVar<Sdc::SCHEME_LOOP>(src, dst, channel);
│ │ │ │ +
384 break;
│ │ │ │ + │ │ │ │ +
386 limitFVar<Sdc::SCHEME_BILINEAR>(src, dst, channel);
│ │ │ │ +
387 break;
│ │ │ │ +
388 }
│ │ │ │ +
389}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
390
│ │ │ │ +
391template <typename REAL>
│ │ │ │ +
392template <class T, class U>
│ │ │ │ +
393inline void
│ │ │ │ +
│ │ │ │ +
394PrimvarRefinerReal<REAL>::InterpolateFaceUniform(int level, T const & src, U & dst) const {
│ │ │ │ +
395
│ │ │ │ +
396 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ +
397
│ │ │ │ +
398 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
399 Vtr::internal::Level const & child = refinement.child();
│ │ │ │ +
400
│ │ │ │ +
401 for (int cFace = 0; cFace < child.getNumFaces(); ++cFace) {
│ │ │ │ +
402
│ │ │ │ +
403 Vtr::Index pFace = refinement.getChildFaceParentFace(cFace);
│ │ │ │ +
404
│ │ │ │ +
405 dst[cFace] = src[pFace];
│ │ │ │ +
406 }
│ │ │ │ +
407}
│ │ │ │ +
│ │ │ │ +
408
│ │ │ │ +
409template <typename REAL>
│ │ │ │ +
410template <class T, class U>
│ │ │ │ +
411inline void
│ │ │ │ +
│ │ │ │ +
412PrimvarRefinerReal<REAL>::InterpolateVarying(int level, T const & src, U & dst) const {
│ │ │ │ +
413
│ │ │ │ +
414 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ +
415
│ │ │ │ +
416 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
417 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ +
418
│ │ │ │ +
419 //
│ │ │ │ +
420 // Group values to interpolate based on origin -- note that there may
│ │ │ │ +
421 // be none originating from faces:
│ │ │ │ +
422 //
│ │ │ │ +
423 if (refinement.getNumChildVerticesFromFaces() > 0) {
│ │ │ │ +
424
│ │ │ │ +
425 for (int face = 0; face < parent.getNumFaces(); ++face) {
│ │ │ │ +
426
│ │ │ │ +
427 Vtr::Index cVert = refinement.getFaceChildVertex(face);
│ │ │ │ +
428 if (Vtr::IndexIsValid(cVert)) {
│ │ │ │ +
429
│ │ │ │ +
430 // Apply the weights to the parent face's vertices:
│ │ │ │ +
431 ConstIndexArray fVerts = parent.getFaceVertices(face);
│ │ │ │ +
432
│ │ │ │ +
433 Weight fVaryingWeight = 1.0f / (Weight) fVerts.size();
│ │ │ │ +
434
│ │ │ │ +
435 dst[cVert].Clear();
│ │ │ │ +
436 for (int i = 0; i < fVerts.size(); ++i) {
│ │ │ │ +
437 dst[cVert].AddWithWeight(src[fVerts[i]], fVaryingWeight);
│ │ │ │ +
438 }
│ │ │ │ +
439 }
│ │ │ │ +
440 }
│ │ │ │ +
441 }
│ │ │ │ +
442 for (int edge = 0; edge < parent.getNumEdges(); ++edge) {
│ │ │ │ +
443
│ │ │ │ +
444 Vtr::Index cVert = refinement.getEdgeChildVertex(edge);
│ │ │ │ +
445 if (Vtr::IndexIsValid(cVert)) {
│ │ │ │ +
446
│ │ │ │ +
447 // Apply the weights to the parent edges's vertices
│ │ │ │ +
448 ConstIndexArray eVerts = parent.getEdgeVertices(edge);
│ │ │ │ +
449
│ │ │ │ +
450 dst[cVert].Clear();
│ │ │ │ +
451 dst[cVert].AddWithWeight(src[eVerts[0]], 0.5f);
│ │ │ │ +
452 dst[cVert].AddWithWeight(src[eVerts[1]], 0.5f);
│ │ │ │ +
453 }
│ │ │ │ +
454 }
│ │ │ │ +
455 for (int vert = 0; vert < parent.getNumVertices(); ++vert) {
│ │ │ │ +
456
│ │ │ │ +
457 Vtr::Index cVert = refinement.getVertexChildVertex(vert);
│ │ │ │ +
458 if (Vtr::IndexIsValid(cVert)) {
│ │ │ │ +
459
│ │ │ │ +
460 // Essentially copy the parent vertex:
│ │ │ │ +
461 dst[cVert].Clear();
│ │ │ │ +
462 dst[cVert].AddWithWeight(src[vert], 1.0f);
│ │ │ │ +
463 }
│ │ │ │ +
464 }
│ │ │ │ +
465}
│ │ │ │ +
│ │ │ │ +
466
│ │ │ │ +
467
│ │ │ │ +
468//
│ │ │ │ +
469// Internal implementation methods -- grouping vertices to be interpolated
│ │ │ │ +
470// based on the type of parent component from which they originated:
│ │ │ │ +
471//
│ │ │ │ +
472template <typename REAL>
│ │ │ │ +
473template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
474inline void
│ │ │ │ +
475PrimvarRefinerReal<REAL>::interpFromFaces(int level, T const & src, U & dst) const {
│ │ │ │ +
476
│ │ │ │ +
477 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
478 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ +
479
│ │ │ │ +
480 if (refinement.getNumChildVerticesFromFaces() == 0) return;
│ │ │ │ +
481
│ │ │ │ +
482 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
483
│ │ │ │ +
484 Vtr::internal::StackBuffer<Weight,16> fVertWeights(parent.getMaxValence());
│ │ │ │ +
485
│ │ │ │ +
486 for (int face = 0; face < parent.getNumFaces(); ++face) {
│ │ │ │ +
487
│ │ │ │ +
488 Vtr::Index cVert = refinement.getFaceChildVertex(face);
│ │ │ │ +
489 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ +
490 continue;
│ │ │ │ +
491
│ │ │ │ +
492 // Declare and compute mask weights for this vertex relative to its parent face:
│ │ │ │ +
493 ConstIndexArray fVerts = parent.getFaceVertices(face);
│ │ │ │ +
494
│ │ │ │ +
495 Mask fMask(fVertWeights, 0, 0);
│ │ │ │ +
496 Vtr::internal::FaceInterface fHood(fVerts.size());
│ │ │ │ +
497
│ │ │ │ +
498 scheme.ComputeFaceVertexMask(fHood, fMask);
│ │ │ │ +
499
│ │ │ │ +
500 // Apply the weights to the parent face's vertices:
│ │ │ │ +
501 dst[cVert].Clear();
│ │ │ │ +
502
│ │ │ │ +
503 for (int i = 0; i < fVerts.size(); ++i) {
│ │ │ │ +
504
│ │ │ │ +
505 dst[cVert].AddWithWeight(src[fVerts[i]], fVertWeights[i]);
│ │ │ │ +
506 }
│ │ │ │ +
507 }
│ │ │ │ +
508}
│ │ │ │ +
509
│ │ │ │ +
510template <typename REAL>
│ │ │ │ +
511template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
512inline void
│ │ │ │ +
513PrimvarRefinerReal<REAL>::interpFromEdges(int level, T const & src, U & dst) const {
│ │ │ │ +
514
│ │ │ │ +
515 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
516 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ +
517 Vtr::internal::Level const & child = refinement.child();
│ │ │ │ +
518
│ │ │ │ +
519 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
520
│ │ │ │ +
521 Vtr::internal::EdgeInterface eHood(parent);
│ │ │ │ +
522
│ │ │ │ +
523 Weight eVertWeights[2];
│ │ │ │ +
524 Vtr::internal::StackBuffer<Weight,8> eFaceWeights(parent.getMaxEdgeFaces());
│ │ │ │ +
525
│ │ │ │ +
526 for (int edge = 0; edge < parent.getNumEdges(); ++edge) {
│ │ │ │ +
527
│ │ │ │ +
528 Vtr::Index cVert = refinement.getEdgeChildVertex(edge);
│ │ │ │ +
529 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ +
530 continue;
│ │ │ │ +
531
│ │ │ │ +
532 // Declare and compute mask weights for this vertex relative to its parent edge:
│ │ │ │ +
533 ConstIndexArray eVerts = parent.getEdgeVertices(edge),
│ │ │ │ +
534 eFaces = parent.getEdgeFaces(edge);
│ │ │ │ +
535
│ │ │ │ +
536 Mask eMask(eVertWeights, 0, eFaceWeights);
│ │ │ │ +
537
│ │ │ │ +
538 eHood.SetIndex(edge);
│ │ │ │ +
539
│ │ │ │ +
540 Sdc::Crease::Rule pRule = (parent.getEdgeSharpness(edge) > 0.0f) ? Sdc::Crease::RULE_CREASE : Sdc::Crease::RULE_SMOOTH;
│ │ │ │ +
541 Sdc::Crease::Rule cRule = child.getVertexRule(cVert);
│ │ │ │ +
542
│ │ │ │ +
543 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule);
│ │ │ │ +
544
│ │ │ │ +
545 // Apply the weights to the parent edges's vertices and (if applicable) to
│ │ │ │ +
546 // the child vertices of its incident faces:
│ │ │ │ +
547 dst[cVert].Clear();
│ │ │ │ +
548 dst[cVert].AddWithWeight(src[eVerts[0]], eVertWeights[0]);
│ │ │ │ +
549 dst[cVert].AddWithWeight(src[eVerts[1]], eVertWeights[1]);
│ │ │ │ +
550
│ │ │ │ +
551 if (eMask.GetNumFaceWeights() > 0) {
│ │ │ │ +
552
│ │ │ │ +
553 for (int i = 0; i < eFaces.size(); ++i) {
│ │ │ │ +
554
│ │ │ │ +
555 if (eMask.AreFaceWeightsForFaceCenters()) {
│ │ │ │ +
556 assert(refinement.getNumChildVerticesFromFaces() > 0);
│ │ │ │ +
557 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(eFaces[i]);
│ │ │ │ +
558
│ │ │ │ +
559 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ +
560 dst[cVert].AddWithWeight(dst[cVertOfFace], eFaceWeights[i]);
│ │ │ │ +
561 } else {
│ │ │ │ +
562 Vtr::Index pFace = eFaces[i];
│ │ │ │ +
563 ConstIndexArray pFaceEdges = parent.getFaceEdges(pFace),
│ │ │ │ +
564 pFaceVerts = parent.getFaceVertices(pFace);
│ │ │ │ +
565
│ │ │ │ +
566 int eInFace = 0;
│ │ │ │ +
567 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ;
│ │ │ │ +
568
│ │ │ │ +
569 int vInFace = eInFace + 2;
│ │ │ │ +
570 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts.size();
│ │ │ │ +
571
│ │ │ │ +
572 Vtr::Index pVertNext = pFaceVerts[vInFace];
│ │ │ │ +
573 dst[cVert].AddWithWeight(src[pVertNext], eFaceWeights[i]);
│ │ │ │ +
574 }
│ │ │ │ +
575 }
│ │ │ │ +
576 }
│ │ │ │ +
577 }
│ │ │ │ +
578}
│ │ │ │ +
579
│ │ │ │ +
580template <typename REAL>
│ │ │ │ +
581template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
582inline void
│ │ │ │ +
583PrimvarRefinerReal<REAL>::interpFromVerts(int level, T const & src, U & dst) const {
│ │ │ │ +
584
│ │ │ │ +
585 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
586 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ +
587 Vtr::internal::Level const & child = refinement.child();
│ │ │ │ +
588
│ │ │ │ +
589 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
590
│ │ │ │ +
591 Vtr::internal::VertexInterface vHood(parent, child);
│ │ │ │ +
592
│ │ │ │ +
593 Vtr::internal::StackBuffer<Weight,32> weightBuffer(2*parent.getMaxValence());
│ │ │ │ +
594
│ │ │ │ +
595 for (int vert = 0; vert < parent.getNumVertices(); ++vert) {
│ │ │ │ +
596
│ │ │ │ +
597 Vtr::Index cVert = refinement.getVertexChildVertex(vert);
│ │ │ │ +
598 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ +
599 continue;
│ │ │ │ +
600
│ │ │ │ +
601 // Declare and compute mask weights for this vertex relative to its parent edge:
│ │ │ │ +
602 ConstIndexArray vEdges = parent.getVertexEdges(vert),
│ │ │ │ +
603 vFaces = parent.getVertexFaces(vert);
│ │ │ │ +
604
│ │ │ │ +
605 Weight vVertWeight,
│ │ │ │ +
606 * vEdgeWeights = weightBuffer,
│ │ │ │ +
607 * vFaceWeights = vEdgeWeights + vEdges.size();
│ │ │ │ +
608
│ │ │ │ +
609 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights);
│ │ │ │ +
610
│ │ │ │ +
611 vHood.SetIndex(vert, cVert);
│ │ │ │ +
612
│ │ │ │ +
613 Sdc::Crease::Rule pRule = parent.getVertexRule(vert);
│ │ │ │ +
614 Sdc::Crease::Rule cRule = child.getVertexRule(cVert);
│ │ │ │ +
615
│ │ │ │ +
616 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule);
│ │ │ │ +
617
│ │ │ │ +
618 // Apply the weights to the parent vertex, the vertices opposite its incident
│ │ │ │ +
619 // edges, and the child vertices of its incident faces:
│ │ │ │ +
620 //
│ │ │ │ +
621 // In order to improve numerical precision, it's better to apply smaller weights
│ │ │ │ +
622 // first, so begin with the face-weights followed by the edge-weights and the
│ │ │ │ +
623 // vertex weight last.
│ │ │ │ +
624 dst[cVert].Clear();
│ │ │ │ +
625
│ │ │ │ +
626 if (vMask.GetNumFaceWeights() > 0) {
│ │ │ │ +
627 assert(vMask.AreFaceWeightsForFaceCenters());
│ │ │ │ +
628
│ │ │ │ +
629 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ +
630
│ │ │ │ +
631 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(vFaces[i]);
│ │ │ │ +
632 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ +
633 dst[cVert].AddWithWeight(dst[cVertOfFace], vFaceWeights[i]);
│ │ │ │ +
634 }
│ │ │ │ +
635 }
│ │ │ │ +
636 if (vMask.GetNumEdgeWeights() > 0) {
│ │ │ │ +
637
│ │ │ │ +
638 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ +
639
│ │ │ │ +
640 ConstIndexArray eVerts = parent.getEdgeVertices(vEdges[i]);
│ │ │ │ +
641 Vtr::Index pVertOppositeEdge = (eVerts[0] == vert) ? eVerts[1] : eVerts[0];
│ │ │ │ +
642
│ │ │ │ +
643 dst[cVert].AddWithWeight(src[pVertOppositeEdge], vEdgeWeights[i]);
│ │ │ │ +
644 }
│ │ │ │ +
645 }
│ │ │ │ +
646 dst[cVert].AddWithWeight(src[vert], vVertWeight);
│ │ │ │ +
647 }
│ │ │ │ +
648}
│ │ │ │ +
649
│ │ │ │ +
650
│ │ │ │ +
651//
│ │ │ │ +
652// Internal face-varying implementation details:
│ │ │ │ +
653//
│ │ │ │ +
654template <typename REAL>
│ │ │ │ +
655template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
656inline void
│ │ │ │ +
657PrimvarRefinerReal<REAL>::interpFVarFromFaces(int level, T const & src, U & dst, int channel) const {
│ │ │ │ +
658
│ │ │ │ +
659 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
660
│ │ │ │ +
661 if (refinement.getNumChildVerticesFromFaces() == 0) return;
│ │ │ │ +
662
│ │ │ │ +
663 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
664
│ │ │ │ +
665 Vtr::internal::Level const & parentLevel = refinement.parent();
│ │ │ │ +
666 Vtr::internal::Level const & childLevel = refinement.child();
│ │ │ │ +
667
│ │ │ │ +
668 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel(channel);
│ │ │ │ +
669 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel(channel);
│ │ │ │ +
670
│ │ │ │ +
671 Vtr::internal::StackBuffer<Weight,16> fValueWeights(parentLevel.getMaxValence());
│ │ │ │ +
672
│ │ │ │ +
673 for (int face = 0; face < parentLevel.getNumFaces(); ++face) {
│ │ │ │ +
674
│ │ │ │ +
675 Vtr::Index cVert = refinement.getFaceChildVertex(face);
│ │ │ │ +
676 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ +
677 continue;
│ │ │ │ +
678
│ │ │ │ +
679 Vtr::Index cVertValue = childFVar.getVertexValueOffset(cVert);
│ │ │ │ +
680
│ │ │ │ +
681 // The only difference for face-varying here is that we get the values associated
│ │ │ │ +
682 // with each face-vertex directly from the FVarLevel, rather than using the parent
│ │ │ │ +
683 // face-vertices directly. If any face-vertex has any sibling values, then we may
│ │ │ │ +
684 // get the wrong one using the face-vertex index directly.
│ │ │ │ +
685
│ │ │ │ +
686 // Declare and compute mask weights for this vertex relative to its parent face:
│ │ │ │ +
687 ConstIndexArray fValues = parentFVar.getFaceValues(face);
│ │ │ │ +
688
│ │ │ │ +
689 Mask fMask(fValueWeights, 0, 0);
│ │ │ │ +
690 Vtr::internal::FaceInterface fHood(fValues.size());
│ │ │ │ +
691
│ │ │ │ +
692 scheme.ComputeFaceVertexMask(fHood, fMask);
│ │ │ │ +
693
│ │ │ │ +
694 // Apply the weights to the parent face's vertices:
│ │ │ │ +
695 dst[cVertValue].Clear();
│ │ │ │ +
696
│ │ │ │ +
697 for (int i = 0; i < fValues.size(); ++i) {
│ │ │ │ +
698 dst[cVertValue].AddWithWeight(src[fValues[i]], fValueWeights[i]);
│ │ │ │ +
699 }
│ │ │ │ +
700 }
│ │ │ │ +
701}
│ │ │ │ +
702
│ │ │ │ +
703template <typename REAL>
│ │ │ │ +
704template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
705inline void
│ │ │ │ +
706PrimvarRefinerReal<REAL>::interpFVarFromEdges(int level, T const & src, U & dst, int channel) const {
│ │ │ │ +
707
│ │ │ │ +
708 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
709
│ │ │ │ +
710 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
711
│ │ │ │ +
712 Vtr::internal::Level const & parentLevel = refinement.parent();
│ │ │ │ +
713 Vtr::internal::Level const & childLevel = refinement.child();
│ │ │ │ +
714
│ │ │ │ +
715 Vtr::internal::FVarRefinement const & refineFVar = refinement.getFVarRefinement(channel);
│ │ │ │ +
716 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel(channel);
│ │ │ │ +
717 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel(channel);
│ │ │ │ +
718
│ │ │ │ +
719 //
│ │ │ │ +
720 // Allocate and initialize (if linearly interpolated) interpolation weights for
│ │ │ │ +
721 // the edge mask:
│ │ │ │ +
722 //
│ │ │ │ +
723 Weight eVertWeights[2];
│ │ │ │ +
724 Vtr::internal::StackBuffer<Weight,8> eFaceWeights(parentLevel.getMaxEdgeFaces());
│ │ │ │ +
725
│ │ │ │ +
726 Mask eMask(eVertWeights, 0, eFaceWeights);
│ │ │ │ +
727
│ │ │ │ +
728 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == Sdc::SCHEME_BILINEAR);
│ │ │ │ +
729 if (isLinearFVar) {
│ │ │ │ +
730 eMask.SetNumVertexWeights(2);
│ │ │ │ +
731 eMask.SetNumEdgeWeights(0);
│ │ │ │ +
732 eMask.SetNumFaceWeights(0);
│ │ │ │ +
733
│ │ │ │ +
734 eVertWeights[0] = 0.5f;
│ │ │ │ +
735 eVertWeights[1] = 0.5f;
│ │ │ │ +
736 }
│ │ │ │ +
737
│ │ │ │ +
738 Vtr::internal::EdgeInterface eHood(parentLevel);
│ │ │ │ +
739
│ │ │ │ +
740 for (int edge = 0; edge < parentLevel.getNumEdges(); ++edge) {
│ │ │ │ +
741
│ │ │ │ +
742 Vtr::Index cVert = refinement.getEdgeChildVertex(edge);
│ │ │ │ +
743 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ +
744 continue;
│ │ │ │ +
745
│ │ │ │ +
746 ConstIndexArray cVertValues = childFVar.getVertexValues(cVert);
│ │ │ │ +
747
│ │ │ │ +
748 bool fvarEdgeVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues[0]);
│ │ │ │ +
749 if (fvarEdgeVertMatchesVertex) {
│ │ │ │ +
750 //
│ │ │ │ +
751 // If smoothly interpolated, compute new weights for the edge mask:
│ │ │ │ +
752 //
│ │ │ │ +
753 if (!isLinearFVar) {
│ │ │ │ +
754 eHood.SetIndex(edge);
│ │ │ │ +
755
│ │ │ │ +
756 Sdc::Crease::Rule pRule = (parentLevel.getEdgeSharpness(edge) > 0.0f)
│ │ │ │ +
757 ? Sdc::Crease::RULE_CREASE : Sdc::Crease::RULE_SMOOTH;
│ │ │ │ +
758 Sdc::Crease::Rule cRule = childLevel.getVertexRule(cVert);
│ │ │ │ +
759
│ │ │ │ +
760 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule);
│ │ │ │ +
761 }
│ │ │ │ +
762
│ │ │ │ +
763 // Apply the weights to the parent edge's vertices and (if applicable) to
│ │ │ │ +
764 // the child vertices of its incident faces:
│ │ │ │ +
765 //
│ │ │ │ +
766 // Even though the face-varying topology matches the vertex topology, we need
│ │ │ │ +
767 // to be careful here when getting values corresponding to the two end-vertices.
│ │ │ │ +
768 // While the edge may be continuous, the vertices at their ends may have
│ │ │ │ +
769 // discontinuities elsewhere in their neighborhood (i.e. on the "other side"
│ │ │ │ +
770 // of the end-vertex) and so have sibling values associated with them. In most
│ │ │ │ +
771 // cases the topology for an end-vertex will match and we can use it directly,
│ │ │ │ +
772 // but we must still check and retrieve as needed.
│ │ │ │ +
773 //
│ │ │ │ +
774 // Indices for values corresponding to face-vertices are guaranteed to match,
│ │ │ │ +
775 // so we can use the child-vertex indices directly.
│ │ │ │ +
776 //
│ │ │ │ +
777 // And by "directly", we always use getVertexValue(vertexIndex) to reference
│ │ │ │ +
778 // values in the "src" to account for the possible indirection that may exist at
│ │ │ │ +
779 // level 0 -- where there may be fewer values than vertices and an additional
│ │ │ │ +
780 // indirection is necessary. We can use a vertex index directly for "dst" when
│ │ │ │ +
781 // it matches.
│ │ │ │ +
782 //
│ │ │ │ +
783 Vtr::Index eVertValues[2];
│ │ │ │ +
784
│ │ │ │ +
785 parentFVar.getEdgeFaceValues(edge, 0, eVertValues);
│ │ │ │ +
786
│ │ │ │ +
787 Index cVertValue = cVertValues[0];
│ │ │ │ +
788
│ │ │ │ +
789 dst[cVertValue].Clear();
│ │ │ │ +
790 dst[cVertValue].AddWithWeight(src[eVertValues[0]], eVertWeights[0]);
│ │ │ │ +
791 dst[cVertValue].AddWithWeight(src[eVertValues[1]], eVertWeights[1]);
│ │ │ │ +
792
│ │ │ │ +
793 if (eMask.GetNumFaceWeights() > 0) {
│ │ │ │ +
794
│ │ │ │ +
795 ConstIndexArray eFaces = parentLevel.getEdgeFaces(edge);
│ │ │ │ +
796
│ │ │ │ +
797 for (int i = 0; i < eFaces.size(); ++i) {
│ │ │ │ +
798 if (eMask.AreFaceWeightsForFaceCenters()) {
│ │ │ │ +
799
│ │ │ │ +
800 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(eFaces[i]);
│ │ │ │ +
801 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ +
802
│ │ │ │ +
803 Vtr::Index cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace);
│ │ │ │ +
804 dst[cVertValue].AddWithWeight(dst[cValueOfFace], eFaceWeights[i]);
│ │ │ │ +
805 } else {
│ │ │ │ +
806 Vtr::Index pFace = eFaces[i];
│ │ │ │ +
807 ConstIndexArray pFaceEdges = parentLevel.getFaceEdges(pFace),
│ │ │ │ +
808 pFaceVerts = parentLevel.getFaceVertices(pFace);
│ │ │ │ +
809
│ │ │ │ +
810 int eInFace = 0;
│ │ │ │ +
811 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ;
│ │ │ │ +
812
│ │ │ │ +
813 // Edge "i" spans vertices [i,i+1] so we want i+2...
│ │ │ │ +
814 int vInFace = eInFace + 2;
│ │ │ │ +
815 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts.size();
│ │ │ │ +
816
│ │ │ │ +
817 Vtr::Index pValueNext = parentFVar.getFaceValues(pFace)[vInFace];
│ │ │ │ +
818 dst[cVertValue].AddWithWeight(src[pValueNext], eFaceWeights[i]);
│ │ │ │ +
819 }
│ │ │ │ +
820 }
│ │ │ │ +
821 }
│ │ │ │ +
822 } else {
│ │ │ │ +
823 //
│ │ │ │ +
824 // Mismatched edge-verts should just be linearly interpolated between the pairs of
│ │ │ │ +
825 // values for each sibling of the child edge-vertex -- the question is: which face
│ │ │ │ +
826 // holds that pair of values for a given sibling?
│ │ │ │ +
827 //
│ │ │ │ +
828 // In the manifold case, the sibling and edge-face indices will correspond. We
│ │ │ │ +
829 // will eventually need to update this to account for > 3 incident faces.
│ │ │ │ +
830 //
│ │ │ │ +
831 for (int i = 0; i < cVertValues.size(); ++i) {
│ │ │ │ +
832 Vtr::Index eVertValues[2];
│ │ │ │ +
833 int eFaceIndex = refineFVar.getChildValueParentSource(cVert, i);
│ │ │ │ +
834 assert(eFaceIndex == i);
│ │ │ │ +
835
│ │ │ │ +
836 parentFVar.getEdgeFaceValues(edge, eFaceIndex, eVertValues);
│ │ │ │ +
837
│ │ │ │ +
838 Index cVertValue = cVertValues[i];
│ │ │ │ +
839
│ │ │ │ +
840 dst[cVertValue].Clear();
│ │ │ │ +
841 dst[cVertValue].AddWithWeight(src[eVertValues[0]], 0.5);
│ │ │ │ +
842 dst[cVertValue].AddWithWeight(src[eVertValues[1]], 0.5);
│ │ │ │ +
843 }
│ │ │ │ +
844 }
│ │ │ │ +
845 }
│ │ │ │ +
846}
│ │ │ │ +
847
│ │ │ │ +
848template <typename REAL>
│ │ │ │ +
849template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
850inline void
│ │ │ │ +
851PrimvarRefinerReal<REAL>::interpFVarFromVerts(int level, T const & src, U & dst, int channel) const {
│ │ │ │ +
852
│ │ │ │ +
853 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ +
854
│ │ │ │ +
855 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
856
│ │ │ │ +
857 Vtr::internal::Level const & parentLevel = refinement.parent();
│ │ │ │ +
858 Vtr::internal::Level const & childLevel = refinement.child();
│ │ │ │ +
859
│ │ │ │ +
860 Vtr::internal::FVarRefinement const & refineFVar = refinement.getFVarRefinement(channel);
│ │ │ │ +
861 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel(channel);
│ │ │ │ +
862 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel(channel);
│ │ │ │ +
863
│ │ │ │ +
864 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == Sdc::SCHEME_BILINEAR);
│ │ │ │ +
865
│ │ │ │ +
866 Vtr::internal::StackBuffer<Weight,32> weightBuffer(2*parentLevel.getMaxValence());
│ │ │ │ +
867
│ │ │ │ +
868 Vtr::internal::StackBuffer<Vtr::Index,16> vEdgeValues(parentLevel.getMaxValence());
│ │ │ │ +
869
│ │ │ │ +
870 Vtr::internal::VertexInterface vHood(parentLevel, childLevel);
│ │ │ │ +
871
│ │ │ │ +
872 for (int vert = 0; vert < parentLevel.getNumVertices(); ++vert) {
│ │ │ │ +
873
│ │ │ │ +
874 Vtr::Index cVert = refinement.getVertexChildVertex(vert);
│ │ │ │ +
875 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ +
876 continue;
│ │ │ │ +
877
│ │ │ │ +
878 ConstIndexArray pVertValues = parentFVar.getVertexValues(vert),
│ │ │ │ +
879 cVertValues = childFVar.getVertexValues(cVert);
│ │ │ │ +
880
│ │ │ │ +
881 bool fvarVertVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues[0]);
│ │ │ │ +
882 if (isLinearFVar && fvarVertVertMatchesVertex) {
│ │ │ │ +
883 dst[cVertValues[0]].Clear();
│ │ │ │ +
884 dst[cVertValues[0]].AddWithWeight(src[pVertValues[0]], 1.0f);
│ │ │ │ +
885 continue;
│ │ │ │ +
886 }
│ │ │ │ +
887
│ │ │ │ +
888 if (fvarVertVertMatchesVertex) {
│ │ │ │ +
889 //
│ │ │ │ +
890 // Declare and compute mask weights for this vertex relative to its parent edge:
│ │ │ │ +
891 //
│ │ │ │ +
892 // (We really need to encapsulate this somewhere else for use here and in the
│ │ │ │ +
893 // general case)
│ │ │ │ +
894 //
│ │ │ │ +
895 ConstIndexArray vEdges = parentLevel.getVertexEdges(vert);
│ │ │ │ +
896
│ │ │ │ +
897 Weight vVertWeight;
│ │ │ │ +
898 Weight * vEdgeWeights = weightBuffer;
│ │ │ │ +
899 Weight * vFaceWeights = vEdgeWeights + vEdges.size();
│ │ │ │ +
900
│ │ │ │ +
901 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights);
│ │ │ │ +
902
│ │ │ │ +
903 vHood.SetIndex(vert, cVert);
│ │ │ │ +
904
│ │ │ │ +
905 Sdc::Crease::Rule pRule = parentLevel.getVertexRule(vert);
│ │ │ │ +
906 Sdc::Crease::Rule cRule = childLevel.getVertexRule(cVert);
│ │ │ │ +
907
│ │ │ │ +
908 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule);
│ │ │ │ +
909
│ │ │ │ +
910 // Apply the weights to the parent vertex, the vertices opposite its incident
│ │ │ │ +
911 // edges, and the child vertices of its incident faces:
│ │ │ │ +
912 //
│ │ │ │ +
913 // Even though the face-varying topology matches the vertex topology, we need
│ │ │ │ +
914 // to be careful here when getting values corresponding to vertices at the
│ │ │ │ +
915 // ends of edges. While the edge may be continuous, the end vertex may have
│ │ │ │ +
916 // discontinuities elsewhere in their neighborhood (i.e. on the "other side"
│ │ │ │ +
917 // of the end-vertex) and so have sibling values associated with them. In most
│ │ │ │ +
918 // cases the topology for an end-vertex will match and we can use it directly,
│ │ │ │ +
919 // but we must still check and retrieve as needed.
│ │ │ │ +
920 //
│ │ │ │ +
921 // Indices for values corresponding to face-vertices are guaranteed to match,
│ │ │ │ +
922 // so we can use the child-vertex indices directly.
│ │ │ │ +
923 //
│ │ │ │ +
924 // And by "directly", we always use getVertexValue(vertexIndex) to reference
│ │ │ │ +
925 // values in the "src" to account for the possible indirection that may exist at
│ │ │ │ +
926 // level 0 -- where there may be fewer values than vertices and an additional
│ │ │ │ +
927 // indirection is necessary. We can use a vertex index directly for "dst" when
│ │ │ │ +
928 // it matches.
│ │ │ │ +
929 //
│ │ │ │ +
930 // As with applying the mask to vertex data, in order to improve numerical
│ │ │ │ +
931 // precision, it's better to apply smaller weights first, so begin with the
│ │ │ │ +
932 // face-weights followed by the edge-weights and the vertex weight last.
│ │ │ │ +
933 //
│ │ │ │ +
934 Vtr::Index pVertValue = pVertValues[0];
│ │ │ │ +
935 Vtr::Index cVertValue = cVertValues[0];
│ │ │ │ +
936
│ │ │ │ +
937 dst[cVertValue].Clear();
│ │ │ │ +
938 if (vMask.GetNumFaceWeights() > 0) {
│ │ │ │ +
939 assert(vMask.AreFaceWeightsForFaceCenters());
│ │ │ │ +
940
│ │ │ │ +
941 ConstIndexArray vFaces = parentLevel.getVertexFaces(vert);
│ │ │ │ +
942
│ │ │ │ +
943 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ +
944
│ │ │ │ +
945 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(vFaces[i]);
│ │ │ │ +
946 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ +
947
│ │ │ │ +
948 Vtr::Index cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace);
│ │ │ │ +
949 dst[cVertValue].AddWithWeight(dst[cValueOfFace], vFaceWeights[i]);
│ │ │ │ +
950 }
│ │ │ │ +
951 }
│ │ │ │ +
952 if (vMask.GetNumEdgeWeights() > 0) {
│ │ │ │ +
953
│ │ │ │ +
954 parentFVar.getVertexEdgeValues(vert, vEdgeValues);
│ │ │ │ +
955
│ │ │ │ +
956 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ +
957 dst[cVertValue].AddWithWeight(src[vEdgeValues[i]], vEdgeWeights[i]);
│ │ │ │ +
958 }
│ │ │ │ +
959 }
│ │ │ │ +
960 dst[cVertValue].AddWithWeight(src[pVertValue], vVertWeight);
│ │ │ │ +
961 } else {
│ │ │ │ +
962 //
│ │ │ │ +
963 // Each FVar value associated with a vertex will be either a corner or a crease,
│ │ │ │ +
964 // or potentially in transition from corner to crease:
│ │ │ │ +
965 // - if the CHILD is a corner, there can be no transition so we have a corner
│ │ │ │ +
966 // - otherwise if the PARENT is a crease, both will be creases (no transition)
│ │ │ │ +
967 // - otherwise the parent must be a corner and the child a crease (transition)
│ │ │ │ +
968 //
│ │ │ │ +
969 Vtr::internal::FVarLevel::ConstValueTagArray pValueTags = parentFVar.getVertexValueTags(vert);
│ │ │ │ +
970 Vtr::internal::FVarLevel::ConstValueTagArray cValueTags = childFVar.getVertexValueTags(cVert);
│ │ │ │ +
971
│ │ │ │ +
972 for (int cSiblingIndex = 0; cSiblingIndex < cVertValues.size(); ++cSiblingIndex) {
│ │ │ │ +
973 int pSiblingIndex = refineFVar.getChildValueParentSource(cVert, cSiblingIndex);
│ │ │ │ +
974 assert(pSiblingIndex == cSiblingIndex);
│ │ │ │ +
975
│ │ │ │ +
976 typedef Vtr::internal::FVarLevel::Sibling SiblingIntType;
│ │ │ │ +
977
│ │ │ │ +
978 SiblingIntType cSibling = (SiblingIntType) cSiblingIndex;
│ │ │ │ +
979 SiblingIntType pSibling = (SiblingIntType) pSiblingIndex;
│ │ │ │ +
980
│ │ │ │ +
981 Vtr::Index pVertValue = pVertValues[pSibling];
│ │ │ │ +
982 Vtr::Index cVertValue = cVertValues[cSibling];
│ │ │ │ +
983
│ │ │ │ +
984 dst[cVertValue].Clear();
│ │ │ │ +
985 if (isLinearFVar || cValueTags[cSibling].isCorner()) {
│ │ │ │ +
986 dst[cVertValue].AddWithWeight(src[pVertValue], 1.0f);
│ │ │ │ +
987 } else {
│ │ │ │ +
988 //
│ │ │ │ +
989 // We have either a crease or a transition from corner to crease -- in
│ │ │ │ +
990 // either case, we need the end values for the full/fractional crease:
│ │ │ │ +
991 //
│ │ │ │ +
992 Index pEndValues[2];
│ │ │ │ +
993 parentFVar.getVertexCreaseEndValues(vert, pSibling, pEndValues);
│ │ │ │ +
994
│ │ │ │ +
995 Weight vWeight = 0.75f;
│ │ │ │ +
996 Weight eWeight = 0.125f;
│ │ │ │ +
997
│ │ │ │ +
998 //
│ │ │ │ +
999 // If semi-sharp we need to apply fractional weighting -- if made sharp because
│ │ │ │ +
1000 // of the other sibling (dependent-sharp) use the fractional weight from that
│ │ │ │ +
1001 // other sibling (should only occur when there are 2):
│ │ │ │ +
1002 //
│ │ │ │ +
1003 if (pValueTags[pSibling].isSemiSharp()) {
│ │ │ │ +
1004 Weight wCorner = pValueTags[pSibling].isDepSharp()
│ │ │ │ +
1005 ? refineFVar.getFractionalWeight(vert, !pSibling, cVert, !cSibling)
│ │ │ │ +
1006 : refineFVar.getFractionalWeight(vert, pSibling, cVert, cSibling);
│ │ │ │ +
1007 Weight wCrease = 1.0f - wCorner;
│ │ │ │ +
1008
│ │ │ │ +
1009 vWeight = wCrease * 0.75f + wCorner;
│ │ │ │ +
1010 eWeight = wCrease * 0.125f;
│ │ │ │ +
1011 }
│ │ │ │ +
1012 dst[cVertValue].AddWithWeight(src[pEndValues[0]], eWeight);
│ │ │ │ +
1013 dst[cVertValue].AddWithWeight(src[pEndValues[1]], eWeight);
│ │ │ │ +
1014 dst[cVertValue].AddWithWeight(src[pVertValue], vWeight);
│ │ │ │ +
1015 }
│ │ │ │ +
1016 }
│ │ │ │ +
1017 }
│ │ │ │ +
1018 }
│ │ │ │ +
1019}
│ │ │ │ +
1020
│ │ │ │ +
1021template <typename REAL>
│ │ │ │ +
1022template <Sdc::SchemeType SCHEME, class T, class U, class U1, class U2>
│ │ │ │ +
1023inline void
│ │ │ │ +
1024PrimvarRefinerReal<REAL>::limit(T const & src, U & dstPos, U1 * dstTan1Ptr, U2 * dstTan2Ptr) const {
│ │ │ │ +
1025
│ │ │ │ +
1026 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
1027
│ │ │ │ +
1028 Vtr::internal::Level const & level = _refiner.getLevel(_refiner.GetMaxLevel());
│ │ │ │ +
1029
│ │ │ │ +
1030 int maxWeightsPerMask = 1 + 2 * level.getMaxValence();
│ │ │ │ +
1031 bool hasTangents = (dstTan1Ptr && dstTan2Ptr);
│ │ │ │ +
1032 int numMasks = 1 + (hasTangents ? 2 : 0);
│ │ │ │ +
1033
│ │ │ │ +
1034 Vtr::internal::StackBuffer<Index,33> indexBuffer(maxWeightsPerMask);
│ │ │ │ +
1035 Vtr::internal::StackBuffer<Weight,99> weightBuffer(numMasks * maxWeightsPerMask);
│ │ │ │ +
1036
│ │ │ │ +
1037 Weight * vPosWeights = weightBuffer,
│ │ │ │ +
1038 * ePosWeights = vPosWeights + 1,
│ │ │ │ +
1039 * fPosWeights = ePosWeights + level.getMaxValence();
│ │ │ │ +
1040 Weight * vTan1Weights = vPosWeights + maxWeightsPerMask,
│ │ │ │ +
1041 * eTan1Weights = ePosWeights + maxWeightsPerMask,
│ │ │ │ +
1042 * fTan1Weights = fPosWeights + maxWeightsPerMask;
│ │ │ │ +
1043 Weight * vTan2Weights = vTan1Weights + maxWeightsPerMask,
│ │ │ │ +
1044 * eTan2Weights = eTan1Weights + maxWeightsPerMask,
│ │ │ │ +
1045 * fTan2Weights = fTan1Weights + maxWeightsPerMask;
│ │ │ │ +
1046
│ │ │ │ +
1047 Mask posMask( vPosWeights, ePosWeights, fPosWeights);
│ │ │ │ +
1048 Mask tan1Mask(vTan1Weights, eTan1Weights, fTan1Weights);
│ │ │ │ +
1049 Mask tan2Mask(vTan2Weights, eTan2Weights, fTan2Weights);
│ │ │ │ +
1050
│ │ │ │ +
1051 // This is a bit obscure -- assigning both parent and child as last level -- but
│ │ │ │ +
1052 // this mask type was intended for another purpose. Consider one for the limit:
│ │ │ │ +
1053 Vtr::internal::VertexInterface vHood(level, level);
│ │ │ │ +
1054
│ │ │ │ +
1055 for (int vert = 0; vert < level.getNumVertices(); ++vert) {
│ │ │ │ +
1056 ConstIndexArray vEdges = level.getVertexEdges(vert);
│ │ │ │ +
1057
│ │ │ │ +
1058 // Incomplete vertices (present in sparse refinement) do not have their full
│ │ │ │ +
1059 // topological neighborhood to determine a proper limit -- just leave the
│ │ │ │ +
1060 // vertex at the refined location and continue to the next:
│ │ │ │ +
1061 if (level.getVertexTag(vert)._incomplete || (vEdges.size() == 0)) {
│ │ │ │ +
1062 dstPos[vert].Clear();
│ │ │ │ +
1063 dstPos[vert].AddWithWeight(src[vert], 1.0);
│ │ │ │ +
1064 if (hasTangents) {
│ │ │ │ +
1065 (*dstTan1Ptr)[vert].Clear();
│ │ │ │ +
1066 (*dstTan2Ptr)[vert].Clear();
│ │ │ │ +
1067 }
│ │ │ │ +
1068 continue;
│ │ │ │ +
1069 }
│ │ │ │ +
1070
│ │ │ │ +
1071 //
│ │ │ │ +
1072 // Limit masks require the subdivision Rule for the vertex in order to deal
│ │ │ │ +
1073 // with infinitely sharp features correctly -- including boundaries and corners.
│ │ │ │ +
1074 // The vertex neighborhood is minimally defined with vertex and edge counts.
│ │ │ │ +
1075 //
│ │ │ │ +
1076 Sdc::Crease::Rule vRule = level.getVertexRule(vert);
│ │ │ │ +
1077
│ │ │ │ +
1078 // This is a bit obscure -- child vertex index will be ignored here
│ │ │ │ +
1079 vHood.SetIndex(vert, vert);
│ │ │ │ +
1080
│ │ │ │ +
1081 if (hasTangents) {
│ │ │ │ +
1082 scheme.ComputeVertexLimitMask(vHood, posMask, tan1Mask, tan2Mask, vRule);
│ │ │ │ +
1083 } else {
│ │ │ │ +
1084 scheme.ComputeVertexLimitMask(vHood, posMask, vRule);
│ │ │ │ +
1085 }
│ │ │ │ +
1086
│ │ │ │ +
1087 //
│ │ │ │ +
1088 // Gather the neighboring vertices of this vertex -- the vertices opposite its
│ │ │ │ +
1089 // incident edges, and the opposite vertices of its incident faces:
│ │ │ │ +
1090 //
│ │ │ │ +
1091 Index * eIndices = indexBuffer;
│ │ │ │ +
1092 Index * fIndices = indexBuffer + vEdges.size();
│ │ │ │ +
1093
│ │ │ │ +
1094 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ +
1095 ConstIndexArray eVerts = level.getEdgeVertices(vEdges[i]);
│ │ │ │ +
1096
│ │ │ │ +
1097 eIndices[i] = (eVerts[0] == vert) ? eVerts[1] : eVerts[0];
│ │ │ │ +
1098 }
│ │ │ │ +
1099 if (posMask.GetNumFaceWeights() || (hasTangents && tan1Mask.GetNumFaceWeights())) {
│ │ │ │ +
1100 ConstIndexArray vFaces = level.getVertexFaces(vert);
│ │ │ │ +
1101 ConstLocalIndexArray vInFace = level.getVertexFaceLocalIndices(vert);
│ │ │ │ +
1102
│ │ │ │ +
1103 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ +
1104 ConstIndexArray fVerts = level.getFaceVertices(vFaces[i]);
│ │ │ │ +
1105
│ │ │ │ +
1106 LocalIndex vOppInFace = (vInFace[i] + 2);
│ │ │ │ +
1107 if (vOppInFace >= fVerts.size()) vOppInFace -= (LocalIndex)fVerts.size();
│ │ │ │ +
1108
│ │ │ │ +
1109 fIndices[i] = level.getFaceVertices(vFaces[i])[vOppInFace];
│ │ │ │ +
1110 }
│ │ │ │ +
1111 }
│ │ │ │ +
1112
│ │ │ │ +
1113 //
│ │ │ │ +
1114 // Combine the weights and indices for position and tangents. As with applying
│ │ │ │ +
1115 // refinement masks to vertex data, in order to improve numerical precision, it's
│ │ │ │ +
1116 // better to apply smaller weights first, so begin with the face-weights followed
│ │ │ │ +
1117 // by the edge-weights and the vertex weight last.
│ │ │ │ +
1118 //
│ │ │ │ +
1119 dstPos[vert].Clear();
│ │ │ │ +
1120 for (int i = 0; i < posMask.GetNumFaceWeights(); ++i) {
│ │ │ │ +
1121 dstPos[vert].AddWithWeight(src[fIndices[i]], fPosWeights[i]);
│ │ │ │ +
1122 }
│ │ │ │ +
1123 for (int i = 0; i < posMask.GetNumEdgeWeights(); ++i) {
│ │ │ │ +
1124 dstPos[vert].AddWithWeight(src[eIndices[i]], ePosWeights[i]);
│ │ │ │ +
1125 }
│ │ │ │ +
1126 dstPos[vert].AddWithWeight(src[vert], vPosWeights[0]);
│ │ │ │ +
1127
│ │ │ │ +
1128 //
│ │ │ │ +
1129 // Apply the tangent masks -- both will have the same number of weights and
│ │ │ │ +
1130 // indices (one tangent may be "padded" to accommodate the other), but these
│ │ │ │ +
1131 // may differ from those of the position:
│ │ │ │ +
1132 //
│ │ │ │ +
1133 if (hasTangents) {
│ │ │ │ +
1134 assert(tan1Mask.GetNumFaceWeights() == tan2Mask.GetNumFaceWeights());
│ │ │ │ +
1135 assert(tan1Mask.GetNumEdgeWeights() == tan2Mask.GetNumEdgeWeights());
│ │ │ │ +
1136
│ │ │ │ +
1137 U1 & dstTan1 = *dstTan1Ptr;
│ │ │ │ +
1138 U2 & dstTan2 = *dstTan2Ptr;
│ │ │ │ +
1139
│ │ │ │ +
1140 dstTan1[vert].Clear();
│ │ │ │ +
1141 dstTan2[vert].Clear();
│ │ │ │ +
1142 for (int i = 0; i < tan1Mask.GetNumFaceWeights(); ++i) {
│ │ │ │ +
1143 dstTan1[vert].AddWithWeight(src[fIndices[i]], fTan1Weights[i]);
│ │ │ │ +
1144 dstTan2[vert].AddWithWeight(src[fIndices[i]], fTan2Weights[i]);
│ │ │ │ +
1145 }
│ │ │ │ +
1146 for (int i = 0; i < tan1Mask.GetNumEdgeWeights(); ++i) {
│ │ │ │ +
1147 dstTan1[vert].AddWithWeight(src[eIndices[i]], eTan1Weights[i]);
│ │ │ │ +
1148 dstTan2[vert].AddWithWeight(src[eIndices[i]], eTan2Weights[i]);
│ │ │ │ +
1149 }
│ │ │ │ +
1150 dstTan1[vert].AddWithWeight(src[vert], vTan1Weights[0]);
│ │ │ │ +
1151 dstTan2[vert].AddWithWeight(src[vert], vTan2Weights[0]);
│ │ │ │ +
1152 }
│ │ │ │ +
1153 }
│ │ │ │ +
1154}
│ │ │ │ +
1155
│ │ │ │ +
1156template <typename REAL>
│ │ │ │ +
1157template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ +
1158inline void
│ │ │ │ +
1159PrimvarRefinerReal<REAL>::limitFVar(T const & src, U & dst, int channel) const {
│ │ │ │ +
1160
│ │ │ │ +
1161 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ +
1162
│ │ │ │ +
1163 Vtr::internal::Level const & level = _refiner.getLevel(_refiner.GetMaxLevel());
│ │ │ │ +
1164 Vtr::internal::FVarLevel const & fvarChannel = level.getFVarLevel(channel);
│ │ │ │ +
1165
│ │ │ │ +
1166 int maxWeightsPerMask = 1 + 2 * level.getMaxValence();
│ │ │ │ +
1167
│ │ │ │ +
1168 Vtr::internal::StackBuffer<Weight,33> weightBuffer(maxWeightsPerMask);
│ │ │ │ +
1169 Vtr::internal::StackBuffer<Index,16> vEdgeBuffer(level.getMaxValence());
│ │ │ │ +
1170
│ │ │ │ +
1171 // This is a bit obscure -- assign both parent and child as last level
│ │ │ │ +
1172 Vtr::internal::VertexInterface vHood(level, level);
│ │ │ │ +
1173
│ │ │ │ +
1174 for (int vert = 0; vert < level.getNumVertices(); ++vert) {
│ │ │ │ +
1175
│ │ │ │ +
1176 ConstIndexArray vEdges = level.getVertexEdges(vert);
│ │ │ │ +
1177 ConstIndexArray vValues = fvarChannel.getVertexValues(vert);
│ │ │ │ +
1178
│ │ │ │ +
1179 // Incomplete vertices (present in sparse refinement) do not have their full
│ │ │ │ +
1180 // topological neighborhood to determine a proper limit -- just leave the
│ │ │ │ +
1181 // values (perhaps more than one per vertex) at the refined location.
│ │ │ │ +
1182 //
│ │ │ │ +
1183 // The same can be done if the face-varying channel is purely linear.
│ │ │ │ +
1184 //
│ │ │ │ +
1185 bool isIncomplete = (level.getVertexTag(vert)._incomplete || (vEdges.size() == 0));
│ │ │ │ +
1186 if (isIncomplete || fvarChannel.isLinear()) {
│ │ │ │ +
1187 for (int i = 0; i < vValues.size(); ++i) {
│ │ │ │ +
1188 Vtr::Index vValue = vValues[i];
│ │ │ │ +
1189
│ │ │ │ +
1190 dst[vValue].Clear();
│ │ │ │ +
1191 dst[vValue].AddWithWeight(src[vValue], 1.0f);
│ │ │ │ +
1192 }
│ │ │ │ +
1193 continue;
│ │ │ │ +
1194 }
│ │ │ │ +
1195
│ │ │ │ +
1196 bool fvarVertMatchesVertex = fvarChannel.valueTopologyMatches(vValues[0]);
│ │ │ │ +
1197 if (fvarVertMatchesVertex) {
│ │ │ │ +
1198
│ │ │ │ +
1199 // Assign the mask weights to the common buffer and compute the mask:
│ │ │ │ +
1200 //
│ │ │ │ +
1201 Weight * vWeights = weightBuffer,
│ │ │ │ +
1202 * eWeights = vWeights + 1,
│ │ │ │ +
1203 * fWeights = eWeights + vEdges.size();
│ │ │ │ +
1204
│ │ │ │ +
1205 Mask vMask(vWeights, eWeights, fWeights);
│ │ │ │ +
1206
│ │ │ │ +
1207 vHood.SetIndex(vert, vert);
│ │ │ │ +
1208
│ │ │ │ +
1209 scheme.ComputeVertexLimitMask(vHood, vMask, level.getVertexRule(vert));
│ │ │ │ +
1210
│ │ │ │ +
1211 //
│ │ │ │ +
1212 // Apply mask to corresponding FVar values for neighboring vertices:
│ │ │ │ +
1213 //
│ │ │ │ +
1214 Vtr::Index vValue = vValues[0];
│ │ │ │ +
1215
│ │ │ │ +
1216 dst[vValue].Clear();
│ │ │ │ +
1217 if (vMask.GetNumFaceWeights() > 0) {
│ │ │ │ +
1218 assert(!vMask.AreFaceWeightsForFaceCenters());
│ │ │ │ +
1219
│ │ │ │ +
1220 ConstIndexArray vFaces = level.getVertexFaces(vert);
│ │ │ │ +
1221 ConstLocalIndexArray vInFace = level.getVertexFaceLocalIndices(vert);
│ │ │ │ +
1222
│ │ │ │ +
1223 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ +
1224 ConstIndexArray faceValues = fvarChannel.getFaceValues(vFaces[i]);
│ │ │ │ +
1225 LocalIndex vOppInFace = vInFace[i] + 2;
│ │ │ │ +
1226 if (vOppInFace >= faceValues.size()) vOppInFace -= faceValues.size();
│ │ │ │ +
1227
│ │ │ │ +
1228 Index vValueOppositeFace = faceValues[vOppInFace];
│ │ │ │ +
1229
│ │ │ │ +
1230 dst[vValue].AddWithWeight(src[vValueOppositeFace], fWeights[i]);
│ │ │ │ +
1231 }
│ │ │ │ +
1232 }
│ │ │ │ +
1233 if (vMask.GetNumEdgeWeights() > 0) {
│ │ │ │ +
1234 Index * vEdgeValues = vEdgeBuffer;
│ │ │ │ +
1235 fvarChannel.getVertexEdgeValues(vert, vEdgeValues);
│ │ │ │ +
1236
│ │ │ │ +
1237 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ +
1238 dst[vValue].AddWithWeight(src[vEdgeValues[i]], eWeights[i]);
│ │ │ │ +
1239 }
│ │ │ │ +
1240 }
│ │ │ │ +
1241 dst[vValue].AddWithWeight(src[vValue], vWeights[0]);
│ │ │ │ +
1242 } else {
│ │ │ │ +
1243 //
│ │ │ │ +
1244 // Sibling FVar values associated with a vertex will be either a corner or a crease:
│ │ │ │ +
1245 //
│ │ │ │ +
1246 for (int i = 0; i < vValues.size(); ++i) {
│ │ │ │ +
1247 Vtr::Index vValue = vValues[i];
│ │ │ │ +
1248
│ │ │ │ +
1249 dst[vValue].Clear();
│ │ │ │ +
1250 if (fvarChannel.getValueTag(vValue).isCorner()) {
│ │ │ │ +
1251 dst[vValue].AddWithWeight(src[vValue], 1.0f);
│ │ │ │ +
1252 } else {
│ │ │ │ +
1253 Index vEndValues[2];
│ │ │ │ +
1254 fvarChannel.getVertexCreaseEndValues(vert, i, vEndValues);
│ │ │ │ +
1255
│ │ │ │ +
1256 dst[vValue].AddWithWeight(src[vEndValues[0]], 1.0f/6.0f);
│ │ │ │ +
1257 dst[vValue].AddWithWeight(src[vEndValues[1]], 1.0f/6.0f);
│ │ │ │ +
1258 dst[vValue].AddWithWeight(src[vValue], 2.0f/3.0f);
│ │ │ │ +
1259 }
│ │ │ │ +
1260 }
│ │ │ │ +
1261 }
│ │ │ │ +
1262 }
│ │ │ │ +
1263}
│ │ │ │ +
1264
│ │ │ │ +
│ │ │ │ +
1265class PrimvarRefiner : public PrimvarRefinerReal<float> {
│ │ │ │ +
1266public:
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1268 : PrimvarRefinerReal<float>(refiner) { }
│ │ │ │ +
│ │ │ │ +
1269};
│ │ │ │ +
│ │ │ │ +
1270
│ │ │ │ +
1271} // end namespace Far
│ │ │ │ +
1272
│ │ │ │ +
1273} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
1274using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
1275} // end namespace OpenSubdiv
│ │ │ │ +
1276
│ │ │ │ +
1277#endif /* OPENSUBDIV3_FAR_PRIMVAR_REFINER_H */
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
│ │ │ │ │ │ │ │ + │ │ │ │ +
void Error(ErrorType err, const char *format,...)
Sends an OSD error with a message (internal use only)
│ │ │ │ +
Vtr::ConstIndexArray ConstIndexArray
Definition types.h:47
│ │ │ │ +
Vtr::ConstLocalIndexArray ConstLocalIndexArray
Definition types.h:48
│ │ │ │ +
@ FAR_RUNTIME_ERROR
Issue a generic runtime error, but continue execution.
Definition error.h:40
│ │ │ │ │ │ │ │ -
Object used to compute and query ptex face indices.
Definition ptexIndices.h:46
│ │ │ │ -
int GetFaceId(Index f) const
Returns the ptex face index given a coarse face 'f' or -1.
│ │ │ │ -
PtexIndices(TopologyRefiner const &refiner)
Constructor.
│ │ │ │ -
void GetAdjacency(TopologyRefiner const &refiner, int face, int quadrant, int adjFaces[4], int adjEdges[4]) const
Returns ptex face adjacency information for a given coarse face.
│ │ │ │ -
int GetNumFaces() const
Returns the number of ptex faces in the mesh.
│ │ │ │ - │ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ + │ │ │ │ +
bool IndexIsValid(Index index)
Definition types.h:58
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
Applies refinement operations to generic primvar data.
│ │ │ │ +
void Limit(T const &src, U &dstPos) const
Apply limit weights to a primvar buffer.
│ │ │ │ + │ │ │ │ +
void Limit(T const &src, U &dstPos, U1 &dstTan1, U2 &dstTan2) const
│ │ │ │ +
void InterpolateFaceUniform(int level, T const &src, U &dst) const
Refine uniform (per-face) primvar data between levels.
│ │ │ │ + │ │ │ │ +
void InterpolateVarying(int level, T const &src, U &dst) const
Apply only varying interpolation weights to a primvar buffer for a single level of refinement.
│ │ │ │ +
void Interpolate(int level, T const &src, U &dst) const
Apply vertex interpolation weights to a primvar buffer for a single level of refinement.
│ │ │ │ +
void InterpolateFaceVarying(int level, T const &src, U &dst, int channel=0) const
Apply face-varying interpolation weights to a primvar buffer associated with a particular face-varyin...
│ │ │ │ + │ │ │ │ +
void LimitFaceVarying(T const &src, U &dst, int channel=0) const
│ │ │ │ + │ │ │ │ + │ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
Scheme is a class template which provides all implementation for the subdivision schemes supported by...
Definition scheme.h:66
│ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -ptexIndices.h │ │ │ │ │ +primvarRefiner.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2015 Pixar │ │ │ │ │ +2// Copyright 2015 DreamWorks Animation LLC. │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,90 +23,1388 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_FAR_PTEX_INDICES_H │ │ │ │ │ -25#define OPENSUBDIV3_FAR_PTEX_INDICES_H │ │ │ │ │ +24#ifndef OPENSUBDIV3_FAR_PRIMVAR_REFINER_H │ │ │ │ │ +25#define OPENSUBDIV3_FAR_PRIMVAR_REFINER_H │ │ │ │ │ 26 │ │ │ │ │ 27#include "../version.h" │ │ │ │ │ 28 │ │ │ │ │ -29#include "../far/topologyRefiner.h" │ │ │ │ │ -30#include "../far/types.h" │ │ │ │ │ -31 │ │ │ │ │ -32#include │ │ │ │ │ -33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Far { │ │ │ │ │ -38 │ │ │ │ │ -_4_6class _P_t_e_x_I_n_d_i_c_e_s { │ │ │ │ │ -47 │ │ │ │ │ -48public: │ │ │ │ │ +29#include "../sdc/types.h" │ │ │ │ │ +30#include "../sdc/options.h" │ │ │ │ │ +31#include "../sdc/bilinearScheme.h" │ │ │ │ │ +32#include "../sdc/catmarkScheme.h" │ │ │ │ │ +33#include "../sdc/loopScheme.h" │ │ │ │ │ +34#include "../vtr/level.h" │ │ │ │ │ +35#include "../vtr/fvarLevel.h" │ │ │ │ │ +36#include "../vtr/refinement.h" │ │ │ │ │ +37#include "../vtr/fvarRefinement.h" │ │ │ │ │ +38#include "../vtr/stackBuffer.h" │ │ │ │ │ +39#include "../vtr/componentInterfaces.h" │ │ │ │ │ +40#include "../far/types.h" │ │ │ │ │ +41#include "../far/error.h" │ │ │ │ │ +42#include "../far/topologyLevel.h" │ │ │ │ │ +43#include "../far/topologyRefiner.h" │ │ │ │ │ +44 │ │ │ │ │ +45#include │ │ │ │ │ +46 │ │ │ │ │ +47namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +48namespace OPENSUBDIV_VERSION { │ │ │ │ │ 49 │ │ │ │ │ -_5_1 _P_t_e_x_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner); │ │ │ │ │ -52 │ │ │ │ │ -_5_4 _~_P_t_e_x_I_n_d_i_c_e_s(); │ │ │ │ │ -55 │ │ │ │ │ +50namespace Far { │ │ │ │ │ +51 │ │ │ │ │ +55template │ │ │ │ │ +_5_6class _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l { │ │ │ │ │ 57 │ │ │ │ │ -60 │ │ │ │ │ -_6_3 int _G_e_t_N_u_m_F_a_c_e_s() const; │ │ │ │ │ -64 │ │ │ │ │ -_6_7 int _G_e_t_F_a_c_e_I_d(_I_n_d_e_x f) const; │ │ │ │ │ -68 │ │ │ │ │ -_8_3 void _G_e_t_A_d_j_a_c_e_n_c_y( │ │ │ │ │ -84 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ -85 int face, int quadrant, │ │ │ │ │ -86 int adjFaces[4], int adjEdges[4]) const; │ │ │ │ │ -87 │ │ │ │ │ -89 │ │ │ │ │ -90private: │ │ │ │ │ -91 │ │ │ │ │ -92 void initializePtexIndices(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner); │ │ │ │ │ -93 │ │ │ │ │ -94private: │ │ │ │ │ -95 │ │ │ │ │ -96 std::vector _ptexIndices; │ │ │ │ │ -97}; │ │ │ │ │ -98 │ │ │ │ │ -99 │ │ │ │ │ -100} // end namespace Far │ │ │ │ │ -101 │ │ │ │ │ -102} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -103using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -104} // end namespace OpenSubdiv │ │ │ │ │ -105 │ │ │ │ │ -106#endif /* OPENSUBDIV3_FAR_PTEX_INDICES_H */ │ │ │ │ │ +58public: │ │ │ │ │ +_5_9 _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner) : _refiner(refiner) { } │ │ │ │ │ +_6_0 _~_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l() { } │ │ │ │ │ +61 │ │ │ │ │ +_6_2 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & _G_e_t_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r() const { return _refiner; } │ │ │ │ │ +63 │ │ │ │ │ +65 │ │ │ │ │ +100 │ │ │ │ │ +_1_1_3 template void _I_n_t_e_r_p_o_l_a_t_e(int level, T const & src, U & │ │ │ │ │ +dst) const; │ │ │ │ │ +114 │ │ │ │ │ +_1_3_0 template void _I_n_t_e_r_p_o_l_a_t_e_V_a_r_y_i_n_g(int level, T const & │ │ │ │ │ +src, U & dst) const; │ │ │ │ │ +131 │ │ │ │ │ +_1_4_8 template void _I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_U_n_i_f_o_r_m(int level, T const │ │ │ │ │ +& src, U & dst) const; │ │ │ │ │ +149 │ │ │ │ │ +_1_6_1 template void _I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_V_a_r_y_i_n_g(int level, T const │ │ │ │ │ +& src, U & dst, int channel = 0) const; │ │ │ │ │ +162 │ │ │ │ │ +163 │ │ │ │ │ +_1_7_5 template void _L_i_m_i_t(T const & src, U & dstPos) const; │ │ │ │ │ +176 │ │ │ │ │ +177 template │ │ │ │ │ +_1_7_8 void _L_i_m_i_t(T const & src, U & dstPos, U1 & dstTan1, U2 & dstTan2) const; │ │ │ │ │ +179 │ │ │ │ │ +_1_8_0 template void _L_i_m_i_t_F_a_c_e_V_a_r_y_i_n_g(T const & src, U & dst, │ │ │ │ │ +int channel = 0) const; │ │ │ │ │ +181 │ │ │ │ │ +183 │ │ │ │ │ +184private: │ │ │ │ │ +185 typedef REAL Weight; │ │ │ │ │ +186 │ │ │ │ │ +187 // Non-copyable: │ │ │ │ │ +188 _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l(_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l const & src) : _refiner(src._refiner) │ │ │ │ │ +{ } │ │ │ │ │ +189 _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l & operator=(_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l const &) { return *this; │ │ │ │ │ +} │ │ │ │ │ +190 │ │ │ │ │ +191 template void interpFromFaces │ │ │ │ │ +(int, T const &, U &) const; │ │ │ │ │ +192 template void interpFromEdges │ │ │ │ │ +(int, T const &, U &) const; │ │ │ │ │ +193 template void interpFromVerts │ │ │ │ │ +(int, T const &, U &) const; │ │ │ │ │ +194 │ │ │ │ │ +195 template void │ │ │ │ │ +interpFVarFromFaces(int, T const &, U &, int) const; │ │ │ │ │ +196 template void │ │ │ │ │ +interpFVarFromEdges(int, T const &, U &, int) const; │ │ │ │ │ +197 template void │ │ │ │ │ +interpFVarFromVerts(int, T const &, U &, int) const; │ │ │ │ │ +198 │ │ │ │ │ +199 template │ │ │ │ │ +200 void limit(T const & src, U & pos, U1 * tan1, U2 * tan2) const; │ │ │ │ │ +201 │ │ │ │ │ +202 template │ │ │ │ │ +203 void limitFVar(T const & src, U & dst, int channel) const; │ │ │ │ │ +204 │ │ │ │ │ +205private: │ │ │ │ │ +206 TopologyRefiner const & _refiner; │ │ │ │ │ +207 │ │ │ │ │ +208private: │ │ │ │ │ +209 // │ │ │ │ │ +210 // Local class to fulfill interface for in the Scheme mask │ │ │ │ │ +queries: │ │ │ │ │ +211 // │ │ │ │ │ +212 class Mask { │ │ │ │ │ +213 public: │ │ │ │ │ +214 typedef REAL Weight; // Also part of the expected interface │ │ │ │ │ +215 │ │ │ │ │ +216 public: │ │ │ │ │ +217 Mask(Weight* v, Weight* e, Weight* f) : │ │ │ │ │ +218 _vertWeights(v), _edgeWeights(e), _faceWeights(f), │ │ │ │ │ +219 _vertCount(0), _edgeCount(0), _faceCount(0), │ │ │ │ │ +220 _faceWeightsForFaceCenters(false) │ │ │ │ │ +221 { } │ │ │ │ │ +222 │ │ │ │ │ +223 ~Mask() { } │ │ │ │ │ +224 │ │ │ │ │ +225 public: // Generic interface expected of : │ │ │ │ │ +226 int GetNumVertexWeights() const { return _vertCount; } │ │ │ │ │ +227 int GetNumEdgeWeights() const { return _edgeCount; } │ │ │ │ │ +228 int GetNumFaceWeights() const { return _faceCount; } │ │ │ │ │ +229 │ │ │ │ │ +230 void SetNumVertexWeights(int count) { _vertCount = count; } │ │ │ │ │ +231 void SetNumEdgeWeights( int count) { _edgeCount = count; } │ │ │ │ │ +232 void SetNumFaceWeights( int count) { _faceCount = count; } │ │ │ │ │ +233 │ │ │ │ │ +234 Weight const& VertexWeight(int index) const { return _vertWeights[index]; } │ │ │ │ │ +235 Weight const& EdgeWeight( int index) const { return _edgeWeights[index]; } │ │ │ │ │ +236 Weight const& FaceWeight( int index) const { return _faceWeights[index]; } │ │ │ │ │ +237 │ │ │ │ │ +238 Weight& VertexWeight(int index) { return _vertWeights[index]; } │ │ │ │ │ +239 Weight& EdgeWeight( int index) { return _edgeWeights[index]; } │ │ │ │ │ +240 Weight& FaceWeight( int index) { return _faceWeights[index]; } │ │ │ │ │ +241 │ │ │ │ │ +242 bool AreFaceWeightsForFaceCenters() const { return │ │ │ │ │ +_faceWeightsForFaceCenters; } │ │ │ │ │ +243 void SetFaceWeightsForFaceCenters(bool on) { _faceWeightsForFaceCenters = │ │ │ │ │ +on; } │ │ │ │ │ +244 │ │ │ │ │ +245 private: │ │ │ │ │ +246 Weight* _vertWeights; │ │ │ │ │ +247 Weight* _edgeWeights; │ │ │ │ │ +248 Weight* _faceWeights; │ │ │ │ │ +249 │ │ │ │ │ +250 int _vertCount; │ │ │ │ │ +251 int _edgeCount; │ │ │ │ │ +252 int _faceCount; │ │ │ │ │ +253 │ │ │ │ │ +254 bool _faceWeightsForFaceCenters; │ │ │ │ │ +255 }; │ │ │ │ │ +256}; │ │ │ │ │ +257 │ │ │ │ │ +258 │ │ │ │ │ +259// │ │ │ │ │ +260// Public entry points to the methods. Queries of the scheme type and its │ │ │ │ │ +261// use as a template parameter in subsequent implementation will be factored │ │ │ │ │ +262// out of a later release: │ │ │ │ │ +263// │ │ │ │ │ +264template │ │ │ │ │ +265template │ │ │ │ │ +266inline void │ │ │ │ │ +_2_6_7_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e(int level, T const & src, U & dst) │ │ │ │ │ +const { │ │ │ │ │ +268 │ │ │ │ │ +269 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ +270 │ │ │ │ │ +271 switch (_refiner._subdivType) { │ │ │ │ │ +272 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ +273 interpFromFaces(level, src, dst); │ │ │ │ │ +274 interpFromEdges(level, src, dst); │ │ │ │ │ +275 interpFromVerts(level, src, dst); │ │ │ │ │ +276 break; │ │ │ │ │ +277 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ +278 interpFromFaces(level, src, dst); │ │ │ │ │ +279 interpFromEdges(level, src, dst); │ │ │ │ │ +280 interpFromVerts(level, src, dst); │ │ │ │ │ +281 break; │ │ │ │ │ +282 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ +283 interpFromFaces(level, src, dst); │ │ │ │ │ +284 interpFromEdges(level, src, dst); │ │ │ │ │ +285 interpFromVerts(level, src, dst); │ │ │ │ │ +286 break; │ │ │ │ │ +287 } │ │ │ │ │ +288} │ │ │ │ │ +289 │ │ │ │ │ +290template │ │ │ │ │ +291template │ │ │ │ │ +292inline void │ │ │ │ │ +_2_9_3_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_V_a_r_y_i_n_g(int level, T const & src, U │ │ │ │ │ +& dst, int channel) const { │ │ │ │ │ +294 │ │ │ │ │ +295 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ +296 │ │ │ │ │ +297 switch (_refiner._subdivType) { │ │ │ │ │ +298 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ +299 interpFVarFromFaces(level, src, dst, channel); │ │ │ │ │ +300 interpFVarFromEdges(level, src, dst, channel); │ │ │ │ │ +301 interpFVarFromVerts(level, src, dst, channel); │ │ │ │ │ +302 break; │ │ │ │ │ +303 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ +304 interpFVarFromFaces(level, src, dst, channel); │ │ │ │ │ +305 interpFVarFromEdges(level, src, dst, channel); │ │ │ │ │ +306 interpFVarFromVerts(level, src, dst, channel); │ │ │ │ │ +307 break; │ │ │ │ │ +308 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ +309 interpFVarFromFaces(level, src, dst, channel); │ │ │ │ │ +310 interpFVarFromEdges(level, src, dst, channel); │ │ │ │ │ +311 interpFVarFromVerts(level, src, dst, channel); │ │ │ │ │ +312 break; │ │ │ │ │ +313 } │ │ │ │ │ +314} │ │ │ │ │ +315 │ │ │ │ │ +316template │ │ │ │ │ +317template │ │ │ │ │ +318inline void │ │ │ │ │ +_3_1_9_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_L_i_m_i_t(T const & src, U & dst) const { │ │ │ │ │ +320 │ │ │ │ │ +321 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == │ │ │ │ │ +0) { │ │ │ │ │ +322 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ +323 "Failure in PrimvarRefiner::Limit() -- " │ │ │ │ │ +324 "last level of refinement does not include full topology."); │ │ │ │ │ +325 return; │ │ │ │ │ +326 } │ │ │ │ │ +327 │ │ │ │ │ +328 switch (_refiner._subdivType) { │ │ │ │ │ +329 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ +330 limit(src, dst, (U*)0, (U*)0); │ │ │ │ │ +331 break; │ │ │ │ │ +332 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ +333 limit(src, dst, (U*)0, (U*)0); │ │ │ │ │ +334 break; │ │ │ │ │ +335 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ +336 limit(src, dst, (U*)0, (U*)0); │ │ │ │ │ +337 break; │ │ │ │ │ +338 } │ │ │ │ │ +339} │ │ │ │ │ +340 │ │ │ │ │ +341template │ │ │ │ │ +342template │ │ │ │ │ +343inline void │ │ │ │ │ +_3_4_4_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_L_i_m_i_t(T const & src, U & dstPos, U1 & dstTan1, U2 │ │ │ │ │ +& dstTan2) const { │ │ │ │ │ +345 │ │ │ │ │ +346 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == │ │ │ │ │ +0) { │ │ │ │ │ +347 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ +348 "Failure in PrimvarRefiner::Limit() -- " │ │ │ │ │ +349 "last level of refinement does not include full topology."); │ │ │ │ │ +350 return; │ │ │ │ │ +351 } │ │ │ │ │ +352 │ │ │ │ │ +353 switch (_refiner._subdivType) { │ │ │ │ │ +354 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ +355 limit(src, dstPos, &dstTan1, &dstTan2); │ │ │ │ │ +356 break; │ │ │ │ │ +357 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ +358 limit(src, dstPos, &dstTan1, &dstTan2); │ │ │ │ │ +359 break; │ │ │ │ │ +360 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ +361 limit(src, dstPos, &dstTan1, &dstTan2); │ │ │ │ │ +362 break; │ │ │ │ │ +363 } │ │ │ │ │ +364} │ │ │ │ │ +365 │ │ │ │ │ +366template │ │ │ │ │ +367template │ │ │ │ │ +368inline void │ │ │ │ │ +_3_6_9_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_L_i_m_i_t_F_a_c_e_V_a_r_y_i_n_g(T const & src, U & dst, int │ │ │ │ │ +channel) const { │ │ │ │ │ +370 │ │ │ │ │ +371 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == │ │ │ │ │ +0) { │ │ │ │ │ +372 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ +373 "Failure in PrimvarRefiner::LimitFaceVarying() -- " │ │ │ │ │ +374 "last level of refinement does not include full topology."); │ │ │ │ │ +375 return; │ │ │ │ │ +376 } │ │ │ │ │ +377 │ │ │ │ │ +378 switch (_refiner._subdivType) { │ │ │ │ │ +379 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ +380 limitFVar(src, dst, channel); │ │ │ │ │ +381 break; │ │ │ │ │ +382 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ +383 limitFVar(src, dst, channel); │ │ │ │ │ +384 break; │ │ │ │ │ +385 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ +386 limitFVar(src, dst, channel); │ │ │ │ │ +387 break; │ │ │ │ │ +388 } │ │ │ │ │ +389} │ │ │ │ │ +390 │ │ │ │ │ +391template │ │ │ │ │ +392template │ │ │ │ │ +393inline void │ │ │ │ │ +_3_9_4_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_U_n_i_f_o_r_m(int level, T const & src, U │ │ │ │ │ +& dst) const { │ │ │ │ │ +395 │ │ │ │ │ +396 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ +397 │ │ │ │ │ +398 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +399 Vtr::internal::Level const & child = refinement.child(); │ │ │ │ │ +400 │ │ │ │ │ +401 for (int cFace = 0; cFace < child.getNumFaces(); ++cFace) { │ │ │ │ │ +402 │ │ │ │ │ +403 _V_t_r_:_:_I_n_d_e_x pFace = refinement.getChildFaceParentFace(cFace); │ │ │ │ │ +404 │ │ │ │ │ +405 dst[cFace] = src[pFace]; │ │ │ │ │ +406 } │ │ │ │ │ +407} │ │ │ │ │ +408 │ │ │ │ │ +409template │ │ │ │ │ +410template │ │ │ │ │ +411inline void │ │ │ │ │ +_4_1_2_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e_V_a_r_y_i_n_g(int level, T const & src, U & │ │ │ │ │ +dst) const { │ │ │ │ │ +413 │ │ │ │ │ +414 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ +415 │ │ │ │ │ +416 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +417 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ +418 │ │ │ │ │ +419 // │ │ │ │ │ +420 // Group values to interpolate based on origin -- note that there may │ │ │ │ │ +421 // be none originating from faces: │ │ │ │ │ +422 // │ │ │ │ │ +423 if (refinement.getNumChildVerticesFromFaces() > 0) { │ │ │ │ │ +424 │ │ │ │ │ +425 for (int face = 0; face < parent.getNumFaces(); ++face) { │ │ │ │ │ +426 │ │ │ │ │ +427 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getFaceChildVertex(face); │ │ │ │ │ +428 if (_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) { │ │ │ │ │ +429 │ │ │ │ │ +430 // Apply the weights to the parent face's vertices: │ │ │ │ │ +431 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fVerts = parent.getFaceVertices(face); │ │ │ │ │ +432 │ │ │ │ │ +433 Weight fVaryingWeight = 1.0f / (Weight) fVerts._s_i_z_e(); │ │ │ │ │ +434 │ │ │ │ │ +435 dst[cVert].Clear(); │ │ │ │ │ +436 for (int i = 0; i < fVerts._s_i_z_e(); ++i) { │ │ │ │ │ +437 dst[cVert].AddWithWeight(src[fVerts[i]], fVaryingWeight); │ │ │ │ │ +438 } │ │ │ │ │ +439 } │ │ │ │ │ +440 } │ │ │ │ │ +441 } │ │ │ │ │ +442 for (int edge = 0; edge < parent.getNumEdges(); ++edge) { │ │ │ │ │ +443 │ │ │ │ │ +444 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getEdgeChildVertex(edge); │ │ │ │ │ +445 if (_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) { │ │ │ │ │ +446 │ │ │ │ │ +447 // Apply the weights to the parent edges's vertices │ │ │ │ │ +448 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = parent.getEdgeVertices(edge); │ │ │ │ │ +449 │ │ │ │ │ +450 dst[cVert].Clear(); │ │ │ │ │ +451 dst[cVert].AddWithWeight(src[eVerts[0]], 0.5f); │ │ │ │ │ +452 dst[cVert].AddWithWeight(src[eVerts[1]], 0.5f); │ │ │ │ │ +453 } │ │ │ │ │ +454 } │ │ │ │ │ +455 for (int vert = 0; vert < parent.getNumVertices(); ++vert) { │ │ │ │ │ +456 │ │ │ │ │ +457 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getVertexChildVertex(vert); │ │ │ │ │ +458 if (_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) { │ │ │ │ │ +459 │ │ │ │ │ +460 // Essentially copy the parent vertex: │ │ │ │ │ +461 dst[cVert].Clear(); │ │ │ │ │ +462 dst[cVert].AddWithWeight(src[vert], 1.0f); │ │ │ │ │ +463 } │ │ │ │ │ +464 } │ │ │ │ │ +465} │ │ │ │ │ +466 │ │ │ │ │ +467 │ │ │ │ │ +468// │ │ │ │ │ +469// Internal implementation methods -- grouping vertices to be interpolated │ │ │ │ │ +470// based on the type of parent component from which they originated: │ │ │ │ │ +471// │ │ │ │ │ +472template │ │ │ │ │ +473template │ │ │ │ │ +474inline void │ │ │ │ │ +475_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_i_n_t_e_r_p_F_r_o_m_F_a_c_e_s(int level, T const & src, U & dst) │ │ │ │ │ +const { │ │ │ │ │ +476 │ │ │ │ │ +477 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +478 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ +479 │ │ │ │ │ +480 if (refinement.getNumChildVerticesFromFaces() == 0) return; │ │ │ │ │ +481 │ │ │ │ │ +482 _S_d_c_:_:_S_c_h_e_m_e_<_S_C_H_E_M_E_> scheme(_refiner._subdivOptions); │ │ │ │ │ +483 │ │ │ │ │ +484 Vtr::internal::StackBuffer fVertWeights(parent.getMaxValence()); │ │ │ │ │ +485 │ │ │ │ │ +486 for (int face = 0; face < parent.getNumFaces(); ++face) { │ │ │ │ │ +487 │ │ │ │ │ +488 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getFaceChildVertex(face); │ │ │ │ │ +489 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ +490 continue; │ │ │ │ │ +491 │ │ │ │ │ +492 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ +face: │ │ │ │ │ +493 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fVerts = parent.getFaceVertices(face); │ │ │ │ │ +494 │ │ │ │ │ +495 Mask fMask(fVertWeights, 0, 0); │ │ │ │ │ +496 Vtr::internal::FaceInterface fHood(fVerts._s_i_z_e()); │ │ │ │ │ +497 │ │ │ │ │ +498 scheme.ComputeFaceVertexMask(fHood, fMask); │ │ │ │ │ +499 │ │ │ │ │ +500 // Apply the weights to the parent face's vertices: │ │ │ │ │ +501 dst[cVert].Clear(); │ │ │ │ │ +502 │ │ │ │ │ +503 for (int i = 0; i < fVerts._s_i_z_e(); ++i) { │ │ │ │ │ +504 │ │ │ │ │ +505 dst[cVert].AddWithWeight(src[fVerts[i]], fVertWeights[i]); │ │ │ │ │ +506 } │ │ │ │ │ +507 } │ │ │ │ │ +508} │ │ │ │ │ +509 │ │ │ │ │ +510template │ │ │ │ │ +511template │ │ │ │ │ +512inline void │ │ │ │ │ +513PrimvarRefinerReal::interpFromEdges(int level, T const & src, U & dst) │ │ │ │ │ +const { │ │ │ │ │ +514 │ │ │ │ │ +515 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +516 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ +517 Vtr::internal::Level const & child = refinement.child(); │ │ │ │ │ +518 │ │ │ │ │ +519 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +520 │ │ │ │ │ +521 Vtr::internal::EdgeInterface eHood(parent); │ │ │ │ │ +522 │ │ │ │ │ +523 Weight eVertWeights[2]; │ │ │ │ │ +524 Vtr::internal::StackBuffer eFaceWeights(parent.getMaxEdgeFaces │ │ │ │ │ +()); │ │ │ │ │ +525 │ │ │ │ │ +526 for (int edge = 0; edge < parent.getNumEdges(); ++edge) { │ │ │ │ │ +527 │ │ │ │ │ +528 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getEdgeChildVertex(edge); │ │ │ │ │ +529 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ +530 continue; │ │ │ │ │ +531 │ │ │ │ │ +532 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ +edge: │ │ │ │ │ +533 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = parent.getEdgeVertices(edge), │ │ │ │ │ +534 eFaces = parent.getEdgeFaces(edge); │ │ │ │ │ +535 │ │ │ │ │ +536 Mask eMask(eVertWeights, 0, eFaceWeights); │ │ │ │ │ +537 │ │ │ │ │ +538 eHood.SetIndex(edge); │ │ │ │ │ +539 │ │ │ │ │ +540 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = (parent.getEdgeSharpness(edge) > 0.0f) ? _S_d_c_:_: │ │ │ │ │ +_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E : Sdc::Crease::RULE_SMOOTH; │ │ │ │ │ +541 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = child.getVertexRule(cVert); │ │ │ │ │ +542 │ │ │ │ │ +543 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule); │ │ │ │ │ +544 │ │ │ │ │ +545 // Apply the weights to the parent edges's vertices and (if applicable) to │ │ │ │ │ +546 // the child vertices of its incident faces: │ │ │ │ │ +547 dst[cVert].Clear(); │ │ │ │ │ +548 dst[cVert].AddWithWeight(src[eVerts[0]], eVertWeights[0]); │ │ │ │ │ +549 dst[cVert].AddWithWeight(src[eVerts[1]], eVertWeights[1]); │ │ │ │ │ +550 │ │ │ │ │ +551 if (eMask.GetNumFaceWeights() > 0) { │ │ │ │ │ +552 │ │ │ │ │ +553 for (int i = 0; i < eFaces.size(); ++i) { │ │ │ │ │ +554 │ │ │ │ │ +555 if (eMask.AreFaceWeightsForFaceCenters()) { │ │ │ │ │ +556 assert(refinement.getNumChildVerticesFromFaces() > 0); │ │ │ │ │ +557 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(eFaces[i]); │ │ │ │ │ +558 │ │ │ │ │ +559 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ +560 dst[cVert].AddWithWeight(dst[cVertOfFace], eFaceWeights[i]); │ │ │ │ │ +561 } else { │ │ │ │ │ +562 _V_t_r_:_:_I_n_d_e_x pFace = eFaces[i]; │ │ │ │ │ +563 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y pFaceEdges = parent.getFaceEdges(pFace), │ │ │ │ │ +564 pFaceVerts = parent.getFaceVertices(pFace); │ │ │ │ │ +565 │ │ │ │ │ +566 int eInFace = 0; │ │ │ │ │ +567 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ; │ │ │ │ │ +568 │ │ │ │ │ +569 int vInFace = eInFace + 2; │ │ │ │ │ +570 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts._s_i_z_e(); │ │ │ │ │ +571 │ │ │ │ │ +572 _V_t_r_:_:_I_n_d_e_x pVertNext = pFaceVerts[vInFace]; │ │ │ │ │ +573 dst[cVert].AddWithWeight(src[pVertNext], eFaceWeights[i]); │ │ │ │ │ +574 } │ │ │ │ │ +575 } │ │ │ │ │ +576 } │ │ │ │ │ +577 } │ │ │ │ │ +578} │ │ │ │ │ +579 │ │ │ │ │ +580template │ │ │ │ │ +581template │ │ │ │ │ +582inline void │ │ │ │ │ +583PrimvarRefinerReal::interpFromVerts(int level, T const & src, U & dst) │ │ │ │ │ +const { │ │ │ │ │ +584 │ │ │ │ │ +585 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +586 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ +587 Vtr::internal::Level const & child = refinement.child(); │ │ │ │ │ +588 │ │ │ │ │ +589 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +590 │ │ │ │ │ +591 Vtr::internal::VertexInterface vHood(parent, child); │ │ │ │ │ +592 │ │ │ │ │ +593 Vtr::internal::StackBuffer weightBuffer(2*parent.getMaxValence │ │ │ │ │ +()); │ │ │ │ │ +594 │ │ │ │ │ +595 for (int vert = 0; vert < parent.getNumVertices(); ++vert) { │ │ │ │ │ +596 │ │ │ │ │ +597 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getVertexChildVertex(vert); │ │ │ │ │ +598 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ +599 continue; │ │ │ │ │ +600 │ │ │ │ │ +601 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ +edge: │ │ │ │ │ +602 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = parent.getVertexEdges(vert), │ │ │ │ │ +603 vFaces = parent.getVertexFaces(vert); │ │ │ │ │ +604 │ │ │ │ │ +605 Weight vVertWeight, │ │ │ │ │ +606 * vEdgeWeights = weightBuffer, │ │ │ │ │ +607 * vFaceWeights = vEdgeWeights + vEdges._s_i_z_e(); │ │ │ │ │ +608 │ │ │ │ │ +609 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights); │ │ │ │ │ +610 │ │ │ │ │ +611 vHood.SetIndex(vert, cVert); │ │ │ │ │ +612 │ │ │ │ │ +613 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = parent.getVertexRule(vert); │ │ │ │ │ +614 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = child.getVertexRule(cVert); │ │ │ │ │ +615 │ │ │ │ │ +616 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule); │ │ │ │ │ +617 │ │ │ │ │ +618 // Apply the weights to the parent vertex, the vertices opposite its │ │ │ │ │ +incident │ │ │ │ │ +619 // edges, and the child vertices of its incident faces: │ │ │ │ │ +620 // │ │ │ │ │ +621 // In order to improve numerical precision, it's better to apply smaller │ │ │ │ │ +weights │ │ │ │ │ +622 // first, so begin with the face-weights followed by the edge-weights and │ │ │ │ │ +the │ │ │ │ │ +623 // vertex weight last. │ │ │ │ │ +624 dst[cVert].Clear(); │ │ │ │ │ +625 │ │ │ │ │ +626 if (vMask.GetNumFaceWeights() > 0) { │ │ │ │ │ +627 assert(vMask.AreFaceWeightsForFaceCenters()); │ │ │ │ │ +628 │ │ │ │ │ +629 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ +630 │ │ │ │ │ +631 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(vFaces[i]); │ │ │ │ │ +632 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ +633 dst[cVert].AddWithWeight(dst[cVertOfFace], vFaceWeights[i]); │ │ │ │ │ +634 } │ │ │ │ │ +635 } │ │ │ │ │ +636 if (vMask.GetNumEdgeWeights() > 0) { │ │ │ │ │ +637 │ │ │ │ │ +638 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ +639 │ │ │ │ │ +640 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = parent.getEdgeVertices(vEdges[i]); │ │ │ │ │ +641 _V_t_r_:_:_I_n_d_e_x pVertOppositeEdge = (eVerts[0] == vert) ? eVerts[1] : eVerts[0]; │ │ │ │ │ +642 │ │ │ │ │ +643 dst[cVert].AddWithWeight(src[pVertOppositeEdge], vEdgeWeights[i]); │ │ │ │ │ +644 } │ │ │ │ │ +645 } │ │ │ │ │ +646 dst[cVert].AddWithWeight(src[vert], vVertWeight); │ │ │ │ │ +647 } │ │ │ │ │ +648} │ │ │ │ │ +649 │ │ │ │ │ +650 │ │ │ │ │ +651// │ │ │ │ │ +652// Internal face-varying implementation details: │ │ │ │ │ +653// │ │ │ │ │ +654template │ │ │ │ │ +655template │ │ │ │ │ +656inline void │ │ │ │ │ +657PrimvarRefinerReal::interpFVarFromFaces(int level, T const & src, U & │ │ │ │ │ +dst, int channel) const { │ │ │ │ │ +658 │ │ │ │ │ +659 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +660 │ │ │ │ │ +661 if (refinement.getNumChildVerticesFromFaces() == 0) return; │ │ │ │ │ +662 │ │ │ │ │ +663 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +664 │ │ │ │ │ +665 Vtr::internal::Level const & parentLevel = refinement.parent(); │ │ │ │ │ +666 Vtr::internal::Level const & childLevel = refinement.child(); │ │ │ │ │ +667 │ │ │ │ │ +668 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +669 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +670 │ │ │ │ │ +671 Vtr::internal::StackBuffer fValueWeights │ │ │ │ │ +(parentLevel.getMaxValence()); │ │ │ │ │ +672 │ │ │ │ │ +673 for (int face = 0; face < parentLevel.getNumFaces(); ++face) { │ │ │ │ │ +674 │ │ │ │ │ +675 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getFaceChildVertex(face); │ │ │ │ │ +676 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ +677 continue; │ │ │ │ │ +678 │ │ │ │ │ +679 _V_t_r_:_:_I_n_d_e_x cVertValue = childFVar.getVertexValueOffset(cVert); │ │ │ │ │ +680 │ │ │ │ │ +681 // The only difference for face-varying here is that we get the values │ │ │ │ │ +associated │ │ │ │ │ +682 // with each face-vertex directly from the FVarLevel, rather than using the │ │ │ │ │ +parent │ │ │ │ │ +683 // face-vertices directly. If any face-vertex has any sibling values, then │ │ │ │ │ +we may │ │ │ │ │ +684 // get the wrong one using the face-vertex index directly. │ │ │ │ │ +685 │ │ │ │ │ +686 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ +face: │ │ │ │ │ +687 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fValues = parentFVar.getFaceValues(face); │ │ │ │ │ +688 │ │ │ │ │ +689 Mask fMask(fValueWeights, 0, 0); │ │ │ │ │ +690 Vtr::internal::FaceInterface fHood(fValues.size()); │ │ │ │ │ +691 │ │ │ │ │ +692 scheme.ComputeFaceVertexMask(fHood, fMask); │ │ │ │ │ +693 │ │ │ │ │ +694 // Apply the weights to the parent face's vertices: │ │ │ │ │ +695 dst[cVertValue].Clear(); │ │ │ │ │ +696 │ │ │ │ │ +697 for (int i = 0; i < fValues.size(); ++i) { │ │ │ │ │ +698 dst[cVertValue].AddWithWeight(src[fValues[i]], fValueWeights[i]); │ │ │ │ │ +699 } │ │ │ │ │ +700 } │ │ │ │ │ +701} │ │ │ │ │ +702 │ │ │ │ │ +703template │ │ │ │ │ +704template │ │ │ │ │ +705inline void │ │ │ │ │ +706PrimvarRefinerReal::interpFVarFromEdges(int level, T const & src, U & │ │ │ │ │ +dst, int channel) const { │ │ │ │ │ +707 │ │ │ │ │ +708 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +709 │ │ │ │ │ +710 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +711 │ │ │ │ │ +712 Vtr::internal::Level const & parentLevel = refinement.parent(); │ │ │ │ │ +713 Vtr::internal::Level const & childLevel = refinement.child(); │ │ │ │ │ +714 │ │ │ │ │ +715 Vtr::internal::FVarRefinement const & refineFVar = │ │ │ │ │ +refinement.getFVarRefinement(channel); │ │ │ │ │ +716 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +717 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +718 │ │ │ │ │ +719 // │ │ │ │ │ +720 // Allocate and initialize (if linearly interpolated) interpolation weights │ │ │ │ │ +for │ │ │ │ │ +721 // the edge mask: │ │ │ │ │ +722 // │ │ │ │ │ +723 Weight eVertWeights[2]; │ │ │ │ │ +724 Vtr::internal::StackBuffer eFaceWeights │ │ │ │ │ +(parentLevel.getMaxEdgeFaces()); │ │ │ │ │ +725 │ │ │ │ │ +726 Mask eMask(eVertWeights, 0, eFaceWeights); │ │ │ │ │ +727 │ │ │ │ │ +728 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == _S_d_c_:_: │ │ │ │ │ +_S_C_H_E_M_E___B_I_L_I_N_E_A_R); │ │ │ │ │ +729 if (isLinearFVar) { │ │ │ │ │ +730 eMask.SetNumVertexWeights(2); │ │ │ │ │ +731 eMask.SetNumEdgeWeights(0); │ │ │ │ │ +732 eMask.SetNumFaceWeights(0); │ │ │ │ │ +733 │ │ │ │ │ +734 eVertWeights[0] = 0.5f; │ │ │ │ │ +735 eVertWeights[1] = 0.5f; │ │ │ │ │ +736 } │ │ │ │ │ +737 │ │ │ │ │ +738 Vtr::internal::EdgeInterface eHood(parentLevel); │ │ │ │ │ +739 │ │ │ │ │ +740 for (int edge = 0; edge < parentLevel.getNumEdges(); ++edge) { │ │ │ │ │ +741 │ │ │ │ │ +742 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getEdgeChildVertex(edge); │ │ │ │ │ +743 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ +744 continue; │ │ │ │ │ +745 │ │ │ │ │ +746 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y cVertValues = childFVar.getVertexValues(cVert); │ │ │ │ │ +747 │ │ │ │ │ +748 bool fvarEdgeVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues │ │ │ │ │ +[0]); │ │ │ │ │ +749 if (fvarEdgeVertMatchesVertex) { │ │ │ │ │ +750 // │ │ │ │ │ +751 // If smoothly interpolated, compute new weights for the edge mask: │ │ │ │ │ +752 // │ │ │ │ │ +753 if (!isLinearFVar) { │ │ │ │ │ +754 eHood.SetIndex(edge); │ │ │ │ │ +755 │ │ │ │ │ +756 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = (parentLevel.getEdgeSharpness(edge) > 0.0f) │ │ │ │ │ +757 ? _S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E : Sdc::Crease::RULE_SMOOTH; │ │ │ │ │ +758 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = childLevel.getVertexRule(cVert); │ │ │ │ │ +759 │ │ │ │ │ +760 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule); │ │ │ │ │ +761 } │ │ │ │ │ +762 │ │ │ │ │ +763 // Apply the weights to the parent edge's vertices and (if applicable) to │ │ │ │ │ +764 // the child vertices of its incident faces: │ │ │ │ │ +765 // │ │ │ │ │ +766 // Even though the face-varying topology matches the vertex topology, we │ │ │ │ │ +need │ │ │ │ │ +767 // to be careful here when getting values corresponding to the two end- │ │ │ │ │ +vertices. │ │ │ │ │ +768 // While the edge may be continuous, the vertices at their ends may have │ │ │ │ │ +769 // discontinuities elsewhere in their neighborhood (i.e. on the "other │ │ │ │ │ +side" │ │ │ │ │ +770 // of the end-vertex) and so have sibling values associated with them. In │ │ │ │ │ +most │ │ │ │ │ +771 // cases the topology for an end-vertex will match and we can use it │ │ │ │ │ +directly, │ │ │ │ │ +772 // but we must still check and retrieve as needed. │ │ │ │ │ +773 // │ │ │ │ │ +774 // Indices for values corresponding to face-vertices are guaranteed to │ │ │ │ │ +match, │ │ │ │ │ +775 // so we can use the child-vertex indices directly. │ │ │ │ │ +776 // │ │ │ │ │ +777 // And by "directly", we always use getVertexValue(vertexIndex) to │ │ │ │ │ +reference │ │ │ │ │ +778 // values in the "src" to account for the possible indirection that may │ │ │ │ │ +exist at │ │ │ │ │ +779 // level 0 -- where there may be fewer values than vertices and an │ │ │ │ │ +additional │ │ │ │ │ +780 // indirection is necessary. We can use a vertex index directly for "dst" │ │ │ │ │ +when │ │ │ │ │ +781 // it matches. │ │ │ │ │ +782 // │ │ │ │ │ +783 _V_t_r_:_:_I_n_d_e_x eVertValues[2]; │ │ │ │ │ +784 │ │ │ │ │ +785 parentFVar.getEdgeFaceValues(edge, 0, eVertValues); │ │ │ │ │ +786 │ │ │ │ │ +787 _I_n_d_e_x cVertValue = cVertValues[0]; │ │ │ │ │ +788 │ │ │ │ │ +789 dst[cVertValue].Clear(); │ │ │ │ │ +790 dst[cVertValue].AddWithWeight(src[eVertValues[0]], eVertWeights[0]); │ │ │ │ │ +791 dst[cVertValue].AddWithWeight(src[eVertValues[1]], eVertWeights[1]); │ │ │ │ │ +792 │ │ │ │ │ +793 if (eMask.GetNumFaceWeights() > 0) { │ │ │ │ │ +794 │ │ │ │ │ +795 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eFaces = parentLevel.getEdgeFaces(edge); │ │ │ │ │ +796 │ │ │ │ │ +797 for (int i = 0; i < eFaces.size(); ++i) { │ │ │ │ │ +798 if (eMask.AreFaceWeightsForFaceCenters()) { │ │ │ │ │ +799 │ │ │ │ │ +800 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(eFaces[i]); │ │ │ │ │ +801 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ +802 │ │ │ │ │ +803 _V_t_r_:_:_I_n_d_e_x cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace); │ │ │ │ │ +804 dst[cVertValue].AddWithWeight(dst[cValueOfFace], eFaceWeights[i]); │ │ │ │ │ +805 } else { │ │ │ │ │ +806 _V_t_r_:_:_I_n_d_e_x pFace = eFaces[i]; │ │ │ │ │ +807 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y pFaceEdges = parentLevel.getFaceEdges(pFace), │ │ │ │ │ +808 pFaceVerts = parentLevel.getFaceVertices(pFace); │ │ │ │ │ +809 │ │ │ │ │ +810 int eInFace = 0; │ │ │ │ │ +811 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ; │ │ │ │ │ +812 │ │ │ │ │ +813 // Edge "i" spans vertices [i,i+1] so we want i+2... │ │ │ │ │ +814 int vInFace = eInFace + 2; │ │ │ │ │ +815 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts._s_i_z_e(); │ │ │ │ │ +816 │ │ │ │ │ +817 _V_t_r_:_:_I_n_d_e_x pValueNext = parentFVar.getFaceValues(pFace)[vInFace]; │ │ │ │ │ +818 dst[cVertValue].AddWithWeight(src[pValueNext], eFaceWeights[i]); │ │ │ │ │ +819 } │ │ │ │ │ +820 } │ │ │ │ │ +821 } │ │ │ │ │ +822 } else { │ │ │ │ │ +823 // │ │ │ │ │ +824 // Mismatched edge-verts should just be linearly interpolated between the │ │ │ │ │ +pairs of │ │ │ │ │ +825 // values for each sibling of the child edge-vertex -- the question is: │ │ │ │ │ +which face │ │ │ │ │ +826 // holds that pair of values for a given sibling? │ │ │ │ │ +827 // │ │ │ │ │ +828 // In the manifold case, the sibling and edge-face indices will correspond. │ │ │ │ │ +We │ │ │ │ │ +829 // will eventually need to update this to account for > 3 incident faces. │ │ │ │ │ +830 // │ │ │ │ │ +831 for (int i = 0; i < cVertValues.size(); ++i) { │ │ │ │ │ +832 _V_t_r_:_:_I_n_d_e_x eVertValues[2]; │ │ │ │ │ +833 int eFaceIndex = refineFVar.getChildValueParentSource(cVert, i); │ │ │ │ │ +834 assert(eFaceIndex == i); │ │ │ │ │ +835 │ │ │ │ │ +836 parentFVar.getEdgeFaceValues(edge, eFaceIndex, eVertValues); │ │ │ │ │ +837 │ │ │ │ │ +838 _I_n_d_e_x cVertValue = cVertValues[i]; │ │ │ │ │ +839 │ │ │ │ │ +840 dst[cVertValue].Clear(); │ │ │ │ │ +841 dst[cVertValue].AddWithWeight(src[eVertValues[0]], 0.5); │ │ │ │ │ +842 dst[cVertValue].AddWithWeight(src[eVertValues[1]], 0.5); │ │ │ │ │ +843 } │ │ │ │ │ +844 } │ │ │ │ │ +845 } │ │ │ │ │ +846} │ │ │ │ │ +847 │ │ │ │ │ +848template │ │ │ │ │ +849template │ │ │ │ │ +850inline void │ │ │ │ │ +851PrimvarRefinerReal::interpFVarFromVerts(int level, T const & src, U & │ │ │ │ │ +dst, int channel) const { │ │ │ │ │ +852 │ │ │ │ │ +853 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ +(level-1); │ │ │ │ │ +854 │ │ │ │ │ +855 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +856 │ │ │ │ │ +857 Vtr::internal::Level const & parentLevel = refinement.parent(); │ │ │ │ │ +858 Vtr::internal::Level const & childLevel = refinement.child(); │ │ │ │ │ +859 │ │ │ │ │ +860 Vtr::internal::FVarRefinement const & refineFVar = │ │ │ │ │ +refinement.getFVarRefinement(channel); │ │ │ │ │ +861 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +862 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +863 │ │ │ │ │ +864 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == _S_d_c_:_: │ │ │ │ │ +_S_C_H_E_M_E___B_I_L_I_N_E_A_R); │ │ │ │ │ +865 │ │ │ │ │ +866 Vtr::internal::StackBuffer weightBuffer │ │ │ │ │ +(2*parentLevel.getMaxValence()); │ │ │ │ │ +867 │ │ │ │ │ +868 Vtr::internal::StackBuffer vEdgeValues │ │ │ │ │ +(parentLevel.getMaxValence()); │ │ │ │ │ +869 │ │ │ │ │ +870 Vtr::internal::VertexInterface vHood(parentLevel, childLevel); │ │ │ │ │ +871 │ │ │ │ │ +872 for (int vert = 0; vert < parentLevel.getNumVertices(); ++vert) { │ │ │ │ │ +873 │ │ │ │ │ +874 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getVertexChildVertex(vert); │ │ │ │ │ +875 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ +876 continue; │ │ │ │ │ +877 │ │ │ │ │ +878 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y pVertValues = parentFVar.getVertexValues(vert), │ │ │ │ │ +879 cVertValues = childFVar.getVertexValues(cVert); │ │ │ │ │ +880 │ │ │ │ │ +881 bool fvarVertVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues │ │ │ │ │ +[0]); │ │ │ │ │ +882 if (isLinearFVar && fvarVertVertMatchesVertex) { │ │ │ │ │ +883 dst[cVertValues[0]].Clear(); │ │ │ │ │ +884 dst[cVertValues[0]].AddWithWeight(src[pVertValues[0]], 1.0f); │ │ │ │ │ +885 continue; │ │ │ │ │ +886 } │ │ │ │ │ +887 │ │ │ │ │ +888 if (fvarVertVertMatchesVertex) { │ │ │ │ │ +889 // │ │ │ │ │ +890 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ +edge: │ │ │ │ │ +891 // │ │ │ │ │ +892 // (We really need to encapsulate this somewhere else for use here and in │ │ │ │ │ +the │ │ │ │ │ +893 // general case) │ │ │ │ │ +894 // │ │ │ │ │ +895 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = parentLevel.getVertexEdges(vert); │ │ │ │ │ +896 │ │ │ │ │ +897 Weight vVertWeight; │ │ │ │ │ +898 Weight * vEdgeWeights = weightBuffer; │ │ │ │ │ +899 Weight * vFaceWeights = vEdgeWeights + vEdges._s_i_z_e(); │ │ │ │ │ +900 │ │ │ │ │ +901 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights); │ │ │ │ │ +902 │ │ │ │ │ +903 vHood.SetIndex(vert, cVert); │ │ │ │ │ +904 │ │ │ │ │ +905 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = parentLevel.getVertexRule(vert); │ │ │ │ │ +906 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = childLevel.getVertexRule(cVert); │ │ │ │ │ +907 │ │ │ │ │ +908 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule); │ │ │ │ │ +909 │ │ │ │ │ +910 // Apply the weights to the parent vertex, the vertices opposite its │ │ │ │ │ +incident │ │ │ │ │ +911 // edges, and the child vertices of its incident faces: │ │ │ │ │ +912 // │ │ │ │ │ +913 // Even though the face-varying topology matches the vertex topology, we │ │ │ │ │ +need │ │ │ │ │ +914 // to be careful here when getting values corresponding to vertices at the │ │ │ │ │ +915 // ends of edges. While the edge may be continuous, the end vertex may have │ │ │ │ │ +916 // discontinuities elsewhere in their neighborhood (i.e. on the "other │ │ │ │ │ +side" │ │ │ │ │ +917 // of the end-vertex) and so have sibling values associated with them. In │ │ │ │ │ +most │ │ │ │ │ +918 // cases the topology for an end-vertex will match and we can use it │ │ │ │ │ +directly, │ │ │ │ │ +919 // but we must still check and retrieve as needed. │ │ │ │ │ +920 // │ │ │ │ │ +921 // Indices for values corresponding to face-vertices are guaranteed to │ │ │ │ │ +match, │ │ │ │ │ +922 // so we can use the child-vertex indices directly. │ │ │ │ │ +923 // │ │ │ │ │ +924 // And by "directly", we always use getVertexValue(vertexIndex) to │ │ │ │ │ +reference │ │ │ │ │ +925 // values in the "src" to account for the possible indirection that may │ │ │ │ │ +exist at │ │ │ │ │ +926 // level 0 -- where there may be fewer values than vertices and an │ │ │ │ │ +additional │ │ │ │ │ +927 // indirection is necessary. We can use a vertex index directly for "dst" │ │ │ │ │ +when │ │ │ │ │ +928 // it matches. │ │ │ │ │ +929 // │ │ │ │ │ +930 // As with applying the mask to vertex data, in order to improve numerical │ │ │ │ │ +931 // precision, it's better to apply smaller weights first, so begin with the │ │ │ │ │ +932 // face-weights followed by the edge-weights and the vertex weight last. │ │ │ │ │ +933 // │ │ │ │ │ +934 _V_t_r_:_:_I_n_d_e_x pVertValue = pVertValues[0]; │ │ │ │ │ +935 _V_t_r_:_:_I_n_d_e_x cVertValue = cVertValues[0]; │ │ │ │ │ +936 │ │ │ │ │ +937 dst[cVertValue].Clear(); │ │ │ │ │ +938 if (vMask.GetNumFaceWeights() > 0) { │ │ │ │ │ +939 assert(vMask.AreFaceWeightsForFaceCenters()); │ │ │ │ │ +940 │ │ │ │ │ +941 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vFaces = parentLevel.getVertexFaces(vert); │ │ │ │ │ +942 │ │ │ │ │ +943 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ +944 │ │ │ │ │ +945 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(vFaces[i]); │ │ │ │ │ +946 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ +947 │ │ │ │ │ +948 _V_t_r_:_:_I_n_d_e_x cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace); │ │ │ │ │ +949 dst[cVertValue].AddWithWeight(dst[cValueOfFace], vFaceWeights[i]); │ │ │ │ │ +950 } │ │ │ │ │ +951 } │ │ │ │ │ +952 if (vMask.GetNumEdgeWeights() > 0) { │ │ │ │ │ +953 │ │ │ │ │ +954 parentFVar.getVertexEdgeValues(vert, vEdgeValues); │ │ │ │ │ +955 │ │ │ │ │ +956 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ +957 dst[cVertValue].AddWithWeight(src[vEdgeValues[i]], vEdgeWeights[i]); │ │ │ │ │ +958 } │ │ │ │ │ +959 } │ │ │ │ │ +960 dst[cVertValue].AddWithWeight(src[pVertValue], vVertWeight); │ │ │ │ │ +961 } else { │ │ │ │ │ +962 // │ │ │ │ │ +963 // Each FVar value associated with a vertex will be either a corner or a │ │ │ │ │ +crease, │ │ │ │ │ +964 // or potentially in transition from corner to crease: │ │ │ │ │ +965 // - if the CHILD is a corner, there can be no transition so we have a │ │ │ │ │ +corner │ │ │ │ │ +966 // - otherwise if the PARENT is a crease, both will be creases (no │ │ │ │ │ +transition) │ │ │ │ │ +967 // - otherwise the parent must be a corner and the child a crease │ │ │ │ │ +(transition) │ │ │ │ │ +968 // │ │ │ │ │ +969 Vtr::internal::FVarLevel::ConstValueTagArray pValueTags = │ │ │ │ │ +parentFVar.getVertexValueTags(vert); │ │ │ │ │ +970 Vtr::internal::FVarLevel::ConstValueTagArray cValueTags = │ │ │ │ │ +childFVar.getVertexValueTags(cVert); │ │ │ │ │ +971 │ │ │ │ │ +972 for (int cSiblingIndex = 0; cSiblingIndex < cVertValues.size(); │ │ │ │ │ +++cSiblingIndex) { │ │ │ │ │ +973 int pSiblingIndex = refineFVar.getChildValueParentSource(cVert, │ │ │ │ │ +cSiblingIndex); │ │ │ │ │ +974 assert(pSiblingIndex == cSiblingIndex); │ │ │ │ │ +975 │ │ │ │ │ +976 typedef Vtr::internal::FVarLevel::Sibling SiblingIntType; │ │ │ │ │ +977 │ │ │ │ │ +978 SiblingIntType cSibling = (SiblingIntType) cSiblingIndex; │ │ │ │ │ +979 SiblingIntType pSibling = (SiblingIntType) pSiblingIndex; │ │ │ │ │ +980 │ │ │ │ │ +981 _V_t_r_:_:_I_n_d_e_x pVertValue = pVertValues[pSibling]; │ │ │ │ │ +982 _V_t_r_:_:_I_n_d_e_x cVertValue = cVertValues[cSibling]; │ │ │ │ │ +983 │ │ │ │ │ +984 dst[cVertValue].Clear(); │ │ │ │ │ +985 if (isLinearFVar || cValueTags[cSibling].isCorner()) { │ │ │ │ │ +986 dst[cVertValue].AddWithWeight(src[pVertValue], 1.0f); │ │ │ │ │ +987 } else { │ │ │ │ │ +988 // │ │ │ │ │ +989 // We have either a crease or a transition from corner to crease -- in │ │ │ │ │ +990 // either case, we need the end values for the full/fractional crease: │ │ │ │ │ +991 // │ │ │ │ │ +992 _I_n_d_e_x pEndValues[2]; │ │ │ │ │ +993 parentFVar.getVertexCreaseEndValues(vert, pSibling, pEndValues); │ │ │ │ │ +994 │ │ │ │ │ +995 Weight vWeight = 0.75f; │ │ │ │ │ +996 Weight eWeight = 0.125f; │ │ │ │ │ +997 │ │ │ │ │ +998 // │ │ │ │ │ +999 // If semi-sharp we need to apply fractional weighting -- if made sharp │ │ │ │ │ +because │ │ │ │ │ +1000 // of the other sibling (dependent-sharp) use the fractional weight from │ │ │ │ │ +that │ │ │ │ │ +1001 // other sibling (should only occur when there are 2): │ │ │ │ │ +1002 // │ │ │ │ │ +1003 if (pValueTags[pSibling].isSemiSharp()) { │ │ │ │ │ +1004 Weight wCorner = pValueTags[pSibling].isDepSharp() │ │ │ │ │ +1005 ? refineFVar.getFractionalWeight(vert, !pSibling, cVert, !cSibling) │ │ │ │ │ +1006 : refineFVar.getFractionalWeight(vert, pSibling, cVert, cSibling); │ │ │ │ │ +1007 Weight wCrease = 1.0f - wCorner; │ │ │ │ │ +1008 │ │ │ │ │ +1009 vWeight = wCrease * 0.75f + wCorner; │ │ │ │ │ +1010 eWeight = wCrease * 0.125f; │ │ │ │ │ +1011 } │ │ │ │ │ +1012 dst[cVertValue].AddWithWeight(src[pEndValues[0]], eWeight); │ │ │ │ │ +1013 dst[cVertValue].AddWithWeight(src[pEndValues[1]], eWeight); │ │ │ │ │ +1014 dst[cVertValue].AddWithWeight(src[pVertValue], vWeight); │ │ │ │ │ +1015 } │ │ │ │ │ +1016 } │ │ │ │ │ +1017 } │ │ │ │ │ +1018 } │ │ │ │ │ +1019} │ │ │ │ │ +1020 │ │ │ │ │ +1021template │ │ │ │ │ +1022template │ │ │ │ │ +1023inline void │ │ │ │ │ +1024PrimvarRefinerReal::limit(T const & src, U & dstPos, U1 * dstTan1Ptr, │ │ │ │ │ +U2 * dstTan2Ptr) const { │ │ │ │ │ +1025 │ │ │ │ │ +1026 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +1027 │ │ │ │ │ +1028 Vtr::internal::Level const & level = _refiner.getLevel │ │ │ │ │ +(_refiner.GetMaxLevel()); │ │ │ │ │ +1029 │ │ │ │ │ +1030 int maxWeightsPerMask = 1 + 2 * level.getMaxValence(); │ │ │ │ │ +1031 bool hasTangents = (dstTan1Ptr && dstTan2Ptr); │ │ │ │ │ +1032 int numMasks = 1 + (hasTangents ? 2 : 0); │ │ │ │ │ +1033 │ │ │ │ │ +1034 Vtr::internal::StackBuffer indexBuffer(maxWeightsPerMask); │ │ │ │ │ +1035 Vtr::internal::StackBuffer weightBuffer(numMasks * │ │ │ │ │ +maxWeightsPerMask); │ │ │ │ │ +1036 │ │ │ │ │ +1037 Weight * vPosWeights = weightBuffer, │ │ │ │ │ +1038 * ePosWeights = vPosWeights + 1, │ │ │ │ │ +1039 * fPosWeights = ePosWeights + level.getMaxValence(); │ │ │ │ │ +1040 Weight * vTan1Weights = vPosWeights + maxWeightsPerMask, │ │ │ │ │ +1041 * eTan1Weights = ePosWeights + maxWeightsPerMask, │ │ │ │ │ +1042 * fTan1Weights = fPosWeights + maxWeightsPerMask; │ │ │ │ │ +1043 Weight * vTan2Weights = vTan1Weights + maxWeightsPerMask, │ │ │ │ │ +1044 * eTan2Weights = eTan1Weights + maxWeightsPerMask, │ │ │ │ │ +1045 * fTan2Weights = fTan1Weights + maxWeightsPerMask; │ │ │ │ │ +1046 │ │ │ │ │ +1047 Mask posMask( vPosWeights, ePosWeights, fPosWeights); │ │ │ │ │ +1048 Mask tan1Mask(vTan1Weights, eTan1Weights, fTan1Weights); │ │ │ │ │ +1049 Mask tan2Mask(vTan2Weights, eTan2Weights, fTan2Weights); │ │ │ │ │ +1050 │ │ │ │ │ +1051 // This is a bit obscure -- assigning both parent and child as last level │ │ │ │ │ +-- but │ │ │ │ │ +1052 // this mask type was intended for another purpose. Consider one for the │ │ │ │ │ +limit: │ │ │ │ │ +1053 Vtr::internal::VertexInterface vHood(level, level); │ │ │ │ │ +1054 │ │ │ │ │ +1055 for (int vert = 0; vert < level.getNumVertices(); ++vert) { │ │ │ │ │ +1056 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = level.getVertexEdges(vert); │ │ │ │ │ +1057 │ │ │ │ │ +1058 // Incomplete vertices (present in sparse refinement) do not have their │ │ │ │ │ +full │ │ │ │ │ +1059 // topological neighborhood to determine a proper limit -- just leave the │ │ │ │ │ +1060 // vertex at the refined location and continue to the next: │ │ │ │ │ +1061 if (level.getVertexTag(vert)._incomplete || (vEdges.size() == 0)) { │ │ │ │ │ +1062 dstPos[vert].Clear(); │ │ │ │ │ +1063 dstPos[vert].AddWithWeight(src[vert], 1.0); │ │ │ │ │ +1064 if (hasTangents) { │ │ │ │ │ +1065 (*dstTan1Ptr)[vert].Clear(); │ │ │ │ │ +1066 (*dstTan2Ptr)[vert].Clear(); │ │ │ │ │ +1067 } │ │ │ │ │ +1068 continue; │ │ │ │ │ +1069 } │ │ │ │ │ +1070 │ │ │ │ │ +1071 // │ │ │ │ │ +1072 // Limit masks require the subdivision Rule for the vertex in order to │ │ │ │ │ +deal │ │ │ │ │ +1073 // with infinitely sharp features correctly -- including boundaries and │ │ │ │ │ +corners. │ │ │ │ │ +1074 // The vertex neighborhood is minimally defined with vertex and edge │ │ │ │ │ +counts. │ │ │ │ │ +1075 // │ │ │ │ │ +1076 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e vRule = level.getVertexRule(vert); │ │ │ │ │ +1077 │ │ │ │ │ +1078 // This is a bit obscure -- child vertex index will be ignored here │ │ │ │ │ +1079 vHood.SetIndex(vert, vert); │ │ │ │ │ +1080 │ │ │ │ │ +1081 if (hasTangents) { │ │ │ │ │ +1082 scheme.ComputeVertexLimitMask(vHood, posMask, tan1Mask, tan2Mask, vRule); │ │ │ │ │ +1083 } else { │ │ │ │ │ +1084 scheme.ComputeVertexLimitMask(vHood, posMask, vRule); │ │ │ │ │ +1085 } │ │ │ │ │ +1086 │ │ │ │ │ +1087 // │ │ │ │ │ +1088 // Gather the neighboring vertices of this vertex -- the vertices opposite │ │ │ │ │ +its │ │ │ │ │ +1089 // incident edges, and the opposite vertices of its incident faces: │ │ │ │ │ +1090 // │ │ │ │ │ +1091 _I_n_d_e_x * eIndices = indexBuffer; │ │ │ │ │ +1092 _I_n_d_e_x * fIndices = indexBuffer + vEdges._s_i_z_e(); │ │ │ │ │ +1093 │ │ │ │ │ +1094 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ +1095 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = level.getEdgeVertices(vEdges[i]); │ │ │ │ │ +1096 │ │ │ │ │ +1097 eIndices[i] = (eVerts[0] == vert) ? eVerts[1] : eVerts[0]; │ │ │ │ │ +1098 } │ │ │ │ │ +1099 if (posMask.GetNumFaceWeights() || (hasTangents && │ │ │ │ │ +tan1Mask.GetNumFaceWeights())) { │ │ │ │ │ +1100 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vFaces = level.getVertexFaces(vert); │ │ │ │ │ +1101 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y vInFace = level.getVertexFaceLocalIndices(vert); │ │ │ │ │ +1102 │ │ │ │ │ +1103 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ +1104 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fVerts = level.getFaceVertices(vFaces[i]); │ │ │ │ │ +1105 │ │ │ │ │ +1106 _L_o_c_a_l_I_n_d_e_x vOppInFace = (vInFace[i] + 2); │ │ │ │ │ +1107 if (vOppInFace >= fVerts.size()) vOppInFace -= (_L_o_c_a_l_I_n_d_e_x)fVerts._s_i_z_e(); │ │ │ │ │ +1108 │ │ │ │ │ +1109 fIndices[i] = level.getFaceVertices(vFaces[i])[vOppInFace]; │ │ │ │ │ +1110 } │ │ │ │ │ +1111 } │ │ │ │ │ +1112 │ │ │ │ │ +1113 // │ │ │ │ │ +1114 // Combine the weights and indices for position and tangents. As with │ │ │ │ │ +applying │ │ │ │ │ +1115 // refinement masks to vertex data, in order to improve numerical │ │ │ │ │ +precision, it's │ │ │ │ │ +1116 // better to apply smaller weights first, so begin with the face-weights │ │ │ │ │ +followed │ │ │ │ │ +1117 // by the edge-weights and the vertex weight last. │ │ │ │ │ +1118 // │ │ │ │ │ +1119 dstPos[vert].Clear(); │ │ │ │ │ +1120 for (int i = 0; i < posMask.GetNumFaceWeights(); ++i) { │ │ │ │ │ +1121 dstPos[vert].AddWithWeight(src[fIndices[i]], fPosWeights[i]); │ │ │ │ │ +1122 } │ │ │ │ │ +1123 for (int i = 0; i < posMask.GetNumEdgeWeights(); ++i) { │ │ │ │ │ +1124 dstPos[vert].AddWithWeight(src[eIndices[i]], ePosWeights[i]); │ │ │ │ │ +1125 } │ │ │ │ │ +1126 dstPos[vert].AddWithWeight(src[vert], vPosWeights[0]); │ │ │ │ │ +1127 │ │ │ │ │ +1128 // │ │ │ │ │ +1129 // Apply the tangent masks -- both will have the same number of weights │ │ │ │ │ +and │ │ │ │ │ +1130 // indices (one tangent may be "padded" to accommodate the other), but │ │ │ │ │ +these │ │ │ │ │ +1131 // may differ from those of the position: │ │ │ │ │ +1132 // │ │ │ │ │ +1133 if (hasTangents) { │ │ │ │ │ +1134 assert(tan1Mask.GetNumFaceWeights() == tan2Mask.GetNumFaceWeights()); │ │ │ │ │ +1135 assert(tan1Mask.GetNumEdgeWeights() == tan2Mask.GetNumEdgeWeights()); │ │ │ │ │ +1136 │ │ │ │ │ +1137 U1 & dstTan1 = *dstTan1Ptr; │ │ │ │ │ +1138 U2 & dstTan2 = *dstTan2Ptr; │ │ │ │ │ +1139 │ │ │ │ │ +1140 dstTan1[vert].Clear(); │ │ │ │ │ +1141 dstTan2[vert].Clear(); │ │ │ │ │ +1142 for (int i = 0; i < tan1Mask.GetNumFaceWeights(); ++i) { │ │ │ │ │ +1143 dstTan1[vert].AddWithWeight(src[fIndices[i]], fTan1Weights[i]); │ │ │ │ │ +1144 dstTan2[vert].AddWithWeight(src[fIndices[i]], fTan2Weights[i]); │ │ │ │ │ +1145 } │ │ │ │ │ +1146 for (int i = 0; i < tan1Mask.GetNumEdgeWeights(); ++i) { │ │ │ │ │ +1147 dstTan1[vert].AddWithWeight(src[eIndices[i]], eTan1Weights[i]); │ │ │ │ │ +1148 dstTan2[vert].AddWithWeight(src[eIndices[i]], eTan2Weights[i]); │ │ │ │ │ +1149 } │ │ │ │ │ +1150 dstTan1[vert].AddWithWeight(src[vert], vTan1Weights[0]); │ │ │ │ │ +1151 dstTan2[vert].AddWithWeight(src[vert], vTan2Weights[0]); │ │ │ │ │ +1152 } │ │ │ │ │ +1153 } │ │ │ │ │ +1154} │ │ │ │ │ +1155 │ │ │ │ │ +1156template │ │ │ │ │ +1157template │ │ │ │ │ +1158inline void │ │ │ │ │ +1159PrimvarRefinerReal::limitFVar(T const & src, U & dst, int channel) │ │ │ │ │ +const { │ │ │ │ │ +1160 │ │ │ │ │ +1161 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ +1162 │ │ │ │ │ +1163 Vtr::internal::Level const & level = _refiner.getLevel │ │ │ │ │ +(_refiner.GetMaxLevel()); │ │ │ │ │ +1164 Vtr::internal::FVarLevel const & fvarChannel = level.getFVarLevel │ │ │ │ │ +(channel); │ │ │ │ │ +1165 │ │ │ │ │ +1166 int maxWeightsPerMask = 1 + 2 * level.getMaxValence(); │ │ │ │ │ +1167 │ │ │ │ │ +1168 Vtr::internal::StackBuffer weightBuffer(maxWeightsPerMask); │ │ │ │ │ +1169 Vtr::internal::StackBuffer vEdgeBuffer(level.getMaxValence()); │ │ │ │ │ +1170 │ │ │ │ │ +1171 // This is a bit obscure -- assign both parent and child as last level │ │ │ │ │ +1172 Vtr::internal::VertexInterface vHood(level, level); │ │ │ │ │ +1173 │ │ │ │ │ +1174 for (int vert = 0; vert < level.getNumVertices(); ++vert) { │ │ │ │ │ +1175 │ │ │ │ │ +1176 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = level.getVertexEdges(vert); │ │ │ │ │ +1177 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vValues = fvarChannel.getVertexValues(vert); │ │ │ │ │ +1178 │ │ │ │ │ +1179 // Incomplete vertices (present in sparse refinement) do not have their │ │ │ │ │ +full │ │ │ │ │ +1180 // topological neighborhood to determine a proper limit -- just leave the │ │ │ │ │ +1181 // values (perhaps more than one per vertex) at the refined location. │ │ │ │ │ +1182 // │ │ │ │ │ +1183 // The same can be done if the face-varying channel is purely linear. │ │ │ │ │ +1184 // │ │ │ │ │ +1185 bool isIncomplete = (level.getVertexTag(vert)._incomplete || (vEdges.size │ │ │ │ │ +() == 0)); │ │ │ │ │ +1186 if (isIncomplete || fvarChannel.isLinear()) { │ │ │ │ │ +1187 for (int i = 0; i < vValues.size(); ++i) { │ │ │ │ │ +1188 _V_t_r_:_:_I_n_d_e_x vValue = vValues[i]; │ │ │ │ │ +1189 │ │ │ │ │ +1190 dst[vValue].Clear(); │ │ │ │ │ +1191 dst[vValue].AddWithWeight(src[vValue], 1.0f); │ │ │ │ │ +1192 } │ │ │ │ │ +1193 continue; │ │ │ │ │ +1194 } │ │ │ │ │ +1195 │ │ │ │ │ +1196 bool fvarVertMatchesVertex = fvarChannel.valueTopologyMatches(vValues[0]); │ │ │ │ │ +1197 if (fvarVertMatchesVertex) { │ │ │ │ │ +1198 │ │ │ │ │ +1199 // Assign the mask weights to the common buffer and compute the mask: │ │ │ │ │ +1200 // │ │ │ │ │ +1201 Weight * vWeights = weightBuffer, │ │ │ │ │ +1202 * eWeights = vWeights + 1, │ │ │ │ │ +1203 * fWeights = eWeights + vEdges._s_i_z_e(); │ │ │ │ │ +1204 │ │ │ │ │ +1205 Mask vMask(vWeights, eWeights, fWeights); │ │ │ │ │ +1206 │ │ │ │ │ +1207 vHood.SetIndex(vert, vert); │ │ │ │ │ +1208 │ │ │ │ │ +1209 scheme.ComputeVertexLimitMask(vHood, vMask, level.getVertexRule(vert)); │ │ │ │ │ +1210 │ │ │ │ │ +1211 // │ │ │ │ │ +1212 // Apply mask to corresponding FVar values for neighboring vertices: │ │ │ │ │ +1213 // │ │ │ │ │ +1214 _V_t_r_:_:_I_n_d_e_x vValue = vValues[0]; │ │ │ │ │ +1215 │ │ │ │ │ +1216 dst[vValue].Clear(); │ │ │ │ │ +1217 if (vMask.GetNumFaceWeights() > 0) { │ │ │ │ │ +1218 assert(!vMask.AreFaceWeightsForFaceCenters()); │ │ │ │ │ +1219 │ │ │ │ │ +1220 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vFaces = level.getVertexFaces(vert); │ │ │ │ │ +1221 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y vInFace = level.getVertexFaceLocalIndices(vert); │ │ │ │ │ +1222 │ │ │ │ │ +1223 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ +1224 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y faceValues = fvarChannel.getFaceValues(vFaces[i]); │ │ │ │ │ +1225 _L_o_c_a_l_I_n_d_e_x vOppInFace = vInFace[i] + 2; │ │ │ │ │ +1226 if (vOppInFace >= faceValues.size()) vOppInFace -= faceValues._s_i_z_e(); │ │ │ │ │ +1227 │ │ │ │ │ +1228 _I_n_d_e_x vValueOppositeFace = faceValues[vOppInFace]; │ │ │ │ │ +1229 │ │ │ │ │ +1230 dst[vValue].AddWithWeight(src[vValueOppositeFace], fWeights[i]); │ │ │ │ │ +1231 } │ │ │ │ │ +1232 } │ │ │ │ │ +1233 if (vMask.GetNumEdgeWeights() > 0) { │ │ │ │ │ +1234 _I_n_d_e_x * vEdgeValues = vEdgeBuffer; │ │ │ │ │ +1235 fvarChannel.getVertexEdgeValues(vert, vEdgeValues); │ │ │ │ │ +1236 │ │ │ │ │ +1237 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ +1238 dst[vValue].AddWithWeight(src[vEdgeValues[i]], eWeights[i]); │ │ │ │ │ +1239 } │ │ │ │ │ +1240 } │ │ │ │ │ +1241 dst[vValue].AddWithWeight(src[vValue], vWeights[0]); │ │ │ │ │ +1242 } else { │ │ │ │ │ +1243 // │ │ │ │ │ +1244 // Sibling FVar values associated with a vertex will be either a corner or │ │ │ │ │ +a crease: │ │ │ │ │ +1245 // │ │ │ │ │ +1246 for (int i = 0; i < vValues.size(); ++i) { │ │ │ │ │ +1247 _V_t_r_:_:_I_n_d_e_x vValue = vValues[i]; │ │ │ │ │ +1248 │ │ │ │ │ +1249 dst[vValue].Clear(); │ │ │ │ │ +1250 if (fvarChannel.getValueTag(vValue).isCorner()) { │ │ │ │ │ +1251 dst[vValue].AddWithWeight(src[vValue], 1.0f); │ │ │ │ │ +1252 } else { │ │ │ │ │ +1253 _I_n_d_e_x vEndValues[2]; │ │ │ │ │ +1254 fvarChannel.getVertexCreaseEndValues(vert, i, vEndValues); │ │ │ │ │ +1255 │ │ │ │ │ +1256 dst[vValue].AddWithWeight(src[vEndValues[0]], 1.0f/6.0f); │ │ │ │ │ +1257 dst[vValue].AddWithWeight(src[vEndValues[1]], 1.0f/6.0f); │ │ │ │ │ +1258 dst[vValue].AddWithWeight(src[vValue], 2.0f/3.0f); │ │ │ │ │ +1259 } │ │ │ │ │ +1260 } │ │ │ │ │ +1261 } │ │ │ │ │ +1262 } │ │ │ │ │ +1263} │ │ │ │ │ +1264 │ │ │ │ │ +_1_2_6_5class _P_r_i_m_v_a_r_R_e_f_i_n_e_r : public _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l { │ │ │ │ │ +1266public: │ │ │ │ │ +_1_2_6_7 _P_r_i_m_v_a_r_R_e_f_i_n_e_r(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner) │ │ │ │ │ +1268 : _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l(refiner) { } │ │ │ │ │ +1269}; │ │ │ │ │ +1270 │ │ │ │ │ +1271} // end namespace Far │ │ │ │ │ +1272 │ │ │ │ │ +1273} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +1274using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +1275} // end namespace OpenSubdiv │ │ │ │ │ +1276 │ │ │ │ │ +1277#endif /* OPENSUBDIV3_FAR_PRIMVAR_REFINER_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_o_c_a_l_I_n_d_e_x │ │ │ │ │ +Vtr::LocalIndex LocalIndex │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_E_r_r_o_r │ │ │ │ │ +void Error(ErrorType err, const char *format,...) │ │ │ │ │ +Sends an OSD error with a message (internal use only) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +Vtr::ConstIndexArray ConstIndexArray │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +Vtr::ConstLocalIndexArray ConstLocalIndexArray │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R │ │ │ │ │ +@ FAR_RUNTIME_ERROR │ │ │ │ │ +Issue a generic runtime error, but continue execution. │ │ │ │ │ +DDeeffiinniittiioonn _e_r_r_o_r_._h_:_4_0 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ Vtr::Index Index │ │ │ │ │ DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -Object used to compute and query ptex face indices. │ │ │ │ │ -DDeeffiinniittiioonn _p_t_e_x_I_n_d_i_c_e_s_._h_:_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_G_e_t_F_a_c_e_I_d │ │ │ │ │ -int GetFaceId(Index f) const │ │ │ │ │ -Returns the ptex face index given a coarse face 'f' or -1. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -PtexIndices(TopologyRefiner const &refiner) │ │ │ │ │ -Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_G_e_t_A_d_j_a_c_e_n_c_y │ │ │ │ │ -void GetAdjacency(TopologyRefiner const &refiner, int face, int quadrant, int │ │ │ │ │ -adjFaces[4], int adjEdges[4]) const │ │ │ │ │ -Returns ptex face adjacency information for a given coarse face. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_G_e_t_N_u_m_F_a_c_e_s │ │ │ │ │ -int GetNumFaces() const │ │ │ │ │ -Returns the number of ptex faces in the mesh. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_~_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ -~PtexIndices() │ │ │ │ │ -Destructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_I_n_d_e_x │ │ │ │ │ +int Index │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d │ │ │ │ │ +bool IndexIsValid(Index index) │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R │ │ │ │ │ +@ SCHEME_BILINEAR │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K │ │ │ │ │ +@ SCHEME_CATMARK │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___L_O_O_P │ │ │ │ │ +@ SCHEME_LOOP │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ +Applies refinement operations to generic primvar data. │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_L_i_m_i_t │ │ │ │ │ +void Limit(T const &src, U &dstPos) const │ │ │ │ │ +Apply limit weights to a primvar buffer. │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_1_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ +PrimvarRefinerReal(TopologyRefiner const &refiner) │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_5_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_L_i_m_i_t │ │ │ │ │ +void Limit(T const &src, U &dstPos, U1 &dstTan1, U2 &dstTan2) const │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_U_n_i_f_o_r_m │ │ │ │ │ +void InterpolateFaceUniform(int level, T const &src, U &dst) const │ │ │ │ │ +Refine uniform (per-face) primvar data between levels. │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_G_e_t_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ +TopologyRefiner const & GetTopologyRefiner() const │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e_V_a_r_y_i_n_g │ │ │ │ │ +void InterpolateVarying(int level, T const &src, U &dst) const │ │ │ │ │ +Apply only varying interpolation weights to a primvar buffer for a single level │ │ │ │ │ +of refinement. │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_4_1_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e │ │ │ │ │ +void Interpolate(int level, T const &src, U &dst) const │ │ │ │ │ +Apply vertex interpolation weights to a primvar buffer for a single level of │ │ │ │ │ +refinement. │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_2_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +void InterpolateFaceVarying(int level, T const &src, U &dst, int channel=0) │ │ │ │ │ +const │ │ │ │ │ +Apply face-varying interpolation weights to a primvar buffer associated with a │ │ │ │ │ +particular face-varyin... │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_2_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_~_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ +~PrimvarRefinerReal() │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_L_i_m_i_t_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +void LimitFaceVarying(T const &src, U &dst, int channel=0) const │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_1_2_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r │ │ │ │ │ +PrimvarRefiner(TopologyRefiner const &refiner) │ │ │ │ │ +DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_1_2_6_7 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ Stores topology data for a specified set of refinement options. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e │ │ │ │ │ +Rule │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E │ │ │ │ │ +@ RULE_CREASE │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e │ │ │ │ │ +Scheme is a class template which provides all implementation for the │ │ │ │ │ +subdivision schemes supported by... │ │ │ │ │ +DDeeffiinniittiioonn _s_c_h_e_m_e_._h_:_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ +DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_:_:_s_i_z_e │ │ │ │ │ +size_type size() const │ │ │ │ │ +DDeeffiinniittiioonn _a_r_r_a_y_._h_:_7_2 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_t_e_x_I_n_d_i_c_e_s_._h │ │ │ │ │ + * _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00725.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchTableFactory.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/ptexIndices.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,33 +90,28 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
patchTableFactory.h File Reference
│ │ │ │ +
ptexIndices.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/topologyRefiner.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ +#include "../far/topologyRefiner.h"
│ │ │ │ +#include "../far/types.h"
│ │ │ │ +#include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PatchTableFactory
 Factory for constructing a PatchTable from a TopologyRefiner. More...
 
struct  PatchTableFactory::Options
 Public options for the PatchTable factory. More...
 
struct  PatchTableFactory::PatchFaceTag
 Obsolete internal struct not intended for public use – due to be deprecated. More...
class  PtexIndices
 Object used to compute and query ptex face indices. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -125,13 +120,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,32 +1,26 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -patchTableFactory.h File Reference │ │ │ │ │ +ptexIndices.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ #include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ - class   _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ -  Factory for constructing a _P_a_t_c_h_T_a_b_l_e from a _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -struct   _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s │ │ │ │ │ -  Public options for the _P_a_t_c_h_T_a_b_l_e factory. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -struct   _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g │ │ │ │ │ -  Obsolete internal struct not intended for public use – due to be │ │ │ │ │ - deprecated. _M_o_r_e_._._. │ │ │ │ │ +class   _P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ +  Object used to compute and query ptex face indices. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ + * _p_t_e_x_I_n_d_i_c_e_s_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00725.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,5 +1,3 @@ │ │ │ │ │ var a00725 = [ │ │ │ │ │ - ["PatchTableFactory", "a01017.html", "a01017"], │ │ │ │ │ - ["Options", "a01021.html", "a01021"], │ │ │ │ │ - ["PatchFaceTag", "a01025.html", "a01025"] │ │ │ │ │ + ["PtexIndices", "a01041.html", "a01041"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00725_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchTableFactory.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/ptexIndices.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
patchTableFactory.h
│ │ │ │ +
ptexIndices.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2013 Pixar
│ │ │ │ +
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,250 +118,81 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H
│ │ │ │ -
27
│ │ │ │ -
28#include "../version.h"
│ │ │ │ -
29
│ │ │ │ -
30#include "../far/topologyRefiner.h"
│ │ │ │ -
31#include "../far/patchTable.h"
│ │ │ │ -
32
│ │ │ │ -
33namespace OpenSubdiv {
│ │ │ │ -
34namespace OPENSUBDIV_VERSION {
│ │ │ │ -
35
│ │ │ │ -
36namespace Far {
│ │ │ │ -
37
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
41public:
│ │ │ │ -
42
│ │ │ │ -
│ │ │ │ -
45 struct Options {
│ │ │ │ -
46
│ │ │ │ -
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
61 };
│ │ │ │ -
│ │ │ │ -
62
│ │ │ │ -
│ │ │ │ -
63 Options(unsigned int maxIsolation=10) :
│ │ │ │ -
64 generateAllLevels(false),
│ │ │ │ - │ │ │ │ - │ │ │ │ -
67 triangulateQuads(false),
│ │ │ │ - │ │ │ │ -
69 useInfSharpPatch(false),
│ │ │ │ -
70 maxIsolationLevel(maxIsolation & 0xf),
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
75 generateFVarTables(false),
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
82 { }
│ │ │ │ -
│ │ │ │ -
83
│ │ │ │ - │ │ │ │ -
86
│ │ │ │ -
88 void SetEndCapType(EndCapType e) { endCapType = e & 0x7; }
│ │ │ │ +
24#ifndef OPENSUBDIV3_FAR_PTEX_INDICES_H
│ │ │ │ +
25#define OPENSUBDIV3_FAR_PTEX_INDICES_H
│ │ │ │ +
26
│ │ │ │ +
27#include "../version.h"
│ │ │ │ +
28
│ │ │ │ +
29#include "../far/topologyRefiner.h"
│ │ │ │ +
30#include "../far/types.h"
│ │ │ │ +
31
│ │ │ │ +
32#include <vector>
│ │ │ │ +
33
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Far {
│ │ │ │ +
38
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
47
│ │ │ │ +
48public:
│ │ │ │ +
49
│ │ │ │ + │ │ │ │ +
52
│ │ │ │ + │ │ │ │ +
55
│ │ │ │ +
57
│ │ │ │ +
60
│ │ │ │ +
63 int GetNumFaces() const;
│ │ │ │ +
64
│ │ │ │ +
67 int GetFaceId(Index f) const;
│ │ │ │ +
68
│ │ │ │ + │ │ │ │ +
84 TopologyRefiner const &refiner,
│ │ │ │ +
85 int face, int quadrant,
│ │ │ │ +
86 int adjFaces[4], int adjEdges[4]) const;
│ │ │ │ +
87
│ │ │ │
89
│ │ │ │ -
91 void SetMaxIsolationLevel(unsigned int level) { maxIsolationLevel = level & 0xf; }
│ │ │ │ -
92
│ │ │ │ -
94 template <typename REAL> void SetPatchPrecision();
│ │ │ │ +
90private:
│ │ │ │ +
91
│ │ │ │ +
92 void initializePtexIndices(TopologyRefiner const &refiner);
│ │ │ │ +
93
│ │ │ │ +
94private:
│ │ │ │
95
│ │ │ │ -
97 template <typename REAL> void SetFVarPatchPrecision();
│ │ │ │ -
98
│ │ │ │ -
│ │ │ │ - │ │ │ │ - │ │ │ │ -
102
│ │ │ │ -
103 adaptiveOptions.useInfSharpPatch = useInfSharpPatch;
│ │ │ │ - │ │ │ │ -
105 adaptiveOptions.considerFVarChannels = generateFVarTables &&
│ │ │ │ - │ │ │ │ -
107 return adaptiveOptions;
│ │ │ │ -
108 }
│ │ │ │ -
│ │ │ │ -
109
│ │ │ │ -
110 unsigned int generateAllLevels : 1,
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
114
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
118
│ │ │ │ -
119 // end-capping
│ │ │ │ - │ │ │ │ - │ │ │ │ -
123
│ │ │ │ -
124 // varying
│ │ │ │ - │ │ │ │ - │ │ │ │ -
127
│ │ │ │ -
128 // face-varying
│ │ │ │ - │ │ │ │ -
130
│ │ │ │ -
131 // precision
│ │ │ │ - │ │ │ │ - │ │ │ │ -
134
│ │ │ │ -
135 // legacy behaviors (default to true)
│ │ │ │ - │ │ │ │ - │ │ │ │ -
138
│ │ │ │ - │ │ │ │ -
140 int const * fvarChannelIndices;
│ │ │ │ -
141 };
│ │ │ │ -
│ │ │ │ -
142
│ │ │ │ -
175 static PatchTable * Create(TopologyRefiner const & refiner,
│ │ │ │ -
176 Options options = Options(),
│ │ │ │ -
177 ConstIndexArray selectedFaces = ConstIndexArray());
│ │ │ │ -
178
│ │ │ │ -
179public:
│ │ │ │ -
180 // PatchFaceTag
│ │ │ │ -
181 //
│ │ │ │ -
182 // This simple struct was previously used within the factory to take inventory of
│ │ │ │ -
183 // various kinds of patches to fully allocate buffers prior to populating them. It
│ │ │ │ -
184 // was not intended to be exposed as part of the public interface.
│ │ │ │ -
185 //
│ │ │ │ -
186 // It is no longer used internally and is being kept here to respect preservation
│ │ │ │ -
187 // of the public interface, but it will be deprecated at the earliest opportunity.
│ │ │ │ -
188 //
│ │ │ │ -
191 //
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
193 public:
│ │ │ │ -
194 unsigned int _hasPatch : 1;
│ │ │ │ -
195 unsigned int _isRegular : 1;
│ │ │ │ -
196 unsigned int _transitionMask : 4;
│ │ │ │ -
197 unsigned int _boundaryMask : 4;
│ │ │ │ -
198 unsigned int _boundaryIndex : 2;
│ │ │ │ -
199 unsigned int _boundaryCount : 3;
│ │ │ │ -
200 unsigned int _hasBoundaryEdge : 3;
│ │ │ │ -
201 unsigned int _isSingleCrease : 1;
│ │ │ │ -
202
│ │ │ │ -
203 void clear();
│ │ │ │ -
204 void assignBoundaryPropertiesFromEdgeMask(int boundaryEdgeMask);
│ │ │ │ -
205 void assignBoundaryPropertiesFromVertexMask(int boundaryVertexMask);
│ │ │ │ -
206 void assignTransitionPropertiesFromEdgeMask(int boundaryVertexMask);
│ │ │ │ -
207 };
│ │ │ │ +
96 std::vector<Index> _ptexIndices;
│ │ │ │ +
97};
│ │ │ │
│ │ │ │ -
208 typedef std::vector<PatchFaceTag> PatchTagVector;
│ │ │ │ -
209};
│ │ │ │ -
│ │ │ │ -
210
│ │ │ │ -
211
│ │ │ │ -
│ │ │ │ -
212template <> inline void PatchTableFactory::Options::SetPatchPrecision<float>() {
│ │ │ │ -
213 patchPrecisionDouble = false;
│ │ │ │ -
214}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
215template <> inline void PatchTableFactory::Options::SetFVarPatchPrecision<float>() {
│ │ │ │ -
216 fvarPatchPrecisionDouble = false;
│ │ │ │ -
217}
│ │ │ │ -
│ │ │ │ -
218
│ │ │ │ -
219template <> inline void PatchTableFactory::Options::SetPatchPrecision<double>() {
│ │ │ │ -
220 patchPrecisionDouble = true;
│ │ │ │ -
221}
│ │ │ │ -
222template <> inline void PatchTableFactory::Options::SetFVarPatchPrecision<double>() {
│ │ │ │ -
223 fvarPatchPrecisionDouble = true;
│ │ │ │ -
224}
│ │ │ │ -
225
│ │ │ │ -
226
│ │ │ │ -
227} // end namespace Far
│ │ │ │ -
228
│ │ │ │ -
229} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
230using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
231
│ │ │ │ -
232} // end namespace OpenSubdiv
│ │ │ │ -
233
│ │ │ │ -
234
│ │ │ │ -
235#endif /* OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H */
│ │ │ │ +
98
│ │ │ │ +
99
│ │ │ │ +
100} // end namespace Far
│ │ │ │ +
101
│ │ │ │ +
102} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
103using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
104} // end namespace OpenSubdiv
│ │ │ │ +
105
│ │ │ │ +
106#endif /* OPENSUBDIV3_FAR_PTEX_INDICES_H */
│ │ │ │ │ │ │ │ -
Vtr::ConstIndexArray ConstIndexArray
Definition types.h:47
│ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ -
Factory for constructing a PatchTable from a TopologyRefiner.
│ │ │ │ - │ │ │ │ -
static PatchTable * Create(TopologyRefiner const &refiner, Options options=Options(), ConstIndexArray selectedFaces=ConstIndexArray())
Instantiates a PatchTable from a client-provided TopologyRefiner.
│ │ │ │ - │ │ │ │ -
unsigned int generateVaryingTables
Generate varying patch tables.
│ │ │ │ -
unsigned int generateLegacySharpCornerPatches
Generate sharp regular patches at smooth corners (legacy)
│ │ │ │ - │ │ │ │ -
TopologyRefiner::AdaptiveOptions GetRefineAdaptiveOptions() const
Determine adaptive refinement options to match assigned patch options.
│ │ │ │ -
unsigned int maxIsolationLevel
Cap adaptive feature isolation to the given level (max. 10)
│ │ │ │ - │ │ │ │ -
unsigned int generateFVarLegacyLinearPatches
Generate all linear face-varying patches (legacy)
│ │ │ │ -
void SetPatchPrecision()
Set precision of vertex patches.
│ │ │ │ -
unsigned int fvarPatchPrecisionDouble
Generate double-precision stencils for face-varying patches.
│ │ │ │ -
void SetMaxIsolationLevel(unsigned int level)
Set maximum isolation level.
│ │ │ │ - │ │ │ │ -
int const * fvarChannelIndices
List containing the indices of the channels selected for the factory.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
unsigned int generateVaryingLocalPoints
Generate local points with varying patches.
│ │ │ │ -
unsigned int includeFVarBaseLevelIndices
Include base level in face-varying patch point indices (Uniform mode only)
│ │ │ │ -
unsigned int generateAllLevels
Generate levels from 'firstLevel' to 'maxLevel' (Uniform mode only)
│ │ │ │ -
unsigned int patchPrecisionDouble
Generate double-precision stencils for vertex patches.
│ │ │ │ -
unsigned int generateFVarTables
Generate face-varying patch tables.
│ │ │ │ -
unsigned int includeBaseLevelIndices
Include base level in patch point indices (Uniform mode only)
│ │ │ │ -
void SetFVarPatchPrecision()
Set precision of face-varying patches.
│ │ │ │ -
int numFVarChannels
Number of channel indices and interpolation modes passed.
│ │ │ │ -
unsigned int triangulateQuads
Triangulate 'QUADS' primitives (Uniform mode only)
│ │ │ │ -
EndCapType
Choice for approximating irregular patches (end-caps)
│ │ │ │ -
@ ENDCAP_LEGACY_GREGORY
legacy option for 2.x style Gregory patches (Catmark only)
│ │ │ │ -
@ ENDCAP_GREGORY_BASIS
use Gregory patches (highest quality, recommended default)
│ │ │ │ - │ │ │ │ -
@ ENDCAP_BILINEAR_BASIS
use linear patches (simple quads or tris)
│ │ │ │ -
@ ENDCAP_BSPLINE_BASIS
use BSpline-like patches (same patch type as regular)
│ │ │ │ - │ │ │ │ -
Obsolete internal struct not intended for public use – due to be deprecated.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ +
Object used to compute and query ptex face indices.
Definition ptexIndices.h:46
│ │ │ │ +
int GetFaceId(Index f) const
Returns the ptex face index given a coarse face 'f' or -1.
│ │ │ │ +
PtexIndices(TopologyRefiner const &refiner)
Constructor.
│ │ │ │ +
void GetAdjacency(TopologyRefiner const &refiner, int face, int quadrant, int adjFaces[4], int adjEdges[4]) const
Returns ptex face adjacency information for a given coarse face.
│ │ │ │ +
int GetNumFaces() const
Returns the number of ptex faces in the mesh.
│ │ │ │ + │ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── encoding │ │ │ │ │ @@ -1 +1 @@ │ │ │ │ │ -utf-8 │ │ │ │ │ +us-ascii │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -patchTableFactory.h │ │ │ │ │ +ptexIndices.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2013 Pixar │ │ │ │ │ +2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,410 +23,90 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H │ │ │ │ │ -27 │ │ │ │ │ -28#include "../version.h" │ │ │ │ │ -29 │ │ │ │ │ -30#include "../far/topologyRefiner.h" │ │ │ │ │ -31#include "../far/patchTable.h" │ │ │ │ │ -32 │ │ │ │ │ -33namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -34namespace OPENSUBDIV_VERSION { │ │ │ │ │ -35 │ │ │ │ │ -36namespace Far { │ │ │ │ │ -37 │ │ │ │ │ -_4_0class _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y { │ │ │ │ │ -41public: │ │ │ │ │ -42 │ │ │ │ │ -_4_5 struct _O_p_t_i_o_n_s { │ │ │ │ │ -46 │ │ │ │ │ -_5_5 enum _E_n_d_C_a_p_T_y_p_e { │ │ │ │ │ -_5_6 _E_N_D_C_A_P___N_O_N_E = 0, │ │ │ │ │ -_5_7 _E_N_D_C_A_P___B_I_L_I_N_E_A_R___B_A_S_I_S, │ │ │ │ │ -_5_8 _E_N_D_C_A_P___B_S_P_L_I_N_E___B_A_S_I_S, │ │ │ │ │ -_5_9 _E_N_D_C_A_P___G_R_E_G_O_R_Y___B_A_S_I_S, │ │ │ │ │ -60 _E_N_D_C_A_P___L_E_G_A_C_Y___G_R_E_G_O_R_Y │ │ │ │ │ -_6_1 }; │ │ │ │ │ -62 │ │ │ │ │ -_6_3 _O_p_t_i_o_n_s(unsigned int maxIsolation=10) : │ │ │ │ │ -64 _g_e_n_e_r_a_t_e_A_l_l_L_e_v_e_l_s(false), │ │ │ │ │ -65 _i_n_c_l_u_d_e_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s(true), │ │ │ │ │ -66 _i_n_c_l_u_d_e_F_V_a_r_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s(false), │ │ │ │ │ -67 _t_r_i_a_n_g_u_l_a_t_e_Q_u_a_d_s(false), │ │ │ │ │ -68 _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h(false), │ │ │ │ │ -69 _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h(false), │ │ │ │ │ -70 _m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l(maxIsolation & 0xf), │ │ │ │ │ -71 _e_n_d_C_a_p_T_y_p_e(_E_N_D_C_A_P___G_R_E_G_O_R_Y___B_A_S_I_S), │ │ │ │ │ -72 _s_h_a_r_e_E_n_d_C_a_p_P_a_t_c_h_P_o_i_n_t_s(true), │ │ │ │ │ -73 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_T_a_b_l_e_s(true), │ │ │ │ │ -74 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_L_o_c_a_l_P_o_i_n_t_s(true), │ │ │ │ │ -75 _g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s(false), │ │ │ │ │ -76 _p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e(false), │ │ │ │ │ -77 _f_v_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e(false), │ │ │ │ │ -78 _g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s(true), │ │ │ │ │ -79 _g_e_n_e_r_a_t_e_L_e_g_a_c_y_S_h_a_r_p_C_o_r_n_e_r_P_a_t_c_h_e_s(true), │ │ │ │ │ -80 _n_u_m_F_V_a_r_C_h_a_n_n_e_l_s(-1), │ │ │ │ │ -81 _f_v_a_r_C_h_a_n_n_e_l_I_n_d_i_c_e_s(0) │ │ │ │ │ -82 { } │ │ │ │ │ -83 │ │ │ │ │ -_8_5 _E_n_d_C_a_p_T_y_p_e _G_e_t_E_n_d_C_a_p_T_y_p_e() const { return (_E_n_d_C_a_p_T_y_p_e)_e_n_d_C_a_p_T_y_p_e; } │ │ │ │ │ -86 │ │ │ │ │ -_8_8 void _S_e_t_E_n_d_C_a_p_T_y_p_e(_E_n_d_C_a_p_T_y_p_e e) { _e_n_d_C_a_p_T_y_p_e = e & 0x7; } │ │ │ │ │ +24#ifndef OPENSUBDIV3_FAR_PTEX_INDICES_H │ │ │ │ │ +25#define OPENSUBDIV3_FAR_PTEX_INDICES_H │ │ │ │ │ +26 │ │ │ │ │ +27#include "../version.h" │ │ │ │ │ +28 │ │ │ │ │ +29#include "../far/topologyRefiner.h" │ │ │ │ │ +30#include "../far/types.h" │ │ │ │ │ +31 │ │ │ │ │ +32#include │ │ │ │ │ +33 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Far { │ │ │ │ │ +38 │ │ │ │ │ +_4_6class _P_t_e_x_I_n_d_i_c_e_s { │ │ │ │ │ +47 │ │ │ │ │ +48public: │ │ │ │ │ +49 │ │ │ │ │ +_5_1 _P_t_e_x_I_n_d_i_c_e_s(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner); │ │ │ │ │ +52 │ │ │ │ │ +_5_4 _~_P_t_e_x_I_n_d_i_c_e_s(); │ │ │ │ │ +55 │ │ │ │ │ +57 │ │ │ │ │ +60 │ │ │ │ │ +_6_3 int _G_e_t_N_u_m_F_a_c_e_s() const; │ │ │ │ │ +64 │ │ │ │ │ +_6_7 int _G_e_t_F_a_c_e_I_d(_I_n_d_e_x f) const; │ │ │ │ │ +68 │ │ │ │ │ +_8_3 void _G_e_t_A_d_j_a_c_e_n_c_y( │ │ │ │ │ +84 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner, │ │ │ │ │ +85 int face, int quadrant, │ │ │ │ │ +86 int adjFaces[4], int adjEdges[4]) const; │ │ │ │ │ +87 │ │ │ │ │ 89 │ │ │ │ │ -_9_1 void _S_e_t_M_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l(unsigned int level) { _m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l = level & │ │ │ │ │ -0xf; } │ │ │ │ │ -92 │ │ │ │ │ -_9_4 template void _S_e_t_P_a_t_c_h_P_r_e_c_i_s_i_o_n(); │ │ │ │ │ +90private: │ │ │ │ │ +91 │ │ │ │ │ +92 void initializePtexIndices(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const &refiner); │ │ │ │ │ +93 │ │ │ │ │ +94private: │ │ │ │ │ 95 │ │ │ │ │ -_9_7 template void _S_e_t_F_V_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n(); │ │ │ │ │ +96 std::vector _ptexIndices; │ │ │ │ │ +97}; │ │ │ │ │ 98 │ │ │ │ │ -_1_0_0 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s _G_e_t_R_e_f_i_n_e_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s() const { │ │ │ │ │ -101 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s adaptiveOptions(_m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l); │ │ │ │ │ -102 │ │ │ │ │ -103 adaptiveOptions._u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h = _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h; │ │ │ │ │ -104 adaptiveOptions._u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h = _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h; │ │ │ │ │ -105 adaptiveOptions._c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s = _g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s && │ │ │ │ │ -106 !_g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s; │ │ │ │ │ -107 return adaptiveOptions; │ │ │ │ │ -108 } │ │ │ │ │ -109 │ │ │ │ │ -_1_1_0 unsigned int _g_e_n_e_r_a_t_e_A_l_l_L_e_v_e_l_s : 1, │ │ │ │ │ -_1_1_1 _i_n_c_l_u_d_e_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s : 1, │ │ │ │ │ -_1_1_2 _i_n_c_l_u_d_e_F_V_a_r_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s : 1, │ │ │ │ │ -_1_1_3 _t_r_i_a_n_g_u_l_a_t_e_Q_u_a_d_s : 1, │ │ │ │ │ -114 │ │ │ │ │ -_1_1_5 _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h : 1, │ │ │ │ │ -_1_1_6 _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h : 1, │ │ │ │ │ -_1_1_7 _m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l : 4, │ │ │ │ │ -118 │ │ │ │ │ -119 // end-capping │ │ │ │ │ -_1_2_0 _e_n_d_C_a_p_T_y_p_e : 3, │ │ │ │ │ -_1_2_1 _s_h_a_r_e_E_n_d_C_a_p_P_a_t_c_h_P_o_i_n_t_s : 1, │ │ │ │ │ -123 │ │ │ │ │ -124 // varying │ │ │ │ │ -_1_2_5 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_T_a_b_l_e_s : 1, │ │ │ │ │ -_1_2_6 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_L_o_c_a_l_P_o_i_n_t_s : 1, │ │ │ │ │ -127 │ │ │ │ │ -128 // face-varying │ │ │ │ │ -_1_2_9 _g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s : 1, │ │ │ │ │ -130 │ │ │ │ │ -131 // precision │ │ │ │ │ -_1_3_2 _p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e : 1, │ │ │ │ │ -_1_3_3 _f_v_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e : 1, │ │ │ │ │ -134 │ │ │ │ │ -135 // legacy behaviors (default to true) │ │ │ │ │ -_1_3_6 _g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s : 1, │ │ │ │ │ -_1_3_7 _g_e_n_e_r_a_t_e_L_e_g_a_c_y_S_h_a_r_p_C_o_r_n_e_r_P_a_t_c_h_e_s : 1; │ │ │ │ │ -138 │ │ │ │ │ -_1_3_9 int _n_u_m_F_V_a_r_C_h_a_n_n_e_l_s; │ │ │ │ │ -_1_4_0 int const * _f_v_a_r_C_h_a_n_n_e_l_I_n_d_i_c_e_s; │ │ │ │ │ -141 }; │ │ │ │ │ -142 │ │ │ │ │ -_1_7_5 static _P_a_t_c_h_T_a_b_l_e * _C_r_e_a_t_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, │ │ │ │ │ -176 _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s(), │ │ │ │ │ -177 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y selectedFaces = _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y()); │ │ │ │ │ -178 │ │ │ │ │ -179public: │ │ │ │ │ -180 // PatchFaceTag │ │ │ │ │ -181 // │ │ │ │ │ -182 // This simple struct was previously used within the factory to take │ │ │ │ │ -inventory of │ │ │ │ │ -183 // various kinds of patches to fully allocate buffers prior to populating │ │ │ │ │ -them. It │ │ │ │ │ -184 // was not intended to be exposed as part of the public interface. │ │ │ │ │ -185 // │ │ │ │ │ -186 // It is no longer used internally and is being kept here to respect │ │ │ │ │ -preservation │ │ │ │ │ -187 // of the public interface, but it will be deprecated at the earliest │ │ │ │ │ -opportunity. │ │ │ │ │ -188 // │ │ │ │ │ -191 // │ │ │ │ │ -_1_9_2 struct _P_a_t_c_h_F_a_c_e_T_a_g { │ │ │ │ │ -193 public: │ │ │ │ │ -_1_9_4 unsigned int ___h_a_s_P_a_t_c_h : 1; │ │ │ │ │ -_1_9_5 unsigned int ___i_s_R_e_g_u_l_a_r : 1; │ │ │ │ │ -_1_9_6 unsigned int ___t_r_a_n_s_i_t_i_o_n_M_a_s_k : 4; │ │ │ │ │ -_1_9_7 unsigned int ___b_o_u_n_d_a_r_y_M_a_s_k : 4; │ │ │ │ │ -_1_9_8 unsigned int ___b_o_u_n_d_a_r_y_I_n_d_e_x : 2; │ │ │ │ │ -_1_9_9 unsigned int ___b_o_u_n_d_a_r_y_C_o_u_n_t : 3; │ │ │ │ │ -_2_0_0 unsigned int ___h_a_s_B_o_u_n_d_a_r_y_E_d_g_e : 3; │ │ │ │ │ -_2_0_1 unsigned int ___i_s_S_i_n_g_l_e_C_r_e_a_s_e : 1; │ │ │ │ │ -202 │ │ │ │ │ -_2_0_3 void _c_l_e_a_r(); │ │ │ │ │ -_2_0_4 void _a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k(int boundaryEdgeMask); │ │ │ │ │ -_2_0_5 void _a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_V_e_r_t_e_x_M_a_s_k(int boundaryVertexMask); │ │ │ │ │ -_2_0_6 void _a_s_s_i_g_n_T_r_a_n_s_i_t_i_o_n_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k(int boundaryVertexMask); │ │ │ │ │ -207 }; │ │ │ │ │ -_2_0_8 typedef std::vector _P_a_t_c_h_T_a_g_V_e_c_t_o_r; │ │ │ │ │ -209}; │ │ │ │ │ -210 │ │ │ │ │ -211 │ │ │ │ │ -_2_1_2template <> inline void PatchTableFactory::Options::SetPatchPrecision │ │ │ │ │ -() { │ │ │ │ │ -213 _p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e = false; │ │ │ │ │ -214} │ │ │ │ │ -_2_1_5template <> inline void PatchTableFactory::Options:: │ │ │ │ │ -SetFVarPatchPrecision() { │ │ │ │ │ -216 fvarPatchPrecisionDouble = false; │ │ │ │ │ -217} │ │ │ │ │ -218 │ │ │ │ │ -219template <> inline void PatchTableFactory::Options:: │ │ │ │ │ -SetPatchPrecision() { │ │ │ │ │ -220 patchPrecisionDouble = true; │ │ │ │ │ -221} │ │ │ │ │ -222template <> inline void PatchTableFactory::Options:: │ │ │ │ │ -SetFVarPatchPrecision() { │ │ │ │ │ -223 fvarPatchPrecisionDouble = true; │ │ │ │ │ -224} │ │ │ │ │ -225 │ │ │ │ │ -226 │ │ │ │ │ -227} // end namespace Far │ │ │ │ │ -228 │ │ │ │ │ -229} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -230using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -231 │ │ │ │ │ -232} // end namespace OpenSubdiv │ │ │ │ │ -233 │ │ │ │ │ -234 │ │ │ │ │ -235#endif /* OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H */ │ │ │ │ │ +99 │ │ │ │ │ +100} // end namespace Far │ │ │ │ │ +101 │ │ │ │ │ +102} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +103using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +104} // end namespace OpenSubdiv │ │ │ │ │ +105 │ │ │ │ │ +106#endif /* OPENSUBDIV3_FAR_PTEX_INDICES_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ -Vtr::ConstIndexArray ConstIndexArray │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -Container for arrays of parametric patches. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ -Factory for constructing a PatchTable from a TopologyRefiner. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_T_a_g_V_e_c_t_o_r │ │ │ │ │ -std::vector< PatchFaceTag > PatchTagVector │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ -static PatchTable * Create(TopologyRefiner const &refiner, Options │ │ │ │ │ -options=Options(), ConstIndexArray selectedFaces=ConstIndexArray()) │ │ │ │ │ -Instantiates a PatchTable from a client-provided TopologyRefiner. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s │ │ │ │ │ -Public options for the PatchTable factory. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_4_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_T_a_b_l_e_s │ │ │ │ │ -unsigned int generateVaryingTables │ │ │ │ │ -Generate varying patch tables. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_L_e_g_a_c_y_S_h_a_r_p_C_o_r_n_e_r_P_a_t_c_h_e_s │ │ │ │ │ -unsigned int generateLegacySharpCornerPatches │ │ │ │ │ -Generate sharp regular patches at smooth corners (legacy) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_s_h_a_r_e_E_n_d_C_a_p_P_a_t_c_h_P_o_i_n_t_s │ │ │ │ │ -unsigned int shareEndCapPatchPoints │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_G_e_t_R_e_f_i_n_e_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ -TopologyRefiner::AdaptiveOptions GetRefineAdaptiveOptions() const │ │ │ │ │ -Determine adaptive refinement options to match assigned patch options. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l │ │ │ │ │ -unsigned int maxIsolationLevel │ │ │ │ │ -Cap adaptive feature isolation to the given level (max. 10) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_G_e_t_E_n_d_C_a_p_T_y_p_e │ │ │ │ │ -EndCapType GetEndCapType() const │ │ │ │ │ -Get endcap basis type. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s │ │ │ │ │ -unsigned int generateFVarLegacyLinearPatches │ │ │ │ │ -Generate all linear face-varying patches (legacy) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_S_e_t_P_a_t_c_h_P_r_e_c_i_s_i_o_n │ │ │ │ │ -void SetPatchPrecision() │ │ │ │ │ -Set precision of vertex patches. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_f_v_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e │ │ │ │ │ -unsigned int fvarPatchPrecisionDouble │ │ │ │ │ -Generate double-precision stencils for face-varying patches. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_S_e_t_M_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l │ │ │ │ │ -void SetMaxIsolationLevel(unsigned int level) │ │ │ │ │ -Set maximum isolation level. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_9_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_e_n_d_C_a_p_T_y_p_e │ │ │ │ │ -unsigned int endCapType │ │ │ │ │ -EndCapType. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_f_v_a_r_C_h_a_n_n_e_l_I_n_d_i_c_e_s │ │ │ │ │ -int const * fvarChannelIndices │ │ │ │ │ -List containing the indices of the channels selected for the factory. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h │ │ │ │ │ -unsigned int useSingleCreasePatch │ │ │ │ │ -Use single crease patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h │ │ │ │ │ -unsigned int useInfSharpPatch │ │ │ │ │ -Use infinitely-sharp patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_S_e_t_E_n_d_C_a_p_T_y_p_e │ │ │ │ │ -void SetEndCapType(EndCapType e) │ │ │ │ │ -Set endcap basis type. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_L_o_c_a_l_P_o_i_n_t_s │ │ │ │ │ -unsigned int generateVaryingLocalPoints │ │ │ │ │ -Generate local points with varying patches. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_i_n_c_l_u_d_e_F_V_a_r_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s │ │ │ │ │ -unsigned int includeFVarBaseLevelIndices │ │ │ │ │ -Include base level in face-varying patch point indices (Uniform mode only) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_A_l_l_L_e_v_e_l_s │ │ │ │ │ -unsigned int generateAllLevels │ │ │ │ │ -Generate levels from 'firstLevel' to 'maxLevel' (Uniform mode only) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e │ │ │ │ │ -unsigned int patchPrecisionDouble │ │ │ │ │ -Generate double-precision stencils for vertex patches. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s │ │ │ │ │ -unsigned int generateFVarTables │ │ │ │ │ -Generate face-varying patch tables. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_i_n_c_l_u_d_e_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s │ │ │ │ │ -unsigned int includeBaseLevelIndices │ │ │ │ │ -Include base level in patch point indices (Uniform mode only) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_S_e_t_F_V_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n │ │ │ │ │ -void SetFVarPatchPrecision() │ │ │ │ │ -Set precision of face-varying patches. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_n_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -int numFVarChannels │ │ │ │ │ -Number of channel indices and interpolation modes passed. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_t_r_i_a_n_g_u_l_a_t_e_Q_u_a_d_s │ │ │ │ │ -unsigned int triangulateQuads │ │ │ │ │ -Triangulate 'QUADS' primitives (Uniform mode only) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_E_n_d_C_a_p_T_y_p_e │ │ │ │ │ -EndCapType │ │ │ │ │ -Choice for approximating irregular patches (end-caps) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_E_N_D_C_A_P___L_E_G_A_C_Y___G_R_E_G_O_R_Y │ │ │ │ │ -@ ENDCAP_LEGACY_GREGORY │ │ │ │ │ -legacy option for 2.x style Gregory patches (Catmark only) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_E_N_D_C_A_P___G_R_E_G_O_R_Y___B_A_S_I_S │ │ │ │ │ -@ ENDCAP_GREGORY_BASIS │ │ │ │ │ -use Gregory patches (highest quality, recommended default) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_E_N_D_C_A_P___N_O_N_E │ │ │ │ │ -@ ENDCAP_NONE │ │ │ │ │ -unspecified │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_E_N_D_C_A_P___B_I_L_I_N_E_A_R___B_A_S_I_S │ │ │ │ │ -@ ENDCAP_BILINEAR_BASIS │ │ │ │ │ -use linear patches (simple quads or tris) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_E_N_D_C_A_P___B_S_P_L_I_N_E___B_A_S_I_S │ │ │ │ │ -@ ENDCAP_BSPLINE_BASIS │ │ │ │ │ -use BSpline-like patches (same patch type as regular) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ -Options(unsigned int maxIsolation=10) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g │ │ │ │ │ -Obsolete internal struct not intended for public use – due to be deprecated. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___i_s_S_i_n_g_l_e_C_r_e_a_s_e │ │ │ │ │ -unsigned int _isSingleCrease │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___i_s_R_e_g_u_l_a_r │ │ │ │ │ -unsigned int _isRegular │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___b_o_u_n_d_a_r_y_I_n_d_e_x │ │ │ │ │ -unsigned int _boundaryIndex │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -_a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_V_e_r_t_e_x_M_a_s_k │ │ │ │ │ -void assignBoundaryPropertiesFromVertexMask(int boundaryVertexMask) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___t_r_a_n_s_i_t_i_o_n_M_a_s_k │ │ │ │ │ -unsigned int _transitionMask │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___h_a_s_B_o_u_n_d_a_r_y_E_d_g_e │ │ │ │ │ -unsigned int _hasBoundaryEdge │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___b_o_u_n_d_a_r_y_M_a_s_k │ │ │ │ │ -unsigned int _boundaryMask │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_:___h_a_s_P_a_t_c_h │ │ │ │ │ -unsigned int _hasPatch │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -_a_s_s_i_g_n_T_r_a_n_s_i_t_i_o_n_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k │ │ │ │ │ -void assignTransitionPropertiesFromEdgeMask(int boundaryVertexMask) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_:_c_l_e_a_r │ │ │ │ │ -void clear() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -_a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k │ │ │ │ │ -void assignBoundaryPropertiesFromEdgeMask(int boundaryEdgeMask) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ -___b_o_u_n_d_a_r_y_C_o_u_n_t │ │ │ │ │ -unsigned int _boundaryCount │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ +Vtr::Index Index │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ +Object used to compute and query ptex face indices. │ │ │ │ │ +DDeeffiinniittiioonn _p_t_e_x_I_n_d_i_c_e_s_._h_:_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_G_e_t_F_a_c_e_I_d │ │ │ │ │ +int GetFaceId(Index f) const │ │ │ │ │ +Returns the ptex face index given a coarse face 'f' or -1. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ +PtexIndices(TopologyRefiner const &refiner) │ │ │ │ │ +Constructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_G_e_t_A_d_j_a_c_e_n_c_y │ │ │ │ │ +void GetAdjacency(TopologyRefiner const &refiner, int face, int quadrant, int │ │ │ │ │ +adjFaces[4], int adjEdges[4]) const │ │ │ │ │ +Returns ptex face adjacency information for a given coarse face. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_G_e_t_N_u_m_F_a_c_e_s │ │ │ │ │ +int GetNumFaces() const │ │ │ │ │ +Returns the number of ptex faces in the mesh. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_t_e_x_I_n_d_i_c_e_s_:_:_~_P_t_e_x_I_n_d_i_c_e_s │ │ │ │ │ +~PtexIndices() │ │ │ │ │ +Destructor. │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ Stores topology data for a specified set of refinement options. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ -Adaptive refinement options. │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h │ │ │ │ │ -unsigned int useSingleCreasePatch │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h │ │ │ │ │ -unsigned int useInfSharpPatch │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ -_c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -unsigned int considerFVarChannels │ │ │ │ │ -DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ -DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ + * _p_t_e_x_I_n_d_i_c_e_s_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00728.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/primvarRefiner.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/patchTableFactory.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,43 +90,33 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
primvarRefiner.h File Reference
│ │ │ │ +
patchTableFactory.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../sdc/types.h"
│ │ │ │ -#include "../sdc/options.h"
│ │ │ │ -#include "../sdc/bilinearScheme.h"
│ │ │ │ -#include "../sdc/catmarkScheme.h"
│ │ │ │ -#include "../sdc/loopScheme.h"
│ │ │ │ -#include "../vtr/level.h"
│ │ │ │ -#include "../vtr/fvarLevel.h"
│ │ │ │ -#include "../vtr/refinement.h"
│ │ │ │ -#include "../vtr/fvarRefinement.h"
│ │ │ │ -#include "../vtr/stackBuffer.h"
│ │ │ │ -#include "../vtr/componentInterfaces.h"
│ │ │ │ -#include "../far/types.h"
│ │ │ │ -#include "../far/error.h"
│ │ │ │ -#include "../far/topologyLevel.h"
│ │ │ │ -#include "../far/topologyRefiner.h"
│ │ │ │ -#include <cassert>
│ │ │ │ +#include "../far/topologyRefiner.h"
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PrimvarRefinerReal< REAL >
 Applies refinement operations to generic primvar data. More...
class  PatchTableFactory
 Factory for constructing a PatchTable from a TopologyRefiner. More...
 
class  PrimvarRefiner
struct  PatchTableFactory::Options
 Public options for the PatchTable factory. More...
 
struct  PatchTableFactory::PatchFaceTag
 Obsolete internal struct not intended for public use – due to be deprecated. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -135,13 +125,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,41 +1,32 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -primvarRefiner.h File Reference │ │ │ │ │ +patchTableFactory.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_s_d_c_/_t_y_p_e_s_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_b_i_l_i_n_e_a_r_S_c_h_e_m_e_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_c_a_t_m_a_r_k_S_c_h_e_m_e_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_l_o_o_p_S_c_h_e_m_e_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_l_e_v_e_l_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_f_v_a_r_L_e_v_e_l_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_r_e_f_i_n_e_m_e_n_t_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_f_v_a_r_R_e_f_i_n_e_m_e_n_t_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_s_t_a_c_k_B_u_f_f_e_r_._h" │ │ │ │ │ -#include "_._._/_v_t_r_/_c_o_m_p_o_n_e_n_t_I_n_t_e_r_f_a_c_e_s_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_e_r_r_o_r_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_L_e_v_e_l_._h" │ │ │ │ │ #include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_ _R_E_A_L_ _> │ │ │ │ │ -  Applies refinement operations to generic primvar data. _M_o_r_e_._._. │ │ │ │ │ + class   _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ +  Factory for constructing a _P_a_t_c_h_T_a_b_l_e from a _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _P_r_i_m_v_a_r_R_e_f_i_n_e_r │ │ │ │ │ +struct   _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s │ │ │ │ │ +  Public options for the _P_a_t_c_h_T_a_b_l_e factory. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +struct   _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g │ │ │ │ │ +  Obsolete internal struct not intended for public use – due to be │ │ │ │ │ + deprecated. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h │ │ │ │ │ + * _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00728.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,5 @@ │ │ │ │ │ var a00728 = [ │ │ │ │ │ - ["PrimvarRefinerReal< REAL >", "a01029.html", "a01029"], │ │ │ │ │ - ["PrimvarRefiner", "a01037.html", "a01037"] │ │ │ │ │ + ["PatchTableFactory", "a01017.html", "a01017"], │ │ │ │ │ + ["Options", "a01021.html", "a01021"], │ │ │ │ │ + ["PatchFaceTag", "a01025.html", "a01025"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00728_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/primvarRefiner.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/patchTableFactory.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
primvarRefiner.h
│ │ │ │ +
patchTableFactory.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2015 DreamWorks Animation LLC.
│ │ │ │ +
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -118,1233 +118,250 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_FAR_PRIMVAR_REFINER_H
│ │ │ │ -
25#define OPENSUBDIV3_FAR_PRIMVAR_REFINER_H
│ │ │ │ -
26
│ │ │ │ -
27#include "../version.h"
│ │ │ │ -
28
│ │ │ │ -
29#include "../sdc/types.h"
│ │ │ │ -
30#include "../sdc/options.h"
│ │ │ │ -
31#include "../sdc/bilinearScheme.h"
│ │ │ │ -
32#include "../sdc/catmarkScheme.h"
│ │ │ │ -
33#include "../sdc/loopScheme.h"
│ │ │ │ -
34#include "../vtr/level.h"
│ │ │ │ -
35#include "../vtr/fvarLevel.h"
│ │ │ │ -
36#include "../vtr/refinement.h"
│ │ │ │ -
37#include "../vtr/fvarRefinement.h"
│ │ │ │ -
38#include "../vtr/stackBuffer.h"
│ │ │ │ -
39#include "../vtr/componentInterfaces.h"
│ │ │ │ -
40#include "../far/types.h"
│ │ │ │ -
41#include "../far/error.h"
│ │ │ │ -
42#include "../far/topologyLevel.h"
│ │ │ │ -
43#include "../far/topologyRefiner.h"
│ │ │ │ -
44
│ │ │ │ -
45#include <cassert>
│ │ │ │ +
24
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H
│ │ │ │ +
27
│ │ │ │ +
28#include "../version.h"
│ │ │ │ +
29
│ │ │ │ +
30#include "../far/topologyRefiner.h"
│ │ │ │ +
31#include "../far/patchTable.h"
│ │ │ │ +
32
│ │ │ │ +
33namespace OpenSubdiv {
│ │ │ │ +
34namespace OPENSUBDIV_VERSION {
│ │ │ │ +
35
│ │ │ │ +
36namespace Far {
│ │ │ │ +
37
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
41public:
│ │ │ │ +
42
│ │ │ │ +
│ │ │ │ +
45 struct Options {
│ │ │ │
46
│ │ │ │ -
47namespace OpenSubdiv {
│ │ │ │ -
48namespace OPENSUBDIV_VERSION {
│ │ │ │ -
49
│ │ │ │ -
50namespace Far {
│ │ │ │ -
51
│ │ │ │ -
55template <typename REAL>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
57
│ │ │ │ -
58public:
│ │ │ │ -
59 PrimvarRefinerReal(TopologyRefiner const & refiner) : _refiner(refiner) { }
│ │ │ │ - │ │ │ │ -
61
│ │ │ │ -
62 TopologyRefiner const & GetTopologyRefiner() const { return _refiner; }
│ │ │ │ -
63
│ │ │ │ -
65
│ │ │ │ -
100
│ │ │ │ -
│ │ │ │ -
113 template <class T, class U> void Interpolate(int level, T const & src, U & dst) const;
│ │ │ │ +
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
61 };
│ │ │ │ +
│ │ │ │ +
62
│ │ │ │ +
│ │ │ │ +
63 Options(unsigned int maxIsolation=10) :
│ │ │ │ +
64 generateAllLevels(false),
│ │ │ │ + │ │ │ │ + │ │ │ │ +
67 triangulateQuads(false),
│ │ │ │ + │ │ │ │ +
69 useInfSharpPatch(false),
│ │ │ │ +
70 maxIsolationLevel(maxIsolation & 0xf),
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
75 generateFVarTables(false),
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
82 { }
│ │ │ │ +
│ │ │ │ +
83
│ │ │ │ + │ │ │ │ +
86
│ │ │ │ +
88 void SetEndCapType(EndCapType e) { endCapType = e & 0x7; }
│ │ │ │ +
89
│ │ │ │ +
91 void SetMaxIsolationLevel(unsigned int level) { maxIsolationLevel = level & 0xf; }
│ │ │ │ +
92
│ │ │ │ +
94 template <typename REAL> void SetPatchPrecision();
│ │ │ │ +
95
│ │ │ │ +
97 template <typename REAL> void SetFVarPatchPrecision();
│ │ │ │ +
98
│ │ │ │ +
│ │ │ │ + │ │ │ │ + │ │ │ │ +
102
│ │ │ │ +
103 adaptiveOptions.useInfSharpPatch = useInfSharpPatch;
│ │ │ │ + │ │ │ │ +
105 adaptiveOptions.considerFVarChannels = generateFVarTables &&
│ │ │ │ + │ │ │ │ +
107 return adaptiveOptions;
│ │ │ │ +
108 }
│ │ │ │ +
│ │ │ │ +
109
│ │ │ │ +
110 unsigned int generateAllLevels : 1,
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │
114
│ │ │ │ -
│ │ │ │ -
130 template <class T, class U> void InterpolateVarying(int level, T const & src, U & dst) const;
│ │ │ │ -
131
│ │ │ │ -
│ │ │ │ -
148 template <class T, class U> void InterpolateFaceUniform(int level, T const & src, U & dst) const;
│ │ │ │ -
149
│ │ │ │ -
│ │ │ │ -
161 template <class T, class U> void InterpolateFaceVarying(int level, T const & src, U & dst, int channel = 0) const;
│ │ │ │ -
162
│ │ │ │ -
163
│ │ │ │ -
│ │ │ │ -
175 template <class T, class U> void Limit(T const & src, U & dstPos) const;
│ │ │ │ -
176
│ │ │ │ -
177 template <class T, class U, class U1, class U2>
│ │ │ │ -
│ │ │ │ -
178 void Limit(T const & src, U & dstPos, U1 & dstTan1, U2 & dstTan2) const;
│ │ │ │ -
179
│ │ │ │ -
│ │ │ │ -
180 template <class T, class U> void LimitFaceVarying(T const & src, U & dst, int channel = 0) const;
│ │ │ │ -
181
│ │ │ │ -
183
│ │ │ │ -
184private:
│ │ │ │ -
185 typedef REAL Weight;
│ │ │ │ -
186
│ │ │ │ -
187 // Non-copyable:
│ │ │ │ -
188 PrimvarRefinerReal(PrimvarRefinerReal const & src) : _refiner(src._refiner) { }
│ │ │ │ -
189 PrimvarRefinerReal & operator=(PrimvarRefinerReal const &) { return *this; }
│ │ │ │ -
190
│ │ │ │ -
191 template <Sdc::SchemeType SCHEME, class T, class U> void interpFromFaces(int, T const &, U &) const;
│ │ │ │ -
192 template <Sdc::SchemeType SCHEME, class T, class U> void interpFromEdges(int, T const &, U &) const;
│ │ │ │ -
193 template <Sdc::SchemeType SCHEME, class T, class U> void interpFromVerts(int, T const &, U &) const;
│ │ │ │ -
194
│ │ │ │ -
195 template <Sdc::SchemeType SCHEME, class T, class U> void interpFVarFromFaces(int, T const &, U &, int) const;
│ │ │ │ -
196 template <Sdc::SchemeType SCHEME, class T, class U> void interpFVarFromEdges(int, T const &, U &, int) const;
│ │ │ │ -
197 template <Sdc::SchemeType SCHEME, class T, class U> void interpFVarFromVerts(int, T const &, U &, int) const;
│ │ │ │ -
198
│ │ │ │ -
199 template <Sdc::SchemeType SCHEME, class T, class U, class U1, class U2>
│ │ │ │ -
200 void limit(T const & src, U & pos, U1 * tan1, U2 * tan2) const;
│ │ │ │ -
201
│ │ │ │ -
202 template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
203 void limitFVar(T const & src, U & dst, int channel) const;
│ │ │ │ -
204
│ │ │ │ -
205private:
│ │ │ │ -
206 TopologyRefiner const & _refiner;
│ │ │ │ -
207
│ │ │ │ -
208private:
│ │ │ │ -
209 //
│ │ │ │ -
210 // Local class to fulfill interface for <typename MASK> in the Scheme mask queries:
│ │ │ │ -
211 //
│ │ │ │ -
212 class Mask {
│ │ │ │ -
213 public:
│ │ │ │ -
214 typedef REAL Weight; // Also part of the expected interface
│ │ │ │ -
215
│ │ │ │ -
216 public:
│ │ │ │ -
217 Mask(Weight* v, Weight* e, Weight* f) :
│ │ │ │ -
218 _vertWeights(v), _edgeWeights(e), _faceWeights(f),
│ │ │ │ -
219 _vertCount(0), _edgeCount(0), _faceCount(0),
│ │ │ │ -
220 _faceWeightsForFaceCenters(false)
│ │ │ │ -
221 { }
│ │ │ │ -
222
│ │ │ │ -
223 ~Mask() { }
│ │ │ │ -
224
│ │ │ │ -
225 public: // Generic interface expected of <typename MASK>:
│ │ │ │ -
226 int GetNumVertexWeights() const { return _vertCount; }
│ │ │ │ -
227 int GetNumEdgeWeights() const { return _edgeCount; }
│ │ │ │ -
228 int GetNumFaceWeights() const { return _faceCount; }
│ │ │ │ -
229
│ │ │ │ -
230 void SetNumVertexWeights(int count) { _vertCount = count; }
│ │ │ │ -
231 void SetNumEdgeWeights( int count) { _edgeCount = count; }
│ │ │ │ -
232 void SetNumFaceWeights( int count) { _faceCount = count; }
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
118
│ │ │ │ +
119 // end-capping
│ │ │ │ + │ │ │ │ + │ │ │ │ +
123
│ │ │ │ +
124 // varying
│ │ │ │ + │ │ │ │ + │ │ │ │ +
127
│ │ │ │ +
128 // face-varying
│ │ │ │ + │ │ │ │ +
130
│ │ │ │ +
131 // precision
│ │ │ │ + │ │ │ │ + │ │ │ │ +
134
│ │ │ │ +
135 // legacy behaviors (default to true)
│ │ │ │ + │ │ │ │ + │ │ │ │ +
138
│ │ │ │ + │ │ │ │ +
140 int const * fvarChannelIndices;
│ │ │ │ +
141 };
│ │ │ │ +
│ │ │ │ +
142
│ │ │ │ +
175 static PatchTable * Create(TopologyRefiner const & refiner,
│ │ │ │ +
176 Options options = Options(),
│ │ │ │ +
177 ConstIndexArray selectedFaces = ConstIndexArray());
│ │ │ │ +
178
│ │ │ │ +
179public:
│ │ │ │ +
180 // PatchFaceTag
│ │ │ │ +
181 //
│ │ │ │ +
182 // This simple struct was previously used within the factory to take inventory of
│ │ │ │ +
183 // various kinds of patches to fully allocate buffers prior to populating them. It
│ │ │ │ +
184 // was not intended to be exposed as part of the public interface.
│ │ │ │ +
185 //
│ │ │ │ +
186 // It is no longer used internally and is being kept here to respect preservation
│ │ │ │ +
187 // of the public interface, but it will be deprecated at the earliest opportunity.
│ │ │ │ +
188 //
│ │ │ │ +
191 //
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
193 public:
│ │ │ │ +
194 unsigned int _hasPatch : 1;
│ │ │ │ +
195 unsigned int _isRegular : 1;
│ │ │ │ +
196 unsigned int _transitionMask : 4;
│ │ │ │ +
197 unsigned int _boundaryMask : 4;
│ │ │ │ +
198 unsigned int _boundaryIndex : 2;
│ │ │ │ +
199 unsigned int _boundaryCount : 3;
│ │ │ │ +
200 unsigned int _hasBoundaryEdge : 3;
│ │ │ │ +
201 unsigned int _isSingleCrease : 1;
│ │ │ │ +
202
│ │ │ │ +
203 void clear();
│ │ │ │ +
204 void assignBoundaryPropertiesFromEdgeMask(int boundaryEdgeMask);
│ │ │ │ +
205 void assignBoundaryPropertiesFromVertexMask(int boundaryVertexMask);
│ │ │ │ +
206 void assignTransitionPropertiesFromEdgeMask(int boundaryVertexMask);
│ │ │ │ +
207 };
│ │ │ │ +
│ │ │ │ +
208 typedef std::vector<PatchFaceTag> PatchTagVector;
│ │ │ │ +
209};
│ │ │ │ +
│ │ │ │ +
210
│ │ │ │ +
211
│ │ │ │ +
│ │ │ │ +
212template <> inline void PatchTableFactory::Options::SetPatchPrecision<float>() {
│ │ │ │ +
213 patchPrecisionDouble = false;
│ │ │ │ +
214}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
215template <> inline void PatchTableFactory::Options::SetFVarPatchPrecision<float>() {
│ │ │ │ +
216 fvarPatchPrecisionDouble = false;
│ │ │ │ +
217}
│ │ │ │ +
│ │ │ │ +
218
│ │ │ │ +
219template <> inline void PatchTableFactory::Options::SetPatchPrecision<double>() {
│ │ │ │ +
220 patchPrecisionDouble = true;
│ │ │ │ +
221}
│ │ │ │ +
222template <> inline void PatchTableFactory::Options::SetFVarPatchPrecision<double>() {
│ │ │ │ +
223 fvarPatchPrecisionDouble = true;
│ │ │ │ +
224}
│ │ │ │ +
225
│ │ │ │ +
226
│ │ │ │ +
227} // end namespace Far
│ │ │ │ +
228
│ │ │ │ +
229} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
230using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
231
│ │ │ │ +
232} // end namespace OpenSubdiv
│ │ │ │
233
│ │ │ │ -
234 Weight const& VertexWeight(int index) const { return _vertWeights[index]; }
│ │ │ │ -
235 Weight const& EdgeWeight( int index) const { return _edgeWeights[index]; }
│ │ │ │ -
236 Weight const& FaceWeight( int index) const { return _faceWeights[index]; }
│ │ │ │ -
237
│ │ │ │ -
238 Weight& VertexWeight(int index) { return _vertWeights[index]; }
│ │ │ │ -
239 Weight& EdgeWeight( int index) { return _edgeWeights[index]; }
│ │ │ │ -
240 Weight& FaceWeight( int index) { return _faceWeights[index]; }
│ │ │ │ -
241
│ │ │ │ -
242 bool AreFaceWeightsForFaceCenters() const { return _faceWeightsForFaceCenters; }
│ │ │ │ -
243 void SetFaceWeightsForFaceCenters(bool on) { _faceWeightsForFaceCenters = on; }
│ │ │ │ -
244
│ │ │ │ -
245 private:
│ │ │ │ -
246 Weight* _vertWeights;
│ │ │ │ -
247 Weight* _edgeWeights;
│ │ │ │ -
248 Weight* _faceWeights;
│ │ │ │ -
249
│ │ │ │ -
250 int _vertCount;
│ │ │ │ -
251 int _edgeCount;
│ │ │ │ -
252 int _faceCount;
│ │ │ │ -
253
│ │ │ │ -
254 bool _faceWeightsForFaceCenters;
│ │ │ │ -
255 };
│ │ │ │ -
256};
│ │ │ │ -
257
│ │ │ │ -
258
│ │ │ │ -
259//
│ │ │ │ -
260// Public entry points to the methods. Queries of the scheme type and its
│ │ │ │ -
261// use as a template parameter in subsequent implementation will be factored
│ │ │ │ -
262// out of a later release:
│ │ │ │ -
263//
│ │ │ │ -
264template <typename REAL>
│ │ │ │ -
265template <class T, class U>
│ │ │ │ -
266inline void
│ │ │ │ -
│ │ │ │ -
267PrimvarRefinerReal<REAL>::Interpolate(int level, T const & src, U & dst) const {
│ │ │ │ -
268
│ │ │ │ -
269 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ -
270
│ │ │ │ -
271 switch (_refiner._subdivType) {
│ │ │ │ - │ │ │ │ -
273 interpFromFaces<Sdc::SCHEME_CATMARK>(level, src, dst);
│ │ │ │ -
274 interpFromEdges<Sdc::SCHEME_CATMARK>(level, src, dst);
│ │ │ │ -
275 interpFromVerts<Sdc::SCHEME_CATMARK>(level, src, dst);
│ │ │ │ -
276 break;
│ │ │ │ -
277 case Sdc::SCHEME_LOOP:
│ │ │ │ -
278 interpFromFaces<Sdc::SCHEME_LOOP>(level, src, dst);
│ │ │ │ -
279 interpFromEdges<Sdc::SCHEME_LOOP>(level, src, dst);
│ │ │ │ -
280 interpFromVerts<Sdc::SCHEME_LOOP>(level, src, dst);
│ │ │ │ -
281 break;
│ │ │ │ - │ │ │ │ -
283 interpFromFaces<Sdc::SCHEME_BILINEAR>(level, src, dst);
│ │ │ │ -
284 interpFromEdges<Sdc::SCHEME_BILINEAR>(level, src, dst);
│ │ │ │ -
285 interpFromVerts<Sdc::SCHEME_BILINEAR>(level, src, dst);
│ │ │ │ -
286 break;
│ │ │ │ -
287 }
│ │ │ │ -
288}
│ │ │ │ -
│ │ │ │ -
289
│ │ │ │ -
290template <typename REAL>
│ │ │ │ -
291template <class T, class U>
│ │ │ │ -
292inline void
│ │ │ │ -
│ │ │ │ -
293PrimvarRefinerReal<REAL>::InterpolateFaceVarying(int level, T const & src, U & dst, int channel) const {
│ │ │ │ -
294
│ │ │ │ -
295 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ -
296
│ │ │ │ -
297 switch (_refiner._subdivType) {
│ │ │ │ - │ │ │ │ -
299 interpFVarFromFaces<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
│ │ │ │ -
300 interpFVarFromEdges<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
│ │ │ │ -
301 interpFVarFromVerts<Sdc::SCHEME_CATMARK>(level, src, dst, channel);
│ │ │ │ -
302 break;
│ │ │ │ -
303 case Sdc::SCHEME_LOOP:
│ │ │ │ -
304 interpFVarFromFaces<Sdc::SCHEME_LOOP>(level, src, dst, channel);
│ │ │ │ -
305 interpFVarFromEdges<Sdc::SCHEME_LOOP>(level, src, dst, channel);
│ │ │ │ -
306 interpFVarFromVerts<Sdc::SCHEME_LOOP>(level, src, dst, channel);
│ │ │ │ -
307 break;
│ │ │ │ - │ │ │ │ -
309 interpFVarFromFaces<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
│ │ │ │ -
310 interpFVarFromEdges<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
│ │ │ │ -
311 interpFVarFromVerts<Sdc::SCHEME_BILINEAR>(level, src, dst, channel);
│ │ │ │ -
312 break;
│ │ │ │ -
313 }
│ │ │ │ -
314}
│ │ │ │ -
│ │ │ │ -
315
│ │ │ │ -
316template <typename REAL>
│ │ │ │ -
317template <class T, class U>
│ │ │ │ -
318inline void
│ │ │ │ -
│ │ │ │ -
319PrimvarRefinerReal<REAL>::Limit(T const & src, U & dst) const {
│ │ │ │ -
320
│ │ │ │ -
321 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == 0) {
│ │ │ │ - │ │ │ │ -
323 "Failure in PrimvarRefiner::Limit() -- "
│ │ │ │ -
324 "last level of refinement does not include full topology.");
│ │ │ │ -
325 return;
│ │ │ │ -
326 }
│ │ │ │ -
327
│ │ │ │ -
328 switch (_refiner._subdivType) {
│ │ │ │ - │ │ │ │ -
330 limit<Sdc::SCHEME_CATMARK>(src, dst, (U*)0, (U*)0);
│ │ │ │ -
331 break;
│ │ │ │ -
332 case Sdc::SCHEME_LOOP:
│ │ │ │ -
333 limit<Sdc::SCHEME_LOOP>(src, dst, (U*)0, (U*)0);
│ │ │ │ -
334 break;
│ │ │ │ - │ │ │ │ -
336 limit<Sdc::SCHEME_BILINEAR>(src, dst, (U*)0, (U*)0);
│ │ │ │ -
337 break;
│ │ │ │ -
338 }
│ │ │ │ -
339}
│ │ │ │ -
│ │ │ │ -
340
│ │ │ │ -
341template <typename REAL>
│ │ │ │ -
342template <class T, class U, class U1, class U2>
│ │ │ │ -
343inline void
│ │ │ │ -
│ │ │ │ -
344PrimvarRefinerReal<REAL>::Limit(T const & src, U & dstPos, U1 & dstTan1, U2 & dstTan2) const {
│ │ │ │ -
345
│ │ │ │ -
346 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == 0) {
│ │ │ │ - │ │ │ │ -
348 "Failure in PrimvarRefiner::Limit() -- "
│ │ │ │ -
349 "last level of refinement does not include full topology.");
│ │ │ │ -
350 return;
│ │ │ │ -
351 }
│ │ │ │ -
352
│ │ │ │ -
353 switch (_refiner._subdivType) {
│ │ │ │ - │ │ │ │ -
355 limit<Sdc::SCHEME_CATMARK>(src, dstPos, &dstTan1, &dstTan2);
│ │ │ │ -
356 break;
│ │ │ │ -
357 case Sdc::SCHEME_LOOP:
│ │ │ │ -
358 limit<Sdc::SCHEME_LOOP>(src, dstPos, &dstTan1, &dstTan2);
│ │ │ │ -
359 break;
│ │ │ │ - │ │ │ │ -
361 limit<Sdc::SCHEME_BILINEAR>(src, dstPos, &dstTan1, &dstTan2);
│ │ │ │ -
362 break;
│ │ │ │ -
363 }
│ │ │ │ -
364}
│ │ │ │ -
│ │ │ │ -
365
│ │ │ │ -
366template <typename REAL>
│ │ │ │ -
367template <class T, class U>
│ │ │ │ -
368inline void
│ │ │ │ -
│ │ │ │ -
369PrimvarRefinerReal<REAL>::LimitFaceVarying(T const & src, U & dst, int channel) const {
│ │ │ │ -
370
│ │ │ │ -
371 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == 0) {
│ │ │ │ - │ │ │ │ -
373 "Failure in PrimvarRefiner::LimitFaceVarying() -- "
│ │ │ │ -
374 "last level of refinement does not include full topology.");
│ │ │ │ -
375 return;
│ │ │ │ -
376 }
│ │ │ │ -
377
│ │ │ │ -
378 switch (_refiner._subdivType) {
│ │ │ │ - │ │ │ │ -
380 limitFVar<Sdc::SCHEME_CATMARK>(src, dst, channel);
│ │ │ │ -
381 break;
│ │ │ │ -
382 case Sdc::SCHEME_LOOP:
│ │ │ │ -
383 limitFVar<Sdc::SCHEME_LOOP>(src, dst, channel);
│ │ │ │ -
384 break;
│ │ │ │ - │ │ │ │ -
386 limitFVar<Sdc::SCHEME_BILINEAR>(src, dst, channel);
│ │ │ │ -
387 break;
│ │ │ │ -
388 }
│ │ │ │ -
389}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
390
│ │ │ │ -
391template <typename REAL>
│ │ │ │ -
392template <class T, class U>
│ │ │ │ -
393inline void
│ │ │ │ -
│ │ │ │ -
394PrimvarRefinerReal<REAL>::InterpolateFaceUniform(int level, T const & src, U & dst) const {
│ │ │ │ -
395
│ │ │ │ -
396 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ -
397
│ │ │ │ -
398 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
399 Vtr::internal::Level const & child = refinement.child();
│ │ │ │ -
400
│ │ │ │ -
401 for (int cFace = 0; cFace < child.getNumFaces(); ++cFace) {
│ │ │ │ -
402
│ │ │ │ -
403 Vtr::Index pFace = refinement.getChildFaceParentFace(cFace);
│ │ │ │ -
404
│ │ │ │ -
405 dst[cFace] = src[pFace];
│ │ │ │ -
406 }
│ │ │ │ -
407}
│ │ │ │ -
│ │ │ │ -
408
│ │ │ │ -
409template <typename REAL>
│ │ │ │ -
410template <class T, class U>
│ │ │ │ -
411inline void
│ │ │ │ -
│ │ │ │ -
412PrimvarRefinerReal<REAL>::InterpolateVarying(int level, T const & src, U & dst) const {
│ │ │ │ -
413
│ │ │ │ -
414 assert(level>0 && level<=(int)_refiner._refinements.size());
│ │ │ │ -
415
│ │ │ │ -
416 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
417 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ -
418
│ │ │ │ -
419 //
│ │ │ │ -
420 // Group values to interpolate based on origin -- note that there may
│ │ │ │ -
421 // be none originating from faces:
│ │ │ │ -
422 //
│ │ │ │ -
423 if (refinement.getNumChildVerticesFromFaces() > 0) {
│ │ │ │ -
424
│ │ │ │ -
425 for (int face = 0; face < parent.getNumFaces(); ++face) {
│ │ │ │ -
426
│ │ │ │ -
427 Vtr::Index cVert = refinement.getFaceChildVertex(face);
│ │ │ │ -
428 if (Vtr::IndexIsValid(cVert)) {
│ │ │ │ -
429
│ │ │ │ -
430 // Apply the weights to the parent face's vertices:
│ │ │ │ -
431 ConstIndexArray fVerts = parent.getFaceVertices(face);
│ │ │ │ -
432
│ │ │ │ -
433 Weight fVaryingWeight = 1.0f / (Weight) fVerts.size();
│ │ │ │ -
434
│ │ │ │ -
435 dst[cVert].Clear();
│ │ │ │ -
436 for (int i = 0; i < fVerts.size(); ++i) {
│ │ │ │ -
437 dst[cVert].AddWithWeight(src[fVerts[i]], fVaryingWeight);
│ │ │ │ -
438 }
│ │ │ │ -
439 }
│ │ │ │ -
440 }
│ │ │ │ -
441 }
│ │ │ │ -
442 for (int edge = 0; edge < parent.getNumEdges(); ++edge) {
│ │ │ │ -
443
│ │ │ │ -
444 Vtr::Index cVert = refinement.getEdgeChildVertex(edge);
│ │ │ │ -
445 if (Vtr::IndexIsValid(cVert)) {
│ │ │ │ -
446
│ │ │ │ -
447 // Apply the weights to the parent edges's vertices
│ │ │ │ -
448 ConstIndexArray eVerts = parent.getEdgeVertices(edge);
│ │ │ │ -
449
│ │ │ │ -
450 dst[cVert].Clear();
│ │ │ │ -
451 dst[cVert].AddWithWeight(src[eVerts[0]], 0.5f);
│ │ │ │ -
452 dst[cVert].AddWithWeight(src[eVerts[1]], 0.5f);
│ │ │ │ -
453 }
│ │ │ │ -
454 }
│ │ │ │ -
455 for (int vert = 0; vert < parent.getNumVertices(); ++vert) {
│ │ │ │ -
456
│ │ │ │ -
457 Vtr::Index cVert = refinement.getVertexChildVertex(vert);
│ │ │ │ -
458 if (Vtr::IndexIsValid(cVert)) {
│ │ │ │ -
459
│ │ │ │ -
460 // Essentially copy the parent vertex:
│ │ │ │ -
461 dst[cVert].Clear();
│ │ │ │ -
462 dst[cVert].AddWithWeight(src[vert], 1.0f);
│ │ │ │ -
463 }
│ │ │ │ -
464 }
│ │ │ │ -
465}
│ │ │ │ -
│ │ │ │ -
466
│ │ │ │ -
467
│ │ │ │ -
468//
│ │ │ │ -
469// Internal implementation methods -- grouping vertices to be interpolated
│ │ │ │ -
470// based on the type of parent component from which they originated:
│ │ │ │ -
471//
│ │ │ │ -
472template <typename REAL>
│ │ │ │ -
473template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
474inline void
│ │ │ │ -
475PrimvarRefinerReal<REAL>::interpFromFaces(int level, T const & src, U & dst) const {
│ │ │ │ -
476
│ │ │ │ -
477 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
478 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ -
479
│ │ │ │ -
480 if (refinement.getNumChildVerticesFromFaces() == 0) return;
│ │ │ │ -
481
│ │ │ │ -
482 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
483
│ │ │ │ -
484 Vtr::internal::StackBuffer<Weight,16> fVertWeights(parent.getMaxValence());
│ │ │ │ -
485
│ │ │ │ -
486 for (int face = 0; face < parent.getNumFaces(); ++face) {
│ │ │ │ -
487
│ │ │ │ -
488 Vtr::Index cVert = refinement.getFaceChildVertex(face);
│ │ │ │ -
489 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ -
490 continue;
│ │ │ │ -
491
│ │ │ │ -
492 // Declare and compute mask weights for this vertex relative to its parent face:
│ │ │ │ -
493 ConstIndexArray fVerts = parent.getFaceVertices(face);
│ │ │ │ -
494
│ │ │ │ -
495 Mask fMask(fVertWeights, 0, 0);
│ │ │ │ -
496 Vtr::internal::FaceInterface fHood(fVerts.size());
│ │ │ │ -
497
│ │ │ │ -
498 scheme.ComputeFaceVertexMask(fHood, fMask);
│ │ │ │ -
499
│ │ │ │ -
500 // Apply the weights to the parent face's vertices:
│ │ │ │ -
501 dst[cVert].Clear();
│ │ │ │ -
502
│ │ │ │ -
503 for (int i = 0; i < fVerts.size(); ++i) {
│ │ │ │ -
504
│ │ │ │ -
505 dst[cVert].AddWithWeight(src[fVerts[i]], fVertWeights[i]);
│ │ │ │ -
506 }
│ │ │ │ -
507 }
│ │ │ │ -
508}
│ │ │ │ -
509
│ │ │ │ -
510template <typename REAL>
│ │ │ │ -
511template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
512inline void
│ │ │ │ -
513PrimvarRefinerReal<REAL>::interpFromEdges(int level, T const & src, U & dst) const {
│ │ │ │ -
514
│ │ │ │ -
515 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
516 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ -
517 Vtr::internal::Level const & child = refinement.child();
│ │ │ │ -
518
│ │ │ │ -
519 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
520
│ │ │ │ -
521 Vtr::internal::EdgeInterface eHood(parent);
│ │ │ │ -
522
│ │ │ │ -
523 Weight eVertWeights[2];
│ │ │ │ -
524 Vtr::internal::StackBuffer<Weight,8> eFaceWeights(parent.getMaxEdgeFaces());
│ │ │ │ -
525
│ │ │ │ -
526 for (int edge = 0; edge < parent.getNumEdges(); ++edge) {
│ │ │ │ -
527
│ │ │ │ -
528 Vtr::Index cVert = refinement.getEdgeChildVertex(edge);
│ │ │ │ -
529 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ -
530 continue;
│ │ │ │ -
531
│ │ │ │ -
532 // Declare and compute mask weights for this vertex relative to its parent edge:
│ │ │ │ -
533 ConstIndexArray eVerts = parent.getEdgeVertices(edge),
│ │ │ │ -
534 eFaces = parent.getEdgeFaces(edge);
│ │ │ │ -
535
│ │ │ │ -
536 Mask eMask(eVertWeights, 0, eFaceWeights);
│ │ │ │ -
537
│ │ │ │ -
538 eHood.SetIndex(edge);
│ │ │ │ -
539
│ │ │ │ -
540 Sdc::Crease::Rule pRule = (parent.getEdgeSharpness(edge) > 0.0f) ? Sdc::Crease::RULE_CREASE : Sdc::Crease::RULE_SMOOTH;
│ │ │ │ -
541 Sdc::Crease::Rule cRule = child.getVertexRule(cVert);
│ │ │ │ -
542
│ │ │ │ -
543 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule);
│ │ │ │ -
544
│ │ │ │ -
545 // Apply the weights to the parent edges's vertices and (if applicable) to
│ │ │ │ -
546 // the child vertices of its incident faces:
│ │ │ │ -
547 dst[cVert].Clear();
│ │ │ │ -
548 dst[cVert].AddWithWeight(src[eVerts[0]], eVertWeights[0]);
│ │ │ │ -
549 dst[cVert].AddWithWeight(src[eVerts[1]], eVertWeights[1]);
│ │ │ │ -
550
│ │ │ │ -
551 if (eMask.GetNumFaceWeights() > 0) {
│ │ │ │ -
552
│ │ │ │ -
553 for (int i = 0; i < eFaces.size(); ++i) {
│ │ │ │ -
554
│ │ │ │ -
555 if (eMask.AreFaceWeightsForFaceCenters()) {
│ │ │ │ -
556 assert(refinement.getNumChildVerticesFromFaces() > 0);
│ │ │ │ -
557 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(eFaces[i]);
│ │ │ │ -
558
│ │ │ │ -
559 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ -
560 dst[cVert].AddWithWeight(dst[cVertOfFace], eFaceWeights[i]);
│ │ │ │ -
561 } else {
│ │ │ │ -
562 Vtr::Index pFace = eFaces[i];
│ │ │ │ -
563 ConstIndexArray pFaceEdges = parent.getFaceEdges(pFace),
│ │ │ │ -
564 pFaceVerts = parent.getFaceVertices(pFace);
│ │ │ │ -
565
│ │ │ │ -
566 int eInFace = 0;
│ │ │ │ -
567 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ;
│ │ │ │ -
568
│ │ │ │ -
569 int vInFace = eInFace + 2;
│ │ │ │ -
570 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts.size();
│ │ │ │ -
571
│ │ │ │ -
572 Vtr::Index pVertNext = pFaceVerts[vInFace];
│ │ │ │ -
573 dst[cVert].AddWithWeight(src[pVertNext], eFaceWeights[i]);
│ │ │ │ -
574 }
│ │ │ │ -
575 }
│ │ │ │ -
576 }
│ │ │ │ -
577 }
│ │ │ │ -
578}
│ │ │ │ -
579
│ │ │ │ -
580template <typename REAL>
│ │ │ │ -
581template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
582inline void
│ │ │ │ -
583PrimvarRefinerReal<REAL>::interpFromVerts(int level, T const & src, U & dst) const {
│ │ │ │ -
584
│ │ │ │ -
585 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
586 Vtr::internal::Level const & parent = refinement.parent();
│ │ │ │ -
587 Vtr::internal::Level const & child = refinement.child();
│ │ │ │ -
588
│ │ │ │ -
589 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
590
│ │ │ │ -
591 Vtr::internal::VertexInterface vHood(parent, child);
│ │ │ │ -
592
│ │ │ │ -
593 Vtr::internal::StackBuffer<Weight,32> weightBuffer(2*parent.getMaxValence());
│ │ │ │ -
594
│ │ │ │ -
595 for (int vert = 0; vert < parent.getNumVertices(); ++vert) {
│ │ │ │ -
596
│ │ │ │ -
597 Vtr::Index cVert = refinement.getVertexChildVertex(vert);
│ │ │ │ -
598 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ -
599 continue;
│ │ │ │ -
600
│ │ │ │ -
601 // Declare and compute mask weights for this vertex relative to its parent edge:
│ │ │ │ -
602 ConstIndexArray vEdges = parent.getVertexEdges(vert),
│ │ │ │ -
603 vFaces = parent.getVertexFaces(vert);
│ │ │ │ -
604
│ │ │ │ -
605 Weight vVertWeight,
│ │ │ │ -
606 * vEdgeWeights = weightBuffer,
│ │ │ │ -
607 * vFaceWeights = vEdgeWeights + vEdges.size();
│ │ │ │ -
608
│ │ │ │ -
609 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights);
│ │ │ │ -
610
│ │ │ │ -
611 vHood.SetIndex(vert, cVert);
│ │ │ │ -
612
│ │ │ │ -
613 Sdc::Crease::Rule pRule = parent.getVertexRule(vert);
│ │ │ │ -
614 Sdc::Crease::Rule cRule = child.getVertexRule(cVert);
│ │ │ │ -
615
│ │ │ │ -
616 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule);
│ │ │ │ -
617
│ │ │ │ -
618 // Apply the weights to the parent vertex, the vertices opposite its incident
│ │ │ │ -
619 // edges, and the child vertices of its incident faces:
│ │ │ │ -
620 //
│ │ │ │ -
621 // In order to improve numerical precision, it's better to apply smaller weights
│ │ │ │ -
622 // first, so begin with the face-weights followed by the edge-weights and the
│ │ │ │ -
623 // vertex weight last.
│ │ │ │ -
624 dst[cVert].Clear();
│ │ │ │ -
625
│ │ │ │ -
626 if (vMask.GetNumFaceWeights() > 0) {
│ │ │ │ -
627 assert(vMask.AreFaceWeightsForFaceCenters());
│ │ │ │ -
628
│ │ │ │ -
629 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ -
630
│ │ │ │ -
631 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(vFaces[i]);
│ │ │ │ -
632 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ -
633 dst[cVert].AddWithWeight(dst[cVertOfFace], vFaceWeights[i]);
│ │ │ │ -
634 }
│ │ │ │ -
635 }
│ │ │ │ -
636 if (vMask.GetNumEdgeWeights() > 0) {
│ │ │ │ -
637
│ │ │ │ -
638 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ -
639
│ │ │ │ -
640 ConstIndexArray eVerts = parent.getEdgeVertices(vEdges[i]);
│ │ │ │ -
641 Vtr::Index pVertOppositeEdge = (eVerts[0] == vert) ? eVerts[1] : eVerts[0];
│ │ │ │ -
642
│ │ │ │ -
643 dst[cVert].AddWithWeight(src[pVertOppositeEdge], vEdgeWeights[i]);
│ │ │ │ -
644 }
│ │ │ │ -
645 }
│ │ │ │ -
646 dst[cVert].AddWithWeight(src[vert], vVertWeight);
│ │ │ │ -
647 }
│ │ │ │ -
648}
│ │ │ │ -
649
│ │ │ │ -
650
│ │ │ │ -
651//
│ │ │ │ -
652// Internal face-varying implementation details:
│ │ │ │ -
653//
│ │ │ │ -
654template <typename REAL>
│ │ │ │ -
655template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
656inline void
│ │ │ │ -
657PrimvarRefinerReal<REAL>::interpFVarFromFaces(int level, T const & src, U & dst, int channel) const {
│ │ │ │ -
658
│ │ │ │ -
659 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
660
│ │ │ │ -
661 if (refinement.getNumChildVerticesFromFaces() == 0) return;
│ │ │ │ -
662
│ │ │ │ -
663 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
664
│ │ │ │ -
665 Vtr::internal::Level const & parentLevel = refinement.parent();
│ │ │ │ -
666 Vtr::internal::Level const & childLevel = refinement.child();
│ │ │ │ -
667
│ │ │ │ -
668 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel(channel);
│ │ │ │ -
669 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel(channel);
│ │ │ │ -
670
│ │ │ │ -
671 Vtr::internal::StackBuffer<Weight,16> fValueWeights(parentLevel.getMaxValence());
│ │ │ │ -
672
│ │ │ │ -
673 for (int face = 0; face < parentLevel.getNumFaces(); ++face) {
│ │ │ │ -
674
│ │ │ │ -
675 Vtr::Index cVert = refinement.getFaceChildVertex(face);
│ │ │ │ -
676 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ -
677 continue;
│ │ │ │ -
678
│ │ │ │ -
679 Vtr::Index cVertValue = childFVar.getVertexValueOffset(cVert);
│ │ │ │ -
680
│ │ │ │ -
681 // The only difference for face-varying here is that we get the values associated
│ │ │ │ -
682 // with each face-vertex directly from the FVarLevel, rather than using the parent
│ │ │ │ -
683 // face-vertices directly. If any face-vertex has any sibling values, then we may
│ │ │ │ -
684 // get the wrong one using the face-vertex index directly.
│ │ │ │ -
685
│ │ │ │ -
686 // Declare and compute mask weights for this vertex relative to its parent face:
│ │ │ │ -
687 ConstIndexArray fValues = parentFVar.getFaceValues(face);
│ │ │ │ -
688
│ │ │ │ -
689 Mask fMask(fValueWeights, 0, 0);
│ │ │ │ -
690 Vtr::internal::FaceInterface fHood(fValues.size());
│ │ │ │ -
691
│ │ │ │ -
692 scheme.ComputeFaceVertexMask(fHood, fMask);
│ │ │ │ -
693
│ │ │ │ -
694 // Apply the weights to the parent face's vertices:
│ │ │ │ -
695 dst[cVertValue].Clear();
│ │ │ │ -
696
│ │ │ │ -
697 for (int i = 0; i < fValues.size(); ++i) {
│ │ │ │ -
698 dst[cVertValue].AddWithWeight(src[fValues[i]], fValueWeights[i]);
│ │ │ │ -
699 }
│ │ │ │ -
700 }
│ │ │ │ -
701}
│ │ │ │ -
702
│ │ │ │ -
703template <typename REAL>
│ │ │ │ -
704template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
705inline void
│ │ │ │ -
706PrimvarRefinerReal<REAL>::interpFVarFromEdges(int level, T const & src, U & dst, int channel) const {
│ │ │ │ -
707
│ │ │ │ -
708 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
709
│ │ │ │ -
710 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
711
│ │ │ │ -
712 Vtr::internal::Level const & parentLevel = refinement.parent();
│ │ │ │ -
713 Vtr::internal::Level const & childLevel = refinement.child();
│ │ │ │ -
714
│ │ │ │ -
715 Vtr::internal::FVarRefinement const & refineFVar = refinement.getFVarRefinement(channel);
│ │ │ │ -
716 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel(channel);
│ │ │ │ -
717 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel(channel);
│ │ │ │ -
718
│ │ │ │ -
719 //
│ │ │ │ -
720 // Allocate and initialize (if linearly interpolated) interpolation weights for
│ │ │ │ -
721 // the edge mask:
│ │ │ │ -
722 //
│ │ │ │ -
723 Weight eVertWeights[2];
│ │ │ │ -
724 Vtr::internal::StackBuffer<Weight,8> eFaceWeights(parentLevel.getMaxEdgeFaces());
│ │ │ │ -
725
│ │ │ │ -
726 Mask eMask(eVertWeights, 0, eFaceWeights);
│ │ │ │ -
727
│ │ │ │ -
728 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == Sdc::SCHEME_BILINEAR);
│ │ │ │ -
729 if (isLinearFVar) {
│ │ │ │ -
730 eMask.SetNumVertexWeights(2);
│ │ │ │ -
731 eMask.SetNumEdgeWeights(0);
│ │ │ │ -
732 eMask.SetNumFaceWeights(0);
│ │ │ │ -
733
│ │ │ │ -
734 eVertWeights[0] = 0.5f;
│ │ │ │ -
735 eVertWeights[1] = 0.5f;
│ │ │ │ -
736 }
│ │ │ │ -
737
│ │ │ │ -
738 Vtr::internal::EdgeInterface eHood(parentLevel);
│ │ │ │ -
739
│ │ │ │ -
740 for (int edge = 0; edge < parentLevel.getNumEdges(); ++edge) {
│ │ │ │ -
741
│ │ │ │ -
742 Vtr::Index cVert = refinement.getEdgeChildVertex(edge);
│ │ │ │ -
743 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ -
744 continue;
│ │ │ │ -
745
│ │ │ │ -
746 ConstIndexArray cVertValues = childFVar.getVertexValues(cVert);
│ │ │ │ -
747
│ │ │ │ -
748 bool fvarEdgeVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues[0]);
│ │ │ │ -
749 if (fvarEdgeVertMatchesVertex) {
│ │ │ │ -
750 //
│ │ │ │ -
751 // If smoothly interpolated, compute new weights for the edge mask:
│ │ │ │ -
752 //
│ │ │ │ -
753 if (!isLinearFVar) {
│ │ │ │ -
754 eHood.SetIndex(edge);
│ │ │ │ -
755
│ │ │ │ -
756 Sdc::Crease::Rule pRule = (parentLevel.getEdgeSharpness(edge) > 0.0f)
│ │ │ │ -
757 ? Sdc::Crease::RULE_CREASE : Sdc::Crease::RULE_SMOOTH;
│ │ │ │ -
758 Sdc::Crease::Rule cRule = childLevel.getVertexRule(cVert);
│ │ │ │ -
759
│ │ │ │ -
760 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule);
│ │ │ │ -
761 }
│ │ │ │ -
762
│ │ │ │ -
763 // Apply the weights to the parent edge's vertices and (if applicable) to
│ │ │ │ -
764 // the child vertices of its incident faces:
│ │ │ │ -
765 //
│ │ │ │ -
766 // Even though the face-varying topology matches the vertex topology, we need
│ │ │ │ -
767 // to be careful here when getting values corresponding to the two end-vertices.
│ │ │ │ -
768 // While the edge may be continuous, the vertices at their ends may have
│ │ │ │ -
769 // discontinuities elsewhere in their neighborhood (i.e. on the "other side"
│ │ │ │ -
770 // of the end-vertex) and so have sibling values associated with them. In most
│ │ │ │ -
771 // cases the topology for an end-vertex will match and we can use it directly,
│ │ │ │ -
772 // but we must still check and retrieve as needed.
│ │ │ │ -
773 //
│ │ │ │ -
774 // Indices for values corresponding to face-vertices are guaranteed to match,
│ │ │ │ -
775 // so we can use the child-vertex indices directly.
│ │ │ │ -
776 //
│ │ │ │ -
777 // And by "directly", we always use getVertexValue(vertexIndex) to reference
│ │ │ │ -
778 // values in the "src" to account for the possible indirection that may exist at
│ │ │ │ -
779 // level 0 -- where there may be fewer values than vertices and an additional
│ │ │ │ -
780 // indirection is necessary. We can use a vertex index directly for "dst" when
│ │ │ │ -
781 // it matches.
│ │ │ │ -
782 //
│ │ │ │ -
783 Vtr::Index eVertValues[2];
│ │ │ │ -
784
│ │ │ │ -
785 parentFVar.getEdgeFaceValues(edge, 0, eVertValues);
│ │ │ │ -
786
│ │ │ │ -
787 Index cVertValue = cVertValues[0];
│ │ │ │ -
788
│ │ │ │ -
789 dst[cVertValue].Clear();
│ │ │ │ -
790 dst[cVertValue].AddWithWeight(src[eVertValues[0]], eVertWeights[0]);
│ │ │ │ -
791 dst[cVertValue].AddWithWeight(src[eVertValues[1]], eVertWeights[1]);
│ │ │ │ -
792
│ │ │ │ -
793 if (eMask.GetNumFaceWeights() > 0) {
│ │ │ │ -
794
│ │ │ │ -
795 ConstIndexArray eFaces = parentLevel.getEdgeFaces(edge);
│ │ │ │ -
796
│ │ │ │ -
797 for (int i = 0; i < eFaces.size(); ++i) {
│ │ │ │ -
798 if (eMask.AreFaceWeightsForFaceCenters()) {
│ │ │ │ -
799
│ │ │ │ -
800 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(eFaces[i]);
│ │ │ │ -
801 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ -
802
│ │ │ │ -
803 Vtr::Index cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace);
│ │ │ │ -
804 dst[cVertValue].AddWithWeight(dst[cValueOfFace], eFaceWeights[i]);
│ │ │ │ -
805 } else {
│ │ │ │ -
806 Vtr::Index pFace = eFaces[i];
│ │ │ │ -
807 ConstIndexArray pFaceEdges = parentLevel.getFaceEdges(pFace),
│ │ │ │ -
808 pFaceVerts = parentLevel.getFaceVertices(pFace);
│ │ │ │ -
809
│ │ │ │ -
810 int eInFace = 0;
│ │ │ │ -
811 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ;
│ │ │ │ -
812
│ │ │ │ -
813 // Edge "i" spans vertices [i,i+1] so we want i+2...
│ │ │ │ -
814 int vInFace = eInFace + 2;
│ │ │ │ -
815 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts.size();
│ │ │ │ -
816
│ │ │ │ -
817 Vtr::Index pValueNext = parentFVar.getFaceValues(pFace)[vInFace];
│ │ │ │ -
818 dst[cVertValue].AddWithWeight(src[pValueNext], eFaceWeights[i]);
│ │ │ │ -
819 }
│ │ │ │ -
820 }
│ │ │ │ -
821 }
│ │ │ │ -
822 } else {
│ │ │ │ -
823 //
│ │ │ │ -
824 // Mismatched edge-verts should just be linearly interpolated between the pairs of
│ │ │ │ -
825 // values for each sibling of the child edge-vertex -- the question is: which face
│ │ │ │ -
826 // holds that pair of values for a given sibling?
│ │ │ │ -
827 //
│ │ │ │ -
828 // In the manifold case, the sibling and edge-face indices will correspond. We
│ │ │ │ -
829 // will eventually need to update this to account for > 3 incident faces.
│ │ │ │ -
830 //
│ │ │ │ -
831 for (int i = 0; i < cVertValues.size(); ++i) {
│ │ │ │ -
832 Vtr::Index eVertValues[2];
│ │ │ │ -
833 int eFaceIndex = refineFVar.getChildValueParentSource(cVert, i);
│ │ │ │ -
834 assert(eFaceIndex == i);
│ │ │ │ -
835
│ │ │ │ -
836 parentFVar.getEdgeFaceValues(edge, eFaceIndex, eVertValues);
│ │ │ │ -
837
│ │ │ │ -
838 Index cVertValue = cVertValues[i];
│ │ │ │ -
839
│ │ │ │ -
840 dst[cVertValue].Clear();
│ │ │ │ -
841 dst[cVertValue].AddWithWeight(src[eVertValues[0]], 0.5);
│ │ │ │ -
842 dst[cVertValue].AddWithWeight(src[eVertValues[1]], 0.5);
│ │ │ │ -
843 }
│ │ │ │ -
844 }
│ │ │ │ -
845 }
│ │ │ │ -
846}
│ │ │ │ -
847
│ │ │ │ -
848template <typename REAL>
│ │ │ │ -
849template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
850inline void
│ │ │ │ -
851PrimvarRefinerReal<REAL>::interpFVarFromVerts(int level, T const & src, U & dst, int channel) const {
│ │ │ │ -
852
│ │ │ │ -
853 Vtr::internal::Refinement const & refinement = _refiner.getRefinement(level-1);
│ │ │ │ -
854
│ │ │ │ -
855 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
856
│ │ │ │ -
857 Vtr::internal::Level const & parentLevel = refinement.parent();
│ │ │ │ -
858 Vtr::internal::Level const & childLevel = refinement.child();
│ │ │ │ -
859
│ │ │ │ -
860 Vtr::internal::FVarRefinement const & refineFVar = refinement.getFVarRefinement(channel);
│ │ │ │ -
861 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel(channel);
│ │ │ │ -
862 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel(channel);
│ │ │ │ -
863
│ │ │ │ -
864 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == Sdc::SCHEME_BILINEAR);
│ │ │ │ -
865
│ │ │ │ -
866 Vtr::internal::StackBuffer<Weight,32> weightBuffer(2*parentLevel.getMaxValence());
│ │ │ │ -
867
│ │ │ │ -
868 Vtr::internal::StackBuffer<Vtr::Index,16> vEdgeValues(parentLevel.getMaxValence());
│ │ │ │ -
869
│ │ │ │ -
870 Vtr::internal::VertexInterface vHood(parentLevel, childLevel);
│ │ │ │ -
871
│ │ │ │ -
872 for (int vert = 0; vert < parentLevel.getNumVertices(); ++vert) {
│ │ │ │ -
873
│ │ │ │ -
874 Vtr::Index cVert = refinement.getVertexChildVertex(vert);
│ │ │ │ -
875 if (!Vtr::IndexIsValid(cVert))
│ │ │ │ -
876 continue;
│ │ │ │ -
877
│ │ │ │ -
878 ConstIndexArray pVertValues = parentFVar.getVertexValues(vert),
│ │ │ │ -
879 cVertValues = childFVar.getVertexValues(cVert);
│ │ │ │ -
880
│ │ │ │ -
881 bool fvarVertVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues[0]);
│ │ │ │ -
882 if (isLinearFVar && fvarVertVertMatchesVertex) {
│ │ │ │ -
883 dst[cVertValues[0]].Clear();
│ │ │ │ -
884 dst[cVertValues[0]].AddWithWeight(src[pVertValues[0]], 1.0f);
│ │ │ │ -
885 continue;
│ │ │ │ -
886 }
│ │ │ │ -
887
│ │ │ │ -
888 if (fvarVertVertMatchesVertex) {
│ │ │ │ -
889 //
│ │ │ │ -
890 // Declare and compute mask weights for this vertex relative to its parent edge:
│ │ │ │ -
891 //
│ │ │ │ -
892 // (We really need to encapsulate this somewhere else for use here and in the
│ │ │ │ -
893 // general case)
│ │ │ │ -
894 //
│ │ │ │ -
895 ConstIndexArray vEdges = parentLevel.getVertexEdges(vert);
│ │ │ │ -
896
│ │ │ │ -
897 Weight vVertWeight;
│ │ │ │ -
898 Weight * vEdgeWeights = weightBuffer;
│ │ │ │ -
899 Weight * vFaceWeights = vEdgeWeights + vEdges.size();
│ │ │ │ -
900
│ │ │ │ -
901 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights);
│ │ │ │ -
902
│ │ │ │ -
903 vHood.SetIndex(vert, cVert);
│ │ │ │ -
904
│ │ │ │ -
905 Sdc::Crease::Rule pRule = parentLevel.getVertexRule(vert);
│ │ │ │ -
906 Sdc::Crease::Rule cRule = childLevel.getVertexRule(cVert);
│ │ │ │ -
907
│ │ │ │ -
908 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule);
│ │ │ │ -
909
│ │ │ │ -
910 // Apply the weights to the parent vertex, the vertices opposite its incident
│ │ │ │ -
911 // edges, and the child vertices of its incident faces:
│ │ │ │ -
912 //
│ │ │ │ -
913 // Even though the face-varying topology matches the vertex topology, we need
│ │ │ │ -
914 // to be careful here when getting values corresponding to vertices at the
│ │ │ │ -
915 // ends of edges. While the edge may be continuous, the end vertex may have
│ │ │ │ -
916 // discontinuities elsewhere in their neighborhood (i.e. on the "other side"
│ │ │ │ -
917 // of the end-vertex) and so have sibling values associated with them. In most
│ │ │ │ -
918 // cases the topology for an end-vertex will match and we can use it directly,
│ │ │ │ -
919 // but we must still check and retrieve as needed.
│ │ │ │ -
920 //
│ │ │ │ -
921 // Indices for values corresponding to face-vertices are guaranteed to match,
│ │ │ │ -
922 // so we can use the child-vertex indices directly.
│ │ │ │ -
923 //
│ │ │ │ -
924 // And by "directly", we always use getVertexValue(vertexIndex) to reference
│ │ │ │ -
925 // values in the "src" to account for the possible indirection that may exist at
│ │ │ │ -
926 // level 0 -- where there may be fewer values than vertices and an additional
│ │ │ │ -
927 // indirection is necessary. We can use a vertex index directly for "dst" when
│ │ │ │ -
928 // it matches.
│ │ │ │ -
929 //
│ │ │ │ -
930 // As with applying the mask to vertex data, in order to improve numerical
│ │ │ │ -
931 // precision, it's better to apply smaller weights first, so begin with the
│ │ │ │ -
932 // face-weights followed by the edge-weights and the vertex weight last.
│ │ │ │ -
933 //
│ │ │ │ -
934 Vtr::Index pVertValue = pVertValues[0];
│ │ │ │ -
935 Vtr::Index cVertValue = cVertValues[0];
│ │ │ │ -
936
│ │ │ │ -
937 dst[cVertValue].Clear();
│ │ │ │ -
938 if (vMask.GetNumFaceWeights() > 0) {
│ │ │ │ -
939 assert(vMask.AreFaceWeightsForFaceCenters());
│ │ │ │ -
940
│ │ │ │ -
941 ConstIndexArray vFaces = parentLevel.getVertexFaces(vert);
│ │ │ │ -
942
│ │ │ │ -
943 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ -
944
│ │ │ │ -
945 Vtr::Index cVertOfFace = refinement.getFaceChildVertex(vFaces[i]);
│ │ │ │ -
946 assert(Vtr::IndexIsValid(cVertOfFace));
│ │ │ │ -
947
│ │ │ │ -
948 Vtr::Index cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace);
│ │ │ │ -
949 dst[cVertValue].AddWithWeight(dst[cValueOfFace], vFaceWeights[i]);
│ │ │ │ -
950 }
│ │ │ │ -
951 }
│ │ │ │ -
952 if (vMask.GetNumEdgeWeights() > 0) {
│ │ │ │ -
953
│ │ │ │ -
954 parentFVar.getVertexEdgeValues(vert, vEdgeValues);
│ │ │ │ -
955
│ │ │ │ -
956 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ -
957 dst[cVertValue].AddWithWeight(src[vEdgeValues[i]], vEdgeWeights[i]);
│ │ │ │ -
958 }
│ │ │ │ -
959 }
│ │ │ │ -
960 dst[cVertValue].AddWithWeight(src[pVertValue], vVertWeight);
│ │ │ │ -
961 } else {
│ │ │ │ -
962 //
│ │ │ │ -
963 // Each FVar value associated with a vertex will be either a corner or a crease,
│ │ │ │ -
964 // or potentially in transition from corner to crease:
│ │ │ │ -
965 // - if the CHILD is a corner, there can be no transition so we have a corner
│ │ │ │ -
966 // - otherwise if the PARENT is a crease, both will be creases (no transition)
│ │ │ │ -
967 // - otherwise the parent must be a corner and the child a crease (transition)
│ │ │ │ -
968 //
│ │ │ │ -
969 Vtr::internal::FVarLevel::ConstValueTagArray pValueTags = parentFVar.getVertexValueTags(vert);
│ │ │ │ -
970 Vtr::internal::FVarLevel::ConstValueTagArray cValueTags = childFVar.getVertexValueTags(cVert);
│ │ │ │ -
971
│ │ │ │ -
972 for (int cSiblingIndex = 0; cSiblingIndex < cVertValues.size(); ++cSiblingIndex) {
│ │ │ │ -
973 int pSiblingIndex = refineFVar.getChildValueParentSource(cVert, cSiblingIndex);
│ │ │ │ -
974 assert(pSiblingIndex == cSiblingIndex);
│ │ │ │ -
975
│ │ │ │ -
976 typedef Vtr::internal::FVarLevel::Sibling SiblingIntType;
│ │ │ │ -
977
│ │ │ │ -
978 SiblingIntType cSibling = (SiblingIntType) cSiblingIndex;
│ │ │ │ -
979 SiblingIntType pSibling = (SiblingIntType) pSiblingIndex;
│ │ │ │ -
980
│ │ │ │ -
981 Vtr::Index pVertValue = pVertValues[pSibling];
│ │ │ │ -
982 Vtr::Index cVertValue = cVertValues[cSibling];
│ │ │ │ -
983
│ │ │ │ -
984 dst[cVertValue].Clear();
│ │ │ │ -
985 if (isLinearFVar || cValueTags[cSibling].isCorner()) {
│ │ │ │ -
986 dst[cVertValue].AddWithWeight(src[pVertValue], 1.0f);
│ │ │ │ -
987 } else {
│ │ │ │ -
988 //
│ │ │ │ -
989 // We have either a crease or a transition from corner to crease -- in
│ │ │ │ -
990 // either case, we need the end values for the full/fractional crease:
│ │ │ │ -
991 //
│ │ │ │ -
992 Index pEndValues[2];
│ │ │ │ -
993 parentFVar.getVertexCreaseEndValues(vert, pSibling, pEndValues);
│ │ │ │ -
994
│ │ │ │ -
995 Weight vWeight = 0.75f;
│ │ │ │ -
996 Weight eWeight = 0.125f;
│ │ │ │ -
997
│ │ │ │ -
998 //
│ │ │ │ -
999 // If semi-sharp we need to apply fractional weighting -- if made sharp because
│ │ │ │ -
1000 // of the other sibling (dependent-sharp) use the fractional weight from that
│ │ │ │ -
1001 // other sibling (should only occur when there are 2):
│ │ │ │ -
1002 //
│ │ │ │ -
1003 if (pValueTags[pSibling].isSemiSharp()) {
│ │ │ │ -
1004 Weight wCorner = pValueTags[pSibling].isDepSharp()
│ │ │ │ -
1005 ? refineFVar.getFractionalWeight(vert, !pSibling, cVert, !cSibling)
│ │ │ │ -
1006 : refineFVar.getFractionalWeight(vert, pSibling, cVert, cSibling);
│ │ │ │ -
1007 Weight wCrease = 1.0f - wCorner;
│ │ │ │ -
1008
│ │ │ │ -
1009 vWeight = wCrease * 0.75f + wCorner;
│ │ │ │ -
1010 eWeight = wCrease * 0.125f;
│ │ │ │ -
1011 }
│ │ │ │ -
1012 dst[cVertValue].AddWithWeight(src[pEndValues[0]], eWeight);
│ │ │ │ -
1013 dst[cVertValue].AddWithWeight(src[pEndValues[1]], eWeight);
│ │ │ │ -
1014 dst[cVertValue].AddWithWeight(src[pVertValue], vWeight);
│ │ │ │ -
1015 }
│ │ │ │ -
1016 }
│ │ │ │ -
1017 }
│ │ │ │ -
1018 }
│ │ │ │ -
1019}
│ │ │ │ -
1020
│ │ │ │ -
1021template <typename REAL>
│ │ │ │ -
1022template <Sdc::SchemeType SCHEME, class T, class U, class U1, class U2>
│ │ │ │ -
1023inline void
│ │ │ │ -
1024PrimvarRefinerReal<REAL>::limit(T const & src, U & dstPos, U1 * dstTan1Ptr, U2 * dstTan2Ptr) const {
│ │ │ │ -
1025
│ │ │ │ -
1026 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
1027
│ │ │ │ -
1028 Vtr::internal::Level const & level = _refiner.getLevel(_refiner.GetMaxLevel());
│ │ │ │ -
1029
│ │ │ │ -
1030 int maxWeightsPerMask = 1 + 2 * level.getMaxValence();
│ │ │ │ -
1031 bool hasTangents = (dstTan1Ptr && dstTan2Ptr);
│ │ │ │ -
1032 int numMasks = 1 + (hasTangents ? 2 : 0);
│ │ │ │ -
1033
│ │ │ │ -
1034 Vtr::internal::StackBuffer<Index,33> indexBuffer(maxWeightsPerMask);
│ │ │ │ -
1035 Vtr::internal::StackBuffer<Weight,99> weightBuffer(numMasks * maxWeightsPerMask);
│ │ │ │ -
1036
│ │ │ │ -
1037 Weight * vPosWeights = weightBuffer,
│ │ │ │ -
1038 * ePosWeights = vPosWeights + 1,
│ │ │ │ -
1039 * fPosWeights = ePosWeights + level.getMaxValence();
│ │ │ │ -
1040 Weight * vTan1Weights = vPosWeights + maxWeightsPerMask,
│ │ │ │ -
1041 * eTan1Weights = ePosWeights + maxWeightsPerMask,
│ │ │ │ -
1042 * fTan1Weights = fPosWeights + maxWeightsPerMask;
│ │ │ │ -
1043 Weight * vTan2Weights = vTan1Weights + maxWeightsPerMask,
│ │ │ │ -
1044 * eTan2Weights = eTan1Weights + maxWeightsPerMask,
│ │ │ │ -
1045 * fTan2Weights = fTan1Weights + maxWeightsPerMask;
│ │ │ │ -
1046
│ │ │ │ -
1047 Mask posMask( vPosWeights, ePosWeights, fPosWeights);
│ │ │ │ -
1048 Mask tan1Mask(vTan1Weights, eTan1Weights, fTan1Weights);
│ │ │ │ -
1049 Mask tan2Mask(vTan2Weights, eTan2Weights, fTan2Weights);
│ │ │ │ -
1050
│ │ │ │ -
1051 // This is a bit obscure -- assigning both parent and child as last level -- but
│ │ │ │ -
1052 // this mask type was intended for another purpose. Consider one for the limit:
│ │ │ │ -
1053 Vtr::internal::VertexInterface vHood(level, level);
│ │ │ │ -
1054
│ │ │ │ -
1055 for (int vert = 0; vert < level.getNumVertices(); ++vert) {
│ │ │ │ -
1056 ConstIndexArray vEdges = level.getVertexEdges(vert);
│ │ │ │ -
1057
│ │ │ │ -
1058 // Incomplete vertices (present in sparse refinement) do not have their full
│ │ │ │ -
1059 // topological neighborhood to determine a proper limit -- just leave the
│ │ │ │ -
1060 // vertex at the refined location and continue to the next:
│ │ │ │ -
1061 if (level.getVertexTag(vert)._incomplete || (vEdges.size() == 0)) {
│ │ │ │ -
1062 dstPos[vert].Clear();
│ │ │ │ -
1063 dstPos[vert].AddWithWeight(src[vert], 1.0);
│ │ │ │ -
1064 if (hasTangents) {
│ │ │ │ -
1065 (*dstTan1Ptr)[vert].Clear();
│ │ │ │ -
1066 (*dstTan2Ptr)[vert].Clear();
│ │ │ │ -
1067 }
│ │ │ │ -
1068 continue;
│ │ │ │ -
1069 }
│ │ │ │ -
1070
│ │ │ │ -
1071 //
│ │ │ │ -
1072 // Limit masks require the subdivision Rule for the vertex in order to deal
│ │ │ │ -
1073 // with infinitely sharp features correctly -- including boundaries and corners.
│ │ │ │ -
1074 // The vertex neighborhood is minimally defined with vertex and edge counts.
│ │ │ │ -
1075 //
│ │ │ │ -
1076 Sdc::Crease::Rule vRule = level.getVertexRule(vert);
│ │ │ │ -
1077
│ │ │ │ -
1078 // This is a bit obscure -- child vertex index will be ignored here
│ │ │ │ -
1079 vHood.SetIndex(vert, vert);
│ │ │ │ -
1080
│ │ │ │ -
1081 if (hasTangents) {
│ │ │ │ -
1082 scheme.ComputeVertexLimitMask(vHood, posMask, tan1Mask, tan2Mask, vRule);
│ │ │ │ -
1083 } else {
│ │ │ │ -
1084 scheme.ComputeVertexLimitMask(vHood, posMask, vRule);
│ │ │ │ -
1085 }
│ │ │ │ -
1086
│ │ │ │ -
1087 //
│ │ │ │ -
1088 // Gather the neighboring vertices of this vertex -- the vertices opposite its
│ │ │ │ -
1089 // incident edges, and the opposite vertices of its incident faces:
│ │ │ │ -
1090 //
│ │ │ │ -
1091 Index * eIndices = indexBuffer;
│ │ │ │ -
1092 Index * fIndices = indexBuffer + vEdges.size();
│ │ │ │ -
1093
│ │ │ │ -
1094 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ -
1095 ConstIndexArray eVerts = level.getEdgeVertices(vEdges[i]);
│ │ │ │ -
1096
│ │ │ │ -
1097 eIndices[i] = (eVerts[0] == vert) ? eVerts[1] : eVerts[0];
│ │ │ │ -
1098 }
│ │ │ │ -
1099 if (posMask.GetNumFaceWeights() || (hasTangents && tan1Mask.GetNumFaceWeights())) {
│ │ │ │ -
1100 ConstIndexArray vFaces = level.getVertexFaces(vert);
│ │ │ │ -
1101 ConstLocalIndexArray vInFace = level.getVertexFaceLocalIndices(vert);
│ │ │ │ -
1102
│ │ │ │ -
1103 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ -
1104 ConstIndexArray fVerts = level.getFaceVertices(vFaces[i]);
│ │ │ │ -
1105
│ │ │ │ -
1106 LocalIndex vOppInFace = (vInFace[i] + 2);
│ │ │ │ -
1107 if (vOppInFace >= fVerts.size()) vOppInFace -= (LocalIndex)fVerts.size();
│ │ │ │ -
1108
│ │ │ │ -
1109 fIndices[i] = level.getFaceVertices(vFaces[i])[vOppInFace];
│ │ │ │ -
1110 }
│ │ │ │ -
1111 }
│ │ │ │ -
1112
│ │ │ │ -
1113 //
│ │ │ │ -
1114 // Combine the weights and indices for position and tangents. As with applying
│ │ │ │ -
1115 // refinement masks to vertex data, in order to improve numerical precision, it's
│ │ │ │ -
1116 // better to apply smaller weights first, so begin with the face-weights followed
│ │ │ │ -
1117 // by the edge-weights and the vertex weight last.
│ │ │ │ -
1118 //
│ │ │ │ -
1119 dstPos[vert].Clear();
│ │ │ │ -
1120 for (int i = 0; i < posMask.GetNumFaceWeights(); ++i) {
│ │ │ │ -
1121 dstPos[vert].AddWithWeight(src[fIndices[i]], fPosWeights[i]);
│ │ │ │ -
1122 }
│ │ │ │ -
1123 for (int i = 0; i < posMask.GetNumEdgeWeights(); ++i) {
│ │ │ │ -
1124 dstPos[vert].AddWithWeight(src[eIndices[i]], ePosWeights[i]);
│ │ │ │ -
1125 }
│ │ │ │ -
1126 dstPos[vert].AddWithWeight(src[vert], vPosWeights[0]);
│ │ │ │ -
1127
│ │ │ │ -
1128 //
│ │ │ │ -
1129 // Apply the tangent masks -- both will have the same number of weights and
│ │ │ │ -
1130 // indices (one tangent may be "padded" to accommodate the other), but these
│ │ │ │ -
1131 // may differ from those of the position:
│ │ │ │ -
1132 //
│ │ │ │ -
1133 if (hasTangents) {
│ │ │ │ -
1134 assert(tan1Mask.GetNumFaceWeights() == tan2Mask.GetNumFaceWeights());
│ │ │ │ -
1135 assert(tan1Mask.GetNumEdgeWeights() == tan2Mask.GetNumEdgeWeights());
│ │ │ │ -
1136
│ │ │ │ -
1137 U1 & dstTan1 = *dstTan1Ptr;
│ │ │ │ -
1138 U2 & dstTan2 = *dstTan2Ptr;
│ │ │ │ -
1139
│ │ │ │ -
1140 dstTan1[vert].Clear();
│ │ │ │ -
1141 dstTan2[vert].Clear();
│ │ │ │ -
1142 for (int i = 0; i < tan1Mask.GetNumFaceWeights(); ++i) {
│ │ │ │ -
1143 dstTan1[vert].AddWithWeight(src[fIndices[i]], fTan1Weights[i]);
│ │ │ │ -
1144 dstTan2[vert].AddWithWeight(src[fIndices[i]], fTan2Weights[i]);
│ │ │ │ -
1145 }
│ │ │ │ -
1146 for (int i = 0; i < tan1Mask.GetNumEdgeWeights(); ++i) {
│ │ │ │ -
1147 dstTan1[vert].AddWithWeight(src[eIndices[i]], eTan1Weights[i]);
│ │ │ │ -
1148 dstTan2[vert].AddWithWeight(src[eIndices[i]], eTan2Weights[i]);
│ │ │ │ -
1149 }
│ │ │ │ -
1150 dstTan1[vert].AddWithWeight(src[vert], vTan1Weights[0]);
│ │ │ │ -
1151 dstTan2[vert].AddWithWeight(src[vert], vTan2Weights[0]);
│ │ │ │ -
1152 }
│ │ │ │ -
1153 }
│ │ │ │ -
1154}
│ │ │ │ -
1155
│ │ │ │ -
1156template <typename REAL>
│ │ │ │ -
1157template <Sdc::SchemeType SCHEME, class T, class U>
│ │ │ │ -
1158inline void
│ │ │ │ -
1159PrimvarRefinerReal<REAL>::limitFVar(T const & src, U & dst, int channel) const {
│ │ │ │ -
1160
│ │ │ │ -
1161 Sdc::Scheme<SCHEME> scheme(_refiner._subdivOptions);
│ │ │ │ -
1162
│ │ │ │ -
1163 Vtr::internal::Level const & level = _refiner.getLevel(_refiner.GetMaxLevel());
│ │ │ │ -
1164 Vtr::internal::FVarLevel const & fvarChannel = level.getFVarLevel(channel);
│ │ │ │ -
1165
│ │ │ │ -
1166 int maxWeightsPerMask = 1 + 2 * level.getMaxValence();
│ │ │ │ -
1167
│ │ │ │ -
1168 Vtr::internal::StackBuffer<Weight,33> weightBuffer(maxWeightsPerMask);
│ │ │ │ -
1169 Vtr::internal::StackBuffer<Index,16> vEdgeBuffer(level.getMaxValence());
│ │ │ │ -
1170
│ │ │ │ -
1171 // This is a bit obscure -- assign both parent and child as last level
│ │ │ │ -
1172 Vtr::internal::VertexInterface vHood(level, level);
│ │ │ │ -
1173
│ │ │ │ -
1174 for (int vert = 0; vert < level.getNumVertices(); ++vert) {
│ │ │ │ -
1175
│ │ │ │ -
1176 ConstIndexArray vEdges = level.getVertexEdges(vert);
│ │ │ │ -
1177 ConstIndexArray vValues = fvarChannel.getVertexValues(vert);
│ │ │ │ -
1178
│ │ │ │ -
1179 // Incomplete vertices (present in sparse refinement) do not have their full
│ │ │ │ -
1180 // topological neighborhood to determine a proper limit -- just leave the
│ │ │ │ -
1181 // values (perhaps more than one per vertex) at the refined location.
│ │ │ │ -
1182 //
│ │ │ │ -
1183 // The same can be done if the face-varying channel is purely linear.
│ │ │ │ -
1184 //
│ │ │ │ -
1185 bool isIncomplete = (level.getVertexTag(vert)._incomplete || (vEdges.size() == 0));
│ │ │ │ -
1186 if (isIncomplete || fvarChannel.isLinear()) {
│ │ │ │ -
1187 for (int i = 0; i < vValues.size(); ++i) {
│ │ │ │ -
1188 Vtr::Index vValue = vValues[i];
│ │ │ │ -
1189
│ │ │ │ -
1190 dst[vValue].Clear();
│ │ │ │ -
1191 dst[vValue].AddWithWeight(src[vValue], 1.0f);
│ │ │ │ -
1192 }
│ │ │ │ -
1193 continue;
│ │ │ │ -
1194 }
│ │ │ │ -
1195
│ │ │ │ -
1196 bool fvarVertMatchesVertex = fvarChannel.valueTopologyMatches(vValues[0]);
│ │ │ │ -
1197 if (fvarVertMatchesVertex) {
│ │ │ │ -
1198
│ │ │ │ -
1199 // Assign the mask weights to the common buffer and compute the mask:
│ │ │ │ -
1200 //
│ │ │ │ -
1201 Weight * vWeights = weightBuffer,
│ │ │ │ -
1202 * eWeights = vWeights + 1,
│ │ │ │ -
1203 * fWeights = eWeights + vEdges.size();
│ │ │ │ -
1204
│ │ │ │ -
1205 Mask vMask(vWeights, eWeights, fWeights);
│ │ │ │ -
1206
│ │ │ │ -
1207 vHood.SetIndex(vert, vert);
│ │ │ │ -
1208
│ │ │ │ -
1209 scheme.ComputeVertexLimitMask(vHood, vMask, level.getVertexRule(vert));
│ │ │ │ -
1210
│ │ │ │ -
1211 //
│ │ │ │ -
1212 // Apply mask to corresponding FVar values for neighboring vertices:
│ │ │ │ -
1213 //
│ │ │ │ -
1214 Vtr::Index vValue = vValues[0];
│ │ │ │ -
1215
│ │ │ │ -
1216 dst[vValue].Clear();
│ │ │ │ -
1217 if (vMask.GetNumFaceWeights() > 0) {
│ │ │ │ -
1218 assert(!vMask.AreFaceWeightsForFaceCenters());
│ │ │ │ -
1219
│ │ │ │ -
1220 ConstIndexArray vFaces = level.getVertexFaces(vert);
│ │ │ │ -
1221 ConstLocalIndexArray vInFace = level.getVertexFaceLocalIndices(vert);
│ │ │ │ -
1222
│ │ │ │ -
1223 for (int i = 0; i < vFaces.size(); ++i) {
│ │ │ │ -
1224 ConstIndexArray faceValues = fvarChannel.getFaceValues(vFaces[i]);
│ │ │ │ -
1225 LocalIndex vOppInFace = vInFace[i] + 2;
│ │ │ │ -
1226 if (vOppInFace >= faceValues.size()) vOppInFace -= faceValues.size();
│ │ │ │ -
1227
│ │ │ │ -
1228 Index vValueOppositeFace = faceValues[vOppInFace];
│ │ │ │ -
1229
│ │ │ │ -
1230 dst[vValue].AddWithWeight(src[vValueOppositeFace], fWeights[i]);
│ │ │ │ -
1231 }
│ │ │ │ -
1232 }
│ │ │ │ -
1233 if (vMask.GetNumEdgeWeights() > 0) {
│ │ │ │ -
1234 Index * vEdgeValues = vEdgeBuffer;
│ │ │ │ -
1235 fvarChannel.getVertexEdgeValues(vert, vEdgeValues);
│ │ │ │ -
1236
│ │ │ │ -
1237 for (int i = 0; i < vEdges.size(); ++i) {
│ │ │ │ -
1238 dst[vValue].AddWithWeight(src[vEdgeValues[i]], eWeights[i]);
│ │ │ │ -
1239 }
│ │ │ │ -
1240 }
│ │ │ │ -
1241 dst[vValue].AddWithWeight(src[vValue], vWeights[0]);
│ │ │ │ -
1242 } else {
│ │ │ │ -
1243 //
│ │ │ │ -
1244 // Sibling FVar values associated with a vertex will be either a corner or a crease:
│ │ │ │ -
1245 //
│ │ │ │ -
1246 for (int i = 0; i < vValues.size(); ++i) {
│ │ │ │ -
1247 Vtr::Index vValue = vValues[i];
│ │ │ │ -
1248
│ │ │ │ -
1249 dst[vValue].Clear();
│ │ │ │ -
1250 if (fvarChannel.getValueTag(vValue).isCorner()) {
│ │ │ │ -
1251 dst[vValue].AddWithWeight(src[vValue], 1.0f);
│ │ │ │ -
1252 } else {
│ │ │ │ -
1253 Index vEndValues[2];
│ │ │ │ -
1254 fvarChannel.getVertexCreaseEndValues(vert, i, vEndValues);
│ │ │ │ -
1255
│ │ │ │ -
1256 dst[vValue].AddWithWeight(src[vEndValues[0]], 1.0f/6.0f);
│ │ │ │ -
1257 dst[vValue].AddWithWeight(src[vEndValues[1]], 1.0f/6.0f);
│ │ │ │ -
1258 dst[vValue].AddWithWeight(src[vValue], 2.0f/3.0f);
│ │ │ │ -
1259 }
│ │ │ │ -
1260 }
│ │ │ │ -
1261 }
│ │ │ │ -
1262 }
│ │ │ │ -
1263}
│ │ │ │ -
1264
│ │ │ │ -
│ │ │ │ -
1265class PrimvarRefiner : public PrimvarRefinerReal<float> {
│ │ │ │ -
1266public:
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1268 : PrimvarRefinerReal<float>(refiner) { }
│ │ │ │ -
│ │ │ │ -
1269};
│ │ │ │ -
│ │ │ │ -
1270
│ │ │ │ -
1271} // end namespace Far
│ │ │ │ -
1272
│ │ │ │ -
1273} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
1274using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
1275} // end namespace OpenSubdiv
│ │ │ │ -
1276
│ │ │ │ -
1277#endif /* OPENSUBDIV3_FAR_PRIMVAR_REFINER_H */
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
│ │ │ │ +
234
│ │ │ │ +
235#endif /* OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H */
│ │ │ │ │ │ │ │ - │ │ │ │ -
void Error(ErrorType err, const char *format,...)
Sends an OSD error with a message (internal use only)
│ │ │ │
Vtr::ConstIndexArray ConstIndexArray
Definition types.h:47
│ │ │ │ -
Vtr::ConstLocalIndexArray ConstLocalIndexArray
Definition types.h:48
│ │ │ │ -
@ FAR_RUNTIME_ERROR
Issue a generic runtime error, but continue execution.
Definition error.h:40
│ │ │ │ - │ │ │ │ - │ │ │ │ -
bool IndexIsValid(Index index)
Definition types.h:58
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
Applies refinement operations to generic primvar data.
│ │ │ │ -
void Limit(T const &src, U &dstPos) const
Apply limit weights to a primvar buffer.
│ │ │ │ - │ │ │ │ -
void Limit(T const &src, U &dstPos, U1 &dstTan1, U2 &dstTan2) const
│ │ │ │ -
void InterpolateFaceUniform(int level, T const &src, U &dst) const
Refine uniform (per-face) primvar data between levels.
│ │ │ │ - │ │ │ │ -
void InterpolateVarying(int level, T const &src, U &dst) const
Apply only varying interpolation weights to a primvar buffer for a single level of refinement.
│ │ │ │ -
void Interpolate(int level, T const &src, U &dst) const
Apply vertex interpolation weights to a primvar buffer for a single level of refinement.
│ │ │ │ -
void InterpolateFaceVarying(int level, T const &src, U &dst, int channel=0) const
Apply face-varying interpolation weights to a primvar buffer associated with a particular face-varyin...
│ │ │ │ - │ │ │ │ -
void LimitFaceVarying(T const &src, U &dst, int channel=0) const
│ │ │ │ - │ │ │ │ - │ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
Scheme is a class template which provides all implementation for the subdivision schemes supported by...
Definition scheme.h:66
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Factory for constructing a PatchTable from a TopologyRefiner.
│ │ │ │ + │ │ │ │ +
static PatchTable * Create(TopologyRefiner const &refiner, Options options=Options(), ConstIndexArray selectedFaces=ConstIndexArray())
Instantiates a PatchTable from a client-provided TopologyRefiner.
│ │ │ │ + │ │ │ │ +
unsigned int generateVaryingTables
Generate varying patch tables.
│ │ │ │ +
unsigned int generateLegacySharpCornerPatches
Generate sharp regular patches at smooth corners (legacy)
│ │ │ │ + │ │ │ │ +
TopologyRefiner::AdaptiveOptions GetRefineAdaptiveOptions() const
Determine adaptive refinement options to match assigned patch options.
│ │ │ │ +
unsigned int maxIsolationLevel
Cap adaptive feature isolation to the given level (max. 10)
│ │ │ │ + │ │ │ │ +
unsigned int generateFVarLegacyLinearPatches
Generate all linear face-varying patches (legacy)
│ │ │ │ +
void SetPatchPrecision()
Set precision of vertex patches.
│ │ │ │ +
unsigned int fvarPatchPrecisionDouble
Generate double-precision stencils for face-varying patches.
│ │ │ │ +
void SetMaxIsolationLevel(unsigned int level)
Set maximum isolation level.
│ │ │ │ + │ │ │ │ +
int const * fvarChannelIndices
List containing the indices of the channels selected for the factory.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
unsigned int generateVaryingLocalPoints
Generate local points with varying patches.
│ │ │ │ +
unsigned int includeFVarBaseLevelIndices
Include base level in face-varying patch point indices (Uniform mode only)
│ │ │ │ +
unsigned int generateAllLevels
Generate levels from 'firstLevel' to 'maxLevel' (Uniform mode only)
│ │ │ │ +
unsigned int patchPrecisionDouble
Generate double-precision stencils for vertex patches.
│ │ │ │ +
unsigned int generateFVarTables
Generate face-varying patch tables.
│ │ │ │ +
unsigned int includeBaseLevelIndices
Include base level in patch point indices (Uniform mode only)
│ │ │ │ +
void SetFVarPatchPrecision()
Set precision of face-varying patches.
│ │ │ │ +
int numFVarChannels
Number of channel indices and interpolation modes passed.
│ │ │ │ +
unsigned int triangulateQuads
Triangulate 'QUADS' primitives (Uniform mode only)
│ │ │ │ +
EndCapType
Choice for approximating irregular patches (end-caps)
│ │ │ │ +
@ ENDCAP_LEGACY_GREGORY
legacy option for 2.x style Gregory patches (Catmark only)
│ │ │ │ +
@ ENDCAP_GREGORY_BASIS
use Gregory patches (highest quality, recommended default)
│ │ │ │ + │ │ │ │ +
@ ENDCAP_BILINEAR_BASIS
use linear patches (simple quads or tris)
│ │ │ │ +
@ ENDCAP_BSPLINE_BASIS
use BSpline-like patches (same patch type as regular)
│ │ │ │ + │ │ │ │ +
Obsolete internal struct not intended for public use – due to be deprecated.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── encoding │ │ │ │ │ @@ -1 +1 @@ │ │ │ │ │ -us-ascii │ │ │ │ │ +utf-8 │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -primvarRefiner.h │ │ │ │ │ +patchTableFactory.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2015 DreamWorks Animation LLC. │ │ │ │ │ +2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -23,1388 +23,410 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_FAR_PRIMVAR_REFINER_H │ │ │ │ │ -25#define OPENSUBDIV3_FAR_PRIMVAR_REFINER_H │ │ │ │ │ -26 │ │ │ │ │ -27#include "../version.h" │ │ │ │ │ -28 │ │ │ │ │ -29#include "../sdc/types.h" │ │ │ │ │ -30#include "../sdc/options.h" │ │ │ │ │ -31#include "../sdc/bilinearScheme.h" │ │ │ │ │ -32#include "../sdc/catmarkScheme.h" │ │ │ │ │ -33#include "../sdc/loopScheme.h" │ │ │ │ │ -34#include "../vtr/level.h" │ │ │ │ │ -35#include "../vtr/fvarLevel.h" │ │ │ │ │ -36#include "../vtr/refinement.h" │ │ │ │ │ -37#include "../vtr/fvarRefinement.h" │ │ │ │ │ -38#include "../vtr/stackBuffer.h" │ │ │ │ │ -39#include "../vtr/componentInterfaces.h" │ │ │ │ │ -40#include "../far/types.h" │ │ │ │ │ -41#include "../far/error.h" │ │ │ │ │ -42#include "../far/topologyLevel.h" │ │ │ │ │ -43#include "../far/topologyRefiner.h" │ │ │ │ │ -44 │ │ │ │ │ -45#include │ │ │ │ │ +24 │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H │ │ │ │ │ +27 │ │ │ │ │ +28#include "../version.h" │ │ │ │ │ +29 │ │ │ │ │ +30#include "../far/topologyRefiner.h" │ │ │ │ │ +31#include "../far/patchTable.h" │ │ │ │ │ +32 │ │ │ │ │ +33namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +34namespace OPENSUBDIV_VERSION { │ │ │ │ │ +35 │ │ │ │ │ +36namespace Far { │ │ │ │ │ +37 │ │ │ │ │ +_4_0class _P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y { │ │ │ │ │ +41public: │ │ │ │ │ +42 │ │ │ │ │ +_4_5 struct _O_p_t_i_o_n_s { │ │ │ │ │ 46 │ │ │ │ │ -47namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -48namespace OPENSUBDIV_VERSION { │ │ │ │ │ -49 │ │ │ │ │ -50namespace Far { │ │ │ │ │ -51 │ │ │ │ │ -55template │ │ │ │ │ -_5_6class _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l { │ │ │ │ │ -57 │ │ │ │ │ -58public: │ │ │ │ │ -_5_9 _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner) : _refiner(refiner) { } │ │ │ │ │ -_6_0 _~_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l() { } │ │ │ │ │ -61 │ │ │ │ │ -_6_2 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & _G_e_t_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r() const { return _refiner; } │ │ │ │ │ -63 │ │ │ │ │ -65 │ │ │ │ │ -100 │ │ │ │ │ -_1_1_3 template void _I_n_t_e_r_p_o_l_a_t_e(int level, T const & src, U & │ │ │ │ │ -dst) const; │ │ │ │ │ +_5_5 enum _E_n_d_C_a_p_T_y_p_e { │ │ │ │ │ +_5_6 _E_N_D_C_A_P___N_O_N_E = 0, │ │ │ │ │ +_5_7 _E_N_D_C_A_P___B_I_L_I_N_E_A_R___B_A_S_I_S, │ │ │ │ │ +_5_8 _E_N_D_C_A_P___B_S_P_L_I_N_E___B_A_S_I_S, │ │ │ │ │ +_5_9 _E_N_D_C_A_P___G_R_E_G_O_R_Y___B_A_S_I_S, │ │ │ │ │ +60 _E_N_D_C_A_P___L_E_G_A_C_Y___G_R_E_G_O_R_Y │ │ │ │ │ +_6_1 }; │ │ │ │ │ +62 │ │ │ │ │ +_6_3 _O_p_t_i_o_n_s(unsigned int maxIsolation=10) : │ │ │ │ │ +64 _g_e_n_e_r_a_t_e_A_l_l_L_e_v_e_l_s(false), │ │ │ │ │ +65 _i_n_c_l_u_d_e_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s(true), │ │ │ │ │ +66 _i_n_c_l_u_d_e_F_V_a_r_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s(false), │ │ │ │ │ +67 _t_r_i_a_n_g_u_l_a_t_e_Q_u_a_d_s(false), │ │ │ │ │ +68 _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h(false), │ │ │ │ │ +69 _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h(false), │ │ │ │ │ +70 _m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l(maxIsolation & 0xf), │ │ │ │ │ +71 _e_n_d_C_a_p_T_y_p_e(_E_N_D_C_A_P___G_R_E_G_O_R_Y___B_A_S_I_S), │ │ │ │ │ +72 _s_h_a_r_e_E_n_d_C_a_p_P_a_t_c_h_P_o_i_n_t_s(true), │ │ │ │ │ +73 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_T_a_b_l_e_s(true), │ │ │ │ │ +74 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_L_o_c_a_l_P_o_i_n_t_s(true), │ │ │ │ │ +75 _g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s(false), │ │ │ │ │ +76 _p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e(false), │ │ │ │ │ +77 _f_v_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e(false), │ │ │ │ │ +78 _g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s(true), │ │ │ │ │ +79 _g_e_n_e_r_a_t_e_L_e_g_a_c_y_S_h_a_r_p_C_o_r_n_e_r_P_a_t_c_h_e_s(true), │ │ │ │ │ +80 _n_u_m_F_V_a_r_C_h_a_n_n_e_l_s(-1), │ │ │ │ │ +81 _f_v_a_r_C_h_a_n_n_e_l_I_n_d_i_c_e_s(0) │ │ │ │ │ +82 { } │ │ │ │ │ +83 │ │ │ │ │ +_8_5 _E_n_d_C_a_p_T_y_p_e _G_e_t_E_n_d_C_a_p_T_y_p_e() const { return (_E_n_d_C_a_p_T_y_p_e)_e_n_d_C_a_p_T_y_p_e; } │ │ │ │ │ +86 │ │ │ │ │ +_8_8 void _S_e_t_E_n_d_C_a_p_T_y_p_e(_E_n_d_C_a_p_T_y_p_e e) { _e_n_d_C_a_p_T_y_p_e = e & 0x7; } │ │ │ │ │ +89 │ │ │ │ │ +_9_1 void _S_e_t_M_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l(unsigned int level) { _m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l = level & │ │ │ │ │ +0xf; } │ │ │ │ │ +92 │ │ │ │ │ +_9_4 template void _S_e_t_P_a_t_c_h_P_r_e_c_i_s_i_o_n(); │ │ │ │ │ +95 │ │ │ │ │ +_9_7 template void _S_e_t_F_V_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n(); │ │ │ │ │ +98 │ │ │ │ │ +_1_0_0 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s _G_e_t_R_e_f_i_n_e_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s() const { │ │ │ │ │ +101 _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s adaptiveOptions(_m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l); │ │ │ │ │ +102 │ │ │ │ │ +103 adaptiveOptions._u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h = _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h; │ │ │ │ │ +104 adaptiveOptions._u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h = _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h; │ │ │ │ │ +105 adaptiveOptions._c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s = _g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s && │ │ │ │ │ +106 !_g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s; │ │ │ │ │ +107 return adaptiveOptions; │ │ │ │ │ +108 } │ │ │ │ │ +109 │ │ │ │ │ +_1_1_0 unsigned int _g_e_n_e_r_a_t_e_A_l_l_L_e_v_e_l_s : 1, │ │ │ │ │ +_1_1_1 _i_n_c_l_u_d_e_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s : 1, │ │ │ │ │ +_1_1_2 _i_n_c_l_u_d_e_F_V_a_r_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s : 1, │ │ │ │ │ +_1_1_3 _t_r_i_a_n_g_u_l_a_t_e_Q_u_a_d_s : 1, │ │ │ │ │ 114 │ │ │ │ │ -_1_3_0 template void _I_n_t_e_r_p_o_l_a_t_e_V_a_r_y_i_n_g(int level, T const & │ │ │ │ │ -src, U & dst) const; │ │ │ │ │ -131 │ │ │ │ │ -_1_4_8 template void _I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_U_n_i_f_o_r_m(int level, T const │ │ │ │ │ -& src, U & dst) const; │ │ │ │ │ -149 │ │ │ │ │ -_1_6_1 template void _I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_V_a_r_y_i_n_g(int level, T const │ │ │ │ │ -& src, U & dst, int channel = 0) const; │ │ │ │ │ -162 │ │ │ │ │ -163 │ │ │ │ │ -_1_7_5 template void _L_i_m_i_t(T const & src, U & dstPos) const; │ │ │ │ │ -176 │ │ │ │ │ -177 template │ │ │ │ │ -_1_7_8 void _L_i_m_i_t(T const & src, U & dstPos, U1 & dstTan1, U2 & dstTan2) const; │ │ │ │ │ -179 │ │ │ │ │ -_1_8_0 template void _L_i_m_i_t_F_a_c_e_V_a_r_y_i_n_g(T const & src, U & dst, │ │ │ │ │ -int channel = 0) const; │ │ │ │ │ -181 │ │ │ │ │ -183 │ │ │ │ │ -184private: │ │ │ │ │ -185 typedef REAL Weight; │ │ │ │ │ -186 │ │ │ │ │ -187 // Non-copyable: │ │ │ │ │ -188 _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l(_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l const & src) : _refiner(src._refiner) │ │ │ │ │ -{ } │ │ │ │ │ -189 _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l & operator=(_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l const &) { return *this; │ │ │ │ │ -} │ │ │ │ │ -190 │ │ │ │ │ -191 template void interpFromFaces │ │ │ │ │ -(int, T const &, U &) const; │ │ │ │ │ -192 template void interpFromEdges │ │ │ │ │ -(int, T const &, U &) const; │ │ │ │ │ -193 template void interpFromVerts │ │ │ │ │ -(int, T const &, U &) const; │ │ │ │ │ -194 │ │ │ │ │ -195 template void │ │ │ │ │ -interpFVarFromFaces(int, T const &, U &, int) const; │ │ │ │ │ -196 template void │ │ │ │ │ -interpFVarFromEdges(int, T const &, U &, int) const; │ │ │ │ │ -197 template void │ │ │ │ │ -interpFVarFromVerts(int, T const &, U &, int) const; │ │ │ │ │ -198 │ │ │ │ │ -199 template │ │ │ │ │ -200 void limit(T const & src, U & pos, U1 * tan1, U2 * tan2) const; │ │ │ │ │ -201 │ │ │ │ │ -202 template │ │ │ │ │ -203 void limitFVar(T const & src, U & dst, int channel) const; │ │ │ │ │ -204 │ │ │ │ │ -205private: │ │ │ │ │ -206 TopologyRefiner const & _refiner; │ │ │ │ │ -207 │ │ │ │ │ -208private: │ │ │ │ │ -209 // │ │ │ │ │ -210 // Local class to fulfill interface for in the Scheme mask │ │ │ │ │ -queries: │ │ │ │ │ -211 // │ │ │ │ │ -212 class Mask { │ │ │ │ │ -213 public: │ │ │ │ │ -214 typedef REAL Weight; // Also part of the expected interface │ │ │ │ │ -215 │ │ │ │ │ -216 public: │ │ │ │ │ -217 Mask(Weight* v, Weight* e, Weight* f) : │ │ │ │ │ -218 _vertWeights(v), _edgeWeights(e), _faceWeights(f), │ │ │ │ │ -219 _vertCount(0), _edgeCount(0), _faceCount(0), │ │ │ │ │ -220 _faceWeightsForFaceCenters(false) │ │ │ │ │ -221 { } │ │ │ │ │ -222 │ │ │ │ │ -223 ~Mask() { } │ │ │ │ │ -224 │ │ │ │ │ -225 public: // Generic interface expected of : │ │ │ │ │ -226 int GetNumVertexWeights() const { return _vertCount; } │ │ │ │ │ -227 int GetNumEdgeWeights() const { return _edgeCount; } │ │ │ │ │ -228 int GetNumFaceWeights() const { return _faceCount; } │ │ │ │ │ -229 │ │ │ │ │ -230 void SetNumVertexWeights(int count) { _vertCount = count; } │ │ │ │ │ -231 void SetNumEdgeWeights( int count) { _edgeCount = count; } │ │ │ │ │ -232 void SetNumFaceWeights( int count) { _faceCount = count; } │ │ │ │ │ +_1_1_5 _u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h : 1, │ │ │ │ │ +_1_1_6 _u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h : 1, │ │ │ │ │ +_1_1_7 _m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l : 4, │ │ │ │ │ +118 │ │ │ │ │ +119 // end-capping │ │ │ │ │ +_1_2_0 _e_n_d_C_a_p_T_y_p_e : 3, │ │ │ │ │ +_1_2_1 _s_h_a_r_e_E_n_d_C_a_p_P_a_t_c_h_P_o_i_n_t_s : 1, │ │ │ │ │ +123 │ │ │ │ │ +124 // varying │ │ │ │ │ +_1_2_5 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_T_a_b_l_e_s : 1, │ │ │ │ │ +_1_2_6 _g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_L_o_c_a_l_P_o_i_n_t_s : 1, │ │ │ │ │ +127 │ │ │ │ │ +128 // face-varying │ │ │ │ │ +_1_2_9 _g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s : 1, │ │ │ │ │ +130 │ │ │ │ │ +131 // precision │ │ │ │ │ +_1_3_2 _p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e : 1, │ │ │ │ │ +_1_3_3 _f_v_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e : 1, │ │ │ │ │ +134 │ │ │ │ │ +135 // legacy behaviors (default to true) │ │ │ │ │ +_1_3_6 _g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s : 1, │ │ │ │ │ +_1_3_7 _g_e_n_e_r_a_t_e_L_e_g_a_c_y_S_h_a_r_p_C_o_r_n_e_r_P_a_t_c_h_e_s : 1; │ │ │ │ │ +138 │ │ │ │ │ +_1_3_9 int _n_u_m_F_V_a_r_C_h_a_n_n_e_l_s; │ │ │ │ │ +_1_4_0 int const * _f_v_a_r_C_h_a_n_n_e_l_I_n_d_i_c_e_s; │ │ │ │ │ +141 }; │ │ │ │ │ +142 │ │ │ │ │ +_1_7_5 static _P_a_t_c_h_T_a_b_l_e * _C_r_e_a_t_e(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner, │ │ │ │ │ +176 _O_p_t_i_o_n_s options = _O_p_t_i_o_n_s(), │ │ │ │ │ +177 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y selectedFaces = _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y()); │ │ │ │ │ +178 │ │ │ │ │ +179public: │ │ │ │ │ +180 // PatchFaceTag │ │ │ │ │ +181 // │ │ │ │ │ +182 // This simple struct was previously used within the factory to take │ │ │ │ │ +inventory of │ │ │ │ │ +183 // various kinds of patches to fully allocate buffers prior to populating │ │ │ │ │ +them. It │ │ │ │ │ +184 // was not intended to be exposed as part of the public interface. │ │ │ │ │ +185 // │ │ │ │ │ +186 // It is no longer used internally and is being kept here to respect │ │ │ │ │ +preservation │ │ │ │ │ +187 // of the public interface, but it will be deprecated at the earliest │ │ │ │ │ +opportunity. │ │ │ │ │ +188 // │ │ │ │ │ +191 // │ │ │ │ │ +_1_9_2 struct _P_a_t_c_h_F_a_c_e_T_a_g { │ │ │ │ │ +193 public: │ │ │ │ │ +_1_9_4 unsigned int ___h_a_s_P_a_t_c_h : 1; │ │ │ │ │ +_1_9_5 unsigned int ___i_s_R_e_g_u_l_a_r : 1; │ │ │ │ │ +_1_9_6 unsigned int ___t_r_a_n_s_i_t_i_o_n_M_a_s_k : 4; │ │ │ │ │ +_1_9_7 unsigned int ___b_o_u_n_d_a_r_y_M_a_s_k : 4; │ │ │ │ │ +_1_9_8 unsigned int ___b_o_u_n_d_a_r_y_I_n_d_e_x : 2; │ │ │ │ │ +_1_9_9 unsigned int ___b_o_u_n_d_a_r_y_C_o_u_n_t : 3; │ │ │ │ │ +_2_0_0 unsigned int ___h_a_s_B_o_u_n_d_a_r_y_E_d_g_e : 3; │ │ │ │ │ +_2_0_1 unsigned int ___i_s_S_i_n_g_l_e_C_r_e_a_s_e : 1; │ │ │ │ │ +202 │ │ │ │ │ +_2_0_3 void _c_l_e_a_r(); │ │ │ │ │ +_2_0_4 void _a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k(int boundaryEdgeMask); │ │ │ │ │ +_2_0_5 void _a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_V_e_r_t_e_x_M_a_s_k(int boundaryVertexMask); │ │ │ │ │ +_2_0_6 void _a_s_s_i_g_n_T_r_a_n_s_i_t_i_o_n_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k(int boundaryVertexMask); │ │ │ │ │ +207 }; │ │ │ │ │ +_2_0_8 typedef std::vector _P_a_t_c_h_T_a_g_V_e_c_t_o_r; │ │ │ │ │ +209}; │ │ │ │ │ +210 │ │ │ │ │ +211 │ │ │ │ │ +_2_1_2template <> inline void PatchTableFactory::Options::SetPatchPrecision │ │ │ │ │ +() { │ │ │ │ │ +213 _p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e = false; │ │ │ │ │ +214} │ │ │ │ │ +_2_1_5template <> inline void PatchTableFactory::Options:: │ │ │ │ │ +SetFVarPatchPrecision() { │ │ │ │ │ +216 fvarPatchPrecisionDouble = false; │ │ │ │ │ +217} │ │ │ │ │ +218 │ │ │ │ │ +219template <> inline void PatchTableFactory::Options:: │ │ │ │ │ +SetPatchPrecision() { │ │ │ │ │ +220 patchPrecisionDouble = true; │ │ │ │ │ +221} │ │ │ │ │ +222template <> inline void PatchTableFactory::Options:: │ │ │ │ │ +SetFVarPatchPrecision() { │ │ │ │ │ +223 fvarPatchPrecisionDouble = true; │ │ │ │ │ +224} │ │ │ │ │ +225 │ │ │ │ │ +226 │ │ │ │ │ +227} // end namespace Far │ │ │ │ │ +228 │ │ │ │ │ +229} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +230using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +231 │ │ │ │ │ +232} // end namespace OpenSubdiv │ │ │ │ │ 233 │ │ │ │ │ -234 Weight const& VertexWeight(int index) const { return _vertWeights[index]; } │ │ │ │ │ -235 Weight const& EdgeWeight( int index) const { return _edgeWeights[index]; } │ │ │ │ │ -236 Weight const& FaceWeight( int index) const { return _faceWeights[index]; } │ │ │ │ │ -237 │ │ │ │ │ -238 Weight& VertexWeight(int index) { return _vertWeights[index]; } │ │ │ │ │ -239 Weight& EdgeWeight( int index) { return _edgeWeights[index]; } │ │ │ │ │ -240 Weight& FaceWeight( int index) { return _faceWeights[index]; } │ │ │ │ │ -241 │ │ │ │ │ -242 bool AreFaceWeightsForFaceCenters() const { return │ │ │ │ │ -_faceWeightsForFaceCenters; } │ │ │ │ │ -243 void SetFaceWeightsForFaceCenters(bool on) { _faceWeightsForFaceCenters = │ │ │ │ │ -on; } │ │ │ │ │ -244 │ │ │ │ │ -245 private: │ │ │ │ │ -246 Weight* _vertWeights; │ │ │ │ │ -247 Weight* _edgeWeights; │ │ │ │ │ -248 Weight* _faceWeights; │ │ │ │ │ -249 │ │ │ │ │ -250 int _vertCount; │ │ │ │ │ -251 int _edgeCount; │ │ │ │ │ -252 int _faceCount; │ │ │ │ │ -253 │ │ │ │ │ -254 bool _faceWeightsForFaceCenters; │ │ │ │ │ -255 }; │ │ │ │ │ -256}; │ │ │ │ │ -257 │ │ │ │ │ -258 │ │ │ │ │ -259// │ │ │ │ │ -260// Public entry points to the methods. Queries of the scheme type and its │ │ │ │ │ -261// use as a template parameter in subsequent implementation will be factored │ │ │ │ │ -262// out of a later release: │ │ │ │ │ -263// │ │ │ │ │ -264template │ │ │ │ │ -265template │ │ │ │ │ -266inline void │ │ │ │ │ -_2_6_7_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e(int level, T const & src, U & dst) │ │ │ │ │ -const { │ │ │ │ │ -268 │ │ │ │ │ -269 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ -270 │ │ │ │ │ -271 switch (_refiner._subdivType) { │ │ │ │ │ -272 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ -273 interpFromFaces(level, src, dst); │ │ │ │ │ -274 interpFromEdges(level, src, dst); │ │ │ │ │ -275 interpFromVerts(level, src, dst); │ │ │ │ │ -276 break; │ │ │ │ │ -277 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ -278 interpFromFaces(level, src, dst); │ │ │ │ │ -279 interpFromEdges(level, src, dst); │ │ │ │ │ -280 interpFromVerts(level, src, dst); │ │ │ │ │ -281 break; │ │ │ │ │ -282 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ -283 interpFromFaces(level, src, dst); │ │ │ │ │ -284 interpFromEdges(level, src, dst); │ │ │ │ │ -285 interpFromVerts(level, src, dst); │ │ │ │ │ -286 break; │ │ │ │ │ -287 } │ │ │ │ │ -288} │ │ │ │ │ -289 │ │ │ │ │ -290template │ │ │ │ │ -291template │ │ │ │ │ -292inline void │ │ │ │ │ -_2_9_3_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_V_a_r_y_i_n_g(int level, T const & src, U │ │ │ │ │ -& dst, int channel) const { │ │ │ │ │ -294 │ │ │ │ │ -295 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ -296 │ │ │ │ │ -297 switch (_refiner._subdivType) { │ │ │ │ │ -298 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ -299 interpFVarFromFaces(level, src, dst, channel); │ │ │ │ │ -300 interpFVarFromEdges(level, src, dst, channel); │ │ │ │ │ -301 interpFVarFromVerts(level, src, dst, channel); │ │ │ │ │ -302 break; │ │ │ │ │ -303 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ -304 interpFVarFromFaces(level, src, dst, channel); │ │ │ │ │ -305 interpFVarFromEdges(level, src, dst, channel); │ │ │ │ │ -306 interpFVarFromVerts(level, src, dst, channel); │ │ │ │ │ -307 break; │ │ │ │ │ -308 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ -309 interpFVarFromFaces(level, src, dst, channel); │ │ │ │ │ -310 interpFVarFromEdges(level, src, dst, channel); │ │ │ │ │ -311 interpFVarFromVerts(level, src, dst, channel); │ │ │ │ │ -312 break; │ │ │ │ │ -313 } │ │ │ │ │ -314} │ │ │ │ │ -315 │ │ │ │ │ -316template │ │ │ │ │ -317template │ │ │ │ │ -318inline void │ │ │ │ │ -_3_1_9_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_L_i_m_i_t(T const & src, U & dst) const { │ │ │ │ │ -320 │ │ │ │ │ -321 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == │ │ │ │ │ -0) { │ │ │ │ │ -322 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ -323 "Failure in PrimvarRefiner::Limit() -- " │ │ │ │ │ -324 "last level of refinement does not include full topology."); │ │ │ │ │ -325 return; │ │ │ │ │ -326 } │ │ │ │ │ -327 │ │ │ │ │ -328 switch (_refiner._subdivType) { │ │ │ │ │ -329 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ -330 limit(src, dst, (U*)0, (U*)0); │ │ │ │ │ -331 break; │ │ │ │ │ -332 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ -333 limit(src, dst, (U*)0, (U*)0); │ │ │ │ │ -334 break; │ │ │ │ │ -335 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ -336 limit(src, dst, (U*)0, (U*)0); │ │ │ │ │ -337 break; │ │ │ │ │ -338 } │ │ │ │ │ -339} │ │ │ │ │ -340 │ │ │ │ │ -341template │ │ │ │ │ -342template │ │ │ │ │ -343inline void │ │ │ │ │ -_3_4_4_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_L_i_m_i_t(T const & src, U & dstPos, U1 & dstTan1, U2 │ │ │ │ │ -& dstTan2) const { │ │ │ │ │ -345 │ │ │ │ │ -346 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == │ │ │ │ │ -0) { │ │ │ │ │ -347 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ -348 "Failure in PrimvarRefiner::Limit() -- " │ │ │ │ │ -349 "last level of refinement does not include full topology."); │ │ │ │ │ -350 return; │ │ │ │ │ -351 } │ │ │ │ │ -352 │ │ │ │ │ -353 switch (_refiner._subdivType) { │ │ │ │ │ -354 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ -355 limit(src, dstPos, &dstTan1, &dstTan2); │ │ │ │ │ -356 break; │ │ │ │ │ -357 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ -358 limit(src, dstPos, &dstTan1, &dstTan2); │ │ │ │ │ -359 break; │ │ │ │ │ -360 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ -361 limit(src, dstPos, &dstTan1, &dstTan2); │ │ │ │ │ -362 break; │ │ │ │ │ -363 } │ │ │ │ │ -364} │ │ │ │ │ -365 │ │ │ │ │ -366template │ │ │ │ │ -367template │ │ │ │ │ -368inline void │ │ │ │ │ -_3_6_9_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_L_i_m_i_t_F_a_c_e_V_a_r_y_i_n_g(T const & src, U & dst, int │ │ │ │ │ -channel) const { │ │ │ │ │ -370 │ │ │ │ │ -371 if (_refiner.getLevel(_refiner.GetMaxLevel()).getNumVertexEdgesTotal() == │ │ │ │ │ -0) { │ │ │ │ │ -372 _E_r_r_o_r(_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R, │ │ │ │ │ -373 "Failure in PrimvarRefiner::LimitFaceVarying() -- " │ │ │ │ │ -374 "last level of refinement does not include full topology."); │ │ │ │ │ -375 return; │ │ │ │ │ -376 } │ │ │ │ │ -377 │ │ │ │ │ -378 switch (_refiner._subdivType) { │ │ │ │ │ -379 case _S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K: │ │ │ │ │ -380 limitFVar(src, dst, channel); │ │ │ │ │ -381 break; │ │ │ │ │ -382 case _S_d_c_:_:_S_C_H_E_M_E___L_O_O_P: │ │ │ │ │ -383 limitFVar(src, dst, channel); │ │ │ │ │ -384 break; │ │ │ │ │ -385 case _S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R: │ │ │ │ │ -386 limitFVar(src, dst, channel); │ │ │ │ │ -387 break; │ │ │ │ │ -388 } │ │ │ │ │ -389} │ │ │ │ │ -390 │ │ │ │ │ -391template │ │ │ │ │ -392template │ │ │ │ │ -393inline void │ │ │ │ │ -_3_9_4_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_U_n_i_f_o_r_m(int level, T const & src, U │ │ │ │ │ -& dst) const { │ │ │ │ │ -395 │ │ │ │ │ -396 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ -397 │ │ │ │ │ -398 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -399 Vtr::internal::Level const & child = refinement.child(); │ │ │ │ │ -400 │ │ │ │ │ -401 for (int cFace = 0; cFace < child.getNumFaces(); ++cFace) { │ │ │ │ │ -402 │ │ │ │ │ -403 _V_t_r_:_:_I_n_d_e_x pFace = refinement.getChildFaceParentFace(cFace); │ │ │ │ │ -404 │ │ │ │ │ -405 dst[cFace] = src[pFace]; │ │ │ │ │ -406 } │ │ │ │ │ -407} │ │ │ │ │ -408 │ │ │ │ │ -409template │ │ │ │ │ -410template │ │ │ │ │ -411inline void │ │ │ │ │ -_4_1_2_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_I_n_t_e_r_p_o_l_a_t_e_V_a_r_y_i_n_g(int level, T const & src, U & │ │ │ │ │ -dst) const { │ │ │ │ │ -413 │ │ │ │ │ -414 assert(level>0 && level<=(int)_refiner._refinements.size()); │ │ │ │ │ -415 │ │ │ │ │ -416 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -417 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ -418 │ │ │ │ │ -419 // │ │ │ │ │ -420 // Group values to interpolate based on origin -- note that there may │ │ │ │ │ -421 // be none originating from faces: │ │ │ │ │ -422 // │ │ │ │ │ -423 if (refinement.getNumChildVerticesFromFaces() > 0) { │ │ │ │ │ -424 │ │ │ │ │ -425 for (int face = 0; face < parent.getNumFaces(); ++face) { │ │ │ │ │ -426 │ │ │ │ │ -427 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getFaceChildVertex(face); │ │ │ │ │ -428 if (_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) { │ │ │ │ │ -429 │ │ │ │ │ -430 // Apply the weights to the parent face's vertices: │ │ │ │ │ -431 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fVerts = parent.getFaceVertices(face); │ │ │ │ │ -432 │ │ │ │ │ -433 Weight fVaryingWeight = 1.0f / (Weight) fVerts._s_i_z_e(); │ │ │ │ │ -434 │ │ │ │ │ -435 dst[cVert].Clear(); │ │ │ │ │ -436 for (int i = 0; i < fVerts._s_i_z_e(); ++i) { │ │ │ │ │ -437 dst[cVert].AddWithWeight(src[fVerts[i]], fVaryingWeight); │ │ │ │ │ -438 } │ │ │ │ │ -439 } │ │ │ │ │ -440 } │ │ │ │ │ -441 } │ │ │ │ │ -442 for (int edge = 0; edge < parent.getNumEdges(); ++edge) { │ │ │ │ │ -443 │ │ │ │ │ -444 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getEdgeChildVertex(edge); │ │ │ │ │ -445 if (_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) { │ │ │ │ │ -446 │ │ │ │ │ -447 // Apply the weights to the parent edges's vertices │ │ │ │ │ -448 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = parent.getEdgeVertices(edge); │ │ │ │ │ -449 │ │ │ │ │ -450 dst[cVert].Clear(); │ │ │ │ │ -451 dst[cVert].AddWithWeight(src[eVerts[0]], 0.5f); │ │ │ │ │ -452 dst[cVert].AddWithWeight(src[eVerts[1]], 0.5f); │ │ │ │ │ -453 } │ │ │ │ │ -454 } │ │ │ │ │ -455 for (int vert = 0; vert < parent.getNumVertices(); ++vert) { │ │ │ │ │ -456 │ │ │ │ │ -457 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getVertexChildVertex(vert); │ │ │ │ │ -458 if (_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) { │ │ │ │ │ -459 │ │ │ │ │ -460 // Essentially copy the parent vertex: │ │ │ │ │ -461 dst[cVert].Clear(); │ │ │ │ │ -462 dst[cVert].AddWithWeight(src[vert], 1.0f); │ │ │ │ │ -463 } │ │ │ │ │ -464 } │ │ │ │ │ -465} │ │ │ │ │ -466 │ │ │ │ │ -467 │ │ │ │ │ -468// │ │ │ │ │ -469// Internal implementation methods -- grouping vertices to be interpolated │ │ │ │ │ -470// based on the type of parent component from which they originated: │ │ │ │ │ -471// │ │ │ │ │ -472template │ │ │ │ │ -473template │ │ │ │ │ -474inline void │ │ │ │ │ -475_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_<_R_E_A_L_>_:_:_i_n_t_e_r_p_F_r_o_m_F_a_c_e_s(int level, T const & src, U & dst) │ │ │ │ │ -const { │ │ │ │ │ -476 │ │ │ │ │ -477 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -478 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ -479 │ │ │ │ │ -480 if (refinement.getNumChildVerticesFromFaces() == 0) return; │ │ │ │ │ -481 │ │ │ │ │ -482 _S_d_c_:_:_S_c_h_e_m_e_<_S_C_H_E_M_E_> scheme(_refiner._subdivOptions); │ │ │ │ │ -483 │ │ │ │ │ -484 Vtr::internal::StackBuffer fVertWeights(parent.getMaxValence()); │ │ │ │ │ -485 │ │ │ │ │ -486 for (int face = 0; face < parent.getNumFaces(); ++face) { │ │ │ │ │ -487 │ │ │ │ │ -488 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getFaceChildVertex(face); │ │ │ │ │ -489 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ -490 continue; │ │ │ │ │ -491 │ │ │ │ │ -492 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ -face: │ │ │ │ │ -493 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fVerts = parent.getFaceVertices(face); │ │ │ │ │ -494 │ │ │ │ │ -495 Mask fMask(fVertWeights, 0, 0); │ │ │ │ │ -496 Vtr::internal::FaceInterface fHood(fVerts._s_i_z_e()); │ │ │ │ │ -497 │ │ │ │ │ -498 scheme.ComputeFaceVertexMask(fHood, fMask); │ │ │ │ │ -499 │ │ │ │ │ -500 // Apply the weights to the parent face's vertices: │ │ │ │ │ -501 dst[cVert].Clear(); │ │ │ │ │ -502 │ │ │ │ │ -503 for (int i = 0; i < fVerts._s_i_z_e(); ++i) { │ │ │ │ │ -504 │ │ │ │ │ -505 dst[cVert].AddWithWeight(src[fVerts[i]], fVertWeights[i]); │ │ │ │ │ -506 } │ │ │ │ │ -507 } │ │ │ │ │ -508} │ │ │ │ │ -509 │ │ │ │ │ -510template │ │ │ │ │ -511template │ │ │ │ │ -512inline void │ │ │ │ │ -513PrimvarRefinerReal::interpFromEdges(int level, T const & src, U & dst) │ │ │ │ │ -const { │ │ │ │ │ -514 │ │ │ │ │ -515 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -516 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ -517 Vtr::internal::Level const & child = refinement.child(); │ │ │ │ │ -518 │ │ │ │ │ -519 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -520 │ │ │ │ │ -521 Vtr::internal::EdgeInterface eHood(parent); │ │ │ │ │ -522 │ │ │ │ │ -523 Weight eVertWeights[2]; │ │ │ │ │ -524 Vtr::internal::StackBuffer eFaceWeights(parent.getMaxEdgeFaces │ │ │ │ │ -()); │ │ │ │ │ -525 │ │ │ │ │ -526 for (int edge = 0; edge < parent.getNumEdges(); ++edge) { │ │ │ │ │ -527 │ │ │ │ │ -528 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getEdgeChildVertex(edge); │ │ │ │ │ -529 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ -530 continue; │ │ │ │ │ -531 │ │ │ │ │ -532 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ -edge: │ │ │ │ │ -533 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = parent.getEdgeVertices(edge), │ │ │ │ │ -534 eFaces = parent.getEdgeFaces(edge); │ │ │ │ │ -535 │ │ │ │ │ -536 Mask eMask(eVertWeights, 0, eFaceWeights); │ │ │ │ │ -537 │ │ │ │ │ -538 eHood.SetIndex(edge); │ │ │ │ │ -539 │ │ │ │ │ -540 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = (parent.getEdgeSharpness(edge) > 0.0f) ? _S_d_c_:_: │ │ │ │ │ -_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E : Sdc::Crease::RULE_SMOOTH; │ │ │ │ │ -541 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = child.getVertexRule(cVert); │ │ │ │ │ -542 │ │ │ │ │ -543 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule); │ │ │ │ │ -544 │ │ │ │ │ -545 // Apply the weights to the parent edges's vertices and (if applicable) to │ │ │ │ │ -546 // the child vertices of its incident faces: │ │ │ │ │ -547 dst[cVert].Clear(); │ │ │ │ │ -548 dst[cVert].AddWithWeight(src[eVerts[0]], eVertWeights[0]); │ │ │ │ │ -549 dst[cVert].AddWithWeight(src[eVerts[1]], eVertWeights[1]); │ │ │ │ │ -550 │ │ │ │ │ -551 if (eMask.GetNumFaceWeights() > 0) { │ │ │ │ │ -552 │ │ │ │ │ -553 for (int i = 0; i < eFaces.size(); ++i) { │ │ │ │ │ -554 │ │ │ │ │ -555 if (eMask.AreFaceWeightsForFaceCenters()) { │ │ │ │ │ -556 assert(refinement.getNumChildVerticesFromFaces() > 0); │ │ │ │ │ -557 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(eFaces[i]); │ │ │ │ │ -558 │ │ │ │ │ -559 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ -560 dst[cVert].AddWithWeight(dst[cVertOfFace], eFaceWeights[i]); │ │ │ │ │ -561 } else { │ │ │ │ │ -562 _V_t_r_:_:_I_n_d_e_x pFace = eFaces[i]; │ │ │ │ │ -563 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y pFaceEdges = parent.getFaceEdges(pFace), │ │ │ │ │ -564 pFaceVerts = parent.getFaceVertices(pFace); │ │ │ │ │ -565 │ │ │ │ │ -566 int eInFace = 0; │ │ │ │ │ -567 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ; │ │ │ │ │ -568 │ │ │ │ │ -569 int vInFace = eInFace + 2; │ │ │ │ │ -570 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts._s_i_z_e(); │ │ │ │ │ -571 │ │ │ │ │ -572 _V_t_r_:_:_I_n_d_e_x pVertNext = pFaceVerts[vInFace]; │ │ │ │ │ -573 dst[cVert].AddWithWeight(src[pVertNext], eFaceWeights[i]); │ │ │ │ │ -574 } │ │ │ │ │ -575 } │ │ │ │ │ -576 } │ │ │ │ │ -577 } │ │ │ │ │ -578} │ │ │ │ │ -579 │ │ │ │ │ -580template │ │ │ │ │ -581template │ │ │ │ │ -582inline void │ │ │ │ │ -583PrimvarRefinerReal::interpFromVerts(int level, T const & src, U & dst) │ │ │ │ │ -const { │ │ │ │ │ -584 │ │ │ │ │ -585 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -586 Vtr::internal::Level const & parent = refinement.parent(); │ │ │ │ │ -587 Vtr::internal::Level const & child = refinement.child(); │ │ │ │ │ -588 │ │ │ │ │ -589 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -590 │ │ │ │ │ -591 Vtr::internal::VertexInterface vHood(parent, child); │ │ │ │ │ -592 │ │ │ │ │ -593 Vtr::internal::StackBuffer weightBuffer(2*parent.getMaxValence │ │ │ │ │ -()); │ │ │ │ │ -594 │ │ │ │ │ -595 for (int vert = 0; vert < parent.getNumVertices(); ++vert) { │ │ │ │ │ -596 │ │ │ │ │ -597 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getVertexChildVertex(vert); │ │ │ │ │ -598 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ -599 continue; │ │ │ │ │ -600 │ │ │ │ │ -601 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ -edge: │ │ │ │ │ -602 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = parent.getVertexEdges(vert), │ │ │ │ │ -603 vFaces = parent.getVertexFaces(vert); │ │ │ │ │ -604 │ │ │ │ │ -605 Weight vVertWeight, │ │ │ │ │ -606 * vEdgeWeights = weightBuffer, │ │ │ │ │ -607 * vFaceWeights = vEdgeWeights + vEdges._s_i_z_e(); │ │ │ │ │ -608 │ │ │ │ │ -609 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights); │ │ │ │ │ -610 │ │ │ │ │ -611 vHood.SetIndex(vert, cVert); │ │ │ │ │ -612 │ │ │ │ │ -613 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = parent.getVertexRule(vert); │ │ │ │ │ -614 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = child.getVertexRule(cVert); │ │ │ │ │ -615 │ │ │ │ │ -616 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule); │ │ │ │ │ -617 │ │ │ │ │ -618 // Apply the weights to the parent vertex, the vertices opposite its │ │ │ │ │ -incident │ │ │ │ │ -619 // edges, and the child vertices of its incident faces: │ │ │ │ │ -620 // │ │ │ │ │ -621 // In order to improve numerical precision, it's better to apply smaller │ │ │ │ │ -weights │ │ │ │ │ -622 // first, so begin with the face-weights followed by the edge-weights and │ │ │ │ │ -the │ │ │ │ │ -623 // vertex weight last. │ │ │ │ │ -624 dst[cVert].Clear(); │ │ │ │ │ -625 │ │ │ │ │ -626 if (vMask.GetNumFaceWeights() > 0) { │ │ │ │ │ -627 assert(vMask.AreFaceWeightsForFaceCenters()); │ │ │ │ │ -628 │ │ │ │ │ -629 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ -630 │ │ │ │ │ -631 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(vFaces[i]); │ │ │ │ │ -632 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ -633 dst[cVert].AddWithWeight(dst[cVertOfFace], vFaceWeights[i]); │ │ │ │ │ -634 } │ │ │ │ │ -635 } │ │ │ │ │ -636 if (vMask.GetNumEdgeWeights() > 0) { │ │ │ │ │ -637 │ │ │ │ │ -638 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ -639 │ │ │ │ │ -640 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = parent.getEdgeVertices(vEdges[i]); │ │ │ │ │ -641 _V_t_r_:_:_I_n_d_e_x pVertOppositeEdge = (eVerts[0] == vert) ? eVerts[1] : eVerts[0]; │ │ │ │ │ -642 │ │ │ │ │ -643 dst[cVert].AddWithWeight(src[pVertOppositeEdge], vEdgeWeights[i]); │ │ │ │ │ -644 } │ │ │ │ │ -645 } │ │ │ │ │ -646 dst[cVert].AddWithWeight(src[vert], vVertWeight); │ │ │ │ │ -647 } │ │ │ │ │ -648} │ │ │ │ │ -649 │ │ │ │ │ -650 │ │ │ │ │ -651// │ │ │ │ │ -652// Internal face-varying implementation details: │ │ │ │ │ -653// │ │ │ │ │ -654template │ │ │ │ │ -655template │ │ │ │ │ -656inline void │ │ │ │ │ -657PrimvarRefinerReal::interpFVarFromFaces(int level, T const & src, U & │ │ │ │ │ -dst, int channel) const { │ │ │ │ │ -658 │ │ │ │ │ -659 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -660 │ │ │ │ │ -661 if (refinement.getNumChildVerticesFromFaces() == 0) return; │ │ │ │ │ -662 │ │ │ │ │ -663 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -664 │ │ │ │ │ -665 Vtr::internal::Level const & parentLevel = refinement.parent(); │ │ │ │ │ -666 Vtr::internal::Level const & childLevel = refinement.child(); │ │ │ │ │ -667 │ │ │ │ │ -668 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -669 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -670 │ │ │ │ │ -671 Vtr::internal::StackBuffer fValueWeights │ │ │ │ │ -(parentLevel.getMaxValence()); │ │ │ │ │ -672 │ │ │ │ │ -673 for (int face = 0; face < parentLevel.getNumFaces(); ++face) { │ │ │ │ │ -674 │ │ │ │ │ -675 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getFaceChildVertex(face); │ │ │ │ │ -676 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ -677 continue; │ │ │ │ │ -678 │ │ │ │ │ -679 _V_t_r_:_:_I_n_d_e_x cVertValue = childFVar.getVertexValueOffset(cVert); │ │ │ │ │ -680 │ │ │ │ │ -681 // The only difference for face-varying here is that we get the values │ │ │ │ │ -associated │ │ │ │ │ -682 // with each face-vertex directly from the FVarLevel, rather than using the │ │ │ │ │ -parent │ │ │ │ │ -683 // face-vertices directly. If any face-vertex has any sibling values, then │ │ │ │ │ -we may │ │ │ │ │ -684 // get the wrong one using the face-vertex index directly. │ │ │ │ │ -685 │ │ │ │ │ -686 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ -face: │ │ │ │ │ -687 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fValues = parentFVar.getFaceValues(face); │ │ │ │ │ -688 │ │ │ │ │ -689 Mask fMask(fValueWeights, 0, 0); │ │ │ │ │ -690 Vtr::internal::FaceInterface fHood(fValues.size()); │ │ │ │ │ -691 │ │ │ │ │ -692 scheme.ComputeFaceVertexMask(fHood, fMask); │ │ │ │ │ -693 │ │ │ │ │ -694 // Apply the weights to the parent face's vertices: │ │ │ │ │ -695 dst[cVertValue].Clear(); │ │ │ │ │ -696 │ │ │ │ │ -697 for (int i = 0; i < fValues.size(); ++i) { │ │ │ │ │ -698 dst[cVertValue].AddWithWeight(src[fValues[i]], fValueWeights[i]); │ │ │ │ │ -699 } │ │ │ │ │ -700 } │ │ │ │ │ -701} │ │ │ │ │ -702 │ │ │ │ │ -703template │ │ │ │ │ -704template │ │ │ │ │ -705inline void │ │ │ │ │ -706PrimvarRefinerReal::interpFVarFromEdges(int level, T const & src, U & │ │ │ │ │ -dst, int channel) const { │ │ │ │ │ -707 │ │ │ │ │ -708 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -709 │ │ │ │ │ -710 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -711 │ │ │ │ │ -712 Vtr::internal::Level const & parentLevel = refinement.parent(); │ │ │ │ │ -713 Vtr::internal::Level const & childLevel = refinement.child(); │ │ │ │ │ -714 │ │ │ │ │ -715 Vtr::internal::FVarRefinement const & refineFVar = │ │ │ │ │ -refinement.getFVarRefinement(channel); │ │ │ │ │ -716 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -717 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -718 │ │ │ │ │ -719 // │ │ │ │ │ -720 // Allocate and initialize (if linearly interpolated) interpolation weights │ │ │ │ │ -for │ │ │ │ │ -721 // the edge mask: │ │ │ │ │ -722 // │ │ │ │ │ -723 Weight eVertWeights[2]; │ │ │ │ │ -724 Vtr::internal::StackBuffer eFaceWeights │ │ │ │ │ -(parentLevel.getMaxEdgeFaces()); │ │ │ │ │ -725 │ │ │ │ │ -726 Mask eMask(eVertWeights, 0, eFaceWeights); │ │ │ │ │ -727 │ │ │ │ │ -728 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == _S_d_c_:_: │ │ │ │ │ -_S_C_H_E_M_E___B_I_L_I_N_E_A_R); │ │ │ │ │ -729 if (isLinearFVar) { │ │ │ │ │ -730 eMask.SetNumVertexWeights(2); │ │ │ │ │ -731 eMask.SetNumEdgeWeights(0); │ │ │ │ │ -732 eMask.SetNumFaceWeights(0); │ │ │ │ │ -733 │ │ │ │ │ -734 eVertWeights[0] = 0.5f; │ │ │ │ │ -735 eVertWeights[1] = 0.5f; │ │ │ │ │ -736 } │ │ │ │ │ -737 │ │ │ │ │ -738 Vtr::internal::EdgeInterface eHood(parentLevel); │ │ │ │ │ -739 │ │ │ │ │ -740 for (int edge = 0; edge < parentLevel.getNumEdges(); ++edge) { │ │ │ │ │ -741 │ │ │ │ │ -742 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getEdgeChildVertex(edge); │ │ │ │ │ -743 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ -744 continue; │ │ │ │ │ -745 │ │ │ │ │ -746 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y cVertValues = childFVar.getVertexValues(cVert); │ │ │ │ │ -747 │ │ │ │ │ -748 bool fvarEdgeVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues │ │ │ │ │ -[0]); │ │ │ │ │ -749 if (fvarEdgeVertMatchesVertex) { │ │ │ │ │ -750 // │ │ │ │ │ -751 // If smoothly interpolated, compute new weights for the edge mask: │ │ │ │ │ -752 // │ │ │ │ │ -753 if (!isLinearFVar) { │ │ │ │ │ -754 eHood.SetIndex(edge); │ │ │ │ │ -755 │ │ │ │ │ -756 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = (parentLevel.getEdgeSharpness(edge) > 0.0f) │ │ │ │ │ -757 ? _S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E : Sdc::Crease::RULE_SMOOTH; │ │ │ │ │ -758 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = childLevel.getVertexRule(cVert); │ │ │ │ │ -759 │ │ │ │ │ -760 scheme.ComputeEdgeVertexMask(eHood, eMask, pRule, cRule); │ │ │ │ │ -761 } │ │ │ │ │ -762 │ │ │ │ │ -763 // Apply the weights to the parent edge's vertices and (if applicable) to │ │ │ │ │ -764 // the child vertices of its incident faces: │ │ │ │ │ -765 // │ │ │ │ │ -766 // Even though the face-varying topology matches the vertex topology, we │ │ │ │ │ -need │ │ │ │ │ -767 // to be careful here when getting values corresponding to the two end- │ │ │ │ │ -vertices. │ │ │ │ │ -768 // While the edge may be continuous, the vertices at their ends may have │ │ │ │ │ -769 // discontinuities elsewhere in their neighborhood (i.e. on the "other │ │ │ │ │ -side" │ │ │ │ │ -770 // of the end-vertex) and so have sibling values associated with them. In │ │ │ │ │ -most │ │ │ │ │ -771 // cases the topology for an end-vertex will match and we can use it │ │ │ │ │ -directly, │ │ │ │ │ -772 // but we must still check and retrieve as needed. │ │ │ │ │ -773 // │ │ │ │ │ -774 // Indices for values corresponding to face-vertices are guaranteed to │ │ │ │ │ -match, │ │ │ │ │ -775 // so we can use the child-vertex indices directly. │ │ │ │ │ -776 // │ │ │ │ │ -777 // And by "directly", we always use getVertexValue(vertexIndex) to │ │ │ │ │ -reference │ │ │ │ │ -778 // values in the "src" to account for the possible indirection that may │ │ │ │ │ -exist at │ │ │ │ │ -779 // level 0 -- where there may be fewer values than vertices and an │ │ │ │ │ -additional │ │ │ │ │ -780 // indirection is necessary. We can use a vertex index directly for "dst" │ │ │ │ │ -when │ │ │ │ │ -781 // it matches. │ │ │ │ │ -782 // │ │ │ │ │ -783 _V_t_r_:_:_I_n_d_e_x eVertValues[2]; │ │ │ │ │ -784 │ │ │ │ │ -785 parentFVar.getEdgeFaceValues(edge, 0, eVertValues); │ │ │ │ │ -786 │ │ │ │ │ -787 _I_n_d_e_x cVertValue = cVertValues[0]; │ │ │ │ │ -788 │ │ │ │ │ -789 dst[cVertValue].Clear(); │ │ │ │ │ -790 dst[cVertValue].AddWithWeight(src[eVertValues[0]], eVertWeights[0]); │ │ │ │ │ -791 dst[cVertValue].AddWithWeight(src[eVertValues[1]], eVertWeights[1]); │ │ │ │ │ -792 │ │ │ │ │ -793 if (eMask.GetNumFaceWeights() > 0) { │ │ │ │ │ -794 │ │ │ │ │ -795 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eFaces = parentLevel.getEdgeFaces(edge); │ │ │ │ │ -796 │ │ │ │ │ -797 for (int i = 0; i < eFaces.size(); ++i) { │ │ │ │ │ -798 if (eMask.AreFaceWeightsForFaceCenters()) { │ │ │ │ │ -799 │ │ │ │ │ -800 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(eFaces[i]); │ │ │ │ │ -801 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ -802 │ │ │ │ │ -803 _V_t_r_:_:_I_n_d_e_x cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace); │ │ │ │ │ -804 dst[cVertValue].AddWithWeight(dst[cValueOfFace], eFaceWeights[i]); │ │ │ │ │ -805 } else { │ │ │ │ │ -806 _V_t_r_:_:_I_n_d_e_x pFace = eFaces[i]; │ │ │ │ │ -807 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y pFaceEdges = parentLevel.getFaceEdges(pFace), │ │ │ │ │ -808 pFaceVerts = parentLevel.getFaceVertices(pFace); │ │ │ │ │ -809 │ │ │ │ │ -810 int eInFace = 0; │ │ │ │ │ -811 for ( ; pFaceEdges[eInFace] != edge; ++eInFace ) ; │ │ │ │ │ -812 │ │ │ │ │ -813 // Edge "i" spans vertices [i,i+1] so we want i+2... │ │ │ │ │ -814 int vInFace = eInFace + 2; │ │ │ │ │ -815 if (vInFace >= pFaceVerts.size()) vInFace -= pFaceVerts._s_i_z_e(); │ │ │ │ │ -816 │ │ │ │ │ -817 _V_t_r_:_:_I_n_d_e_x pValueNext = parentFVar.getFaceValues(pFace)[vInFace]; │ │ │ │ │ -818 dst[cVertValue].AddWithWeight(src[pValueNext], eFaceWeights[i]); │ │ │ │ │ -819 } │ │ │ │ │ -820 } │ │ │ │ │ -821 } │ │ │ │ │ -822 } else { │ │ │ │ │ -823 // │ │ │ │ │ -824 // Mismatched edge-verts should just be linearly interpolated between the │ │ │ │ │ -pairs of │ │ │ │ │ -825 // values for each sibling of the child edge-vertex -- the question is: │ │ │ │ │ -which face │ │ │ │ │ -826 // holds that pair of values for a given sibling? │ │ │ │ │ -827 // │ │ │ │ │ -828 // In the manifold case, the sibling and edge-face indices will correspond. │ │ │ │ │ -We │ │ │ │ │ -829 // will eventually need to update this to account for > 3 incident faces. │ │ │ │ │ -830 // │ │ │ │ │ -831 for (int i = 0; i < cVertValues.size(); ++i) { │ │ │ │ │ -832 _V_t_r_:_:_I_n_d_e_x eVertValues[2]; │ │ │ │ │ -833 int eFaceIndex = refineFVar.getChildValueParentSource(cVert, i); │ │ │ │ │ -834 assert(eFaceIndex == i); │ │ │ │ │ -835 │ │ │ │ │ -836 parentFVar.getEdgeFaceValues(edge, eFaceIndex, eVertValues); │ │ │ │ │ -837 │ │ │ │ │ -838 _I_n_d_e_x cVertValue = cVertValues[i]; │ │ │ │ │ -839 │ │ │ │ │ -840 dst[cVertValue].Clear(); │ │ │ │ │ -841 dst[cVertValue].AddWithWeight(src[eVertValues[0]], 0.5); │ │ │ │ │ -842 dst[cVertValue].AddWithWeight(src[eVertValues[1]], 0.5); │ │ │ │ │ -843 } │ │ │ │ │ -844 } │ │ │ │ │ -845 } │ │ │ │ │ -846} │ │ │ │ │ -847 │ │ │ │ │ -848template │ │ │ │ │ -849template │ │ │ │ │ -850inline void │ │ │ │ │ -851PrimvarRefinerReal::interpFVarFromVerts(int level, T const & src, U & │ │ │ │ │ -dst, int channel) const { │ │ │ │ │ -852 │ │ │ │ │ -853 Vtr::internal::Refinement const & refinement = _refiner.getRefinement │ │ │ │ │ -(level-1); │ │ │ │ │ -854 │ │ │ │ │ -855 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -856 │ │ │ │ │ -857 Vtr::internal::Level const & parentLevel = refinement.parent(); │ │ │ │ │ -858 Vtr::internal::Level const & childLevel = refinement.child(); │ │ │ │ │ -859 │ │ │ │ │ -860 Vtr::internal::FVarRefinement const & refineFVar = │ │ │ │ │ -refinement.getFVarRefinement(channel); │ │ │ │ │ -861 Vtr::internal::FVarLevel const & parentFVar = parentLevel.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -862 Vtr::internal::FVarLevel const & childFVar = childLevel.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -863 │ │ │ │ │ -864 bool isLinearFVar = parentFVar.isLinear() || (_refiner._subdivType == _S_d_c_:_: │ │ │ │ │ -_S_C_H_E_M_E___B_I_L_I_N_E_A_R); │ │ │ │ │ -865 │ │ │ │ │ -866 Vtr::internal::StackBuffer weightBuffer │ │ │ │ │ -(2*parentLevel.getMaxValence()); │ │ │ │ │ -867 │ │ │ │ │ -868 Vtr::internal::StackBuffer vEdgeValues │ │ │ │ │ -(parentLevel.getMaxValence()); │ │ │ │ │ -869 │ │ │ │ │ -870 Vtr::internal::VertexInterface vHood(parentLevel, childLevel); │ │ │ │ │ -871 │ │ │ │ │ -872 for (int vert = 0; vert < parentLevel.getNumVertices(); ++vert) { │ │ │ │ │ -873 │ │ │ │ │ -874 _V_t_r_:_:_I_n_d_e_x cVert = refinement.getVertexChildVertex(vert); │ │ │ │ │ -875 if (!_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVert)) │ │ │ │ │ -876 continue; │ │ │ │ │ -877 │ │ │ │ │ -878 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y pVertValues = parentFVar.getVertexValues(vert), │ │ │ │ │ -879 cVertValues = childFVar.getVertexValues(cVert); │ │ │ │ │ -880 │ │ │ │ │ -881 bool fvarVertVertMatchesVertex = childFVar.valueTopologyMatches(cVertValues │ │ │ │ │ -[0]); │ │ │ │ │ -882 if (isLinearFVar && fvarVertVertMatchesVertex) { │ │ │ │ │ -883 dst[cVertValues[0]].Clear(); │ │ │ │ │ -884 dst[cVertValues[0]].AddWithWeight(src[pVertValues[0]], 1.0f); │ │ │ │ │ -885 continue; │ │ │ │ │ -886 } │ │ │ │ │ -887 │ │ │ │ │ -888 if (fvarVertVertMatchesVertex) { │ │ │ │ │ -889 // │ │ │ │ │ -890 // Declare and compute mask weights for this vertex relative to its parent │ │ │ │ │ -edge: │ │ │ │ │ -891 // │ │ │ │ │ -892 // (We really need to encapsulate this somewhere else for use here and in │ │ │ │ │ -the │ │ │ │ │ -893 // general case) │ │ │ │ │ -894 // │ │ │ │ │ -895 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = parentLevel.getVertexEdges(vert); │ │ │ │ │ -896 │ │ │ │ │ -897 Weight vVertWeight; │ │ │ │ │ -898 Weight * vEdgeWeights = weightBuffer; │ │ │ │ │ -899 Weight * vFaceWeights = vEdgeWeights + vEdges._s_i_z_e(); │ │ │ │ │ -900 │ │ │ │ │ -901 Mask vMask(&vVertWeight, vEdgeWeights, vFaceWeights); │ │ │ │ │ -902 │ │ │ │ │ -903 vHood.SetIndex(vert, cVert); │ │ │ │ │ -904 │ │ │ │ │ -905 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e pRule = parentLevel.getVertexRule(vert); │ │ │ │ │ -906 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e cRule = childLevel.getVertexRule(cVert); │ │ │ │ │ -907 │ │ │ │ │ -908 scheme.ComputeVertexVertexMask(vHood, vMask, pRule, cRule); │ │ │ │ │ -909 │ │ │ │ │ -910 // Apply the weights to the parent vertex, the vertices opposite its │ │ │ │ │ -incident │ │ │ │ │ -911 // edges, and the child vertices of its incident faces: │ │ │ │ │ -912 // │ │ │ │ │ -913 // Even though the face-varying topology matches the vertex topology, we │ │ │ │ │ -need │ │ │ │ │ -914 // to be careful here when getting values corresponding to vertices at the │ │ │ │ │ -915 // ends of edges. While the edge may be continuous, the end vertex may have │ │ │ │ │ -916 // discontinuities elsewhere in their neighborhood (i.e. on the "other │ │ │ │ │ -side" │ │ │ │ │ -917 // of the end-vertex) and so have sibling values associated with them. In │ │ │ │ │ -most │ │ │ │ │ -918 // cases the topology for an end-vertex will match and we can use it │ │ │ │ │ -directly, │ │ │ │ │ -919 // but we must still check and retrieve as needed. │ │ │ │ │ -920 // │ │ │ │ │ -921 // Indices for values corresponding to face-vertices are guaranteed to │ │ │ │ │ -match, │ │ │ │ │ -922 // so we can use the child-vertex indices directly. │ │ │ │ │ -923 // │ │ │ │ │ -924 // And by "directly", we always use getVertexValue(vertexIndex) to │ │ │ │ │ -reference │ │ │ │ │ -925 // values in the "src" to account for the possible indirection that may │ │ │ │ │ -exist at │ │ │ │ │ -926 // level 0 -- where there may be fewer values than vertices and an │ │ │ │ │ -additional │ │ │ │ │ -927 // indirection is necessary. We can use a vertex index directly for "dst" │ │ │ │ │ -when │ │ │ │ │ -928 // it matches. │ │ │ │ │ -929 // │ │ │ │ │ -930 // As with applying the mask to vertex data, in order to improve numerical │ │ │ │ │ -931 // precision, it's better to apply smaller weights first, so begin with the │ │ │ │ │ -932 // face-weights followed by the edge-weights and the vertex weight last. │ │ │ │ │ -933 // │ │ │ │ │ -934 _V_t_r_:_:_I_n_d_e_x pVertValue = pVertValues[0]; │ │ │ │ │ -935 _V_t_r_:_:_I_n_d_e_x cVertValue = cVertValues[0]; │ │ │ │ │ -936 │ │ │ │ │ -937 dst[cVertValue].Clear(); │ │ │ │ │ -938 if (vMask.GetNumFaceWeights() > 0) { │ │ │ │ │ -939 assert(vMask.AreFaceWeightsForFaceCenters()); │ │ │ │ │ -940 │ │ │ │ │ -941 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vFaces = parentLevel.getVertexFaces(vert); │ │ │ │ │ -942 │ │ │ │ │ -943 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ -944 │ │ │ │ │ -945 _V_t_r_:_:_I_n_d_e_x cVertOfFace = refinement.getFaceChildVertex(vFaces[i]); │ │ │ │ │ -946 assert(_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d(cVertOfFace)); │ │ │ │ │ -947 │ │ │ │ │ -948 _V_t_r_:_:_I_n_d_e_x cValueOfFace = childFVar.getVertexValueOffset(cVertOfFace); │ │ │ │ │ -949 dst[cVertValue].AddWithWeight(dst[cValueOfFace], vFaceWeights[i]); │ │ │ │ │ -950 } │ │ │ │ │ -951 } │ │ │ │ │ -952 if (vMask.GetNumEdgeWeights() > 0) { │ │ │ │ │ -953 │ │ │ │ │ -954 parentFVar.getVertexEdgeValues(vert, vEdgeValues); │ │ │ │ │ -955 │ │ │ │ │ -956 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ -957 dst[cVertValue].AddWithWeight(src[vEdgeValues[i]], vEdgeWeights[i]); │ │ │ │ │ -958 } │ │ │ │ │ -959 } │ │ │ │ │ -960 dst[cVertValue].AddWithWeight(src[pVertValue], vVertWeight); │ │ │ │ │ -961 } else { │ │ │ │ │ -962 // │ │ │ │ │ -963 // Each FVar value associated with a vertex will be either a corner or a │ │ │ │ │ -crease, │ │ │ │ │ -964 // or potentially in transition from corner to crease: │ │ │ │ │ -965 // - if the CHILD is a corner, there can be no transition so we have a │ │ │ │ │ -corner │ │ │ │ │ -966 // - otherwise if the PARENT is a crease, both will be creases (no │ │ │ │ │ -transition) │ │ │ │ │ -967 // - otherwise the parent must be a corner and the child a crease │ │ │ │ │ -(transition) │ │ │ │ │ -968 // │ │ │ │ │ -969 Vtr::internal::FVarLevel::ConstValueTagArray pValueTags = │ │ │ │ │ -parentFVar.getVertexValueTags(vert); │ │ │ │ │ -970 Vtr::internal::FVarLevel::ConstValueTagArray cValueTags = │ │ │ │ │ -childFVar.getVertexValueTags(cVert); │ │ │ │ │ -971 │ │ │ │ │ -972 for (int cSiblingIndex = 0; cSiblingIndex < cVertValues.size(); │ │ │ │ │ -++cSiblingIndex) { │ │ │ │ │ -973 int pSiblingIndex = refineFVar.getChildValueParentSource(cVert, │ │ │ │ │ -cSiblingIndex); │ │ │ │ │ -974 assert(pSiblingIndex == cSiblingIndex); │ │ │ │ │ -975 │ │ │ │ │ -976 typedef Vtr::internal::FVarLevel::Sibling SiblingIntType; │ │ │ │ │ -977 │ │ │ │ │ -978 SiblingIntType cSibling = (SiblingIntType) cSiblingIndex; │ │ │ │ │ -979 SiblingIntType pSibling = (SiblingIntType) pSiblingIndex; │ │ │ │ │ -980 │ │ │ │ │ -981 _V_t_r_:_:_I_n_d_e_x pVertValue = pVertValues[pSibling]; │ │ │ │ │ -982 _V_t_r_:_:_I_n_d_e_x cVertValue = cVertValues[cSibling]; │ │ │ │ │ -983 │ │ │ │ │ -984 dst[cVertValue].Clear(); │ │ │ │ │ -985 if (isLinearFVar || cValueTags[cSibling].isCorner()) { │ │ │ │ │ -986 dst[cVertValue].AddWithWeight(src[pVertValue], 1.0f); │ │ │ │ │ -987 } else { │ │ │ │ │ -988 // │ │ │ │ │ -989 // We have either a crease or a transition from corner to crease -- in │ │ │ │ │ -990 // either case, we need the end values for the full/fractional crease: │ │ │ │ │ -991 // │ │ │ │ │ -992 _I_n_d_e_x pEndValues[2]; │ │ │ │ │ -993 parentFVar.getVertexCreaseEndValues(vert, pSibling, pEndValues); │ │ │ │ │ -994 │ │ │ │ │ -995 Weight vWeight = 0.75f; │ │ │ │ │ -996 Weight eWeight = 0.125f; │ │ │ │ │ -997 │ │ │ │ │ -998 // │ │ │ │ │ -999 // If semi-sharp we need to apply fractional weighting -- if made sharp │ │ │ │ │ -because │ │ │ │ │ -1000 // of the other sibling (dependent-sharp) use the fractional weight from │ │ │ │ │ -that │ │ │ │ │ -1001 // other sibling (should only occur when there are 2): │ │ │ │ │ -1002 // │ │ │ │ │ -1003 if (pValueTags[pSibling].isSemiSharp()) { │ │ │ │ │ -1004 Weight wCorner = pValueTags[pSibling].isDepSharp() │ │ │ │ │ -1005 ? refineFVar.getFractionalWeight(vert, !pSibling, cVert, !cSibling) │ │ │ │ │ -1006 : refineFVar.getFractionalWeight(vert, pSibling, cVert, cSibling); │ │ │ │ │ -1007 Weight wCrease = 1.0f - wCorner; │ │ │ │ │ -1008 │ │ │ │ │ -1009 vWeight = wCrease * 0.75f + wCorner; │ │ │ │ │ -1010 eWeight = wCrease * 0.125f; │ │ │ │ │ -1011 } │ │ │ │ │ -1012 dst[cVertValue].AddWithWeight(src[pEndValues[0]], eWeight); │ │ │ │ │ -1013 dst[cVertValue].AddWithWeight(src[pEndValues[1]], eWeight); │ │ │ │ │ -1014 dst[cVertValue].AddWithWeight(src[pVertValue], vWeight); │ │ │ │ │ -1015 } │ │ │ │ │ -1016 } │ │ │ │ │ -1017 } │ │ │ │ │ -1018 } │ │ │ │ │ -1019} │ │ │ │ │ -1020 │ │ │ │ │ -1021template │ │ │ │ │ -1022template │ │ │ │ │ -1023inline void │ │ │ │ │ -1024PrimvarRefinerReal::limit(T const & src, U & dstPos, U1 * dstTan1Ptr, │ │ │ │ │ -U2 * dstTan2Ptr) const { │ │ │ │ │ -1025 │ │ │ │ │ -1026 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -1027 │ │ │ │ │ -1028 Vtr::internal::Level const & level = _refiner.getLevel │ │ │ │ │ -(_refiner.GetMaxLevel()); │ │ │ │ │ -1029 │ │ │ │ │ -1030 int maxWeightsPerMask = 1 + 2 * level.getMaxValence(); │ │ │ │ │ -1031 bool hasTangents = (dstTan1Ptr && dstTan2Ptr); │ │ │ │ │ -1032 int numMasks = 1 + (hasTangents ? 2 : 0); │ │ │ │ │ -1033 │ │ │ │ │ -1034 Vtr::internal::StackBuffer indexBuffer(maxWeightsPerMask); │ │ │ │ │ -1035 Vtr::internal::StackBuffer weightBuffer(numMasks * │ │ │ │ │ -maxWeightsPerMask); │ │ │ │ │ -1036 │ │ │ │ │ -1037 Weight * vPosWeights = weightBuffer, │ │ │ │ │ -1038 * ePosWeights = vPosWeights + 1, │ │ │ │ │ -1039 * fPosWeights = ePosWeights + level.getMaxValence(); │ │ │ │ │ -1040 Weight * vTan1Weights = vPosWeights + maxWeightsPerMask, │ │ │ │ │ -1041 * eTan1Weights = ePosWeights + maxWeightsPerMask, │ │ │ │ │ -1042 * fTan1Weights = fPosWeights + maxWeightsPerMask; │ │ │ │ │ -1043 Weight * vTan2Weights = vTan1Weights + maxWeightsPerMask, │ │ │ │ │ -1044 * eTan2Weights = eTan1Weights + maxWeightsPerMask, │ │ │ │ │ -1045 * fTan2Weights = fTan1Weights + maxWeightsPerMask; │ │ │ │ │ -1046 │ │ │ │ │ -1047 Mask posMask( vPosWeights, ePosWeights, fPosWeights); │ │ │ │ │ -1048 Mask tan1Mask(vTan1Weights, eTan1Weights, fTan1Weights); │ │ │ │ │ -1049 Mask tan2Mask(vTan2Weights, eTan2Weights, fTan2Weights); │ │ │ │ │ -1050 │ │ │ │ │ -1051 // This is a bit obscure -- assigning both parent and child as last level │ │ │ │ │ --- but │ │ │ │ │ -1052 // this mask type was intended for another purpose. Consider one for the │ │ │ │ │ -limit: │ │ │ │ │ -1053 Vtr::internal::VertexInterface vHood(level, level); │ │ │ │ │ -1054 │ │ │ │ │ -1055 for (int vert = 0; vert < level.getNumVertices(); ++vert) { │ │ │ │ │ -1056 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = level.getVertexEdges(vert); │ │ │ │ │ -1057 │ │ │ │ │ -1058 // Incomplete vertices (present in sparse refinement) do not have their │ │ │ │ │ -full │ │ │ │ │ -1059 // topological neighborhood to determine a proper limit -- just leave the │ │ │ │ │ -1060 // vertex at the refined location and continue to the next: │ │ │ │ │ -1061 if (level.getVertexTag(vert)._incomplete || (vEdges.size() == 0)) { │ │ │ │ │ -1062 dstPos[vert].Clear(); │ │ │ │ │ -1063 dstPos[vert].AddWithWeight(src[vert], 1.0); │ │ │ │ │ -1064 if (hasTangents) { │ │ │ │ │ -1065 (*dstTan1Ptr)[vert].Clear(); │ │ │ │ │ -1066 (*dstTan2Ptr)[vert].Clear(); │ │ │ │ │ -1067 } │ │ │ │ │ -1068 continue; │ │ │ │ │ -1069 } │ │ │ │ │ -1070 │ │ │ │ │ -1071 // │ │ │ │ │ -1072 // Limit masks require the subdivision Rule for the vertex in order to │ │ │ │ │ -deal │ │ │ │ │ -1073 // with infinitely sharp features correctly -- including boundaries and │ │ │ │ │ -corners. │ │ │ │ │ -1074 // The vertex neighborhood is minimally defined with vertex and edge │ │ │ │ │ -counts. │ │ │ │ │ -1075 // │ │ │ │ │ -1076 _S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e vRule = level.getVertexRule(vert); │ │ │ │ │ -1077 │ │ │ │ │ -1078 // This is a bit obscure -- child vertex index will be ignored here │ │ │ │ │ -1079 vHood.SetIndex(vert, vert); │ │ │ │ │ -1080 │ │ │ │ │ -1081 if (hasTangents) { │ │ │ │ │ -1082 scheme.ComputeVertexLimitMask(vHood, posMask, tan1Mask, tan2Mask, vRule); │ │ │ │ │ -1083 } else { │ │ │ │ │ -1084 scheme.ComputeVertexLimitMask(vHood, posMask, vRule); │ │ │ │ │ -1085 } │ │ │ │ │ -1086 │ │ │ │ │ -1087 // │ │ │ │ │ -1088 // Gather the neighboring vertices of this vertex -- the vertices opposite │ │ │ │ │ -its │ │ │ │ │ -1089 // incident edges, and the opposite vertices of its incident faces: │ │ │ │ │ -1090 // │ │ │ │ │ -1091 _I_n_d_e_x * eIndices = indexBuffer; │ │ │ │ │ -1092 _I_n_d_e_x * fIndices = indexBuffer + vEdges._s_i_z_e(); │ │ │ │ │ -1093 │ │ │ │ │ -1094 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ -1095 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y eVerts = level.getEdgeVertices(vEdges[i]); │ │ │ │ │ -1096 │ │ │ │ │ -1097 eIndices[i] = (eVerts[0] == vert) ? eVerts[1] : eVerts[0]; │ │ │ │ │ -1098 } │ │ │ │ │ -1099 if (posMask.GetNumFaceWeights() || (hasTangents && │ │ │ │ │ -tan1Mask.GetNumFaceWeights())) { │ │ │ │ │ -1100 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vFaces = level.getVertexFaces(vert); │ │ │ │ │ -1101 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y vInFace = level.getVertexFaceLocalIndices(vert); │ │ │ │ │ -1102 │ │ │ │ │ -1103 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ -1104 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y fVerts = level.getFaceVertices(vFaces[i]); │ │ │ │ │ -1105 │ │ │ │ │ -1106 _L_o_c_a_l_I_n_d_e_x vOppInFace = (vInFace[i] + 2); │ │ │ │ │ -1107 if (vOppInFace >= fVerts.size()) vOppInFace -= (_L_o_c_a_l_I_n_d_e_x)fVerts._s_i_z_e(); │ │ │ │ │ -1108 │ │ │ │ │ -1109 fIndices[i] = level.getFaceVertices(vFaces[i])[vOppInFace]; │ │ │ │ │ -1110 } │ │ │ │ │ -1111 } │ │ │ │ │ -1112 │ │ │ │ │ -1113 // │ │ │ │ │ -1114 // Combine the weights and indices for position and tangents. As with │ │ │ │ │ -applying │ │ │ │ │ -1115 // refinement masks to vertex data, in order to improve numerical │ │ │ │ │ -precision, it's │ │ │ │ │ -1116 // better to apply smaller weights first, so begin with the face-weights │ │ │ │ │ -followed │ │ │ │ │ -1117 // by the edge-weights and the vertex weight last. │ │ │ │ │ -1118 // │ │ │ │ │ -1119 dstPos[vert].Clear(); │ │ │ │ │ -1120 for (int i = 0; i < posMask.GetNumFaceWeights(); ++i) { │ │ │ │ │ -1121 dstPos[vert].AddWithWeight(src[fIndices[i]], fPosWeights[i]); │ │ │ │ │ -1122 } │ │ │ │ │ -1123 for (int i = 0; i < posMask.GetNumEdgeWeights(); ++i) { │ │ │ │ │ -1124 dstPos[vert].AddWithWeight(src[eIndices[i]], ePosWeights[i]); │ │ │ │ │ -1125 } │ │ │ │ │ -1126 dstPos[vert].AddWithWeight(src[vert], vPosWeights[0]); │ │ │ │ │ -1127 │ │ │ │ │ -1128 // │ │ │ │ │ -1129 // Apply the tangent masks -- both will have the same number of weights │ │ │ │ │ -and │ │ │ │ │ -1130 // indices (one tangent may be "padded" to accommodate the other), but │ │ │ │ │ -these │ │ │ │ │ -1131 // may differ from those of the position: │ │ │ │ │ -1132 // │ │ │ │ │ -1133 if (hasTangents) { │ │ │ │ │ -1134 assert(tan1Mask.GetNumFaceWeights() == tan2Mask.GetNumFaceWeights()); │ │ │ │ │ -1135 assert(tan1Mask.GetNumEdgeWeights() == tan2Mask.GetNumEdgeWeights()); │ │ │ │ │ -1136 │ │ │ │ │ -1137 U1 & dstTan1 = *dstTan1Ptr; │ │ │ │ │ -1138 U2 & dstTan2 = *dstTan2Ptr; │ │ │ │ │ -1139 │ │ │ │ │ -1140 dstTan1[vert].Clear(); │ │ │ │ │ -1141 dstTan2[vert].Clear(); │ │ │ │ │ -1142 for (int i = 0; i < tan1Mask.GetNumFaceWeights(); ++i) { │ │ │ │ │ -1143 dstTan1[vert].AddWithWeight(src[fIndices[i]], fTan1Weights[i]); │ │ │ │ │ -1144 dstTan2[vert].AddWithWeight(src[fIndices[i]], fTan2Weights[i]); │ │ │ │ │ -1145 } │ │ │ │ │ -1146 for (int i = 0; i < tan1Mask.GetNumEdgeWeights(); ++i) { │ │ │ │ │ -1147 dstTan1[vert].AddWithWeight(src[eIndices[i]], eTan1Weights[i]); │ │ │ │ │ -1148 dstTan2[vert].AddWithWeight(src[eIndices[i]], eTan2Weights[i]); │ │ │ │ │ -1149 } │ │ │ │ │ -1150 dstTan1[vert].AddWithWeight(src[vert], vTan1Weights[0]); │ │ │ │ │ -1151 dstTan2[vert].AddWithWeight(src[vert], vTan2Weights[0]); │ │ │ │ │ -1152 } │ │ │ │ │ -1153 } │ │ │ │ │ -1154} │ │ │ │ │ -1155 │ │ │ │ │ -1156template │ │ │ │ │ -1157template │ │ │ │ │ -1158inline void │ │ │ │ │ -1159PrimvarRefinerReal::limitFVar(T const & src, U & dst, int channel) │ │ │ │ │ -const { │ │ │ │ │ -1160 │ │ │ │ │ -1161 Sdc::Scheme scheme(_refiner._subdivOptions); │ │ │ │ │ -1162 │ │ │ │ │ -1163 Vtr::internal::Level const & level = _refiner.getLevel │ │ │ │ │ -(_refiner.GetMaxLevel()); │ │ │ │ │ -1164 Vtr::internal::FVarLevel const & fvarChannel = level.getFVarLevel │ │ │ │ │ -(channel); │ │ │ │ │ -1165 │ │ │ │ │ -1166 int maxWeightsPerMask = 1 + 2 * level.getMaxValence(); │ │ │ │ │ -1167 │ │ │ │ │ -1168 Vtr::internal::StackBuffer weightBuffer(maxWeightsPerMask); │ │ │ │ │ -1169 Vtr::internal::StackBuffer vEdgeBuffer(level.getMaxValence()); │ │ │ │ │ -1170 │ │ │ │ │ -1171 // This is a bit obscure -- assign both parent and child as last level │ │ │ │ │ -1172 Vtr::internal::VertexInterface vHood(level, level); │ │ │ │ │ -1173 │ │ │ │ │ -1174 for (int vert = 0; vert < level.getNumVertices(); ++vert) { │ │ │ │ │ -1175 │ │ │ │ │ -1176 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vEdges = level.getVertexEdges(vert); │ │ │ │ │ -1177 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vValues = fvarChannel.getVertexValues(vert); │ │ │ │ │ -1178 │ │ │ │ │ -1179 // Incomplete vertices (present in sparse refinement) do not have their │ │ │ │ │ -full │ │ │ │ │ -1180 // topological neighborhood to determine a proper limit -- just leave the │ │ │ │ │ -1181 // values (perhaps more than one per vertex) at the refined location. │ │ │ │ │ -1182 // │ │ │ │ │ -1183 // The same can be done if the face-varying channel is purely linear. │ │ │ │ │ -1184 // │ │ │ │ │ -1185 bool isIncomplete = (level.getVertexTag(vert)._incomplete || (vEdges.size │ │ │ │ │ -() == 0)); │ │ │ │ │ -1186 if (isIncomplete || fvarChannel.isLinear()) { │ │ │ │ │ -1187 for (int i = 0; i < vValues.size(); ++i) { │ │ │ │ │ -1188 _V_t_r_:_:_I_n_d_e_x vValue = vValues[i]; │ │ │ │ │ -1189 │ │ │ │ │ -1190 dst[vValue].Clear(); │ │ │ │ │ -1191 dst[vValue].AddWithWeight(src[vValue], 1.0f); │ │ │ │ │ -1192 } │ │ │ │ │ -1193 continue; │ │ │ │ │ -1194 } │ │ │ │ │ -1195 │ │ │ │ │ -1196 bool fvarVertMatchesVertex = fvarChannel.valueTopologyMatches(vValues[0]); │ │ │ │ │ -1197 if (fvarVertMatchesVertex) { │ │ │ │ │ -1198 │ │ │ │ │ -1199 // Assign the mask weights to the common buffer and compute the mask: │ │ │ │ │ -1200 // │ │ │ │ │ -1201 Weight * vWeights = weightBuffer, │ │ │ │ │ -1202 * eWeights = vWeights + 1, │ │ │ │ │ -1203 * fWeights = eWeights + vEdges._s_i_z_e(); │ │ │ │ │ -1204 │ │ │ │ │ -1205 Mask vMask(vWeights, eWeights, fWeights); │ │ │ │ │ -1206 │ │ │ │ │ -1207 vHood.SetIndex(vert, vert); │ │ │ │ │ -1208 │ │ │ │ │ -1209 scheme.ComputeVertexLimitMask(vHood, vMask, level.getVertexRule(vert)); │ │ │ │ │ -1210 │ │ │ │ │ -1211 // │ │ │ │ │ -1212 // Apply mask to corresponding FVar values for neighboring vertices: │ │ │ │ │ -1213 // │ │ │ │ │ -1214 _V_t_r_:_:_I_n_d_e_x vValue = vValues[0]; │ │ │ │ │ -1215 │ │ │ │ │ -1216 dst[vValue].Clear(); │ │ │ │ │ -1217 if (vMask.GetNumFaceWeights() > 0) { │ │ │ │ │ -1218 assert(!vMask.AreFaceWeightsForFaceCenters()); │ │ │ │ │ -1219 │ │ │ │ │ -1220 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y vFaces = level.getVertexFaces(vert); │ │ │ │ │ -1221 _C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y vInFace = level.getVertexFaceLocalIndices(vert); │ │ │ │ │ -1222 │ │ │ │ │ -1223 for (int i = 0; i < vFaces.size(); ++i) { │ │ │ │ │ -1224 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y faceValues = fvarChannel.getFaceValues(vFaces[i]); │ │ │ │ │ -1225 _L_o_c_a_l_I_n_d_e_x vOppInFace = vInFace[i] + 2; │ │ │ │ │ -1226 if (vOppInFace >= faceValues.size()) vOppInFace -= faceValues._s_i_z_e(); │ │ │ │ │ -1227 │ │ │ │ │ -1228 _I_n_d_e_x vValueOppositeFace = faceValues[vOppInFace]; │ │ │ │ │ -1229 │ │ │ │ │ -1230 dst[vValue].AddWithWeight(src[vValueOppositeFace], fWeights[i]); │ │ │ │ │ -1231 } │ │ │ │ │ -1232 } │ │ │ │ │ -1233 if (vMask.GetNumEdgeWeights() > 0) { │ │ │ │ │ -1234 _I_n_d_e_x * vEdgeValues = vEdgeBuffer; │ │ │ │ │ -1235 fvarChannel.getVertexEdgeValues(vert, vEdgeValues); │ │ │ │ │ -1236 │ │ │ │ │ -1237 for (int i = 0; i < vEdges.size(); ++i) { │ │ │ │ │ -1238 dst[vValue].AddWithWeight(src[vEdgeValues[i]], eWeights[i]); │ │ │ │ │ -1239 } │ │ │ │ │ -1240 } │ │ │ │ │ -1241 dst[vValue].AddWithWeight(src[vValue], vWeights[0]); │ │ │ │ │ -1242 } else { │ │ │ │ │ -1243 // │ │ │ │ │ -1244 // Sibling FVar values associated with a vertex will be either a corner or │ │ │ │ │ -a crease: │ │ │ │ │ -1245 // │ │ │ │ │ -1246 for (int i = 0; i < vValues.size(); ++i) { │ │ │ │ │ -1247 _V_t_r_:_:_I_n_d_e_x vValue = vValues[i]; │ │ │ │ │ -1248 │ │ │ │ │ -1249 dst[vValue].Clear(); │ │ │ │ │ -1250 if (fvarChannel.getValueTag(vValue).isCorner()) { │ │ │ │ │ -1251 dst[vValue].AddWithWeight(src[vValue], 1.0f); │ │ │ │ │ -1252 } else { │ │ │ │ │ -1253 _I_n_d_e_x vEndValues[2]; │ │ │ │ │ -1254 fvarChannel.getVertexCreaseEndValues(vert, i, vEndValues); │ │ │ │ │ -1255 │ │ │ │ │ -1256 dst[vValue].AddWithWeight(src[vEndValues[0]], 1.0f/6.0f); │ │ │ │ │ -1257 dst[vValue].AddWithWeight(src[vEndValues[1]], 1.0f/6.0f); │ │ │ │ │ -1258 dst[vValue].AddWithWeight(src[vValue], 2.0f/3.0f); │ │ │ │ │ -1259 } │ │ │ │ │ -1260 } │ │ │ │ │ -1261 } │ │ │ │ │ -1262 } │ │ │ │ │ -1263} │ │ │ │ │ -1264 │ │ │ │ │ -_1_2_6_5class _P_r_i_m_v_a_r_R_e_f_i_n_e_r : public _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l { │ │ │ │ │ -1266public: │ │ │ │ │ -_1_2_6_7 _P_r_i_m_v_a_r_R_e_f_i_n_e_r(_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r const & refiner) │ │ │ │ │ -1268 : _P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l(refiner) { } │ │ │ │ │ -1269}; │ │ │ │ │ -1270 │ │ │ │ │ -1271} // end namespace Far │ │ │ │ │ -1272 │ │ │ │ │ -1273} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -1274using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -1275} // end namespace OpenSubdiv │ │ │ │ │ -1276 │ │ │ │ │ -1277#endif /* OPENSUBDIV3_FAR_PRIMVAR_REFINER_H */ │ │ │ │ │ +234 │ │ │ │ │ +235#endif /* OPENSUBDIV3_FAR_PATCH_TABLE_FACTORY_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_o_c_a_l_I_n_d_e_x │ │ │ │ │ -Vtr::LocalIndex LocalIndex │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_E_r_r_o_r │ │ │ │ │ -void Error(ErrorType err, const char *format,...) │ │ │ │ │ -Sends an OSD error with a message (internal use only) │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ Vtr::ConstIndexArray ConstIndexArray │ │ │ │ │ DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_L_o_c_a_l_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ -Vtr::ConstLocalIndexArray ConstLocalIndexArray │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_F_A_R___R_U_N_T_I_M_E___E_R_R_O_R │ │ │ │ │ -@ FAR_RUNTIME_ERROR │ │ │ │ │ -Issue a generic runtime error, but continue execution. │ │ │ │ │ -DDeeffiinniittiioonn _e_r_r_o_r_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ -Vtr::Index Index │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_I_n_d_e_x │ │ │ │ │ -int Index │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_I_n_d_e_x_I_s_V_a_l_i_d │ │ │ │ │ -bool IndexIsValid(Index index) │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___B_I_L_I_N_E_A_R │ │ │ │ │ -@ SCHEME_BILINEAR │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___C_A_T_M_A_R_K │ │ │ │ │ -@ SCHEME_CATMARK │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_C_H_E_M_E___L_O_O_P │ │ │ │ │ -@ SCHEME_LOOP │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ -Applies refinement operations to generic primvar data. │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_L_i_m_i_t │ │ │ │ │ -void Limit(T const &src, U &dstPos) const │ │ │ │ │ -Apply limit weights to a primvar buffer. │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_1_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ -PrimvarRefinerReal(TopologyRefiner const &refiner) │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_5_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_L_i_m_i_t │ │ │ │ │ -void Limit(T const &src, U &dstPos, U1 &dstTan1, U2 &dstTan2) const │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_U_n_i_f_o_r_m │ │ │ │ │ -void InterpolateFaceUniform(int level, T const &src, U &dst) const │ │ │ │ │ -Refine uniform (per-face) primvar data between levels. │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_9_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_G_e_t_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ -TopologyRefiner const & GetTopologyRefiner() const │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e_V_a_r_y_i_n_g │ │ │ │ │ -void InterpolateVarying(int level, T const &src, U &dst) const │ │ │ │ │ -Apply only varying interpolation weights to a primvar buffer for a single level │ │ │ │ │ -of refinement. │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_4_1_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e │ │ │ │ │ -void Interpolate(int level, T const &src, U &dst) const │ │ │ │ │ -Apply vertex interpolation weights to a primvar buffer for a single level of │ │ │ │ │ -refinement. │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_2_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_I_n_t_e_r_p_o_l_a_t_e_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -void InterpolateFaceVarying(int level, T const &src, U &dst, int channel=0) │ │ │ │ │ -const │ │ │ │ │ -Apply face-varying interpolation weights to a primvar buffer associated with a │ │ │ │ │ -particular face-varyin... │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_2_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_~_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l │ │ │ │ │ -~PrimvarRefinerReal() │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_6_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_R_e_a_l_:_:_L_i_m_i_t_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -void LimitFaceVarying(T const &src, U &dst, int channel=0) const │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_3_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_1_2_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r_:_:_P_r_i_m_v_a_r_R_e_f_i_n_e_r │ │ │ │ │ -PrimvarRefiner(TopologyRefiner const &refiner) │ │ │ │ │ -DDeeffiinniittiioonn _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h_:_1_2_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +Container for arrays of parametric patches. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y │ │ │ │ │ +Factory for constructing a PatchTable from a TopologyRefiner. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_T_a_g_V_e_c_t_o_r │ │ │ │ │ +std::vector< PatchFaceTag > PatchTagVector │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_C_r_e_a_t_e │ │ │ │ │ +static PatchTable * Create(TopologyRefiner const &refiner, Options │ │ │ │ │ +options=Options(), ConstIndexArray selectedFaces=ConstIndexArray()) │ │ │ │ │ +Instantiates a PatchTable from a client-provided TopologyRefiner. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Public options for the PatchTable factory. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_4_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_T_a_b_l_e_s │ │ │ │ │ +unsigned int generateVaryingTables │ │ │ │ │ +Generate varying patch tables. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_L_e_g_a_c_y_S_h_a_r_p_C_o_r_n_e_r_P_a_t_c_h_e_s │ │ │ │ │ +unsigned int generateLegacySharpCornerPatches │ │ │ │ │ +Generate sharp regular patches at smooth corners (legacy) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_s_h_a_r_e_E_n_d_C_a_p_P_a_t_c_h_P_o_i_n_t_s │ │ │ │ │ +unsigned int shareEndCapPatchPoints │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_G_e_t_R_e_f_i_n_e_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ +TopologyRefiner::AdaptiveOptions GetRefineAdaptiveOptions() const │ │ │ │ │ +Determine adaptive refinement options to match assigned patch options. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_m_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l │ │ │ │ │ +unsigned int maxIsolationLevel │ │ │ │ │ +Cap adaptive feature isolation to the given level (max. 10) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_G_e_t_E_n_d_C_a_p_T_y_p_e │ │ │ │ │ +EndCapType GetEndCapType() const │ │ │ │ │ +Get endcap basis type. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_F_V_a_r_L_e_g_a_c_y_L_i_n_e_a_r_P_a_t_c_h_e_s │ │ │ │ │ +unsigned int generateFVarLegacyLinearPatches │ │ │ │ │ +Generate all linear face-varying patches (legacy) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_S_e_t_P_a_t_c_h_P_r_e_c_i_s_i_o_n │ │ │ │ │ +void SetPatchPrecision() │ │ │ │ │ +Set precision of vertex patches. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_f_v_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e │ │ │ │ │ +unsigned int fvarPatchPrecisionDouble │ │ │ │ │ +Generate double-precision stencils for face-varying patches. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_S_e_t_M_a_x_I_s_o_l_a_t_i_o_n_L_e_v_e_l │ │ │ │ │ +void SetMaxIsolationLevel(unsigned int level) │ │ │ │ │ +Set maximum isolation level. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_e_n_d_C_a_p_T_y_p_e │ │ │ │ │ +unsigned int endCapType │ │ │ │ │ +EndCapType. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_f_v_a_r_C_h_a_n_n_e_l_I_n_d_i_c_e_s │ │ │ │ │ +int const * fvarChannelIndices │ │ │ │ │ +List containing the indices of the channels selected for the factory. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h │ │ │ │ │ +unsigned int useSingleCreasePatch │ │ │ │ │ +Use single crease patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h │ │ │ │ │ +unsigned int useInfSharpPatch │ │ │ │ │ +Use infinitely-sharp patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_S_e_t_E_n_d_C_a_p_T_y_p_e │ │ │ │ │ +void SetEndCapType(EndCapType e) │ │ │ │ │ +Set endcap basis type. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_V_a_r_y_i_n_g_L_o_c_a_l_P_o_i_n_t_s │ │ │ │ │ +unsigned int generateVaryingLocalPoints │ │ │ │ │ +Generate local points with varying patches. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_i_n_c_l_u_d_e_F_V_a_r_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s │ │ │ │ │ +unsigned int includeFVarBaseLevelIndices │ │ │ │ │ +Include base level in face-varying patch point indices (Uniform mode only) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_A_l_l_L_e_v_e_l_s │ │ │ │ │ +unsigned int generateAllLevels │ │ │ │ │ +Generate levels from 'firstLevel' to 'maxLevel' (Uniform mode only) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_p_a_t_c_h_P_r_e_c_i_s_i_o_n_D_o_u_b_l_e │ │ │ │ │ +unsigned int patchPrecisionDouble │ │ │ │ │ +Generate double-precision stencils for vertex patches. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_g_e_n_e_r_a_t_e_F_V_a_r_T_a_b_l_e_s │ │ │ │ │ +unsigned int generateFVarTables │ │ │ │ │ +Generate face-varying patch tables. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_2_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_i_n_c_l_u_d_e_B_a_s_e_L_e_v_e_l_I_n_d_i_c_e_s │ │ │ │ │ +unsigned int includeBaseLevelIndices │ │ │ │ │ +Include base level in patch point indices (Uniform mode only) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_S_e_t_F_V_a_r_P_a_t_c_h_P_r_e_c_i_s_i_o_n │ │ │ │ │ +void SetFVarPatchPrecision() │ │ │ │ │ +Set precision of face-varying patches. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_n_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +int numFVarChannels │ │ │ │ │ +Number of channel indices and interpolation modes passed. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_t_r_i_a_n_g_u_l_a_t_e_Q_u_a_d_s │ │ │ │ │ +unsigned int triangulateQuads │ │ │ │ │ +Triangulate 'QUADS' primitives (Uniform mode only) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_1_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_E_n_d_C_a_p_T_y_p_e │ │ │ │ │ +EndCapType │ │ │ │ │ +Choice for approximating irregular patches (end-caps) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_E_N_D_C_A_P___L_E_G_A_C_Y___G_R_E_G_O_R_Y │ │ │ │ │ +@ ENDCAP_LEGACY_GREGORY │ │ │ │ │ +legacy option for 2.x style Gregory patches (Catmark only) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_E_N_D_C_A_P___G_R_E_G_O_R_Y___B_A_S_I_S │ │ │ │ │ +@ ENDCAP_GREGORY_BASIS │ │ │ │ │ +use Gregory patches (highest quality, recommended default) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_E_N_D_C_A_P___N_O_N_E │ │ │ │ │ +@ ENDCAP_NONE │ │ │ │ │ +unspecified │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_E_N_D_C_A_P___B_I_L_I_N_E_A_R___B_A_S_I_S │ │ │ │ │ +@ ENDCAP_BILINEAR_BASIS │ │ │ │ │ +use linear patches (simple quads or tris) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_E_N_D_C_A_P___B_S_P_L_I_N_E___B_A_S_I_S │ │ │ │ │ +@ ENDCAP_BSPLINE_BASIS │ │ │ │ │ +use BSpline-like patches (same patch type as regular) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_O_p_t_i_o_n_s_:_:_O_p_t_i_o_n_s │ │ │ │ │ +Options(unsigned int maxIsolation=10) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g │ │ │ │ │ +Obsolete internal struct not intended for public use – due to be deprecated. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___i_s_S_i_n_g_l_e_C_r_e_a_s_e │ │ │ │ │ +unsigned int _isSingleCrease │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___i_s_R_e_g_u_l_a_r │ │ │ │ │ +unsigned int _isRegular │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___b_o_u_n_d_a_r_y_I_n_d_e_x │ │ │ │ │ +unsigned int _boundaryIndex │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +_a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_V_e_r_t_e_x_M_a_s_k │ │ │ │ │ +void assignBoundaryPropertiesFromVertexMask(int boundaryVertexMask) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___t_r_a_n_s_i_t_i_o_n_M_a_s_k │ │ │ │ │ +unsigned int _transitionMask │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___h_a_s_B_o_u_n_d_a_r_y_E_d_g_e │ │ │ │ │ +unsigned int _hasBoundaryEdge │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_2_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___b_o_u_n_d_a_r_y_M_a_s_k │ │ │ │ │ +unsigned int _boundaryMask │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_:___h_a_s_P_a_t_c_h │ │ │ │ │ +unsigned int _hasPatch │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +_a_s_s_i_g_n_T_r_a_n_s_i_t_i_o_n_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k │ │ │ │ │ +void assignTransitionPropertiesFromEdgeMask(int boundaryVertexMask) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_:_c_l_e_a_r │ │ │ │ │ +void clear() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +_a_s_s_i_g_n_B_o_u_n_d_a_r_y_P_r_o_p_e_r_t_i_e_s_F_r_o_m_E_d_g_e_M_a_s_k │ │ │ │ │ +void assignBoundaryPropertiesFromEdgeMask(int boundaryEdgeMask) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_:_:_P_a_t_c_h_F_a_c_e_T_a_g_:_: │ │ │ │ │ +___b_o_u_n_d_a_r_y_C_o_u_n_t │ │ │ │ │ +unsigned int _boundaryCount │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h_:_1_9_9 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ Stores topology data for a specified set of refinement options. │ │ │ │ │ DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e │ │ │ │ │ -Rule │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E │ │ │ │ │ -@ RULE_CREASE │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e │ │ │ │ │ -Scheme is a class template which provides all implementation for the │ │ │ │ │ -subdivision schemes supported by... │ │ │ │ │ -DDeeffiinniittiioonn _s_c_h_e_m_e_._h_:_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ +Adaptive refinement options. │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_u_s_e_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h │ │ │ │ │ +unsigned int useSingleCreasePatch │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_u_s_e_I_n_f_S_h_a_r_p_P_a_t_c_h │ │ │ │ │ +unsigned int useInfSharpPatch │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s_:_: │ │ │ │ │ +_c_o_n_s_i_d_e_r_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +unsigned int considerFVarChannels │ │ │ │ │ +DDeeffiinniittiioonn _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h_:_1_8_0 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_:_:_s_i_z_e │ │ │ │ │ -size_type size() const │ │ │ │ │ -DDeeffiinniittiioonn _a_r_r_a_y_._h_:_7_2 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_r_i_m_v_a_r_R_e_f_i_n_e_r_._h │ │ │ │ │ + * _p_a_t_c_h_T_a_b_l_e_F_a_c_t_o_r_y_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00731.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchTable.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/patchMap.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,33 +90,29 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
patchTable.h File Reference
│ │ │ │ +
patchMap.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ -#include "../far/patchParam.h"
│ │ │ │ -#include "../far/stencilTable.h"
│ │ │ │ -#include "../sdc/options.h"
│ │ │ │ -#include <vector>
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │ +#include <cassert>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PatchTable
 Container for arrays of parametric patches. More...
class  PatchMap
 An quadtree-based map connecting coarse faces to their sub-patches. More...
 
class  PatchTable::PatchHandle
 Handle that can be used as unique patch identifier within PatchTable. More...
struct  PatchMap::QuadNode::Child
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -125,13 +121,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,32 +1,28 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -patchTable.h File Reference │ │ │ │ │ +patchMap.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_P_a_r_a_m_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_s_t_e_n_c_i_l_T_a_b_l_e_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -  Container for arrays of parametric patches. _M_o_r_e_._._. │ │ │ │ │ + class   _P_a_t_c_h_M_a_p │ │ │ │ │ +  An quadtree-based map connecting coarse faces to their sub-patches. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e │ │ │ │ │ -  Handle that can be used as unique patch identifier within _P_a_t_c_h_T_a_b_l_e. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ +struct   _P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ + * _p_a_t_c_h_M_a_p_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00731.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,4 @@ │ │ │ │ │ var a00731 = [ │ │ │ │ │ - ["PatchTable", "a00993.html", "a00993"], │ │ │ │ │ - ["PatchHandle", "a00997.html", "a00997"] │ │ │ │ │ + ["PatchMap", "a00977.html", "a00977"], │ │ │ │ │ + ["Child", "a00985.html", "a00985"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00731_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchTable.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/patchMap.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
patchTable.h
│ │ │ │ +
patchMap.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,798 +119,222 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_PATCH_TABLE_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_PATCH_MAP_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_PATCH_MAP_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../far/patchDescriptor.h"
│ │ │ │ -
31#include "../far/patchParam.h"
│ │ │ │ -
32#include "../far/stencilTable.h"
│ │ │ │ +
30#include "../far/patchTable.h"
│ │ │ │ +
31
│ │ │ │ +
32#include <cassert>
│ │ │ │
33
│ │ │ │ -
34#include "../sdc/options.h"
│ │ │ │ -
35
│ │ │ │ -
36#include <vector>
│ │ │ │ -
37
│ │ │ │ -
38namespace OpenSubdiv {
│ │ │ │ -
39namespace OPENSUBDIV_VERSION {
│ │ │ │ -
40
│ │ │ │ -
41namespace Far {
│ │ │ │ -
42
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
56
│ │ │ │ -
57public:
│ │ │ │ -
58
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
61 // XXXX manuelk members will eventually be made private
│ │ │ │ -
62 public:
│ │ │ │ -
63
│ │ │ │ -
64 friend class PatchTable;
│ │ │ │ -
65 friend class PatchMap;
│ │ │ │ -
66
│ │ │ │ -
67 Index arrayIndex, // Array index of the patch
│ │ │ │ -
68 patchIndex, // Absolute Index of the patch
│ │ │ │ -
69 vertIndex; // Relative offset to the first CV of the patch in array
│ │ │ │ -
70 };
│ │ │ │ -
│ │ │ │ -
71
│ │ │ │ -
72public:
│ │ │ │ -
73
│ │ │ │ -
75 PatchTable(PatchTable const & src);
│ │ │ │ -
76
│ │ │ │ - │ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Far {
│ │ │ │ +
38
│ │ │ │ +
│ │ │ │ +
49class PatchMap {
│ │ │ │ +
50public:
│ │ │ │ +
51
│ │ │ │ + │ │ │ │ +
53
│ │ │ │ +
58 PatchMap( PatchTable const & patchTable );
│ │ │ │ +
59
│ │ │ │ +
74 Handle const * FindPatch( int patchFaceId, double u, double v ) const;
│ │ │ │ +
75
│ │ │ │ +
76private:
│ │ │ │ +
77 void initializeHandles(PatchTable const & patchTable);
│ │ │ │ +
78 void initializeQuadtree(PatchTable const & patchTable);
│ │ │ │
79
│ │ │ │ -
81 bool IsFeatureAdaptive() const;
│ │ │ │ -
82
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
85 return (int)_patchVerts.size();
│ │ │ │ -
86 }
│ │ │ │ +
80private:
│ │ │ │ +
81 // Quadtree node with 4 children, tree is just a vector of nodes
│ │ │ │ +
82 struct QuadNode {
│ │ │ │ +
83 QuadNode() { std::memset(this, 0, sizeof(QuadNode)); }
│ │ │ │ +
84
│ │ │ │ +
│ │ │ │ +
85 struct Child {
│ │ │ │ +
86 unsigned int isSet : 1; // true if the child has been set
│ │ │ │ +
87 unsigned int isLeaf : 1; // true if the child is a QuadNode
│ │ │ │ +
88 unsigned int index : 30; // child index (either QuadNode or Handle)
│ │ │ │ +
89 };
│ │ │ │
│ │ │ │ -
87
│ │ │ │ -
89 int GetNumPatchesTotal() const;
│ │ │ │
90
│ │ │ │ -
92 int GetMaxValence() const { return _maxValence; }
│ │ │ │ +
91 // sets all the children to point to the patch of given index
│ │ │ │ +
92 void SetChildren(int index);
│ │ │ │
93
│ │ │ │ -
95 int GetNumPtexFaces() const { return _numPtexFaces; }
│ │ │ │ +
94 // sets the child in "quadrant" to point to the node or patch of the given index
│ │ │ │ +
95 void SetChild(int quadrant, int index, bool isLeaf);
│ │ │ │
96
│ │ │ │ -
97
│ │ │ │ -
99
│ │ │ │ -
105
│ │ │ │ - │ │ │ │ -
108
│ │ │ │ - │ │ │ │ -
111
│ │ │ │ -
113 PatchParam GetPatchParam(PatchHandle const & handle) const;
│ │ │ │ -
114
│ │ │ │ -
116 ConstIndexArray GetPatchVertices(int array, int patch) const;
│ │ │ │ -
117
│ │ │ │ -
119 PatchParam GetPatchParam(int array, int patch) const;
│ │ │ │ -
121
│ │ │ │ -
122
│ │ │ │ -
124
│ │ │ │ -
130
│ │ │ │ -
132 int GetNumPatchArrays() const;
│ │ │ │ -
133
│ │ │ │ -
135 int GetNumPatches(int array) const;
│ │ │ │ -
136
│ │ │ │ -
138 int GetNumControlVertices(int array) const;
│ │ │ │ -
139
│ │ │ │ - │ │ │ │ -
142
│ │ │ │ - │ │ │ │ -
145
│ │ │ │ -
147 ConstPatchParamArray const GetPatchParams(int array) const;
│ │ │ │ -
149
│ │ │ │ +
97 Child children[4];
│ │ │ │ +
98 };
│ │ │ │ +
99 typedef std::vector<QuadNode> QuadTree;
│ │ │ │ +
100
│ │ │ │ +
101 // Internal methods supporting quadtree construction and queries
│ │ │ │ +
102 void assignRootNode(QuadNode * node, int index);
│ │ │ │ +
103 QuadNode * assignLeafOrChildNode(QuadNode * node, bool isLeaf, int quad, int index);
│ │ │ │ +
104
│ │ │ │ +
105 template <class T>
│ │ │ │ +
106 static int transformUVToQuadQuadrant(T const & median, T & u, T & v);
│ │ │ │ +
107 template <class T>
│ │ │ │ +
108 static int transformUVToTriQuadrant(T const & median, T & u, T & v, bool & rotated);
│ │ │ │ +
109
│ │ │ │ +
110private:
│ │ │ │ +
111 bool _patchesAreTriangular; // tri and quad assembly and search requirements differ
│ │ │ │ +
112
│ │ │ │ +
113 int _minPatchFace; // minimum patch face index supported by the map
│ │ │ │ +
114 int _maxPatchFace; // maximum patch face index supported by the map
│ │ │ │ +
115 int _maxDepth; // maximum depth of a patch in the tree
│ │ │ │ +
116
│ │ │ │ +
117 std::vector<Handle> _handles; // all the patches in the PatchTable
│ │ │ │ +
118 std::vector<QuadNode> _quadtree; // quadtree nodes
│ │ │ │ +
119};
│ │ │ │ +
│ │ │ │ +
120
│ │ │ │ +
121//
│ │ │ │ +
122// Given a median value for both U and V, these methods transform a (u,v) pair
│ │ │ │ +
123// into the quadrant that contains them and returns the quadrant index.
│ │ │ │ +
124//
│ │ │ │ +
125// Quadrant indexing for tri and quad patches -- consistent with PatchParam's
│ │ │ │ +
126// usage of UV bits:
│ │ │ │ +
127//
│ │ │ │ +
128// (0,1) o-----o-----o (1,1) (0,1) o (1,0) o-----o-----o (0,0)
│ │ │ │ +
129// | | | |\ \ 1 |\ 0 |
│ │ │ │ +
130// | 2 | 3 | | \ \ | \ |
│ │ │ │ +
131// | | | | 2 \ \| 3 \|
│ │ │ │ +
132// o-----o-----o o-----o o-----o
│ │ │ │ +
133// | | | |\ 3 |\ \ 2 |
│ │ │ │ +
134// | 0 | 1 | | \ | \ \ |
│ │ │ │ +
135// | | | | 0 \| 1 \ \|
│ │ │ │ +
136// (0,0) o-----o-----o (1,0) (0,0) o-----o-----o (1,0) o (0,1)
│ │ │ │ +
137//
│ │ │ │ +
138// The triangular case also takes and returns/affects the rotation of the
│ │ │ │ +
139// quadrant being searched and identified (quadrant 3 imparts a rotation).
│ │ │ │ +
140//
│ │ │ │ +
141template <class T>
│ │ │ │ +
142inline int
│ │ │ │ +
143PatchMap::transformUVToQuadQuadrant(T const & median, T & u, T & v) {
│ │ │ │ +
144
│ │ │ │ +
145 int uHalf = (u >= median);
│ │ │ │ +
146 if (uHalf) u -= median;
│ │ │ │ +
147
│ │ │ │ +
148 int vHalf = (v >= median);
│ │ │ │ +
149 if (vHalf) v -= median;
│ │ │ │
150
│ │ │ │ -
152
│ │ │ │ -
159
│ │ │ │ -
161 int GetNumLocalPoints() const;
│ │ │ │ -
162
│ │ │ │ - │ │ │ │ -
165
│ │ │ │ -
167 template <typename REAL>
│ │ │ │ - │ │ │ │ -
169
│ │ │ │ -
172 template <typename REAL> bool LocalPointStencilPrecisionMatchesType() const;
│ │ │ │ -
173
│ │ │ │ -
186 template <class T> void
│ │ │ │ -
187 ComputeLocalPointValues(T const *src, T *dst) const;
│ │ │ │ -
188
│ │ │ │ -
189
│ │ │ │ - │ │ │ │ -
192
│ │ │ │ - │ │ │ │ -
195
│ │ │ │ -
197 template <typename REAL>
│ │ │ │ - │ │ │ │ -
199
│ │ │ │ -
202 template <typename REAL> bool LocalPointVaryingStencilPrecisionMatchesType() const;
│ │ │ │ +
151 return (vHalf << 1) | uHalf;
│ │ │ │ +
152}
│ │ │ │ +
153
│ │ │ │ +
154template <class T>
│ │ │ │ +
155int inline
│ │ │ │ +
156PatchMap::transformUVToTriQuadrant(T const & median, T & u, T & v, bool & rotated) {
│ │ │ │ +
157
│ │ │ │ +
158 if (!rotated) {
│ │ │ │ +
159 if (u >= median) {
│ │ │ │ +
160 u -= median;
│ │ │ │ +
161 return 1;
│ │ │ │ +
162 }
│ │ │ │ +
163 if (v >= median) {
│ │ │ │ +
164 v -= median;
│ │ │ │ +
165 return 2;
│ │ │ │ +
166 }
│ │ │ │ +
167 if ((u + v) >= median) {
│ │ │ │ +
168 rotated = true;
│ │ │ │ +
169 return 3;
│ │ │ │ +
170 }
│ │ │ │ +
171 return 0;
│ │ │ │ +
172 } else {
│ │ │ │ +
173 if (u < median) {
│ │ │ │ +
174 v -= median;
│ │ │ │ +
175 return 1;
│ │ │ │ +
176 }
│ │ │ │ +
177 if (v < median) {
│ │ │ │ +
178 u -= median;
│ │ │ │ +
179 return 2;
│ │ │ │ +
180 }
│ │ │ │ +
181 u -= median;
│ │ │ │ +
182 v -= median;
│ │ │ │ +
183 if ((u + v) < median) {
│ │ │ │ +
184 rotated = false;
│ │ │ │ +
185 return 3;
│ │ │ │ +
186 }
│ │ │ │ +
187 return 0;
│ │ │ │ +
188 }
│ │ │ │ +
189}
│ │ │ │ +
190
│ │ │ │ +
192inline PatchMap::Handle const *
│ │ │ │ +
│ │ │ │ +
193PatchMap::FindPatch( int faceid, double u, double v ) const {
│ │ │ │ +
194
│ │ │ │ +
195 //
│ │ │ │ +
196 // Reject patch faces not supported by this map, or those corresponding
│ │ │ │ +
197 // to holes or otherwise unassigned (the root node for a patch will
│ │ │ │ +
198 // have all or no quadrants set):
│ │ │ │ +
199 //
│ │ │ │ +
200 if ((faceid < _minPatchFace) || (faceid > _maxPatchFace)) return 0;
│ │ │ │ +
201
│ │ │ │ +
202 QuadNode const * node = &_quadtree[faceid - _minPatchFace];
│ │ │ │
203
│ │ │ │ -
216 template <class T> void
│ │ │ │ -
217 ComputeLocalPointValuesVarying(T const *src, T *dst) const;
│ │ │ │ -
218
│ │ │ │ +
204 if (!node->children[0].isSet) return 0;
│ │ │ │ +
205
│ │ │ │ +
206 //
│ │ │ │ +
207 // Search the tree for the sub-patch containing the given (u,v)
│ │ │ │ +
208 //
│ │ │ │ +
209 assert( (u>=0.0) && (u<=1.0) && (v>=0.0) && (v<=1.0) );
│ │ │ │ +
210
│ │ │ │ +
211 double median = 0.5;
│ │ │ │ +
212 bool triRotated = false;
│ │ │ │ +
213
│ │ │ │ +
214 for (int depth = 0; depth <= _maxDepth; ++depth, median *= 0.5) {
│ │ │ │ +
215
│ │ │ │ +
216 int quadrant = _patchesAreTriangular
│ │ │ │ +
217 ? transformUVToTriQuadrant(median, u, v, triRotated)
│ │ │ │ +
218 : transformUVToQuadQuadrant(median, u, v);
│ │ │ │
219
│ │ │ │ -
221 int GetNumLocalPointsFaceVarying(int channel = 0) const;
│ │ │ │ +
220 // holes should have been rejected at the root node of the face
│ │ │ │ +
221 assert(node->children[quadrant].isSet);
│ │ │ │
222
│ │ │ │ -
224 StencilTable const *GetLocalPointFaceVaryingStencilTable(int channel = 0) const;
│ │ │ │ -
225
│ │ │ │ -
227 template <typename REAL>
│ │ │ │ - │ │ │ │ -
229
│ │ │ │ -
232 template <typename REAL> bool LocalPointFaceVaryingStencilPrecisionMatchesType() const;
│ │ │ │ -
233
│ │ │ │ -
248 template <class T> void
│ │ │ │ -
249 ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel = 0) const;
│ │ │ │ -
251
│ │ │ │ -
252
│ │ │ │ -
254
│ │ │ │ -
255
│ │ │ │ - │ │ │ │ -
260
│ │ │ │ - │ │ │ │ -
263
│ │ │ │ -
264 typedef std::vector<Index> VertexValenceTable;
│ │ │ │ -
265
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
268 return _vertexValenceTable;
│ │ │ │ -
269 }
│ │ │ │ -
│ │ │ │ -
271
│ │ │ │ -
272
│ │ │ │ -
274
│ │ │ │ -
280
│ │ │ │ - │ │ │ │ -
284
│ │ │ │ -
287 float GetSingleCreasePatchSharpnessValue(int array, int patch) const;
│ │ │ │ -
289
│ │ │ │ -
290
│ │ │ │ -
292
│ │ │ │ -
298
│ │ │ │ - │ │ │ │ -
301
│ │ │ │ - │ │ │ │ -
304
│ │ │ │ -
306 ConstIndexArray GetPatchVaryingVertices(int array, int patch) const;
│ │ │ │ -
307
│ │ │ │ - │ │ │ │ -
310
│ │ │ │ - │ │ │ │ -
314
│ │ │ │ -
315
│ │ │ │ -
317
│ │ │ │ -
323
│ │ │ │ - │ │ │ │ -
326
│ │ │ │ - │ │ │ │ -
329
│ │ │ │ - │ │ │ │ -
332
│ │ │ │ - │ │ │ │ -
335
│ │ │ │ -
337 ConstIndexArray GetPatchFVarValues(PatchHandle const & handle, int channel = 0) const;
│ │ │ │ -
338
│ │ │ │ -
340 ConstIndexArray GetPatchFVarValues(int array, int patch, int channel = 0) const;
│ │ │ │ -
341
│ │ │ │ -
343 ConstIndexArray GetPatchArrayFVarValues(int array, int channel = 0) const;
│ │ │ │ -
344
│ │ │ │ -
346 ConstIndexArray GetFVarValues(int channel = 0) const;
│ │ │ │ -
347
│ │ │ │ -
349 int GetFVarValueStride(int channel = 0) const;
│ │ │ │ -
350
│ │ │ │ -
352 PatchParam GetPatchFVarPatchParam(PatchHandle const & handle, int channel = 0) const;
│ │ │ │ -
353
│ │ │ │ -
355 PatchParam GetPatchFVarPatchParam(int array, int patch, int channel = 0) const;
│ │ │ │ -
356
│ │ │ │ -
358 ConstPatchParamArray GetPatchArrayFVarPatchParams(int array, int channel = 0) const;
│ │ │ │ -
359
│ │ │ │ - │ │ │ │ -
362
│ │ │ │ - │ │ │ │ -
366
│ │ │ │ -
367
│ │ │ │ -
369
│ │ │ │ -
374
│ │ │ │ -
375 typedef std::vector<Index> PatchVertsTable;
│ │ │ │ -
376
│ │ │ │ -
378 PatchVertsTable const & GetPatchControlVerticesTable() const { return _patchVerts; }
│ │ │ │ -
379
│ │ │ │ -
381 PatchParamTable const & GetPatchParamTable() const { return _paramTable; }
│ │ │ │ -
382
│ │ │ │ -
384 std::vector<Index> const &GetSharpnessIndexTable() const { return _sharpnessIndices; }
│ │ │ │ -
385
│ │ │ │ -
387 std::vector<float> const &GetSharpnessValues() const { return _sharpnessValues; }
│ │ │ │ -
388
│ │ │ │ -
389 typedef std::vector<unsigned int> QuadOffsetsTable;
│ │ │ │ -
390
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
393 return _quadOffsetsTable;
│ │ │ │ -
394 }
│ │ │ │ -
│ │ │ │ -
396
│ │ │ │ -
398 void print() const;
│ │ │ │ -
399
│ │ │ │ -
400public:
│ │ │ │ -
401
│ │ │ │ -
403
│ │ │ │ -
405
│ │ │ │ -
428 template <typename REAL>
│ │ │ │ -
429 void EvaluateBasis(PatchHandle const & handle, REAL u, REAL v,
│ │ │ │ -
430 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0,
│ │ │ │ -
431 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const;
│ │ │ │ -
432
│ │ │ │ -
435 void EvaluateBasis(PatchHandle const & handle, float u, float v,
│ │ │ │ -
436 float wP[], float wDu[] = 0, float wDv[] = 0,
│ │ │ │ -
437 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const;
│ │ │ │ -
438
│ │ │ │ -
441 void EvaluateBasis(PatchHandle const & handle, double u, double v,
│ │ │ │ -
442 double wP[], double wDu[] = 0, double wDv[] = 0,
│ │ │ │ -
443 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const;
│ │ │ │ -
444
│ │ │ │ -
467 template <typename REAL>
│ │ │ │ -
468 void EvaluateBasisVarying(PatchHandle const & handle, REAL u, REAL v,
│ │ │ │ -
469 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0,
│ │ │ │ -
470 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const;
│ │ │ │ -
471
│ │ │ │ -
474 void EvaluateBasisVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ -
475 float wP[], float wDu[] = 0, float wDv[] = 0,
│ │ │ │ -
476 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const;
│ │ │ │ -
477
│ │ │ │ -
480 void EvaluateBasisVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ -
481 double wP[], double wDu[] = 0, double wDv[] = 0,
│ │ │ │ -
482 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const;
│ │ │ │ -
483
│ │ │ │ -
508 template <typename REAL>
│ │ │ │ -
509 void EvaluateBasisFaceVarying(PatchHandle const & handle, REAL u, REAL v,
│ │ │ │ -
510 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0,
│ │ │ │ -
511 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0,
│ │ │ │ -
512 int channel = 0) const;
│ │ │ │ -
513
│ │ │ │ -
516 void EvaluateBasisFaceVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ -
517 float wP[], float wDu[] = 0, float wDv[] = 0,
│ │ │ │ -
518 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0,
│ │ │ │ -
519 int channel = 0) const;
│ │ │ │ -
520
│ │ │ │ -
523 void EvaluateBasisFaceVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ -
524 double wP[], double wDu[] = 0, double wDv[] = 0,
│ │ │ │ -
525 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0,
│ │ │ │ -
526 int channel = 0) const;
│ │ │ │ -
528
│ │ │ │ -
529protected:
│ │ │ │ -
530
│ │ │ │ -
531 friend class PatchTableBuilder;
│ │ │ │ -
532
│ │ │ │ -
533 // Factory constructor
│ │ │ │ -
534 PatchTable(int maxvalence);
│ │ │ │ -
535
│ │ │ │ -
536 Index getPatchIndex(int array, int patch) const;
│ │ │ │ -
537
│ │ │ │ - │ │ │ │ -
539
│ │ │ │ - │ │ │ │ -
541 float * getSharpnessValues(Index arrayIndex);
│ │ │ │ -
542
│ │ │ │ -
543private:
│ │ │ │ -
544
│ │ │ │ -
545 //
│ │ │ │ -
546 // Patch arrays
│ │ │ │ -
547 //
│ │ │ │ -
548 struct PatchArray {
│ │ │ │ -
549 PatchArray(PatchDescriptor d, int np, Index v, Index p, Index qo) :
│ │ │ │ -
550 desc(d), numPatches(np), vertIndex(v),
│ │ │ │ -
551 patchIndex(p), quadOffsetIndex (qo) { }
│ │ │ │ -
552
│ │ │ │ -
553 void print() const;
│ │ │ │ -
554
│ │ │ │ -
555 PatchDescriptor desc; // type of patches in the array
│ │ │ │ -
556
│ │ │ │ -
557 int numPatches; // number of patches in the array
│ │ │ │ -
558
│ │ │ │ -
559 Index vertIndex, // index to the first control vertex
│ │ │ │ -
560 patchIndex, // absolute index of the first patch in the array
│ │ │ │ -
561 quadOffsetIndex; // index of the first quad offset entry
│ │ │ │ -
562 };
│ │ │ │ -
563
│ │ │ │ -
564 typedef std::vector<PatchArray> PatchArrayVector;
│ │ │ │ -
565
│ │ │ │ -
566 PatchArray & getPatchArray(Index arrayIndex);
│ │ │ │ -
567 PatchArray const & getPatchArray(Index arrayIndex) const;
│ │ │ │ -
568
│ │ │ │ -
569 void reservePatchArrays(int numPatchArrays);
│ │ │ │ -
570 void pushPatchArray(PatchDescriptor desc, int npatches,
│ │ │ │ -
571 Index * vidx, Index * pidx, Index * qoidx=0);
│ │ │ │ -
572
│ │ │ │ -
573 IndexArray getPatchArrayVertices(int arrayIndex);
│ │ │ │ -
574
│ │ │ │ -
575 Index findPatchArray(PatchDescriptor desc);
│ │ │ │ -
576
│ │ │ │ -
577
│ │ │ │ -
578 //
│ │ │ │ -
579 // Varying patch arrays
│ │ │ │ -
580 //
│ │ │ │ -
581 IndexArray getPatchArrayVaryingVertices(int arrayIndex);
│ │ │ │ -
582
│ │ │ │ -
583 void allocateVaryingVertices(
│ │ │ │ -
584 PatchDescriptor desc, int numPatches);
│ │ │ │ -
585 void populateVaryingVertices();
│ │ │ │ -
586
│ │ │ │ -
587 //
│ │ │ │ -
588 // Face-varying patch channels
│ │ │ │ -
589 //
│ │ │ │ -
590
│ │ │ │ -
591 //
│ │ │ │ -
592 // FVarPatchChannel
│ │ │ │ -
593 //
│ │ │ │ -
594 // Stores a record for each patch in the primitive :
│ │ │ │ -
595 //
│ │ │ │ -
596 // - Each patch in the PatchTable has a corresponding patch in each
│ │ │ │ -
597 // face-varying patch channel. Patch vertex indices are sorted in the same
│ │ │ │ -
598 // patch-type order as PatchTable::PTables. Face-varying data for a patch
│ │ │ │ -
599 // can therefore be quickly accessed by using the patch primitive ID as
│ │ │ │ -
600 // index into patchValueOffsets to locate the face-varying control vertex
│ │ │ │ -
601 // indices.
│ │ │ │ -
602 //
│ │ │ │ -
603 // - Face-varying channels can have a different interpolation modes
│ │ │ │ -
604 //
│ │ │ │ -
605 // - Unlike "vertex" patches, there are no transition masks required
│ │ │ │ -
606 // for face-varying patches.
│ │ │ │ -
607 //
│ │ │ │ -
608 // - Face-varying patches still require boundary edge masks.
│ │ │ │ -
609 //
│ │ │ │ -
610 // - currently most patches with sharp boundaries but smooth interiors have
│ │ │ │ -
611 // to be isolated to level 10 : we need a special type of bicubic patch
│ │ │ │ -
612 // similar to single-crease to resolve this condition without requiring
│ │ │ │ -
613 // isolation if possible
│ │ │ │ -
614 //
│ │ │ │ -
615 struct FVarPatchChannel {
│ │ │ │ - │ │ │ │ -
617
│ │ │ │ -
618 PatchDescriptor regDesc;
│ │ │ │ -
619 PatchDescriptor irregDesc;
│ │ │ │ -
620
│ │ │ │ -
621 int stride;
│ │ │ │ -
622
│ │ │ │ -
623 std::vector<Index> patchValues;
│ │ │ │ -
624 std::vector<PatchParam> patchParam;
│ │ │ │ -
625 };
│ │ │ │ -
626 typedef std::vector<FVarPatchChannel> FVarPatchChannelVector;
│ │ │ │ -
627
│ │ │ │ -
628 FVarPatchChannel & getFVarPatchChannel(int channel);
│ │ │ │ -
629 FVarPatchChannel const & getFVarPatchChannel(int channel) const;
│ │ │ │ -
630
│ │ │ │ -
631 void allocateFVarPatchChannels(int numChannels);
│ │ │ │ -
632 void allocateFVarPatchChannelValues(
│ │ │ │ -
633 PatchDescriptor regDesc, PatchDescriptor irregDesc,
│ │ │ │ -
634 int numPatches, int channel);
│ │ │ │ -
635
│ │ │ │ -
636 // deprecated
│ │ │ │ -
637 void setFVarPatchChannelLinearInterpolation(
│ │ │ │ -
638 Sdc::Options::FVarLinearInterpolation interpolation, int channel);
│ │ │ │ -
639
│ │ │ │ -
640 IndexArray getFVarValues(int channel);
│ │ │ │ -
641 ConstIndexArray getPatchFVarValues(int patch, int channel) const;
│ │ │ │ -
642
│ │ │ │ -
643 PatchParamArray getFVarPatchParams(int channel);
│ │ │ │ -
644 PatchParam getPatchFVarPatchParam(int patch, int channel) const;
│ │ │ │ -
645
│ │ │ │ -
646private:
│ │ │ │ -
647 //
│ │ │ │ -
648 // Simple private class to hold stencil table pointers of varying precision,
│ │ │ │ -
649 // where the discriminant of the precision is external.
│ │ │ │ -
650 //
│ │ │ │ -
651 // NOTE that this is a simple pointer container and NOT a smart pointer that
│ │ │ │ -
652 // manages the ownership of the object referred to by it.
│ │ │ │ -
653 //
│ │ │ │ -
654 class StencilTablePtr {
│ │ │ │ -
655 private:
│ │ │ │ -
656 typedef StencilTableReal<float> float_type;
│ │ │ │ -
657 typedef StencilTableReal<double> double_type;
│ │ │ │ -
658
│ │ │ │ -
659 union {
│ │ │ │ -
660 float_type * _fPtr;
│ │ │ │ -
661 double_type * _dPtr;
│ │ │ │ -
662 };
│ │ │ │ -
663
│ │ │ │ -
664 public:
│ │ │ │ -
665 StencilTablePtr() { _fPtr = 0; }
│ │ │ │ -
666 StencilTablePtr(float_type * ptr) { _fPtr = ptr; }
│ │ │ │ -
667 StencilTablePtr(double_type * ptr) { _dPtr = ptr; }
│ │ │ │ -
668
│ │ │ │ -
669 operator bool() const { return _fPtr != 0; }
│ │ │ │ -
670
│ │ │ │ -
671 void Set() { _fPtr = 0; }
│ │ │ │ -
672 void Set(float_type * ptr) { _fPtr = ptr; }
│ │ │ │ -
673 void Set(double_type * ptr) { _dPtr = ptr; }
│ │ │ │ -
674
│ │ │ │ -
675 template <typename REAL> StencilTableReal<REAL> * Get() const;
│ │ │ │ -
676 };
│ │ │ │ -
677
│ │ │ │ -
678private:
│ │ │ │ -
679
│ │ │ │ -
680 //
│ │ │ │ -
681 // Topology
│ │ │ │ -
682 //
│ │ │ │ -
683
│ │ │ │ -
684 int _maxValence, // highest vertex valence found in the mesh
│ │ │ │ -
685 _numPtexFaces; // total number of ptex faces
│ │ │ │ -
686
│ │ │ │ -
687 PatchArrayVector _patchArrays; // Vector of descriptors for arrays of patches
│ │ │ │ -
688
│ │ │ │ -
689 std::vector<Index> _patchVerts; // Indices of the control vertices of the patches
│ │ │ │ -
690
│ │ │ │ -
691 PatchParamTable _paramTable; // PatchParam bitfields (one per patch)
│ │ │ │ -
692
│ │ │ │ -
693 //
│ │ │ │ -
694 // Extraordinary vertex closed-form evaluation / endcap basis conversion
│ │ │ │ -
695 //
│ │ │ │ -
696 // XXXtakahito: these data will probably be replaced with mask coefficient or something
│ │ │ │ -
697 // SchemeWorker populates.
│ │ │ │ -
698 //
│ │ │ │ -
699 QuadOffsetsTable _quadOffsetsTable; // Quad offsets (for Gregory patches)
│ │ │ │ -
700 VertexValenceTable _vertexValenceTable; // Vertex valence table (for Gregory patches)
│ │ │ │ -
701
│ │ │ │ -
702 StencilTablePtr _localPointStencils; // local point conversion stencils
│ │ │ │ -
703 StencilTablePtr _localPointVaryingStencils; // local point varying stencils
│ │ │ │ -
704
│ │ │ │ -
705 //
│ │ │ │ -
706 // Varying data
│ │ │ │ -
707 //
│ │ │ │ -
708 PatchDescriptor _varyingDesc;
│ │ │ │ -
709
│ │ │ │ -
710 std::vector<Index> _varyingVerts;
│ │ │ │ -
711
│ │ │ │ -
712 //
│ │ │ │ -
713 // Face-varying data
│ │ │ │ -
714 //
│ │ │ │ -
715 FVarPatchChannelVector _fvarChannels;
│ │ │ │ -
716
│ │ │ │ -
717 std::vector<StencilTablePtr> _localPointFaceVaryingStencils;
│ │ │ │ -
718
│ │ │ │ -
719 //
│ │ │ │ -
720 // 'single-crease' patch sharpness tables
│ │ │ │ -
721 //
│ │ │ │ -
722 std::vector<Index> _sharpnessIndices; // Indices of single-crease sharpness (one per patch)
│ │ │ │ -
723 std::vector<float> _sharpnessValues; // Sharpness values.
│ │ │ │ -
724
│ │ │ │ -
725 //
│ │ │ │ -
726 // Construction history -- relevant to at least one public query:
│ │ │ │ -
727 //
│ │ │ │ -
728 unsigned int _isUniformLinear : 1;
│ │ │ │ -
729
│ │ │ │ -
730 //
│ │ │ │ -
731 // Precision -- only applies to local-point stencil tables
│ │ │ │ -
732 //
│ │ │ │ -
733 unsigned int _vertexPrecisionIsDouble : 1;
│ │ │ │ -
734 unsigned int _varyingPrecisionIsDouble : 1;
│ │ │ │ -
735 unsigned int _faceVaryingPrecisionIsDouble : 1;
│ │ │ │ -
736};
│ │ │ │ -
│ │ │ │ -
737
│ │ │ │ -
738
│ │ │ │ -
739//
│ │ │ │ -
740// Template specializations for float/double -- to be defined before used:
│ │ │ │ -
741//
│ │ │ │ -
742template <> inline StencilTableReal<float> *
│ │ │ │ -
743PatchTable::StencilTablePtr::Get<float>() const { return _fPtr; }
│ │ │ │ -
744
│ │ │ │ -
745template <> inline StencilTableReal<double> *
│ │ │ │ -
746PatchTable::StencilTablePtr::Get<double>() const { return _dPtr; }
│ │ │ │ -
747
│ │ │ │ -
│ │ │ │ -
748template <> inline bool
│ │ │ │ -
749PatchTable::LocalPointStencilPrecisionMatchesType<float>() const {
│ │ │ │ -
750 return !_vertexPrecisionIsDouble;
│ │ │ │ -
751}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
752template <> inline bool
│ │ │ │ -
753PatchTable::LocalPointVaryingStencilPrecisionMatchesType<float>() const {
│ │ │ │ -
754 return !_varyingPrecisionIsDouble;
│ │ │ │ -
755}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
756template <> inline bool
│ │ │ │ -
757PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType<float>() const {
│ │ │ │ -
758 return !_faceVaryingPrecisionIsDouble;
│ │ │ │ -
759}
│ │ │ │ -
│ │ │ │ -
760
│ │ │ │ -
│ │ │ │ -
761template <> inline bool
│ │ │ │ -
762PatchTable::LocalPointStencilPrecisionMatchesType<double>() const {
│ │ │ │ -
763 return _vertexPrecisionIsDouble;
│ │ │ │ -
764}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
765template <> inline bool
│ │ │ │ -
766PatchTable::LocalPointVaryingStencilPrecisionMatchesType<double>() const {
│ │ │ │ -
767 return _varyingPrecisionIsDouble;
│ │ │ │ -
768}
│ │ │ │ -
│ │ │ │ -
│ │ │ │ -
769template <> inline bool
│ │ │ │ -
770PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType<double>() const {
│ │ │ │ -
771 return _faceVaryingPrecisionIsDouble;
│ │ │ │ -
772}
│ │ │ │ -
│ │ │ │ -
773
│ │ │ │ -
774//
│ │ │ │ -
775// StencilTable access -- backward compatible and generic:
│ │ │ │ -
776//
│ │ │ │ -
777inline StencilTable const *
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
779 assert(LocalPointStencilPrecisionMatchesType<float>());
│ │ │ │ -
780 return static_cast<StencilTable const *>(_localPointStencils.Get<float>());
│ │ │ │ -
781}
│ │ │ │ -
│ │ │ │ -
782inline StencilTable const *
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
784 assert(LocalPointVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ -
785 return static_cast<StencilTable const *>(
│ │ │ │ -
786 _localPointVaryingStencils.Get<float>());
│ │ │ │ -
787}
│ │ │ │ -
│ │ │ │ -
788inline StencilTable const *
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
790 assert(LocalPointFaceVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ -
791 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) {
│ │ │ │ -
792 return static_cast<StencilTable const *>(
│ │ │ │ -
793 _localPointFaceVaryingStencils[channel].Get<float>());
│ │ │ │ -
794 }
│ │ │ │ -
795 return NULL;
│ │ │ │ -
796}
│ │ │ │ -
│ │ │ │ -
797
│ │ │ │ -
798template <typename REAL>
│ │ │ │ -
799inline StencilTableReal<REAL> const *
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
801 assert(LocalPointStencilPrecisionMatchesType<REAL>());
│ │ │ │ -
802 return _localPointStencils.Get<REAL>();
│ │ │ │ -
803}
│ │ │ │ -
│ │ │ │ -
804template <typename REAL>
│ │ │ │ -
805inline StencilTableReal<REAL> const *
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
807 assert(LocalPointVaryingStencilPrecisionMatchesType<REAL>());
│ │ │ │ -
808 return _localPointVaryingStencils.Get<REAL>();
│ │ │ │ -
809}
│ │ │ │ -
│ │ │ │ -
810template <typename REAL>
│ │ │ │ -
811inline StencilTableReal<REAL> const *
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
813 assert(LocalPointFaceVaryingStencilPrecisionMatchesType<REAL>());
│ │ │ │ -
814 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) {
│ │ │ │ -
815 return _localPointFaceVaryingStencils[channel].Get<REAL>();
│ │ │ │ -
816 }
│ │ │ │ -
817 return NULL;
│ │ │ │ -
818}
│ │ │ │ -
│ │ │ │ -
819
│ │ │ │ -
820
│ │ │ │ -
821//
│ │ │ │ -
822// Computation of local point values:
│ │ │ │ -
823//
│ │ │ │ -
824template <class T>
│ │ │ │ -
825inline void
│ │ │ │ -
│ │ │ │ -
826PatchTable::ComputeLocalPointValues(T const *src, T *dst) const {
│ │ │ │ -
827 assert(LocalPointStencilPrecisionMatchesType<float>());
│ │ │ │ -
828 if (_localPointStencils) {
│ │ │ │ -
829 _localPointStencils.Get<float>()->UpdateValues(src, dst);
│ │ │ │ -
830 }
│ │ │ │ -
831}
│ │ │ │ -
│ │ │ │ -
832
│ │ │ │ -
833template <class T>
│ │ │ │ -
834inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
836 assert(LocalPointVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ -
837 if (_localPointVaryingStencils) {
│ │ │ │ -
838 _localPointVaryingStencils.Get<float>()->UpdateValues(src, dst);
│ │ │ │ -
839 }
│ │ │ │ -
840}
│ │ │ │ -
│ │ │ │ -
841
│ │ │ │ -
842template <class T>
│ │ │ │ -
843inline void
│ │ │ │ -
│ │ │ │ -
844PatchTable::ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel) const {
│ │ │ │ -
845 assert(LocalPointFaceVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ -
846 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) {
│ │ │ │ -
847 if (_localPointFaceVaryingStencils[channel]) {
│ │ │ │ -
848 _localPointFaceVaryingStencils[channel].Get<float>()->UpdateValues(src, dst);
│ │ │ │ -
849 }
│ │ │ │ -
850 }
│ │ │ │ -
851}
│ │ │ │ -
│ │ │ │ -
852
│ │ │ │ -
853
│ │ │ │ -
854//
│ │ │ │ -
855// Basis evaluation overloads
│ │ │ │ -
856//
│ │ │ │ -
857inline void
│ │ │ │ -
│ │ │ │ -
858PatchTable::EvaluateBasis(PatchHandle const & handle, float u, float v,
│ │ │ │ -
859 float wP[], float wDu[], float wDv[],
│ │ │ │ -
860 float wDuu[], float wDuv[], float wDvv[]) const {
│ │ │ │ -
861
│ │ │ │ -
862 EvaluateBasis<float>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ -
863}
│ │ │ │ -
│ │ │ │ -
864inline void
│ │ │ │ -
│ │ │ │ -
865PatchTable::EvaluateBasis(PatchHandle const & handle, double u, double v,
│ │ │ │ -
866 double wP[], double wDu[], double wDv[],
│ │ │ │ -
867 double wDuu[], double wDuv[], double wDvv[]) const {
│ │ │ │ -
868
│ │ │ │ -
869 EvaluateBasis<double>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ -
870}
│ │ │ │ -
│ │ │ │ -
871
│ │ │ │ -
872inline void
│ │ │ │ -
│ │ │ │ -
873PatchTable::EvaluateBasisVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ -
874 float wP[], float wDu[], float wDv[],
│ │ │ │ -
875 float wDuu[], float wDuv[], float wDvv[]) const {
│ │ │ │ -
876
│ │ │ │ -
877 EvaluateBasisVarying<float>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ -
878}
│ │ │ │ -
│ │ │ │ -
879inline void
│ │ │ │ -
│ │ │ │ -
880PatchTable::EvaluateBasisVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ -
881 double wP[], double wDu[], double wDv[],
│ │ │ │ -
882 double wDuu[], double wDuv[], double wDvv[]) const {
│ │ │ │ -
883
│ │ │ │ -
884 EvaluateBasisVarying<double>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ -
885}
│ │ │ │ -
│ │ │ │ -
886
│ │ │ │ -
887inline void
│ │ │ │ -
│ │ │ │ -
888PatchTable::EvaluateBasisFaceVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ -
889 float wP[], float wDu[], float wDv[],
│ │ │ │ -
890 float wDuu[], float wDuv[], float wDvv[], int channel) const {
│ │ │ │ -
891
│ │ │ │ -
892 EvaluateBasisFaceVarying<float>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv, channel);
│ │ │ │ -
893}
│ │ │ │ -
│ │ │ │ -
894inline void
│ │ │ │ -
│ │ │ │ -
895PatchTable::EvaluateBasisFaceVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ -
896 double wP[], double wDu[], double wDv[],
│ │ │ │ -
897 double wDuu[], double wDuv[], double wDvv[], int channel) const {
│ │ │ │ -
898
│ │ │ │ -
899 EvaluateBasisFaceVarying<double>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv, channel);
│ │ │ │ -
900}
│ │ │ │ -
│ │ │ │ -
901
│ │ │ │ -
902} // end namespace Far
│ │ │ │ -
903
│ │ │ │ -
904} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
905using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
906
│ │ │ │ -
907} // end namespace OpenSubdiv
│ │ │ │ -
908
│ │ │ │ -
909#endif /* OPENSUBDIV3_FAR_PATCH_TABLE */
│ │ │ │ +
223 if (node->children[quadrant].isLeaf) {
│ │ │ │ +
224 return &_handles[node->children[quadrant].index];
│ │ │ │ +
225 } else {
│ │ │ │ +
226 node = &_quadtree[node->children[quadrant].index];
│ │ │ │ +
227 }
│ │ │ │ +
228 }
│ │ │ │ +
229 assert(0);
│ │ │ │ +
230 return 0;
│ │ │ │ +
231}
│ │ │ │ +
│ │ │ │ +
232
│ │ │ │ +
233} // end namespace Far
│ │ │ │ +
234
│ │ │ │ +
235} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
236using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
237
│ │ │ │ +
238} // end namespace OpenSubdiv
│ │ │ │ +
239
│ │ │ │ +
240#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */
│ │ │ │ │ │ │ │ -
Vtr::ConstIndexArray ConstIndexArray
Definition types.h:47
│ │ │ │ -
std::vector< PatchParam > PatchParamTable
Definition patchParam.h:243
│ │ │ │ - │ │ │ │ - │ │ │ │ -
Vtr::Array< PatchParam > PatchParamArray
Definition patchParam.h:245
│ │ │ │ -
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ - │ │ │ │ -
An quadtree-based map connecting coarse faces to their sub-patches.
Definition patchMap.h:49
│ │ │ │ - │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ -
ConstIndexArray GetPatchArrayVaryingVertices(int array) const
Returns the varying vertex indices for the patches in array.
│ │ │ │ - │ │ │ │ -
PatchVertsTable const & GetPatchControlVerticesTable() const
Get the table of patch control vertices.
Definition patchTable.h:378
│ │ │ │ -
void ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel=0) const
Updates local point face-varying values.
Definition patchTable.h:844
│ │ │ │ -
ConstIndexArray GetVaryingVertices() const
Returns an array of varying vertex indices for the patches.
│ │ │ │ -
void ComputeLocalPointValuesVarying(T const *src, T *dst) const
Updates local point varying values.
Definition patchTable.h:835
│ │ │ │ -
ConstIndexArray GetPatchVaryingVertices(PatchHandle const &handle) const
Returns the varying vertex indices for a given patch.
│ │ │ │ -
bool IsFeatureAdaptive() const
True if the patches are of feature adaptive types.
│ │ │ │ -
int GetMaxValence() const
Returns max vertex valence.
Definition patchTable.h:92
│ │ │ │ -
StencilTableReal< REAL > const * GetLocalPointStencilTable() const
Returns the stencil table to compute local point vertex values.
│ │ │ │ -
StencilTable const * GetLocalPointStencilTable() const
Returns the stencil table to compute local point vertex values.
Definition patchTable.h:778
│ │ │ │ -
PatchParamArray getPatchParams(int arrayIndex)
│ │ │ │ -
ConstIndexArray GetPatchArrayFVarValues(int array, int channel=0) const
Returns the value indices for the patches in array in channel.
│ │ │ │ -
std::vector< float > const & GetSharpnessValues() const
Returns sharpness values table.
Definition patchTable.h:387
│ │ │ │ - │ │ │ │ -
PatchParam GetPatchFVarPatchParam(int array, int patch, int channel=0) const
Returns the face-varying params for a given patch channel.
│ │ │ │ -
ConstIndexArray GetPatchVaryingVertices(int array, int patch) const
Returns the varying vertex indices for a given patch.
│ │ │ │ -
PatchTable(PatchTable const &src)
Copy constructor.
│ │ │ │ -
int GetNumPatchArrays() const
Returns the number of patch arrays in the table.
│ │ │ │ -
ConstIndexArray GetPatchVertices(PatchHandle const &handle) const
Returns the control vertex indices for the patch identified by handle.
│ │ │ │ - │ │ │ │ -
bool LocalPointFaceVaryingStencilPrecisionMatchesType() const
Tests if the precision of the stencil table to compute local point face-varying values matches the gi...
│ │ │ │ -
PatchParamTable const & GetPatchParamTable() const
Returns the PatchParamTable (PatchParams order matches patch array sorting)
Definition patchTable.h:381
│ │ │ │ -
VertexValenceTable const & GetVertexValenceTable() const
Returns the 'VertexValences' table (vertex neighborhoods table)
Definition patchTable.h:267
│ │ │ │ -
StencilTable const * GetLocalPointFaceVaryingStencilTable(int channel=0) const
Returns the stencil table to compute local point face-varying values.
Definition patchTable.h:789
│ │ │ │ -
int GetNumControlVertices(int array) const
Returns the number of control vertices in array.
│ │ │ │ - │ │ │ │ -
void EvaluateBasisFaceVarying(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0, int channel=0) const
Evaluate basis functions for a face-varying value and derivatives at a given (u,v) parametric locatio...
│ │ │ │ -
ConstQuadOffsetsArray GetPatchQuadOffsets(PatchHandle const &handle) const
Returns the 'QuadOffsets' for the Gregory patch identified by handle.
│ │ │ │ -
PatchDescriptor GetFVarPatchDescriptorIrregular(int channel=0) const
Returns the irregular patch descriptor for channel.
│ │ │ │ -
float GetSingleCreasePatchSharpnessValue(int array, int patch) const
Returns the crease sharpness for the patch in array if it is a single-crease patch,...
│ │ │ │ - │ │ │ │ -
void ComputeLocalPointValues(T const *src, T *dst) const
Updates local point vertex values.
Definition patchTable.h:826
│ │ │ │ -
float GetSingleCreasePatchSharpnessValue(PatchHandle const &handle) const
Returns the crease sharpness for the patch identified by handle if it is a single-crease patch,...
│ │ │ │ -
PatchParam GetPatchParam(int array, int patch) const
Returns the PatchParam for patch in array.
│ │ │ │ -
ConstIndexArray GetPatchFVarValues(int array, int patch, int channel=0) const
Returns the value indices for a given patch in channel.
│ │ │ │ -
PatchDescriptor GetFVarPatchDescriptorRegular(int channel=0) const
Returns the regular patch descriptor for channel.
│ │ │ │ -
PatchDescriptor GetPatchDescriptor(PatchHandle const &handle) const
Returns the PatchDescriptor for the patch identified by handle.
│ │ │ │ - │ │ │ │ -
QuadOffsetsTable const & GetQuadOffsetsTable() const
Returns the quad-offsets table.
Definition patchTable.h:392
│ │ │ │ -
int GetNumPatches(int array) const
Returns the number of patches in array.
│ │ │ │ -
PatchDescriptor GetVaryingPatchDescriptor() const
Returns the varying patch descriptor.
│ │ │ │ -
ConstIndexArray GetPatchFVarValues(PatchHandle const &handle, int channel=0) const
Returns the value indices for a given patch in channel.
│ │ │ │ -
ConstPatchParamArray const GetPatchParams(int array) const
Returns the PatchParams for the patches in array.
│ │ │ │ -
int GetNumControlVerticesTotal() const
Returns the total number of control vertex indices in the table.
Definition patchTable.h:84
│ │ │ │ -
int GetNumFVarChannels() const
Returns the number of face-varying channels.
│ │ │ │ -
ConstPatchParamArray GetPatchArrayFVarPatchParams(int array, int channel=0) const
Returns the face-varying for a given patch in array in channel.
│ │ │ │ -
Index getPatchIndex(int array, int patch) const
│ │ │ │ -
int GetNumLocalPoints() const
Returns the number of local vertex points.
│ │ │ │ -
bool LocalPointVaryingStencilPrecisionMatchesType() const
Tests if the precision of the stencil table to compute local point varying values matches the given f...
│ │ │ │ -
ConstIndexArray GetPatchArrayVertices(int array) const
Returns the control vertex indices for the patches in array.
│ │ │ │ -
int GetNumPtexFaces() const
Returns the total number of ptex faces in the mesh.
Definition patchTable.h:95
│ │ │ │ -
ConstIndexArray GetFVarValues(int channel=0) const
Returns an array of value indices for the patches in channel.
│ │ │ │ -
Vtr::ConstArray< unsigned int > ConstQuadOffsetsArray
Accessors for the gregory patch evaluation buffers. These methods will be deprecated.
Definition patchTable.h:259
│ │ │ │ -
void EvaluateBasis(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const
Evaluate basis functions for position and derivatives at a given (u,v) parametric location of a patch...
│ │ │ │ -
StencilTableReal< REAL > const * GetLocalPointFaceVaryingStencilTable(int channel=0) const
Returns the stencil table to compute local point face-varying values.
│ │ │ │ -
int GetNumPatchesTotal() const
Returns the total number of patches stored in the table.
│ │ │ │ -
PatchParam GetPatchParam(PatchHandle const &handle) const
Returns a PatchParam for the patch identified by handle.
│ │ │ │ - │ │ │ │ -
Sdc::Options::FVarLinearInterpolation GetFVarChannelLinearInterpolation(int channel=0) const
Deprecated.
│ │ │ │ -
std::vector< Index > const & GetSharpnessIndexTable() const
Returns a sharpness index table for each patch (if exists)
Definition patchTable.h:384
│ │ │ │ -
PatchDescriptor GetPatchArrayDescriptor(int array) const
Returns the PatchDescriptor for the patches in array.
│ │ │ │ - │ │ │ │ -
void EvaluateBasisVarying(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const
Evaluate basis functions for a varying value and derivatives at a given (u,v) parametric location of ...
│ │ │ │ -
StencilTable const * GetLocalPointVaryingStencilTable() const
Returns the stencil table to compute local point varying values.
Definition patchTable.h:783
│ │ │ │ -
std::vector< unsigned int > QuadOffsetsTable
Definition patchTable.h:389
│ │ │ │ -
ConstIndexArray GetPatchVertices(int array, int patch) const
Returns the control vertex indices for patch in array.
│ │ │ │ -
PatchParam GetPatchFVarPatchParam(PatchHandle const &handle, int channel=0) const
Returns the value indices for a given patch in channel.
│ │ │ │ -
int GetFVarValueStride(int channel=0) const
Returns the stride between patches in the value index array of channel.
│ │ │ │ -
ConstPatchParamArray GetFVarPatchParams(int channel=0) const
Returns an array of face-varying patch param for channel.
│ │ │ │ -
PatchDescriptor GetFVarPatchDescriptor(int channel=0) const
Returns the default/irregular patch descriptor for channel.
│ │ │ │ -
int GetNumLocalPointsVarying() const
Returns the number of local varying points.
│ │ │ │ -
bool LocalPointStencilPrecisionMatchesType() const
Tests if the precision of the stencil table to compute local point vertex values matches the given fl...
│ │ │ │ -
StencilTableReal< REAL > const * GetLocalPointVaryingStencilTable() const
Returns the stencil table to compute local point varying values.
│ │ │ │ -
int GetNumLocalPointsFaceVarying(int channel=0) const
Returns the number of local face-varying points for channel.
│ │ │ │ -
Handle that can be used as unique patch identifier within PatchTable.
Definition patchTable.h:60
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ +
An quadtree-based map connecting coarse faces to their sub-patches.
Definition patchMap.h:49
│ │ │ │ +
PatchMap(PatchTable const &patchTable)
Constructor.
│ │ │ │ +
Handle const * FindPatch(int patchFaceId, double u, double v) const
Returns a handle to the sub-patch of the face at the given (u,v). Note that the patch face ID corresp...
Definition patchMap.h:193
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Handle that can be used as unique patch identifier within PatchTable.
Definition patchTable.h:60
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -patchTable.h │ │ │ │ │ +patchMap.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,1002 +24,238 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_PATCH_TABLE_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_PATCH_MAP_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_PATCH_MAP_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../far/patchDescriptor.h" │ │ │ │ │ -31#include "../far/patchParam.h" │ │ │ │ │ -32#include "../far/stencilTable.h" │ │ │ │ │ +30#include "../far/patchTable.h" │ │ │ │ │ +31 │ │ │ │ │ +32#include │ │ │ │ │ 33 │ │ │ │ │ -34#include "../sdc/options.h" │ │ │ │ │ -35 │ │ │ │ │ -36#include │ │ │ │ │ -37 │ │ │ │ │ -38namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -39namespace OPENSUBDIV_VERSION { │ │ │ │ │ -40 │ │ │ │ │ -41namespace Far { │ │ │ │ │ -42 │ │ │ │ │ -_5_5class _P_a_t_c_h_T_a_b_l_e { │ │ │ │ │ -56 │ │ │ │ │ -57public: │ │ │ │ │ -58 │ │ │ │ │ -_6_0 class _P_a_t_c_h_H_a_n_d_l_e { │ │ │ │ │ -61 // XXXX manuelk members will eventually be made private │ │ │ │ │ -62 public: │ │ │ │ │ -63 │ │ │ │ │ -_6_4 friend class _P_a_t_c_h_T_a_b_l_e; │ │ │ │ │ -_6_5 friend class _P_a_t_c_h_M_a_p; │ │ │ │ │ -66 │ │ │ │ │ -_6_7 _I_n_d_e_x _a_r_r_a_y_I_n_d_e_x, // Array index of the patch │ │ │ │ │ -_6_8 _p_a_t_c_h_I_n_d_e_x, // Absolute Index of the patch │ │ │ │ │ -_6_9 _v_e_r_t_I_n_d_e_x; // Relative offset to the first CV of the patch in array │ │ │ │ │ -70 }; │ │ │ │ │ -71 │ │ │ │ │ -72public: │ │ │ │ │ -73 │ │ │ │ │ -_7_5 _P_a_t_c_h_T_a_b_l_e(_P_a_t_c_h_T_a_b_l_e const & src); │ │ │ │ │ -76 │ │ │ │ │ -_7_8 _~_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Far { │ │ │ │ │ +38 │ │ │ │ │ +_4_9class _P_a_t_c_h_M_a_p { │ │ │ │ │ +50public: │ │ │ │ │ +51 │ │ │ │ │ +_5_2 typedef _P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e _H_a_n_d_l_e; │ │ │ │ │ +53 │ │ │ │ │ +_5_8 _P_a_t_c_h_M_a_p( _P_a_t_c_h_T_a_b_l_e const & patchTable ); │ │ │ │ │ +59 │ │ │ │ │ +74 _H_a_n_d_l_e const * _F_i_n_d_P_a_t_c_h( int patchFaceId, double u, double v ) const; │ │ │ │ │ +75 │ │ │ │ │ +76private: │ │ │ │ │ +77 void initializeHandles(_P_a_t_c_h_T_a_b_l_e const & patchTable); │ │ │ │ │ +78 void initializeQuadtree(_P_a_t_c_h_T_a_b_l_e const & patchTable); │ │ │ │ │ 79 │ │ │ │ │ -_8_1 bool _I_s_F_e_a_t_u_r_e_A_d_a_p_t_i_v_e() const; │ │ │ │ │ -82 │ │ │ │ │ -_8_4 int _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_o_t_a_l() const { │ │ │ │ │ -85 return (int)_patchVerts.size(); │ │ │ │ │ -86 } │ │ │ │ │ -87 │ │ │ │ │ -_8_9 int _G_e_t_N_u_m_P_a_t_c_h_e_s_T_o_t_a_l() const; │ │ │ │ │ +80private: │ │ │ │ │ +81 // Quadtree node with 4 children, tree is just a vector of nodes │ │ │ │ │ +82 struct QuadNode { │ │ │ │ │ +83 QuadNode() { std::memset(this, 0, sizeof(QuadNode)); } │ │ │ │ │ +84 │ │ │ │ │ +_8_5 struct _C_h_i_l_d { │ │ │ │ │ +_8_6 unsigned int _i_s_S_e_t : 1; // true if the child has been set │ │ │ │ │ +_8_7 unsigned int _i_s_L_e_a_f : 1; // true if the child is a QuadNode │ │ │ │ │ +_8_8 unsigned int _i_n_d_e_x : 30; // child index (either QuadNode or Handle) │ │ │ │ │ +89 }; │ │ │ │ │ 90 │ │ │ │ │ -_9_2 int _G_e_t_M_a_x_V_a_l_e_n_c_e() const { return _maxValence; } │ │ │ │ │ +91 // sets all the children to point to the patch of given index │ │ │ │ │ +92 void SetChildren(int index); │ │ │ │ │ 93 │ │ │ │ │ -_9_5 int _G_e_t_N_u_m_P_t_e_x_F_a_c_e_s() const { return _numPtexFaces; } │ │ │ │ │ +94 // sets the child in "quadrant" to point to the node or patch of the given │ │ │ │ │ +index │ │ │ │ │ +95 void SetChild(int quadrant, int index, bool isLeaf); │ │ │ │ │ 96 │ │ │ │ │ -97 │ │ │ │ │ -99 │ │ │ │ │ -105 │ │ │ │ │ -_1_0_7 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ -108 │ │ │ │ │ -_1_1_0 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ -111 │ │ │ │ │ -_1_1_3 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_P_a_r_a_m(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ -114 │ │ │ │ │ -_1_1_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s(int array, int patch) const; │ │ │ │ │ -117 │ │ │ │ │ -_1_1_9 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_P_a_r_a_m(int array, int patch) const; │ │ │ │ │ -121 │ │ │ │ │ -122 │ │ │ │ │ -124 │ │ │ │ │ -130 │ │ │ │ │ -_1_3_2 int _G_e_t_N_u_m_P_a_t_c_h_A_r_r_a_y_s() const; │ │ │ │ │ -133 │ │ │ │ │ -_1_3_5 int _G_e_t_N_u_m_P_a_t_c_h_e_s(int array) const; │ │ │ │ │ -136 │ │ │ │ │ -_1_3_8 int _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(int array) const; │ │ │ │ │ -139 │ │ │ │ │ -_1_4_1 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_P_a_t_c_h_A_r_r_a_y_D_e_s_c_r_i_p_t_o_r(int array) const; │ │ │ │ │ -142 │ │ │ │ │ -_1_4_4 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_V_e_r_t_i_c_e_s(int array) const; │ │ │ │ │ -145 │ │ │ │ │ -_1_4_7 _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y const _G_e_t_P_a_t_c_h_P_a_r_a_m_s(int array) const; │ │ │ │ │ -149 │ │ │ │ │ +97 _C_h_i_l_d children[4]; │ │ │ │ │ +98 }; │ │ │ │ │ +99 typedef std::vector QuadTree; │ │ │ │ │ +100 │ │ │ │ │ +101 // Internal methods supporting quadtree construction and queries │ │ │ │ │ +102 void assignRootNode(QuadNode * node, int index); │ │ │ │ │ +103 QuadNode * assignLeafOrChildNode(QuadNode * node, bool isLeaf, int quad, │ │ │ │ │ +int index); │ │ │ │ │ +104 │ │ │ │ │ +105 template │ │ │ │ │ +106 static int transformUVToQuadQuadrant(T const & median, T & u, T & v); │ │ │ │ │ +107 template │ │ │ │ │ +108 static int transformUVToTriQuadrant(T const & median, T & u, T & v, bool & │ │ │ │ │ +rotated); │ │ │ │ │ +109 │ │ │ │ │ +110private: │ │ │ │ │ +111 bool _patchesAreTriangular; // tri and quad assembly and search │ │ │ │ │ +requirements differ │ │ │ │ │ +112 │ │ │ │ │ +113 int _minPatchFace; // minimum patch face index supported by the map │ │ │ │ │ +114 int _maxPatchFace; // maximum patch face index supported by the map │ │ │ │ │ +115 int _maxDepth; // maximum depth of a patch in the tree │ │ │ │ │ +116 │ │ │ │ │ +117 std::vector _handles; // all the patches in the PatchTable │ │ │ │ │ +118 std::vector _quadtree; // quadtree nodes │ │ │ │ │ +119}; │ │ │ │ │ +120 │ │ │ │ │ +121// │ │ │ │ │ +122// Given a median value for both U and V, these methods transform a (u,v) │ │ │ │ │ +pair │ │ │ │ │ +123// into the quadrant that contains them and returns the quadrant index. │ │ │ │ │ +124// │ │ │ │ │ +125// Quadrant indexing for tri and quad patches -- consistent with │ │ │ │ │ +PatchParam's │ │ │ │ │ +126// usage of UV bits: │ │ │ │ │ +127// │ │ │ │ │ +128// (0,1) o-----o-----o (1,1) (0,1) o (1,0) o-----o-----o (0,0) │ │ │ │ │ +129// | | | |\ \ 1 |\ 0 | │ │ │ │ │ +130// | 2 | 3 | | \ \ | \ | │ │ │ │ │ +131// | | | | 2 \ \| 3 \| │ │ │ │ │ +132// o-----o-----o o-----o o-----o │ │ │ │ │ +133// | | | |\ 3 |\ \ 2 | │ │ │ │ │ +134// | 0 | 1 | | \ | \ \ | │ │ │ │ │ +135// | | | | 0 \| 1 \ \| │ │ │ │ │ +136// (0,0) o-----o-----o (1,0) (0,0) o-----o-----o (1,0) o (0,1) │ │ │ │ │ +137// │ │ │ │ │ +138// The triangular case also takes and returns/affects the rotation of the │ │ │ │ │ +139// quadrant being searched and identified (quadrant 3 imparts a rotation). │ │ │ │ │ +140// │ │ │ │ │ +141template │ │ │ │ │ +142inline int │ │ │ │ │ +143PatchMap::transformUVToQuadQuadrant(T const & median, T & u, T & v) { │ │ │ │ │ +144 │ │ │ │ │ +145 int uHalf = (u >= median); │ │ │ │ │ +146 if (uHalf) u -= median; │ │ │ │ │ +147 │ │ │ │ │ +148 int vHalf = (v >= median); │ │ │ │ │ +149 if (vHalf) v -= median; │ │ │ │ │ 150 │ │ │ │ │ -152 │ │ │ │ │ -159 │ │ │ │ │ -_1_6_1 int _G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s() const; │ │ │ │ │ -162 │ │ │ │ │ -164 _S_t_e_n_c_i_l_T_a_b_l_e const *_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ -165 │ │ │ │ │ -167 template │ │ │ │ │ -_1_6_8 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ -169 │ │ │ │ │ -_1_7_2 template bool _L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e() │ │ │ │ │ -const; │ │ │ │ │ -173 │ │ │ │ │ -186 template void │ │ │ │ │ -187 _C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s(T const *src, T *dst) const; │ │ │ │ │ -188 │ │ │ │ │ -189 │ │ │ │ │ -_1_9_1 int _G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_V_a_r_y_i_n_g() const; │ │ │ │ │ -192 │ │ │ │ │ -194 _S_t_e_n_c_i_l_T_a_b_l_e const *_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ -195 │ │ │ │ │ -197 template │ │ │ │ │ -_1_9_8 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ -199 │ │ │ │ │ -_2_0_2 template bool _L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ -() const; │ │ │ │ │ +151 return (vHalf << 1) | uHalf; │ │ │ │ │ +152} │ │ │ │ │ +153 │ │ │ │ │ +154template │ │ │ │ │ +155int inline │ │ │ │ │ +156PatchMap::transformUVToTriQuadrant(T const & median, T & u, T & v, bool & │ │ │ │ │ +rotated) { │ │ │ │ │ +157 │ │ │ │ │ +158 if (!rotated) { │ │ │ │ │ +159 if (u >= median) { │ │ │ │ │ +160 u -= median; │ │ │ │ │ +161 return 1; │ │ │ │ │ +162 } │ │ │ │ │ +163 if (v >= median) { │ │ │ │ │ +164 v -= median; │ │ │ │ │ +165 return 2; │ │ │ │ │ +166 } │ │ │ │ │ +167 if ((u + v) >= median) { │ │ │ │ │ +168 rotated = true; │ │ │ │ │ +169 return 3; │ │ │ │ │ +170 } │ │ │ │ │ +171 return 0; │ │ │ │ │ +172 } else { │ │ │ │ │ +173 if (u < median) { │ │ │ │ │ +174 v -= median; │ │ │ │ │ +175 return 1; │ │ │ │ │ +176 } │ │ │ │ │ +177 if (v < median) { │ │ │ │ │ +178 u -= median; │ │ │ │ │ +179 return 2; │ │ │ │ │ +180 } │ │ │ │ │ +181 u -= median; │ │ │ │ │ +182 v -= median; │ │ │ │ │ +183 if ((u + v) < median) { │ │ │ │ │ +184 rotated = false; │ │ │ │ │ +185 return 3; │ │ │ │ │ +186 } │ │ │ │ │ +187 return 0; │ │ │ │ │ +188 } │ │ │ │ │ +189} │ │ │ │ │ +190 │ │ │ │ │ +192inline _P_a_t_c_h_M_a_p_:_:_H_a_n_d_l_e const * │ │ │ │ │ +_1_9_3_P_a_t_c_h_M_a_p_:_:_F_i_n_d_P_a_t_c_h( int faceid, double u, double v ) const { │ │ │ │ │ +194 │ │ │ │ │ +195 // │ │ │ │ │ +196 // Reject patch faces not supported by this map, or those corresponding │ │ │ │ │ +197 // to holes or otherwise unassigned (the root node for a patch will │ │ │ │ │ +198 // have all or no quadrants set): │ │ │ │ │ +199 // │ │ │ │ │ +200 if ((faceid < _minPatchFace) || (faceid > _maxPatchFace)) return 0; │ │ │ │ │ +201 │ │ │ │ │ +202 QuadNode const * node = &_quadtree[faceid - _minPatchFace]; │ │ │ │ │ 203 │ │ │ │ │ -216 template void │ │ │ │ │ -217 _C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_V_a_r_y_i_n_g(T const *src, T *dst) const; │ │ │ │ │ -218 │ │ │ │ │ +204 if (!node->children[0].isSet) return 0; │ │ │ │ │ +205 │ │ │ │ │ +206 // │ │ │ │ │ +207 // Search the tree for the sub-patch containing the given (u,v) │ │ │ │ │ +208 // │ │ │ │ │ +209 assert( (u>=0.0) && (u<=1.0) && (v>=0.0) && (v<=1.0) ); │ │ │ │ │ +210 │ │ │ │ │ +211 double median = 0.5; │ │ │ │ │ +212 bool triRotated = false; │ │ │ │ │ +213 │ │ │ │ │ +214 for (int depth = 0; depth <= _maxDepth; ++depth, median *= 0.5) { │ │ │ │ │ +215 │ │ │ │ │ +216 int quadrant = _patchesAreTriangular │ │ │ │ │ +217 ? transformUVToTriQuadrant(median, u, v, triRotated) │ │ │ │ │ +218 : transformUVToQuadQuadrant(median, u, v); │ │ │ │ │ 219 │ │ │ │ │ -_2_2_1 int _G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_F_a_c_e_V_a_r_y_i_n_g(int channel = 0) const; │ │ │ │ │ +220 // holes should have been rejected at the root node of the face │ │ │ │ │ +221 assert(node->children[quadrant].isSet); │ │ │ │ │ 222 │ │ │ │ │ -224 _S_t_e_n_c_i_l_T_a_b_l_e const *_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int channel = 0) │ │ │ │ │ -const; │ │ │ │ │ -225 │ │ │ │ │ -227 template │ │ │ │ │ -_2_2_8 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int │ │ │ │ │ -channel = 0) const; │ │ │ │ │ -229 │ │ │ │ │ -_2_3_2 template bool │ │ │ │ │ -_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e() const; │ │ │ │ │ -233 │ │ │ │ │ -248 template void │ │ │ │ │ -249 _C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_F_a_c_e_V_a_r_y_i_n_g(T const *src, T *dst, int channel = 0) │ │ │ │ │ -const; │ │ │ │ │ -251 │ │ │ │ │ -252 │ │ │ │ │ -254 │ │ │ │ │ -255 │ │ │ │ │ -_2_5_9 typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_u_n_s_i_g_n_e_d_ _i_n_t_> _C_o_n_s_t_Q_u_a_d_O_f_f_s_e_t_s_A_r_r_a_y; │ │ │ │ │ -260 │ │ │ │ │ -_2_6_2 _C_o_n_s_t_Q_u_a_d_O_f_f_s_e_t_s_A_r_r_a_y _G_e_t_P_a_t_c_h_Q_u_a_d_O_f_f_s_e_t_s(_P_a_t_c_h_H_a_n_d_l_e const & handle) │ │ │ │ │ -const; │ │ │ │ │ -263 │ │ │ │ │ -_2_6_4 typedef std::vector _V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e; │ │ │ │ │ -265 │ │ │ │ │ -_2_6_7 _V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e const & _G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e() const { │ │ │ │ │ -268 return _vertexValenceTable; │ │ │ │ │ -269 } │ │ │ │ │ -271 │ │ │ │ │ -272 │ │ │ │ │ -274 │ │ │ │ │ -280 │ │ │ │ │ -_2_8_3 float _G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ -284 │ │ │ │ │ -_2_8_7 float _G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e(int array, int patch) const; │ │ │ │ │ -289 │ │ │ │ │ -290 │ │ │ │ │ -292 │ │ │ │ │ -298 │ │ │ │ │ -_3_0_0 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r() const; │ │ │ │ │ -301 │ │ │ │ │ -_3_0_3 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ -304 │ │ │ │ │ -_3_0_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s(int array, int patch) const; │ │ │ │ │ -307 │ │ │ │ │ -_3_0_9 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s(int array) const; │ │ │ │ │ -310 │ │ │ │ │ -_3_1_2 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s() const; │ │ │ │ │ -314 │ │ │ │ │ -315 │ │ │ │ │ -317 │ │ │ │ │ -323 │ │ │ │ │ -_3_2_5 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const; │ │ │ │ │ -326 │ │ │ │ │ -_3_2_8 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_R_e_g_u_l_a_r(int channel = 0) const; │ │ │ │ │ -329 │ │ │ │ │ -_3_3_1 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_I_r_r_e_g_u_l_a_r(int channel = 0) const; │ │ │ │ │ -332 │ │ │ │ │ -_3_3_4 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r(int channel = 0) const; │ │ │ │ │ -335 │ │ │ │ │ -_3_3_7 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, int channel │ │ │ │ │ -= 0) const; │ │ │ │ │ -338 │ │ │ │ │ -_3_4_0 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s(int array, int patch, int channel = 0) │ │ │ │ │ -const; │ │ │ │ │ -341 │ │ │ │ │ -_3_4_3 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_V_a_l_u_e_s(int array, int channel = 0) const; │ │ │ │ │ -344 │ │ │ │ │ -_3_4_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_V_a_r_V_a_l_u_e_s(int channel = 0) const; │ │ │ │ │ -347 │ │ │ │ │ -_3_4_9 int _G_e_t_F_V_a_r_V_a_l_u_e_S_t_r_i_d_e(int channel = 0) const; │ │ │ │ │ -350 │ │ │ │ │ -_3_5_2 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m(_P_a_t_c_h_H_a_n_d_l_e const & handle, int channel = │ │ │ │ │ -0) const; │ │ │ │ │ -353 │ │ │ │ │ -_3_5_5 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m(int array, int patch, int channel = 0) │ │ │ │ │ -const; │ │ │ │ │ -356 │ │ │ │ │ -_3_5_8 _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s(int array, int channel = │ │ │ │ │ -0) const; │ │ │ │ │ -359 │ │ │ │ │ -_3_6_1 _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y _G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s(int channel = 0) const; │ │ │ │ │ -362 │ │ │ │ │ -_3_6_4 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n _G_e_t_F_V_a_r_C_h_a_n_n_e_l_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n(int │ │ │ │ │ -channel = 0) const; │ │ │ │ │ -366 │ │ │ │ │ -367 │ │ │ │ │ -369 │ │ │ │ │ -374 │ │ │ │ │ -_3_7_5 typedef std::vector _P_a_t_c_h_V_e_r_t_s_T_a_b_l_e; │ │ │ │ │ -376 │ │ │ │ │ -_3_7_8 _P_a_t_c_h_V_e_r_t_s_T_a_b_l_e const & _G_e_t_P_a_t_c_h_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_a_b_l_e() const { return │ │ │ │ │ -_patchVerts; } │ │ │ │ │ -379 │ │ │ │ │ -_3_8_1 _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e const & _G_e_t_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e() const { return _paramTable; } │ │ │ │ │ -382 │ │ │ │ │ -_3_8_4 std::vector const &_G_e_t_S_h_a_r_p_n_e_s_s_I_n_d_e_x_T_a_b_l_e() const { return │ │ │ │ │ -_sharpnessIndices; } │ │ │ │ │ -385 │ │ │ │ │ -_3_8_7 std::vector const &_G_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s() const { return │ │ │ │ │ -_sharpnessValues; } │ │ │ │ │ -388 │ │ │ │ │ -_3_8_9 typedef std::vector _Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e; │ │ │ │ │ -390 │ │ │ │ │ -_3_9_2 _Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e const & _G_e_t_Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e() const { │ │ │ │ │ -393 return _quadOffsetsTable; │ │ │ │ │ -394 } │ │ │ │ │ -396 │ │ │ │ │ -_3_9_8 void _p_r_i_n_t() const; │ │ │ │ │ -399 │ │ │ │ │ -400public: │ │ │ │ │ -401 │ │ │ │ │ -403 │ │ │ │ │ -405 │ │ │ │ │ -428 template │ │ │ │ │ -_4_2_9 void _E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, REAL u, REAL v, │ │ │ │ │ -430 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0, │ │ │ │ │ -431 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const; │ │ │ │ │ -432 │ │ │ │ │ -435 void _E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ -436 float wP[], float wDu[] = 0, float wDv[] = 0, │ │ │ │ │ -437 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const; │ │ │ │ │ -438 │ │ │ │ │ -441 void _E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double v, │ │ │ │ │ -442 double wP[], double wDu[] = 0, double wDv[] = 0, │ │ │ │ │ -443 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const; │ │ │ │ │ -444 │ │ │ │ │ -467 template │ │ │ │ │ -_4_6_8 void _E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, REAL u, REAL v, │ │ │ │ │ -469 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0, │ │ │ │ │ -470 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const; │ │ │ │ │ -471 │ │ │ │ │ -474 void _E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ -475 float wP[], float wDu[] = 0, float wDv[] = 0, │ │ │ │ │ -476 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const; │ │ │ │ │ -477 │ │ │ │ │ -480 void _E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double v, │ │ │ │ │ -481 double wP[], double wDu[] = 0, double wDv[] = 0, │ │ │ │ │ -482 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const; │ │ │ │ │ -483 │ │ │ │ │ -508 template │ │ │ │ │ -_5_0_9 void _E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, REAL u, REAL v, │ │ │ │ │ -510 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0, │ │ │ │ │ -511 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0, │ │ │ │ │ -512 int channel = 0) const; │ │ │ │ │ -513 │ │ │ │ │ -516 void _E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ -517 float wP[], float wDu[] = 0, float wDv[] = 0, │ │ │ │ │ -518 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0, │ │ │ │ │ -519 int channel = 0) const; │ │ │ │ │ -520 │ │ │ │ │ -523 void _E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double │ │ │ │ │ -v, │ │ │ │ │ -524 double wP[], double wDu[] = 0, double wDv[] = 0, │ │ │ │ │ -525 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0, │ │ │ │ │ -526 int channel = 0) const; │ │ │ │ │ -528 │ │ │ │ │ -529protected: │ │ │ │ │ -530 │ │ │ │ │ -_5_3_1 friend class _P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r; │ │ │ │ │ -532 │ │ │ │ │ -533 // Factory constructor │ │ │ │ │ -_5_3_4 _P_a_t_c_h_T_a_b_l_e(int maxvalence); │ │ │ │ │ -535 │ │ │ │ │ -_5_3_6 _I_n_d_e_x _g_e_t_P_a_t_c_h_I_n_d_e_x(int array, int patch) const; │ │ │ │ │ -537 │ │ │ │ │ -_5_3_8 _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y _g_e_t_P_a_t_c_h_P_a_r_a_m_s(int arrayIndex); │ │ │ │ │ -539 │ │ │ │ │ -_5_4_0 _I_n_d_e_x * _g_e_t_S_h_a_r_p_n_e_s_s_I_n_d_i_c_e_s(_I_n_d_e_x arrayIndex); │ │ │ │ │ -_5_4_1 float * _g_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s(_I_n_d_e_x arrayIndex); │ │ │ │ │ -542 │ │ │ │ │ -543private: │ │ │ │ │ -544 │ │ │ │ │ -545 // │ │ │ │ │ -546 // Patch arrays │ │ │ │ │ -547 // │ │ │ │ │ -548 struct PatchArray { │ │ │ │ │ -549 PatchArray(_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r d, int np, _I_n_d_e_x v, _I_n_d_e_x p, _I_n_d_e_x qo) : │ │ │ │ │ -550 desc(d), numPatches(np), vertIndex(v), │ │ │ │ │ -551 patchIndex(p), quadOffsetIndex (qo) { } │ │ │ │ │ -552 │ │ │ │ │ -553 void print() const; │ │ │ │ │ -554 │ │ │ │ │ -555 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r desc; // type of patches in the array │ │ │ │ │ -556 │ │ │ │ │ -557 int numPatches; // number of patches in the array │ │ │ │ │ -558 │ │ │ │ │ -559 _I_n_d_e_x vertIndex, // index to the first control vertex │ │ │ │ │ -560 patchIndex, // absolute index of the first patch in the array │ │ │ │ │ -561 quadOffsetIndex; // index of the first quad offset entry │ │ │ │ │ -562 }; │ │ │ │ │ -563 │ │ │ │ │ -564 typedef std::vector PatchArrayVector; │ │ │ │ │ -565 │ │ │ │ │ -566 PatchArray & getPatchArray(_I_n_d_e_x arrayIndex); │ │ │ │ │ -567 PatchArray const & getPatchArray(_I_n_d_e_x arrayIndex) const; │ │ │ │ │ -568 │ │ │ │ │ -569 void reservePatchArrays(int numPatchArrays); │ │ │ │ │ -570 void pushPatchArray(PatchDescriptor desc, int npatches, │ │ │ │ │ -571 _I_n_d_e_x * vidx, _I_n_d_e_x * pidx, _I_n_d_e_x * qoidx=0); │ │ │ │ │ -572 │ │ │ │ │ -573 _I_n_d_e_x_A_r_r_a_y getPatchArrayVertices(int arrayIndex); │ │ │ │ │ -574 │ │ │ │ │ -575 _I_n_d_e_x findPatchArray(PatchDescriptor desc); │ │ │ │ │ -576 │ │ │ │ │ -577 │ │ │ │ │ -578 // │ │ │ │ │ -579 // Varying patch arrays │ │ │ │ │ -580 // │ │ │ │ │ -581 _I_n_d_e_x_A_r_r_a_y getPatchArrayVaryingVertices(int arrayIndex); │ │ │ │ │ -582 │ │ │ │ │ -583 void allocateVaryingVertices( │ │ │ │ │ -584 PatchDescriptor desc, int numPatches); │ │ │ │ │ -585 void populateVaryingVertices(); │ │ │ │ │ -586 │ │ │ │ │ -587 // │ │ │ │ │ -588 // Face-varying patch channels │ │ │ │ │ -589 // │ │ │ │ │ -590 │ │ │ │ │ -591 // │ │ │ │ │ -592 // FVarPatchChannel │ │ │ │ │ -593 // │ │ │ │ │ -594 // Stores a record for each patch in the primitive : │ │ │ │ │ -595 // │ │ │ │ │ -596 // - Each patch in the PatchTable has a corresponding patch in each │ │ │ │ │ -597 // face-varying patch channel. Patch vertex indices are sorted in the same │ │ │ │ │ -598 // patch-type order as PatchTable::PTables. Face-varying data for a patch │ │ │ │ │ -599 // can therefore be quickly accessed by using the patch primitive ID as │ │ │ │ │ -600 // index into patchValueOffsets to locate the face-varying control vertex │ │ │ │ │ -601 // indices. │ │ │ │ │ -602 // │ │ │ │ │ -603 // - Face-varying channels can have a different interpolation modes │ │ │ │ │ -604 // │ │ │ │ │ -605 // - Unlike "vertex" patches, there are no transition masks required │ │ │ │ │ -606 // for face-varying patches. │ │ │ │ │ -607 // │ │ │ │ │ -608 // - Face-varying patches still require boundary edge masks. │ │ │ │ │ -609 // │ │ │ │ │ -610 // - currently most patches with sharp boundaries but smooth interiors have │ │ │ │ │ -611 // to be isolated to level 10 : we need a special type of bicubic patch │ │ │ │ │ -612 // similar to single-crease to resolve this condition without requiring │ │ │ │ │ -613 // isolation if possible │ │ │ │ │ -614 // │ │ │ │ │ -615 struct FVarPatchChannel { │ │ │ │ │ -616 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n interpolation; │ │ │ │ │ -617 │ │ │ │ │ -618 PatchDescriptor regDesc; │ │ │ │ │ -619 PatchDescriptor irregDesc; │ │ │ │ │ -620 │ │ │ │ │ -621 int stride; │ │ │ │ │ -622 │ │ │ │ │ -623 std::vector patchValues; │ │ │ │ │ -624 std::vector patchParam; │ │ │ │ │ -625 }; │ │ │ │ │ -626 typedef std::vector FVarPatchChannelVector; │ │ │ │ │ -627 │ │ │ │ │ -628 FVarPatchChannel & getFVarPatchChannel(int channel); │ │ │ │ │ -629 FVarPatchChannel const & getFVarPatchChannel(int channel) const; │ │ │ │ │ -630 │ │ │ │ │ -631 void allocateFVarPatchChannels(int numChannels); │ │ │ │ │ -632 void allocateFVarPatchChannelValues( │ │ │ │ │ -633 PatchDescriptor regDesc, PatchDescriptor irregDesc, │ │ │ │ │ -634 int numPatches, int channel); │ │ │ │ │ -635 │ │ │ │ │ -636 // deprecated │ │ │ │ │ -637 void setFVarPatchChannelLinearInterpolation( │ │ │ │ │ -638 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n interpolation, int channel); │ │ │ │ │ -639 │ │ │ │ │ -640 _I_n_d_e_x_A_r_r_a_y getFVarValues(int channel); │ │ │ │ │ -641 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y getPatchFVarValues(int patch, int channel) const; │ │ │ │ │ -642 │ │ │ │ │ -643 _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y getFVarPatchParams(int channel); │ │ │ │ │ -644 PatchParam getPatchFVarPatchParam(int patch, int channel) const; │ │ │ │ │ -645 │ │ │ │ │ -646private: │ │ │ │ │ -647 // │ │ │ │ │ -648 // Simple private class to hold stencil table pointers of varying │ │ │ │ │ -precision, │ │ │ │ │ -649 // where the discriminant of the precision is external. │ │ │ │ │ -650 // │ │ │ │ │ -651 // NOTE that this is a simple pointer container and NOT a smart pointer │ │ │ │ │ -that │ │ │ │ │ -652 // manages the ownership of the object referred to by it. │ │ │ │ │ -653 // │ │ │ │ │ -654 class StencilTablePtr { │ │ │ │ │ -655 private: │ │ │ │ │ -656 typedef StencilTableReal float_type; │ │ │ │ │ -657 typedef StencilTableReal double_type; │ │ │ │ │ -658 │ │ │ │ │ -659 union { │ │ │ │ │ -660 float_type * _fPtr; │ │ │ │ │ -661 double_type * _dPtr; │ │ │ │ │ -662 }; │ │ │ │ │ -663 │ │ │ │ │ -664 public: │ │ │ │ │ -665 StencilTablePtr() { _fPtr = 0; } │ │ │ │ │ -666 StencilTablePtr(float_type * ptr) { _fPtr = ptr; } │ │ │ │ │ -667 StencilTablePtr(double_type * ptr) { _dPtr = ptr; } │ │ │ │ │ -668 │ │ │ │ │ -669 operator bool() const { return _fPtr != 0; } │ │ │ │ │ -670 │ │ │ │ │ -671 void Set() { _fPtr = 0; } │ │ │ │ │ -672 void Set(float_type * ptr) { _fPtr = ptr; } │ │ │ │ │ -673 void Set(double_type * ptr) { _dPtr = ptr; } │ │ │ │ │ -674 │ │ │ │ │ -675 template StencilTableReal * Get() const; │ │ │ │ │ -676 }; │ │ │ │ │ -677 │ │ │ │ │ -678private: │ │ │ │ │ -679 │ │ │ │ │ -680 // │ │ │ │ │ -681 // Topology │ │ │ │ │ -682 // │ │ │ │ │ -683 │ │ │ │ │ -684 int _maxValence, // highest vertex valence found in the mesh │ │ │ │ │ -685 _numPtexFaces; // total number of ptex faces │ │ │ │ │ -686 │ │ │ │ │ -687 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r _patchArrays; // Vector of descriptors for arrays of │ │ │ │ │ -patches │ │ │ │ │ -688 │ │ │ │ │ -689 std::vector _patchVerts; // Indices of the control vertices of the │ │ │ │ │ -patches │ │ │ │ │ -690 │ │ │ │ │ -691 _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e _paramTable; // PatchParam bitfields (one per patch) │ │ │ │ │ -692 │ │ │ │ │ -693 // │ │ │ │ │ -694 // Extraordinary vertex closed-form evaluation / endcap basis conversion │ │ │ │ │ -695 // │ │ │ │ │ -696 // XXXtakahito: these data will probably be replaced with mask coefficient │ │ │ │ │ -or something │ │ │ │ │ -697 // SchemeWorker populates. │ │ │ │ │ -698 // │ │ │ │ │ -699 _Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e _quadOffsetsTable; // Quad offsets (for Gregory patches) │ │ │ │ │ -700 _V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e _vertexValenceTable; // Vertex valence table (for │ │ │ │ │ -Gregory patches) │ │ │ │ │ -701 │ │ │ │ │ -702 StencilTablePtr _localPointStencils; // local point conversion stencils │ │ │ │ │ -703 StencilTablePtr _localPointVaryingStencils; // local point varying stencils │ │ │ │ │ -704 │ │ │ │ │ -705 // │ │ │ │ │ -706 // Varying data │ │ │ │ │ -707 // │ │ │ │ │ -708 PatchDescriptor _varyingDesc; │ │ │ │ │ -709 │ │ │ │ │ -710 std::vector _varyingVerts; │ │ │ │ │ -711 │ │ │ │ │ -712 // │ │ │ │ │ -713 // Face-varying data │ │ │ │ │ -714 // │ │ │ │ │ -715 FVarPatchChannelVector _fvarChannels; │ │ │ │ │ -716 │ │ │ │ │ -717 std::vector _localPointFaceVaryingStencils; │ │ │ │ │ -718 │ │ │ │ │ -719 // │ │ │ │ │ -720 // 'single-crease' patch sharpness tables │ │ │ │ │ -721 // │ │ │ │ │ -722 std::vector _sharpnessIndices; // Indices of single-crease sharpness │ │ │ │ │ -(one per patch) │ │ │ │ │ -723 std::vector _sharpnessValues; // Sharpness values. │ │ │ │ │ -724 │ │ │ │ │ -725 // │ │ │ │ │ -726 // Construction history -- relevant to at least one public query: │ │ │ │ │ -727 // │ │ │ │ │ -728 unsigned int _isUniformLinear : 1; │ │ │ │ │ -729 │ │ │ │ │ -730 // │ │ │ │ │ -731 // Precision -- only applies to local-point stencil tables │ │ │ │ │ -732 // │ │ │ │ │ -733 unsigned int _vertexPrecisionIsDouble : 1; │ │ │ │ │ -734 unsigned int _varyingPrecisionIsDouble : 1; │ │ │ │ │ -735 unsigned int _faceVaryingPrecisionIsDouble : 1; │ │ │ │ │ -736}; │ │ │ │ │ -737 │ │ │ │ │ -738 │ │ │ │ │ -739// │ │ │ │ │ -740// Template specializations for float/double -- to be defined before used: │ │ │ │ │ -741// │ │ │ │ │ -742template <> inline StencilTableReal * │ │ │ │ │ -743PatchTable::StencilTablePtr::Get() const { return _fPtr; } │ │ │ │ │ -744 │ │ │ │ │ -745template <> inline StencilTableReal * │ │ │ │ │ -746PatchTable::StencilTablePtr::Get() const { return _dPtr; } │ │ │ │ │ -747 │ │ │ │ │ -_7_4_8template <> inline bool │ │ │ │ │ -749PatchTable::LocalPointStencilPrecisionMatchesType() const { │ │ │ │ │ -750 return !_vertexPrecisionIsDouble; │ │ │ │ │ -751} │ │ │ │ │ -_7_5_2template <> inline bool │ │ │ │ │ -753PatchTable::LocalPointVaryingStencilPrecisionMatchesType() const { │ │ │ │ │ -754 return !_varyingPrecisionIsDouble; │ │ │ │ │ -755} │ │ │ │ │ -_7_5_6template <> inline bool │ │ │ │ │ -757PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType() const │ │ │ │ │ -{ │ │ │ │ │ -758 return !_faceVaryingPrecisionIsDouble; │ │ │ │ │ -759} │ │ │ │ │ -760 │ │ │ │ │ -_7_6_1template <> inline bool │ │ │ │ │ -762PatchTable::LocalPointStencilPrecisionMatchesType() const { │ │ │ │ │ -763 return _vertexPrecisionIsDouble; │ │ │ │ │ -764} │ │ │ │ │ -_7_6_5template <> inline bool │ │ │ │ │ -766PatchTable::LocalPointVaryingStencilPrecisionMatchesType() const { │ │ │ │ │ -767 return _varyingPrecisionIsDouble; │ │ │ │ │ -768} │ │ │ │ │ -_7_6_9template <> inline bool │ │ │ │ │ -770PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType() const │ │ │ │ │ -{ │ │ │ │ │ -771 return _faceVaryingPrecisionIsDouble; │ │ │ │ │ -772} │ │ │ │ │ -773 │ │ │ │ │ -774// │ │ │ │ │ -775// StencilTable access -- backward compatible and generic: │ │ │ │ │ -776// │ │ │ │ │ -777inline _S_t_e_n_c_i_l_T_a_b_l_e const * │ │ │ │ │ -_7_7_8_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ -779 assert(LocalPointStencilPrecisionMatchesType()); │ │ │ │ │ -780 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>(_localPointStencils.Get()); │ │ │ │ │ -781} │ │ │ │ │ -782inline _S_t_e_n_c_i_l_T_a_b_l_e const * │ │ │ │ │ -_7_8_3_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ -784 assert(LocalPointVaryingStencilPrecisionMatchesType()); │ │ │ │ │ -785 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -786 _localPointVaryingStencils.Get()); │ │ │ │ │ -787} │ │ │ │ │ -788inline _S_t_e_n_c_i_l_T_a_b_l_e const * │ │ │ │ │ -_7_8_9_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int channel) const { │ │ │ │ │ -790 assert(LocalPointFaceVaryingStencilPrecisionMatchesType()); │ │ │ │ │ -791 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) { │ │ │ │ │ -792 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ -793 _localPointFaceVaryingStencils[channel].Get()); │ │ │ │ │ -794 } │ │ │ │ │ -795 return NULL; │ │ │ │ │ -796} │ │ │ │ │ -797 │ │ │ │ │ -798template │ │ │ │ │ -799inline _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ -_8_0_0_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ -801 assert(LocalPointStencilPrecisionMatchesType()); │ │ │ │ │ -802 return _localPointStencils.Get(); │ │ │ │ │ -803} │ │ │ │ │ -804template │ │ │ │ │ -805inline _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ -_8_0_6_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ -807 assert(LocalPointVaryingStencilPrecisionMatchesType()); │ │ │ │ │ -808 return _localPointVaryingStencils.Get(); │ │ │ │ │ -809} │ │ │ │ │ -810template │ │ │ │ │ -811inline _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ -_8_1_2_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int channel) const { │ │ │ │ │ -813 assert(LocalPointFaceVaryingStencilPrecisionMatchesType()); │ │ │ │ │ -814 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) { │ │ │ │ │ -815 return _localPointFaceVaryingStencils[channel].Get(); │ │ │ │ │ -816 } │ │ │ │ │ -817 return NULL; │ │ │ │ │ -818} │ │ │ │ │ -819 │ │ │ │ │ -820 │ │ │ │ │ -821// │ │ │ │ │ -822// Computation of local point values: │ │ │ │ │ -823// │ │ │ │ │ -824template │ │ │ │ │ -825inline void │ │ │ │ │ -_8_2_6_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s(T const *src, T *dst) const { │ │ │ │ │ -827 assert(LocalPointStencilPrecisionMatchesType()); │ │ │ │ │ -828 if (_localPointStencils) { │ │ │ │ │ -829 _localPointStencils.Get()->UpdateValues(src, dst); │ │ │ │ │ -830 } │ │ │ │ │ -831} │ │ │ │ │ -832 │ │ │ │ │ -833template │ │ │ │ │ -834inline void │ │ │ │ │ -_8_3_5_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_V_a_r_y_i_n_g(T const *src, T *dst) const { │ │ │ │ │ -836 assert(LocalPointVaryingStencilPrecisionMatchesType()); │ │ │ │ │ -837 if (_localPointVaryingStencils) { │ │ │ │ │ -838 _localPointVaryingStencils.Get()->UpdateValues(src, dst); │ │ │ │ │ -839 } │ │ │ │ │ -840} │ │ │ │ │ -841 │ │ │ │ │ -842template │ │ │ │ │ -843inline void │ │ │ │ │ -_8_4_4_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_F_a_c_e_V_a_r_y_i_n_g(T const *src, T *dst, int │ │ │ │ │ -channel) const { │ │ │ │ │ -845 assert(LocalPointFaceVaryingStencilPrecisionMatchesType()); │ │ │ │ │ -846 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) { │ │ │ │ │ -847 if (_localPointFaceVaryingStencils[channel]) { │ │ │ │ │ -848 _localPointFaceVaryingStencils[channel].Get()->UpdateValues(src, │ │ │ │ │ -dst); │ │ │ │ │ -849 } │ │ │ │ │ -850 } │ │ │ │ │ -851} │ │ │ │ │ -852 │ │ │ │ │ -853 │ │ │ │ │ -854// │ │ │ │ │ -855// Basis evaluation overloads │ │ │ │ │ -856// │ │ │ │ │ -857inline void │ │ │ │ │ -_8_5_8_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ -859 float wP[], float wDu[], float wDv[], │ │ │ │ │ -860 float wDuu[], float wDuv[], float wDvv[]) const { │ │ │ │ │ -861 │ │ │ │ │ -862 EvaluateBasis(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ -863} │ │ │ │ │ -864inline void │ │ │ │ │ -_8_6_5_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double v, │ │ │ │ │ -866 double wP[], double wDu[], double wDv[], │ │ │ │ │ -867 double wDuu[], double wDuv[], double wDvv[]) const { │ │ │ │ │ -868 │ │ │ │ │ -869 EvaluateBasis(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ -870} │ │ │ │ │ -871 │ │ │ │ │ -872inline void │ │ │ │ │ -_8_7_3_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float │ │ │ │ │ -v, │ │ │ │ │ -874 float wP[], float wDu[], float wDv[], │ │ │ │ │ -875 float wDuu[], float wDuv[], float wDvv[]) const { │ │ │ │ │ -876 │ │ │ │ │ -877 EvaluateBasisVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ -878} │ │ │ │ │ -879inline void │ │ │ │ │ -_8_8_0_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, │ │ │ │ │ -double v, │ │ │ │ │ -881 double wP[], double wDu[], double wDv[], │ │ │ │ │ -882 double wDuu[], double wDuv[], double wDvv[]) const { │ │ │ │ │ -883 │ │ │ │ │ -884 EvaluateBasisVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ -885} │ │ │ │ │ -886 │ │ │ │ │ -887inline void │ │ │ │ │ -_8_8_8_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, │ │ │ │ │ -float v, │ │ │ │ │ -889 float wP[], float wDu[], float wDv[], │ │ │ │ │ -890 float wDuu[], float wDuv[], float wDvv[], int channel) const { │ │ │ │ │ -891 │ │ │ │ │ -892 EvaluateBasisFaceVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, │ │ │ │ │ -wDvv, channel); │ │ │ │ │ -893} │ │ │ │ │ -894inline void │ │ │ │ │ -_8_9_5_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, │ │ │ │ │ -double v, │ │ │ │ │ -896 double wP[], double wDu[], double wDv[], │ │ │ │ │ -897 double wDuu[], double wDuv[], double wDvv[], int channel) const { │ │ │ │ │ -898 │ │ │ │ │ -899 EvaluateBasisFaceVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, │ │ │ │ │ -wDvv, channel); │ │ │ │ │ -900} │ │ │ │ │ -901 │ │ │ │ │ -902} // end namespace Far │ │ │ │ │ -903 │ │ │ │ │ -904} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -905using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -906 │ │ │ │ │ -907} // end namespace OpenSubdiv │ │ │ │ │ -908 │ │ │ │ │ -909#endif /* OPENSUBDIV3_FAR_PATCH_TABLE */ │ │ │ │ │ +223 if (node->children[quadrant].isLeaf) { │ │ │ │ │ +224 return &_handles[node->children[quadrant].index]; │ │ │ │ │ +225 } else { │ │ │ │ │ +226 node = &_quadtree[node->children[quadrant].index]; │ │ │ │ │ +227 } │ │ │ │ │ +228 } │ │ │ │ │ +229 assert(0); │ │ │ │ │ +230 return 0; │ │ │ │ │ +231} │ │ │ │ │ +232 │ │ │ │ │ +233} // end namespace Far │ │ │ │ │ +234 │ │ │ │ │ +235} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +236using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +237 │ │ │ │ │ +238} // end namespace OpenSubdiv │ │ │ │ │ +239 │ │ │ │ │ +240#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ -Vtr::ConstIndexArray ConstIndexArray │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ -std::vector< PatchParam > PatchParamTable │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ -Vtr::IndexArray IndexArray │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ -Vtr::Index Index │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ -Vtr::Array< PatchParam > PatchParamArray │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r │ │ │ │ │ -std::vector< PatchArray > PatchArrayVector │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -Describes the type of a patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_4 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p │ │ │ │ │ An quadtree-based map connecting coarse faces to their sub-patches. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -Patch parameterization. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_P_a_t_c_h_M_a_p │ │ │ │ │ +PatchMap(PatchTable const &patchTable) │ │ │ │ │ +Constructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_F_i_n_d_P_a_t_c_h │ │ │ │ │ +Handle const * FindPatch(int patchFaceId, double u, double v) const │ │ │ │ │ +Returns a handle to the sub-patch of the face at the given (u,v). Note that the │ │ │ │ │ +patch face ID corresp... │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_1_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_H_a_n_d_l_e │ │ │ │ │ +PatchTable::PatchHandle Handle │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d_:_:_i_s_L_e_a_f │ │ │ │ │ +unsigned int isLeaf │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d_:_:_i_n_d_e_x │ │ │ │ │ +unsigned int index │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d_:_:_i_s_S_e_t │ │ │ │ │ +unsigned int isSet │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_6 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ Container for arrays of parametric patches. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetPatchArrayVaryingVertices(int array) const │ │ │ │ │ -Returns the varying vertex indices for the patches in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s │ │ │ │ │ -float * getSharpnessValues(Index arrayIndex) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_a_b_l_e │ │ │ │ │ -PatchVertsTable const & GetPatchControlVerticesTable() const │ │ │ │ │ -Get the table of patch control vertices. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -void ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel=0) │ │ │ │ │ -const │ │ │ │ │ -Updates local point face-varying values. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetVaryingVertices() const │ │ │ │ │ -Returns an array of varying vertex indices for the patches. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_V_a_r_y_i_n_g │ │ │ │ │ -void ComputeLocalPointValuesVarying(T const *src, T *dst) const │ │ │ │ │ -Updates local point varying values. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_3_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetPatchVaryingVertices(PatchHandle const &handle) const │ │ │ │ │ -Returns the varying vertex indices for a given patch. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_I_s_F_e_a_t_u_r_e_A_d_a_p_t_i_v_e │ │ │ │ │ -bool IsFeatureAdaptive() const │ │ │ │ │ -True if the patches are of feature adaptive types. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_M_a_x_V_a_l_e_n_c_e │ │ │ │ │ -int GetMaxValence() const │ │ │ │ │ -Returns max vertex valence. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTableReal< REAL > const * GetLocalPointStencilTable() const │ │ │ │ │ -Returns the stencil table to compute local point vertex values. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTable const * GetLocalPointStencilTable() const │ │ │ │ │ -Returns the stencil table to compute local point vertex values. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_7_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ -PatchParamArray getPatchParams(int arrayIndex) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ -ConstIndexArray GetPatchArrayFVarValues(int array, int channel=0) const │ │ │ │ │ -Returns the value indices for the patches in array in channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s │ │ │ │ │ -std::vector< float > const & GetSharpnessValues() const │ │ │ │ │ -Returns sharpness values table. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e │ │ │ │ │ -std::vector< Index > VertexValenceTable │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_2_6_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -PatchParam GetPatchFVarPatchParam(int array, int patch, int channel=0) const │ │ │ │ │ -Returns the face-varying params for a given patch channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetPatchVaryingVertices(int array, int patch) const │ │ │ │ │ -Returns the varying vertex indices for a given patch. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -PatchTable(PatchTable const &src) │ │ │ │ │ -Copy constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -int GetNumPatchArrays() const │ │ │ │ │ -Returns the number of patch arrays in the table. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetPatchVertices(PatchHandle const &handle) const │ │ │ │ │ -Returns the control vertex indices for the patch identified by handle. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -PatchTable(int maxvalence) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ -bool LocalPointFaceVaryingStencilPrecisionMatchesType() const │ │ │ │ │ -Tests if the precision of the stencil table to compute local point face-varying │ │ │ │ │ -values matches the gi... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ -PatchParamTable const & GetPatchParamTable() const │ │ │ │ │ -Returns the PatchParamTable (PatchParams order matches patch array sorting) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e │ │ │ │ │ -VertexValenceTable const & GetVertexValenceTable() const │ │ │ │ │ -Returns the 'VertexValences' table (vertex neighborhoods table) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_2_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTable const * GetLocalPointFaceVaryingStencilTable(int channel=0) const │ │ │ │ │ -Returns the stencil table to compute local point face-varying values. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_7_8_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ -int GetNumControlVertices(int array) const │ │ │ │ │ -Returns the number of control vertices in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_~_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -~PatchTable() │ │ │ │ │ -Destructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -void EvaluateBasisFaceVarying(PatchHandle const &handle, REAL u, REAL v, REAL │ │ │ │ │ -wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0, │ │ │ │ │ -int channel=0) const │ │ │ │ │ -Evaluate basis functions for a face-varying value and derivatives at a given │ │ │ │ │ -(u,v) parametric locatio... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_Q_u_a_d_O_f_f_s_e_t_s │ │ │ │ │ -ConstQuadOffsetsArray GetPatchQuadOffsets(PatchHandle const &handle) const │ │ │ │ │ -Returns the 'QuadOffsets' for the Gregory patch identified by handle. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_I_r_r_e_g_u_l_a_r │ │ │ │ │ -PatchDescriptor GetFVarPatchDescriptorIrregular(int channel=0) const │ │ │ │ │ -Returns the irregular patch descriptor for channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e │ │ │ │ │ -float GetSingleCreasePatchSharpnessValue(int array, int patch) const │ │ │ │ │ -Returns the crease sharpness for the patch in array if it is a single-crease │ │ │ │ │ -patch,... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_S_h_a_r_p_n_e_s_s_I_n_d_i_c_e_s │ │ │ │ │ -Index * getSharpnessIndices(Index arrayIndex) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s │ │ │ │ │ -void ComputeLocalPointValues(T const *src, T *dst) const │ │ │ │ │ -Updates local point vertex values. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e │ │ │ │ │ -float GetSingleCreasePatchSharpnessValue(PatchHandle const &handle) const │ │ │ │ │ -Returns the crease sharpness for the patch identified by handle if it is a │ │ │ │ │ -single-crease patch,... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -PatchParam GetPatchParam(int array, int patch) const │ │ │ │ │ -Returns the PatchParam for patch in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ -ConstIndexArray GetPatchFVarValues(int array, int patch, int channel=0) const │ │ │ │ │ -Returns the value indices for a given patch in channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_R_e_g_u_l_a_r │ │ │ │ │ -PatchDescriptor GetFVarPatchDescriptorRegular(int channel=0) const │ │ │ │ │ -Returns the regular patch descriptor for channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor GetPatchDescriptor(PatchHandle const &handle) const │ │ │ │ │ -Returns the PatchDescriptor for the patch identified by handle. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_V_e_r_t_s_T_a_b_l_e │ │ │ │ │ -std::vector< Index > PatchVertsTable │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e │ │ │ │ │ -QuadOffsetsTable const & GetQuadOffsetsTable() const │ │ │ │ │ -Returns the quad-offsets table. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_a_t_c_h_e_s │ │ │ │ │ -int GetNumPatches(int array) const │ │ │ │ │ -Returns the number of patches in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor GetVaryingPatchDescriptor() const │ │ │ │ │ -Returns the varying patch descriptor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ -ConstIndexArray GetPatchFVarValues(PatchHandle const &handle, int channel=0) │ │ │ │ │ -const │ │ │ │ │ -Returns the value indices for a given patch in channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ -ConstPatchParamArray const GetPatchParams(int array) const │ │ │ │ │ -Returns the PatchParams for the patches in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumControlVerticesTotal() const │ │ │ │ │ -Returns the total number of control vertex indices in the table. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -int GetNumFVarChannels() const │ │ │ │ │ -Returns the number of face-varying channels. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ -ConstPatchParamArray GetPatchArrayFVarPatchParams(int array, int channel=0) │ │ │ │ │ -const │ │ │ │ │ -Returns the face-varying for a given patch in array in channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_P_a_t_c_h_I_n_d_e_x │ │ │ │ │ -Index getPatchIndex(int array, int patch) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s │ │ │ │ │ -int GetNumLocalPoints() const │ │ │ │ │ -Returns the number of local vertex points. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ -bool LocalPointVaryingStencilPrecisionMatchesType() const │ │ │ │ │ -Tests if the precision of the stencil table to compute local point varying │ │ │ │ │ -values matches the given f... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetPatchArrayVertices(int array) const │ │ │ │ │ -Returns the control vertex indices for the patches in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_t_e_x_F_a_c_e_s │ │ │ │ │ -int GetNumPtexFaces() const │ │ │ │ │ -Returns the total number of ptex faces in the mesh. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_9_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ -ConstIndexArray GetFVarValues(int channel=0) const │ │ │ │ │ -Returns an array of value indices for the patches in channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_C_o_n_s_t_Q_u_a_d_O_f_f_s_e_t_s_A_r_r_a_y │ │ │ │ │ -Vtr::ConstArray< unsigned int > ConstQuadOffsetsArray │ │ │ │ │ -Accessors for the gregory patch evaluation buffers. These methods will be │ │ │ │ │ -deprecated. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_2_5_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s │ │ │ │ │ -void EvaluateBasis(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL │ │ │ │ │ -wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const │ │ │ │ │ -Evaluate basis functions for position and derivatives at a given (u,v) │ │ │ │ │ -parametric location of a patch... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTableReal< REAL > const * GetLocalPointFaceVaryingStencilTable(int │ │ │ │ │ -channel=0) const │ │ │ │ │ -Returns the stencil table to compute local point face-varying values. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_a_t_c_h_e_s_T_o_t_a_l │ │ │ │ │ -int GetNumPatchesTotal() const │ │ │ │ │ -Returns the total number of patches stored in the table. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -PatchParam GetPatchParam(PatchHandle const &handle) const │ │ │ │ │ -Returns a PatchParam for the patch identified by handle. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_p_r_i_n_t │ │ │ │ │ -void print() const │ │ │ │ │ -debug helper │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_F_V_a_r_C_h_a_n_n_e_l_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ -Sdc::Options::FVarLinearInterpolation GetFVarChannelLinearInterpolation(int │ │ │ │ │ -channel=0) const │ │ │ │ │ -Deprecated. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_S_h_a_r_p_n_e_s_s_I_n_d_e_x_T_a_b_l_e │ │ │ │ │ -std::vector< Index > const & GetSharpnessIndexTable() const │ │ │ │ │ -Returns a sharpness index table for each patch (if exists) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor GetPatchArrayDescriptor(int array) const │ │ │ │ │ -Returns the PatchDescriptor for the patches in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r │ │ │ │ │ -friend class PatchTableBuilder │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g │ │ │ │ │ -void EvaluateBasisVarying(PatchHandle const &handle, REAL u, REAL v, REAL wP[], │ │ │ │ │ -REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const │ │ │ │ │ -Evaluate basis functions for a varying value and derivatives at a given (u,v) │ │ │ │ │ -parametric location of ... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTable const * GetLocalPointVaryingStencilTable() const │ │ │ │ │ -Returns the stencil table to compute local point varying values. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_7_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e │ │ │ │ │ -std::vector< unsigned int > QuadOffsetsTable │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s │ │ │ │ │ -ConstIndexArray GetPatchVertices(int array, int patch) const │ │ │ │ │ -Returns the control vertex indices for patch in array. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -PatchParam GetPatchFVarPatchParam(PatchHandle const &handle, int channel=0) │ │ │ │ │ -const │ │ │ │ │ -Returns the value indices for a given patch in channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_V_a_l_u_e_S_t_r_i_d_e │ │ │ │ │ -int GetFVarValueStride(int channel=0) const │ │ │ │ │ -Returns the stride between patches in the value index array of channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ -ConstPatchParamArray GetFVarPatchParams(int channel=0) const │ │ │ │ │ -Returns an array of face-varying patch param for channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor GetFVarPatchDescriptor(int channel=0) const │ │ │ │ │ -Returns the default/irregular patch descriptor for channel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_V_a_r_y_i_n_g │ │ │ │ │ -int GetNumLocalPointsVarying() const │ │ │ │ │ -Returns the number of local varying points. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ -bool LocalPointStencilPrecisionMatchesType() const │ │ │ │ │ -Tests if the precision of the stencil table to compute local point vertex │ │ │ │ │ -values matches the given fl... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -StencilTableReal< REAL > const * GetLocalPointVaryingStencilTable() const │ │ │ │ │ -Returns the stencil table to compute local point varying values. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -int GetNumLocalPointsFaceVarying(int channel=0) const │ │ │ │ │ -Returns the number of local face-varying points for channel. │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e │ │ │ │ │ Handle that can be used as unique patch identifier within PatchTable. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e_:_:_p_a_t_c_h_I_n_d_e_x │ │ │ │ │ -Index patchIndex │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e_:_:_a_r_r_a_y_I_n_d_e_x │ │ │ │ │ -Index arrayIndex │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e_:_:_v_e_r_t_I_n_d_e_x │ │ │ │ │ -Index vertIndex │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ -Table of subdivision stencils. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ -FVarLinearInterpolation │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_6_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ -DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_A_r_r_a_y │ │ │ │ │ -DDeeffiinniittiioonn _a_r_r_a_y_._h_:_1_0_5 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ + * _p_a_t_c_h_M_a_p_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00734.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchMap.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/patchTable.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,29 +90,33 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
patchMap.h File Reference
│ │ │ │ +
patchTable.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ -#include <cassert>
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ +#include "../far/patchParam.h"
│ │ │ │ +#include "../far/stencilTable.h"
│ │ │ │ +#include "../sdc/options.h"
│ │ │ │ +#include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PatchMap
 An quadtree-based map connecting coarse faces to their sub-patches. More...
class  PatchTable
 Container for arrays of parametric patches. More...
 
struct  PatchMap::QuadNode::Child
class  PatchTable::PatchHandle
 Handle that can be used as unique patch identifier within PatchTable. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -121,13 +125,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,28 +1,32 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -patchMap.h File Reference │ │ │ │ │ +patchTable.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_P_a_r_a_m_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_s_t_e_n_c_i_l_T_a_b_l_e_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ - class   _P_a_t_c_h_M_a_p │ │ │ │ │ -  An quadtree-based map connecting coarse faces to their sub-patches. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ +class   _P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +  Container for arrays of parametric patches. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -struct   _P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d │ │ │ │ │ +class   _P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e │ │ │ │ │ +  Handle that can be used as unique patch identifier within _P_a_t_c_h_T_a_b_l_e. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_M_a_p_._h │ │ │ │ │ + * _p_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00734.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,4 @@ │ │ │ │ │ var a00734 = [ │ │ │ │ │ - ["PatchMap", "a00977.html", "a00977"], │ │ │ │ │ - ["Child", "a00985.html", "a00985"] │ │ │ │ │ + ["PatchTable", "a00993.html", "a00993"], │ │ │ │ │ + ["PatchHandle", "a00997.html", "a00997"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00734_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchMap.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/patchTable.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
patchMap.h
│ │ │ │ +
patchTable.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,222 +119,798 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_PATCH_MAP_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_PATCH_MAP_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_PATCH_TABLE_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../far/patchTable.h"
│ │ │ │ -
31
│ │ │ │ -
32#include <cassert>
│ │ │ │ +
30#include "../far/patchDescriptor.h"
│ │ │ │ +
31#include "../far/patchParam.h"
│ │ │ │ +
32#include "../far/stencilTable.h"
│ │ │ │
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Far {
│ │ │ │ -
38
│ │ │ │ -
│ │ │ │ -
49class PatchMap {
│ │ │ │ -
50public:
│ │ │ │ -
51
│ │ │ │ - │ │ │ │ -
53
│ │ │ │ -
58 PatchMap( PatchTable const & patchTable );
│ │ │ │ -
59
│ │ │ │ -
74 Handle const * FindPatch( int patchFaceId, double u, double v ) const;
│ │ │ │ -
75
│ │ │ │ -
76private:
│ │ │ │ -
77 void initializeHandles(PatchTable const & patchTable);
│ │ │ │ -
78 void initializeQuadtree(PatchTable const & patchTable);
│ │ │ │ +
34#include "../sdc/options.h"
│ │ │ │ +
35
│ │ │ │ +
36#include <vector>
│ │ │ │ +
37
│ │ │ │ +
38namespace OpenSubdiv {
│ │ │ │ +
39namespace OPENSUBDIV_VERSION {
│ │ │ │ +
40
│ │ │ │ +
41namespace Far {
│ │ │ │ +
42
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
56
│ │ │ │ +
57public:
│ │ │ │ +
58
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
61 // XXXX manuelk members will eventually be made private
│ │ │ │ +
62 public:
│ │ │ │ +
63
│ │ │ │ +
64 friend class PatchTable;
│ │ │ │ +
65 friend class PatchMap;
│ │ │ │ +
66
│ │ │ │ +
67 Index arrayIndex, // Array index of the patch
│ │ │ │ +
68 patchIndex, // Absolute Index of the patch
│ │ │ │ +
69 vertIndex; // Relative offset to the first CV of the patch in array
│ │ │ │ +
70 };
│ │ │ │ +
│ │ │ │ +
71
│ │ │ │ +
72public:
│ │ │ │ +
73
│ │ │ │ +
75 PatchTable(PatchTable const & src);
│ │ │ │ +
76
│ │ │ │ + │ │ │ │
79
│ │ │ │ -
80private:
│ │ │ │ -
81 // Quadtree node with 4 children, tree is just a vector of nodes
│ │ │ │ -
82 struct QuadNode {
│ │ │ │ -
83 QuadNode() { std::memset(this, 0, sizeof(QuadNode)); }
│ │ │ │ -
84
│ │ │ │ -
│ │ │ │ -
85 struct Child {
│ │ │ │ -
86 unsigned int isSet : 1; // true if the child has been set
│ │ │ │ -
87 unsigned int isLeaf : 1; // true if the child is a QuadNode
│ │ │ │ -
88 unsigned int index : 30; // child index (either QuadNode or Handle)
│ │ │ │ -
89 };
│ │ │ │ +
81 bool IsFeatureAdaptive() const;
│ │ │ │ +
82
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
85 return (int)_patchVerts.size();
│ │ │ │ +
86 }
│ │ │ │
│ │ │ │ +
87
│ │ │ │ +
89 int GetNumPatchesTotal() const;
│ │ │ │
90
│ │ │ │ -
91 // sets all the children to point to the patch of given index
│ │ │ │ -
92 void SetChildren(int index);
│ │ │ │ +
92 int GetMaxValence() const { return _maxValence; }
│ │ │ │
93
│ │ │ │ -
94 // sets the child in "quadrant" to point to the node or patch of the given index
│ │ │ │ -
95 void SetChild(int quadrant, int index, bool isLeaf);
│ │ │ │ +
95 int GetNumPtexFaces() const { return _numPtexFaces; }
│ │ │ │
96
│ │ │ │ -
97 Child children[4];
│ │ │ │ -
98 };
│ │ │ │ -
99 typedef std::vector<QuadNode> QuadTree;
│ │ │ │ -
100
│ │ │ │ -
101 // Internal methods supporting quadtree construction and queries
│ │ │ │ -
102 void assignRootNode(QuadNode * node, int index);
│ │ │ │ -
103 QuadNode * assignLeafOrChildNode(QuadNode * node, bool isLeaf, int quad, int index);
│ │ │ │ -
104
│ │ │ │ -
105 template <class T>
│ │ │ │ -
106 static int transformUVToQuadQuadrant(T const & median, T & u, T & v);
│ │ │ │ -
107 template <class T>
│ │ │ │ -
108 static int transformUVToTriQuadrant(T const & median, T & u, T & v, bool & rotated);
│ │ │ │ -
109
│ │ │ │ -
110private:
│ │ │ │ -
111 bool _patchesAreTriangular; // tri and quad assembly and search requirements differ
│ │ │ │ -
112
│ │ │ │ -
113 int _minPatchFace; // minimum patch face index supported by the map
│ │ │ │ -
114 int _maxPatchFace; // maximum patch face index supported by the map
│ │ │ │ -
115 int _maxDepth; // maximum depth of a patch in the tree
│ │ │ │ -
116
│ │ │ │ -
117 std::vector<Handle> _handles; // all the patches in the PatchTable
│ │ │ │ -
118 std::vector<QuadNode> _quadtree; // quadtree nodes
│ │ │ │ -
119};
│ │ │ │ -
│ │ │ │ -
120
│ │ │ │ -
121//
│ │ │ │ -
122// Given a median value for both U and V, these methods transform a (u,v) pair
│ │ │ │ -
123// into the quadrant that contains them and returns the quadrant index.
│ │ │ │ -
124//
│ │ │ │ -
125// Quadrant indexing for tri and quad patches -- consistent with PatchParam's
│ │ │ │ -
126// usage of UV bits:
│ │ │ │ -
127//
│ │ │ │ -
128// (0,1) o-----o-----o (1,1) (0,1) o (1,0) o-----o-----o (0,0)
│ │ │ │ -
129// | | | |\ \ 1 |\ 0 |
│ │ │ │ -
130// | 2 | 3 | | \ \ | \ |
│ │ │ │ -
131// | | | | 2 \ \| 3 \|
│ │ │ │ -
132// o-----o-----o o-----o o-----o
│ │ │ │ -
133// | | | |\ 3 |\ \ 2 |
│ │ │ │ -
134// | 0 | 1 | | \ | \ \ |
│ │ │ │ -
135// | | | | 0 \| 1 \ \|
│ │ │ │ -
136// (0,0) o-----o-----o (1,0) (0,0) o-----o-----o (1,0) o (0,1)
│ │ │ │ -
137//
│ │ │ │ -
138// The triangular case also takes and returns/affects the rotation of the
│ │ │ │ -
139// quadrant being searched and identified (quadrant 3 imparts a rotation).
│ │ │ │ -
140//
│ │ │ │ -
141template <class T>
│ │ │ │ -
142inline int
│ │ │ │ -
143PatchMap::transformUVToQuadQuadrant(T const & median, T & u, T & v) {
│ │ │ │ -
144
│ │ │ │ -
145 int uHalf = (u >= median);
│ │ │ │ -
146 if (uHalf) u -= median;
│ │ │ │ -
147
│ │ │ │ -
148 int vHalf = (v >= median);
│ │ │ │ -
149 if (vHalf) v -= median;
│ │ │ │ +
97
│ │ │ │ +
99
│ │ │ │ +
105
│ │ │ │ + │ │ │ │ +
108
│ │ │ │ + │ │ │ │ +
111
│ │ │ │ +
113 PatchParam GetPatchParam(PatchHandle const & handle) const;
│ │ │ │ +
114
│ │ │ │ +
116 ConstIndexArray GetPatchVertices(int array, int patch) const;
│ │ │ │ +
117
│ │ │ │ +
119 PatchParam GetPatchParam(int array, int patch) const;
│ │ │ │ +
121
│ │ │ │ +
122
│ │ │ │ +
124
│ │ │ │ +
130
│ │ │ │ +
132 int GetNumPatchArrays() const;
│ │ │ │ +
133
│ │ │ │ +
135 int GetNumPatches(int array) const;
│ │ │ │ +
136
│ │ │ │ +
138 int GetNumControlVertices(int array) const;
│ │ │ │ +
139
│ │ │ │ + │ │ │ │ +
142
│ │ │ │ + │ │ │ │ +
145
│ │ │ │ +
147 ConstPatchParamArray const GetPatchParams(int array) const;
│ │ │ │ +
149
│ │ │ │
150
│ │ │ │ -
151 return (vHalf << 1) | uHalf;
│ │ │ │ -
152}
│ │ │ │ -
153
│ │ │ │ -
154template <class T>
│ │ │ │ -
155int inline
│ │ │ │ -
156PatchMap::transformUVToTriQuadrant(T const & median, T & u, T & v, bool & rotated) {
│ │ │ │ -
157
│ │ │ │ -
158 if (!rotated) {
│ │ │ │ -
159 if (u >= median) {
│ │ │ │ -
160 u -= median;
│ │ │ │ -
161 return 1;
│ │ │ │ -
162 }
│ │ │ │ -
163 if (v >= median) {
│ │ │ │ -
164 v -= median;
│ │ │ │ -
165 return 2;
│ │ │ │ -
166 }
│ │ │ │ -
167 if ((u + v) >= median) {
│ │ │ │ -
168 rotated = true;
│ │ │ │ -
169 return 3;
│ │ │ │ -
170 }
│ │ │ │ -
171 return 0;
│ │ │ │ -
172 } else {
│ │ │ │ -
173 if (u < median) {
│ │ │ │ -
174 v -= median;
│ │ │ │ -
175 return 1;
│ │ │ │ -
176 }
│ │ │ │ -
177 if (v < median) {
│ │ │ │ -
178 u -= median;
│ │ │ │ -
179 return 2;
│ │ │ │ -
180 }
│ │ │ │ -
181 u -= median;
│ │ │ │ -
182 v -= median;
│ │ │ │ -
183 if ((u + v) < median) {
│ │ │ │ -
184 rotated = false;
│ │ │ │ -
185 return 3;
│ │ │ │ -
186 }
│ │ │ │ -
187 return 0;
│ │ │ │ -
188 }
│ │ │ │ -
189}
│ │ │ │ -
190
│ │ │ │ -
192inline PatchMap::Handle const *
│ │ │ │ -
│ │ │ │ -
193PatchMap::FindPatch( int faceid, double u, double v ) const {
│ │ │ │ -
194
│ │ │ │ -
195 //
│ │ │ │ -
196 // Reject patch faces not supported by this map, or those corresponding
│ │ │ │ -
197 // to holes or otherwise unassigned (the root node for a patch will
│ │ │ │ -
198 // have all or no quadrants set):
│ │ │ │ -
199 //
│ │ │ │ -
200 if ((faceid < _minPatchFace) || (faceid > _maxPatchFace)) return 0;
│ │ │ │ -
201
│ │ │ │ -
202 QuadNode const * node = &_quadtree[faceid - _minPatchFace];
│ │ │ │ +
152
│ │ │ │ +
159
│ │ │ │ +
161 int GetNumLocalPoints() const;
│ │ │ │ +
162
│ │ │ │ + │ │ │ │ +
165
│ │ │ │ +
167 template <typename REAL>
│ │ │ │ + │ │ │ │ +
169
│ │ │ │ +
172 template <typename REAL> bool LocalPointStencilPrecisionMatchesType() const;
│ │ │ │ +
173
│ │ │ │ +
186 template <class T> void
│ │ │ │ +
187 ComputeLocalPointValues(T const *src, T *dst) const;
│ │ │ │ +
188
│ │ │ │ +
189
│ │ │ │ + │ │ │ │ +
192
│ │ │ │ + │ │ │ │ +
195
│ │ │ │ +
197 template <typename REAL>
│ │ │ │ + │ │ │ │ +
199
│ │ │ │ +
202 template <typename REAL> bool LocalPointVaryingStencilPrecisionMatchesType() const;
│ │ │ │
203
│ │ │ │ -
204 if (!node->children[0].isSet) return 0;
│ │ │ │ -
205
│ │ │ │ -
206 //
│ │ │ │ -
207 // Search the tree for the sub-patch containing the given (u,v)
│ │ │ │ -
208 //
│ │ │ │ -
209 assert( (u>=0.0) && (u<=1.0) && (v>=0.0) && (v<=1.0) );
│ │ │ │ -
210
│ │ │ │ -
211 double median = 0.5;
│ │ │ │ -
212 bool triRotated = false;
│ │ │ │ -
213
│ │ │ │ -
214 for (int depth = 0; depth <= _maxDepth; ++depth, median *= 0.5) {
│ │ │ │ -
215
│ │ │ │ -
216 int quadrant = _patchesAreTriangular
│ │ │ │ -
217 ? transformUVToTriQuadrant(median, u, v, triRotated)
│ │ │ │ -
218 : transformUVToQuadQuadrant(median, u, v);
│ │ │ │ +
216 template <class T> void
│ │ │ │ +
217 ComputeLocalPointValuesVarying(T const *src, T *dst) const;
│ │ │ │ +
218
│ │ │ │
219
│ │ │ │ -
220 // holes should have been rejected at the root node of the face
│ │ │ │ -
221 assert(node->children[quadrant].isSet);
│ │ │ │ +
221 int GetNumLocalPointsFaceVarying(int channel = 0) const;
│ │ │ │
222
│ │ │ │ -
223 if (node->children[quadrant].isLeaf) {
│ │ │ │ -
224 return &_handles[node->children[quadrant].index];
│ │ │ │ -
225 } else {
│ │ │ │ -
226 node = &_quadtree[node->children[quadrant].index];
│ │ │ │ -
227 }
│ │ │ │ -
228 }
│ │ │ │ -
229 assert(0);
│ │ │ │ -
230 return 0;
│ │ │ │ -
231}
│ │ │ │ -
│ │ │ │ -
232
│ │ │ │ -
233} // end namespace Far
│ │ │ │ -
234
│ │ │ │ -
235} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
236using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
237
│ │ │ │ -
238} // end namespace OpenSubdiv
│ │ │ │ -
239
│ │ │ │ -
240#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */
│ │ │ │ +
224 StencilTable const *GetLocalPointFaceVaryingStencilTable(int channel = 0) const;
│ │ │ │ +
225
│ │ │ │ +
227 template <typename REAL>
│ │ │ │ + │ │ │ │ +
229
│ │ │ │ +
232 template <typename REAL> bool LocalPointFaceVaryingStencilPrecisionMatchesType() const;
│ │ │ │ +
233
│ │ │ │ +
248 template <class T> void
│ │ │ │ +
249 ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel = 0) const;
│ │ │ │ +
251
│ │ │ │ +
252
│ │ │ │ +
254
│ │ │ │ +
255
│ │ │ │ + │ │ │ │ +
260
│ │ │ │ + │ │ │ │ +
263
│ │ │ │ +
264 typedef std::vector<Index> VertexValenceTable;
│ │ │ │ +
265
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
268 return _vertexValenceTable;
│ │ │ │ +
269 }
│ │ │ │ +
│ │ │ │ +
271
│ │ │ │ +
272
│ │ │ │ +
274
│ │ │ │ +
280
│ │ │ │ + │ │ │ │ +
284
│ │ │ │ +
287 float GetSingleCreasePatchSharpnessValue(int array, int patch) const;
│ │ │ │ +
289
│ │ │ │ +
290
│ │ │ │ +
292
│ │ │ │ +
298
│ │ │ │ + │ │ │ │ +
301
│ │ │ │ + │ │ │ │ +
304
│ │ │ │ +
306 ConstIndexArray GetPatchVaryingVertices(int array, int patch) const;
│ │ │ │ +
307
│ │ │ │ + │ │ │ │ +
310
│ │ │ │ + │ │ │ │ +
314
│ │ │ │ +
315
│ │ │ │ +
317
│ │ │ │ +
323
│ │ │ │ + │ │ │ │ +
326
│ │ │ │ + │ │ │ │ +
329
│ │ │ │ + │ │ │ │ +
332
│ │ │ │ + │ │ │ │ +
335
│ │ │ │ +
337 ConstIndexArray GetPatchFVarValues(PatchHandle const & handle, int channel = 0) const;
│ │ │ │ +
338
│ │ │ │ +
340 ConstIndexArray GetPatchFVarValues(int array, int patch, int channel = 0) const;
│ │ │ │ +
341
│ │ │ │ +
343 ConstIndexArray GetPatchArrayFVarValues(int array, int channel = 0) const;
│ │ │ │ +
344
│ │ │ │ +
346 ConstIndexArray GetFVarValues(int channel = 0) const;
│ │ │ │ +
347
│ │ │ │ +
349 int GetFVarValueStride(int channel = 0) const;
│ │ │ │ +
350
│ │ │ │ +
352 PatchParam GetPatchFVarPatchParam(PatchHandle const & handle, int channel = 0) const;
│ │ │ │ +
353
│ │ │ │ +
355 PatchParam GetPatchFVarPatchParam(int array, int patch, int channel = 0) const;
│ │ │ │ +
356
│ │ │ │ +
358 ConstPatchParamArray GetPatchArrayFVarPatchParams(int array, int channel = 0) const;
│ │ │ │ +
359
│ │ │ │ + │ │ │ │ +
362
│ │ │ │ + │ │ │ │ +
366
│ │ │ │ +
367
│ │ │ │ +
369
│ │ │ │ +
374
│ │ │ │ +
375 typedef std::vector<Index> PatchVertsTable;
│ │ │ │ +
376
│ │ │ │ +
378 PatchVertsTable const & GetPatchControlVerticesTable() const { return _patchVerts; }
│ │ │ │ +
379
│ │ │ │ +
381 PatchParamTable const & GetPatchParamTable() const { return _paramTable; }
│ │ │ │ +
382
│ │ │ │ +
384 std::vector<Index> const &GetSharpnessIndexTable() const { return _sharpnessIndices; }
│ │ │ │ +
385
│ │ │ │ +
387 std::vector<float> const &GetSharpnessValues() const { return _sharpnessValues; }
│ │ │ │ +
388
│ │ │ │ +
389 typedef std::vector<unsigned int> QuadOffsetsTable;
│ │ │ │ +
390
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
393 return _quadOffsetsTable;
│ │ │ │ +
394 }
│ │ │ │ +
│ │ │ │ +
396
│ │ │ │ +
398 void print() const;
│ │ │ │ +
399
│ │ │ │ +
400public:
│ │ │ │ +
401
│ │ │ │ +
403
│ │ │ │ +
405
│ │ │ │ +
428 template <typename REAL>
│ │ │ │ +
429 void EvaluateBasis(PatchHandle const & handle, REAL u, REAL v,
│ │ │ │ +
430 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0,
│ │ │ │ +
431 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const;
│ │ │ │ +
432
│ │ │ │ +
435 void EvaluateBasis(PatchHandle const & handle, float u, float v,
│ │ │ │ +
436 float wP[], float wDu[] = 0, float wDv[] = 0,
│ │ │ │ +
437 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const;
│ │ │ │ +
438
│ │ │ │ +
441 void EvaluateBasis(PatchHandle const & handle, double u, double v,
│ │ │ │ +
442 double wP[], double wDu[] = 0, double wDv[] = 0,
│ │ │ │ +
443 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const;
│ │ │ │ +
444
│ │ │ │ +
467 template <typename REAL>
│ │ │ │ +
468 void EvaluateBasisVarying(PatchHandle const & handle, REAL u, REAL v,
│ │ │ │ +
469 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0,
│ │ │ │ +
470 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const;
│ │ │ │ +
471
│ │ │ │ +
474 void EvaluateBasisVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ +
475 float wP[], float wDu[] = 0, float wDv[] = 0,
│ │ │ │ +
476 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const;
│ │ │ │ +
477
│ │ │ │ +
480 void EvaluateBasisVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ +
481 double wP[], double wDu[] = 0, double wDv[] = 0,
│ │ │ │ +
482 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const;
│ │ │ │ +
483
│ │ │ │ +
508 template <typename REAL>
│ │ │ │ +
509 void EvaluateBasisFaceVarying(PatchHandle const & handle, REAL u, REAL v,
│ │ │ │ +
510 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0,
│ │ │ │ +
511 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0,
│ │ │ │ +
512 int channel = 0) const;
│ │ │ │ +
513
│ │ │ │ +
516 void EvaluateBasisFaceVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ +
517 float wP[], float wDu[] = 0, float wDv[] = 0,
│ │ │ │ +
518 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0,
│ │ │ │ +
519 int channel = 0) const;
│ │ │ │ +
520
│ │ │ │ +
523 void EvaluateBasisFaceVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ +
524 double wP[], double wDu[] = 0, double wDv[] = 0,
│ │ │ │ +
525 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0,
│ │ │ │ +
526 int channel = 0) const;
│ │ │ │ +
528
│ │ │ │ +
529protected:
│ │ │ │ +
530
│ │ │ │ +
531 friend class PatchTableBuilder;
│ │ │ │ +
532
│ │ │ │ +
533 // Factory constructor
│ │ │ │ +
534 PatchTable(int maxvalence);
│ │ │ │ +
535
│ │ │ │ +
536 Index getPatchIndex(int array, int patch) const;
│ │ │ │ +
537
│ │ │ │ + │ │ │ │ +
539
│ │ │ │ + │ │ │ │ +
541 float * getSharpnessValues(Index arrayIndex);
│ │ │ │ +
542
│ │ │ │ +
543private:
│ │ │ │ +
544
│ │ │ │ +
545 //
│ │ │ │ +
546 // Patch arrays
│ │ │ │ +
547 //
│ │ │ │ +
548 struct PatchArray {
│ │ │ │ +
549 PatchArray(PatchDescriptor d, int np, Index v, Index p, Index qo) :
│ │ │ │ +
550 desc(d), numPatches(np), vertIndex(v),
│ │ │ │ +
551 patchIndex(p), quadOffsetIndex (qo) { }
│ │ │ │ +
552
│ │ │ │ +
553 void print() const;
│ │ │ │ +
554
│ │ │ │ +
555 PatchDescriptor desc; // type of patches in the array
│ │ │ │ +
556
│ │ │ │ +
557 int numPatches; // number of patches in the array
│ │ │ │ +
558
│ │ │ │ +
559 Index vertIndex, // index to the first control vertex
│ │ │ │ +
560 patchIndex, // absolute index of the first patch in the array
│ │ │ │ +
561 quadOffsetIndex; // index of the first quad offset entry
│ │ │ │ +
562 };
│ │ │ │ +
563
│ │ │ │ +
564 typedef std::vector<PatchArray> PatchArrayVector;
│ │ │ │ +
565
│ │ │ │ +
566 PatchArray & getPatchArray(Index arrayIndex);
│ │ │ │ +
567 PatchArray const & getPatchArray(Index arrayIndex) const;
│ │ │ │ +
568
│ │ │ │ +
569 void reservePatchArrays(int numPatchArrays);
│ │ │ │ +
570 void pushPatchArray(PatchDescriptor desc, int npatches,
│ │ │ │ +
571 Index * vidx, Index * pidx, Index * qoidx=0);
│ │ │ │ +
572
│ │ │ │ +
573 IndexArray getPatchArrayVertices(int arrayIndex);
│ │ │ │ +
574
│ │ │ │ +
575 Index findPatchArray(PatchDescriptor desc);
│ │ │ │ +
576
│ │ │ │ +
577
│ │ │ │ +
578 //
│ │ │ │ +
579 // Varying patch arrays
│ │ │ │ +
580 //
│ │ │ │ +
581 IndexArray getPatchArrayVaryingVertices(int arrayIndex);
│ │ │ │ +
582
│ │ │ │ +
583 void allocateVaryingVertices(
│ │ │ │ +
584 PatchDescriptor desc, int numPatches);
│ │ │ │ +
585 void populateVaryingVertices();
│ │ │ │ +
586
│ │ │ │ +
587 //
│ │ │ │ +
588 // Face-varying patch channels
│ │ │ │ +
589 //
│ │ │ │ +
590
│ │ │ │ +
591 //
│ │ │ │ +
592 // FVarPatchChannel
│ │ │ │ +
593 //
│ │ │ │ +
594 // Stores a record for each patch in the primitive :
│ │ │ │ +
595 //
│ │ │ │ +
596 // - Each patch in the PatchTable has a corresponding patch in each
│ │ │ │ +
597 // face-varying patch channel. Patch vertex indices are sorted in the same
│ │ │ │ +
598 // patch-type order as PatchTable::PTables. Face-varying data for a patch
│ │ │ │ +
599 // can therefore be quickly accessed by using the patch primitive ID as
│ │ │ │ +
600 // index into patchValueOffsets to locate the face-varying control vertex
│ │ │ │ +
601 // indices.
│ │ │ │ +
602 //
│ │ │ │ +
603 // - Face-varying channels can have a different interpolation modes
│ │ │ │ +
604 //
│ │ │ │ +
605 // - Unlike "vertex" patches, there are no transition masks required
│ │ │ │ +
606 // for face-varying patches.
│ │ │ │ +
607 //
│ │ │ │ +
608 // - Face-varying patches still require boundary edge masks.
│ │ │ │ +
609 //
│ │ │ │ +
610 // - currently most patches with sharp boundaries but smooth interiors have
│ │ │ │ +
611 // to be isolated to level 10 : we need a special type of bicubic patch
│ │ │ │ +
612 // similar to single-crease to resolve this condition without requiring
│ │ │ │ +
613 // isolation if possible
│ │ │ │ +
614 //
│ │ │ │ +
615 struct FVarPatchChannel {
│ │ │ │ + │ │ │ │ +
617
│ │ │ │ +
618 PatchDescriptor regDesc;
│ │ │ │ +
619 PatchDescriptor irregDesc;
│ │ │ │ +
620
│ │ │ │ +
621 int stride;
│ │ │ │ +
622
│ │ │ │ +
623 std::vector<Index> patchValues;
│ │ │ │ +
624 std::vector<PatchParam> patchParam;
│ │ │ │ +
625 };
│ │ │ │ +
626 typedef std::vector<FVarPatchChannel> FVarPatchChannelVector;
│ │ │ │ +
627
│ │ │ │ +
628 FVarPatchChannel & getFVarPatchChannel(int channel);
│ │ │ │ +
629 FVarPatchChannel const & getFVarPatchChannel(int channel) const;
│ │ │ │ +
630
│ │ │ │ +
631 void allocateFVarPatchChannels(int numChannels);
│ │ │ │ +
632 void allocateFVarPatchChannelValues(
│ │ │ │ +
633 PatchDescriptor regDesc, PatchDescriptor irregDesc,
│ │ │ │ +
634 int numPatches, int channel);
│ │ │ │ +
635
│ │ │ │ +
636 // deprecated
│ │ │ │ +
637 void setFVarPatchChannelLinearInterpolation(
│ │ │ │ +
638 Sdc::Options::FVarLinearInterpolation interpolation, int channel);
│ │ │ │ +
639
│ │ │ │ +
640 IndexArray getFVarValues(int channel);
│ │ │ │ +
641 ConstIndexArray getPatchFVarValues(int patch, int channel) const;
│ │ │ │ +
642
│ │ │ │ +
643 PatchParamArray getFVarPatchParams(int channel);
│ │ │ │ +
644 PatchParam getPatchFVarPatchParam(int patch, int channel) const;
│ │ │ │ +
645
│ │ │ │ +
646private:
│ │ │ │ +
647 //
│ │ │ │ +
648 // Simple private class to hold stencil table pointers of varying precision,
│ │ │ │ +
649 // where the discriminant of the precision is external.
│ │ │ │ +
650 //
│ │ │ │ +
651 // NOTE that this is a simple pointer container and NOT a smart pointer that
│ │ │ │ +
652 // manages the ownership of the object referred to by it.
│ │ │ │ +
653 //
│ │ │ │ +
654 class StencilTablePtr {
│ │ │ │ +
655 private:
│ │ │ │ +
656 typedef StencilTableReal<float> float_type;
│ │ │ │ +
657 typedef StencilTableReal<double> double_type;
│ │ │ │ +
658
│ │ │ │ +
659 union {
│ │ │ │ +
660 float_type * _fPtr;
│ │ │ │ +
661 double_type * _dPtr;
│ │ │ │ +
662 };
│ │ │ │ +
663
│ │ │ │ +
664 public:
│ │ │ │ +
665 StencilTablePtr() { _fPtr = 0; }
│ │ │ │ +
666 StencilTablePtr(float_type * ptr) { _fPtr = ptr; }
│ │ │ │ +
667 StencilTablePtr(double_type * ptr) { _dPtr = ptr; }
│ │ │ │ +
668
│ │ │ │ +
669 operator bool() const { return _fPtr != 0; }
│ │ │ │ +
670
│ │ │ │ +
671 void Set() { _fPtr = 0; }
│ │ │ │ +
672 void Set(float_type * ptr) { _fPtr = ptr; }
│ │ │ │ +
673 void Set(double_type * ptr) { _dPtr = ptr; }
│ │ │ │ +
674
│ │ │ │ +
675 template <typename REAL> StencilTableReal<REAL> * Get() const;
│ │ │ │ +
676 };
│ │ │ │ +
677
│ │ │ │ +
678private:
│ │ │ │ +
679
│ │ │ │ +
680 //
│ │ │ │ +
681 // Topology
│ │ │ │ +
682 //
│ │ │ │ +
683
│ │ │ │ +
684 int _maxValence, // highest vertex valence found in the mesh
│ │ │ │ +
685 _numPtexFaces; // total number of ptex faces
│ │ │ │ +
686
│ │ │ │ +
687 PatchArrayVector _patchArrays; // Vector of descriptors for arrays of patches
│ │ │ │ +
688
│ │ │ │ +
689 std::vector<Index> _patchVerts; // Indices of the control vertices of the patches
│ │ │ │ +
690
│ │ │ │ +
691 PatchParamTable _paramTable; // PatchParam bitfields (one per patch)
│ │ │ │ +
692
│ │ │ │ +
693 //
│ │ │ │ +
694 // Extraordinary vertex closed-form evaluation / endcap basis conversion
│ │ │ │ +
695 //
│ │ │ │ +
696 // XXXtakahito: these data will probably be replaced with mask coefficient or something
│ │ │ │ +
697 // SchemeWorker populates.
│ │ │ │ +
698 //
│ │ │ │ +
699 QuadOffsetsTable _quadOffsetsTable; // Quad offsets (for Gregory patches)
│ │ │ │ +
700 VertexValenceTable _vertexValenceTable; // Vertex valence table (for Gregory patches)
│ │ │ │ +
701
│ │ │ │ +
702 StencilTablePtr _localPointStencils; // local point conversion stencils
│ │ │ │ +
703 StencilTablePtr _localPointVaryingStencils; // local point varying stencils
│ │ │ │ +
704
│ │ │ │ +
705 //
│ │ │ │ +
706 // Varying data
│ │ │ │ +
707 //
│ │ │ │ +
708 PatchDescriptor _varyingDesc;
│ │ │ │ +
709
│ │ │ │ +
710 std::vector<Index> _varyingVerts;
│ │ │ │ +
711
│ │ │ │ +
712 //
│ │ │ │ +
713 // Face-varying data
│ │ │ │ +
714 //
│ │ │ │ +
715 FVarPatchChannelVector _fvarChannels;
│ │ │ │ +
716
│ │ │ │ +
717 std::vector<StencilTablePtr> _localPointFaceVaryingStencils;
│ │ │ │ +
718
│ │ │ │ +
719 //
│ │ │ │ +
720 // 'single-crease' patch sharpness tables
│ │ │ │ +
721 //
│ │ │ │ +
722 std::vector<Index> _sharpnessIndices; // Indices of single-crease sharpness (one per patch)
│ │ │ │ +
723 std::vector<float> _sharpnessValues; // Sharpness values.
│ │ │ │ +
724
│ │ │ │ +
725 //
│ │ │ │ +
726 // Construction history -- relevant to at least one public query:
│ │ │ │ +
727 //
│ │ │ │ +
728 unsigned int _isUniformLinear : 1;
│ │ │ │ +
729
│ │ │ │ +
730 //
│ │ │ │ +
731 // Precision -- only applies to local-point stencil tables
│ │ │ │ +
732 //
│ │ │ │ +
733 unsigned int _vertexPrecisionIsDouble : 1;
│ │ │ │ +
734 unsigned int _varyingPrecisionIsDouble : 1;
│ │ │ │ +
735 unsigned int _faceVaryingPrecisionIsDouble : 1;
│ │ │ │ +
736};
│ │ │ │ +
│ │ │ │ +
737
│ │ │ │ +
738
│ │ │ │ +
739//
│ │ │ │ +
740// Template specializations for float/double -- to be defined before used:
│ │ │ │ +
741//
│ │ │ │ +
742template <> inline StencilTableReal<float> *
│ │ │ │ +
743PatchTable::StencilTablePtr::Get<float>() const { return _fPtr; }
│ │ │ │ +
744
│ │ │ │ +
745template <> inline StencilTableReal<double> *
│ │ │ │ +
746PatchTable::StencilTablePtr::Get<double>() const { return _dPtr; }
│ │ │ │ +
747
│ │ │ │ +
│ │ │ │ +
748template <> inline bool
│ │ │ │ +
749PatchTable::LocalPointStencilPrecisionMatchesType<float>() const {
│ │ │ │ +
750 return !_vertexPrecisionIsDouble;
│ │ │ │ +
751}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
752template <> inline bool
│ │ │ │ +
753PatchTable::LocalPointVaryingStencilPrecisionMatchesType<float>() const {
│ │ │ │ +
754 return !_varyingPrecisionIsDouble;
│ │ │ │ +
755}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
756template <> inline bool
│ │ │ │ +
757PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType<float>() const {
│ │ │ │ +
758 return !_faceVaryingPrecisionIsDouble;
│ │ │ │ +
759}
│ │ │ │ +
│ │ │ │ +
760
│ │ │ │ +
│ │ │ │ +
761template <> inline bool
│ │ │ │ +
762PatchTable::LocalPointStencilPrecisionMatchesType<double>() const {
│ │ │ │ +
763 return _vertexPrecisionIsDouble;
│ │ │ │ +
764}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
765template <> inline bool
│ │ │ │ +
766PatchTable::LocalPointVaryingStencilPrecisionMatchesType<double>() const {
│ │ │ │ +
767 return _varyingPrecisionIsDouble;
│ │ │ │ +
768}
│ │ │ │ +
│ │ │ │ +
│ │ │ │ +
769template <> inline bool
│ │ │ │ +
770PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType<double>() const {
│ │ │ │ +
771 return _faceVaryingPrecisionIsDouble;
│ │ │ │ +
772}
│ │ │ │ +
│ │ │ │ +
773
│ │ │ │ +
774//
│ │ │ │ +
775// StencilTable access -- backward compatible and generic:
│ │ │ │ +
776//
│ │ │ │ +
777inline StencilTable const *
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
779 assert(LocalPointStencilPrecisionMatchesType<float>());
│ │ │ │ +
780 return static_cast<StencilTable const *>(_localPointStencils.Get<float>());
│ │ │ │ +
781}
│ │ │ │ +
│ │ │ │ +
782inline StencilTable const *
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
784 assert(LocalPointVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ +
785 return static_cast<StencilTable const *>(
│ │ │ │ +
786 _localPointVaryingStencils.Get<float>());
│ │ │ │ +
787}
│ │ │ │ +
│ │ │ │ +
788inline StencilTable const *
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
790 assert(LocalPointFaceVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ +
791 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) {
│ │ │ │ +
792 return static_cast<StencilTable const *>(
│ │ │ │ +
793 _localPointFaceVaryingStencils[channel].Get<float>());
│ │ │ │ +
794 }
│ │ │ │ +
795 return NULL;
│ │ │ │ +
796}
│ │ │ │ +
│ │ │ │ +
797
│ │ │ │ +
798template <typename REAL>
│ │ │ │ +
799inline StencilTableReal<REAL> const *
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
801 assert(LocalPointStencilPrecisionMatchesType<REAL>());
│ │ │ │ +
802 return _localPointStencils.Get<REAL>();
│ │ │ │ +
803}
│ │ │ │ +
│ │ │ │ +
804template <typename REAL>
│ │ │ │ +
805inline StencilTableReal<REAL> const *
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
807 assert(LocalPointVaryingStencilPrecisionMatchesType<REAL>());
│ │ │ │ +
808 return _localPointVaryingStencils.Get<REAL>();
│ │ │ │ +
809}
│ │ │ │ +
│ │ │ │ +
810template <typename REAL>
│ │ │ │ +
811inline StencilTableReal<REAL> const *
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
813 assert(LocalPointFaceVaryingStencilPrecisionMatchesType<REAL>());
│ │ │ │ +
814 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) {
│ │ │ │ +
815 return _localPointFaceVaryingStencils[channel].Get<REAL>();
│ │ │ │ +
816 }
│ │ │ │ +
817 return NULL;
│ │ │ │ +
818}
│ │ │ │ +
│ │ │ │ +
819
│ │ │ │ +
820
│ │ │ │ +
821//
│ │ │ │ +
822// Computation of local point values:
│ │ │ │ +
823//
│ │ │ │ +
824template <class T>
│ │ │ │ +
825inline void
│ │ │ │ +
│ │ │ │ +
826PatchTable::ComputeLocalPointValues(T const *src, T *dst) const {
│ │ │ │ +
827 assert(LocalPointStencilPrecisionMatchesType<float>());
│ │ │ │ +
828 if (_localPointStencils) {
│ │ │ │ +
829 _localPointStencils.Get<float>()->UpdateValues(src, dst);
│ │ │ │ +
830 }
│ │ │ │ +
831}
│ │ │ │ +
│ │ │ │ +
832
│ │ │ │ +
833template <class T>
│ │ │ │ +
834inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
836 assert(LocalPointVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ +
837 if (_localPointVaryingStencils) {
│ │ │ │ +
838 _localPointVaryingStencils.Get<float>()->UpdateValues(src, dst);
│ │ │ │ +
839 }
│ │ │ │ +
840}
│ │ │ │ +
│ │ │ │ +
841
│ │ │ │ +
842template <class T>
│ │ │ │ +
843inline void
│ │ │ │ +
│ │ │ │ +
844PatchTable::ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel) const {
│ │ │ │ +
845 assert(LocalPointFaceVaryingStencilPrecisionMatchesType<float>());
│ │ │ │ +
846 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) {
│ │ │ │ +
847 if (_localPointFaceVaryingStencils[channel]) {
│ │ │ │ +
848 _localPointFaceVaryingStencils[channel].Get<float>()->UpdateValues(src, dst);
│ │ │ │ +
849 }
│ │ │ │ +
850 }
│ │ │ │ +
851}
│ │ │ │ +
│ │ │ │ +
852
│ │ │ │ +
853
│ │ │ │ +
854//
│ │ │ │ +
855// Basis evaluation overloads
│ │ │ │ +
856//
│ │ │ │ +
857inline void
│ │ │ │ +
│ │ │ │ +
858PatchTable::EvaluateBasis(PatchHandle const & handle, float u, float v,
│ │ │ │ +
859 float wP[], float wDu[], float wDv[],
│ │ │ │ +
860 float wDuu[], float wDuv[], float wDvv[]) const {
│ │ │ │ +
861
│ │ │ │ +
862 EvaluateBasis<float>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ +
863}
│ │ │ │ +
│ │ │ │ +
864inline void
│ │ │ │ +
│ │ │ │ +
865PatchTable::EvaluateBasis(PatchHandle const & handle, double u, double v,
│ │ │ │ +
866 double wP[], double wDu[], double wDv[],
│ │ │ │ +
867 double wDuu[], double wDuv[], double wDvv[]) const {
│ │ │ │ +
868
│ │ │ │ +
869 EvaluateBasis<double>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ +
870}
│ │ │ │ +
│ │ │ │ +
871
│ │ │ │ +
872inline void
│ │ │ │ +
│ │ │ │ +
873PatchTable::EvaluateBasisVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ +
874 float wP[], float wDu[], float wDv[],
│ │ │ │ +
875 float wDuu[], float wDuv[], float wDvv[]) const {
│ │ │ │ +
876
│ │ │ │ +
877 EvaluateBasisVarying<float>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ +
878}
│ │ │ │ +
│ │ │ │ +
879inline void
│ │ │ │ +
│ │ │ │ +
880PatchTable::EvaluateBasisVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ +
881 double wP[], double wDu[], double wDv[],
│ │ │ │ +
882 double wDuu[], double wDuv[], double wDvv[]) const {
│ │ │ │ +
883
│ │ │ │ +
884 EvaluateBasisVarying<double>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv);
│ │ │ │ +
885}
│ │ │ │ +
│ │ │ │ +
886
│ │ │ │ +
887inline void
│ │ │ │ +
│ │ │ │ +
888PatchTable::EvaluateBasisFaceVarying(PatchHandle const & handle, float u, float v,
│ │ │ │ +
889 float wP[], float wDu[], float wDv[],
│ │ │ │ +
890 float wDuu[], float wDuv[], float wDvv[], int channel) const {
│ │ │ │ +
891
│ │ │ │ +
892 EvaluateBasisFaceVarying<float>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv, channel);
│ │ │ │ +
893}
│ │ │ │ +
│ │ │ │ +
894inline void
│ │ │ │ +
│ │ │ │ +
895PatchTable::EvaluateBasisFaceVarying(PatchHandle const & handle, double u, double v,
│ │ │ │ +
896 double wP[], double wDu[], double wDv[],
│ │ │ │ +
897 double wDuu[], double wDuv[], double wDvv[], int channel) const {
│ │ │ │ +
898
│ │ │ │ +
899 EvaluateBasisFaceVarying<double>(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv, channel);
│ │ │ │ +
900}
│ │ │ │ +
│ │ │ │ +
901
│ │ │ │ +
902} // end namespace Far
│ │ │ │ +
903
│ │ │ │ +
904} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
905using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
906
│ │ │ │ +
907} // end namespace OpenSubdiv
│ │ │ │ +
908
│ │ │ │ +
909#endif /* OPENSUBDIV3_FAR_PATCH_TABLE */
│ │ │ │ │ │ │ │ -
An quadtree-based map connecting coarse faces to their sub-patches.
Definition patchMap.h:49
│ │ │ │ -
PatchMap(PatchTable const &patchTable)
Constructor.
│ │ │ │ -
Handle const * FindPatch(int patchFaceId, double u, double v) const
Returns a handle to the sub-patch of the face at the given (u,v). Note that the patch face ID corresp...
Definition patchMap.h:193
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ -
Handle that can be used as unique patch identifier within PatchTable.
Definition patchTable.h:60
│ │ │ │ +
Vtr::ConstIndexArray ConstIndexArray
Definition types.h:47
│ │ │ │ +
std::vector< PatchParam > PatchParamTable
Definition patchParam.h:243
│ │ │ │ + │ │ │ │ + │ │ │ │ +
Vtr::Array< PatchParam > PatchParamArray
Definition patchParam.h:245
│ │ │ │ +
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ + │ │ │ │ +
An quadtree-based map connecting coarse faces to their sub-patches.
Definition patchMap.h:49
│ │ │ │ + │ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
ConstIndexArray GetPatchArrayVaryingVertices(int array) const
Returns the varying vertex indices for the patches in array.
│ │ │ │ + │ │ │ │ +
PatchVertsTable const & GetPatchControlVerticesTable() const
Get the table of patch control vertices.
Definition patchTable.h:378
│ │ │ │ +
void ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel=0) const
Updates local point face-varying values.
Definition patchTable.h:844
│ │ │ │ +
ConstIndexArray GetVaryingVertices() const
Returns an array of varying vertex indices for the patches.
│ │ │ │ +
void ComputeLocalPointValuesVarying(T const *src, T *dst) const
Updates local point varying values.
Definition patchTable.h:835
│ │ │ │ +
ConstIndexArray GetPatchVaryingVertices(PatchHandle const &handle) const
Returns the varying vertex indices for a given patch.
│ │ │ │ +
bool IsFeatureAdaptive() const
True if the patches are of feature adaptive types.
│ │ │ │ +
int GetMaxValence() const
Returns max vertex valence.
Definition patchTable.h:92
│ │ │ │ +
StencilTableReal< REAL > const * GetLocalPointStencilTable() const
Returns the stencil table to compute local point vertex values.
│ │ │ │ +
StencilTable const * GetLocalPointStencilTable() const
Returns the stencil table to compute local point vertex values.
Definition patchTable.h:778
│ │ │ │ +
PatchParamArray getPatchParams(int arrayIndex)
│ │ │ │ +
ConstIndexArray GetPatchArrayFVarValues(int array, int channel=0) const
Returns the value indices for the patches in array in channel.
│ │ │ │ +
std::vector< float > const & GetSharpnessValues() const
Returns sharpness values table.
Definition patchTable.h:387
│ │ │ │ + │ │ │ │ +
PatchParam GetPatchFVarPatchParam(int array, int patch, int channel=0) const
Returns the face-varying params for a given patch channel.
│ │ │ │ +
ConstIndexArray GetPatchVaryingVertices(int array, int patch) const
Returns the varying vertex indices for a given patch.
│ │ │ │ +
PatchTable(PatchTable const &src)
Copy constructor.
│ │ │ │ +
int GetNumPatchArrays() const
Returns the number of patch arrays in the table.
│ │ │ │ +
ConstIndexArray GetPatchVertices(PatchHandle const &handle) const
Returns the control vertex indices for the patch identified by handle.
│ │ │ │ + │ │ │ │ +
bool LocalPointFaceVaryingStencilPrecisionMatchesType() const
Tests if the precision of the stencil table to compute local point face-varying values matches the gi...
│ │ │ │ +
PatchParamTable const & GetPatchParamTable() const
Returns the PatchParamTable (PatchParams order matches patch array sorting)
Definition patchTable.h:381
│ │ │ │ +
VertexValenceTable const & GetVertexValenceTable() const
Returns the 'VertexValences' table (vertex neighborhoods table)
Definition patchTable.h:267
│ │ │ │ +
StencilTable const * GetLocalPointFaceVaryingStencilTable(int channel=0) const
Returns the stencil table to compute local point face-varying values.
Definition patchTable.h:789
│ │ │ │ +
int GetNumControlVertices(int array) const
Returns the number of control vertices in array.
│ │ │ │ + │ │ │ │ +
void EvaluateBasisFaceVarying(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0, int channel=0) const
Evaluate basis functions for a face-varying value and derivatives at a given (u,v) parametric locatio...
│ │ │ │ +
ConstQuadOffsetsArray GetPatchQuadOffsets(PatchHandle const &handle) const
Returns the 'QuadOffsets' for the Gregory patch identified by handle.
│ │ │ │ +
PatchDescriptor GetFVarPatchDescriptorIrregular(int channel=0) const
Returns the irregular patch descriptor for channel.
│ │ │ │ +
float GetSingleCreasePatchSharpnessValue(int array, int patch) const
Returns the crease sharpness for the patch in array if it is a single-crease patch,...
│ │ │ │ + │ │ │ │ +
void ComputeLocalPointValues(T const *src, T *dst) const
Updates local point vertex values.
Definition patchTable.h:826
│ │ │ │ +
float GetSingleCreasePatchSharpnessValue(PatchHandle const &handle) const
Returns the crease sharpness for the patch identified by handle if it is a single-crease patch,...
│ │ │ │ +
PatchParam GetPatchParam(int array, int patch) const
Returns the PatchParam for patch in array.
│ │ │ │ +
ConstIndexArray GetPatchFVarValues(int array, int patch, int channel=0) const
Returns the value indices for a given patch in channel.
│ │ │ │ +
PatchDescriptor GetFVarPatchDescriptorRegular(int channel=0) const
Returns the regular patch descriptor for channel.
│ │ │ │ +
PatchDescriptor GetPatchDescriptor(PatchHandle const &handle) const
Returns the PatchDescriptor for the patch identified by handle.
│ │ │ │ + │ │ │ │ +
QuadOffsetsTable const & GetQuadOffsetsTable() const
Returns the quad-offsets table.
Definition patchTable.h:392
│ │ │ │ +
int GetNumPatches(int array) const
Returns the number of patches in array.
│ │ │ │ +
PatchDescriptor GetVaryingPatchDescriptor() const
Returns the varying patch descriptor.
│ │ │ │ +
ConstIndexArray GetPatchFVarValues(PatchHandle const &handle, int channel=0) const
Returns the value indices for a given patch in channel.
│ │ │ │ +
ConstPatchParamArray const GetPatchParams(int array) const
Returns the PatchParams for the patches in array.
│ │ │ │ +
int GetNumControlVerticesTotal() const
Returns the total number of control vertex indices in the table.
Definition patchTable.h:84
│ │ │ │ +
int GetNumFVarChannels() const
Returns the number of face-varying channels.
│ │ │ │ +
ConstPatchParamArray GetPatchArrayFVarPatchParams(int array, int channel=0) const
Returns the face-varying for a given patch in array in channel.
│ │ │ │ +
Index getPatchIndex(int array, int patch) const
│ │ │ │ +
int GetNumLocalPoints() const
Returns the number of local vertex points.
│ │ │ │ +
bool LocalPointVaryingStencilPrecisionMatchesType() const
Tests if the precision of the stencil table to compute local point varying values matches the given f...
│ │ │ │ +
ConstIndexArray GetPatchArrayVertices(int array) const
Returns the control vertex indices for the patches in array.
│ │ │ │ +
int GetNumPtexFaces() const
Returns the total number of ptex faces in the mesh.
Definition patchTable.h:95
│ │ │ │ +
ConstIndexArray GetFVarValues(int channel=0) const
Returns an array of value indices for the patches in channel.
│ │ │ │ +
Vtr::ConstArray< unsigned int > ConstQuadOffsetsArray
Accessors for the gregory patch evaluation buffers. These methods will be deprecated.
Definition patchTable.h:259
│ │ │ │ +
void EvaluateBasis(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const
Evaluate basis functions for position and derivatives at a given (u,v) parametric location of a patch...
│ │ │ │ +
StencilTableReal< REAL > const * GetLocalPointFaceVaryingStencilTable(int channel=0) const
Returns the stencil table to compute local point face-varying values.
│ │ │ │ +
int GetNumPatchesTotal() const
Returns the total number of patches stored in the table.
│ │ │ │ +
PatchParam GetPatchParam(PatchHandle const &handle) const
Returns a PatchParam for the patch identified by handle.
│ │ │ │ + │ │ │ │ +
Sdc::Options::FVarLinearInterpolation GetFVarChannelLinearInterpolation(int channel=0) const
Deprecated.
│ │ │ │ +
std::vector< Index > const & GetSharpnessIndexTable() const
Returns a sharpness index table for each patch (if exists)
Definition patchTable.h:384
│ │ │ │ +
PatchDescriptor GetPatchArrayDescriptor(int array) const
Returns the PatchDescriptor for the patches in array.
│ │ │ │ + │ │ │ │ +
void EvaluateBasisVarying(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const
Evaluate basis functions for a varying value and derivatives at a given (u,v) parametric location of ...
│ │ │ │ +
StencilTable const * GetLocalPointVaryingStencilTable() const
Returns the stencil table to compute local point varying values.
Definition patchTable.h:783
│ │ │ │ +
std::vector< unsigned int > QuadOffsetsTable
Definition patchTable.h:389
│ │ │ │ +
ConstIndexArray GetPatchVertices(int array, int patch) const
Returns the control vertex indices for patch in array.
│ │ │ │ +
PatchParam GetPatchFVarPatchParam(PatchHandle const &handle, int channel=0) const
Returns the value indices for a given patch in channel.
│ │ │ │ +
int GetFVarValueStride(int channel=0) const
Returns the stride between patches in the value index array of channel.
│ │ │ │ +
ConstPatchParamArray GetFVarPatchParams(int channel=0) const
Returns an array of face-varying patch param for channel.
│ │ │ │ +
PatchDescriptor GetFVarPatchDescriptor(int channel=0) const
Returns the default/irregular patch descriptor for channel.
│ │ │ │ +
int GetNumLocalPointsVarying() const
Returns the number of local varying points.
│ │ │ │ +
bool LocalPointStencilPrecisionMatchesType() const
Tests if the precision of the stencil table to compute local point vertex values matches the given fl...
│ │ │ │ +
StencilTableReal< REAL > const * GetLocalPointVaryingStencilTable() const
Returns the stencil table to compute local point varying values.
│ │ │ │ +
int GetNumLocalPointsFaceVarying(int channel=0) const
Returns the number of local face-varying points for channel.
│ │ │ │ +
Handle that can be used as unique patch identifier within PatchTable.
Definition patchTable.h:60
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -patchMap.h │ │ │ │ │ +patchTable.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,238 +24,1002 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_PATCH_MAP_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_PATCH_MAP_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_PATCH_TABLE_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_PATCH_TABLE_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../far/patchTable.h" │ │ │ │ │ -31 │ │ │ │ │ -32#include │ │ │ │ │ +30#include "../far/patchDescriptor.h" │ │ │ │ │ +31#include "../far/patchParam.h" │ │ │ │ │ +32#include "../far/stencilTable.h" │ │ │ │ │ 33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Far { │ │ │ │ │ -38 │ │ │ │ │ -_4_9class _P_a_t_c_h_M_a_p { │ │ │ │ │ -50public: │ │ │ │ │ -51 │ │ │ │ │ -_5_2 typedef _P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e _H_a_n_d_l_e; │ │ │ │ │ -53 │ │ │ │ │ -_5_8 _P_a_t_c_h_M_a_p( _P_a_t_c_h_T_a_b_l_e const & patchTable ); │ │ │ │ │ -59 │ │ │ │ │ -74 _H_a_n_d_l_e const * _F_i_n_d_P_a_t_c_h( int patchFaceId, double u, double v ) const; │ │ │ │ │ -75 │ │ │ │ │ -76private: │ │ │ │ │ -77 void initializeHandles(_P_a_t_c_h_T_a_b_l_e const & patchTable); │ │ │ │ │ -78 void initializeQuadtree(_P_a_t_c_h_T_a_b_l_e const & patchTable); │ │ │ │ │ +34#include "../sdc/options.h" │ │ │ │ │ +35 │ │ │ │ │ +36#include │ │ │ │ │ +37 │ │ │ │ │ +38namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +39namespace OPENSUBDIV_VERSION { │ │ │ │ │ +40 │ │ │ │ │ +41namespace Far { │ │ │ │ │ +42 │ │ │ │ │ +_5_5class _P_a_t_c_h_T_a_b_l_e { │ │ │ │ │ +56 │ │ │ │ │ +57public: │ │ │ │ │ +58 │ │ │ │ │ +_6_0 class _P_a_t_c_h_H_a_n_d_l_e { │ │ │ │ │ +61 // XXXX manuelk members will eventually be made private │ │ │ │ │ +62 public: │ │ │ │ │ +63 │ │ │ │ │ +_6_4 friend class _P_a_t_c_h_T_a_b_l_e; │ │ │ │ │ +_6_5 friend class _P_a_t_c_h_M_a_p; │ │ │ │ │ +66 │ │ │ │ │ +_6_7 _I_n_d_e_x _a_r_r_a_y_I_n_d_e_x, // Array index of the patch │ │ │ │ │ +_6_8 _p_a_t_c_h_I_n_d_e_x, // Absolute Index of the patch │ │ │ │ │ +_6_9 _v_e_r_t_I_n_d_e_x; // Relative offset to the first CV of the patch in array │ │ │ │ │ +70 }; │ │ │ │ │ +71 │ │ │ │ │ +72public: │ │ │ │ │ +73 │ │ │ │ │ +_7_5 _P_a_t_c_h_T_a_b_l_e(_P_a_t_c_h_T_a_b_l_e const & src); │ │ │ │ │ +76 │ │ │ │ │ +_7_8 _~_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ 79 │ │ │ │ │ -80private: │ │ │ │ │ -81 // Quadtree node with 4 children, tree is just a vector of nodes │ │ │ │ │ -82 struct QuadNode { │ │ │ │ │ -83 QuadNode() { std::memset(this, 0, sizeof(QuadNode)); } │ │ │ │ │ -84 │ │ │ │ │ -_8_5 struct _C_h_i_l_d { │ │ │ │ │ -_8_6 unsigned int _i_s_S_e_t : 1; // true if the child has been set │ │ │ │ │ -_8_7 unsigned int _i_s_L_e_a_f : 1; // true if the child is a QuadNode │ │ │ │ │ -_8_8 unsigned int _i_n_d_e_x : 30; // child index (either QuadNode or Handle) │ │ │ │ │ -89 }; │ │ │ │ │ +_8_1 bool _I_s_F_e_a_t_u_r_e_A_d_a_p_t_i_v_e() const; │ │ │ │ │ +82 │ │ │ │ │ +_8_4 int _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_o_t_a_l() const { │ │ │ │ │ +85 return (int)_patchVerts.size(); │ │ │ │ │ +86 } │ │ │ │ │ +87 │ │ │ │ │ +_8_9 int _G_e_t_N_u_m_P_a_t_c_h_e_s_T_o_t_a_l() const; │ │ │ │ │ 90 │ │ │ │ │ -91 // sets all the children to point to the patch of given index │ │ │ │ │ -92 void SetChildren(int index); │ │ │ │ │ +_9_2 int _G_e_t_M_a_x_V_a_l_e_n_c_e() const { return _maxValence; } │ │ │ │ │ 93 │ │ │ │ │ -94 // sets the child in "quadrant" to point to the node or patch of the given │ │ │ │ │ -index │ │ │ │ │ -95 void SetChild(int quadrant, int index, bool isLeaf); │ │ │ │ │ +_9_5 int _G_e_t_N_u_m_P_t_e_x_F_a_c_e_s() const { return _numPtexFaces; } │ │ │ │ │ 96 │ │ │ │ │ -97 _C_h_i_l_d children[4]; │ │ │ │ │ -98 }; │ │ │ │ │ -99 typedef std::vector QuadTree; │ │ │ │ │ -100 │ │ │ │ │ -101 // Internal methods supporting quadtree construction and queries │ │ │ │ │ -102 void assignRootNode(QuadNode * node, int index); │ │ │ │ │ -103 QuadNode * assignLeafOrChildNode(QuadNode * node, bool isLeaf, int quad, │ │ │ │ │ -int index); │ │ │ │ │ -104 │ │ │ │ │ -105 template │ │ │ │ │ -106 static int transformUVToQuadQuadrant(T const & median, T & u, T & v); │ │ │ │ │ -107 template │ │ │ │ │ -108 static int transformUVToTriQuadrant(T const & median, T & u, T & v, bool & │ │ │ │ │ -rotated); │ │ │ │ │ -109 │ │ │ │ │ -110private: │ │ │ │ │ -111 bool _patchesAreTriangular; // tri and quad assembly and search │ │ │ │ │ -requirements differ │ │ │ │ │ -112 │ │ │ │ │ -113 int _minPatchFace; // minimum patch face index supported by the map │ │ │ │ │ -114 int _maxPatchFace; // maximum patch face index supported by the map │ │ │ │ │ -115 int _maxDepth; // maximum depth of a patch in the tree │ │ │ │ │ -116 │ │ │ │ │ -117 std::vector _handles; // all the patches in the PatchTable │ │ │ │ │ -118 std::vector _quadtree; // quadtree nodes │ │ │ │ │ -119}; │ │ │ │ │ -120 │ │ │ │ │ -121// │ │ │ │ │ -122// Given a median value for both U and V, these methods transform a (u,v) │ │ │ │ │ -pair │ │ │ │ │ -123// into the quadrant that contains them and returns the quadrant index. │ │ │ │ │ -124// │ │ │ │ │ -125// Quadrant indexing for tri and quad patches -- consistent with │ │ │ │ │ -PatchParam's │ │ │ │ │ -126// usage of UV bits: │ │ │ │ │ -127// │ │ │ │ │ -128// (0,1) o-----o-----o (1,1) (0,1) o (1,0) o-----o-----o (0,0) │ │ │ │ │ -129// | | | |\ \ 1 |\ 0 | │ │ │ │ │ -130// | 2 | 3 | | \ \ | \ | │ │ │ │ │ -131// | | | | 2 \ \| 3 \| │ │ │ │ │ -132// o-----o-----o o-----o o-----o │ │ │ │ │ -133// | | | |\ 3 |\ \ 2 | │ │ │ │ │ -134// | 0 | 1 | | \ | \ \ | │ │ │ │ │ -135// | | | | 0 \| 1 \ \| │ │ │ │ │ -136// (0,0) o-----o-----o (1,0) (0,0) o-----o-----o (1,0) o (0,1) │ │ │ │ │ -137// │ │ │ │ │ -138// The triangular case also takes and returns/affects the rotation of the │ │ │ │ │ -139// quadrant being searched and identified (quadrant 3 imparts a rotation). │ │ │ │ │ -140// │ │ │ │ │ -141template │ │ │ │ │ -142inline int │ │ │ │ │ -143PatchMap::transformUVToQuadQuadrant(T const & median, T & u, T & v) { │ │ │ │ │ -144 │ │ │ │ │ -145 int uHalf = (u >= median); │ │ │ │ │ -146 if (uHalf) u -= median; │ │ │ │ │ -147 │ │ │ │ │ -148 int vHalf = (v >= median); │ │ │ │ │ -149 if (vHalf) v -= median; │ │ │ │ │ +97 │ │ │ │ │ +99 │ │ │ │ │ +105 │ │ │ │ │ +_1_0_7 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ +108 │ │ │ │ │ +_1_1_0 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ +111 │ │ │ │ │ +_1_1_3 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_P_a_r_a_m(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ +114 │ │ │ │ │ +_1_1_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s(int array, int patch) const; │ │ │ │ │ +117 │ │ │ │ │ +_1_1_9 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_P_a_r_a_m(int array, int patch) const; │ │ │ │ │ +121 │ │ │ │ │ +122 │ │ │ │ │ +124 │ │ │ │ │ +130 │ │ │ │ │ +_1_3_2 int _G_e_t_N_u_m_P_a_t_c_h_A_r_r_a_y_s() const; │ │ │ │ │ +133 │ │ │ │ │ +_1_3_5 int _G_e_t_N_u_m_P_a_t_c_h_e_s(int array) const; │ │ │ │ │ +136 │ │ │ │ │ +_1_3_8 int _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(int array) const; │ │ │ │ │ +139 │ │ │ │ │ +_1_4_1 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_P_a_t_c_h_A_r_r_a_y_D_e_s_c_r_i_p_t_o_r(int array) const; │ │ │ │ │ +142 │ │ │ │ │ +_1_4_4 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_V_e_r_t_i_c_e_s(int array) const; │ │ │ │ │ +145 │ │ │ │ │ +_1_4_7 _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y const _G_e_t_P_a_t_c_h_P_a_r_a_m_s(int array) const; │ │ │ │ │ +149 │ │ │ │ │ 150 │ │ │ │ │ -151 return (vHalf << 1) | uHalf; │ │ │ │ │ -152} │ │ │ │ │ -153 │ │ │ │ │ -154template │ │ │ │ │ -155int inline │ │ │ │ │ -156PatchMap::transformUVToTriQuadrant(T const & median, T & u, T & v, bool & │ │ │ │ │ -rotated) { │ │ │ │ │ -157 │ │ │ │ │ -158 if (!rotated) { │ │ │ │ │ -159 if (u >= median) { │ │ │ │ │ -160 u -= median; │ │ │ │ │ -161 return 1; │ │ │ │ │ -162 } │ │ │ │ │ -163 if (v >= median) { │ │ │ │ │ -164 v -= median; │ │ │ │ │ -165 return 2; │ │ │ │ │ -166 } │ │ │ │ │ -167 if ((u + v) >= median) { │ │ │ │ │ -168 rotated = true; │ │ │ │ │ -169 return 3; │ │ │ │ │ -170 } │ │ │ │ │ -171 return 0; │ │ │ │ │ -172 } else { │ │ │ │ │ -173 if (u < median) { │ │ │ │ │ -174 v -= median; │ │ │ │ │ -175 return 1; │ │ │ │ │ -176 } │ │ │ │ │ -177 if (v < median) { │ │ │ │ │ -178 u -= median; │ │ │ │ │ -179 return 2; │ │ │ │ │ -180 } │ │ │ │ │ -181 u -= median; │ │ │ │ │ -182 v -= median; │ │ │ │ │ -183 if ((u + v) < median) { │ │ │ │ │ -184 rotated = false; │ │ │ │ │ -185 return 3; │ │ │ │ │ -186 } │ │ │ │ │ -187 return 0; │ │ │ │ │ -188 } │ │ │ │ │ -189} │ │ │ │ │ -190 │ │ │ │ │ -192inline _P_a_t_c_h_M_a_p_:_:_H_a_n_d_l_e const * │ │ │ │ │ -_1_9_3_P_a_t_c_h_M_a_p_:_:_F_i_n_d_P_a_t_c_h( int faceid, double u, double v ) const { │ │ │ │ │ -194 │ │ │ │ │ -195 // │ │ │ │ │ -196 // Reject patch faces not supported by this map, or those corresponding │ │ │ │ │ -197 // to holes or otherwise unassigned (the root node for a patch will │ │ │ │ │ -198 // have all or no quadrants set): │ │ │ │ │ -199 // │ │ │ │ │ -200 if ((faceid < _minPatchFace) || (faceid > _maxPatchFace)) return 0; │ │ │ │ │ -201 │ │ │ │ │ -202 QuadNode const * node = &_quadtree[faceid - _minPatchFace]; │ │ │ │ │ +152 │ │ │ │ │ +159 │ │ │ │ │ +_1_6_1 int _G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s() const; │ │ │ │ │ +162 │ │ │ │ │ +164 _S_t_e_n_c_i_l_T_a_b_l_e const *_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ +165 │ │ │ │ │ +167 template │ │ │ │ │ +_1_6_8 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ +169 │ │ │ │ │ +_1_7_2 template bool _L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e() │ │ │ │ │ +const; │ │ │ │ │ +173 │ │ │ │ │ +186 template void │ │ │ │ │ +187 _C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s(T const *src, T *dst) const; │ │ │ │ │ +188 │ │ │ │ │ +189 │ │ │ │ │ +_1_9_1 int _G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_V_a_r_y_i_n_g() const; │ │ │ │ │ +192 │ │ │ │ │ +194 _S_t_e_n_c_i_l_T_a_b_l_e const *_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ +195 │ │ │ │ │ +197 template │ │ │ │ │ +_1_9_8 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const *_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const; │ │ │ │ │ +199 │ │ │ │ │ +_2_0_2 template bool _L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ +() const; │ │ │ │ │ 203 │ │ │ │ │ -204 if (!node->children[0].isSet) return 0; │ │ │ │ │ -205 │ │ │ │ │ -206 // │ │ │ │ │ -207 // Search the tree for the sub-patch containing the given (u,v) │ │ │ │ │ -208 // │ │ │ │ │ -209 assert( (u>=0.0) && (u<=1.0) && (v>=0.0) && (v<=1.0) ); │ │ │ │ │ -210 │ │ │ │ │ -211 double median = 0.5; │ │ │ │ │ -212 bool triRotated = false; │ │ │ │ │ -213 │ │ │ │ │ -214 for (int depth = 0; depth <= _maxDepth; ++depth, median *= 0.5) { │ │ │ │ │ -215 │ │ │ │ │ -216 int quadrant = _patchesAreTriangular │ │ │ │ │ -217 ? transformUVToTriQuadrant(median, u, v, triRotated) │ │ │ │ │ -218 : transformUVToQuadQuadrant(median, u, v); │ │ │ │ │ +216 template void │ │ │ │ │ +217 _C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_V_a_r_y_i_n_g(T const *src, T *dst) const; │ │ │ │ │ +218 │ │ │ │ │ 219 │ │ │ │ │ -220 // holes should have been rejected at the root node of the face │ │ │ │ │ -221 assert(node->children[quadrant].isSet); │ │ │ │ │ +_2_2_1 int _G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_F_a_c_e_V_a_r_y_i_n_g(int channel = 0) const; │ │ │ │ │ 222 │ │ │ │ │ -223 if (node->children[quadrant].isLeaf) { │ │ │ │ │ -224 return &_handles[node->children[quadrant].index]; │ │ │ │ │ -225 } else { │ │ │ │ │ -226 node = &_quadtree[node->children[quadrant].index]; │ │ │ │ │ -227 } │ │ │ │ │ -228 } │ │ │ │ │ -229 assert(0); │ │ │ │ │ -230 return 0; │ │ │ │ │ -231} │ │ │ │ │ -232 │ │ │ │ │ -233} // end namespace Far │ │ │ │ │ -234 │ │ │ │ │ -235} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -236using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -237 │ │ │ │ │ -238} // end namespace OpenSubdiv │ │ │ │ │ -239 │ │ │ │ │ -240#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */ │ │ │ │ │ +224 _S_t_e_n_c_i_l_T_a_b_l_e const *_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int channel = 0) │ │ │ │ │ +const; │ │ │ │ │ +225 │ │ │ │ │ +227 template │ │ │ │ │ +_2_2_8 _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * _G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int │ │ │ │ │ +channel = 0) const; │ │ │ │ │ +229 │ │ │ │ │ +_2_3_2 template bool │ │ │ │ │ +_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e() const; │ │ │ │ │ +233 │ │ │ │ │ +248 template void │ │ │ │ │ +249 _C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_F_a_c_e_V_a_r_y_i_n_g(T const *src, T *dst, int channel = 0) │ │ │ │ │ +const; │ │ │ │ │ +251 │ │ │ │ │ +252 │ │ │ │ │ +254 │ │ │ │ │ +255 │ │ │ │ │ +_2_5_9 typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_u_n_s_i_g_n_e_d_ _i_n_t_> _C_o_n_s_t_Q_u_a_d_O_f_f_s_e_t_s_A_r_r_a_y; │ │ │ │ │ +260 │ │ │ │ │ +_2_6_2 _C_o_n_s_t_Q_u_a_d_O_f_f_s_e_t_s_A_r_r_a_y _G_e_t_P_a_t_c_h_Q_u_a_d_O_f_f_s_e_t_s(_P_a_t_c_h_H_a_n_d_l_e const & handle) │ │ │ │ │ +const; │ │ │ │ │ +263 │ │ │ │ │ +_2_6_4 typedef std::vector _V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e; │ │ │ │ │ +265 │ │ │ │ │ +_2_6_7 _V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e const & _G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e() const { │ │ │ │ │ +268 return _vertexValenceTable; │ │ │ │ │ +269 } │ │ │ │ │ +271 │ │ │ │ │ +272 │ │ │ │ │ +274 │ │ │ │ │ +280 │ │ │ │ │ +_2_8_3 float _G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ +284 │ │ │ │ │ +_2_8_7 float _G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e(int array, int patch) const; │ │ │ │ │ +289 │ │ │ │ │ +290 │ │ │ │ │ +292 │ │ │ │ │ +298 │ │ │ │ │ +_3_0_0 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r() const; │ │ │ │ │ +301 │ │ │ │ │ +_3_0_3 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s(_P_a_t_c_h_H_a_n_d_l_e const & handle) const; │ │ │ │ │ +304 │ │ │ │ │ +_3_0_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s(int array, int patch) const; │ │ │ │ │ +307 │ │ │ │ │ +_3_0_9 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s(int array) const; │ │ │ │ │ +310 │ │ │ │ │ +_3_1_2 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s() const; │ │ │ │ │ +314 │ │ │ │ │ +315 │ │ │ │ │ +317 │ │ │ │ │ +323 │ │ │ │ │ +_3_2_5 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const; │ │ │ │ │ +326 │ │ │ │ │ +_3_2_8 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_R_e_g_u_l_a_r(int channel = 0) const; │ │ │ │ │ +329 │ │ │ │ │ +_3_3_1 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_I_r_r_e_g_u_l_a_r(int channel = 0) const; │ │ │ │ │ +332 │ │ │ │ │ +_3_3_4 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r _G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r(int channel = 0) const; │ │ │ │ │ +335 │ │ │ │ │ +_3_3_7 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, int channel │ │ │ │ │ += 0) const; │ │ │ │ │ +338 │ │ │ │ │ +_3_4_0 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s(int array, int patch, int channel = 0) │ │ │ │ │ +const; │ │ │ │ │ +341 │ │ │ │ │ +_3_4_3 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_V_a_l_u_e_s(int array, int channel = 0) const; │ │ │ │ │ +344 │ │ │ │ │ +_3_4_6 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y _G_e_t_F_V_a_r_V_a_l_u_e_s(int channel = 0) const; │ │ │ │ │ +347 │ │ │ │ │ +_3_4_9 int _G_e_t_F_V_a_r_V_a_l_u_e_S_t_r_i_d_e(int channel = 0) const; │ │ │ │ │ +350 │ │ │ │ │ +_3_5_2 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m(_P_a_t_c_h_H_a_n_d_l_e const & handle, int channel = │ │ │ │ │ +0) const; │ │ │ │ │ +353 │ │ │ │ │ +_3_5_5 _P_a_t_c_h_P_a_r_a_m _G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m(int array, int patch, int channel = 0) │ │ │ │ │ +const; │ │ │ │ │ +356 │ │ │ │ │ +_3_5_8 _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y _G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s(int array, int channel = │ │ │ │ │ +0) const; │ │ │ │ │ +359 │ │ │ │ │ +_3_6_1 _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y _G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s(int channel = 0) const; │ │ │ │ │ +362 │ │ │ │ │ +_3_6_4 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n _G_e_t_F_V_a_r_C_h_a_n_n_e_l_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n(int │ │ │ │ │ +channel = 0) const; │ │ │ │ │ +366 │ │ │ │ │ +367 │ │ │ │ │ +369 │ │ │ │ │ +374 │ │ │ │ │ +_3_7_5 typedef std::vector _P_a_t_c_h_V_e_r_t_s_T_a_b_l_e; │ │ │ │ │ +376 │ │ │ │ │ +_3_7_8 _P_a_t_c_h_V_e_r_t_s_T_a_b_l_e const & _G_e_t_P_a_t_c_h_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_a_b_l_e() const { return │ │ │ │ │ +_patchVerts; } │ │ │ │ │ +379 │ │ │ │ │ +_3_8_1 _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e const & _G_e_t_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e() const { return _paramTable; } │ │ │ │ │ +382 │ │ │ │ │ +_3_8_4 std::vector const &_G_e_t_S_h_a_r_p_n_e_s_s_I_n_d_e_x_T_a_b_l_e() const { return │ │ │ │ │ +_sharpnessIndices; } │ │ │ │ │ +385 │ │ │ │ │ +_3_8_7 std::vector const &_G_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s() const { return │ │ │ │ │ +_sharpnessValues; } │ │ │ │ │ +388 │ │ │ │ │ +_3_8_9 typedef std::vector _Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e; │ │ │ │ │ +390 │ │ │ │ │ +_3_9_2 _Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e const & _G_e_t_Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e() const { │ │ │ │ │ +393 return _quadOffsetsTable; │ │ │ │ │ +394 } │ │ │ │ │ +396 │ │ │ │ │ +_3_9_8 void _p_r_i_n_t() const; │ │ │ │ │ +399 │ │ │ │ │ +400public: │ │ │ │ │ +401 │ │ │ │ │ +403 │ │ │ │ │ +405 │ │ │ │ │ +428 template │ │ │ │ │ +_4_2_9 void _E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, REAL u, REAL v, │ │ │ │ │ +430 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0, │ │ │ │ │ +431 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const; │ │ │ │ │ +432 │ │ │ │ │ +435 void _E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ +436 float wP[], float wDu[] = 0, float wDv[] = 0, │ │ │ │ │ +437 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const; │ │ │ │ │ +438 │ │ │ │ │ +441 void _E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double v, │ │ │ │ │ +442 double wP[], double wDu[] = 0, double wDv[] = 0, │ │ │ │ │ +443 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const; │ │ │ │ │ +444 │ │ │ │ │ +467 template │ │ │ │ │ +_4_6_8 void _E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, REAL u, REAL v, │ │ │ │ │ +469 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0, │ │ │ │ │ +470 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0) const; │ │ │ │ │ +471 │ │ │ │ │ +474 void _E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ +475 float wP[], float wDu[] = 0, float wDv[] = 0, │ │ │ │ │ +476 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0) const; │ │ │ │ │ +477 │ │ │ │ │ +480 void _E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double v, │ │ │ │ │ +481 double wP[], double wDu[] = 0, double wDv[] = 0, │ │ │ │ │ +482 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0) const; │ │ │ │ │ +483 │ │ │ │ │ +508 template │ │ │ │ │ +_5_0_9 void _E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, REAL u, REAL v, │ │ │ │ │ +510 REAL wP[], REAL wDu[] = 0, REAL wDv[] = 0, │ │ │ │ │ +511 REAL wDuu[] = 0, REAL wDuv[] = 0, REAL wDvv[] = 0, │ │ │ │ │ +512 int channel = 0) const; │ │ │ │ │ +513 │ │ │ │ │ +516 void _E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ +517 float wP[], float wDu[] = 0, float wDv[] = 0, │ │ │ │ │ +518 float wDuu[] = 0, float wDuv[] = 0, float wDvv[] = 0, │ │ │ │ │ +519 int channel = 0) const; │ │ │ │ │ +520 │ │ │ │ │ +523 void _E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double │ │ │ │ │ +v, │ │ │ │ │ +524 double wP[], double wDu[] = 0, double wDv[] = 0, │ │ │ │ │ +525 double wDuu[] = 0, double wDuv[] = 0, double wDvv[] = 0, │ │ │ │ │ +526 int channel = 0) const; │ │ │ │ │ +528 │ │ │ │ │ +529protected: │ │ │ │ │ +530 │ │ │ │ │ +_5_3_1 friend class _P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r; │ │ │ │ │ +532 │ │ │ │ │ +533 // Factory constructor │ │ │ │ │ +_5_3_4 _P_a_t_c_h_T_a_b_l_e(int maxvalence); │ │ │ │ │ +535 │ │ │ │ │ +_5_3_6 _I_n_d_e_x _g_e_t_P_a_t_c_h_I_n_d_e_x(int array, int patch) const; │ │ │ │ │ +537 │ │ │ │ │ +_5_3_8 _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y _g_e_t_P_a_t_c_h_P_a_r_a_m_s(int arrayIndex); │ │ │ │ │ +539 │ │ │ │ │ +_5_4_0 _I_n_d_e_x * _g_e_t_S_h_a_r_p_n_e_s_s_I_n_d_i_c_e_s(_I_n_d_e_x arrayIndex); │ │ │ │ │ +_5_4_1 float * _g_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s(_I_n_d_e_x arrayIndex); │ │ │ │ │ +542 │ │ │ │ │ +543private: │ │ │ │ │ +544 │ │ │ │ │ +545 // │ │ │ │ │ +546 // Patch arrays │ │ │ │ │ +547 // │ │ │ │ │ +548 struct PatchArray { │ │ │ │ │ +549 PatchArray(_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r d, int np, _I_n_d_e_x v, _I_n_d_e_x p, _I_n_d_e_x qo) : │ │ │ │ │ +550 desc(d), numPatches(np), vertIndex(v), │ │ │ │ │ +551 patchIndex(p), quadOffsetIndex (qo) { } │ │ │ │ │ +552 │ │ │ │ │ +553 void print() const; │ │ │ │ │ +554 │ │ │ │ │ +555 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r desc; // type of patches in the array │ │ │ │ │ +556 │ │ │ │ │ +557 int numPatches; // number of patches in the array │ │ │ │ │ +558 │ │ │ │ │ +559 _I_n_d_e_x vertIndex, // index to the first control vertex │ │ │ │ │ +560 patchIndex, // absolute index of the first patch in the array │ │ │ │ │ +561 quadOffsetIndex; // index of the first quad offset entry │ │ │ │ │ +562 }; │ │ │ │ │ +563 │ │ │ │ │ +564 typedef std::vector PatchArrayVector; │ │ │ │ │ +565 │ │ │ │ │ +566 PatchArray & getPatchArray(_I_n_d_e_x arrayIndex); │ │ │ │ │ +567 PatchArray const & getPatchArray(_I_n_d_e_x arrayIndex) const; │ │ │ │ │ +568 │ │ │ │ │ +569 void reservePatchArrays(int numPatchArrays); │ │ │ │ │ +570 void pushPatchArray(PatchDescriptor desc, int npatches, │ │ │ │ │ +571 _I_n_d_e_x * vidx, _I_n_d_e_x * pidx, _I_n_d_e_x * qoidx=0); │ │ │ │ │ +572 │ │ │ │ │ +573 _I_n_d_e_x_A_r_r_a_y getPatchArrayVertices(int arrayIndex); │ │ │ │ │ +574 │ │ │ │ │ +575 _I_n_d_e_x findPatchArray(PatchDescriptor desc); │ │ │ │ │ +576 │ │ │ │ │ +577 │ │ │ │ │ +578 // │ │ │ │ │ +579 // Varying patch arrays │ │ │ │ │ +580 // │ │ │ │ │ +581 _I_n_d_e_x_A_r_r_a_y getPatchArrayVaryingVertices(int arrayIndex); │ │ │ │ │ +582 │ │ │ │ │ +583 void allocateVaryingVertices( │ │ │ │ │ +584 PatchDescriptor desc, int numPatches); │ │ │ │ │ +585 void populateVaryingVertices(); │ │ │ │ │ +586 │ │ │ │ │ +587 // │ │ │ │ │ +588 // Face-varying patch channels │ │ │ │ │ +589 // │ │ │ │ │ +590 │ │ │ │ │ +591 // │ │ │ │ │ +592 // FVarPatchChannel │ │ │ │ │ +593 // │ │ │ │ │ +594 // Stores a record for each patch in the primitive : │ │ │ │ │ +595 // │ │ │ │ │ +596 // - Each patch in the PatchTable has a corresponding patch in each │ │ │ │ │ +597 // face-varying patch channel. Patch vertex indices are sorted in the same │ │ │ │ │ +598 // patch-type order as PatchTable::PTables. Face-varying data for a patch │ │ │ │ │ +599 // can therefore be quickly accessed by using the patch primitive ID as │ │ │ │ │ +600 // index into patchValueOffsets to locate the face-varying control vertex │ │ │ │ │ +601 // indices. │ │ │ │ │ +602 // │ │ │ │ │ +603 // - Face-varying channels can have a different interpolation modes │ │ │ │ │ +604 // │ │ │ │ │ +605 // - Unlike "vertex" patches, there are no transition masks required │ │ │ │ │ +606 // for face-varying patches. │ │ │ │ │ +607 // │ │ │ │ │ +608 // - Face-varying patches still require boundary edge masks. │ │ │ │ │ +609 // │ │ │ │ │ +610 // - currently most patches with sharp boundaries but smooth interiors have │ │ │ │ │ +611 // to be isolated to level 10 : we need a special type of bicubic patch │ │ │ │ │ +612 // similar to single-crease to resolve this condition without requiring │ │ │ │ │ +613 // isolation if possible │ │ │ │ │ +614 // │ │ │ │ │ +615 struct FVarPatchChannel { │ │ │ │ │ +616 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n interpolation; │ │ │ │ │ +617 │ │ │ │ │ +618 PatchDescriptor regDesc; │ │ │ │ │ +619 PatchDescriptor irregDesc; │ │ │ │ │ +620 │ │ │ │ │ +621 int stride; │ │ │ │ │ +622 │ │ │ │ │ +623 std::vector patchValues; │ │ │ │ │ +624 std::vector patchParam; │ │ │ │ │ +625 }; │ │ │ │ │ +626 typedef std::vector FVarPatchChannelVector; │ │ │ │ │ +627 │ │ │ │ │ +628 FVarPatchChannel & getFVarPatchChannel(int channel); │ │ │ │ │ +629 FVarPatchChannel const & getFVarPatchChannel(int channel) const; │ │ │ │ │ +630 │ │ │ │ │ +631 void allocateFVarPatchChannels(int numChannels); │ │ │ │ │ +632 void allocateFVarPatchChannelValues( │ │ │ │ │ +633 PatchDescriptor regDesc, PatchDescriptor irregDesc, │ │ │ │ │ +634 int numPatches, int channel); │ │ │ │ │ +635 │ │ │ │ │ +636 // deprecated │ │ │ │ │ +637 void setFVarPatchChannelLinearInterpolation( │ │ │ │ │ +638 _S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n interpolation, int channel); │ │ │ │ │ +639 │ │ │ │ │ +640 _I_n_d_e_x_A_r_r_a_y getFVarValues(int channel); │ │ │ │ │ +641 _C_o_n_s_t_I_n_d_e_x_A_r_r_a_y getPatchFVarValues(int patch, int channel) const; │ │ │ │ │ +642 │ │ │ │ │ +643 _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y getFVarPatchParams(int channel); │ │ │ │ │ +644 PatchParam getPatchFVarPatchParam(int patch, int channel) const; │ │ │ │ │ +645 │ │ │ │ │ +646private: │ │ │ │ │ +647 // │ │ │ │ │ +648 // Simple private class to hold stencil table pointers of varying │ │ │ │ │ +precision, │ │ │ │ │ +649 // where the discriminant of the precision is external. │ │ │ │ │ +650 // │ │ │ │ │ +651 // NOTE that this is a simple pointer container and NOT a smart pointer │ │ │ │ │ +that │ │ │ │ │ +652 // manages the ownership of the object referred to by it. │ │ │ │ │ +653 // │ │ │ │ │ +654 class StencilTablePtr { │ │ │ │ │ +655 private: │ │ │ │ │ +656 typedef StencilTableReal float_type; │ │ │ │ │ +657 typedef StencilTableReal double_type; │ │ │ │ │ +658 │ │ │ │ │ +659 union { │ │ │ │ │ +660 float_type * _fPtr; │ │ │ │ │ +661 double_type * _dPtr; │ │ │ │ │ +662 }; │ │ │ │ │ +663 │ │ │ │ │ +664 public: │ │ │ │ │ +665 StencilTablePtr() { _fPtr = 0; } │ │ │ │ │ +666 StencilTablePtr(float_type * ptr) { _fPtr = ptr; } │ │ │ │ │ +667 StencilTablePtr(double_type * ptr) { _dPtr = ptr; } │ │ │ │ │ +668 │ │ │ │ │ +669 operator bool() const { return _fPtr != 0; } │ │ │ │ │ +670 │ │ │ │ │ +671 void Set() { _fPtr = 0; } │ │ │ │ │ +672 void Set(float_type * ptr) { _fPtr = ptr; } │ │ │ │ │ +673 void Set(double_type * ptr) { _dPtr = ptr; } │ │ │ │ │ +674 │ │ │ │ │ +675 template StencilTableReal * Get() const; │ │ │ │ │ +676 }; │ │ │ │ │ +677 │ │ │ │ │ +678private: │ │ │ │ │ +679 │ │ │ │ │ +680 // │ │ │ │ │ +681 // Topology │ │ │ │ │ +682 // │ │ │ │ │ +683 │ │ │ │ │ +684 int _maxValence, // highest vertex valence found in the mesh │ │ │ │ │ +685 _numPtexFaces; // total number of ptex faces │ │ │ │ │ +686 │ │ │ │ │ +687 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r _patchArrays; // Vector of descriptors for arrays of │ │ │ │ │ +patches │ │ │ │ │ +688 │ │ │ │ │ +689 std::vector _patchVerts; // Indices of the control vertices of the │ │ │ │ │ +patches │ │ │ │ │ +690 │ │ │ │ │ +691 _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e _paramTable; // PatchParam bitfields (one per patch) │ │ │ │ │ +692 │ │ │ │ │ +693 // │ │ │ │ │ +694 // Extraordinary vertex closed-form evaluation / endcap basis conversion │ │ │ │ │ +695 // │ │ │ │ │ +696 // XXXtakahito: these data will probably be replaced with mask coefficient │ │ │ │ │ +or something │ │ │ │ │ +697 // SchemeWorker populates. │ │ │ │ │ +698 // │ │ │ │ │ +699 _Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e _quadOffsetsTable; // Quad offsets (for Gregory patches) │ │ │ │ │ +700 _V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e _vertexValenceTable; // Vertex valence table (for │ │ │ │ │ +Gregory patches) │ │ │ │ │ +701 │ │ │ │ │ +702 StencilTablePtr _localPointStencils; // local point conversion stencils │ │ │ │ │ +703 StencilTablePtr _localPointVaryingStencils; // local point varying stencils │ │ │ │ │ +704 │ │ │ │ │ +705 // │ │ │ │ │ +706 // Varying data │ │ │ │ │ +707 // │ │ │ │ │ +708 PatchDescriptor _varyingDesc; │ │ │ │ │ +709 │ │ │ │ │ +710 std::vector _varyingVerts; │ │ │ │ │ +711 │ │ │ │ │ +712 // │ │ │ │ │ +713 // Face-varying data │ │ │ │ │ +714 // │ │ │ │ │ +715 FVarPatchChannelVector _fvarChannels; │ │ │ │ │ +716 │ │ │ │ │ +717 std::vector _localPointFaceVaryingStencils; │ │ │ │ │ +718 │ │ │ │ │ +719 // │ │ │ │ │ +720 // 'single-crease' patch sharpness tables │ │ │ │ │ +721 // │ │ │ │ │ +722 std::vector _sharpnessIndices; // Indices of single-crease sharpness │ │ │ │ │ +(one per patch) │ │ │ │ │ +723 std::vector _sharpnessValues; // Sharpness values. │ │ │ │ │ +724 │ │ │ │ │ +725 // │ │ │ │ │ +726 // Construction history -- relevant to at least one public query: │ │ │ │ │ +727 // │ │ │ │ │ +728 unsigned int _isUniformLinear : 1; │ │ │ │ │ +729 │ │ │ │ │ +730 // │ │ │ │ │ +731 // Precision -- only applies to local-point stencil tables │ │ │ │ │ +732 // │ │ │ │ │ +733 unsigned int _vertexPrecisionIsDouble : 1; │ │ │ │ │ +734 unsigned int _varyingPrecisionIsDouble : 1; │ │ │ │ │ +735 unsigned int _faceVaryingPrecisionIsDouble : 1; │ │ │ │ │ +736}; │ │ │ │ │ +737 │ │ │ │ │ +738 │ │ │ │ │ +739// │ │ │ │ │ +740// Template specializations for float/double -- to be defined before used: │ │ │ │ │ +741// │ │ │ │ │ +742template <> inline StencilTableReal * │ │ │ │ │ +743PatchTable::StencilTablePtr::Get() const { return _fPtr; } │ │ │ │ │ +744 │ │ │ │ │ +745template <> inline StencilTableReal * │ │ │ │ │ +746PatchTable::StencilTablePtr::Get() const { return _dPtr; } │ │ │ │ │ +747 │ │ │ │ │ +_7_4_8template <> inline bool │ │ │ │ │ +749PatchTable::LocalPointStencilPrecisionMatchesType() const { │ │ │ │ │ +750 return !_vertexPrecisionIsDouble; │ │ │ │ │ +751} │ │ │ │ │ +_7_5_2template <> inline bool │ │ │ │ │ +753PatchTable::LocalPointVaryingStencilPrecisionMatchesType() const { │ │ │ │ │ +754 return !_varyingPrecisionIsDouble; │ │ │ │ │ +755} │ │ │ │ │ +_7_5_6template <> inline bool │ │ │ │ │ +757PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType() const │ │ │ │ │ +{ │ │ │ │ │ +758 return !_faceVaryingPrecisionIsDouble; │ │ │ │ │ +759} │ │ │ │ │ +760 │ │ │ │ │ +_7_6_1template <> inline bool │ │ │ │ │ +762PatchTable::LocalPointStencilPrecisionMatchesType() const { │ │ │ │ │ +763 return _vertexPrecisionIsDouble; │ │ │ │ │ +764} │ │ │ │ │ +_7_6_5template <> inline bool │ │ │ │ │ +766PatchTable::LocalPointVaryingStencilPrecisionMatchesType() const { │ │ │ │ │ +767 return _varyingPrecisionIsDouble; │ │ │ │ │ +768} │ │ │ │ │ +_7_6_9template <> inline bool │ │ │ │ │ +770PatchTable::LocalPointFaceVaryingStencilPrecisionMatchesType() const │ │ │ │ │ +{ │ │ │ │ │ +771 return _faceVaryingPrecisionIsDouble; │ │ │ │ │ +772} │ │ │ │ │ +773 │ │ │ │ │ +774// │ │ │ │ │ +775// StencilTable access -- backward compatible and generic: │ │ │ │ │ +776// │ │ │ │ │ +777inline _S_t_e_n_c_i_l_T_a_b_l_e const * │ │ │ │ │ +_7_7_8_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ +779 assert(LocalPointStencilPrecisionMatchesType()); │ │ │ │ │ +780 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>(_localPointStencils.Get()); │ │ │ │ │ +781} │ │ │ │ │ +782inline _S_t_e_n_c_i_l_T_a_b_l_e const * │ │ │ │ │ +_7_8_3_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ +784 assert(LocalPointVaryingStencilPrecisionMatchesType()); │ │ │ │ │ +785 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +786 _localPointVaryingStencils.Get()); │ │ │ │ │ +787} │ │ │ │ │ +788inline _S_t_e_n_c_i_l_T_a_b_l_e const * │ │ │ │ │ +_7_8_9_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int channel) const { │ │ │ │ │ +790 assert(LocalPointFaceVaryingStencilPrecisionMatchesType()); │ │ │ │ │ +791 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) { │ │ │ │ │ +792 return static_cast<_S_t_e_n_c_i_l_T_a_b_l_e const *>( │ │ │ │ │ +793 _localPointFaceVaryingStencils[channel].Get()); │ │ │ │ │ +794 } │ │ │ │ │ +795 return NULL; │ │ │ │ │ +796} │ │ │ │ │ +797 │ │ │ │ │ +798template │ │ │ │ │ +799inline _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ +_8_0_0_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ +801 assert(LocalPointStencilPrecisionMatchesType()); │ │ │ │ │ +802 return _localPointStencils.Get(); │ │ │ │ │ +803} │ │ │ │ │ +804template │ │ │ │ │ +805inline _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ +_8_0_6_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e() const { │ │ │ │ │ +807 assert(LocalPointVaryingStencilPrecisionMatchesType()); │ │ │ │ │ +808 return _localPointVaryingStencils.Get(); │ │ │ │ │ +809} │ │ │ │ │ +810template │ │ │ │ │ +811inline _S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l_<_R_E_A_L_> const * │ │ │ │ │ +_8_1_2_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e(int channel) const { │ │ │ │ │ +813 assert(LocalPointFaceVaryingStencilPrecisionMatchesType()); │ │ │ │ │ +814 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) { │ │ │ │ │ +815 return _localPointFaceVaryingStencils[channel].Get(); │ │ │ │ │ +816 } │ │ │ │ │ +817 return NULL; │ │ │ │ │ +818} │ │ │ │ │ +819 │ │ │ │ │ +820 │ │ │ │ │ +821// │ │ │ │ │ +822// Computation of local point values: │ │ │ │ │ +823// │ │ │ │ │ +824template │ │ │ │ │ +825inline void │ │ │ │ │ +_8_2_6_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s(T const *src, T *dst) const { │ │ │ │ │ +827 assert(LocalPointStencilPrecisionMatchesType()); │ │ │ │ │ +828 if (_localPointStencils) { │ │ │ │ │ +829 _localPointStencils.Get()->UpdateValues(src, dst); │ │ │ │ │ +830 } │ │ │ │ │ +831} │ │ │ │ │ +832 │ │ │ │ │ +833template │ │ │ │ │ +834inline void │ │ │ │ │ +_8_3_5_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_V_a_r_y_i_n_g(T const *src, T *dst) const { │ │ │ │ │ +836 assert(LocalPointVaryingStencilPrecisionMatchesType()); │ │ │ │ │ +837 if (_localPointVaryingStencils) { │ │ │ │ │ +838 _localPointVaryingStencils.Get()->UpdateValues(src, dst); │ │ │ │ │ +839 } │ │ │ │ │ +840} │ │ │ │ │ +841 │ │ │ │ │ +842template │ │ │ │ │ +843inline void │ │ │ │ │ +_8_4_4_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_F_a_c_e_V_a_r_y_i_n_g(T const *src, T *dst, int │ │ │ │ │ +channel) const { │ │ │ │ │ +845 assert(LocalPointFaceVaryingStencilPrecisionMatchesType()); │ │ │ │ │ +846 if (channel >= 0 && channel < (int)_localPointFaceVaryingStencils.size()) { │ │ │ │ │ +847 if (_localPointFaceVaryingStencils[channel]) { │ │ │ │ │ +848 _localPointFaceVaryingStencils[channel].Get()->UpdateValues(src, │ │ │ │ │ +dst); │ │ │ │ │ +849 } │ │ │ │ │ +850 } │ │ │ │ │ +851} │ │ │ │ │ +852 │ │ │ │ │ +853 │ │ │ │ │ +854// │ │ │ │ │ +855// Basis evaluation overloads │ │ │ │ │ +856// │ │ │ │ │ +857inline void │ │ │ │ │ +_8_5_8_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float v, │ │ │ │ │ +859 float wP[], float wDu[], float wDv[], │ │ │ │ │ +860 float wDuu[], float wDuv[], float wDvv[]) const { │ │ │ │ │ +861 │ │ │ │ │ +862 EvaluateBasis(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ +863} │ │ │ │ │ +864inline void │ │ │ │ │ +_8_6_5_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, double v, │ │ │ │ │ +866 double wP[], double wDu[], double wDv[], │ │ │ │ │ +867 double wDuu[], double wDuv[], double wDvv[]) const { │ │ │ │ │ +868 │ │ │ │ │ +869 EvaluateBasis(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ +870} │ │ │ │ │ +871 │ │ │ │ │ +872inline void │ │ │ │ │ +_8_7_3_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, float │ │ │ │ │ +v, │ │ │ │ │ +874 float wP[], float wDu[], float wDv[], │ │ │ │ │ +875 float wDuu[], float wDuv[], float wDvv[]) const { │ │ │ │ │ +876 │ │ │ │ │ +877 EvaluateBasisVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ +878} │ │ │ │ │ +879inline void │ │ │ │ │ +_8_8_0_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, │ │ │ │ │ +double v, │ │ │ │ │ +881 double wP[], double wDu[], double wDv[], │ │ │ │ │ +882 double wDuu[], double wDuv[], double wDvv[]) const { │ │ │ │ │ +883 │ │ │ │ │ +884 EvaluateBasisVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, wDvv); │ │ │ │ │ +885} │ │ │ │ │ +886 │ │ │ │ │ +887inline void │ │ │ │ │ +_8_8_8_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, float u, │ │ │ │ │ +float v, │ │ │ │ │ +889 float wP[], float wDu[], float wDv[], │ │ │ │ │ +890 float wDuu[], float wDuv[], float wDvv[], int channel) const { │ │ │ │ │ +891 │ │ │ │ │ +892 EvaluateBasisFaceVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, │ │ │ │ │ +wDvv, channel); │ │ │ │ │ +893} │ │ │ │ │ +894inline void │ │ │ │ │ +_8_9_5_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g(_P_a_t_c_h_H_a_n_d_l_e const & handle, double u, │ │ │ │ │ +double v, │ │ │ │ │ +896 double wP[], double wDu[], double wDv[], │ │ │ │ │ +897 double wDuu[], double wDuv[], double wDvv[], int channel) const { │ │ │ │ │ +898 │ │ │ │ │ +899 EvaluateBasisFaceVarying(handle, u, v, wP, wDu, wDv, wDuu, wDuv, │ │ │ │ │ +wDvv, channel); │ │ │ │ │ +900} │ │ │ │ │ +901 │ │ │ │ │ +902} // end namespace Far │ │ │ │ │ +903 │ │ │ │ │ +904} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +905using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +906 │ │ │ │ │ +907} // end namespace OpenSubdiv │ │ │ │ │ +908 │ │ │ │ │ +909#endif /* OPENSUBDIV3_FAR_PATCH_TABLE */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +Vtr::ConstIndexArray ConstIndexArray │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ +std::vector< PatchParam > PatchParamTable │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x_A_r_r_a_y │ │ │ │ │ +Vtr::IndexArray IndexArray │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ +Vtr::Index Index │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ +Vtr::Array< PatchParam > PatchParamArray │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r │ │ │ │ │ +std::vector< PatchArray > PatchArrayVector │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +Describes the type of a patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_4 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p │ │ │ │ │ An quadtree-based map connecting coarse faces to their sub-patches. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_P_a_t_c_h_M_a_p │ │ │ │ │ -PatchMap(PatchTable const &patchTable) │ │ │ │ │ -Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_F_i_n_d_P_a_t_c_h │ │ │ │ │ -Handle const * FindPatch(int patchFaceId, double u, double v) const │ │ │ │ │ -Returns a handle to the sub-patch of the face at the given (u,v). Note that the │ │ │ │ │ -patch face ID corresp... │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_1_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_H_a_n_d_l_e │ │ │ │ │ -PatchTable::PatchHandle Handle │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d_:_:_i_s_L_e_a_f │ │ │ │ │ -unsigned int isLeaf │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d_:_:_i_n_d_e_x │ │ │ │ │ -unsigned int index │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_M_a_p_:_:_Q_u_a_d_N_o_d_e_:_:_C_h_i_l_d_:_:_i_s_S_e_t │ │ │ │ │ -unsigned int isSet │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_M_a_p_._h_:_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +Patch parameterization. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_5_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ Container for arrays of parametric patches. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetPatchArrayVaryingVertices(int array) const │ │ │ │ │ +Returns the varying vertex indices for the patches in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s │ │ │ │ │ +float * getSharpnessValues(Index arrayIndex) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_a_b_l_e │ │ │ │ │ +PatchVertsTable const & GetPatchControlVerticesTable() const │ │ │ │ │ +Get the table of patch control vertices. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +void ComputeLocalPointValuesFaceVarying(T const *src, T *dst, int channel=0) │ │ │ │ │ +const │ │ │ │ │ +Updates local point face-varying values. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetVaryingVertices() const │ │ │ │ │ +Returns an array of varying vertex indices for the patches. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s_V_a_r_y_i_n_g │ │ │ │ │ +void ComputeLocalPointValuesVarying(T const *src, T *dst) const │ │ │ │ │ +Updates local point varying values. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_3_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetPatchVaryingVertices(PatchHandle const &handle) const │ │ │ │ │ +Returns the varying vertex indices for a given patch. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_I_s_F_e_a_t_u_r_e_A_d_a_p_t_i_v_e │ │ │ │ │ +bool IsFeatureAdaptive() const │ │ │ │ │ +True if the patches are of feature adaptive types. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_M_a_x_V_a_l_e_n_c_e │ │ │ │ │ +int GetMaxValence() const │ │ │ │ │ +Returns max vertex valence. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTableReal< REAL > const * GetLocalPointStencilTable() const │ │ │ │ │ +Returns the stencil table to compute local point vertex values. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTable const * GetLocalPointStencilTable() const │ │ │ │ │ +Returns the stencil table to compute local point vertex values. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_7_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ +PatchParamArray getPatchParams(int arrayIndex) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +ConstIndexArray GetPatchArrayFVarValues(int array, int channel=0) const │ │ │ │ │ +Returns the value indices for the patches in array in channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_S_h_a_r_p_n_e_s_s_V_a_l_u_e_s │ │ │ │ │ +std::vector< float > const & GetSharpnessValues() const │ │ │ │ │ +Returns sharpness values table. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e │ │ │ │ │ +std::vector< Index > VertexValenceTable │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_2_6_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +PatchParam GetPatchFVarPatchParam(int array, int patch, int channel=0) const │ │ │ │ │ +Returns the face-varying params for a given patch channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_a_r_y_i_n_g_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetPatchVaryingVertices(int array, int patch) const │ │ │ │ │ +Returns the varying vertex indices for a given patch. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +PatchTable(PatchTable const &src) │ │ │ │ │ +Copy constructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +int GetNumPatchArrays() const │ │ │ │ │ +Returns the number of patch arrays in the table. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetPatchVertices(PatchHandle const &handle) const │ │ │ │ │ +Returns the control vertex indices for the patch identified by handle. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +PatchTable(int maxvalence) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ +bool LocalPointFaceVaryingStencilPrecisionMatchesType() const │ │ │ │ │ +Tests if the precision of the stencil table to compute local point face-varying │ │ │ │ │ +values matches the gi... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ +PatchParamTable const & GetPatchParamTable() const │ │ │ │ │ +Returns the PatchParamTable (PatchParams order matches patch array sorting) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_T_a_b_l_e │ │ │ │ │ +VertexValenceTable const & GetVertexValenceTable() const │ │ │ │ │ +Returns the 'VertexValences' table (vertex neighborhoods table) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_2_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTable const * GetLocalPointFaceVaryingStencilTable(int channel=0) const │ │ │ │ │ +Returns the stencil table to compute local point face-varying values. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_7_8_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ +int GetNumControlVertices(int array) const │ │ │ │ │ +Returns the number of control vertices in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_~_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +~PatchTable() │ │ │ │ │ +Destructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +void EvaluateBasisFaceVarying(PatchHandle const &handle, REAL u, REAL v, REAL │ │ │ │ │ +wP[], REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0, │ │ │ │ │ +int channel=0) const │ │ │ │ │ +Evaluate basis functions for a face-varying value and derivatives at a given │ │ │ │ │ +(u,v) parametric locatio... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_Q_u_a_d_O_f_f_s_e_t_s │ │ │ │ │ +ConstQuadOffsetsArray GetPatchQuadOffsets(PatchHandle const &handle) const │ │ │ │ │ +Returns the 'QuadOffsets' for the Gregory patch identified by handle. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_I_r_r_e_g_u_l_a_r │ │ │ │ │ +PatchDescriptor GetFVarPatchDescriptorIrregular(int channel=0) const │ │ │ │ │ +Returns the irregular patch descriptor for channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e │ │ │ │ │ +float GetSingleCreasePatchSharpnessValue(int array, int patch) const │ │ │ │ │ +Returns the crease sharpness for the patch in array if it is a single-crease │ │ │ │ │ +patch,... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_S_h_a_r_p_n_e_s_s_I_n_d_i_c_e_s │ │ │ │ │ +Index * getSharpnessIndices(Index arrayIndex) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_C_o_m_p_u_t_e_L_o_c_a_l_P_o_i_n_t_V_a_l_u_e_s │ │ │ │ │ +void ComputeLocalPointValues(T const *src, T *dst) const │ │ │ │ │ +Updates local point vertex values. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_2_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_S_i_n_g_l_e_C_r_e_a_s_e_P_a_t_c_h_S_h_a_r_p_n_e_s_s_V_a_l_u_e │ │ │ │ │ +float GetSingleCreasePatchSharpnessValue(PatchHandle const &handle) const │ │ │ │ │ +Returns the crease sharpness for the patch identified by handle if it is a │ │ │ │ │ +single-crease patch,... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +PatchParam GetPatchParam(int array, int patch) const │ │ │ │ │ +Returns the PatchParam for patch in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +ConstIndexArray GetPatchFVarValues(int array, int patch, int channel=0) const │ │ │ │ │ +Returns the value indices for a given patch in channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_R_e_g_u_l_a_r │ │ │ │ │ +PatchDescriptor GetFVarPatchDescriptorRegular(int channel=0) const │ │ │ │ │ +Returns the regular patch descriptor for channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor GetPatchDescriptor(PatchHandle const &handle) const │ │ │ │ │ +Returns the PatchDescriptor for the patch identified by handle. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_V_e_r_t_s_T_a_b_l_e │ │ │ │ │ +std::vector< Index > PatchVertsTable │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e │ │ │ │ │ +QuadOffsetsTable const & GetQuadOffsetsTable() const │ │ │ │ │ +Returns the quad-offsets table. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_a_t_c_h_e_s │ │ │ │ │ +int GetNumPatches(int array) const │ │ │ │ │ +Returns the number of patches in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor GetVaryingPatchDescriptor() const │ │ │ │ │ +Returns the varying patch descriptor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +ConstIndexArray GetPatchFVarValues(PatchHandle const &handle, int channel=0) │ │ │ │ │ +const │ │ │ │ │ +Returns the value indices for a given patch in channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ +ConstPatchParamArray const GetPatchParams(int array) const │ │ │ │ │ +Returns the PatchParams for the patches in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s_T_o_t_a_l │ │ │ │ │ +int GetNumControlVerticesTotal() const │ │ │ │ │ +Returns the total number of control vertex indices in the table. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +int GetNumFVarChannels() const │ │ │ │ │ +Returns the number of face-varying channels. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ +ConstPatchParamArray GetPatchArrayFVarPatchParams(int array, int channel=0) │ │ │ │ │ +const │ │ │ │ │ +Returns the face-varying for a given patch in array in channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_g_e_t_P_a_t_c_h_I_n_d_e_x │ │ │ │ │ +Index getPatchIndex(int array, int patch) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s │ │ │ │ │ +int GetNumLocalPoints() const │ │ │ │ │ +Returns the number of local vertex points. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ +bool LocalPointVaryingStencilPrecisionMatchesType() const │ │ │ │ │ +Tests if the precision of the stencil table to compute local point varying │ │ │ │ │ +values matches the given f... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetPatchArrayVertices(int array) const │ │ │ │ │ +Returns the control vertex indices for the patches in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_t_e_x_F_a_c_e_s │ │ │ │ │ +int GetNumPtexFaces() const │ │ │ │ │ +Returns the total number of ptex faces in the mesh. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_9_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_V_a_l_u_e_s │ │ │ │ │ +ConstIndexArray GetFVarValues(int channel=0) const │ │ │ │ │ +Returns an array of value indices for the patches in channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_C_o_n_s_t_Q_u_a_d_O_f_f_s_e_t_s_A_r_r_a_y │ │ │ │ │ +Vtr::ConstArray< unsigned int > ConstQuadOffsetsArray │ │ │ │ │ +Accessors for the gregory patch evaluation buffers. These methods will be │ │ │ │ │ +deprecated. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_2_5_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s │ │ │ │ │ +void EvaluateBasis(PatchHandle const &handle, REAL u, REAL v, REAL wP[], REAL │ │ │ │ │ +wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const │ │ │ │ │ +Evaluate basis functions for position and derivatives at a given (u,v) │ │ │ │ │ +parametric location of a patch... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_L_o_c_a_l_P_o_i_n_t_F_a_c_e_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTableReal< REAL > const * GetLocalPointFaceVaryingStencilTable(int │ │ │ │ │ +channel=0) const │ │ │ │ │ +Returns the stencil table to compute local point face-varying values. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_P_a_t_c_h_e_s_T_o_t_a_l │ │ │ │ │ +int GetNumPatchesTotal() const │ │ │ │ │ +Returns the total number of patches stored in the table. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +PatchParam GetPatchParam(PatchHandle const &handle) const │ │ │ │ │ +Returns a PatchParam for the patch identified by handle. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_p_r_i_n_t │ │ │ │ │ +void print() const │ │ │ │ │ +debug helper │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_F_V_a_r_C_h_a_n_n_e_l_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ +Sdc::Options::FVarLinearInterpolation GetFVarChannelLinearInterpolation(int │ │ │ │ │ +channel=0) const │ │ │ │ │ +Deprecated. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_S_h_a_r_p_n_e_s_s_I_n_d_e_x_T_a_b_l_e │ │ │ │ │ +std::vector< Index > const & GetSharpnessIndexTable() const │ │ │ │ │ +Returns a sharpness index table for each patch (if exists) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor GetPatchArrayDescriptor(int array) const │ │ │ │ │ +Returns the PatchDescriptor for the patches in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_T_a_b_l_e_B_u_i_l_d_e_r │ │ │ │ │ +friend class PatchTableBuilder │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_E_v_a_l_u_a_t_e_B_a_s_i_s_V_a_r_y_i_n_g │ │ │ │ │ +void EvaluateBasisVarying(PatchHandle const &handle, REAL u, REAL v, REAL wP[], │ │ │ │ │ +REAL wDu[]=0, REAL wDv[]=0, REAL wDuu[]=0, REAL wDuv[]=0, REAL wDvv[]=0) const │ │ │ │ │ +Evaluate basis functions for a varying value and derivatives at a given (u,v) │ │ │ │ │ +parametric location of ... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTable const * GetLocalPointVaryingStencilTable() const │ │ │ │ │ +Returns the stencil table to compute local point varying values. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_7_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_Q_u_a_d_O_f_f_s_e_t_s_T_a_b_l_e │ │ │ │ │ +std::vector< unsigned int > QuadOffsetsTable │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_3_8_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_V_e_r_t_i_c_e_s │ │ │ │ │ +ConstIndexArray GetPatchVertices(int array, int patch) const │ │ │ │ │ +Returns the control vertex indices for patch in array. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_F_V_a_r_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +PatchParam GetPatchFVarPatchParam(PatchHandle const &handle, int channel=0) │ │ │ │ │ +const │ │ │ │ │ +Returns the value indices for a given patch in channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_V_a_l_u_e_S_t_r_i_d_e │ │ │ │ │ +int GetFVarValueStride(int channel=0) const │ │ │ │ │ +Returns the stride between patches in the value index array of channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_s │ │ │ │ │ +ConstPatchParamArray GetFVarPatchParams(int channel=0) const │ │ │ │ │ +Returns an array of face-varying patch param for channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor GetFVarPatchDescriptor(int channel=0) const │ │ │ │ │ +Returns the default/irregular patch descriptor for channel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_V_a_r_y_i_n_g │ │ │ │ │ +int GetNumLocalPointsVarying() const │ │ │ │ │ +Returns the number of local varying points. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_L_o_c_a_l_P_o_i_n_t_S_t_e_n_c_i_l_P_r_e_c_i_s_i_o_n_M_a_t_c_h_e_s_T_y_p_e │ │ │ │ │ +bool LocalPointStencilPrecisionMatchesType() const │ │ │ │ │ +Tests if the precision of the stencil table to compute local point vertex │ │ │ │ │ +values matches the given fl... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_L_o_c_a_l_P_o_i_n_t_V_a_r_y_i_n_g_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +StencilTableReal< REAL > const * GetLocalPointVaryingStencilTable() const │ │ │ │ │ +Returns the stencil table to compute local point varying values. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_L_o_c_a_l_P_o_i_n_t_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +int GetNumLocalPointsFaceVarying(int channel=0) const │ │ │ │ │ +Returns the number of local face-varying points for channel. │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e │ │ │ │ │ Handle that can be used as unique patch identifier within PatchTable. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e_:_:_p_a_t_c_h_I_n_d_e_x │ │ │ │ │ +Index patchIndex │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e_:_:_a_r_r_a_y_I_n_d_e_x │ │ │ │ │ +Index arrayIndex │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e_:_:_P_a_t_c_h_H_a_n_d_l_e_:_:_v_e_r_t_I_n_d_e_x │ │ │ │ │ +Index vertIndex │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e_R_e_a_l │ │ │ │ │ +Table of subdivision stencils. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_1_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_F_V_a_r_L_i_n_e_a_r_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ +FVarLinearInterpolation │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ +DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_A_r_r_a_y │ │ │ │ │ +DDeeffiinniittiioonn _a_r_r_a_y_._h_:_1_0_5 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_M_a_p_._h │ │ │ │ │ + * _p_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00737.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchDescriptor.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/patchParam.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -91,48 +91,50 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces | │ │ │ │ Typedefs
│ │ │ │ -
patchDescriptor.h File Reference
│ │ │ │ +
patchParam.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../far/types.h"
│ │ │ │ -#include "../sdc/types.h"
│ │ │ │ -#include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PatchDescriptor
 Describes the type of a patch. More...
struct  PatchParam
 Patch parameterization. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │

│ │ │ │ Typedefs

typedef Vtr::ConstArray< PatchDescriptorConstPatchDescriptorArray
 
typedef std::vector< PatchParamPatchParamTable
 
typedef Vtr::Array< PatchParamPatchParamArray
 
typedef Vtr::ConstArray< PatchParamConstPatchParamArray
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,29 +1,31 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s │ │ │ │ │ -patchDescriptor.h File Reference │ │ │ │ │ +patchParam.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ #include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ -#include "_._._/_s_d_c_/_t_y_p_e_s_._h" │ │ │ │ │ -#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -  Describes the type of a patch. _M_o_r_e_._._. │ │ │ │ │ +struct   _P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +  Patch parameterization. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ TTyyppeeddeeffss │ │ │ │ │ -typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y< _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r >  _C_o_n_s_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_A_r_r_a_y │ │ │ │ │ + typedef std::vector< _P_a_t_c_h_P_a_r_a_m >  _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ +  │ │ │ │ │ + typedef _V_t_r_:_:_A_r_r_a_y< _P_a_t_c_h_P_a_r_a_m >  _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ +  │ │ │ │ │ +typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y< _P_a_t_c_h_P_a_r_a_m >  _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _p_a_t_c_h_P_a_r_a_m_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00737.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,6 @@ │ │ │ │ │ var a00737 = [ │ │ │ │ │ - ["PatchDescriptor", "a00973.html", "a00973"], │ │ │ │ │ - ["ConstPatchDescriptorArray", "a00737.html#ad258c2d8f7871bc0d40cf3a9ded6e08a", null] │ │ │ │ │ + ["PatchParam", "a00989.html", "a00989"], │ │ │ │ │ + ["ConstPatchParamArray", "a00737.html#a3139c7c52ddf26b2403e8e95ff63eeb3", null], │ │ │ │ │ + ["PatchParamArray", "a00737.html#abe07210a029a01571c54276ae28b4d88", null], │ │ │ │ │ + ["PatchParamTable", "a00737.html#a46ea68db89cc3d55c4191ef7648281ce", null] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00737_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchDescriptor.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/patchParam.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
patchDescriptor.h
│ │ │ │ +
patchParam.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,226 +119,214 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_PATCH_PARAM_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_PATCH_PARAM_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │
30#include "../far/types.h"
│ │ │ │ -
31#include "../sdc/types.h"
│ │ │ │ -
32
│ │ │ │ -
33#include <vector>
│ │ │ │ +
31
│ │ │ │ +
32namespace OpenSubdiv {
│ │ │ │ +
33namespace OPENSUBDIV_VERSION {
│ │ │ │
34
│ │ │ │ -
35namespace OpenSubdiv {
│ │ │ │ -
36namespace OPENSUBDIV_VERSION {
│ │ │ │ -
37
│ │ │ │ -
38namespace Far {
│ │ │ │ -
39
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
45
│ │ │ │ -
46public:
│ │ │ │ -
47
│ │ │ │ -
│ │ │ │ -
48 enum Type {
│ │ │ │ - │ │ │ │ -
50
│ │ │ │ - │ │ │ │ - │ │ │ │ -
53
│ │ │ │ - │ │ │ │ - │ │ │ │ -
56
│ │ │ │ - │ │ │ │ -
58
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
64 };
│ │ │ │ -
│ │ │ │ -
65
│ │ │ │ -
66public:
│ │ │ │ -
67
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
70 _type(NON_PATCH) { }
│ │ │ │ -
│ │ │ │ -
71
│ │ │ │ -
│ │ │ │ -
73 PatchDescriptor(int type) :
│ │ │ │ -
74 _type(type) { }
│ │ │ │ -
│ │ │ │ -
75
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
78 _type(d.GetType()) { }
│ │ │ │ -
│ │ │ │ -
79
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
82 _type = d.GetType();
│ │ │ │ -
83 return *this;
│ │ │ │ -
84 }
│ │ │ │ -
│ │ │ │ -
85
│ │ │ │ -
│ │ │ │ -
87 Type GetType() const {
│ │ │ │ -
88 return (Type)_type;
│ │ │ │ -
89 }
│ │ │ │ -
│ │ │ │ -
90
│ │ │ │ -
│ │ │ │ -
92 static inline bool IsAdaptive(Type type) {
│ │ │ │ -
93 return type > TRIANGLES;
│ │ │ │ -
94 }
│ │ │ │ -
│ │ │ │ -
95
│ │ │ │ -
│ │ │ │ -
97 bool IsAdaptive() const {
│ │ │ │ -
98 return IsAdaptive( this->GetType() );
│ │ │ │ -
99 }
│ │ │ │ -
│ │ │ │ -
100
│ │ │ │ -
103 static inline short GetNumControlVertices( Type t );
│ │ │ │ -
104
│ │ │ │ -
106 static inline short GetNumFVarControlVertices( Type t );
│ │ │ │ -
107
│ │ │ │ -
│ │ │ │ -
110 short GetNumControlVertices() const {
│ │ │ │ -
111 return GetNumControlVertices( this->GetType() );
│ │ │ │ -
112 }
│ │ │ │ -
│ │ │ │ -
113
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
116 return GetNumFVarControlVertices( this->GetType() );
│ │ │ │ -
117 }
│ │ │ │ -
│ │ │ │ -
118
│ │ │ │ -
120 static short GetRegularPatchSize() { return 16; }
│ │ │ │ -
121
│ │ │ │ -
123 static short GetGregoryPatchSize() { return 4; }
│ │ │ │ -
124
│ │ │ │ -
126 static short GetGregoryBasisPatchSize() { return 20; }
│ │ │ │ -
127
│ │ │ │ -
128
│ │ │ │ - │ │ │ │ -
132
│ │ │ │ -
134 inline bool operator < ( PatchDescriptor const other ) const;
│ │ │ │ -
135
│ │ │ │ -
137 inline bool operator == ( PatchDescriptor const other ) const;
│ │ │ │ -
138
│ │ │ │ -
139 // debug helper
│ │ │ │ -
140 void print() const;
│ │ │ │ -
141
│ │ │ │ -
142private:
│ │ │ │ -
143 unsigned int _type;
│ │ │ │ -
144};
│ │ │ │ -
│ │ │ │ -
145
│ │ │ │ - │ │ │ │ -
147
│ │ │ │ -
148// Returns the number of control vertices expected for a patch of this type
│ │ │ │ -
149inline short
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
151 switch (type) {
│ │ │ │ -
152 case REGULAR : return GetRegularPatchSize();
│ │ │ │ -
153 case LOOP : return 12;
│ │ │ │ -
154 case QUADS : return 4;
│ │ │ │ -
155 case GREGORY :
│ │ │ │ - │ │ │ │ - │ │ │ │ -
158 case GREGORY_TRIANGLE : return 18;
│ │ │ │ -
159 case TRIANGLES : return 3;
│ │ │ │ -
160 case LINES : return 2;
│ │ │ │ -
161 case POINTS : return 1;
│ │ │ │ -
162 default : return -1;
│ │ │ │ -
163 }
│ │ │ │ -
164}
│ │ │ │ -
│ │ │ │ -
165
│ │ │ │ -
166// Returns the number of face-varying control vertices expected for a patch of this type
│ │ │ │ -
167inline short
│ │ │ │ -
│ │ │ │ - │ │ │ │ - │ │ │ │ -
170}
│ │ │ │ -
│ │ │ │ -
171
│ │ │ │ -
172// Allows ordering of patches by type
│ │ │ │ -
│ │ │ │ -
173inline bool
│ │ │ │ - │ │ │ │ -
175 return (_type < other._type);
│ │ │ │ -
176}
│ │ │ │ -
│ │ │ │ -
177
│ │ │ │ -
178// True if the descriptors are identical
│ │ │ │ -
179inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
181 return _type == other._type;
│ │ │ │ -
182}
│ │ │ │ -
│ │ │ │ -
183
│ │ │ │ -
184
│ │ │ │ -
185
│ │ │ │ -
186} // end namespace Far
│ │ │ │ -
187
│ │ │ │ -
188} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
189using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
190
│ │ │ │ -
191} // end namespace OpenSubdiv
│ │ │ │ +
35namespace Far {
│ │ │ │ +
36
│ │ │ │ +
101
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
168 void Set(Index faceid, short u, short v,
│ │ │ │ +
169 unsigned short depth, bool nonquad,
│ │ │ │ +
170 unsigned short boundary, unsigned short transition,
│ │ │ │ +
171 bool regular = false);
│ │ │ │ +
172
│ │ │ │ +
174 void Clear() { field0 = field1 = 0; }
│ │ │ │ +
175
│ │ │ │ +
177 Index GetFaceId() const { return Index(unpack(field0,28,0)); }
│ │ │ │ +
178
│ │ │ │ +
181 unsigned short GetU() const { return (unsigned short)unpack(field1,10,22); }
│ │ │ │ +
182
│ │ │ │ +
185 unsigned short GetV() const { return (unsigned short)unpack(field1,10,12); }
│ │ │ │ +
186
│ │ │ │ +
188 unsigned short GetTransition() const { return (unsigned short)unpack(field0,4,28); }
│ │ │ │ +
189
│ │ │ │ +
191 unsigned short GetBoundary() const { return (unsigned short)unpack(field1,5,7); }
│ │ │ │
192
│ │ │ │ -
193#endif /* OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H */
│ │ │ │ +
194 bool NonQuadRoot() const { return (unpack(field1,1,4) != 0); }
│ │ │ │ +
195
│ │ │ │ +
197 unsigned short GetDepth() const { return (unsigned short)unpack(field1,4,0); }
│ │ │ │ +
198
│ │ │ │ +
200 float GetParamFraction() const;
│ │ │ │ +
201
│ │ │ │ +
208 template <typename REAL>
│ │ │ │ +
209 void Normalize( REAL & u, REAL & v ) const;
│ │ │ │ +
210 template <typename REAL>
│ │ │ │ +
211 void NormalizeTriangle( REAL & u, REAL & v ) const;
│ │ │ │ +
212
│ │ │ │ +
219 template <typename REAL>
│ │ │ │ +
220 void Unnormalize( REAL & u, REAL & v ) const;
│ │ │ │ +
221 template <typename REAL>
│ │ │ │ +
222 void UnnormalizeTriangle( REAL & u, REAL & v ) const;
│ │ │ │ +
223
│ │ │ │ +
225 bool IsTriangleRotated() const;
│ │ │ │ +
226
│ │ │ │ +
228 bool IsRegular() const { return (unpack(field1,1,5) != 0); }
│ │ │ │ +
229
│ │ │ │ +
230 unsigned int field0:32;
│ │ │ │ +
231 unsigned int field1:32;
│ │ │ │ +
232
│ │ │ │ +
233private:
│ │ │ │ +
234 unsigned int pack(unsigned int value, int width, int offset) const {
│ │ │ │ +
235 return (unsigned int)((value & ((1<<width)-1)) << offset);
│ │ │ │ +
236 }
│ │ │ │ +
237
│ │ │ │ +
238 unsigned int unpack(unsigned int value, int width, int offset) const {
│ │ │ │ +
239 return (unsigned int)((value >> offset) & ((1<<width)-1));
│ │ │ │ +
240 }
│ │ │ │ +
241};
│ │ │ │ +
│ │ │ │ +
242
│ │ │ │ +
243typedef std::vector<PatchParam> PatchParamTable;
│ │ │ │ +
244
│ │ │ │ + │ │ │ │ + │ │ │ │ +
247
│ │ │ │ +
248inline void
│ │ │ │ +
│ │ │ │ +
249PatchParam::Set(Index faceid, short u, short v,
│ │ │ │ +
250 unsigned short depth, bool nonquad,
│ │ │ │ +
251 unsigned short boundary, unsigned short transition,
│ │ │ │ +
252 bool regular) {
│ │ │ │ +
253 field0 = pack(faceid, 28, 0) |
│ │ │ │ +
254 pack(transition, 4, 28);
│ │ │ │ +
255
│ │ │ │ +
256 field1 = pack(u, 10, 22) |
│ │ │ │ +
257 pack(v, 10, 12) |
│ │ │ │ +
258 pack(boundary, 5, 7) |
│ │ │ │ +
259 pack(regular, 1, 5) |
│ │ │ │ +
260 pack(nonquad, 1, 4) |
│ │ │ │ +
261 pack(depth, 4, 0);
│ │ │ │ +
262}
│ │ │ │ +
│ │ │ │ +
263
│ │ │ │ +
264inline float
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
266 return 1.0f / (float)(1 << (GetDepth() - NonQuadRoot()));
│ │ │ │ +
267}
│ │ │ │ +
│ │ │ │ +
268
│ │ │ │ +
269template <typename REAL>
│ │ │ │ +
270inline void
│ │ │ │ +
│ │ │ │ +
271PatchParam::Normalize( REAL & u, REAL & v ) const {
│ │ │ │ +
272
│ │ │ │ +
273 REAL fracInv = (REAL)(1.0f / GetParamFraction());
│ │ │ │ +
274
│ │ │ │ +
275 u = u * fracInv - (REAL)GetU();
│ │ │ │ +
276 v = v * fracInv - (REAL)GetV();
│ │ │ │ +
277}
│ │ │ │ +
│ │ │ │ +
278
│ │ │ │ +
279template <typename REAL>
│ │ │ │ +
280inline void
│ │ │ │ +
│ │ │ │ +
281PatchParam::Unnormalize( REAL & u, REAL & v ) const {
│ │ │ │ +
282
│ │ │ │ +
283 REAL frac = (REAL)GetParamFraction();
│ │ │ │ +
284
│ │ │ │ +
285 u = (u + (REAL)GetU()) * frac;
│ │ │ │ +
286 v = (v + (REAL)GetV()) * frac;
│ │ │ │ +
287}
│ │ │ │ +
│ │ │ │ +
288
│ │ │ │ +
289inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
291
│ │ │ │ +
292 return (GetU() + GetV()) >= (1 << GetDepth());
│ │ │ │ +
293}
│ │ │ │ +
│ │ │ │ +
294
│ │ │ │ +
295template <typename REAL>
│ │ │ │ +
296inline void
│ │ │ │ +
│ │ │ │ +
297PatchParam::NormalizeTriangle( REAL & u, REAL & v ) const {
│ │ │ │ +
298
│ │ │ │ +
299 if (IsTriangleRotated()) {
│ │ │ │ +
300 REAL fracInv = (REAL)(1.0f / GetParamFraction());
│ │ │ │ +
301
│ │ │ │ +
302 int depthFactor = 1 << GetDepth();
│ │ │ │ +
303 u = (REAL)(depthFactor - GetU()) - (u * fracInv);
│ │ │ │ +
304 v = (REAL)(depthFactor - GetV()) - (v * fracInv);
│ │ │ │ +
305 } else {
│ │ │ │ +
306 Normalize(u, v);
│ │ │ │ +
307 }
│ │ │ │ +
308}
│ │ │ │ +
│ │ │ │ +
309
│ │ │ │ +
310template <typename REAL>
│ │ │ │ +
311inline void
│ │ │ │ +
│ │ │ │ +
312PatchParam::UnnormalizeTriangle( REAL & u, REAL & v ) const {
│ │ │ │ +
313
│ │ │ │ +
314 if (IsTriangleRotated()) {
│ │ │ │ +
315 REAL frac = GetParamFraction();
│ │ │ │ +
316
│ │ │ │ +
317 int depthFactor = 1 << GetDepth();
│ │ │ │ +
318 u = ((REAL)(depthFactor - GetU()) - u) * frac;
│ │ │ │ +
319 v = ((REAL)(depthFactor - GetV()) - v) * frac;
│ │ │ │ +
320 } else {
│ │ │ │ +
321 Unnormalize(u, v);
│ │ │ │ +
322 }
│ │ │ │ +
323}
│ │ │ │ +
│ │ │ │ +
324
│ │ │ │ +
325} // end namespace Far
│ │ │ │ +
326
│ │ │ │ +
327} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
328using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
329
│ │ │ │ +
330} // end namespace OpenSubdiv
│ │ │ │ +
331
│ │ │ │ +
332#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */
│ │ │ │ │ │ │ │ -
Vtr::ConstArray< PatchDescriptor > ConstPatchDescriptorArray
│ │ │ │ -
SchemeType
Enumerated type for all subdivision schemes supported by OpenSubdiv.
Definition types.h:37
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
@ LOOP
regular triangular patch for the Loop scheme
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
@ REGULAR
regular B-Spline patch for the Catmark scheme
│ │ │ │ -
bool IsAdaptive() const
Returns true if the type is an adaptive patch.
│ │ │ │ -
Type GetType() const
Returns the type of the patch.
│ │ │ │ -
static short GetGregoryBasisPatchSize()
Number of control vertices of Gregory patch basis (20)
│ │ │ │ -
short GetNumControlVertices() const
Returns the number of control vertices expected for a patch of the type described.
│ │ │ │ -
PatchDescriptor(PatchDescriptor const &d)
Copy Constructor.
│ │ │ │ -
bool operator==(PatchDescriptor const other) const
True if the descriptors are identical.
│ │ │ │ -
static short GetRegularPatchSize()
Number of control vertices of Regular Patches in table.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
PatchDescriptor & operator=(PatchDescriptor const &d)
Assignment operator.
│ │ │ │ -
static bool IsAdaptive(Type type)
Returns true if the type is an adaptive (non-linear) patch.
│ │ │ │ -
bool operator<(PatchDescriptor const other) const
Allows ordering of patches by type.
│ │ │ │ -
static short GetGregoryPatchSize()
Number of control vertices of Gregory (and Gregory Boundary) Patches in table.
│ │ │ │ - │ │ │ │ -
static Vtr::ConstArray< PatchDescriptor > GetAdaptivePatchDescriptors(Sdc::SchemeType type)
Returns a vector of all the legal patch descriptors for the given adaptive subdivision scheme.
│ │ │ │ - │ │ │ │ +
Vtr::ConstArray< PatchParam > ConstPatchParamArray
Definition patchParam.h:246
│ │ │ │ +
std::vector< PatchParam > PatchParamTable
Definition patchParam.h:243
│ │ │ │ + │ │ │ │ +
Vtr::Array< PatchParam > PatchParamArray
Definition patchParam.h:245
│ │ │ │ + │ │ │ │ +
bool IsTriangleRotated() const
Returns if a triangular patch is parametrically rotated 180 degrees.
Definition patchParam.h:290
│ │ │ │ +
bool IsRegular() const
Returns whether the patch is regular.
Definition patchParam.h:228
│ │ │ │ +
void NormalizeTriangle(REAL &u, REAL &v) const
Definition patchParam.h:297
│ │ │ │ +
unsigned short GetBoundary() const
Returns the boundary edge encoding for the patch.
Definition patchParam.h:191
│ │ │ │ +
unsigned short GetTransition() const
Returns the transition edge encoding for the patch.
Definition patchParam.h:188
│ │ │ │ +
float GetParamFraction() const
Returns the fraction of unit parametric space covered by this face.
Definition patchParam.h:265
│ │ │ │ +
unsigned short GetU() const
Returns the log2 value of the u parameter at the first corner of the patch.
Definition patchParam.h:181
│ │ │ │ +
Index GetFaceId() const
Returns the faceid.
Definition patchParam.h:177
│ │ │ │ +
unsigned short GetDepth() const
Returns the level of subdivision of the patch.
Definition patchParam.h:197
│ │ │ │ +
bool NonQuadRoot() const
True if the parent base face is a non-quad.
Definition patchParam.h:194
│ │ │ │ +
void Set(Index faceid, short u, short v, unsigned short depth, bool nonquad, unsigned short boundary, unsigned short transition, bool regular=false)
Sets the values of the bit fields.
Definition patchParam.h:249
│ │ │ │ + │ │ │ │ + │ │ │ │ +
void Unnormalize(REAL &u, REAL &v) const
A (u,v) pair in a normalized parametric space is mapped back into the fraction of parametric space co...
Definition patchParam.h:281
│ │ │ │ +
void UnnormalizeTriangle(REAL &u, REAL &v) const
Definition patchParam.h:312
│ │ │ │ +
unsigned short GetV() const
Returns the log2 value of the v parameter at the first corner of the patch.
Definition patchParam.h:185
│ │ │ │ + │ │ │ │ +
void Normalize(REAL &u, REAL &v) const
A (u,v) pair in the fraction of parametric space covered by this face is mapped into a normalized par...
Definition patchParam.h:271
│ │ │ │ │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -patchDescriptor.h │ │ │ │ │ +patchParam.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,280 +24,262 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_PATCH_PARAM_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_PATCH_PARAM_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ 30#include "../far/types.h" │ │ │ │ │ -31#include "../sdc/types.h" │ │ │ │ │ -32 │ │ │ │ │ -33#include │ │ │ │ │ +31 │ │ │ │ │ +32namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +33namespace OPENSUBDIV_VERSION { │ │ │ │ │ 34 │ │ │ │ │ -35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -36namespace OPENSUBDIV_VERSION { │ │ │ │ │ -37 │ │ │ │ │ -38namespace Far { │ │ │ │ │ -39 │ │ │ │ │ -_4_4class _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ -45 │ │ │ │ │ -46public: │ │ │ │ │ -47 │ │ │ │ │ -_4_8 enum _T_y_p_e { │ │ │ │ │ -_4_9 _N_O_N___P_A_T_C_H = 0, │ │ │ │ │ -50 │ │ │ │ │ -_5_1 _P_O_I_N_T_S, │ │ │ │ │ -_5_2 _L_I_N_E_S, │ │ │ │ │ -53 │ │ │ │ │ -_5_4 _Q_U_A_D_S, │ │ │ │ │ -_5_5 _T_R_I_A_N_G_L_E_S, │ │ │ │ │ -56 │ │ │ │ │ -_5_7 _L_O_O_P, │ │ │ │ │ -58 │ │ │ │ │ -_5_9 _R_E_G_U_L_A_R, │ │ │ │ │ -_6_0 _G_R_E_G_O_R_Y, │ │ │ │ │ -_6_1 _G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y, │ │ │ │ │ -_6_2 _G_R_E_G_O_R_Y___B_A_S_I_S, │ │ │ │ │ -63 _G_R_E_G_O_R_Y___T_R_I_A_N_G_L_E │ │ │ │ │ -_6_4 }; │ │ │ │ │ -65 │ │ │ │ │ -66public: │ │ │ │ │ -67 │ │ │ │ │ -_6_9 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r() : │ │ │ │ │ -70 _type(_N_O_N___P_A_T_C_H) { } │ │ │ │ │ -71 │ │ │ │ │ -_7_3 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r(int type) : │ │ │ │ │ -74 _type(type) { } │ │ │ │ │ -75 │ │ │ │ │ -_7_7 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const & d ) : │ │ │ │ │ -78 _type(d._G_e_t_T_y_p_e()) { } │ │ │ │ │ -79 │ │ │ │ │ -_8_1 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r & _o_p_e_r_a_t_o_r_=( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const & d ) { │ │ │ │ │ -82 _type = d._G_e_t_T_y_p_e(); │ │ │ │ │ -83 return *this; │ │ │ │ │ -84 } │ │ │ │ │ -85 │ │ │ │ │ -_8_7 _T_y_p_e _G_e_t_T_y_p_e() const { │ │ │ │ │ -88 return (_T_y_p_e)_type; │ │ │ │ │ -89 } │ │ │ │ │ -90 │ │ │ │ │ -_9_2 static inline bool _I_s_A_d_a_p_t_i_v_e(_T_y_p_e type) { │ │ │ │ │ -93 return type > _T_R_I_A_N_G_L_E_S; │ │ │ │ │ -94 } │ │ │ │ │ -95 │ │ │ │ │ -_9_7 bool _I_s_A_d_a_p_t_i_v_e() const { │ │ │ │ │ -98 return _I_s_A_d_a_p_t_i_v_e( this->_G_e_t_T_y_p_e() ); │ │ │ │ │ -99 } │ │ │ │ │ -100 │ │ │ │ │ -103 static inline short _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e t ); │ │ │ │ │ -104 │ │ │ │ │ -106 static inline short _G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e t ); │ │ │ │ │ -107 │ │ │ │ │ -_1_1_0 short _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s() const { │ │ │ │ │ -111 return _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( this->_G_e_t_T_y_p_e() ); │ │ │ │ │ -112 } │ │ │ │ │ -113 │ │ │ │ │ -_1_1_5 short _G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s() const { │ │ │ │ │ -116 return _G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( this->_G_e_t_T_y_p_e() ); │ │ │ │ │ -117 } │ │ │ │ │ -118 │ │ │ │ │ -_1_2_0 static short _G_e_t_R_e_g_u_l_a_r_P_a_t_c_h_S_i_z_e() { return 16; } │ │ │ │ │ -121 │ │ │ │ │ -_1_2_3 static short _G_e_t_G_r_e_g_o_r_y_P_a_t_c_h_S_i_z_e() { return 4; } │ │ │ │ │ -124 │ │ │ │ │ -_1_2_6 static short _G_e_t_G_r_e_g_o_r_y_B_a_s_i_s_P_a_t_c_h_S_i_z_e() { return 20; } │ │ │ │ │ -127 │ │ │ │ │ -128 │ │ │ │ │ -_1_3_1 static _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_> _G_e_t_A_d_a_p_t_i_v_e_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_s(_S_d_c_:_: │ │ │ │ │ -_S_c_h_e_m_e_T_y_p_e type); │ │ │ │ │ -132 │ │ │ │ │ -134 inline bool _o_p_e_r_a_t_o_r_ _<_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const; │ │ │ │ │ -135 │ │ │ │ │ -137 inline bool _o_p_e_r_a_t_o_r_ _=_=_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const; │ │ │ │ │ -138 │ │ │ │ │ -139 // debug helper │ │ │ │ │ -_1_4_0 void _p_r_i_n_t() const; │ │ │ │ │ -141 │ │ │ │ │ -142private: │ │ │ │ │ -143 unsigned int _type; │ │ │ │ │ -144}; │ │ │ │ │ -145 │ │ │ │ │ -_1_4_6typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_> _C_o_n_s_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_A_r_r_a_y; │ │ │ │ │ -147 │ │ │ │ │ -148// Returns the number of control vertices expected for a patch of this type │ │ │ │ │ -149inline short │ │ │ │ │ -_1_5_0_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e type ) { │ │ │ │ │ -151 switch (type) { │ │ │ │ │ -152 case _R_E_G_U_L_A_R : return _G_e_t_R_e_g_u_l_a_r_P_a_t_c_h_S_i_z_e(); │ │ │ │ │ -153 case _L_O_O_P : return 12; │ │ │ │ │ -154 case _Q_U_A_D_S : return 4; │ │ │ │ │ -155 case _G_R_E_G_O_R_Y : │ │ │ │ │ -156 case _G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y : return _G_e_t_G_r_e_g_o_r_y_P_a_t_c_h_S_i_z_e(); │ │ │ │ │ -157 case _G_R_E_G_O_R_Y___B_A_S_I_S : return _G_e_t_G_r_e_g_o_r_y_B_a_s_i_s_P_a_t_c_h_S_i_z_e(); │ │ │ │ │ -158 case _G_R_E_G_O_R_Y___T_R_I_A_N_G_L_E : return 18; │ │ │ │ │ -159 case _T_R_I_A_N_G_L_E_S : return 3; │ │ │ │ │ -160 case _L_I_N_E_S : return 2; │ │ │ │ │ -161 case _P_O_I_N_T_S : return 1; │ │ │ │ │ -162 default : return -1; │ │ │ │ │ -163 } │ │ │ │ │ -164} │ │ │ │ │ -165 │ │ │ │ │ -166// Returns the number of face-varying control vertices expected for a patch │ │ │ │ │ -of this type │ │ │ │ │ -167inline short │ │ │ │ │ -_1_6_8_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e type ) { │ │ │ │ │ -169 return _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(type); │ │ │ │ │ -170} │ │ │ │ │ -171 │ │ │ │ │ -172// Allows ordering of patches by type │ │ │ │ │ -_1_7_3inline bool │ │ │ │ │ -174_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_ _<_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const { │ │ │ │ │ -175 return (_type < other._type); │ │ │ │ │ -176} │ │ │ │ │ -177 │ │ │ │ │ -178// True if the descriptors are identical │ │ │ │ │ -179inline bool │ │ │ │ │ -_1_8_0_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_ _=_=_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const { │ │ │ │ │ -181 return _type == other._type; │ │ │ │ │ -182} │ │ │ │ │ -183 │ │ │ │ │ -184 │ │ │ │ │ -185 │ │ │ │ │ -186} // end namespace Far │ │ │ │ │ -187 │ │ │ │ │ -188} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -189using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -190 │ │ │ │ │ -191} // end namespace OpenSubdiv │ │ │ │ │ +35namespace Far { │ │ │ │ │ +36 │ │ │ │ │ +101 │ │ │ │ │ +_1_5_2struct _P_a_t_c_h_P_a_r_a_m { │ │ │ │ │ +168 void _S_e_t(_I_n_d_e_x faceid, short u, short v, │ │ │ │ │ +169 unsigned short depth, bool nonquad, │ │ │ │ │ +170 unsigned short boundary, unsigned short transition, │ │ │ │ │ +171 bool regular = false); │ │ │ │ │ +172 │ │ │ │ │ +_1_7_4 void _C_l_e_a_r() { _f_i_e_l_d_0 = _f_i_e_l_d_1 = 0; } │ │ │ │ │ +175 │ │ │ │ │ +_1_7_7 _I_n_d_e_x _G_e_t_F_a_c_e_I_d() const { return _I_n_d_e_x(unpack(_f_i_e_l_d_0,28,0)); } │ │ │ │ │ +178 │ │ │ │ │ +_1_8_1 unsigned short _G_e_t_U() const { return (unsigned short)unpack(_f_i_e_l_d_1,10,22); │ │ │ │ │ +} │ │ │ │ │ +182 │ │ │ │ │ +_1_8_5 unsigned short _G_e_t_V() const { return (unsigned short)unpack(_f_i_e_l_d_1,10,12); │ │ │ │ │ +} │ │ │ │ │ +186 │ │ │ │ │ +_1_8_8 unsigned short _G_e_t_T_r_a_n_s_i_t_i_o_n() const { return (unsigned short)unpack │ │ │ │ │ +(_f_i_e_l_d_0,4,28); } │ │ │ │ │ +189 │ │ │ │ │ +_1_9_1 unsigned short _G_e_t_B_o_u_n_d_a_r_y() const { return (unsigned short)unpack │ │ │ │ │ +(_f_i_e_l_d_1,5,7); } │ │ │ │ │ 192 │ │ │ │ │ -193#endif /* OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H */ │ │ │ │ │ +_1_9_4 bool _N_o_n_Q_u_a_d_R_o_o_t() const { return (unpack(_f_i_e_l_d_1,1,4) != 0); } │ │ │ │ │ +195 │ │ │ │ │ +_1_9_7 unsigned short _G_e_t_D_e_p_t_h() const { return (unsigned short)unpack │ │ │ │ │ +(_f_i_e_l_d_1,4,0); } │ │ │ │ │ +198 │ │ │ │ │ +200 float _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n() const; │ │ │ │ │ +201 │ │ │ │ │ +208 template │ │ │ │ │ +209 void _N_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const; │ │ │ │ │ +210 template │ │ │ │ │ +211 void _N_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const; │ │ │ │ │ +212 │ │ │ │ │ +219 template │ │ │ │ │ +220 void _U_n_n_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const; │ │ │ │ │ +221 template │ │ │ │ │ +222 void _U_n_n_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const; │ │ │ │ │ +223 │ │ │ │ │ +225 bool _I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d() const; │ │ │ │ │ +226 │ │ │ │ │ +_2_2_8 bool _I_s_R_e_g_u_l_a_r() const { return (unpack(_f_i_e_l_d_1,1,5) != 0); } │ │ │ │ │ +229 │ │ │ │ │ +_2_3_0 unsigned int _f_i_e_l_d_0:32; │ │ │ │ │ +_2_3_1 unsigned int _f_i_e_l_d_1:32; │ │ │ │ │ +232 │ │ │ │ │ +233private: │ │ │ │ │ +234 unsigned int pack(unsigned int value, int width, int offset) const { │ │ │ │ │ +235 return (unsigned int)((value & ((1<> offset) & ((1< _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e; │ │ │ │ │ +244 │ │ │ │ │ +_2_4_5typedef _V_t_r_:_:_A_r_r_a_y_<_P_a_t_c_h_P_a_r_a_m_> _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y; │ │ │ │ │ +_2_4_6typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_P_a_t_c_h_P_a_r_a_m_> _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y; │ │ │ │ │ +247 │ │ │ │ │ +248inline void │ │ │ │ │ +_2_4_9_P_a_t_c_h_P_a_r_a_m_:_:_S_e_t(_I_n_d_e_x faceid, short u, short v, │ │ │ │ │ +250 unsigned short depth, bool nonquad, │ │ │ │ │ +251 unsigned short boundary, unsigned short transition, │ │ │ │ │ +252 bool regular) { │ │ │ │ │ +253 _f_i_e_l_d_0 = pack(faceid, 28, 0) | │ │ │ │ │ +254 pack(transition, 4, 28); │ │ │ │ │ +255 │ │ │ │ │ +256 _f_i_e_l_d_1 = pack(u, 10, 22) | │ │ │ │ │ +257 pack(v, 10, 12) | │ │ │ │ │ +258 pack(boundary, 5, 7) | │ │ │ │ │ +259 pack(regular, 1, 5) | │ │ │ │ │ +260 pack(nonquad, 1, 4) | │ │ │ │ │ +261 pack(depth, 4, 0); │ │ │ │ │ +262} │ │ │ │ │ +263 │ │ │ │ │ +264inline float │ │ │ │ │ +_2_6_5_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n( ) const { │ │ │ │ │ +266 return 1.0f / (float)(1 << (_G_e_t_D_e_p_t_h() - _N_o_n_Q_u_a_d_R_o_o_t())); │ │ │ │ │ +267} │ │ │ │ │ +268 │ │ │ │ │ +269template │ │ │ │ │ +270inline void │ │ │ │ │ +_2_7_1_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const { │ │ │ │ │ +272 │ │ │ │ │ +273 REAL fracInv = (REAL)(1.0f / _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n()); │ │ │ │ │ +274 │ │ │ │ │ +275 u = u * fracInv - (REAL)_G_e_t_U(); │ │ │ │ │ +276 v = v * fracInv - (REAL)_G_e_t_V(); │ │ │ │ │ +277} │ │ │ │ │ +278 │ │ │ │ │ +279template │ │ │ │ │ +280inline void │ │ │ │ │ +_2_8_1_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const { │ │ │ │ │ +282 │ │ │ │ │ +283 REAL frac = (REAL)_G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n(); │ │ │ │ │ +284 │ │ │ │ │ +285 u = (u + (REAL)_G_e_t_U()) * frac; │ │ │ │ │ +286 v = (v + (REAL)_G_e_t_V()) * frac; │ │ │ │ │ +287} │ │ │ │ │ +288 │ │ │ │ │ +289inline bool │ │ │ │ │ +_2_9_0_P_a_t_c_h_P_a_r_a_m_:_:_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d() const { │ │ │ │ │ +291 │ │ │ │ │ +292 return (_G_e_t_U() + _G_e_t_V()) >= (1 << _G_e_t_D_e_p_t_h()); │ │ │ │ │ +293} │ │ │ │ │ +294 │ │ │ │ │ +295template │ │ │ │ │ +296inline void │ │ │ │ │ +_2_9_7_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const { │ │ │ │ │ +298 │ │ │ │ │ +299 if (_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d()) { │ │ │ │ │ +300 REAL fracInv = (REAL)(1.0f / _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n()); │ │ │ │ │ +301 │ │ │ │ │ +302 int depthFactor = 1 << _G_e_t_D_e_p_t_h(); │ │ │ │ │ +303 u = (REAL)(depthFactor - _G_e_t_U()) - (u * fracInv); │ │ │ │ │ +304 v = (REAL)(depthFactor - _G_e_t_V()) - (v * fracInv); │ │ │ │ │ +305 } else { │ │ │ │ │ +306 _N_o_r_m_a_l_i_z_e(u, v); │ │ │ │ │ +307 } │ │ │ │ │ +308} │ │ │ │ │ +309 │ │ │ │ │ +310template │ │ │ │ │ +311inline void │ │ │ │ │ +_3_1_2_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const { │ │ │ │ │ +313 │ │ │ │ │ +314 if (_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d()) { │ │ │ │ │ +315 REAL frac = _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n(); │ │ │ │ │ +316 │ │ │ │ │ +317 int depthFactor = 1 << _G_e_t_D_e_p_t_h(); │ │ │ │ │ +318 u = ((REAL)(depthFactor - _G_e_t_U()) - u) * frac; │ │ │ │ │ +319 v = ((REAL)(depthFactor - _G_e_t_V()) - v) * frac; │ │ │ │ │ +320 } else { │ │ │ │ │ +321 _U_n_n_o_r_m_a_l_i_z_e(u, v); │ │ │ │ │ +322 } │ │ │ │ │ +323} │ │ │ │ │ +324 │ │ │ │ │ +325} // end namespace Far │ │ │ │ │ +326 │ │ │ │ │ +327} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +328using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +329 │ │ │ │ │ +330} // end namespace OpenSubdiv │ │ │ │ │ +331 │ │ │ │ │ +332#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_A_r_r_a_y │ │ │ │ │ -Vtr::ConstArray< PatchDescriptor > ConstPatchDescriptorArray │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_T_y_p_e │ │ │ │ │ -SchemeType │ │ │ │ │ -Enumerated type for all subdivision schemes supported by OpenSubdiv. │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -Describes the type of a patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e │ │ │ │ │ -Type │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_L_I_N_E_S │ │ │ │ │ -@ LINES │ │ │ │ │ -lines (useful for cage drawing) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_Q_U_A_D_S │ │ │ │ │ -@ QUADS │ │ │ │ │ -4-sided quadrilateral (bilinear) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_N_O_N___P_A_T_C_H │ │ │ │ │ -@ NON_PATCH │ │ │ │ │ -undefined │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_L_O_O_P │ │ │ │ │ -@ LOOP │ │ │ │ │ -regular triangular patch for the Loop scheme │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___T_R_I_A_N_G_L_E │ │ │ │ │ -@ GREGORY_TRIANGLE │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_R_I_A_N_G_L_E_S │ │ │ │ │ -@ TRIANGLES │ │ │ │ │ -3-sided triangle │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y │ │ │ │ │ -@ GREGORY_BOUNDARY │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_A_S_I_S │ │ │ │ │ -@ GREGORY_BASIS │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_O_I_N_T_S │ │ │ │ │ -@ POINTS │ │ │ │ │ -points (useful for cage drawing) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y │ │ │ │ │ -@ GREGORY │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_R_E_G_U_L_A_R │ │ │ │ │ -@ REGULAR │ │ │ │ │ -regular B-Spline patch for the Catmark scheme │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_I_s_A_d_a_p_t_i_v_e │ │ │ │ │ -bool IsAdaptive() const │ │ │ │ │ -Returns true if the type is an adaptive patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_9_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_T_y_p_e │ │ │ │ │ -Type GetType() const │ │ │ │ │ -Returns the type of the patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_G_r_e_g_o_r_y_B_a_s_i_s_P_a_t_c_h_S_i_z_e │ │ │ │ │ -static short GetGregoryBasisPatchSize() │ │ │ │ │ -Number of control vertices of Gregory patch basis (20) │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ -short GetNumControlVertices() const │ │ │ │ │ -Returns the number of control vertices expected for a patch of the type │ │ │ │ │ -described. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_1_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor(PatchDescriptor const &d) │ │ │ │ │ -Copy Constructor. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ │ -bool operator==(PatchDescriptor const other) const │ │ │ │ │ -True if the descriptors are identical. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_R_e_g_u_l_a_r_P_a_t_c_h_S_i_z_e │ │ │ │ │ -static short GetRegularPatchSize() │ │ │ │ │ -Number of control vertices of Regular Patches in table. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_2_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ -short GetNumFVarControlVertices() const │ │ │ │ │ -Deprecated. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_1_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor(int type) │ │ │ │ │ -Constructor. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ │ -PatchDescriptor & operator=(PatchDescriptor const &d) │ │ │ │ │ -Assignment operator. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_I_s_A_d_a_p_t_i_v_e │ │ │ │ │ -static bool IsAdaptive(Type type) │ │ │ │ │ -Returns true if the type is an adaptive (non-linear) patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_< │ │ │ │ │ -bool operator<(PatchDescriptor const other) const │ │ │ │ │ -Allows ordering of patches by type. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_G_r_e_g_o_r_y_P_a_t_c_h_S_i_z_e │ │ │ │ │ -static short GetGregoryPatchSize() │ │ │ │ │ -Number of control vertices of Gregory (and Gregory Boundary) Patches in table. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_2_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_p_r_i_n_t │ │ │ │ │ -void print() const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_: │ │ │ │ │ -_G_e_t_A_d_a_p_t_i_v_e_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_s │ │ │ │ │ -static Vtr::ConstArray< PatchDescriptor > GetAdaptivePatchDescriptors(Sdc:: │ │ │ │ │ -SchemeType type) │ │ │ │ │ -Returns a vector of all the legal patch descriptors for the given adaptive │ │ │ │ │ -subdivision scheme. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -PatchDescriptor() │ │ │ │ │ -Default constructor. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ +Vtr::ConstArray< PatchParam > ConstPatchParamArray │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ +std::vector< PatchParam > PatchParamTable │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ +Vtr::Index Index │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ +Vtr::Array< PatchParam > PatchParamArray │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +Patch parameterization. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d │ │ │ │ │ +bool IsTriangleRotated() const │ │ │ │ │ +Returns if a triangular patch is parametrically rotated 180 degrees. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_9_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_I_s_R_e_g_u_l_a_r │ │ │ │ │ +bool IsRegular() const │ │ │ │ │ +Returns whether the patch is regular. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_2_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e │ │ │ │ │ +void NormalizeTriangle(REAL &u, REAL &v) const │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_9_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_B_o_u_n_d_a_r_y │ │ │ │ │ +unsigned short GetBoundary() const │ │ │ │ │ +Returns the boundary edge encoding for the patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_T_r_a_n_s_i_t_i_o_n │ │ │ │ │ +unsigned short GetTransition() const │ │ │ │ │ +Returns the transition edge encoding for the patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n │ │ │ │ │ +float GetParamFraction() const │ │ │ │ │ +Returns the fraction of unit parametric space covered by this face. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_U │ │ │ │ │ +unsigned short GetU() const │ │ │ │ │ +Returns the log2 value of the u parameter at the first corner of the patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_F_a_c_e_I_d │ │ │ │ │ +Index GetFaceId() const │ │ │ │ │ +Returns the faceid. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_D_e_p_t_h │ │ │ │ │ +unsigned short GetDepth() const │ │ │ │ │ +Returns the level of subdivision of the patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_9_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_N_o_n_Q_u_a_d_R_o_o_t │ │ │ │ │ +bool NonQuadRoot() const │ │ │ │ │ +True if the parent base face is a non-quad. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_9_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_S_e_t │ │ │ │ │ +void Set(Index faceid, short u, short v, unsigned short depth, bool nonquad, │ │ │ │ │ +unsigned short boundary, unsigned short transition, bool regular=false) │ │ │ │ │ +Sets the values of the bit fields. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_C_l_e_a_r │ │ │ │ │ +void Clear() │ │ │ │ │ +Resets everything to 0. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_f_i_e_l_d_1 │ │ │ │ │ +unsigned int field1 │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e │ │ │ │ │ +void Unnormalize(REAL &u, REAL &v) const │ │ │ │ │ +A (u,v) pair in a normalized parametric space is mapped back into the fraction │ │ │ │ │ +of parametric space co... │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e │ │ │ │ │ +void UnnormalizeTriangle(REAL &u, REAL &v) const │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_3_1_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_V │ │ │ │ │ +unsigned short GetV() const │ │ │ │ │ +Returns the log2 value of the v parameter at the first corner of the patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_f_i_e_l_d_0 │ │ │ │ │ +unsigned int field0 │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_3_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e │ │ │ │ │ +void Normalize(REAL &u, REAL &v) const │ │ │ │ │ +A (u,v) pair in the fraction of parametric space covered by this face is mapped │ │ │ │ │ +into a normalized par... │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_7_1 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_A_r_r_a_y │ │ │ │ │ +DDeeffiinniittiioonn _a_r_r_a_y_._h_:_1_0_5 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _p_a_t_c_h_P_a_r_a_m_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00740.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchParam.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/far/patchDescriptor.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -91,50 +91,48 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces | │ │ │ │ Typedefs
│ │ │ │ -
patchParam.h File Reference
│ │ │ │ +
patchDescriptor.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../far/types.h"
│ │ │ │ +#include "../sdc/types.h"
│ │ │ │ +#include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  PatchParam
 Patch parameterization. More...
class  PatchDescriptor
 Describes the type of a patch. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │

│ │ │ │ Typedefs

typedef std::vector< PatchParamPatchParamTable
 
typedef Vtr::Array< PatchParamPatchParamArray
 
typedef Vtr::ConstArray< PatchParamConstPatchParamArray
 
typedef Vtr::ConstArray< PatchDescriptorConstPatchDescriptorArray
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,31 +1,29 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s │ │ │ │ │ -patchParam.h File Reference │ │ │ │ │ +patchDescriptor.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ #include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_t_y_p_e_s_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -struct   _P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -  Patch parameterization. _M_o_r_e_._._. │ │ │ │ │ +class   _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +  Describes the type of a patch. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ TTyyppeeddeeffss │ │ │ │ │ - typedef std::vector< _P_a_t_c_h_P_a_r_a_m >  _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ -  │ │ │ │ │ - typedef _V_t_r_:_:_A_r_r_a_y< _P_a_t_c_h_P_a_r_a_m >  _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ -  │ │ │ │ │ -typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y< _P_a_t_c_h_P_a_r_a_m >  _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ +typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y< _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r >  _C_o_n_s_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_A_r_r_a_y │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_P_a_r_a_m_._h │ │ │ │ │ + * _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00740.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,6 +1,4 @@ │ │ │ │ │ var a00740 = [ │ │ │ │ │ - ["PatchParam", "a00989.html", "a00989"], │ │ │ │ │ - ["ConstPatchParamArray", "a00740.html#a3139c7c52ddf26b2403e8e95ff63eeb3", null], │ │ │ │ │ - ["PatchParamArray", "a00740.html#abe07210a029a01571c54276ae28b4d88", null], │ │ │ │ │ - ["PatchParamTable", "a00740.html#a46ea68db89cc3d55c4191ef7648281ce", null] │ │ │ │ │ + ["PatchDescriptor", "a00973.html", "a00973"], │ │ │ │ │ + ["ConstPatchDescriptorArray", "a00740.html#ad258c2d8f7871bc0d40cf3a9ded6e08a", null] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00740_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/far/patchParam.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/far/patchDescriptor.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
patchParam.h
│ │ │ │ +
patchDescriptor.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,214 +119,226 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_FAR_PATCH_PARAM_H
│ │ │ │ -
26#define OPENSUBDIV3_FAR_PATCH_PARAM_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H
│ │ │ │ +
26#define OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │
30#include "../far/types.h"
│ │ │ │ -
31
│ │ │ │ -
32namespace OpenSubdiv {
│ │ │ │ -
33namespace OPENSUBDIV_VERSION {
│ │ │ │ +
31#include "../sdc/types.h"
│ │ │ │ +
32
│ │ │ │ +
33#include <vector>
│ │ │ │
34
│ │ │ │ -
35namespace Far {
│ │ │ │ -
36
│ │ │ │ -
101
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
168 void Set(Index faceid, short u, short v,
│ │ │ │ -
169 unsigned short depth, bool nonquad,
│ │ │ │ -
170 unsigned short boundary, unsigned short transition,
│ │ │ │ -
171 bool regular = false);
│ │ │ │ -
172
│ │ │ │ -
174 void Clear() { field0 = field1 = 0; }
│ │ │ │ -
175
│ │ │ │ -
177 Index GetFaceId() const { return Index(unpack(field0,28,0)); }
│ │ │ │ -
178
│ │ │ │ -
181 unsigned short GetU() const { return (unsigned short)unpack(field1,10,22); }
│ │ │ │ -
182
│ │ │ │ -
185 unsigned short GetV() const { return (unsigned short)unpack(field1,10,12); }
│ │ │ │ -
186
│ │ │ │ -
188 unsigned short GetTransition() const { return (unsigned short)unpack(field0,4,28); }
│ │ │ │ -
189
│ │ │ │ -
191 unsigned short GetBoundary() const { return (unsigned short)unpack(field1,5,7); }
│ │ │ │ +
35namespace OpenSubdiv {
│ │ │ │ +
36namespace OPENSUBDIV_VERSION {
│ │ │ │ +
37
│ │ │ │ +
38namespace Far {
│ │ │ │ +
39
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
45
│ │ │ │ +
46public:
│ │ │ │ +
47
│ │ │ │ +
│ │ │ │ +
48 enum Type {
│ │ │ │ + │ │ │ │ +
50
│ │ │ │ + │ │ │ │ + │ │ │ │ +
53
│ │ │ │ + │ │ │ │ + │ │ │ │ +
56
│ │ │ │ + │ │ │ │ +
58
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
64 };
│ │ │ │ +
│ │ │ │ +
65
│ │ │ │ +
66public:
│ │ │ │ +
67
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
70 _type(NON_PATCH) { }
│ │ │ │ +
│ │ │ │ +
71
│ │ │ │ +
│ │ │ │ +
73 PatchDescriptor(int type) :
│ │ │ │ +
74 _type(type) { }
│ │ │ │ +
│ │ │ │ +
75
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
78 _type(d.GetType()) { }
│ │ │ │ +
│ │ │ │ +
79
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
82 _type = d.GetType();
│ │ │ │ +
83 return *this;
│ │ │ │ +
84 }
│ │ │ │ +
│ │ │ │ +
85
│ │ │ │ +
│ │ │ │ +
87 Type GetType() const {
│ │ │ │ +
88 return (Type)_type;
│ │ │ │ +
89 }
│ │ │ │ +
│ │ │ │ +
90
│ │ │ │ +
│ │ │ │ +
92 static inline bool IsAdaptive(Type type) {
│ │ │ │ +
93 return type > TRIANGLES;
│ │ │ │ +
94 }
│ │ │ │ +
│ │ │ │ +
95
│ │ │ │ +
│ │ │ │ +
97 bool IsAdaptive() const {
│ │ │ │ +
98 return IsAdaptive( this->GetType() );
│ │ │ │ +
99 }
│ │ │ │ +
│ │ │ │ +
100
│ │ │ │ +
103 static inline short GetNumControlVertices( Type t );
│ │ │ │ +
104
│ │ │ │ +
106 static inline short GetNumFVarControlVertices( Type t );
│ │ │ │ +
107
│ │ │ │ +
│ │ │ │ +
110 short GetNumControlVertices() const {
│ │ │ │ +
111 return GetNumControlVertices( this->GetType() );
│ │ │ │ +
112 }
│ │ │ │ +
│ │ │ │ +
113
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
116 return GetNumFVarControlVertices( this->GetType() );
│ │ │ │ +
117 }
│ │ │ │ +
│ │ │ │ +
118
│ │ │ │ +
120 static short GetRegularPatchSize() { return 16; }
│ │ │ │ +
121
│ │ │ │ +
123 static short GetGregoryPatchSize() { return 4; }
│ │ │ │ +
124
│ │ │ │ +
126 static short GetGregoryBasisPatchSize() { return 20; }
│ │ │ │ +
127
│ │ │ │ +
128
│ │ │ │ + │ │ │ │ +
132
│ │ │ │ +
134 inline bool operator < ( PatchDescriptor const other ) const;
│ │ │ │ +
135
│ │ │ │ +
137 inline bool operator == ( PatchDescriptor const other ) const;
│ │ │ │ +
138
│ │ │ │ +
139 // debug helper
│ │ │ │ +
140 void print() const;
│ │ │ │ +
141
│ │ │ │ +
142private:
│ │ │ │ +
143 unsigned int _type;
│ │ │ │ +
144};
│ │ │ │ +
│ │ │ │ +
145
│ │ │ │ + │ │ │ │ +
147
│ │ │ │ +
148// Returns the number of control vertices expected for a patch of this type
│ │ │ │ +
149inline short
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
151 switch (type) {
│ │ │ │ +
152 case REGULAR : return GetRegularPatchSize();
│ │ │ │ +
153 case LOOP : return 12;
│ │ │ │ +
154 case QUADS : return 4;
│ │ │ │ +
155 case GREGORY :
│ │ │ │ + │ │ │ │ + │ │ │ │ +
158 case GREGORY_TRIANGLE : return 18;
│ │ │ │ +
159 case TRIANGLES : return 3;
│ │ │ │ +
160 case LINES : return 2;
│ │ │ │ +
161 case POINTS : return 1;
│ │ │ │ +
162 default : return -1;
│ │ │ │ +
163 }
│ │ │ │ +
164}
│ │ │ │ +
│ │ │ │ +
165
│ │ │ │ +
166// Returns the number of face-varying control vertices expected for a patch of this type
│ │ │ │ +
167inline short
│ │ │ │ +
│ │ │ │ + │ │ │ │ + │ │ │ │ +
170}
│ │ │ │ +
│ │ │ │ +
171
│ │ │ │ +
172// Allows ordering of patches by type
│ │ │ │ +
│ │ │ │ +
173inline bool
│ │ │ │ + │ │ │ │ +
175 return (_type < other._type);
│ │ │ │ +
176}
│ │ │ │ +
│ │ │ │ +
177
│ │ │ │ +
178// True if the descriptors are identical
│ │ │ │ +
179inline bool
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
181 return _type == other._type;
│ │ │ │ +
182}
│ │ │ │ +
│ │ │ │ +
183
│ │ │ │ +
184
│ │ │ │ +
185
│ │ │ │ +
186} // end namespace Far
│ │ │ │ +
187
│ │ │ │ +
188} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
189using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
190
│ │ │ │ +
191} // end namespace OpenSubdiv
│ │ │ │
192
│ │ │ │ -
194 bool NonQuadRoot() const { return (unpack(field1,1,4) != 0); }
│ │ │ │ -
195
│ │ │ │ -
197 unsigned short GetDepth() const { return (unsigned short)unpack(field1,4,0); }
│ │ │ │ -
198
│ │ │ │ -
200 float GetParamFraction() const;
│ │ │ │ -
201
│ │ │ │ -
208 template <typename REAL>
│ │ │ │ -
209 void Normalize( REAL & u, REAL & v ) const;
│ │ │ │ -
210 template <typename REAL>
│ │ │ │ -
211 void NormalizeTriangle( REAL & u, REAL & v ) const;
│ │ │ │ -
212
│ │ │ │ -
219 template <typename REAL>
│ │ │ │ -
220 void Unnormalize( REAL & u, REAL & v ) const;
│ │ │ │ -
221 template <typename REAL>
│ │ │ │ -
222 void UnnormalizeTriangle( REAL & u, REAL & v ) const;
│ │ │ │ -
223
│ │ │ │ -
225 bool IsTriangleRotated() const;
│ │ │ │ -
226
│ │ │ │ -
228 bool IsRegular() const { return (unpack(field1,1,5) != 0); }
│ │ │ │ -
229
│ │ │ │ -
230 unsigned int field0:32;
│ │ │ │ -
231 unsigned int field1:32;
│ │ │ │ -
232
│ │ │ │ -
233private:
│ │ │ │ -
234 unsigned int pack(unsigned int value, int width, int offset) const {
│ │ │ │ -
235 return (unsigned int)((value & ((1<<width)-1)) << offset);
│ │ │ │ -
236 }
│ │ │ │ -
237
│ │ │ │ -
238 unsigned int unpack(unsigned int value, int width, int offset) const {
│ │ │ │ -
239 return (unsigned int)((value >> offset) & ((1<<width)-1));
│ │ │ │ -
240 }
│ │ │ │ -
241};
│ │ │ │ -
│ │ │ │ -
242
│ │ │ │ -
243typedef std::vector<PatchParam> PatchParamTable;
│ │ │ │ -
244
│ │ │ │ - │ │ │ │ - │ │ │ │ -
247
│ │ │ │ -
248inline void
│ │ │ │ -
│ │ │ │ -
249PatchParam::Set(Index faceid, short u, short v,
│ │ │ │ -
250 unsigned short depth, bool nonquad,
│ │ │ │ -
251 unsigned short boundary, unsigned short transition,
│ │ │ │ -
252 bool regular) {
│ │ │ │ -
253 field0 = pack(faceid, 28, 0) |
│ │ │ │ -
254 pack(transition, 4, 28);
│ │ │ │ -
255
│ │ │ │ -
256 field1 = pack(u, 10, 22) |
│ │ │ │ -
257 pack(v, 10, 12) |
│ │ │ │ -
258 pack(boundary, 5, 7) |
│ │ │ │ -
259 pack(regular, 1, 5) |
│ │ │ │ -
260 pack(nonquad, 1, 4) |
│ │ │ │ -
261 pack(depth, 4, 0);
│ │ │ │ -
262}
│ │ │ │ -
│ │ │ │ -
263
│ │ │ │ -
264inline float
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
266 return 1.0f / (float)(1 << (GetDepth() - NonQuadRoot()));
│ │ │ │ -
267}
│ │ │ │ -
│ │ │ │ -
268
│ │ │ │ -
269template <typename REAL>
│ │ │ │ -
270inline void
│ │ │ │ -
│ │ │ │ -
271PatchParam::Normalize( REAL & u, REAL & v ) const {
│ │ │ │ -
272
│ │ │ │ -
273 REAL fracInv = (REAL)(1.0f / GetParamFraction());
│ │ │ │ -
274
│ │ │ │ -
275 u = u * fracInv - (REAL)GetU();
│ │ │ │ -
276 v = v * fracInv - (REAL)GetV();
│ │ │ │ -
277}
│ │ │ │ -
│ │ │ │ -
278
│ │ │ │ -
279template <typename REAL>
│ │ │ │ -
280inline void
│ │ │ │ -
│ │ │ │ -
281PatchParam::Unnormalize( REAL & u, REAL & v ) const {
│ │ │ │ -
282
│ │ │ │ -
283 REAL frac = (REAL)GetParamFraction();
│ │ │ │ -
284
│ │ │ │ -
285 u = (u + (REAL)GetU()) * frac;
│ │ │ │ -
286 v = (v + (REAL)GetV()) * frac;
│ │ │ │ -
287}
│ │ │ │ -
│ │ │ │ -
288
│ │ │ │ -
289inline bool
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
291
│ │ │ │ -
292 return (GetU() + GetV()) >= (1 << GetDepth());
│ │ │ │ -
293}
│ │ │ │ -
│ │ │ │ -
294
│ │ │ │ -
295template <typename REAL>
│ │ │ │ -
296inline void
│ │ │ │ -
│ │ │ │ -
297PatchParam::NormalizeTriangle( REAL & u, REAL & v ) const {
│ │ │ │ -
298
│ │ │ │ -
299 if (IsTriangleRotated()) {
│ │ │ │ -
300 REAL fracInv = (REAL)(1.0f / GetParamFraction());
│ │ │ │ -
301
│ │ │ │ -
302 int depthFactor = 1 << GetDepth();
│ │ │ │ -
303 u = (REAL)(depthFactor - GetU()) - (u * fracInv);
│ │ │ │ -
304 v = (REAL)(depthFactor - GetV()) - (v * fracInv);
│ │ │ │ -
305 } else {
│ │ │ │ -
306 Normalize(u, v);
│ │ │ │ -
307 }
│ │ │ │ -
308}
│ │ │ │ -
│ │ │ │ -
309
│ │ │ │ -
310template <typename REAL>
│ │ │ │ -
311inline void
│ │ │ │ -
│ │ │ │ -
312PatchParam::UnnormalizeTriangle( REAL & u, REAL & v ) const {
│ │ │ │ -
313
│ │ │ │ -
314 if (IsTriangleRotated()) {
│ │ │ │ -
315 REAL frac = GetParamFraction();
│ │ │ │ -
316
│ │ │ │ -
317 int depthFactor = 1 << GetDepth();
│ │ │ │ -
318 u = ((REAL)(depthFactor - GetU()) - u) * frac;
│ │ │ │ -
319 v = ((REAL)(depthFactor - GetV()) - v) * frac;
│ │ │ │ -
320 } else {
│ │ │ │ -
321 Unnormalize(u, v);
│ │ │ │ -
322 }
│ │ │ │ -
323}
│ │ │ │ -
│ │ │ │ -
324
│ │ │ │ -
325} // end namespace Far
│ │ │ │ -
326
│ │ │ │ -
327} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
328using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
329
│ │ │ │ -
330} // end namespace OpenSubdiv
│ │ │ │ -
331
│ │ │ │ -
332#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */
│ │ │ │ +
193#endif /* OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H */
│ │ │ │ │ │ │ │ -
Vtr::ConstArray< PatchParam > ConstPatchParamArray
Definition patchParam.h:246
│ │ │ │ -
std::vector< PatchParam > PatchParamTable
Definition patchParam.h:243
│ │ │ │ - │ │ │ │ -
Vtr::Array< PatchParam > PatchParamArray
Definition patchParam.h:245
│ │ │ │ - │ │ │ │ -
bool IsTriangleRotated() const
Returns if a triangular patch is parametrically rotated 180 degrees.
Definition patchParam.h:290
│ │ │ │ -
bool IsRegular() const
Returns whether the patch is regular.
Definition patchParam.h:228
│ │ │ │ -
void NormalizeTriangle(REAL &u, REAL &v) const
Definition patchParam.h:297
│ │ │ │ -
unsigned short GetBoundary() const
Returns the boundary edge encoding for the patch.
Definition patchParam.h:191
│ │ │ │ -
unsigned short GetTransition() const
Returns the transition edge encoding for the patch.
Definition patchParam.h:188
│ │ │ │ -
float GetParamFraction() const
Returns the fraction of unit parametric space covered by this face.
Definition patchParam.h:265
│ │ │ │ -
unsigned short GetU() const
Returns the log2 value of the u parameter at the first corner of the patch.
Definition patchParam.h:181
│ │ │ │ -
Index GetFaceId() const
Returns the faceid.
Definition patchParam.h:177
│ │ │ │ -
unsigned short GetDepth() const
Returns the level of subdivision of the patch.
Definition patchParam.h:197
│ │ │ │ -
bool NonQuadRoot() const
True if the parent base face is a non-quad.
Definition patchParam.h:194
│ │ │ │ -
void Set(Index faceid, short u, short v, unsigned short depth, bool nonquad, unsigned short boundary, unsigned short transition, bool regular=false)
Sets the values of the bit fields.
Definition patchParam.h:249
│ │ │ │ - │ │ │ │ - │ │ │ │ -
void Unnormalize(REAL &u, REAL &v) const
A (u,v) pair in a normalized parametric space is mapped back into the fraction of parametric space co...
Definition patchParam.h:281
│ │ │ │ -
void UnnormalizeTriangle(REAL &u, REAL &v) const
Definition patchParam.h:312
│ │ │ │ -
unsigned short GetV() const
Returns the log2 value of the v parameter at the first corner of the patch.
Definition patchParam.h:185
│ │ │ │ - │ │ │ │ -
void Normalize(REAL &u, REAL &v) const
A (u,v) pair in the fraction of parametric space covered by this face is mapped into a normalized par...
Definition patchParam.h:271
│ │ │ │ +
Vtr::ConstArray< PatchDescriptor > ConstPatchDescriptorArray
│ │ │ │ +
SchemeType
Enumerated type for all subdivision schemes supported by OpenSubdiv.
Definition types.h:37
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
@ LOOP
regular triangular patch for the Loop scheme
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
@ REGULAR
regular B-Spline patch for the Catmark scheme
│ │ │ │ +
bool IsAdaptive() const
Returns true if the type is an adaptive patch.
│ │ │ │ +
Type GetType() const
Returns the type of the patch.
│ │ │ │ +
static short GetGregoryBasisPatchSize()
Number of control vertices of Gregory patch basis (20)
│ │ │ │ +
short GetNumControlVertices() const
Returns the number of control vertices expected for a patch of the type described.
│ │ │ │ +
PatchDescriptor(PatchDescriptor const &d)
Copy Constructor.
│ │ │ │ +
bool operator==(PatchDescriptor const other) const
True if the descriptors are identical.
│ │ │ │ +
static short GetRegularPatchSize()
Number of control vertices of Regular Patches in table.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
PatchDescriptor & operator=(PatchDescriptor const &d)
Assignment operator.
│ │ │ │ +
static bool IsAdaptive(Type type)
Returns true if the type is an adaptive (non-linear) patch.
│ │ │ │ +
bool operator<(PatchDescriptor const other) const
Allows ordering of patches by type.
│ │ │ │ +
static short GetGregoryPatchSize()
Number of control vertices of Gregory (and Gregory Boundary) Patches in table.
│ │ │ │ + │ │ │ │ +
static Vtr::ConstArray< PatchDescriptor > GetAdaptivePatchDescriptors(Sdc::SchemeType type)
Returns a vector of all the legal patch descriptors for the given adaptive subdivision scheme.
│ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -patchParam.h │ │ │ │ │ +patchDescriptor.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,262 +24,280 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_FAR_PATCH_PARAM_H │ │ │ │ │ -26#define OPENSUBDIV3_FAR_PATCH_PARAM_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H │ │ │ │ │ +26#define OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ 30#include "../far/types.h" │ │ │ │ │ -31 │ │ │ │ │ -32namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -33namespace OPENSUBDIV_VERSION { │ │ │ │ │ +31#include "../sdc/types.h" │ │ │ │ │ +32 │ │ │ │ │ +33#include │ │ │ │ │ 34 │ │ │ │ │ -35namespace Far { │ │ │ │ │ -36 │ │ │ │ │ -101 │ │ │ │ │ -_1_5_2struct _P_a_t_c_h_P_a_r_a_m { │ │ │ │ │ -168 void _S_e_t(_I_n_d_e_x faceid, short u, short v, │ │ │ │ │ -169 unsigned short depth, bool nonquad, │ │ │ │ │ -170 unsigned short boundary, unsigned short transition, │ │ │ │ │ -171 bool regular = false); │ │ │ │ │ -172 │ │ │ │ │ -_1_7_4 void _C_l_e_a_r() { _f_i_e_l_d_0 = _f_i_e_l_d_1 = 0; } │ │ │ │ │ -175 │ │ │ │ │ -_1_7_7 _I_n_d_e_x _G_e_t_F_a_c_e_I_d() const { return _I_n_d_e_x(unpack(_f_i_e_l_d_0,28,0)); } │ │ │ │ │ -178 │ │ │ │ │ -_1_8_1 unsigned short _G_e_t_U() const { return (unsigned short)unpack(_f_i_e_l_d_1,10,22); │ │ │ │ │ -} │ │ │ │ │ -182 │ │ │ │ │ -_1_8_5 unsigned short _G_e_t_V() const { return (unsigned short)unpack(_f_i_e_l_d_1,10,12); │ │ │ │ │ -} │ │ │ │ │ -186 │ │ │ │ │ -_1_8_8 unsigned short _G_e_t_T_r_a_n_s_i_t_i_o_n() const { return (unsigned short)unpack │ │ │ │ │ -(_f_i_e_l_d_0,4,28); } │ │ │ │ │ -189 │ │ │ │ │ -_1_9_1 unsigned short _G_e_t_B_o_u_n_d_a_r_y() const { return (unsigned short)unpack │ │ │ │ │ -(_f_i_e_l_d_1,5,7); } │ │ │ │ │ +35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +36namespace OPENSUBDIV_VERSION { │ │ │ │ │ +37 │ │ │ │ │ +38namespace Far { │ │ │ │ │ +39 │ │ │ │ │ +_4_4class _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ +45 │ │ │ │ │ +46public: │ │ │ │ │ +47 │ │ │ │ │ +_4_8 enum _T_y_p_e { │ │ │ │ │ +_4_9 _N_O_N___P_A_T_C_H = 0, │ │ │ │ │ +50 │ │ │ │ │ +_5_1 _P_O_I_N_T_S, │ │ │ │ │ +_5_2 _L_I_N_E_S, │ │ │ │ │ +53 │ │ │ │ │ +_5_4 _Q_U_A_D_S, │ │ │ │ │ +_5_5 _T_R_I_A_N_G_L_E_S, │ │ │ │ │ +56 │ │ │ │ │ +_5_7 _L_O_O_P, │ │ │ │ │ +58 │ │ │ │ │ +_5_9 _R_E_G_U_L_A_R, │ │ │ │ │ +_6_0 _G_R_E_G_O_R_Y, │ │ │ │ │ +_6_1 _G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y, │ │ │ │ │ +_6_2 _G_R_E_G_O_R_Y___B_A_S_I_S, │ │ │ │ │ +63 _G_R_E_G_O_R_Y___T_R_I_A_N_G_L_E │ │ │ │ │ +_6_4 }; │ │ │ │ │ +65 │ │ │ │ │ +66public: │ │ │ │ │ +67 │ │ │ │ │ +_6_9 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r() : │ │ │ │ │ +70 _type(_N_O_N___P_A_T_C_H) { } │ │ │ │ │ +71 │ │ │ │ │ +_7_3 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r(int type) : │ │ │ │ │ +74 _type(type) { } │ │ │ │ │ +75 │ │ │ │ │ +_7_7 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const & d ) : │ │ │ │ │ +78 _type(d._G_e_t_T_y_p_e()) { } │ │ │ │ │ +79 │ │ │ │ │ +_8_1 _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r & _o_p_e_r_a_t_o_r_=( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const & d ) { │ │ │ │ │ +82 _type = d._G_e_t_T_y_p_e(); │ │ │ │ │ +83 return *this; │ │ │ │ │ +84 } │ │ │ │ │ +85 │ │ │ │ │ +_8_7 _T_y_p_e _G_e_t_T_y_p_e() const { │ │ │ │ │ +88 return (_T_y_p_e)_type; │ │ │ │ │ +89 } │ │ │ │ │ +90 │ │ │ │ │ +_9_2 static inline bool _I_s_A_d_a_p_t_i_v_e(_T_y_p_e type) { │ │ │ │ │ +93 return type > _T_R_I_A_N_G_L_E_S; │ │ │ │ │ +94 } │ │ │ │ │ +95 │ │ │ │ │ +_9_7 bool _I_s_A_d_a_p_t_i_v_e() const { │ │ │ │ │ +98 return _I_s_A_d_a_p_t_i_v_e( this->_G_e_t_T_y_p_e() ); │ │ │ │ │ +99 } │ │ │ │ │ +100 │ │ │ │ │ +103 static inline short _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e t ); │ │ │ │ │ +104 │ │ │ │ │ +106 static inline short _G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e t ); │ │ │ │ │ +107 │ │ │ │ │ +_1_1_0 short _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s() const { │ │ │ │ │ +111 return _G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( this->_G_e_t_T_y_p_e() ); │ │ │ │ │ +112 } │ │ │ │ │ +113 │ │ │ │ │ +_1_1_5 short _G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s() const { │ │ │ │ │ +116 return _G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( this->_G_e_t_T_y_p_e() ); │ │ │ │ │ +117 } │ │ │ │ │ +118 │ │ │ │ │ +_1_2_0 static short _G_e_t_R_e_g_u_l_a_r_P_a_t_c_h_S_i_z_e() { return 16; } │ │ │ │ │ +121 │ │ │ │ │ +_1_2_3 static short _G_e_t_G_r_e_g_o_r_y_P_a_t_c_h_S_i_z_e() { return 4; } │ │ │ │ │ +124 │ │ │ │ │ +_1_2_6 static short _G_e_t_G_r_e_g_o_r_y_B_a_s_i_s_P_a_t_c_h_S_i_z_e() { return 20; } │ │ │ │ │ +127 │ │ │ │ │ +128 │ │ │ │ │ +_1_3_1 static _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_> _G_e_t_A_d_a_p_t_i_v_e_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_s(_S_d_c_:_: │ │ │ │ │ +_S_c_h_e_m_e_T_y_p_e type); │ │ │ │ │ +132 │ │ │ │ │ +134 inline bool _o_p_e_r_a_t_o_r_ _<_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const; │ │ │ │ │ +135 │ │ │ │ │ +137 inline bool _o_p_e_r_a_t_o_r_ _=_=_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const; │ │ │ │ │ +138 │ │ │ │ │ +139 // debug helper │ │ │ │ │ +_1_4_0 void _p_r_i_n_t() const; │ │ │ │ │ +141 │ │ │ │ │ +142private: │ │ │ │ │ +143 unsigned int _type; │ │ │ │ │ +144}; │ │ │ │ │ +145 │ │ │ │ │ +_1_4_6typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_> _C_o_n_s_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_A_r_r_a_y; │ │ │ │ │ +147 │ │ │ │ │ +148// Returns the number of control vertices expected for a patch of this type │ │ │ │ │ +149inline short │ │ │ │ │ +_1_5_0_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e type ) { │ │ │ │ │ +151 switch (type) { │ │ │ │ │ +152 case _R_E_G_U_L_A_R : return _G_e_t_R_e_g_u_l_a_r_P_a_t_c_h_S_i_z_e(); │ │ │ │ │ +153 case _L_O_O_P : return 12; │ │ │ │ │ +154 case _Q_U_A_D_S : return 4; │ │ │ │ │ +155 case _G_R_E_G_O_R_Y : │ │ │ │ │ +156 case _G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y : return _G_e_t_G_r_e_g_o_r_y_P_a_t_c_h_S_i_z_e(); │ │ │ │ │ +157 case _G_R_E_G_O_R_Y___B_A_S_I_S : return _G_e_t_G_r_e_g_o_r_y_B_a_s_i_s_P_a_t_c_h_S_i_z_e(); │ │ │ │ │ +158 case _G_R_E_G_O_R_Y___T_R_I_A_N_G_L_E : return 18; │ │ │ │ │ +159 case _T_R_I_A_N_G_L_E_S : return 3; │ │ │ │ │ +160 case _L_I_N_E_S : return 2; │ │ │ │ │ +161 case _P_O_I_N_T_S : return 1; │ │ │ │ │ +162 default : return -1; │ │ │ │ │ +163 } │ │ │ │ │ +164} │ │ │ │ │ +165 │ │ │ │ │ +166// Returns the number of face-varying control vertices expected for a patch │ │ │ │ │ +of this type │ │ │ │ │ +167inline short │ │ │ │ │ +_1_6_8_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s( _T_y_p_e type ) { │ │ │ │ │ +169 return _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s(type); │ │ │ │ │ +170} │ │ │ │ │ +171 │ │ │ │ │ +172// Allows ordering of patches by type │ │ │ │ │ +_1_7_3inline bool │ │ │ │ │ +174_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_ _<_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const { │ │ │ │ │ +175 return (_type < other._type); │ │ │ │ │ +176} │ │ │ │ │ +177 │ │ │ │ │ +178// True if the descriptors are identical │ │ │ │ │ +179inline bool │ │ │ │ │ +_1_8_0_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_ _=_=_ ( _P_a_t_c_h_D_e_s_c_r_i_p_t_o_r const other ) const { │ │ │ │ │ +181 return _type == other._type; │ │ │ │ │ +182} │ │ │ │ │ +183 │ │ │ │ │ +184 │ │ │ │ │ +185 │ │ │ │ │ +186} // end namespace Far │ │ │ │ │ +187 │ │ │ │ │ +188} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +189using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +190 │ │ │ │ │ +191} // end namespace OpenSubdiv │ │ │ │ │ 192 │ │ │ │ │ -_1_9_4 bool _N_o_n_Q_u_a_d_R_o_o_t() const { return (unpack(_f_i_e_l_d_1,1,4) != 0); } │ │ │ │ │ -195 │ │ │ │ │ -_1_9_7 unsigned short _G_e_t_D_e_p_t_h() const { return (unsigned short)unpack │ │ │ │ │ -(_f_i_e_l_d_1,4,0); } │ │ │ │ │ -198 │ │ │ │ │ -200 float _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n() const; │ │ │ │ │ -201 │ │ │ │ │ -208 template │ │ │ │ │ -209 void _N_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const; │ │ │ │ │ -210 template │ │ │ │ │ -211 void _N_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const; │ │ │ │ │ -212 │ │ │ │ │ -219 template │ │ │ │ │ -220 void _U_n_n_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const; │ │ │ │ │ -221 template │ │ │ │ │ -222 void _U_n_n_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const; │ │ │ │ │ -223 │ │ │ │ │ -225 bool _I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d() const; │ │ │ │ │ -226 │ │ │ │ │ -_2_2_8 bool _I_s_R_e_g_u_l_a_r() const { return (unpack(_f_i_e_l_d_1,1,5) != 0); } │ │ │ │ │ -229 │ │ │ │ │ -_2_3_0 unsigned int _f_i_e_l_d_0:32; │ │ │ │ │ -_2_3_1 unsigned int _f_i_e_l_d_1:32; │ │ │ │ │ -232 │ │ │ │ │ -233private: │ │ │ │ │ -234 unsigned int pack(unsigned int value, int width, int offset) const { │ │ │ │ │ -235 return (unsigned int)((value & ((1<> offset) & ((1< _P_a_t_c_h_P_a_r_a_m_T_a_b_l_e; │ │ │ │ │ -244 │ │ │ │ │ -_2_4_5typedef _V_t_r_:_:_A_r_r_a_y_<_P_a_t_c_h_P_a_r_a_m_> _P_a_t_c_h_P_a_r_a_m_A_r_r_a_y; │ │ │ │ │ -_2_4_6typedef _V_t_r_:_:_C_o_n_s_t_A_r_r_a_y_<_P_a_t_c_h_P_a_r_a_m_> _C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y; │ │ │ │ │ -247 │ │ │ │ │ -248inline void │ │ │ │ │ -_2_4_9_P_a_t_c_h_P_a_r_a_m_:_:_S_e_t(_I_n_d_e_x faceid, short u, short v, │ │ │ │ │ -250 unsigned short depth, bool nonquad, │ │ │ │ │ -251 unsigned short boundary, unsigned short transition, │ │ │ │ │ -252 bool regular) { │ │ │ │ │ -253 _f_i_e_l_d_0 = pack(faceid, 28, 0) | │ │ │ │ │ -254 pack(transition, 4, 28); │ │ │ │ │ -255 │ │ │ │ │ -256 _f_i_e_l_d_1 = pack(u, 10, 22) | │ │ │ │ │ -257 pack(v, 10, 12) | │ │ │ │ │ -258 pack(boundary, 5, 7) | │ │ │ │ │ -259 pack(regular, 1, 5) | │ │ │ │ │ -260 pack(nonquad, 1, 4) | │ │ │ │ │ -261 pack(depth, 4, 0); │ │ │ │ │ -262} │ │ │ │ │ -263 │ │ │ │ │ -264inline float │ │ │ │ │ -_2_6_5_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n( ) const { │ │ │ │ │ -266 return 1.0f / (float)(1 << (_G_e_t_D_e_p_t_h() - _N_o_n_Q_u_a_d_R_o_o_t())); │ │ │ │ │ -267} │ │ │ │ │ -268 │ │ │ │ │ -269template │ │ │ │ │ -270inline void │ │ │ │ │ -_2_7_1_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const { │ │ │ │ │ -272 │ │ │ │ │ -273 REAL fracInv = (REAL)(1.0f / _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n()); │ │ │ │ │ -274 │ │ │ │ │ -275 u = u * fracInv - (REAL)_G_e_t_U(); │ │ │ │ │ -276 v = v * fracInv - (REAL)_G_e_t_V(); │ │ │ │ │ -277} │ │ │ │ │ -278 │ │ │ │ │ -279template │ │ │ │ │ -280inline void │ │ │ │ │ -_2_8_1_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e( REAL & u, REAL & v ) const { │ │ │ │ │ -282 │ │ │ │ │ -283 REAL frac = (REAL)_G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n(); │ │ │ │ │ -284 │ │ │ │ │ -285 u = (u + (REAL)_G_e_t_U()) * frac; │ │ │ │ │ -286 v = (v + (REAL)_G_e_t_V()) * frac; │ │ │ │ │ -287} │ │ │ │ │ -288 │ │ │ │ │ -289inline bool │ │ │ │ │ -_2_9_0_P_a_t_c_h_P_a_r_a_m_:_:_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d() const { │ │ │ │ │ -291 │ │ │ │ │ -292 return (_G_e_t_U() + _G_e_t_V()) >= (1 << _G_e_t_D_e_p_t_h()); │ │ │ │ │ -293} │ │ │ │ │ -294 │ │ │ │ │ -295template │ │ │ │ │ -296inline void │ │ │ │ │ -_2_9_7_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const { │ │ │ │ │ -298 │ │ │ │ │ -299 if (_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d()) { │ │ │ │ │ -300 REAL fracInv = (REAL)(1.0f / _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n()); │ │ │ │ │ -301 │ │ │ │ │ -302 int depthFactor = 1 << _G_e_t_D_e_p_t_h(); │ │ │ │ │ -303 u = (REAL)(depthFactor - _G_e_t_U()) - (u * fracInv); │ │ │ │ │ -304 v = (REAL)(depthFactor - _G_e_t_V()) - (v * fracInv); │ │ │ │ │ -305 } else { │ │ │ │ │ -306 _N_o_r_m_a_l_i_z_e(u, v); │ │ │ │ │ -307 } │ │ │ │ │ -308} │ │ │ │ │ -309 │ │ │ │ │ -310template │ │ │ │ │ -311inline void │ │ │ │ │ -_3_1_2_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e( REAL & u, REAL & v ) const { │ │ │ │ │ -313 │ │ │ │ │ -314 if (_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d()) { │ │ │ │ │ -315 REAL frac = _G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n(); │ │ │ │ │ -316 │ │ │ │ │ -317 int depthFactor = 1 << _G_e_t_D_e_p_t_h(); │ │ │ │ │ -318 u = ((REAL)(depthFactor - _G_e_t_U()) - u) * frac; │ │ │ │ │ -319 v = ((REAL)(depthFactor - _G_e_t_V()) - v) * frac; │ │ │ │ │ -320 } else { │ │ │ │ │ -321 _U_n_n_o_r_m_a_l_i_z_e(u, v); │ │ │ │ │ -322 } │ │ │ │ │ -323} │ │ │ │ │ -324 │ │ │ │ │ -325} // end namespace Far │ │ │ │ │ -326 │ │ │ │ │ -327} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -328using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -329 │ │ │ │ │ -330} // end namespace OpenSubdiv │ │ │ │ │ -331 │ │ │ │ │ -332#endif /* OPENSUBDIV3_FAR_PATCH_PARAM */ │ │ │ │ │ +193#endif /* OPENSUBDIV3_FAR_PATCH_DESCRIPTOR_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ -Vtr::ConstArray< PatchParam > ConstPatchParamArray │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_T_a_b_l_e │ │ │ │ │ -std::vector< PatchParam > PatchParamTable │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_I_n_d_e_x │ │ │ │ │ -Vtr::Index Index │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_A_r_r_a_y │ │ │ │ │ -Vtr::Array< PatchParam > PatchParamArray │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -Patch parameterization. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_I_s_T_r_i_a_n_g_l_e_R_o_t_a_t_e_d │ │ │ │ │ -bool IsTriangleRotated() const │ │ │ │ │ -Returns if a triangular patch is parametrically rotated 180 degrees. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_9_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_I_s_R_e_g_u_l_a_r │ │ │ │ │ -bool IsRegular() const │ │ │ │ │ -Returns whether the patch is regular. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_2_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e │ │ │ │ │ -void NormalizeTriangle(REAL &u, REAL &v) const │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_9_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_B_o_u_n_d_a_r_y │ │ │ │ │ -unsigned short GetBoundary() const │ │ │ │ │ -Returns the boundary edge encoding for the patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_9_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_T_r_a_n_s_i_t_i_o_n │ │ │ │ │ -unsigned short GetTransition() const │ │ │ │ │ -Returns the transition edge encoding for the patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_P_a_r_a_m_F_r_a_c_t_i_o_n │ │ │ │ │ -float GetParamFraction() const │ │ │ │ │ -Returns the fraction of unit parametric space covered by this face. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_U │ │ │ │ │ -unsigned short GetU() const │ │ │ │ │ -Returns the log2 value of the u parameter at the first corner of the patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_F_a_c_e_I_d │ │ │ │ │ -Index GetFaceId() const │ │ │ │ │ -Returns the faceid. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_D_e_p_t_h │ │ │ │ │ -unsigned short GetDepth() const │ │ │ │ │ -Returns the level of subdivision of the patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_9_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_N_o_n_Q_u_a_d_R_o_o_t │ │ │ │ │ -bool NonQuadRoot() const │ │ │ │ │ -True if the parent base face is a non-quad. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_9_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_S_e_t │ │ │ │ │ -void Set(Index faceid, short u, short v, unsigned short depth, bool nonquad, │ │ │ │ │ -unsigned short boundary, unsigned short transition, bool regular=false) │ │ │ │ │ -Sets the values of the bit fields. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_C_l_e_a_r │ │ │ │ │ -void Clear() │ │ │ │ │ -Resets everything to 0. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_f_i_e_l_d_1 │ │ │ │ │ -unsigned int field1 │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e │ │ │ │ │ -void Unnormalize(REAL &u, REAL &v) const │ │ │ │ │ -A (u,v) pair in a normalized parametric space is mapped back into the fraction │ │ │ │ │ -of parametric space co... │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_U_n_n_o_r_m_a_l_i_z_e_T_r_i_a_n_g_l_e │ │ │ │ │ -void UnnormalizeTriangle(REAL &u, REAL &v) const │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_3_1_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_G_e_t_V │ │ │ │ │ -unsigned short GetV() const │ │ │ │ │ -Returns the log2 value of the v parameter at the first corner of the patch. │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_1_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_f_i_e_l_d_0 │ │ │ │ │ -unsigned int field0 │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_3_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_P_a_r_a_m_:_:_N_o_r_m_a_l_i_z_e │ │ │ │ │ -void Normalize(REAL &u, REAL &v) const │ │ │ │ │ -A (u,v) pair in the fraction of parametric space covered by this face is mapped │ │ │ │ │ -into a normalized par... │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_P_a_r_a_m_._h_:_2_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_C_o_n_s_t_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_A_r_r_a_y │ │ │ │ │ +Vtr::ConstArray< PatchDescriptor > ConstPatchDescriptorArray │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_T_y_p_e │ │ │ │ │ +SchemeType │ │ │ │ │ +Enumerated type for all subdivision schemes supported by OpenSubdiv. │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +Describes the type of a patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e │ │ │ │ │ +Type │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_L_I_N_E_S │ │ │ │ │ +@ LINES │ │ │ │ │ +lines (useful for cage drawing) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_Q_U_A_D_S │ │ │ │ │ +@ QUADS │ │ │ │ │ +4-sided quadrilateral (bilinear) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_N_O_N___P_A_T_C_H │ │ │ │ │ +@ NON_PATCH │ │ │ │ │ +undefined │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_L_O_O_P │ │ │ │ │ +@ LOOP │ │ │ │ │ +regular triangular patch for the Loop scheme │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___T_R_I_A_N_G_L_E │ │ │ │ │ +@ GREGORY_TRIANGLE │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_R_I_A_N_G_L_E_S │ │ │ │ │ +@ TRIANGLES │ │ │ │ │ +3-sided triangle │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y │ │ │ │ │ +@ GREGORY_BOUNDARY │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_A_S_I_S │ │ │ │ │ +@ GREGORY_BASIS │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_O_I_N_T_S │ │ │ │ │ +@ POINTS │ │ │ │ │ +points (useful for cage drawing) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y │ │ │ │ │ +@ GREGORY │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_R_E_G_U_L_A_R │ │ │ │ │ +@ REGULAR │ │ │ │ │ +regular B-Spline patch for the Catmark scheme │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_5_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_I_s_A_d_a_p_t_i_v_e │ │ │ │ │ +bool IsAdaptive() const │ │ │ │ │ +Returns true if the type is an adaptive patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_9_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_T_y_p_e │ │ │ │ │ +Type GetType() const │ │ │ │ │ +Returns the type of the patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_G_r_e_g_o_r_y_B_a_s_i_s_P_a_t_c_h_S_i_z_e │ │ │ │ │ +static short GetGregoryBasisPatchSize() │ │ │ │ │ +Number of control vertices of Gregory patch basis (20) │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_2_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ +short GetNumControlVertices() const │ │ │ │ │ +Returns the number of control vertices expected for a patch of the type │ │ │ │ │ +described. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_1_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor(PatchDescriptor const &d) │ │ │ │ │ +Copy Constructor. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ │ +bool operator==(PatchDescriptor const other) const │ │ │ │ │ +True if the descriptors are identical. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_8_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_R_e_g_u_l_a_r_P_a_t_c_h_S_i_z_e │ │ │ │ │ +static short GetRegularPatchSize() │ │ │ │ │ +Number of control vertices of Regular Patches in table. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_2_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_N_u_m_F_V_a_r_C_o_n_t_r_o_l_V_e_r_t_i_c_e_s │ │ │ │ │ +short GetNumFVarControlVertices() const │ │ │ │ │ +Deprecated. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_1_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor(int type) │ │ │ │ │ +Constructor. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ │ +PatchDescriptor & operator=(PatchDescriptor const &d) │ │ │ │ │ +Assignment operator. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_I_s_A_d_a_p_t_i_v_e │ │ │ │ │ +static bool IsAdaptive(Type type) │ │ │ │ │ +Returns true if the type is an adaptive (non-linear) patch. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_< │ │ │ │ │ +bool operator<(PatchDescriptor const other) const │ │ │ │ │ +Allows ordering of patches by type. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_G_r_e_g_o_r_y_P_a_t_c_h_S_i_z_e │ │ │ │ │ +static short GetGregoryPatchSize() │ │ │ │ │ +Number of control vertices of Gregory (and Gregory Boundary) Patches in table. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_1_2_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_p_r_i_n_t │ │ │ │ │ +void print() const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_: │ │ │ │ │ +_G_e_t_A_d_a_p_t_i_v_e_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_s │ │ │ │ │ +static Vtr::ConstArray< PatchDescriptor > GetAdaptivePatchDescriptors(Sdc:: │ │ │ │ │ +SchemeType type) │ │ │ │ │ +Returns a vector of all the legal patch descriptors for the given adaptive │ │ │ │ │ +subdivision scheme. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +PatchDescriptor() │ │ │ │ │ +Default constructor. │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_9 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_C_o_n_s_t_A_r_r_a_y │ │ │ │ │ DDeeffiinniittiioonn _a_r_r_a_y_._h_:_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r_:_:_A_r_r_a_y │ │ │ │ │ -DDeeffiinniittiioonn _a_r_r_a_y_._h_:_1_0_5 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _p_a_t_c_h_P_a_r_a_m_._h │ │ │ │ │ + * _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00755.html │ │ │ │ @@ -94,15 +94,15 @@ │ │ │ │
│ │ │ │ Namespaces
│ │ │ │
level.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../sdc/types.h"
│ │ │ │ -#include "../sdc/crease.h"
│ │ │ │ +#include "../sdc/crease.h"
│ │ │ │ #include "../sdc/options.h"
│ │ │ │ #include "../vtr/types.h"
│ │ │ │ #include <algorithm>
│ │ │ │ #include <vector>
│ │ │ │ #include <cassert>
│ │ │ │ #include <cstring>
│ │ │ │
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00755_source.html │ │ │ │ @@ -981,15 +981,15 @@ │ │ │ │ │ │ │ │
ConstArray< LocalIndex > ConstLocalIndexArray
Definition types.h:83
│ │ │ │
Array< LocalIndex > LocalIndexArray
Definition types.h:82
│ │ │ │ │ │ │ │
ConstArray< Index > ConstIndexArray
Definition types.h:80
│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../sdc/types.h"
│ │ │ │ -#include "../sdc/crease.h"
│ │ │ │ +#include "../sdc/crease.h"
│ │ │ │ #include "../vtr/types.h"
│ │ │ │ #include "../vtr/refinement.h"
│ │ │ │ #include "../vtr/fvarLevel.h"
│ │ │ │ #include <vector>
│ │ │ │ #include <cassert>
│ │ │ │ #include <cstring>
│ │ │ │
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00761.html │ │ │ │ @@ -94,15 +94,15 @@ │ │ │ │
│ │ │ │ Namespaces
│ │ │ │
fvarLevel.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../sdc/types.h"
│ │ │ │ -#include "../sdc/crease.h"
│ │ │ │ +#include "../sdc/crease.h"
│ │ │ │ #include "../sdc/options.h"
│ │ │ │ #include "../vtr/types.h"
│ │ │ │ #include "../vtr/level.h"
│ │ │ │ #include <vector>
│ │ │ │ #include <cassert>
│ │ │ │ #include <cstring>
│ │ │ │
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00761_source.html │ │ │ │ @@ -541,16 +541,16 @@ │ │ │ │ │ │ │ │
ConstArray< LocalIndex > ConstLocalIndexArray
Definition types.h:83
│ │ │ │
Array< LocalIndex > LocalIndexArray
Definition types.h:82
│ │ │ │ │ │ │ │
ConstArray< Index > ConstIndexArray
Definition types.h:80
│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../sdc/types.h"
│ │ │ │ -#include "../sdc/crease.h"
│ │ │ │ +#include "../sdc/crease.h"
│ │ │ │ #include "../vtr/types.h"
│ │ │ │ #include "../vtr/stackBuffer.h"
│ │ │ │ #include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00770.html │ │ │ │ @@ -96,15 +96,15 @@ │ │ │ │ Namespaces │ │ │ │
scheme.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../sdc/types.h"
│ │ │ │ #include "../sdc/options.h"
│ │ │ │ -#include "../sdc/crease.h"
│ │ │ │ +#include "../sdc/crease.h"
│ │ │ │ #include <cassert>
│ │ │ │ #include <cstdlib>
│ │ │ │ #include <vector>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00770_source.html │ │ │ │ @@ -7138,16 +7138,16 @@ │ │ │ │ 0001be10: 7465 6420 746f 2073 656d 692d 7368 6172 ted to semi-shar │ │ │ │ 0001be20: 7020 6372 6561 7369 6e67 20e2 8093 2077 p creasing ... w │ │ │ │ 0001be30: 686f 7365 2069 6d70 6c65 6d65 6e74 6174 hose implementat │ │ │ │ 0001be40: 696f 6e20 6973 2069 6e64 6570 656e 6465 ion is independe │ │ │ │ 0001be50: 6e74 206f 2e2e 2e3c 2f64 6976 3e3c 6469 nt o... │ │ │ │ 0001be70: 3c62 3e44 6566 696e 6974 696f 6e3c 2f62 Definition crease.h:6 │ │ │ │ 0001beb0: 323c 2f61 3e3c 2f64 6976 3e3c 2f64 6976 2.
Rule
< │ │ │ │ 0001bfc0: 623e 4465 6669 6e69 7469 6f6e 3c2f 623e b>Definition │ │ │ │ -0001bfd0: 203c 6120 6872 6566 3d22 6130 3037 3832 crease.h:82 │ │ │ │ 0001c000: 3c2f 613e 3c2f 6469 763e 3c2f 6469 763e
│ │ │ │ 0001c010: 0a3c 6469 7620 636c 6173 733d 2274 7463 .
@ RULE_D │ │ │ │ 0001c140: 4152 543c 2f64 6976 3e3c 6469 7620 636c ART
D │ │ │ │ 0001c160: 6566 696e 6974 696f 6e3c 2f62 3e20 3c61 efinition crease.h:85
.@ RULE_SM │ │ │ │ 0001c2e0: 4f4f 5448 3c2f 6469 763e 3c64 6976 2063 OOTH
│ │ │ │ 0001c300: 4465 6669 6e69 7469 6f6e 3c2f 623e 203c Definition < │ │ │ │ -0001c310: 6120 6872 6566 3d22 6130 3037 3832 5f73 a href="a00782_s │ │ │ │ +0001c310: 6120 6872 6566 3d22 6130 3037 3739 5f73 a href="a00779_s │ │ │ │ 0001c320: 6f75 7263 652e 6874 6d6c 236c 3030 3038 ource.html#l0008 │ │ │ │ 0001c330: 3422 3e63 7265 6173 652e 683a 3834 3c2f 4">crease.h:84
.< │ │ │ │ 0001c350: 6469 7620 636c 6173 733d 2274 7463 2220 div class="ttc" │ │ │ │ 0001c360: 6964 3d22 6161 3031 3333 335f 6874 6d6c id="aa01333_html │ │ │ │ 0001c370: 5f61 3131 6663 6435 3165 6638 3631 3138 _a11fcd51ef86118 │ │ │ │ 0001c380: 6636 3565 3630 3363 3134 3734 3337 3761 f65e603c1474377a │ │ │ │ @@ -7237,15 +7237,15 @@ │ │ │ │ 0001c440: 3a3a 5364 633a 3a43 7265 6173 653a 3a52 ::Sdc::Crease::R │ │ │ │ 0001c450: 554c 455f 4352 4541 5345 3c2f 613e 3c2f ULE_CREASE
@ RULE_C │ │ │ │ 0001c480: 5245 4153 453c 2f64 6976 3e3c 6469 7620 REASE
Definition │ │ │ │ -0001c4b0: 3c61 2068 7265 663d 2261 3030 3738 325f crease.h:86< │ │ │ │ 0001c4e0: 2f61 3e3c 2f64 6976 3e3c 2f64 6976 3e0a /a>
. │ │ │ │ 0001c4f0: 3c64 6976 2063 6c61 7373 3d22 7474 6322
@ RULE │ │ │ │ 0001c620: 5f55 4e4b 4e4f 574e 3c2f 6469 763e 3c64 _UNKNOWN
Definition
crease.h: │ │ │ │ 0001c680: 3833 3c2f 613e 3c2f 6469 763e 3c2f 6469 83
.
Definitio │ │ │ │ 0001c820: 6e3c 2f62 3e20 3c61 2068 7265 663d 2261 n crease │ │ │ │ 0001c850: 2e68 3a32 3238 3c2f 613e 3c2f 6469 763e .h:228
│ │ │ │ 0001c860: 3c2f 6469 763e 0a3c 6469 7620 636c 6173
.
│ │ │ │ 0001cab0: 3c64 6976 2063 6c61 7373 3d22 7474 6465
bool IsUnifo │ │ │ │ 0001cad0: 726d 2829 2063 6f6e 7374 3c2f 6469 763e rm() const
│ │ │ │ 0001cae0: 3c64 6976 2063 6c61 7373 3d22 7474 6465
Definition │ │ │ │ 0001cb00: 3c2f 623e 203c 6120 6872 6566 3d22 6130 crease. │ │ │ │ 0001cb30: 683a 3935 3c2f 613e 3c2f 6469 763e 3c2f h:95
.
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/sdc/catmarkScheme.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/sdc/crease.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -88,38 +88,43 @@ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ +Classes | │ │ │ │ Namespaces
│ │ │ │ -
catmarkScheme.h File Reference
│ │ │ │ +
crease.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../sdc/scheme.h"
│ │ │ │ -#include <cassert>
│ │ │ │ -#include <cmath>
│ │ │ │ +#include "../sdc/options.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +

│ │ │ │ +Classes

class  Crease
 Types, constants and utilities related to semi-sharp creasing – whose implementation is independent of the subdivision scheme. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Sdc
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,22 +1,25 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -_N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -catmarkScheme.h File Reference │ │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ +crease.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_s_d_c_/_s_c_h_e_m_e_._h" │ │ │ │ │ -#include │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ +CCllaasssseess │ │ │ │ │ +class   _C_r_e_a_s_e │ │ │ │ │ +  Types, constants and utilities related to semi-sharp creasing – whose │ │ │ │ │ + implementation is independent of the subdivision scheme. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _s_d_c │ │ │ │ │ - * _c_a_t_m_a_r_k_S_c_h_e_m_e_._h │ │ │ │ │ + * _c_r_e_a_s_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00779_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/sdc/catmarkScheme.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/sdc/crease.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
catmarkScheme.h
│ │ │ │ +
crease.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2014 DreamWorks Animation LLC.
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -118,566 +118,221 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_SDC_CATMARK_SCHEME_H
│ │ │ │ -
25#define OPENSUBDIV3_SDC_CATMARK_SCHEME_H
│ │ │ │ +
24#ifndef OPENSUBDIV3_SDC_CREASE_H
│ │ │ │ +
25#define OPENSUBDIV3_SDC_CREASE_H
│ │ │ │
26
│ │ │ │
27#include "../version.h"
│ │ │ │
28
│ │ │ │ -
29#include "../sdc/scheme.h"
│ │ │ │ +
29#include "../sdc/options.h"
│ │ │ │
30
│ │ │ │ -
31#include <cassert>
│ │ │ │ -
32#include <cmath>
│ │ │ │ +
31namespace OpenSubdiv {
│ │ │ │ +
32namespace OPENSUBDIV_VERSION {
│ │ │ │
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Sdc {
│ │ │ │ -
38
│ │ │ │ -
39//
│ │ │ │ -
40// Specializations for Scheme<SCHEME_CATMARK>:
│ │ │ │ -
41//
│ │ │ │ -
42
│ │ │ │ -
43//
│ │ │ │ -
44// Catmark traits:
│ │ │ │ -
45//
│ │ │ │ -
46template <>
│ │ │ │ - │ │ │ │ -
48
│ │ │ │ -
49template <>
│ │ │ │ - │ │ │ │ -
51
│ │ │ │ -
52template <>
│ │ │ │ - │ │ │ │ -
54
│ │ │ │ -
55template <>
│ │ │ │ - │ │ │ │ -
57
│ │ │ │ -
58
│ │ │ │ -
59//
│ │ │ │ -
60// Masks for edge-vertices: the hard Crease mask does not need to be specialized
│ │ │ │ -
61// (simply the midpoint), so all that is left is the Smooth case:
│ │ │ │ -
62//
│ │ │ │ -
63// The Smooth mask is complicated by the need to support the "triangle subdivision"
│ │ │ │ -
64// option, which applies different weighting in the presence of triangles. It is
│ │ │ │ -
65// up for debate as to whether this is useful or not -- we may be able to deprecate
│ │ │ │ -
66// this option.
│ │ │ │ -
67//
│ │ │ │ -
68template <>
│ │ │ │ -
69template <typename EDGE, typename MASK>
│ │ │ │ -
70inline void
│ │ │ │ -
│ │ │ │ -
71Scheme<SCHEME_CATMARK>::assignSmoothMaskForEdge(EDGE const& edge, MASK& mask) const {
│ │ │ │ -
72
│ │ │ │ -
73 typedef typename MASK::Weight Weight;
│ │ │ │ -
74
│ │ │ │ -
75 int faceCount = edge.GetNumFaces();
│ │ │ │ -
76
│ │ │ │ -
77 mask.SetNumVertexWeights(2);
│ │ │ │ -
78 mask.SetNumEdgeWeights(0);
│ │ │ │ -
79 mask.SetNumFaceWeights(faceCount);
│ │ │ │ -
80 mask.SetFaceWeightsForFaceCenters(true);
│ │ │ │ -
81
│ │ │ │ -
82 //
│ │ │ │ -
83 // Determine if we need to inspect incident faces and apply alternate weighting for
│ │ │ │ -
84 // triangles -- and if so, determine which of the two are triangles.
│ │ │ │ -
85 //
│ │ │ │ -
86 bool face0IsTri = false;
│ │ │ │ -
87 bool face1IsTri = false;
│ │ │ │ -
88 bool useTriangleOption = (_options.GetTriangleSubdivision() == Options::TRI_SUB_SMOOTH);
│ │ │ │ -
89 if (useTriangleOption) {
│ │ │ │ -
90 if (faceCount == 2) {
│ │ │ │ -
91 //
│ │ │ │ -
92 // Ideally we want to avoid this inspection when we have already subdivided at
│ │ │ │ -
93 // least once -- need something in the Edge interface to help avoid this, e.g.
│ │ │ │ -
94 // an IsRegular() query, the subdivision level...
│ │ │ │ -
95 //
│ │ │ │ -
96 int vertsPerFace[2];
│ │ │ │ -
97 edge.GetNumVerticesPerFace(vertsPerFace);
│ │ │ │ +
34namespace Sdc {
│ │ │ │ +
35
│ │ │ │ +
61
│ │ │ │ +
│ │ │ │ +
62class Crease {
│ │ │ │ +
63public:
│ │ │ │ +
65
│ │ │ │ +
67 static float const SHARPNESS_SMOOTH; // = 0.0f, do we really need this?
│ │ │ │ +
68 static float const SHARPNESS_INFINITE; // = 10.0f;
│ │ │ │ +
69
│ │ │ │ +
70 static bool IsSmooth(float sharpness) { return sharpness <= SHARPNESS_SMOOTH; }
│ │ │ │ +
71 static bool IsSharp(float sharpness) { return sharpness > SHARPNESS_SMOOTH; }
│ │ │ │ +
72 static bool IsInfinite(float sharpness) { return sharpness >= SHARPNESS_INFINITE; }
│ │ │ │ +
73 static bool IsSemiSharp(float sharpness) { return (SHARPNESS_SMOOTH < sharpness) && (sharpness < SHARPNESS_INFINITE); }
│ │ │ │ +
75
│ │ │ │ +
│ │ │ │ +
82 enum Rule {
│ │ │ │ + │ │ │ │ +
84 RULE_SMOOTH = (1 << 0),
│ │ │ │ +
85 RULE_DART = (1 << 1),
│ │ │ │ +
86 RULE_CREASE = (1 << 2),
│ │ │ │ +
87 RULE_CORNER = (1 << 3)
│ │ │ │ +
88 };
│ │ │ │ +
│ │ │ │ +
89
│ │ │ │ +
90public:
│ │ │ │ +
91 Crease() : _options() { }
│ │ │ │ +
92 Crease(Options const& options) : _options(options) { }
│ │ │ │ +
93 ~Crease() { }
│ │ │ │ +
94
│ │ │ │ +
95 bool IsUniform() const { return _options.GetCreasingMethod() == Options::CREASE_UNIFORM; }
│ │ │ │ +
96
│ │ │ │
98
│ │ │ │ -
99 face0IsTri = (vertsPerFace[0] == 3);
│ │ │ │ -
100 face1IsTri = (vertsPerFace[1] == 3);
│ │ │ │ -
101 useTriangleOption = face0IsTri || face1IsTri;
│ │ │ │ -
102 } else {
│ │ │ │ -
103 useTriangleOption = false;
│ │ │ │ -
104 }
│ │ │ │ -
105 }
│ │ │ │ +
104 float SharpenBoundaryEdge(float edgeSharpness) const;
│ │ │ │ +
105 float SharpenBoundaryVertex(float edgeSharpness) const;
│ │ │ │
106
│ │ │ │ -
107 if (! useTriangleOption) {
│ │ │ │ -
108 mask.VertexWeight(0) = 0.25f;
│ │ │ │ -
109 mask.VertexWeight(1) = 0.25f;
│ │ │ │ -
110
│ │ │ │ -
111 if (faceCount == 2) {
│ │ │ │ -
112 mask.FaceWeight(0) = 0.25f;
│ │ │ │ -
113 mask.FaceWeight(1) = 0.25f;
│ │ │ │ -
114 } else {
│ │ │ │ -
115 Weight fWeight = 0.5f / (Weight)faceCount;
│ │ │ │ -
116 for (int i = 0; i < faceCount; ++i) {
│ │ │ │ -
117 mask.FaceWeight(i) = fWeight;
│ │ │ │ -
118 }
│ │ │ │ -
119 }
│ │ │ │ -
120 } else {
│ │ │ │ -
121 //
│ │ │ │ -
122 // This mimics the implementation in Hbr in terms of order of operations.
│ │ │ │ -
123 //
│ │ │ │ -
124 const Weight CATMARK_SMOOTH_TRI_EDGE_WEIGHT = (Weight) 0.470;
│ │ │ │ +
107 // For future consideration
│ │ │ │ +
108 //float SharpenNonManifoldEdge(float edgeSharpness) const;
│ │ │ │ +
109 //float SharpenNonManifoldVertex(float edgeSharpness) const;
│ │ │ │ +
111
│ │ │ │ +
113
│ │ │ │ +
124 float SubdivideUniformSharpness(float vertexOrEdgeSharpness) const;
│ │ │ │
125
│ │ │ │ -
126 Weight f0Weight = face0IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f;
│ │ │ │ -
127 Weight f1Weight = face1IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f;
│ │ │ │ -
128
│ │ │ │ -
129 Weight fWeight = 0.5f * (f0Weight + f1Weight);
│ │ │ │ -
130 Weight vWeight = 0.5f * (1.0f - 2.0f * fWeight);
│ │ │ │ +
126 float SubdivideVertexSharpness(float vertexSharpness) const;
│ │ │ │ +
127
│ │ │ │ +
128 float SubdivideEdgeSharpnessAtVertex(float edgeSharpness,
│ │ │ │ +
129 int incidentEdgeCountAtEndVertex,
│ │ │ │ +
130 float const* edgeSharpnessAroundEndVertex) const;
│ │ │ │
131
│ │ │ │ -
132 mask.VertexWeight(0) = vWeight;
│ │ │ │ -
133 mask.VertexWeight(1) = vWeight;
│ │ │ │ -
134
│ │ │ │ -
135 mask.FaceWeight(0) = fWeight;
│ │ │ │ -
136 mask.FaceWeight(1) = fWeight;
│ │ │ │ -
137 }
│ │ │ │ -
138}
│ │ │ │ -
│ │ │ │ -
139
│ │ │ │ -
140
│ │ │ │ -
141//
│ │ │ │ -
142// Masks for vertex-vertices: the hard Corner mask does not need to be specialized
│ │ │ │ -
143// (simply the vertex itself), leaving the Crease and Smooth cases (Dart is smooth):
│ │ │ │ -
144//
│ │ │ │ -
145template <>
│ │ │ │ -
146template <typename VERTEX, typename MASK>
│ │ │ │ -
147inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
149 int const creaseEnds[2]) const {
│ │ │ │ -
150 typedef typename MASK::Weight Weight;
│ │ │ │ -
151
│ │ │ │ -
152 int valence = vertex.GetNumEdges();
│ │ │ │ -
153
│ │ │ │ -
154 mask.SetNumVertexWeights(1);
│ │ │ │ -
155 mask.SetNumEdgeWeights(valence);
│ │ │ │ -
156 mask.SetNumFaceWeights(0);
│ │ │ │ -
157 mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
158
│ │ │ │ -
159 Weight vWeight = 0.75f;
│ │ │ │ -
160 Weight eWeight = 0.125f;
│ │ │ │ -
161
│ │ │ │ -
162 mask.VertexWeight(0) = vWeight;
│ │ │ │ -
163 for (int i = 0; i < valence; ++i) {
│ │ │ │ -
164 mask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
165 }
│ │ │ │ -
166 mask.EdgeWeight(creaseEnds[0]) = eWeight;
│ │ │ │ -
167 mask.EdgeWeight(creaseEnds[1]) = eWeight;
│ │ │ │ -
168}
│ │ │ │ -
│ │ │ │ -
169
│ │ │ │ -
170template <>
│ │ │ │ -
171template <typename VERTEX, typename MASK>
│ │ │ │ -
172inline void
│ │ │ │ -
│ │ │ │ -
173Scheme<SCHEME_CATMARK>::assignSmoothMaskForVertex(VERTEX const& vertex, MASK& mask) const {
│ │ │ │ -
174
│ │ │ │ -
175 typedef typename MASK::Weight Weight;
│ │ │ │ +
132 void SubdivideEdgeSharpnessesAroundVertex(int incidentEdgeCountAtVertex,
│ │ │ │ +
133 float const* incidentEdgeSharpnessAroundVertex,
│ │ │ │ +
134 float* childEdgesSharpnessAroundVertex) const;
│ │ │ │ +
136
│ │ │ │ +
138
│ │ │ │ +
144 Rule DetermineVertexVertexRule(float vertexSharpness,
│ │ │ │ +
145 int incidentEdgeCount,
│ │ │ │ +
146 float const* incidentEdgeSharpness) const;
│ │ │ │ +
147 Rule DetermineVertexVertexRule(float vertexSharpness,
│ │ │ │ +
148 int sharpEdgeCount) const;
│ │ │ │ +
150
│ │ │ │ +
162 float ComputeFractionalWeightAtVertex(float vertexSharpness,
│ │ │ │ +
163 float childVertexSharpness,
│ │ │ │ +
164 int incidentEdgeCount,
│ │ │ │ +
165 float const* incidentEdgeSharpness,
│ │ │ │ +
166 float const* childEdgesSharpness) const;
│ │ │ │ +
167
│ │ │ │ +
168 void GetSharpEdgePairOfCrease(float const * incidentEdgeSharpness,
│ │ │ │ +
169 int incidentEdgeCount,
│ │ │ │ +
170 int sharpEdgePair[2]) const;
│ │ │ │ +
171
│ │ │ │ +
172 // Would these really help? Maybe only need Rules for the vertex-vertex case...
│ │ │ │ +
173 //
│ │ │ │ +
174 // Rule DetermineEdgeVertexRule(float parentEdgeSharpness) const;
│ │ │ │ +
175 // Rule DetermineEdgeVertexRule(float childEdge1Sharpness, float childEdge2Sharpness) const;
│ │ │ │
176
│ │ │ │ -
177 //
│ │ │ │ -
178 // A Smooth vertex must be manifold and interior -- manifold boundary vertices will be
│ │ │ │ -
179 // Creases and non-manifold vertices of any kind will be Corners or Creases. If smooth
│ │ │ │ -
180 // rules for non-manifold vertices are ever defined, this will need adjusting:
│ │ │ │ -
181 //
│ │ │ │ -
182 assert(vertex.GetNumFaces() == vertex.GetNumEdges());
│ │ │ │ +
177protected:
│ │ │ │ +
178 float decrementSharpness(float sharpness) const;
│ │ │ │ +
179
│ │ │ │ +
180private:
│ │ │ │ +
181 Options _options;
│ │ │ │ +
182};
│ │ │ │ +
│ │ │ │
183
│ │ │ │ -
184 int valence = vertex.GetNumFaces();
│ │ │ │ -
185
│ │ │ │ -
186 mask.SetNumVertexWeights(1);
│ │ │ │ -
187 mask.SetNumEdgeWeights(valence);
│ │ │ │ -
188 mask.SetNumFaceWeights(valence);
│ │ │ │ -
189 mask.SetFaceWeightsForFaceCenters(true);
│ │ │ │ +
184
│ │ │ │ +
185//
│ │ │ │ +
186// Inline declarations:
│ │ │ │ +
187//
│ │ │ │ +
188inline float
│ │ │ │ +
│ │ │ │ +
189Crease::SharpenBoundaryEdge(float /* edgeSharpness */) const {
│ │ │ │
190
│ │ │ │ -
191 Weight vWeight = (Weight)(valence - 2) / (Weight)valence;
│ │ │ │ -
192 Weight fWeight = 1.0f / (Weight)(valence * valence);
│ │ │ │ -
193 Weight eWeight = fWeight;
│ │ │ │ -
194
│ │ │ │ -
195 mask.VertexWeight(0) = vWeight;
│ │ │ │ -
196 for (int i = 0; i < valence; ++i) {
│ │ │ │ -
197 mask.EdgeWeight(i) = eWeight;
│ │ │ │ -
198 mask.FaceWeight(i) = fWeight;
│ │ │ │ -
199 }
│ │ │ │ -
200}
│ │ │ │ -
│ │ │ │ +
191 //
│ │ │ │ +
192 // Despite the presence of the BOUNDARY_NONE option, boundary edges are always sharpened.
│ │ │ │ +
193 // Much of the code relies on sharpness to indicate boundaries to avoid the more complex
│ │ │ │ +
194 // topological inspection
│ │ │ │ +
195 //
│ │ │ │ +
196 return SHARPNESS_INFINITE;
│ │ │ │ +
197}
│ │ │ │ +
│ │ │ │ +
198
│ │ │ │ +
199inline float
│ │ │ │ +
│ │ │ │ +
200Crease::SharpenBoundaryVertex(float vertexSharpness) const {
│ │ │ │
201
│ │ │ │ -
202//
│ │ │ │ -
203// Limit masks for position:
│ │ │ │ -
204//
│ │ │ │ -
205template <>
│ │ │ │ -
206template <typename VERTEX, typename MASK>
│ │ │ │ -
207inline void
│ │ │ │ -
│ │ │ │ -
208Scheme<SCHEME_CATMARK>::assignCornerLimitMask(VERTEX const& /* vertex */, MASK& posMask) const {
│ │ │ │ -
209
│ │ │ │ -
210 posMask.SetNumVertexWeights(1);
│ │ │ │ -
211 posMask.SetNumEdgeWeights(0);
│ │ │ │ -
212 posMask.SetNumFaceWeights(0);
│ │ │ │ -
213 posMask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
214
│ │ │ │ -
215 posMask.VertexWeight(0) = 1.0f;
│ │ │ │ -
216}
│ │ │ │ + │ │ │ │ +
203 SHARPNESS_INFINITE : vertexSharpness;
│ │ │ │ +
204}
│ │ │ │ +
│ │ │ │ +
205
│ │ │ │ +
206inline float
│ │ │ │ +
│ │ │ │ +
207Crease::decrementSharpness(float sharpness) const {
│ │ │ │ +
208
│ │ │ │ +
209 if (IsSmooth(sharpness)) return Crease::SHARPNESS_SMOOTH; // redundant but most common
│ │ │ │ +
210 if (IsInfinite(sharpness)) return Crease::SHARPNESS_INFINITE;
│ │ │ │ +
211 if (sharpness > 1.0f) return (sharpness - 1.0f);
│ │ │ │ + │ │ │ │ +
213}
│ │ │ │
│ │ │ │ +
214
│ │ │ │ +
215inline float
│ │ │ │ +
│ │ │ │ +
216Crease::SubdivideUniformSharpness(float vertexOrEdgeSharpness) const {
│ │ │ │
217
│ │ │ │ -
218template <>
│ │ │ │ -
219template <typename VERTEX, typename MASK>
│ │ │ │ -
220inline void
│ │ │ │ -
│ │ │ │ -
221Scheme<SCHEME_CATMARK>::assignCreaseLimitMask(VERTEX const& vertex, MASK& posMask,
│ │ │ │ -
222 int const creaseEnds[2]) const {
│ │ │ │ +
218 return decrementSharpness(vertexOrEdgeSharpness);
│ │ │ │ +
219}
│ │ │ │ +
│ │ │ │ +
220
│ │ │ │ +
221inline float
│ │ │ │ +
│ │ │ │ +
222Crease::SubdivideVertexSharpness(float vertexSharpness) const {
│ │ │ │
223
│ │ │ │ -
224 typedef typename MASK::Weight Weight;
│ │ │ │ -
225
│ │ │ │ -
226 int valence = vertex.GetNumEdges();
│ │ │ │ -
227
│ │ │ │ -
228 posMask.SetNumVertexWeights(1);
│ │ │ │ -
229 posMask.SetNumEdgeWeights(valence);
│ │ │ │ -
230 posMask.SetNumFaceWeights(0);
│ │ │ │ -
231 posMask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
232
│ │ │ │ -
233 Weight vWeight = (Weight)(2.0 / 3.0);
│ │ │ │ -
234 Weight eWeight = (Weight)(1.0 / 6.0);
│ │ │ │ -
235
│ │ │ │ -
236 posMask.VertexWeight(0) = vWeight;
│ │ │ │ -
237 for (int i = 0; i < valence; ++i) {
│ │ │ │ -
238 posMask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
239 }
│ │ │ │ -
240 posMask.EdgeWeight(creaseEnds[0]) = eWeight;
│ │ │ │ -
241 posMask.EdgeWeight(creaseEnds[1]) = eWeight;
│ │ │ │ -
242}
│ │ │ │ -
│ │ │ │ -
243
│ │ │ │ -
244template <>
│ │ │ │ -
245template <typename VERTEX, typename MASK>
│ │ │ │ -
246inline void
│ │ │ │ -
│ │ │ │ -
247Scheme<SCHEME_CATMARK>::assignSmoothLimitMask(VERTEX const& vertex, MASK& posMask) const {
│ │ │ │ -
248
│ │ │ │ -
249 typedef typename MASK::Weight Weight;
│ │ │ │ -
250
│ │ │ │ -
251 int valence = vertex.GetNumFaces();
│ │ │ │ -
252 if (valence == 2) {
│ │ │ │ -
253 assignCornerLimitMask(vertex, posMask);
│ │ │ │ -
254 return;
│ │ │ │ -
255 }
│ │ │ │ -
256
│ │ │ │ -
257 posMask.SetNumVertexWeights(1);
│ │ │ │ -
258 posMask.SetNumEdgeWeights(valence);
│ │ │ │ -
259 posMask.SetNumFaceWeights(valence);
│ │ │ │ -
260 posMask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
261
│ │ │ │ -
262 // Specialize for the regular case:
│ │ │ │ -
263 if (valence == 4) {
│ │ │ │ -
264 Weight fWeight = (Weight)(1.0 / 36.0);
│ │ │ │ -
265 Weight eWeight = (Weight)(1.0 / 9.0);
│ │ │ │ -
266 Weight vWeight = (Weight)(4.0 / 9.0);
│ │ │ │ -
267
│ │ │ │ -
268 posMask.VertexWeight(0) = vWeight;
│ │ │ │ -
269
│ │ │ │ -
270 posMask.EdgeWeight(0) = eWeight;
│ │ │ │ -
271 posMask.EdgeWeight(1) = eWeight;
│ │ │ │ -
272 posMask.EdgeWeight(2) = eWeight;
│ │ │ │ -
273 posMask.EdgeWeight(3) = eWeight;
│ │ │ │ -
274
│ │ │ │ -
275 posMask.FaceWeight(0) = fWeight;
│ │ │ │ -
276 posMask.FaceWeight(1) = fWeight;
│ │ │ │ -
277 posMask.FaceWeight(2) = fWeight;
│ │ │ │ -
278 posMask.FaceWeight(3) = fWeight;
│ │ │ │ -
279 } else {
│ │ │ │ -
280 Weight Valence = (Weight) valence;
│ │ │ │ -
281
│ │ │ │ -
282 Weight fWeight = 1.0f / (Valence * (Valence + 5.0f));
│ │ │ │ -
283 Weight eWeight = 4.0f * fWeight;
│ │ │ │ -
284 Weight vWeight = 1.0f - Valence * (eWeight + fWeight);
│ │ │ │ -
285
│ │ │ │ -
286 posMask.VertexWeight(0) = vWeight;
│ │ │ │ -
287 for (int i = 0; i < valence; ++i) {
│ │ │ │ -
288 posMask.EdgeWeight(i) = eWeight;
│ │ │ │ -
289 posMask.FaceWeight(i) = fWeight;
│ │ │ │ -
290 }
│ │ │ │ -
291 }
│ │ │ │ -
292}
│ │ │ │ -
│ │ │ │ -
293
│ │ │ │ -
294//
│ │ │ │ -
295// Limit masks for tangents -- these are stubs for now, or have a temporary
│ │ │ │ -
296// implementation
│ │ │ │ -
297//
│ │ │ │ -
298template <>
│ │ │ │ -
299template <typename VERTEX, typename MASK>
│ │ │ │ -
300inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
302 MASK& tan1Mask, MASK& tan2Mask) const {
│ │ │ │ -
303
│ │ │ │ -
304 int valence = vertex.GetNumEdges();
│ │ │ │ -
305
│ │ │ │ -
306 tan1Mask.SetNumVertexWeights(1);
│ │ │ │ -
307 tan1Mask.SetNumEdgeWeights(valence);
│ │ │ │ -
308 tan1Mask.SetNumFaceWeights(0);
│ │ │ │ -
309 tan1Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
310
│ │ │ │ -
311 tan2Mask.SetNumVertexWeights(1);
│ │ │ │ -
312 tan2Mask.SetNumEdgeWeights(valence);
│ │ │ │ -
313 tan2Mask.SetNumFaceWeights(0);
│ │ │ │ -
314 tan2Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
315
│ │ │ │ -
316 // Should be at least 2 edges -- be sure to clear weights for any more:
│ │ │ │ -
317 tan1Mask.VertexWeight(0) = -1.0f;
│ │ │ │ -
318 tan1Mask.EdgeWeight(0) = 1.0f;
│ │ │ │ -
319 tan1Mask.EdgeWeight(1) = 0.0f;
│ │ │ │ -
320
│ │ │ │ -
321 tan2Mask.VertexWeight(0) = -1.0f;
│ │ │ │ -
322 tan2Mask.EdgeWeight(0) = 0.0f;
│ │ │ │ -
323 tan2Mask.EdgeWeight(1) = 1.0f;
│ │ │ │ -
324
│ │ │ │ -
325 for (int i = 2; i < valence; ++i) {
│ │ │ │ -
326 tan1Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
327 tan2Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
328 }
│ │ │ │ -
329}
│ │ │ │ -
│ │ │ │ -
330
│ │ │ │ -
331template <>
│ │ │ │ -
332template <typename VERTEX, typename MASK>
│ │ │ │ -
333inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
335 MASK& tan1Mask, MASK& tan2Mask, int const creaseEnds[2]) const {
│ │ │ │ -
336
│ │ │ │ -
337 typedef typename MASK::Weight Weight;
│ │ │ │ -
338
│ │ │ │ -
339 //
│ │ │ │ -
340 // First, the tangent along the crease:
│ │ │ │ -
341 // The first crease edge is considered the "leading" edge of the span
│ │ │ │ -
342 // of surface for which we are evaluating tangents and the second edge the
│ │ │ │ -
343 // "trailing edge". By convention, the tangent along the crease is oriented
│ │ │ │ -
344 // in the direction of the leading edge.
│ │ │ │ -
345 //
│ │ │ │ -
346 int numEdges = vertex.GetNumEdges();
│ │ │ │ -
347 int numFaces = vertex.GetNumFaces();
│ │ │ │ -
348
│ │ │ │ -
349 tan1Mask.SetNumVertexWeights(1);
│ │ │ │ -
350 tan1Mask.SetNumEdgeWeights(numEdges);
│ │ │ │ -
351 tan1Mask.SetNumFaceWeights(numFaces);
│ │ │ │ -
352 tan1Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
353
│ │ │ │ -
354 tan1Mask.VertexWeight(0) = 0.0f;
│ │ │ │ -
355 for (int i = 0; i < numEdges; ++i) {
│ │ │ │ -
356 tan1Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
357 }
│ │ │ │ -
358 for (int i = 0; i < numFaces; ++i) {
│ │ │ │ -
359 tan1Mask.FaceWeight(i) = 0.0f;
│ │ │ │ -
360 }
│ │ │ │ -
361
│ │ │ │ -
362 tan1Mask.EdgeWeight(creaseEnds[0]) = 0.5f;
│ │ │ │ -
363 tan1Mask.EdgeWeight(creaseEnds[1]) = -0.5f;
│ │ │ │ -
364
│ │ │ │ -
365 //
│ │ │ │ -
366 // Second, the tangent across the interior faces:
│ │ │ │ -
367 // Note this is ambiguous for an interior vertex. We currently return
│ │ │ │ -
368 // the tangent for the surface in the counter-clockwise span between the
│ │ │ │ -
369 // leading and trailing edges that form the crease. Given the expected
│ │ │ │ -
370 // computation of a surface normal as Tan1 X Tan2, this tangent should be
│ │ │ │ -
371 // oriented "inward" from the crease/boundary -- across the surface rather
│ │ │ │ -
372 // than outward and away from it.
│ │ │ │ -
373 //
│ │ │ │ -
374 tan2Mask.SetNumVertexWeights(1);
│ │ │ │ -
375 tan2Mask.SetNumEdgeWeights(numEdges);
│ │ │ │ -
376 tan2Mask.SetNumFaceWeights(numFaces);
│ │ │ │ -
377 tan2Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
378
│ │ │ │ -
379 // Prepend weights of 0 preceding the crease:
│ │ │ │ -
380 for (int i = 0; i < creaseEnds[0]; ++i) {
│ │ │ │ -
381 tan2Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
382 tan2Mask.FaceWeight(i) = 0.0f;
│ │ │ │ -
383 }
│ │ │ │ -
384
│ │ │ │ -
385 // Assign weights to crease edge and interior points:
│ │ │ │ -
386 int interiorEdgeCount = creaseEnds[1] - creaseEnds[0] - 1;
│ │ │ │ -
387 if (interiorEdgeCount == 1) {
│ │ │ │ -
388 // The regular case -- uniform B-spline cross-tangent:
│ │ │ │ -
389
│ │ │ │ -
390 tan2Mask.VertexWeight(0) = (Weight)(-4.0 / 6.0);
│ │ │ │ -
391
│ │ │ │ -
392 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight)(-1.0 / 6.0);
│ │ │ │ -
393 tan2Mask.EdgeWeight(creaseEnds[0] + 1) = (Weight)( 4.0 / 6.0);
│ │ │ │ -
394 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight)(-1.0 / 6.0);
│ │ │ │ -
395
│ │ │ │ -
396 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight)(1.0 / 6.0);
│ │ │ │ -
397 tan2Mask.FaceWeight(creaseEnds[0] + 1) = (Weight)(1.0 / 6.0);
│ │ │ │ -
398 } else if (interiorEdgeCount > 1) {
│ │ │ │ -
399 // The irregular case -- formulae from Biermann et al:
│ │ │ │ -
400
│ │ │ │ -
401 double k = (double) (interiorEdgeCount + 1);
│ │ │ │ -
402 double theta = M_PI / k;
│ │ │ │ -
403
│ │ │ │ -
404 double cosTheta = std::cos(theta);
│ │ │ │ -
405 double sinTheta = std::sin(theta);
│ │ │ │ -
406
│ │ │ │ -
407 // Loop/Schaefer use a different divisor here (3*k + cos(theta)):
│ │ │ │ -
408 double commonDenom = 1.0f / (k * (3.0f + cosTheta));
│ │ │ │ -
409 double R = (cosTheta + 1.0f) / sinTheta;
│ │ │ │ -
410
│ │ │ │ -
411 double vertexWeight = 4.0f * R * (cosTheta - 1.0f);
│ │ │ │ -
412 double creaseWeight = -R * (1.0f + 2.0f * cosTheta);
│ │ │ │ -
413
│ │ │ │ -
414 tan2Mask.VertexWeight(0) = (Weight) (vertexWeight * commonDenom);
│ │ │ │ -
415
│ │ │ │ -
416 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight) (creaseWeight * commonDenom);
│ │ │ │ -
417 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight) (creaseWeight * commonDenom);
│ │ │ │ -
418
│ │ │ │ -
419 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight) (sinTheta * commonDenom);
│ │ │ │ -
420
│ │ │ │ -
421 double sinThetaI = 0.0f;
│ │ │ │ -
422 double sinThetaIplus1 = sinTheta;
│ │ │ │ -
423 for (int i = 1; i < k; ++i) {
│ │ │ │ -
424 sinThetaI = sinThetaIplus1;
│ │ │ │ -
425 sinThetaIplus1 = std::sin((i+1)*theta);
│ │ │ │ -
426
│ │ │ │ -
427 tan2Mask.EdgeWeight(creaseEnds[0] + i) = (Weight) ((4.0f * sinThetaI) * commonDenom);
│ │ │ │ -
428 tan2Mask.FaceWeight(creaseEnds[0] + i) = (Weight) ((sinThetaI + sinThetaIplus1) * commonDenom);
│ │ │ │ -
429 }
│ │ │ │ -
430 } else {
│ │ │ │ -
431 // Special case for a single face -- simple average of boundary edges:
│ │ │ │ -
432
│ │ │ │ -
433 tan2Mask.VertexWeight(0) = -6.0f;
│ │ │ │ -
434
│ │ │ │ -
435 tan2Mask.EdgeWeight(creaseEnds[0]) = 3.0f;
│ │ │ │ -
436 tan2Mask.EdgeWeight(creaseEnds[1]) = 3.0f;
│ │ │ │ -
437
│ │ │ │ -
438 tan2Mask.FaceWeight(creaseEnds[0]) = 0.0f;
│ │ │ │ -
439 }
│ │ │ │ -
440
│ │ │ │ -
441 // Append weights of 0 following the crease:
│ │ │ │ -
442 for (int i = creaseEnds[1]; i < numFaces; ++i) {
│ │ │ │ -
443 tan2Mask.FaceWeight(i) = 0.0f;
│ │ │ │ -
444 }
│ │ │ │ -
445 for (int i = creaseEnds[1] + 1; i < numEdges; ++i) {
│ │ │ │ -
446 tan2Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ -
447 }
│ │ │ │ -
448}
│ │ │ │ -
│ │ │ │ -
449
│ │ │ │ -
450template <>
│ │ │ │ -
451template <typename VERTEX, typename MASK>
│ │ │ │ -
452inline void
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
454 MASK& tan1Mask, MASK& tan2Mask) const {
│ │ │ │ -
455
│ │ │ │ -
456 typedef typename MASK::Weight Weight;
│ │ │ │ -
457
│ │ │ │ -
458 int valence = vertex.GetNumFaces();
│ │ │ │ -
459 if (valence == 2) {
│ │ │ │ -
460 assignCornerLimitTangentMasks(vertex, tan1Mask, tan2Mask);
│ │ │ │ -
461 return;
│ │ │ │ -
462 }
│ │ │ │ -
463
│ │ │ │ -
464 // Compute tan1 initially -- tan2 is simply a rotation:
│ │ │ │ -
465 tan1Mask.SetNumVertexWeights(1);
│ │ │ │ -
466 tan1Mask.SetNumEdgeWeights(valence);
│ │ │ │ -
467 tan1Mask.SetNumFaceWeights(valence);
│ │ │ │ -
468 tan1Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
469
│ │ │ │ -
470 tan1Mask.VertexWeight(0) = 0.0f;
│ │ │ │ -
471
│ │ │ │ -
472 if (valence == 4) {
│ │ │ │ -
473 tan1Mask.EdgeWeight(0) = 4.0f;
│ │ │ │ -
474 tan1Mask.EdgeWeight(1) = 0.0f;
│ │ │ │ -
475 tan1Mask.EdgeWeight(2) = -4.0f;
│ │ │ │ -
476 tan1Mask.EdgeWeight(3) = 0.0f;
│ │ │ │ -
477
│ │ │ │ -
478 tan1Mask.FaceWeight(0) = 1.0f;
│ │ │ │ -
479 tan1Mask.FaceWeight(1) = -1.0f;
│ │ │ │ -
480 tan1Mask.FaceWeight(2) = -1.0f;
│ │ │ │ -
481 tan1Mask.FaceWeight(3) = 1.0f;
│ │ │ │ -
482 } else {
│ │ │ │ -
483 double theta = 2.0f * M_PI / (double)valence;
│ │ │ │ -
484
│ │ │ │ -
485 double cosTheta = std::cos(theta);
│ │ │ │ -
486 double cosHalfTheta = std::cos(theta * 0.5f);
│ │ │ │ -
487
│ │ │ │ -
488 double lambda = (5.0 / 16.0) + (1.0 / 16.0) *
│ │ │ │ -
489 (cosTheta + cosHalfTheta * std::sqrt(2.0f * (9.0f + cosTheta)));
│ │ │ │ -
490
│ │ │ │ -
491 double edgeWeightScale = 4.0f;
│ │ │ │ -
492 double faceWeightScale = 1.0f / (4.0f * lambda - 1.0f);
│ │ │ │ -
493
│ │ │ │ -
494 for (int i = 0; i < valence; ++i) {
│ │ │ │ -
495 double cosThetaI = std::cos( i * theta);
│ │ │ │ -
496 double cosThetaIplus1 = std::cos((i+1)* theta);
│ │ │ │ -
497
│ │ │ │ -
498 tan1Mask.EdgeWeight(i) = (Weight) (edgeWeightScale * cosThetaI);
│ │ │ │ -
499 tan1Mask.FaceWeight(i) = (Weight) (faceWeightScale * (cosThetaI + cosThetaIplus1));
│ │ │ │ -
500 }
│ │ │ │ -
501 }
│ │ │ │ -
502
│ │ │ │ -
503 // Now rotate/copy tan1 weights to tan2:
│ │ │ │ -
504 tan2Mask.SetNumVertexWeights(1);
│ │ │ │ -
505 tan2Mask.SetNumEdgeWeights(valence);
│ │ │ │ -
506 tan2Mask.SetNumFaceWeights(valence);
│ │ │ │ -
507 tan2Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ -
508
│ │ │ │ -
509 tan2Mask.VertexWeight(0) = 0.0f;
│ │ │ │ -
510 if (valence == 4) {
│ │ │ │ -
511 tan2Mask.EdgeWeight(0) = 0.0f;
│ │ │ │ -
512 tan2Mask.EdgeWeight(1) = 4.0f;
│ │ │ │ -
513 tan2Mask.EdgeWeight(2) = 0.0f;
│ │ │ │ -
514 tan2Mask.EdgeWeight(3) = -4.0f;
│ │ │ │ -
515
│ │ │ │ -
516 tan2Mask.FaceWeight(0) = 1.0f;
│ │ │ │ -
517 tan2Mask.FaceWeight(1) = 1.0f;
│ │ │ │ -
518 tan2Mask.FaceWeight(2) = -1.0f;
│ │ │ │ -
519 tan2Mask.FaceWeight(3) = -1.0f;
│ │ │ │ -
520 } else {
│ │ │ │ -
521 tan2Mask.EdgeWeight(0) = tan1Mask.EdgeWeight(valence-1);
│ │ │ │ -
522 tan2Mask.FaceWeight(0) = tan1Mask.FaceWeight(valence-1);
│ │ │ │ -
523 for (int i = 1; i < valence; ++i) {
│ │ │ │ -
524 tan2Mask.EdgeWeight(i) = tan1Mask.EdgeWeight(i-1);
│ │ │ │ -
525 tan2Mask.FaceWeight(i) = tan1Mask.FaceWeight(i-1);
│ │ │ │ -
526 }
│ │ │ │ -
527 }
│ │ │ │ -
528}
│ │ │ │ -
│ │ │ │ -
529
│ │ │ │ -
530} // end namespace sdc
│ │ │ │ -
531
│ │ │ │ -
532} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
533using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
534} // end namespace OpenSubdiv
│ │ │ │ -
535
│ │ │ │ -
536#endif /* OPENSUBDIV3_SDC_CATMARK_SCHEME_H */
│ │ │ │ +
224 return decrementSharpness(vertexSharpness);
│ │ │ │ +
225}
│ │ │ │ +
│ │ │ │ +
226
│ │ │ │ +
227inline void
│ │ │ │ +
│ │ │ │ +
228Crease::GetSharpEdgePairOfCrease(float const * incidentEdgeSharpness, int incidentEdgeCount,
│ │ │ │ +
229 int sharpEdgePair[2]) const {
│ │ │ │ +
230
│ │ │ │ +
231 // Only to be called when a crease is present at a vertex -- exactly two sharp
│ │ │ │ +
232 // edges are expected here:
│ │ │ │ +
233 //
│ │ │ │ +
234 sharpEdgePair[0] = 0;
│ │ │ │ +
235 while (IsSmooth(incidentEdgeSharpness[sharpEdgePair[0]])) ++ sharpEdgePair[0];
│ │ │ │ +
236
│ │ │ │ +
237 sharpEdgePair[1] = incidentEdgeCount - 1;
│ │ │ │ +
238 while (IsSmooth(incidentEdgeSharpness[sharpEdgePair[1]])) -- sharpEdgePair[1];
│ │ │ │ +
239}
│ │ │ │ +
│ │ │ │ +
240
│ │ │ │ +
241} // end namespace sdc
│ │ │ │ +
242
│ │ │ │ +
243} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
244using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
245} // end namespace OpenSubdiv
│ │ │ │ +
246
│ │ │ │ +
247#endif /* OPENSUBDIV3_SDC_CREASE_H */
│ │ │ │ │ │ │ │ -
Split
Enumerated type for all face splitting schemes.
Definition types.h:47
│ │ │ │ -
@ SPLIT_TO_QUADS
Used by Catmark and Bilinear.
Definition types.h:48
│ │ │ │ -
@ TRI_SUB_SMOOTH
"smooth triangle" weights (Catmark scheme only)
Definition options.h:74
│ │ │ │ -
void assignSmoothMaskForEdge(EDGE const &edge, MASK &mask) const
│ │ │ │ - │ │ │ │ -
void assignCreaseMaskForVertex(VERTEX const &edge, MASK &mask, int const creaseEnds[2]) const
│ │ │ │ -
void assignCreaseLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2, int const creaseEnds[2]) const
│ │ │ │ - │ │ │ │ -
void assignSmoothLimitMask(VERTEX const &vertex, MASK &pos) const
│ │ │ │ - │ │ │ │ -
void assignCreaseLimitMask(VERTEX const &vertex, MASK &pos, int const creaseEnds[2]) const
│ │ │ │ -
void assignSmoothMaskForVertex(VERTEX const &edge, MASK &mask) const
│ │ │ │ - │ │ │ │ -
void assignSmoothLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2) const
│ │ │ │ -
void assignCornerLimitMask(VERTEX const &vertex, MASK &pos) const
│ │ │ │ -
void assignCornerLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2) const
│ │ │ │ +
Types, constants and utilities related to semi-sharp creasing – whose implementation is independent o...
Definition crease.h:62
│ │ │ │ +
float SubdivideVertexSharpness(float vertexSharpness) const
Definition crease.h:222
│ │ │ │ +
static bool IsInfinite(float sharpness)
Definition crease.h:72
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
float SharpenBoundaryVertex(float edgeSharpness) const
Definition crease.h:200
│ │ │ │ + │ │ │ │ +
void GetSharpEdgePairOfCrease(float const *incidentEdgeSharpness, int incidentEdgeCount, int sharpEdgePair[2]) const
Definition crease.h:228
│ │ │ │ + │ │ │ │ +
Rule DetermineVertexVertexRule(float vertexSharpness, int incidentEdgeCount, float const *incidentEdgeSharpness) const
│ │ │ │ +
float decrementSharpness(float sharpness) const
Definition crease.h:207
│ │ │ │ +
static bool IsSmooth(float sharpness)
Definition crease.h:70
│ │ │ │ +
Rule DetermineVertexVertexRule(float vertexSharpness, int sharpEdgeCount) const
│ │ │ │ + │ │ │ │ +
static bool IsSemiSharp(float sharpness)
Definition crease.h:73
│ │ │ │ + │ │ │ │ +
void SubdivideEdgeSharpnessesAroundVertex(int incidentEdgeCountAtVertex, float const *incidentEdgeSharpnessAroundVertex, float *childEdgesSharpnessAroundVertex) const
│ │ │ │ +
float SubdivideUniformSharpness(float vertexOrEdgeSharpness) const
Definition crease.h:216
│ │ │ │ + │ │ │ │ +
float SharpenBoundaryEdge(float edgeSharpness) const
Definition crease.h:189
│ │ │ │ +
float ComputeFractionalWeightAtVertex(float vertexSharpness, float childVertexSharpness, int incidentEdgeCount, float const *incidentEdgeSharpness, float const *childEdgesSharpness) const
Transitional weighting: When the rules applicable to a parent vertex and its child differ,...
│ │ │ │ +
float SubdivideEdgeSharpnessAtVertex(float edgeSharpness, int incidentEdgeCountAtEndVertex, float const *edgeSharpnessAroundEndVertex) const
│ │ │ │ +
static bool IsSharp(float sharpness)
Definition crease.h:71
│ │ │ │ + │ │ │ │ +
All supported options applying to subdivision scheme.
Definition options.h:51
│ │ │ │ + │ │ │ │ +
CreasingMethod GetCreasingMethod() const
Get edge crease rule.
Definition options.h:101
│ │ │ │ +
VtxBoundaryInterpolation GetVtxBoundaryInterpolation() const
Get vertex boundary interpolation rule.
Definition options.h:89
│ │ │ │ + │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── encoding │ │ │ │ │ @@ -1 +1 @@ │ │ │ │ │ -us-ascii │ │ │ │ │ +utf-8 │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -catmarkScheme.h │ │ │ │ │ +crease.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2014 DreamWorks Animation LLC. │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -23,592 +23,289 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_SDC_CATMARK_SCHEME_H │ │ │ │ │ -25#define OPENSUBDIV3_SDC_CATMARK_SCHEME_H │ │ │ │ │ +24#ifndef OPENSUBDIV3_SDC_CREASE_H │ │ │ │ │ +25#define OPENSUBDIV3_SDC_CREASE_H │ │ │ │ │ 26 │ │ │ │ │ 27#include "../version.h" │ │ │ │ │ 28 │ │ │ │ │ -29#include "../sdc/scheme.h" │ │ │ │ │ +29#include "../sdc/options.h" │ │ │ │ │ 30 │ │ │ │ │ -31#include │ │ │ │ │ -32#include │ │ │ │ │ +31namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +32namespace OPENSUBDIV_VERSION { │ │ │ │ │ 33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Sdc { │ │ │ │ │ -38 │ │ │ │ │ -39// │ │ │ │ │ -40// Specializations for Scheme: │ │ │ │ │ -41// │ │ │ │ │ -42 │ │ │ │ │ -43// │ │ │ │ │ -44// Catmark traits: │ │ │ │ │ -45// │ │ │ │ │ -46template <> │ │ │ │ │ -_4_7inline _S_p_l_i_t _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_T_o_p_o_l_o_g_i_c_a_l_S_p_l_i_t_T_y_p_e() { return │ │ │ │ │ -_S_P_L_I_T___T_O___Q_U_A_D_S; } │ │ │ │ │ -48 │ │ │ │ │ -49template <> │ │ │ │ │ -_5_0inline int _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_R_e_g_u_l_a_r_F_a_c_e_S_i_z_e() { return 4; } │ │ │ │ │ -51 │ │ │ │ │ -52template <> │ │ │ │ │ -_5_3inline int _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_R_e_g_u_l_a_r_V_e_r_t_e_x_V_a_l_e_n_c_e() { return 4; } │ │ │ │ │ -54 │ │ │ │ │ -55template <> │ │ │ │ │ -_5_6inline int _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_L_o_c_a_l_N_e_i_g_h_b_o_r_h_o_o_d_S_i_z_e() { return 1; } │ │ │ │ │ -57 │ │ │ │ │ -58 │ │ │ │ │ -59// │ │ │ │ │ -60// Masks for edge-vertices: the hard Crease mask does not need to be │ │ │ │ │ -specialized │ │ │ │ │ -61// (simply the midpoint), so all that is left is the Smooth case: │ │ │ │ │ -62// │ │ │ │ │ -63// The Smooth mask is complicated by the need to support the "triangle │ │ │ │ │ -subdivision" │ │ │ │ │ -64// option, which applies different weighting in the presence of triangles. It │ │ │ │ │ -is │ │ │ │ │ -65// up for debate as to whether this is useful or not -- we may be able to │ │ │ │ │ -deprecate │ │ │ │ │ -66// this option. │ │ │ │ │ -67// │ │ │ │ │ -68template <> │ │ │ │ │ -69template │ │ │ │ │ -70inline void │ │ │ │ │ -_7_1_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_E_d_g_e(EDGE const& edge, MASK& mask) │ │ │ │ │ -const { │ │ │ │ │ -72 │ │ │ │ │ -73 typedef typename MASK::Weight Weight; │ │ │ │ │ -74 │ │ │ │ │ -75 int faceCount = edge.GetNumFaces(); │ │ │ │ │ -76 │ │ │ │ │ -77 mask.SetNumVertexWeights(2); │ │ │ │ │ -78 mask.SetNumEdgeWeights(0); │ │ │ │ │ -79 mask.SetNumFaceWeights(faceCount); │ │ │ │ │ -80 mask.SetFaceWeightsForFaceCenters(true); │ │ │ │ │ -81 │ │ │ │ │ -82 // │ │ │ │ │ -83 // Determine if we need to inspect incident faces and apply alternate │ │ │ │ │ -weighting for │ │ │ │ │ -84 // triangles -- and if so, determine which of the two are triangles. │ │ │ │ │ -85 // │ │ │ │ │ -86 bool face0IsTri = false; │ │ │ │ │ -87 bool face1IsTri = false; │ │ │ │ │ -88 bool useTriangleOption = (_options.GetTriangleSubdivision() == _O_p_t_i_o_n_s_:_: │ │ │ │ │ -_T_R_I___S_U_B___S_M_O_O_T_H); │ │ │ │ │ -89 if (useTriangleOption) { │ │ │ │ │ -90 if (faceCount == 2) { │ │ │ │ │ -91 // │ │ │ │ │ -92 // Ideally we want to avoid this inspection when we have already subdivided │ │ │ │ │ -at │ │ │ │ │ -93 // least once -- need something in the Edge interface to help avoid this, │ │ │ │ │ -e.g. │ │ │ │ │ -94 // an IsRegular() query, the subdivision level... │ │ │ │ │ -95 // │ │ │ │ │ -96 int vertsPerFace[2]; │ │ │ │ │ -97 edge.GetNumVerticesPerFace(vertsPerFace); │ │ │ │ │ +34namespace Sdc { │ │ │ │ │ +35 │ │ │ │ │ +61 │ │ │ │ │ +_6_2class _C_r_e_a_s_e { │ │ │ │ │ +63public: │ │ │ │ │ +65 │ │ │ │ │ +_6_7 static float const _S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; // = 0.0f, do we really need this? │ │ │ │ │ +_6_8 static float const _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; // = 10.0f; │ │ │ │ │ +69 │ │ │ │ │ +_7_0 static bool _I_s_S_m_o_o_t_h(float sharpness) { return sharpness <= │ │ │ │ │ +_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; } │ │ │ │ │ +_7_1 static bool _I_s_S_h_a_r_p(float sharpness) { return sharpness > _S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; │ │ │ │ │ +} │ │ │ │ │ +_7_2 static bool _I_s_I_n_f_i_n_i_t_e(float sharpness) { return sharpness >= │ │ │ │ │ +_S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; } │ │ │ │ │ +_7_3 static bool _I_s_S_e_m_i_S_h_a_r_p(float sharpness) { return (_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H < │ │ │ │ │ +sharpness) && (sharpness < _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E); } │ │ │ │ │ +75 │ │ │ │ │ +_8_2 enum _R_u_l_e { │ │ │ │ │ +_8_3 _R_U_L_E___U_N_K_N_O_W_N = 0, │ │ │ │ │ +_8_4 _R_U_L_E___S_M_O_O_T_H = (1 << 0), │ │ │ │ │ +_8_5 _R_U_L_E___D_A_R_T = (1 << 1), │ │ │ │ │ +_8_6 _R_U_L_E___C_R_E_A_S_E = (1 << 2), │ │ │ │ │ +87 _R_U_L_E___C_O_R_N_E_R = (1 << 3) │ │ │ │ │ +_8_8 }; │ │ │ │ │ +89 │ │ │ │ │ +90public: │ │ │ │ │ +_9_1 _C_r_e_a_s_e() : _options() { } │ │ │ │ │ +_9_2 _C_r_e_a_s_e(_O_p_t_i_o_n_s const& options) : _options(options) { } │ │ │ │ │ +_9_3 _~_C_r_e_a_s_e() { } │ │ │ │ │ +94 │ │ │ │ │ +_9_5 bool _I_s_U_n_i_f_o_r_m() const { return _options._G_e_t_C_r_e_a_s_i_n_g_M_e_t_h_o_d() == _O_p_t_i_o_n_s_:_: │ │ │ │ │ +_C_R_E_A_S_E___U_N_I_F_O_R_M; } │ │ │ │ │ +96 │ │ │ │ │ 98 │ │ │ │ │ -99 face0IsTri = (vertsPerFace[0] == 3); │ │ │ │ │ -100 face1IsTri = (vertsPerFace[1] == 3); │ │ │ │ │ -101 useTriangleOption = face0IsTri || face1IsTri; │ │ │ │ │ -102 } else { │ │ │ │ │ -103 useTriangleOption = false; │ │ │ │ │ -104 } │ │ │ │ │ -105 } │ │ │ │ │ +104 float _S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_E_d_g_e(float edgeSharpness) const; │ │ │ │ │ +105 float _S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_V_e_r_t_e_x(float edgeSharpness) const; │ │ │ │ │ 106 │ │ │ │ │ -107 if (! useTriangleOption) { │ │ │ │ │ -108 mask.VertexWeight(0) = 0.25f; │ │ │ │ │ -109 mask.VertexWeight(1) = 0.25f; │ │ │ │ │ -110 │ │ │ │ │ -111 if (faceCount == 2) { │ │ │ │ │ -112 mask.FaceWeight(0) = 0.25f; │ │ │ │ │ -113 mask.FaceWeight(1) = 0.25f; │ │ │ │ │ -114 } else { │ │ │ │ │ -115 Weight fWeight = 0.5f / (Weight)faceCount; │ │ │ │ │ -116 for (int i = 0; i < faceCount; ++i) { │ │ │ │ │ -117 mask.FaceWeight(i) = fWeight; │ │ │ │ │ -118 } │ │ │ │ │ -119 } │ │ │ │ │ -120 } else { │ │ │ │ │ -121 // │ │ │ │ │ -122 // This mimics the implementation in Hbr in terms of order of operations. │ │ │ │ │ -123 // │ │ │ │ │ -124 const Weight CATMARK_SMOOTH_TRI_EDGE_WEIGHT = (Weight) 0.470; │ │ │ │ │ +107 // For future consideration │ │ │ │ │ +108 //float SharpenNonManifoldEdge(float edgeSharpness) const; │ │ │ │ │ +109 //float SharpenNonManifoldVertex(float edgeSharpness) const; │ │ │ │ │ +111 │ │ │ │ │ +113 │ │ │ │ │ +124 float _S_u_b_d_i_v_i_d_e_U_n_i_f_o_r_m_S_h_a_r_p_n_e_s_s(float vertexOrEdgeSharpness) const; │ │ │ │ │ 125 │ │ │ │ │ -126 Weight f0Weight = face0IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f; │ │ │ │ │ -127 Weight f1Weight = face1IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f; │ │ │ │ │ -128 │ │ │ │ │ -129 Weight fWeight = 0.5f * (f0Weight + f1Weight); │ │ │ │ │ -130 Weight vWeight = 0.5f * (1.0f - 2.0f * fWeight); │ │ │ │ │ +126 float _S_u_b_d_i_v_i_d_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float vertexSharpness) const; │ │ │ │ │ +127 │ │ │ │ │ +_1_2_8 float _S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_A_t_V_e_r_t_e_x(float edgeSharpness, │ │ │ │ │ +129 int incidentEdgeCountAtEndVertex, │ │ │ │ │ +130 float const* edgeSharpnessAroundEndVertex) const; │ │ │ │ │ 131 │ │ │ │ │ -132 mask.VertexWeight(0) = vWeight; │ │ │ │ │ -133 mask.VertexWeight(1) = vWeight; │ │ │ │ │ -134 │ │ │ │ │ -135 mask.FaceWeight(0) = fWeight; │ │ │ │ │ -136 mask.FaceWeight(1) = fWeight; │ │ │ │ │ -137 } │ │ │ │ │ -138} │ │ │ │ │ -139 │ │ │ │ │ -140 │ │ │ │ │ -141// │ │ │ │ │ -142// Masks for vertex-vertices: the hard Corner mask does not need to be │ │ │ │ │ -specialized │ │ │ │ │ -143// (simply the vertex itself), leaving the Crease and Smooth cases (Dart is │ │ │ │ │ -smooth): │ │ │ │ │ -144// │ │ │ │ │ -145template <> │ │ │ │ │ -146template │ │ │ │ │ -147inline void │ │ │ │ │ -_1_4_8_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_r_e_a_s_e_M_a_s_k_F_o_r_V_e_r_t_e_x(VERTEX const& vertex, │ │ │ │ │ -MASK& mask, │ │ │ │ │ -149 int const creaseEnds[2]) const { │ │ │ │ │ -150 typedef typename MASK::Weight Weight; │ │ │ │ │ -151 │ │ │ │ │ -152 int valence = vertex.GetNumEdges(); │ │ │ │ │ -153 │ │ │ │ │ -154 mask.SetNumVertexWeights(1); │ │ │ │ │ -155 mask.SetNumEdgeWeights(valence); │ │ │ │ │ -156 mask.SetNumFaceWeights(0); │ │ │ │ │ -157 mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -158 │ │ │ │ │ -159 Weight vWeight = 0.75f; │ │ │ │ │ -160 Weight eWeight = 0.125f; │ │ │ │ │ -161 │ │ │ │ │ -162 mask.VertexWeight(0) = vWeight; │ │ │ │ │ -163 for (int i = 0; i < valence; ++i) { │ │ │ │ │ -164 mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -165 } │ │ │ │ │ -166 mask.EdgeWeight(creaseEnds[0]) = eWeight; │ │ │ │ │ -167 mask.EdgeWeight(creaseEnds[1]) = eWeight; │ │ │ │ │ -168} │ │ │ │ │ -169 │ │ │ │ │ -170template <> │ │ │ │ │ -171template │ │ │ │ │ -172inline void │ │ │ │ │ -_1_7_3_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_V_e_r_t_e_x(VERTEX const& vertex, │ │ │ │ │ -MASK& mask) const { │ │ │ │ │ -174 │ │ │ │ │ -175 typedef typename MASK::Weight Weight; │ │ │ │ │ +_1_3_2 void _S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_e_s_A_r_o_u_n_d_V_e_r_t_e_x(int incidentEdgeCountAtVertex, │ │ │ │ │ +133 float const* incidentEdgeSharpnessAroundVertex, │ │ │ │ │ +134 float* childEdgesSharpnessAroundVertex) const; │ │ │ │ │ +136 │ │ │ │ │ +138 │ │ │ │ │ +_1_4_4 _R_u_l_e _D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e(float vertexSharpness, │ │ │ │ │ +145 int incidentEdgeCount, │ │ │ │ │ +146 float const* incidentEdgeSharpness) const; │ │ │ │ │ +_1_4_7 _R_u_l_e _D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e(float vertexSharpness, │ │ │ │ │ +148 int sharpEdgeCount) const; │ │ │ │ │ +150 │ │ │ │ │ +_1_6_2 float _C_o_m_p_u_t_e_F_r_a_c_t_i_o_n_a_l_W_e_i_g_h_t_A_t_V_e_r_t_e_x(float vertexSharpness, │ │ │ │ │ +163 float childVertexSharpness, │ │ │ │ │ +164 int incidentEdgeCount, │ │ │ │ │ +165 float const* incidentEdgeSharpness, │ │ │ │ │ +166 float const* childEdgesSharpness) const; │ │ │ │ │ +167 │ │ │ │ │ +168 void _G_e_t_S_h_a_r_p_E_d_g_e_P_a_i_r_O_f_C_r_e_a_s_e(float const * incidentEdgeSharpness, │ │ │ │ │ +169 int incidentEdgeCount, │ │ │ │ │ +170 int sharpEdgePair[2]) const; │ │ │ │ │ +171 │ │ │ │ │ +172 // Would these really help? Maybe only need Rules for the vertex-vertex │ │ │ │ │ +case... │ │ │ │ │ +173 // │ │ │ │ │ +174 // Rule DetermineEdgeVertexRule(float parentEdgeSharpness) const; │ │ │ │ │ +175 // Rule DetermineEdgeVertexRule(float childEdge1Sharpness, float │ │ │ │ │ +childEdge2Sharpness) const; │ │ │ │ │ 176 │ │ │ │ │ -177 // │ │ │ │ │ -178 // A Smooth vertex must be manifold and interior -- manifold boundary │ │ │ │ │ -vertices will be │ │ │ │ │ -179 // Creases and non-manifold vertices of any kind will be Corners or │ │ │ │ │ -Creases. If smooth │ │ │ │ │ -180 // rules for non-manifold vertices are ever defined, this will need │ │ │ │ │ -adjusting: │ │ │ │ │ -181 // │ │ │ │ │ -182 assert(vertex.GetNumFaces() == vertex.GetNumEdges()); │ │ │ │ │ +177protected: │ │ │ │ │ +178 float _d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(float sharpness) const; │ │ │ │ │ +179 │ │ │ │ │ +180private: │ │ │ │ │ +181 _O_p_t_i_o_n_s _options; │ │ │ │ │ +182}; │ │ │ │ │ 183 │ │ │ │ │ -184 int valence = vertex.GetNumFaces(); │ │ │ │ │ -185 │ │ │ │ │ -186 mask.SetNumVertexWeights(1); │ │ │ │ │ -187 mask.SetNumEdgeWeights(valence); │ │ │ │ │ -188 mask.SetNumFaceWeights(valence); │ │ │ │ │ -189 mask.SetFaceWeightsForFaceCenters(true); │ │ │ │ │ +184 │ │ │ │ │ +185// │ │ │ │ │ +186// Inline declarations: │ │ │ │ │ +187// │ │ │ │ │ +188inline float │ │ │ │ │ +_1_8_9_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_E_d_g_e(float /* edgeSharpness */) const { │ │ │ │ │ 190 │ │ │ │ │ -191 Weight vWeight = (Weight)(valence - 2) / (Weight)valence; │ │ │ │ │ -192 Weight fWeight = 1.0f / (Weight)(valence * valence); │ │ │ │ │ -193 Weight eWeight = fWeight; │ │ │ │ │ -194 │ │ │ │ │ -195 mask.VertexWeight(0) = vWeight; │ │ │ │ │ -196 for (int i = 0; i < valence; ++i) { │ │ │ │ │ -197 mask.EdgeWeight(i) = eWeight; │ │ │ │ │ -198 mask.FaceWeight(i) = fWeight; │ │ │ │ │ -199 } │ │ │ │ │ -200} │ │ │ │ │ +191 // │ │ │ │ │ +192 // Despite the presence of the BOUNDARY_NONE option, boundary edges are │ │ │ │ │ +always sharpened. │ │ │ │ │ +193 // Much of the code relies on sharpness to indicate boundaries to avoid the │ │ │ │ │ +more complex │ │ │ │ │ +194 // topological inspection │ │ │ │ │ +195 // │ │ │ │ │ +196 return _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; │ │ │ │ │ +197} │ │ │ │ │ +198 │ │ │ │ │ +199inline float │ │ │ │ │ +_2_0_0_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_V_e_r_t_e_x(float vertexSharpness) const { │ │ │ │ │ 201 │ │ │ │ │ -202// │ │ │ │ │ -203// Limit masks for position: │ │ │ │ │ -204// │ │ │ │ │ -205template <> │ │ │ │ │ -206template │ │ │ │ │ -207inline void │ │ │ │ │ -_2_0_8_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_M_a_s_k(VERTEX const& /* vertex */, │ │ │ │ │ -MASK& posMask) const { │ │ │ │ │ -209 │ │ │ │ │ -210 posMask.SetNumVertexWeights(1); │ │ │ │ │ -211 posMask.SetNumEdgeWeights(0); │ │ │ │ │ -212 posMask.SetNumFaceWeights(0); │ │ │ │ │ -213 posMask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +202 return (_options._G_e_t_V_t_x_B_o_u_n_d_a_r_y_I_n_t_e_r_p_o_l_a_t_i_o_n() == _O_p_t_i_o_n_s_:_: │ │ │ │ │ +_V_T_X___B_O_U_N_D_A_R_Y___E_D_G_E___A_N_D___C_O_R_N_E_R) ? │ │ │ │ │ +203 _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E : vertexSharpness; │ │ │ │ │ +204} │ │ │ │ │ +205 │ │ │ │ │ +206inline float │ │ │ │ │ +_2_0_7_C_r_e_a_s_e_:_:_d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(float sharpness) const { │ │ │ │ │ +208 │ │ │ │ │ +209 if (_I_s_S_m_o_o_t_h(sharpness)) return _C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; // redundant but │ │ │ │ │ +most common │ │ │ │ │ +210 if (_I_s_I_n_f_i_n_i_t_e(sharpness)) return _C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; │ │ │ │ │ +211 if (sharpness > 1.0f) return (sharpness - 1.0f); │ │ │ │ │ +212 return _C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; │ │ │ │ │ +213} │ │ │ │ │ 214 │ │ │ │ │ -215 posMask.VertexWeight(0) = 1.0f; │ │ │ │ │ -216} │ │ │ │ │ +215inline float │ │ │ │ │ +_2_1_6_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_U_n_i_f_o_r_m_S_h_a_r_p_n_e_s_s(float vertexOrEdgeSharpness) const { │ │ │ │ │ 217 │ │ │ │ │ -218template <> │ │ │ │ │ -219template │ │ │ │ │ -220inline void │ │ │ │ │ -_2_2_1_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_M_a_s_k(VERTEX const& vertex, MASK& │ │ │ │ │ -posMask, │ │ │ │ │ -222 int const creaseEnds[2]) const { │ │ │ │ │ +218 return _d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(vertexOrEdgeSharpness); │ │ │ │ │ +219} │ │ │ │ │ +220 │ │ │ │ │ +221inline float │ │ │ │ │ +_2_2_2_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float vertexSharpness) const { │ │ │ │ │ 223 │ │ │ │ │ -224 typedef typename MASK::Weight Weight; │ │ │ │ │ -225 │ │ │ │ │ -226 int valence = vertex.GetNumEdges(); │ │ │ │ │ -227 │ │ │ │ │ -228 posMask.SetNumVertexWeights(1); │ │ │ │ │ -229 posMask.SetNumEdgeWeights(valence); │ │ │ │ │ -230 posMask.SetNumFaceWeights(0); │ │ │ │ │ -231 posMask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -232 │ │ │ │ │ -233 Weight vWeight = (Weight)(2.0 / 3.0); │ │ │ │ │ -234 Weight eWeight = (Weight)(1.0 / 6.0); │ │ │ │ │ -235 │ │ │ │ │ -236 posMask.VertexWeight(0) = vWeight; │ │ │ │ │ -237 for (int i = 0; i < valence; ++i) { │ │ │ │ │ -238 posMask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -239 } │ │ │ │ │ -240 posMask.EdgeWeight(creaseEnds[0]) = eWeight; │ │ │ │ │ -241 posMask.EdgeWeight(creaseEnds[1]) = eWeight; │ │ │ │ │ -242} │ │ │ │ │ -243 │ │ │ │ │ -244template <> │ │ │ │ │ -245template │ │ │ │ │ -246inline void │ │ │ │ │ -_2_4_7_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_M_a_s_k(VERTEX const& vertex, MASK& │ │ │ │ │ -posMask) const { │ │ │ │ │ -248 │ │ │ │ │ -249 typedef typename MASK::Weight Weight; │ │ │ │ │ -250 │ │ │ │ │ -251 int valence = vertex.GetNumFaces(); │ │ │ │ │ -252 if (valence == 2) { │ │ │ │ │ -253 assignCornerLimitMask(vertex, posMask); │ │ │ │ │ -254 return; │ │ │ │ │ -255 } │ │ │ │ │ -256 │ │ │ │ │ -257 posMask.SetNumVertexWeights(1); │ │ │ │ │ -258 posMask.SetNumEdgeWeights(valence); │ │ │ │ │ -259 posMask.SetNumFaceWeights(valence); │ │ │ │ │ -260 posMask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -261 │ │ │ │ │ -262 // Specialize for the regular case: │ │ │ │ │ -263 if (valence == 4) { │ │ │ │ │ -264 Weight fWeight = (Weight)(1.0 / 36.0); │ │ │ │ │ -265 Weight eWeight = (Weight)(1.0 / 9.0); │ │ │ │ │ -266 Weight vWeight = (Weight)(4.0 / 9.0); │ │ │ │ │ -267 │ │ │ │ │ -268 posMask.VertexWeight(0) = vWeight; │ │ │ │ │ -269 │ │ │ │ │ -270 posMask.EdgeWeight(0) = eWeight; │ │ │ │ │ -271 posMask.EdgeWeight(1) = eWeight; │ │ │ │ │ -272 posMask.EdgeWeight(2) = eWeight; │ │ │ │ │ -273 posMask.EdgeWeight(3) = eWeight; │ │ │ │ │ -274 │ │ │ │ │ -275 posMask.FaceWeight(0) = fWeight; │ │ │ │ │ -276 posMask.FaceWeight(1) = fWeight; │ │ │ │ │ -277 posMask.FaceWeight(2) = fWeight; │ │ │ │ │ -278 posMask.FaceWeight(3) = fWeight; │ │ │ │ │ -279 } else { │ │ │ │ │ -280 Weight Valence = (Weight) valence; │ │ │ │ │ -281 │ │ │ │ │ -282 Weight fWeight = 1.0f / (Valence * (Valence + 5.0f)); │ │ │ │ │ -283 Weight eWeight = 4.0f * fWeight; │ │ │ │ │ -284 Weight vWeight = 1.0f - Valence * (eWeight + fWeight); │ │ │ │ │ -285 │ │ │ │ │ -286 posMask.VertexWeight(0) = vWeight; │ │ │ │ │ -287 for (int i = 0; i < valence; ++i) { │ │ │ │ │ -288 posMask.EdgeWeight(i) = eWeight; │ │ │ │ │ -289 posMask.FaceWeight(i) = fWeight; │ │ │ │ │ -290 } │ │ │ │ │ -291 } │ │ │ │ │ -292} │ │ │ │ │ -293 │ │ │ │ │ -294// │ │ │ │ │ -295// Limit masks for tangents -- these are stubs for now, or have a temporary │ │ │ │ │ -296// implementation │ │ │ │ │ -297// │ │ │ │ │ -298template <> │ │ │ │ │ -299template │ │ │ │ │ -300inline void │ │ │ │ │ -_3_0_1_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s(VERTEX const& vertex, │ │ │ │ │ -302 MASK& tan1Mask, MASK& tan2Mask) const { │ │ │ │ │ -303 │ │ │ │ │ -304 int valence = vertex.GetNumEdges(); │ │ │ │ │ -305 │ │ │ │ │ -306 tan1Mask.SetNumVertexWeights(1); │ │ │ │ │ -307 tan1Mask.SetNumEdgeWeights(valence); │ │ │ │ │ -308 tan1Mask.SetNumFaceWeights(0); │ │ │ │ │ -309 tan1Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -310 │ │ │ │ │ -311 tan2Mask.SetNumVertexWeights(1); │ │ │ │ │ -312 tan2Mask.SetNumEdgeWeights(valence); │ │ │ │ │ -313 tan2Mask.SetNumFaceWeights(0); │ │ │ │ │ -314 tan2Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -315 │ │ │ │ │ -316 // Should be at least 2 edges -- be sure to clear weights for any more: │ │ │ │ │ -317 tan1Mask.VertexWeight(0) = -1.0f; │ │ │ │ │ -318 tan1Mask.EdgeWeight(0) = 1.0f; │ │ │ │ │ -319 tan1Mask.EdgeWeight(1) = 0.0f; │ │ │ │ │ -320 │ │ │ │ │ -321 tan2Mask.VertexWeight(0) = -1.0f; │ │ │ │ │ -322 tan2Mask.EdgeWeight(0) = 0.0f; │ │ │ │ │ -323 tan2Mask.EdgeWeight(1) = 1.0f; │ │ │ │ │ -324 │ │ │ │ │ -325 for (int i = 2; i < valence; ++i) { │ │ │ │ │ -326 tan1Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -327 tan2Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -328 } │ │ │ │ │ -329} │ │ │ │ │ -330 │ │ │ │ │ -331template <> │ │ │ │ │ -332template │ │ │ │ │ -333inline void │ │ │ │ │ -_3_3_4_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s(VERTEX const& vertex, │ │ │ │ │ -335 MASK& tan1Mask, MASK& tan2Mask, int const creaseEnds[2]) const { │ │ │ │ │ -336 │ │ │ │ │ -337 typedef typename MASK::Weight Weight; │ │ │ │ │ -338 │ │ │ │ │ -339 // │ │ │ │ │ -340 // First, the tangent along the crease: │ │ │ │ │ -341 // The first crease edge is considered the "leading" edge of the span │ │ │ │ │ -342 // of surface for which we are evaluating tangents and the second edge the │ │ │ │ │ -343 // "trailing edge". By convention, the tangent along the crease is oriented │ │ │ │ │ -344 // in the direction of the leading edge. │ │ │ │ │ -345 // │ │ │ │ │ -346 int numEdges = vertex.GetNumEdges(); │ │ │ │ │ -347 int numFaces = vertex.GetNumFaces(); │ │ │ │ │ -348 │ │ │ │ │ -349 tan1Mask.SetNumVertexWeights(1); │ │ │ │ │ -350 tan1Mask.SetNumEdgeWeights(numEdges); │ │ │ │ │ -351 tan1Mask.SetNumFaceWeights(numFaces); │ │ │ │ │ -352 tan1Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -353 │ │ │ │ │ -354 tan1Mask.VertexWeight(0) = 0.0f; │ │ │ │ │ -355 for (int i = 0; i < numEdges; ++i) { │ │ │ │ │ -356 tan1Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -357 } │ │ │ │ │ -358 for (int i = 0; i < numFaces; ++i) { │ │ │ │ │ -359 tan1Mask.FaceWeight(i) = 0.0f; │ │ │ │ │ -360 } │ │ │ │ │ -361 │ │ │ │ │ -362 tan1Mask.EdgeWeight(creaseEnds[0]) = 0.5f; │ │ │ │ │ -363 tan1Mask.EdgeWeight(creaseEnds[1]) = -0.5f; │ │ │ │ │ -364 │ │ │ │ │ -365 // │ │ │ │ │ -366 // Second, the tangent across the interior faces: │ │ │ │ │ -367 // Note this is ambiguous for an interior vertex. We currently return │ │ │ │ │ -368 // the tangent for the surface in the counter-clockwise span between the │ │ │ │ │ -369 // leading and trailing edges that form the crease. Given the expected │ │ │ │ │ -370 // computation of a surface normal as Tan1 X Tan2, this tangent should be │ │ │ │ │ -371 // oriented "inward" from the crease/boundary -- across the surface rather │ │ │ │ │ -372 // than outward and away from it. │ │ │ │ │ -373 // │ │ │ │ │ -374 tan2Mask.SetNumVertexWeights(1); │ │ │ │ │ -375 tan2Mask.SetNumEdgeWeights(numEdges); │ │ │ │ │ -376 tan2Mask.SetNumFaceWeights(numFaces); │ │ │ │ │ -377 tan2Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -378 │ │ │ │ │ -379 // Prepend weights of 0 preceding the crease: │ │ │ │ │ -380 for (int i = 0; i < creaseEnds[0]; ++i) { │ │ │ │ │ -381 tan2Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -382 tan2Mask.FaceWeight(i) = 0.0f; │ │ │ │ │ -383 } │ │ │ │ │ -384 │ │ │ │ │ -385 // Assign weights to crease edge and interior points: │ │ │ │ │ -386 int interiorEdgeCount = creaseEnds[1] - creaseEnds[0] - 1; │ │ │ │ │ -387 if (interiorEdgeCount == 1) { │ │ │ │ │ -388 // The regular case -- uniform B-spline cross-tangent: │ │ │ │ │ -389 │ │ │ │ │ -390 tan2Mask.VertexWeight(0) = (Weight)(-4.0 / 6.0); │ │ │ │ │ -391 │ │ │ │ │ -392 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight)(-1.0 / 6.0); │ │ │ │ │ -393 tan2Mask.EdgeWeight(creaseEnds[0] + 1) = (Weight)( 4.0 / 6.0); │ │ │ │ │ -394 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight)(-1.0 / 6.0); │ │ │ │ │ -395 │ │ │ │ │ -396 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight)(1.0 / 6.0); │ │ │ │ │ -397 tan2Mask.FaceWeight(creaseEnds[0] + 1) = (Weight)(1.0 / 6.0); │ │ │ │ │ -398 } else if (interiorEdgeCount > 1) { │ │ │ │ │ -399 // The irregular case -- formulae from Biermann et al: │ │ │ │ │ -400 │ │ │ │ │ -401 double k = (double) (interiorEdgeCount + 1); │ │ │ │ │ -402 double theta = M_PI / k; │ │ │ │ │ -403 │ │ │ │ │ -404 double cosTheta = std::cos(theta); │ │ │ │ │ -405 double sinTheta = std::sin(theta); │ │ │ │ │ -406 │ │ │ │ │ -407 // Loop/Schaefer use a different divisor here (3*k + cos(theta)): │ │ │ │ │ -408 double commonDenom = 1.0f / (k * (3.0f + cosTheta)); │ │ │ │ │ -409 double R = (cosTheta + 1.0f) / sinTheta; │ │ │ │ │ -410 │ │ │ │ │ -411 double vertexWeight = 4.0f * R * (cosTheta - 1.0f); │ │ │ │ │ -412 double creaseWeight = -R * (1.0f + 2.0f * cosTheta); │ │ │ │ │ -413 │ │ │ │ │ -414 tan2Mask.VertexWeight(0) = (Weight) (vertexWeight * commonDenom); │ │ │ │ │ -415 │ │ │ │ │ -416 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight) (creaseWeight * commonDenom); │ │ │ │ │ -417 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight) (creaseWeight * commonDenom); │ │ │ │ │ -418 │ │ │ │ │ -419 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight) (sinTheta * commonDenom); │ │ │ │ │ -420 │ │ │ │ │ -421 double sinThetaI = 0.0f; │ │ │ │ │ -422 double sinThetaIplus1 = sinTheta; │ │ │ │ │ -423 for (int i = 1; i < k; ++i) { │ │ │ │ │ -424 sinThetaI = sinThetaIplus1; │ │ │ │ │ -425 sinThetaIplus1 = std::sin((i+1)*theta); │ │ │ │ │ -426 │ │ │ │ │ -427 tan2Mask.EdgeWeight(creaseEnds[0] + i) = (Weight) ((4.0f * sinThetaI) * │ │ │ │ │ -commonDenom); │ │ │ │ │ -428 tan2Mask.FaceWeight(creaseEnds[0] + i) = (Weight) ((sinThetaI + │ │ │ │ │ -sinThetaIplus1) * commonDenom); │ │ │ │ │ -429 } │ │ │ │ │ -430 } else { │ │ │ │ │ -431 // Special case for a single face -- simple average of boundary edges: │ │ │ │ │ -432 │ │ │ │ │ -433 tan2Mask.VertexWeight(0) = -6.0f; │ │ │ │ │ -434 │ │ │ │ │ -435 tan2Mask.EdgeWeight(creaseEnds[0]) = 3.0f; │ │ │ │ │ -436 tan2Mask.EdgeWeight(creaseEnds[1]) = 3.0f; │ │ │ │ │ -437 │ │ │ │ │ -438 tan2Mask.FaceWeight(creaseEnds[0]) = 0.0f; │ │ │ │ │ -439 } │ │ │ │ │ -440 │ │ │ │ │ -441 // Append weights of 0 following the crease: │ │ │ │ │ -442 for (int i = creaseEnds[1]; i < numFaces; ++i) { │ │ │ │ │ -443 tan2Mask.FaceWeight(i) = 0.0f; │ │ │ │ │ -444 } │ │ │ │ │ -445 for (int i = creaseEnds[1] + 1; i < numEdges; ++i) { │ │ │ │ │ -446 tan2Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ -447 } │ │ │ │ │ -448} │ │ │ │ │ -449 │ │ │ │ │ -450template <> │ │ │ │ │ -451template │ │ │ │ │ -452inline void │ │ │ │ │ -_4_5_3_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s(VERTEX const& vertex, │ │ │ │ │ -454 MASK& tan1Mask, MASK& tan2Mask) const { │ │ │ │ │ -455 │ │ │ │ │ -456 typedef typename MASK::Weight Weight; │ │ │ │ │ -457 │ │ │ │ │ -458 int valence = vertex.GetNumFaces(); │ │ │ │ │ -459 if (valence == 2) { │ │ │ │ │ -460 assignCornerLimitTangentMasks(vertex, tan1Mask, tan2Mask); │ │ │ │ │ -461 return; │ │ │ │ │ -462 } │ │ │ │ │ -463 │ │ │ │ │ -464 // Compute tan1 initially -- tan2 is simply a rotation: │ │ │ │ │ -465 tan1Mask.SetNumVertexWeights(1); │ │ │ │ │ -466 tan1Mask.SetNumEdgeWeights(valence); │ │ │ │ │ -467 tan1Mask.SetNumFaceWeights(valence); │ │ │ │ │ -468 tan1Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -469 │ │ │ │ │ -470 tan1Mask.VertexWeight(0) = 0.0f; │ │ │ │ │ -471 │ │ │ │ │ -472 if (valence == 4) { │ │ │ │ │ -473 tan1Mask.EdgeWeight(0) = 4.0f; │ │ │ │ │ -474 tan1Mask.EdgeWeight(1) = 0.0f; │ │ │ │ │ -475 tan1Mask.EdgeWeight(2) = -4.0f; │ │ │ │ │ -476 tan1Mask.EdgeWeight(3) = 0.0f; │ │ │ │ │ -477 │ │ │ │ │ -478 tan1Mask.FaceWeight(0) = 1.0f; │ │ │ │ │ -479 tan1Mask.FaceWeight(1) = -1.0f; │ │ │ │ │ -480 tan1Mask.FaceWeight(2) = -1.0f; │ │ │ │ │ -481 tan1Mask.FaceWeight(3) = 1.0f; │ │ │ │ │ -482 } else { │ │ │ │ │ -483 double theta = 2.0f * M_PI / (double)valence; │ │ │ │ │ -484 │ │ │ │ │ -485 double cosTheta = std::cos(theta); │ │ │ │ │ -486 double cosHalfTheta = std::cos(theta * 0.5f); │ │ │ │ │ -487 │ │ │ │ │ -488 double lambda = (5.0 / 16.0) + (1.0 / 16.0) * │ │ │ │ │ -489 (cosTheta + cosHalfTheta * std::sqrt(2.0f * (9.0f + cosTheta))); │ │ │ │ │ -490 │ │ │ │ │ -491 double edgeWeightScale = 4.0f; │ │ │ │ │ -492 double faceWeightScale = 1.0f / (4.0f * lambda - 1.0f); │ │ │ │ │ -493 │ │ │ │ │ -494 for (int i = 0; i < valence; ++i) { │ │ │ │ │ -495 double cosThetaI = std::cos( i * theta); │ │ │ │ │ -496 double cosThetaIplus1 = std::cos((i+1)* theta); │ │ │ │ │ -497 │ │ │ │ │ -498 tan1Mask.EdgeWeight(i) = (Weight) (edgeWeightScale * cosThetaI); │ │ │ │ │ -499 tan1Mask.FaceWeight(i) = (Weight) (faceWeightScale * (cosThetaI + │ │ │ │ │ -cosThetaIplus1)); │ │ │ │ │ -500 } │ │ │ │ │ -501 } │ │ │ │ │ -502 │ │ │ │ │ -503 // Now rotate/copy tan1 weights to tan2: │ │ │ │ │ -504 tan2Mask.SetNumVertexWeights(1); │ │ │ │ │ -505 tan2Mask.SetNumEdgeWeights(valence); │ │ │ │ │ -506 tan2Mask.SetNumFaceWeights(valence); │ │ │ │ │ -507 tan2Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ -508 │ │ │ │ │ -509 tan2Mask.VertexWeight(0) = 0.0f; │ │ │ │ │ -510 if (valence == 4) { │ │ │ │ │ -511 tan2Mask.EdgeWeight(0) = 0.0f; │ │ │ │ │ -512 tan2Mask.EdgeWeight(1) = 4.0f; │ │ │ │ │ -513 tan2Mask.EdgeWeight(2) = 0.0f; │ │ │ │ │ -514 tan2Mask.EdgeWeight(3) = -4.0f; │ │ │ │ │ -515 │ │ │ │ │ -516 tan2Mask.FaceWeight(0) = 1.0f; │ │ │ │ │ -517 tan2Mask.FaceWeight(1) = 1.0f; │ │ │ │ │ -518 tan2Mask.FaceWeight(2) = -1.0f; │ │ │ │ │ -519 tan2Mask.FaceWeight(3) = -1.0f; │ │ │ │ │ -520 } else { │ │ │ │ │ -521 tan2Mask.EdgeWeight(0) = tan1Mask.EdgeWeight(valence-1); │ │ │ │ │ -522 tan2Mask.FaceWeight(0) = tan1Mask.FaceWeight(valence-1); │ │ │ │ │ -523 for (int i = 1; i < valence; ++i) { │ │ │ │ │ -524 tan2Mask.EdgeWeight(i) = tan1Mask.EdgeWeight(i-1); │ │ │ │ │ -525 tan2Mask.FaceWeight(i) = tan1Mask.FaceWeight(i-1); │ │ │ │ │ -526 } │ │ │ │ │ -527 } │ │ │ │ │ -528} │ │ │ │ │ -529 │ │ │ │ │ -530} // end namespace sdc │ │ │ │ │ -531 │ │ │ │ │ -532} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -533using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -534} // end namespace OpenSubdiv │ │ │ │ │ -535 │ │ │ │ │ -536#endif /* OPENSUBDIV3_SDC_CATMARK_SCHEME_H */ │ │ │ │ │ +224 return _d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(vertexSharpness); │ │ │ │ │ +225} │ │ │ │ │ +226 │ │ │ │ │ +227inline void │ │ │ │ │ +_2_2_8_C_r_e_a_s_e_:_:_G_e_t_S_h_a_r_p_E_d_g_e_P_a_i_r_O_f_C_r_e_a_s_e(float const * incidentEdgeSharpness, int │ │ │ │ │ +incidentEdgeCount, │ │ │ │ │ +229 int sharpEdgePair[2]) const { │ │ │ │ │ +230 │ │ │ │ │ +231 // Only to be called when a crease is present at a vertex -- exactly two │ │ │ │ │ +sharp │ │ │ │ │ +232 // edges are expected here: │ │ │ │ │ +233 // │ │ │ │ │ +234 sharpEdgePair[0] = 0; │ │ │ │ │ +235 while (_I_s_S_m_o_o_t_h(incidentEdgeSharpness[sharpEdgePair[0]])) ++ sharpEdgePair │ │ │ │ │ +[0]; │ │ │ │ │ +236 │ │ │ │ │ +237 sharpEdgePair[1] = incidentEdgeCount - 1; │ │ │ │ │ +238 while (_I_s_S_m_o_o_t_h(incidentEdgeSharpness[sharpEdgePair[1]])) -- sharpEdgePair │ │ │ │ │ +[1]; │ │ │ │ │ +239} │ │ │ │ │ +240 │ │ │ │ │ +241} // end namespace sdc │ │ │ │ │ +242 │ │ │ │ │ +243} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +244using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +245} // end namespace OpenSubdiv │ │ │ │ │ +246 │ │ │ │ │ +247#endif /* OPENSUBDIV3_SDC_CREASE_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_p_l_i_t │ │ │ │ │ -Split │ │ │ │ │ -Enumerated type for all face splitting schemes. │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_P_L_I_T___T_O___Q_U_A_D_S │ │ │ │ │ -@ SPLIT_TO_QUADS │ │ │ │ │ -Used by Catmark and Bilinear. │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_T_R_I___S_U_B___S_M_O_O_T_H │ │ │ │ │ -@ TRI_SUB_SMOOTH │ │ │ │ │ -"smooth triangle" weights (Catmark scheme only) │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_E_d_g_e │ │ │ │ │ -void assignSmoothMaskForEdge(EDGE const &edge, MASK &mask) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_T_o_p_o_l_o_g_i_c_a_l_S_p_l_i_t_T_y_p_e │ │ │ │ │ -static Split GetTopologicalSplitType() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_r_e_a_s_e_M_a_s_k_F_o_r_V_e_r_t_e_x │ │ │ │ │ -void assignCreaseMaskForVertex(VERTEX const &edge, MASK &mask, int const │ │ │ │ │ -creaseEnds[2]) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s │ │ │ │ │ -void assignCreaseLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK │ │ │ │ │ -&tan2, int const creaseEnds[2]) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_R_e_g_u_l_a_r_F_a_c_e_S_i_z_e │ │ │ │ │ -static int GetRegularFaceSize() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_M_a_s_k │ │ │ │ │ -void assignSmoothLimitMask(VERTEX const &vertex, MASK &pos) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_L_o_c_a_l_N_e_i_g_h_b_o_r_h_o_o_d_S_i_z_e │ │ │ │ │ -static int GetLocalNeighborhoodSize() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_M_a_s_k │ │ │ │ │ -void assignCreaseLimitMask(VERTEX const &vertex, MASK &pos, int const │ │ │ │ │ -creaseEnds[2]) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_V_e_r_t_e_x │ │ │ │ │ -void assignSmoothMaskForVertex(VERTEX const &edge, MASK &mask) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_R_e_g_u_l_a_r_V_e_r_t_e_x_V_a_l_e_n_c_e │ │ │ │ │ -static int GetRegularVertexValence() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s │ │ │ │ │ -void assignSmoothLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK │ │ │ │ │ -&tan2) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_M_a_s_k │ │ │ │ │ -void assignCornerLimitMask(VERTEX const &vertex, MASK &pos) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s │ │ │ │ │ -void assignCornerLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK │ │ │ │ │ -&tan2) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e │ │ │ │ │ +Types, constants and utilities related to semi-sharp creasing – whose │ │ │ │ │ +implementation is independent o... │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float SubdivideVertexSharpness(float vertexSharpness) const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_2_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_I_n_f_i_n_i_t_e │ │ │ │ │ +static bool IsInfinite(float sharpness) │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e │ │ │ │ │ +Rule │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_O_R_N_E_R │ │ │ │ │ +@ RULE_CORNER │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___D_A_R_T │ │ │ │ │ +@ RULE_DART │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___S_M_O_O_T_H │ │ │ │ │ +@ RULE_SMOOTH │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E │ │ │ │ │ +@ RULE_CREASE │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___U_N_K_N_O_W_N │ │ │ │ │ +@ RULE_UNKNOWN │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_V_e_r_t_e_x │ │ │ │ │ +float SharpenBoundaryVertex(float edgeSharpness) const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H │ │ │ │ │ +static float const SHARPNESS_SMOOTH │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_G_e_t_S_h_a_r_p_E_d_g_e_P_a_i_r_O_f_C_r_e_a_s_e │ │ │ │ │ +void GetSharpEdgePairOfCrease(float const *incidentEdgeSharpness, int │ │ │ │ │ +incidentEdgeCount, int sharpEdgePair[2]) const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_2_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E │ │ │ │ │ +static float const SHARPNESS_INFINITE │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e │ │ │ │ │ +Rule DetermineVertexVertexRule(float vertexSharpness, int incidentEdgeCount, │ │ │ │ │ +float const *incidentEdgeSharpness) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float decrementSharpness(float sharpness) const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_0_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_S_m_o_o_t_h │ │ │ │ │ +static bool IsSmooth(float sharpness) │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e │ │ │ │ │ +Rule DetermineVertexVertexRule(float vertexSharpness, int sharpEdgeCount) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_U_n_i_f_o_r_m │ │ │ │ │ +bool IsUniform() const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_S_e_m_i_S_h_a_r_p │ │ │ │ │ +static bool IsSemiSharp(float sharpness) │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_C_r_e_a_s_e │ │ │ │ │ +Crease(Options const &options) │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_: │ │ │ │ │ +_S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_e_s_A_r_o_u_n_d_V_e_r_t_e_x │ │ │ │ │ +void SubdivideEdgeSharpnessesAroundVertex(int incidentEdgeCountAtVertex, float │ │ │ │ │ +const *incidentEdgeSharpnessAroundVertex, float │ │ │ │ │ +*childEdgesSharpnessAroundVertex) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_U_n_i_f_o_r_m_S_h_a_r_p_n_e_s_s │ │ │ │ │ +float SubdivideUniformSharpness(float vertexOrEdgeSharpness) const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_1_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_C_r_e_a_s_e │ │ │ │ │ +Crease() │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_E_d_g_e │ │ │ │ │ +float SharpenBoundaryEdge(float edgeSharpness) const │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_1_8_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_C_o_m_p_u_t_e_F_r_a_c_t_i_o_n_a_l_W_e_i_g_h_t_A_t_V_e_r_t_e_x │ │ │ │ │ +float ComputeFractionalWeightAtVertex(float vertexSharpness, float │ │ │ │ │ +childVertexSharpness, int incidentEdgeCount, float const │ │ │ │ │ +*incidentEdgeSharpness, float const *childEdgesSharpness) const │ │ │ │ │ +Transitional weighting: When the rules applicable to a parent vertex and its │ │ │ │ │ +child differ,... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_A_t_V_e_r_t_e_x │ │ │ │ │ +float SubdivideEdgeSharpnessAtVertex(float edgeSharpness, int │ │ │ │ │ +incidentEdgeCountAtEndVertex, float const *edgeSharpnessAroundEndVertex) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_S_h_a_r_p │ │ │ │ │ +static bool IsSharp(float sharpness) │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_~_C_r_e_a_s_e │ │ │ │ │ +~Crease() │ │ │ │ │ +DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s │ │ │ │ │ +All supported options applying to subdivision scheme. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_C_R_E_A_S_E___U_N_I_F_O_R_M │ │ │ │ │ +@ CREASE_UNIFORM │ │ │ │ │ +Catmark rule. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_G_e_t_C_r_e_a_s_i_n_g_M_e_t_h_o_d │ │ │ │ │ +CreasingMethod GetCreasingMethod() const │ │ │ │ │ +Get edge crease rule. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_1_0_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_G_e_t_V_t_x_B_o_u_n_d_a_r_y_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ +VtxBoundaryInterpolation GetVtxBoundaryInterpolation() const │ │ │ │ │ +Get vertex boundary interpolation rule. │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_8_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_V_T_X___B_O_U_N_D_A_R_Y___E_D_G_E___A_N_D___C_O_R_N_E_R │ │ │ │ │ +@ VTX_BOUNDARY_EDGE_AND_CORNER │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_5_7 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _s_d_c │ │ │ │ │ - * _c_a_t_m_a_r_k_S_c_h_e_m_e_._h │ │ │ │ │ + * _c_r_e_a_s_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00782.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/sdc/crease.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/sdc/catmarkScheme.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -88,43 +88,38 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ -Classes | │ │ │ │ Namespaces
│ │ │ │ -
crease.h File Reference
│ │ │ │ +
catmarkScheme.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../sdc/options.h"
│ │ │ │ +#include "../sdc/scheme.h"
│ │ │ │ +#include <cassert>
│ │ │ │ +#include <cmath>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -

│ │ │ │ -Classes

class  Crease
 Types, constants and utilities related to semi-sharp creasing – whose implementation is independent of the subdivision scheme. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Sdc
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,25 +1,22 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -crease.h File Reference │ │ │ │ │ +_N_a_m_e_s_p_a_c_e_s │ │ │ │ │ +catmarkScheme.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_s_c_h_e_m_e_._h" │ │ │ │ │ +#include │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ -CCllaasssseess │ │ │ │ │ -class   _C_r_e_a_s_e │ │ │ │ │ -  Types, constants and utilities related to semi-sharp creasing – whose │ │ │ │ │ - implementation is independent of the subdivision scheme. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _s_d_c │ │ │ │ │ - * _c_r_e_a_s_e_._h │ │ │ │ │ + * _c_a_t_m_a_r_k_S_c_h_e_m_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00782_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/sdc/crease.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/sdc/catmarkScheme.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
crease.h
│ │ │ │ +
catmarkScheme.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2014 DreamWorks Animation LLC.
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -118,221 +118,566 @@ │ │ │ │
17//
│ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │ -
24#ifndef OPENSUBDIV3_SDC_CREASE_H
│ │ │ │ -
25#define OPENSUBDIV3_SDC_CREASE_H
│ │ │ │ +
24#ifndef OPENSUBDIV3_SDC_CATMARK_SCHEME_H
│ │ │ │ +
25#define OPENSUBDIV3_SDC_CATMARK_SCHEME_H
│ │ │ │
26
│ │ │ │
27#include "../version.h"
│ │ │ │
28
│ │ │ │ -
29#include "../sdc/options.h"
│ │ │ │ +
29#include "../sdc/scheme.h"
│ │ │ │
30
│ │ │ │ -
31namespace OpenSubdiv {
│ │ │ │ -
32namespace OPENSUBDIV_VERSION {
│ │ │ │ +
31#include <cassert>
│ │ │ │ +
32#include <cmath>
│ │ │ │
33
│ │ │ │ -
34namespace Sdc {
│ │ │ │ -
35
│ │ │ │ -
61
│ │ │ │ -
│ │ │ │ -
62class Crease {
│ │ │ │ -
63public:
│ │ │ │ -
65
│ │ │ │ -
67 static float const SHARPNESS_SMOOTH; // = 0.0f, do we really need this?
│ │ │ │ -
68 static float const SHARPNESS_INFINITE; // = 10.0f;
│ │ │ │ -
69
│ │ │ │ -
70 static bool IsSmooth(float sharpness) { return sharpness <= SHARPNESS_SMOOTH; }
│ │ │ │ -
71 static bool IsSharp(float sharpness) { return sharpness > SHARPNESS_SMOOTH; }
│ │ │ │ -
72 static bool IsInfinite(float sharpness) { return sharpness >= SHARPNESS_INFINITE; }
│ │ │ │ -
73 static bool IsSemiSharp(float sharpness) { return (SHARPNESS_SMOOTH < sharpness) && (sharpness < SHARPNESS_INFINITE); }
│ │ │ │ -
75
│ │ │ │ -
│ │ │ │ -
82 enum Rule {
│ │ │ │ - │ │ │ │ -
84 RULE_SMOOTH = (1 << 0),
│ │ │ │ -
85 RULE_DART = (1 << 1),
│ │ │ │ -
86 RULE_CREASE = (1 << 2),
│ │ │ │ -
87 RULE_CORNER = (1 << 3)
│ │ │ │ -
88 };
│ │ │ │ -
│ │ │ │ -
89
│ │ │ │ -
90public:
│ │ │ │ -
91 Crease() : _options() { }
│ │ │ │ -
92 Crease(Options const& options) : _options(options) { }
│ │ │ │ -
93 ~Crease() { }
│ │ │ │ -
94
│ │ │ │ -
95 bool IsUniform() const { return _options.GetCreasingMethod() == Options::CREASE_UNIFORM; }
│ │ │ │ -
96
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Sdc {
│ │ │ │ +
38
│ │ │ │ +
39//
│ │ │ │ +
40// Specializations for Scheme<SCHEME_CATMARK>:
│ │ │ │ +
41//
│ │ │ │ +
42
│ │ │ │ +
43//
│ │ │ │ +
44// Catmark traits:
│ │ │ │ +
45//
│ │ │ │ +
46template <>
│ │ │ │ + │ │ │ │ +
48
│ │ │ │ +
49template <>
│ │ │ │ + │ │ │ │ +
51
│ │ │ │ +
52template <>
│ │ │ │ + │ │ │ │ +
54
│ │ │ │ +
55template <>
│ │ │ │ + │ │ │ │ +
57
│ │ │ │ +
58
│ │ │ │ +
59//
│ │ │ │ +
60// Masks for edge-vertices: the hard Crease mask does not need to be specialized
│ │ │ │ +
61// (simply the midpoint), so all that is left is the Smooth case:
│ │ │ │ +
62//
│ │ │ │ +
63// The Smooth mask is complicated by the need to support the "triangle subdivision"
│ │ │ │ +
64// option, which applies different weighting in the presence of triangles. It is
│ │ │ │ +
65// up for debate as to whether this is useful or not -- we may be able to deprecate
│ │ │ │ +
66// this option.
│ │ │ │ +
67//
│ │ │ │ +
68template <>
│ │ │ │ +
69template <typename EDGE, typename MASK>
│ │ │ │ +
70inline void
│ │ │ │ +
│ │ │ │ +
71Scheme<SCHEME_CATMARK>::assignSmoothMaskForEdge(EDGE const& edge, MASK& mask) const {
│ │ │ │ +
72
│ │ │ │ +
73 typedef typename MASK::Weight Weight;
│ │ │ │ +
74
│ │ │ │ +
75 int faceCount = edge.GetNumFaces();
│ │ │ │ +
76
│ │ │ │ +
77 mask.SetNumVertexWeights(2);
│ │ │ │ +
78 mask.SetNumEdgeWeights(0);
│ │ │ │ +
79 mask.SetNumFaceWeights(faceCount);
│ │ │ │ +
80 mask.SetFaceWeightsForFaceCenters(true);
│ │ │ │ +
81
│ │ │ │ +
82 //
│ │ │ │ +
83 // Determine if we need to inspect incident faces and apply alternate weighting for
│ │ │ │ +
84 // triangles -- and if so, determine which of the two are triangles.
│ │ │ │ +
85 //
│ │ │ │ +
86 bool face0IsTri = false;
│ │ │ │ +
87 bool face1IsTri = false;
│ │ │ │ +
88 bool useTriangleOption = (_options.GetTriangleSubdivision() == Options::TRI_SUB_SMOOTH);
│ │ │ │ +
89 if (useTriangleOption) {
│ │ │ │ +
90 if (faceCount == 2) {
│ │ │ │ +
91 //
│ │ │ │ +
92 // Ideally we want to avoid this inspection when we have already subdivided at
│ │ │ │ +
93 // least once -- need something in the Edge interface to help avoid this, e.g.
│ │ │ │ +
94 // an IsRegular() query, the subdivision level...
│ │ │ │ +
95 //
│ │ │ │ +
96 int vertsPerFace[2];
│ │ │ │ +
97 edge.GetNumVerticesPerFace(vertsPerFace);
│ │ │ │
98
│ │ │ │ -
104 float SharpenBoundaryEdge(float edgeSharpness) const;
│ │ │ │ -
105 float SharpenBoundaryVertex(float edgeSharpness) const;
│ │ │ │ +
99 face0IsTri = (vertsPerFace[0] == 3);
│ │ │ │ +
100 face1IsTri = (vertsPerFace[1] == 3);
│ │ │ │ +
101 useTriangleOption = face0IsTri || face1IsTri;
│ │ │ │ +
102 } else {
│ │ │ │ +
103 useTriangleOption = false;
│ │ │ │ +
104 }
│ │ │ │ +
105 }
│ │ │ │
106
│ │ │ │ -
107 // For future consideration
│ │ │ │ -
108 //float SharpenNonManifoldEdge(float edgeSharpness) const;
│ │ │ │ -
109 //float SharpenNonManifoldVertex(float edgeSharpness) const;
│ │ │ │ -
111
│ │ │ │ -
113
│ │ │ │ -
124 float SubdivideUniformSharpness(float vertexOrEdgeSharpness) const;
│ │ │ │ +
107 if (! useTriangleOption) {
│ │ │ │ +
108 mask.VertexWeight(0) = 0.25f;
│ │ │ │ +
109 mask.VertexWeight(1) = 0.25f;
│ │ │ │ +
110
│ │ │ │ +
111 if (faceCount == 2) {
│ │ │ │ +
112 mask.FaceWeight(0) = 0.25f;
│ │ │ │ +
113 mask.FaceWeight(1) = 0.25f;
│ │ │ │ +
114 } else {
│ │ │ │ +
115 Weight fWeight = 0.5f / (Weight)faceCount;
│ │ │ │ +
116 for (int i = 0; i < faceCount; ++i) {
│ │ │ │ +
117 mask.FaceWeight(i) = fWeight;
│ │ │ │ +
118 }
│ │ │ │ +
119 }
│ │ │ │ +
120 } else {
│ │ │ │ +
121 //
│ │ │ │ +
122 // This mimics the implementation in Hbr in terms of order of operations.
│ │ │ │ +
123 //
│ │ │ │ +
124 const Weight CATMARK_SMOOTH_TRI_EDGE_WEIGHT = (Weight) 0.470;
│ │ │ │
125
│ │ │ │ -
126 float SubdivideVertexSharpness(float vertexSharpness) const;
│ │ │ │ -
127
│ │ │ │ -
128 float SubdivideEdgeSharpnessAtVertex(float edgeSharpness,
│ │ │ │ -
129 int incidentEdgeCountAtEndVertex,
│ │ │ │ -
130 float const* edgeSharpnessAroundEndVertex) const;
│ │ │ │ +
126 Weight f0Weight = face0IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f;
│ │ │ │ +
127 Weight f1Weight = face1IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f;
│ │ │ │ +
128
│ │ │ │ +
129 Weight fWeight = 0.5f * (f0Weight + f1Weight);
│ │ │ │ +
130 Weight vWeight = 0.5f * (1.0f - 2.0f * fWeight);
│ │ │ │
131
│ │ │ │ -
132 void SubdivideEdgeSharpnessesAroundVertex(int incidentEdgeCountAtVertex,
│ │ │ │ -
133 float const* incidentEdgeSharpnessAroundVertex,
│ │ │ │ -
134 float* childEdgesSharpnessAroundVertex) const;
│ │ │ │ -
136
│ │ │ │ -
138
│ │ │ │ -
144 Rule DetermineVertexVertexRule(float vertexSharpness,
│ │ │ │ -
145 int incidentEdgeCount,
│ │ │ │ -
146 float const* incidentEdgeSharpness) const;
│ │ │ │ -
147 Rule DetermineVertexVertexRule(float vertexSharpness,
│ │ │ │ -
148 int sharpEdgeCount) const;
│ │ │ │ -
150
│ │ │ │ -
162 float ComputeFractionalWeightAtVertex(float vertexSharpness,
│ │ │ │ -
163 float childVertexSharpness,
│ │ │ │ -
164 int incidentEdgeCount,
│ │ │ │ -
165 float const* incidentEdgeSharpness,
│ │ │ │ -
166 float const* childEdgesSharpness) const;
│ │ │ │ -
167
│ │ │ │ -
168 void GetSharpEdgePairOfCrease(float const * incidentEdgeSharpness,
│ │ │ │ -
169 int incidentEdgeCount,
│ │ │ │ -
170 int sharpEdgePair[2]) const;
│ │ │ │ -
171
│ │ │ │ -
172 // Would these really help? Maybe only need Rules for the vertex-vertex case...
│ │ │ │ -
173 //
│ │ │ │ -
174 // Rule DetermineEdgeVertexRule(float parentEdgeSharpness) const;
│ │ │ │ -
175 // Rule DetermineEdgeVertexRule(float childEdge1Sharpness, float childEdge2Sharpness) const;
│ │ │ │ +
132 mask.VertexWeight(0) = vWeight;
│ │ │ │ +
133 mask.VertexWeight(1) = vWeight;
│ │ │ │ +
134
│ │ │ │ +
135 mask.FaceWeight(0) = fWeight;
│ │ │ │ +
136 mask.FaceWeight(1) = fWeight;
│ │ │ │ +
137 }
│ │ │ │ +
138}
│ │ │ │ +
│ │ │ │ +
139
│ │ │ │ +
140
│ │ │ │ +
141//
│ │ │ │ +
142// Masks for vertex-vertices: the hard Corner mask does not need to be specialized
│ │ │ │ +
143// (simply the vertex itself), leaving the Crease and Smooth cases (Dart is smooth):
│ │ │ │ +
144//
│ │ │ │ +
145template <>
│ │ │ │ +
146template <typename VERTEX, typename MASK>
│ │ │ │ +
147inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
149 int const creaseEnds[2]) const {
│ │ │ │ +
150 typedef typename MASK::Weight Weight;
│ │ │ │ +
151
│ │ │ │ +
152 int valence = vertex.GetNumEdges();
│ │ │ │ +
153
│ │ │ │ +
154 mask.SetNumVertexWeights(1);
│ │ │ │ +
155 mask.SetNumEdgeWeights(valence);
│ │ │ │ +
156 mask.SetNumFaceWeights(0);
│ │ │ │ +
157 mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
158
│ │ │ │ +
159 Weight vWeight = 0.75f;
│ │ │ │ +
160 Weight eWeight = 0.125f;
│ │ │ │ +
161
│ │ │ │ +
162 mask.VertexWeight(0) = vWeight;
│ │ │ │ +
163 for (int i = 0; i < valence; ++i) {
│ │ │ │ +
164 mask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
165 }
│ │ │ │ +
166 mask.EdgeWeight(creaseEnds[0]) = eWeight;
│ │ │ │ +
167 mask.EdgeWeight(creaseEnds[1]) = eWeight;
│ │ │ │ +
168}
│ │ │ │ +
│ │ │ │ +
169
│ │ │ │ +
170template <>
│ │ │ │ +
171template <typename VERTEX, typename MASK>
│ │ │ │ +
172inline void
│ │ │ │ +
│ │ │ │ +
173Scheme<SCHEME_CATMARK>::assignSmoothMaskForVertex(VERTEX const& vertex, MASK& mask) const {
│ │ │ │ +
174
│ │ │ │ +
175 typedef typename MASK::Weight Weight;
│ │ │ │
176
│ │ │ │ -
177protected:
│ │ │ │ -
178 float decrementSharpness(float sharpness) const;
│ │ │ │ -
179
│ │ │ │ -
180private:
│ │ │ │ -
181 Options _options;
│ │ │ │ -
182};
│ │ │ │ -
│ │ │ │ +
177 //
│ │ │ │ +
178 // A Smooth vertex must be manifold and interior -- manifold boundary vertices will be
│ │ │ │ +
179 // Creases and non-manifold vertices of any kind will be Corners or Creases. If smooth
│ │ │ │ +
180 // rules for non-manifold vertices are ever defined, this will need adjusting:
│ │ │ │ +
181 //
│ │ │ │ +
182 assert(vertex.GetNumFaces() == vertex.GetNumEdges());
│ │ │ │
183
│ │ │ │ -
184
│ │ │ │ -
185//
│ │ │ │ -
186// Inline declarations:
│ │ │ │ -
187//
│ │ │ │ -
188inline float
│ │ │ │ -
│ │ │ │ -
189Crease::SharpenBoundaryEdge(float /* edgeSharpness */) const {
│ │ │ │ +
184 int valence = vertex.GetNumFaces();
│ │ │ │ +
185
│ │ │ │ +
186 mask.SetNumVertexWeights(1);
│ │ │ │ +
187 mask.SetNumEdgeWeights(valence);
│ │ │ │ +
188 mask.SetNumFaceWeights(valence);
│ │ │ │ +
189 mask.SetFaceWeightsForFaceCenters(true);
│ │ │ │
190
│ │ │ │ -
191 //
│ │ │ │ -
192 // Despite the presence of the BOUNDARY_NONE option, boundary edges are always sharpened.
│ │ │ │ -
193 // Much of the code relies on sharpness to indicate boundaries to avoid the more complex
│ │ │ │ -
194 // topological inspection
│ │ │ │ -
195 //
│ │ │ │ -
196 return SHARPNESS_INFINITE;
│ │ │ │ -
197}
│ │ │ │ -
│ │ │ │ -
198
│ │ │ │ -
199inline float
│ │ │ │ -
│ │ │ │ -
200Crease::SharpenBoundaryVertex(float vertexSharpness) const {
│ │ │ │ -
201
│ │ │ │ - │ │ │ │ -
203 SHARPNESS_INFINITE : vertexSharpness;
│ │ │ │ -
204}
│ │ │ │ -
│ │ │ │ -
205
│ │ │ │ -
206inline float
│ │ │ │ -
│ │ │ │ -
207Crease::decrementSharpness(float sharpness) const {
│ │ │ │ -
208
│ │ │ │ -
209 if (IsSmooth(sharpness)) return Crease::SHARPNESS_SMOOTH; // redundant but most common
│ │ │ │ -
210 if (IsInfinite(sharpness)) return Crease::SHARPNESS_INFINITE;
│ │ │ │ -
211 if (sharpness > 1.0f) return (sharpness - 1.0f);
│ │ │ │ - │ │ │ │ -
213}
│ │ │ │ +
191 Weight vWeight = (Weight)(valence - 2) / (Weight)valence;
│ │ │ │ +
192 Weight fWeight = 1.0f / (Weight)(valence * valence);
│ │ │ │ +
193 Weight eWeight = fWeight;
│ │ │ │ +
194
│ │ │ │ +
195 mask.VertexWeight(0) = vWeight;
│ │ │ │ +
196 for (int i = 0; i < valence; ++i) {
│ │ │ │ +
197 mask.EdgeWeight(i) = eWeight;
│ │ │ │ +
198 mask.FaceWeight(i) = fWeight;
│ │ │ │ +
199 }
│ │ │ │ +
200}
│ │ │ │
│ │ │ │ +
201
│ │ │ │ +
202//
│ │ │ │ +
203// Limit masks for position:
│ │ │ │ +
204//
│ │ │ │ +
205template <>
│ │ │ │ +
206template <typename VERTEX, typename MASK>
│ │ │ │ +
207inline void
│ │ │ │ +
│ │ │ │ +
208Scheme<SCHEME_CATMARK>::assignCornerLimitMask(VERTEX const& /* vertex */, MASK& posMask) const {
│ │ │ │ +
209
│ │ │ │ +
210 posMask.SetNumVertexWeights(1);
│ │ │ │ +
211 posMask.SetNumEdgeWeights(0);
│ │ │ │ +
212 posMask.SetNumFaceWeights(0);
│ │ │ │ +
213 posMask.SetFaceWeightsForFaceCenters(false);
│ │ │ │
214
│ │ │ │ -
215inline float
│ │ │ │ -
│ │ │ │ -
216Crease::SubdivideUniformSharpness(float vertexOrEdgeSharpness) const {
│ │ │ │ -
217
│ │ │ │ -
218 return decrementSharpness(vertexOrEdgeSharpness);
│ │ │ │ -
219}
│ │ │ │ +
215 posMask.VertexWeight(0) = 1.0f;
│ │ │ │ +
216}
│ │ │ │
│ │ │ │ -
220
│ │ │ │ -
221inline float
│ │ │ │ -
│ │ │ │ -
222Crease::SubdivideVertexSharpness(float vertexSharpness) const {
│ │ │ │ +
217
│ │ │ │ +
218template <>
│ │ │ │ +
219template <typename VERTEX, typename MASK>
│ │ │ │ +
220inline void
│ │ │ │ +
│ │ │ │ +
221Scheme<SCHEME_CATMARK>::assignCreaseLimitMask(VERTEX const& vertex, MASK& posMask,
│ │ │ │ +
222 int const creaseEnds[2]) const {
│ │ │ │
223
│ │ │ │ -
224 return decrementSharpness(vertexSharpness);
│ │ │ │ -
225}
│ │ │ │ -
│ │ │ │ -
226
│ │ │ │ -
227inline void
│ │ │ │ -
│ │ │ │ -
228Crease::GetSharpEdgePairOfCrease(float const * incidentEdgeSharpness, int incidentEdgeCount,
│ │ │ │ -
229 int sharpEdgePair[2]) const {
│ │ │ │ -
230
│ │ │ │ -
231 // Only to be called when a crease is present at a vertex -- exactly two sharp
│ │ │ │ -
232 // edges are expected here:
│ │ │ │ -
233 //
│ │ │ │ -
234 sharpEdgePair[0] = 0;
│ │ │ │ -
235 while (IsSmooth(incidentEdgeSharpness[sharpEdgePair[0]])) ++ sharpEdgePair[0];
│ │ │ │ -
236
│ │ │ │ -
237 sharpEdgePair[1] = incidentEdgeCount - 1;
│ │ │ │ -
238 while (IsSmooth(incidentEdgeSharpness[sharpEdgePair[1]])) -- sharpEdgePair[1];
│ │ │ │ -
239}
│ │ │ │ -
│ │ │ │ -
240
│ │ │ │ -
241} // end namespace sdc
│ │ │ │ -
242
│ │ │ │ -
243} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
244using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
245} // end namespace OpenSubdiv
│ │ │ │ -
246
│ │ │ │ -
247#endif /* OPENSUBDIV3_SDC_CREASE_H */
│ │ │ │ +
224 typedef typename MASK::Weight Weight;
│ │ │ │ +
225
│ │ │ │ +
226 int valence = vertex.GetNumEdges();
│ │ │ │ +
227
│ │ │ │ +
228 posMask.SetNumVertexWeights(1);
│ │ │ │ +
229 posMask.SetNumEdgeWeights(valence);
│ │ │ │ +
230 posMask.SetNumFaceWeights(0);
│ │ │ │ +
231 posMask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
232
│ │ │ │ +
233 Weight vWeight = (Weight)(2.0 / 3.0);
│ │ │ │ +
234 Weight eWeight = (Weight)(1.0 / 6.0);
│ │ │ │ +
235
│ │ │ │ +
236 posMask.VertexWeight(0) = vWeight;
│ │ │ │ +
237 for (int i = 0; i < valence; ++i) {
│ │ │ │ +
238 posMask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
239 }
│ │ │ │ +
240 posMask.EdgeWeight(creaseEnds[0]) = eWeight;
│ │ │ │ +
241 posMask.EdgeWeight(creaseEnds[1]) = eWeight;
│ │ │ │ +
242}
│ │ │ │ +
│ │ │ │ +
243
│ │ │ │ +
244template <>
│ │ │ │ +
245template <typename VERTEX, typename MASK>
│ │ │ │ +
246inline void
│ │ │ │ +
│ │ │ │ +
247Scheme<SCHEME_CATMARK>::assignSmoothLimitMask(VERTEX const& vertex, MASK& posMask) const {
│ │ │ │ +
248
│ │ │ │ +
249 typedef typename MASK::Weight Weight;
│ │ │ │ +
250
│ │ │ │ +
251 int valence = vertex.GetNumFaces();
│ │ │ │ +
252 if (valence == 2) {
│ │ │ │ +
253 assignCornerLimitMask(vertex, posMask);
│ │ │ │ +
254 return;
│ │ │ │ +
255 }
│ │ │ │ +
256
│ │ │ │ +
257 posMask.SetNumVertexWeights(1);
│ │ │ │ +
258 posMask.SetNumEdgeWeights(valence);
│ │ │ │ +
259 posMask.SetNumFaceWeights(valence);
│ │ │ │ +
260 posMask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
261
│ │ │ │ +
262 // Specialize for the regular case:
│ │ │ │ +
263 if (valence == 4) {
│ │ │ │ +
264 Weight fWeight = (Weight)(1.0 / 36.0);
│ │ │ │ +
265 Weight eWeight = (Weight)(1.0 / 9.0);
│ │ │ │ +
266 Weight vWeight = (Weight)(4.0 / 9.0);
│ │ │ │ +
267
│ │ │ │ +
268 posMask.VertexWeight(0) = vWeight;
│ │ │ │ +
269
│ │ │ │ +
270 posMask.EdgeWeight(0) = eWeight;
│ │ │ │ +
271 posMask.EdgeWeight(1) = eWeight;
│ │ │ │ +
272 posMask.EdgeWeight(2) = eWeight;
│ │ │ │ +
273 posMask.EdgeWeight(3) = eWeight;
│ │ │ │ +
274
│ │ │ │ +
275 posMask.FaceWeight(0) = fWeight;
│ │ │ │ +
276 posMask.FaceWeight(1) = fWeight;
│ │ │ │ +
277 posMask.FaceWeight(2) = fWeight;
│ │ │ │ +
278 posMask.FaceWeight(3) = fWeight;
│ │ │ │ +
279 } else {
│ │ │ │ +
280 Weight Valence = (Weight) valence;
│ │ │ │ +
281
│ │ │ │ +
282 Weight fWeight = 1.0f / (Valence * (Valence + 5.0f));
│ │ │ │ +
283 Weight eWeight = 4.0f * fWeight;
│ │ │ │ +
284 Weight vWeight = 1.0f - Valence * (eWeight + fWeight);
│ │ │ │ +
285
│ │ │ │ +
286 posMask.VertexWeight(0) = vWeight;
│ │ │ │ +
287 for (int i = 0; i < valence; ++i) {
│ │ │ │ +
288 posMask.EdgeWeight(i) = eWeight;
│ │ │ │ +
289 posMask.FaceWeight(i) = fWeight;
│ │ │ │ +
290 }
│ │ │ │ +
291 }
│ │ │ │ +
292}
│ │ │ │ +
│ │ │ │ +
293
│ │ │ │ +
294//
│ │ │ │ +
295// Limit masks for tangents -- these are stubs for now, or have a temporary
│ │ │ │ +
296// implementation
│ │ │ │ +
297//
│ │ │ │ +
298template <>
│ │ │ │ +
299template <typename VERTEX, typename MASK>
│ │ │ │ +
300inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
302 MASK& tan1Mask, MASK& tan2Mask) const {
│ │ │ │ +
303
│ │ │ │ +
304 int valence = vertex.GetNumEdges();
│ │ │ │ +
305
│ │ │ │ +
306 tan1Mask.SetNumVertexWeights(1);
│ │ │ │ +
307 tan1Mask.SetNumEdgeWeights(valence);
│ │ │ │ +
308 tan1Mask.SetNumFaceWeights(0);
│ │ │ │ +
309 tan1Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
310
│ │ │ │ +
311 tan2Mask.SetNumVertexWeights(1);
│ │ │ │ +
312 tan2Mask.SetNumEdgeWeights(valence);
│ │ │ │ +
313 tan2Mask.SetNumFaceWeights(0);
│ │ │ │ +
314 tan2Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
315
│ │ │ │ +
316 // Should be at least 2 edges -- be sure to clear weights for any more:
│ │ │ │ +
317 tan1Mask.VertexWeight(0) = -1.0f;
│ │ │ │ +
318 tan1Mask.EdgeWeight(0) = 1.0f;
│ │ │ │ +
319 tan1Mask.EdgeWeight(1) = 0.0f;
│ │ │ │ +
320
│ │ │ │ +
321 tan2Mask.VertexWeight(0) = -1.0f;
│ │ │ │ +
322 tan2Mask.EdgeWeight(0) = 0.0f;
│ │ │ │ +
323 tan2Mask.EdgeWeight(1) = 1.0f;
│ │ │ │ +
324
│ │ │ │ +
325 for (int i = 2; i < valence; ++i) {
│ │ │ │ +
326 tan1Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
327 tan2Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
328 }
│ │ │ │ +
329}
│ │ │ │ +
│ │ │ │ +
330
│ │ │ │ +
331template <>
│ │ │ │ +
332template <typename VERTEX, typename MASK>
│ │ │ │ +
333inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
335 MASK& tan1Mask, MASK& tan2Mask, int const creaseEnds[2]) const {
│ │ │ │ +
336
│ │ │ │ +
337 typedef typename MASK::Weight Weight;
│ │ │ │ +
338
│ │ │ │ +
339 //
│ │ │ │ +
340 // First, the tangent along the crease:
│ │ │ │ +
341 // The first crease edge is considered the "leading" edge of the span
│ │ │ │ +
342 // of surface for which we are evaluating tangents and the second edge the
│ │ │ │ +
343 // "trailing edge". By convention, the tangent along the crease is oriented
│ │ │ │ +
344 // in the direction of the leading edge.
│ │ │ │ +
345 //
│ │ │ │ +
346 int numEdges = vertex.GetNumEdges();
│ │ │ │ +
347 int numFaces = vertex.GetNumFaces();
│ │ │ │ +
348
│ │ │ │ +
349 tan1Mask.SetNumVertexWeights(1);
│ │ │ │ +
350 tan1Mask.SetNumEdgeWeights(numEdges);
│ │ │ │ +
351 tan1Mask.SetNumFaceWeights(numFaces);
│ │ │ │ +
352 tan1Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
353
│ │ │ │ +
354 tan1Mask.VertexWeight(0) = 0.0f;
│ │ │ │ +
355 for (int i = 0; i < numEdges; ++i) {
│ │ │ │ +
356 tan1Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
357 }
│ │ │ │ +
358 for (int i = 0; i < numFaces; ++i) {
│ │ │ │ +
359 tan1Mask.FaceWeight(i) = 0.0f;
│ │ │ │ +
360 }
│ │ │ │ +
361
│ │ │ │ +
362 tan1Mask.EdgeWeight(creaseEnds[0]) = 0.5f;
│ │ │ │ +
363 tan1Mask.EdgeWeight(creaseEnds[1]) = -0.5f;
│ │ │ │ +
364
│ │ │ │ +
365 //
│ │ │ │ +
366 // Second, the tangent across the interior faces:
│ │ │ │ +
367 // Note this is ambiguous for an interior vertex. We currently return
│ │ │ │ +
368 // the tangent for the surface in the counter-clockwise span between the
│ │ │ │ +
369 // leading and trailing edges that form the crease. Given the expected
│ │ │ │ +
370 // computation of a surface normal as Tan1 X Tan2, this tangent should be
│ │ │ │ +
371 // oriented "inward" from the crease/boundary -- across the surface rather
│ │ │ │ +
372 // than outward and away from it.
│ │ │ │ +
373 //
│ │ │ │ +
374 tan2Mask.SetNumVertexWeights(1);
│ │ │ │ +
375 tan2Mask.SetNumEdgeWeights(numEdges);
│ │ │ │ +
376 tan2Mask.SetNumFaceWeights(numFaces);
│ │ │ │ +
377 tan2Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
378
│ │ │ │ +
379 // Prepend weights of 0 preceding the crease:
│ │ │ │ +
380 for (int i = 0; i < creaseEnds[0]; ++i) {
│ │ │ │ +
381 tan2Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
382 tan2Mask.FaceWeight(i) = 0.0f;
│ │ │ │ +
383 }
│ │ │ │ +
384
│ │ │ │ +
385 // Assign weights to crease edge and interior points:
│ │ │ │ +
386 int interiorEdgeCount = creaseEnds[1] - creaseEnds[0] - 1;
│ │ │ │ +
387 if (interiorEdgeCount == 1) {
│ │ │ │ +
388 // The regular case -- uniform B-spline cross-tangent:
│ │ │ │ +
389
│ │ │ │ +
390 tan2Mask.VertexWeight(0) = (Weight)(-4.0 / 6.0);
│ │ │ │ +
391
│ │ │ │ +
392 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight)(-1.0 / 6.0);
│ │ │ │ +
393 tan2Mask.EdgeWeight(creaseEnds[0] + 1) = (Weight)( 4.0 / 6.0);
│ │ │ │ +
394 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight)(-1.0 / 6.0);
│ │ │ │ +
395
│ │ │ │ +
396 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight)(1.0 / 6.0);
│ │ │ │ +
397 tan2Mask.FaceWeight(creaseEnds[0] + 1) = (Weight)(1.0 / 6.0);
│ │ │ │ +
398 } else if (interiorEdgeCount > 1) {
│ │ │ │ +
399 // The irregular case -- formulae from Biermann et al:
│ │ │ │ +
400
│ │ │ │ +
401 double k = (double) (interiorEdgeCount + 1);
│ │ │ │ +
402 double theta = M_PI / k;
│ │ │ │ +
403
│ │ │ │ +
404 double cosTheta = std::cos(theta);
│ │ │ │ +
405 double sinTheta = std::sin(theta);
│ │ │ │ +
406
│ │ │ │ +
407 // Loop/Schaefer use a different divisor here (3*k + cos(theta)):
│ │ │ │ +
408 double commonDenom = 1.0f / (k * (3.0f + cosTheta));
│ │ │ │ +
409 double R = (cosTheta + 1.0f) / sinTheta;
│ │ │ │ +
410
│ │ │ │ +
411 double vertexWeight = 4.0f * R * (cosTheta - 1.0f);
│ │ │ │ +
412 double creaseWeight = -R * (1.0f + 2.0f * cosTheta);
│ │ │ │ +
413
│ │ │ │ +
414 tan2Mask.VertexWeight(0) = (Weight) (vertexWeight * commonDenom);
│ │ │ │ +
415
│ │ │ │ +
416 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight) (creaseWeight * commonDenom);
│ │ │ │ +
417 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight) (creaseWeight * commonDenom);
│ │ │ │ +
418
│ │ │ │ +
419 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight) (sinTheta * commonDenom);
│ │ │ │ +
420
│ │ │ │ +
421 double sinThetaI = 0.0f;
│ │ │ │ +
422 double sinThetaIplus1 = sinTheta;
│ │ │ │ +
423 for (int i = 1; i < k; ++i) {
│ │ │ │ +
424 sinThetaI = sinThetaIplus1;
│ │ │ │ +
425 sinThetaIplus1 = std::sin((i+1)*theta);
│ │ │ │ +
426
│ │ │ │ +
427 tan2Mask.EdgeWeight(creaseEnds[0] + i) = (Weight) ((4.0f * sinThetaI) * commonDenom);
│ │ │ │ +
428 tan2Mask.FaceWeight(creaseEnds[0] + i) = (Weight) ((sinThetaI + sinThetaIplus1) * commonDenom);
│ │ │ │ +
429 }
│ │ │ │ +
430 } else {
│ │ │ │ +
431 // Special case for a single face -- simple average of boundary edges:
│ │ │ │ +
432
│ │ │ │ +
433 tan2Mask.VertexWeight(0) = -6.0f;
│ │ │ │ +
434
│ │ │ │ +
435 tan2Mask.EdgeWeight(creaseEnds[0]) = 3.0f;
│ │ │ │ +
436 tan2Mask.EdgeWeight(creaseEnds[1]) = 3.0f;
│ │ │ │ +
437
│ │ │ │ +
438 tan2Mask.FaceWeight(creaseEnds[0]) = 0.0f;
│ │ │ │ +
439 }
│ │ │ │ +
440
│ │ │ │ +
441 // Append weights of 0 following the crease:
│ │ │ │ +
442 for (int i = creaseEnds[1]; i < numFaces; ++i) {
│ │ │ │ +
443 tan2Mask.FaceWeight(i) = 0.0f;
│ │ │ │ +
444 }
│ │ │ │ +
445 for (int i = creaseEnds[1] + 1; i < numEdges; ++i) {
│ │ │ │ +
446 tan2Mask.EdgeWeight(i) = 0.0f;
│ │ │ │ +
447 }
│ │ │ │ +
448}
│ │ │ │ +
│ │ │ │ +
449
│ │ │ │ +
450template <>
│ │ │ │ +
451template <typename VERTEX, typename MASK>
│ │ │ │ +
452inline void
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
454 MASK& tan1Mask, MASK& tan2Mask) const {
│ │ │ │ +
455
│ │ │ │ +
456 typedef typename MASK::Weight Weight;
│ │ │ │ +
457
│ │ │ │ +
458 int valence = vertex.GetNumFaces();
│ │ │ │ +
459 if (valence == 2) {
│ │ │ │ +
460 assignCornerLimitTangentMasks(vertex, tan1Mask, tan2Mask);
│ │ │ │ +
461 return;
│ │ │ │ +
462 }
│ │ │ │ +
463
│ │ │ │ +
464 // Compute tan1 initially -- tan2 is simply a rotation:
│ │ │ │ +
465 tan1Mask.SetNumVertexWeights(1);
│ │ │ │ +
466 tan1Mask.SetNumEdgeWeights(valence);
│ │ │ │ +
467 tan1Mask.SetNumFaceWeights(valence);
│ │ │ │ +
468 tan1Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
469
│ │ │ │ +
470 tan1Mask.VertexWeight(0) = 0.0f;
│ │ │ │ +
471
│ │ │ │ +
472 if (valence == 4) {
│ │ │ │ +
473 tan1Mask.EdgeWeight(0) = 4.0f;
│ │ │ │ +
474 tan1Mask.EdgeWeight(1) = 0.0f;
│ │ │ │ +
475 tan1Mask.EdgeWeight(2) = -4.0f;
│ │ │ │ +
476 tan1Mask.EdgeWeight(3) = 0.0f;
│ │ │ │ +
477
│ │ │ │ +
478 tan1Mask.FaceWeight(0) = 1.0f;
│ │ │ │ +
479 tan1Mask.FaceWeight(1) = -1.0f;
│ │ │ │ +
480 tan1Mask.FaceWeight(2) = -1.0f;
│ │ │ │ +
481 tan1Mask.FaceWeight(3) = 1.0f;
│ │ │ │ +
482 } else {
│ │ │ │ +
483 double theta = 2.0f * M_PI / (double)valence;
│ │ │ │ +
484
│ │ │ │ +
485 double cosTheta = std::cos(theta);
│ │ │ │ +
486 double cosHalfTheta = std::cos(theta * 0.5f);
│ │ │ │ +
487
│ │ │ │ +
488 double lambda = (5.0 / 16.0) + (1.0 / 16.0) *
│ │ │ │ +
489 (cosTheta + cosHalfTheta * std::sqrt(2.0f * (9.0f + cosTheta)));
│ │ │ │ +
490
│ │ │ │ +
491 double edgeWeightScale = 4.0f;
│ │ │ │ +
492 double faceWeightScale = 1.0f / (4.0f * lambda - 1.0f);
│ │ │ │ +
493
│ │ │ │ +
494 for (int i = 0; i < valence; ++i) {
│ │ │ │ +
495 double cosThetaI = std::cos( i * theta);
│ │ │ │ +
496 double cosThetaIplus1 = std::cos((i+1)* theta);
│ │ │ │ +
497
│ │ │ │ +
498 tan1Mask.EdgeWeight(i) = (Weight) (edgeWeightScale * cosThetaI);
│ │ │ │ +
499 tan1Mask.FaceWeight(i) = (Weight) (faceWeightScale * (cosThetaI + cosThetaIplus1));
│ │ │ │ +
500 }
│ │ │ │ +
501 }
│ │ │ │ +
502
│ │ │ │ +
503 // Now rotate/copy tan1 weights to tan2:
│ │ │ │ +
504 tan2Mask.SetNumVertexWeights(1);
│ │ │ │ +
505 tan2Mask.SetNumEdgeWeights(valence);
│ │ │ │ +
506 tan2Mask.SetNumFaceWeights(valence);
│ │ │ │ +
507 tan2Mask.SetFaceWeightsForFaceCenters(false);
│ │ │ │ +
508
│ │ │ │ +
509 tan2Mask.VertexWeight(0) = 0.0f;
│ │ │ │ +
510 if (valence == 4) {
│ │ │ │ +
511 tan2Mask.EdgeWeight(0) = 0.0f;
│ │ │ │ +
512 tan2Mask.EdgeWeight(1) = 4.0f;
│ │ │ │ +
513 tan2Mask.EdgeWeight(2) = 0.0f;
│ │ │ │ +
514 tan2Mask.EdgeWeight(3) = -4.0f;
│ │ │ │ +
515
│ │ │ │ +
516 tan2Mask.FaceWeight(0) = 1.0f;
│ │ │ │ +
517 tan2Mask.FaceWeight(1) = 1.0f;
│ │ │ │ +
518 tan2Mask.FaceWeight(2) = -1.0f;
│ │ │ │ +
519 tan2Mask.FaceWeight(3) = -1.0f;
│ │ │ │ +
520 } else {
│ │ │ │ +
521 tan2Mask.EdgeWeight(0) = tan1Mask.EdgeWeight(valence-1);
│ │ │ │ +
522 tan2Mask.FaceWeight(0) = tan1Mask.FaceWeight(valence-1);
│ │ │ │ +
523 for (int i = 1; i < valence; ++i) {
│ │ │ │ +
524 tan2Mask.EdgeWeight(i) = tan1Mask.EdgeWeight(i-1);
│ │ │ │ +
525 tan2Mask.FaceWeight(i) = tan1Mask.FaceWeight(i-1);
│ │ │ │ +
526 }
│ │ │ │ +
527 }
│ │ │ │ +
528}
│ │ │ │ +
│ │ │ │ +
529
│ │ │ │ +
530} // end namespace sdc
│ │ │ │ +
531
│ │ │ │ +
532} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
533using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
534} // end namespace OpenSubdiv
│ │ │ │ +
535
│ │ │ │ +
536#endif /* OPENSUBDIV3_SDC_CATMARK_SCHEME_H */
│ │ │ │ │ │ │ │ -
Types, constants and utilities related to semi-sharp creasing – whose implementation is independent o...
Definition crease.h:62
│ │ │ │ -
float SubdivideVertexSharpness(float vertexSharpness) const
Definition crease.h:222
│ │ │ │ -
static bool IsInfinite(float sharpness)
Definition crease.h:72
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
float SharpenBoundaryVertex(float edgeSharpness) const
Definition crease.h:200
│ │ │ │ - │ │ │ │ -
void GetSharpEdgePairOfCrease(float const *incidentEdgeSharpness, int incidentEdgeCount, int sharpEdgePair[2]) const
Definition crease.h:228
│ │ │ │ - │ │ │ │ -
Rule DetermineVertexVertexRule(float vertexSharpness, int incidentEdgeCount, float const *incidentEdgeSharpness) const
│ │ │ │ -
float decrementSharpness(float sharpness) const
Definition crease.h:207
│ │ │ │ -
static bool IsSmooth(float sharpness)
Definition crease.h:70
│ │ │ │ -
Rule DetermineVertexVertexRule(float vertexSharpness, int sharpEdgeCount) const
│ │ │ │ - │ │ │ │ -
static bool IsSemiSharp(float sharpness)
Definition crease.h:73
│ │ │ │ - │ │ │ │ -
void SubdivideEdgeSharpnessesAroundVertex(int incidentEdgeCountAtVertex, float const *incidentEdgeSharpnessAroundVertex, float *childEdgesSharpnessAroundVertex) const
│ │ │ │ -
float SubdivideUniformSharpness(float vertexOrEdgeSharpness) const
Definition crease.h:216
│ │ │ │ - │ │ │ │ -
float SharpenBoundaryEdge(float edgeSharpness) const
Definition crease.h:189
│ │ │ │ -
float ComputeFractionalWeightAtVertex(float vertexSharpness, float childVertexSharpness, int incidentEdgeCount, float const *incidentEdgeSharpness, float const *childEdgesSharpness) const
Transitional weighting: When the rules applicable to a parent vertex and its child differ,...
│ │ │ │ -
float SubdivideEdgeSharpnessAtVertex(float edgeSharpness, int incidentEdgeCountAtEndVertex, float const *edgeSharpnessAroundEndVertex) const
│ │ │ │ -
static bool IsSharp(float sharpness)
Definition crease.h:71
│ │ │ │ - │ │ │ │ -
All supported options applying to subdivision scheme.
Definition options.h:51
│ │ │ │ - │ │ │ │ -
CreasingMethod GetCreasingMethod() const
Get edge crease rule.
Definition options.h:101
│ │ │ │ -
VtxBoundaryInterpolation GetVtxBoundaryInterpolation() const
Get vertex boundary interpolation rule.
Definition options.h:89
│ │ │ │ - │ │ │ │ +
Split
Enumerated type for all face splitting schemes.
Definition types.h:47
│ │ │ │ +
@ SPLIT_TO_QUADS
Used by Catmark and Bilinear.
Definition types.h:48
│ │ │ │ +
@ TRI_SUB_SMOOTH
"smooth triangle" weights (Catmark scheme only)
Definition options.h:74
│ │ │ │ +
void assignSmoothMaskForEdge(EDGE const &edge, MASK &mask) const
│ │ │ │ + │ │ │ │ +
void assignCreaseMaskForVertex(VERTEX const &edge, MASK &mask, int const creaseEnds[2]) const
│ │ │ │ +
void assignCreaseLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2, int const creaseEnds[2]) const
│ │ │ │ + │ │ │ │ +
void assignSmoothLimitMask(VERTEX const &vertex, MASK &pos) const
│ │ │ │ + │ │ │ │ +
void assignCreaseLimitMask(VERTEX const &vertex, MASK &pos, int const creaseEnds[2]) const
│ │ │ │ +
void assignSmoothMaskForVertex(VERTEX const &edge, MASK &mask) const
│ │ │ │ + │ │ │ │ +
void assignSmoothLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2) const
│ │ │ │ +
void assignCornerLimitMask(VERTEX const &vertex, MASK &pos) const
│ │ │ │ +
void assignCornerLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2) const
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── encoding │ │ │ │ │ @@ -1 +1 @@ │ │ │ │ │ -utf-8 │ │ │ │ │ +us-ascii │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -crease.h │ │ │ │ │ +catmarkScheme.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2014 DreamWorks Animation LLC. │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -23,289 +23,592 @@ │ │ │ │ │ 17// │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ -24#ifndef OPENSUBDIV3_SDC_CREASE_H │ │ │ │ │ -25#define OPENSUBDIV3_SDC_CREASE_H │ │ │ │ │ +24#ifndef OPENSUBDIV3_SDC_CATMARK_SCHEME_H │ │ │ │ │ +25#define OPENSUBDIV3_SDC_CATMARK_SCHEME_H │ │ │ │ │ 26 │ │ │ │ │ 27#include "../version.h" │ │ │ │ │ 28 │ │ │ │ │ -29#include "../sdc/options.h" │ │ │ │ │ +29#include "../sdc/scheme.h" │ │ │ │ │ 30 │ │ │ │ │ -31namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -32namespace OPENSUBDIV_VERSION { │ │ │ │ │ +31#include │ │ │ │ │ +32#include │ │ │ │ │ 33 │ │ │ │ │ -34namespace Sdc { │ │ │ │ │ -35 │ │ │ │ │ -61 │ │ │ │ │ -_6_2class _C_r_e_a_s_e { │ │ │ │ │ -63public: │ │ │ │ │ -65 │ │ │ │ │ -_6_7 static float const _S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; // = 0.0f, do we really need this? │ │ │ │ │ -_6_8 static float const _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; // = 10.0f; │ │ │ │ │ -69 │ │ │ │ │ -_7_0 static bool _I_s_S_m_o_o_t_h(float sharpness) { return sharpness <= │ │ │ │ │ -_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; } │ │ │ │ │ -_7_1 static bool _I_s_S_h_a_r_p(float sharpness) { return sharpness > _S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; │ │ │ │ │ -} │ │ │ │ │ -_7_2 static bool _I_s_I_n_f_i_n_i_t_e(float sharpness) { return sharpness >= │ │ │ │ │ -_S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; } │ │ │ │ │ -_7_3 static bool _I_s_S_e_m_i_S_h_a_r_p(float sharpness) { return (_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H < │ │ │ │ │ -sharpness) && (sharpness < _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E); } │ │ │ │ │ -75 │ │ │ │ │ -_8_2 enum _R_u_l_e { │ │ │ │ │ -_8_3 _R_U_L_E___U_N_K_N_O_W_N = 0, │ │ │ │ │ -_8_4 _R_U_L_E___S_M_O_O_T_H = (1 << 0), │ │ │ │ │ -_8_5 _R_U_L_E___D_A_R_T = (1 << 1), │ │ │ │ │ -_8_6 _R_U_L_E___C_R_E_A_S_E = (1 << 2), │ │ │ │ │ -87 _R_U_L_E___C_O_R_N_E_R = (1 << 3) │ │ │ │ │ -_8_8 }; │ │ │ │ │ -89 │ │ │ │ │ -90public: │ │ │ │ │ -_9_1 _C_r_e_a_s_e() : _options() { } │ │ │ │ │ -_9_2 _C_r_e_a_s_e(_O_p_t_i_o_n_s const& options) : _options(options) { } │ │ │ │ │ -_9_3 _~_C_r_e_a_s_e() { } │ │ │ │ │ -94 │ │ │ │ │ -_9_5 bool _I_s_U_n_i_f_o_r_m() const { return _options._G_e_t_C_r_e_a_s_i_n_g_M_e_t_h_o_d() == _O_p_t_i_o_n_s_:_: │ │ │ │ │ -_C_R_E_A_S_E___U_N_I_F_O_R_M; } │ │ │ │ │ -96 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Sdc { │ │ │ │ │ +38 │ │ │ │ │ +39// │ │ │ │ │ +40// Specializations for Scheme: │ │ │ │ │ +41// │ │ │ │ │ +42 │ │ │ │ │ +43// │ │ │ │ │ +44// Catmark traits: │ │ │ │ │ +45// │ │ │ │ │ +46template <> │ │ │ │ │ +_4_7inline _S_p_l_i_t _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_T_o_p_o_l_o_g_i_c_a_l_S_p_l_i_t_T_y_p_e() { return │ │ │ │ │ +_S_P_L_I_T___T_O___Q_U_A_D_S; } │ │ │ │ │ +48 │ │ │ │ │ +49template <> │ │ │ │ │ +_5_0inline int _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_R_e_g_u_l_a_r_F_a_c_e_S_i_z_e() { return 4; } │ │ │ │ │ +51 │ │ │ │ │ +52template <> │ │ │ │ │ +_5_3inline int _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_R_e_g_u_l_a_r_V_e_r_t_e_x_V_a_l_e_n_c_e() { return 4; } │ │ │ │ │ +54 │ │ │ │ │ +55template <> │ │ │ │ │ +_5_6inline int _S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_G_e_t_L_o_c_a_l_N_e_i_g_h_b_o_r_h_o_o_d_S_i_z_e() { return 1; } │ │ │ │ │ +57 │ │ │ │ │ +58 │ │ │ │ │ +59// │ │ │ │ │ +60// Masks for edge-vertices: the hard Crease mask does not need to be │ │ │ │ │ +specialized │ │ │ │ │ +61// (simply the midpoint), so all that is left is the Smooth case: │ │ │ │ │ +62// │ │ │ │ │ +63// The Smooth mask is complicated by the need to support the "triangle │ │ │ │ │ +subdivision" │ │ │ │ │ +64// option, which applies different weighting in the presence of triangles. It │ │ │ │ │ +is │ │ │ │ │ +65// up for debate as to whether this is useful or not -- we may be able to │ │ │ │ │ +deprecate │ │ │ │ │ +66// this option. │ │ │ │ │ +67// │ │ │ │ │ +68template <> │ │ │ │ │ +69template │ │ │ │ │ +70inline void │ │ │ │ │ +_7_1_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_E_d_g_e(EDGE const& edge, MASK& mask) │ │ │ │ │ +const { │ │ │ │ │ +72 │ │ │ │ │ +73 typedef typename MASK::Weight Weight; │ │ │ │ │ +74 │ │ │ │ │ +75 int faceCount = edge.GetNumFaces(); │ │ │ │ │ +76 │ │ │ │ │ +77 mask.SetNumVertexWeights(2); │ │ │ │ │ +78 mask.SetNumEdgeWeights(0); │ │ │ │ │ +79 mask.SetNumFaceWeights(faceCount); │ │ │ │ │ +80 mask.SetFaceWeightsForFaceCenters(true); │ │ │ │ │ +81 │ │ │ │ │ +82 // │ │ │ │ │ +83 // Determine if we need to inspect incident faces and apply alternate │ │ │ │ │ +weighting for │ │ │ │ │ +84 // triangles -- and if so, determine which of the two are triangles. │ │ │ │ │ +85 // │ │ │ │ │ +86 bool face0IsTri = false; │ │ │ │ │ +87 bool face1IsTri = false; │ │ │ │ │ +88 bool useTriangleOption = (_options.GetTriangleSubdivision() == _O_p_t_i_o_n_s_:_: │ │ │ │ │ +_T_R_I___S_U_B___S_M_O_O_T_H); │ │ │ │ │ +89 if (useTriangleOption) { │ │ │ │ │ +90 if (faceCount == 2) { │ │ │ │ │ +91 // │ │ │ │ │ +92 // Ideally we want to avoid this inspection when we have already subdivided │ │ │ │ │ +at │ │ │ │ │ +93 // least once -- need something in the Edge interface to help avoid this, │ │ │ │ │ +e.g. │ │ │ │ │ +94 // an IsRegular() query, the subdivision level... │ │ │ │ │ +95 // │ │ │ │ │ +96 int vertsPerFace[2]; │ │ │ │ │ +97 edge.GetNumVerticesPerFace(vertsPerFace); │ │ │ │ │ 98 │ │ │ │ │ -104 float _S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_E_d_g_e(float edgeSharpness) const; │ │ │ │ │ -105 float _S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_V_e_r_t_e_x(float edgeSharpness) const; │ │ │ │ │ +99 face0IsTri = (vertsPerFace[0] == 3); │ │ │ │ │ +100 face1IsTri = (vertsPerFace[1] == 3); │ │ │ │ │ +101 useTriangleOption = face0IsTri || face1IsTri; │ │ │ │ │ +102 } else { │ │ │ │ │ +103 useTriangleOption = false; │ │ │ │ │ +104 } │ │ │ │ │ +105 } │ │ │ │ │ 106 │ │ │ │ │ -107 // For future consideration │ │ │ │ │ -108 //float SharpenNonManifoldEdge(float edgeSharpness) const; │ │ │ │ │ -109 //float SharpenNonManifoldVertex(float edgeSharpness) const; │ │ │ │ │ -111 │ │ │ │ │ -113 │ │ │ │ │ -124 float _S_u_b_d_i_v_i_d_e_U_n_i_f_o_r_m_S_h_a_r_p_n_e_s_s(float vertexOrEdgeSharpness) const; │ │ │ │ │ +107 if (! useTriangleOption) { │ │ │ │ │ +108 mask.VertexWeight(0) = 0.25f; │ │ │ │ │ +109 mask.VertexWeight(1) = 0.25f; │ │ │ │ │ +110 │ │ │ │ │ +111 if (faceCount == 2) { │ │ │ │ │ +112 mask.FaceWeight(0) = 0.25f; │ │ │ │ │ +113 mask.FaceWeight(1) = 0.25f; │ │ │ │ │ +114 } else { │ │ │ │ │ +115 Weight fWeight = 0.5f / (Weight)faceCount; │ │ │ │ │ +116 for (int i = 0; i < faceCount; ++i) { │ │ │ │ │ +117 mask.FaceWeight(i) = fWeight; │ │ │ │ │ +118 } │ │ │ │ │ +119 } │ │ │ │ │ +120 } else { │ │ │ │ │ +121 // │ │ │ │ │ +122 // This mimics the implementation in Hbr in terms of order of operations. │ │ │ │ │ +123 // │ │ │ │ │ +124 const Weight CATMARK_SMOOTH_TRI_EDGE_WEIGHT = (Weight) 0.470; │ │ │ │ │ 125 │ │ │ │ │ -126 float _S_u_b_d_i_v_i_d_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float vertexSharpness) const; │ │ │ │ │ -127 │ │ │ │ │ -_1_2_8 float _S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_A_t_V_e_r_t_e_x(float edgeSharpness, │ │ │ │ │ -129 int incidentEdgeCountAtEndVertex, │ │ │ │ │ -130 float const* edgeSharpnessAroundEndVertex) const; │ │ │ │ │ +126 Weight f0Weight = face0IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f; │ │ │ │ │ +127 Weight f1Weight = face1IsTri ? CATMARK_SMOOTH_TRI_EDGE_WEIGHT : 0.25f; │ │ │ │ │ +128 │ │ │ │ │ +129 Weight fWeight = 0.5f * (f0Weight + f1Weight); │ │ │ │ │ +130 Weight vWeight = 0.5f * (1.0f - 2.0f * fWeight); │ │ │ │ │ 131 │ │ │ │ │ -_1_3_2 void _S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_e_s_A_r_o_u_n_d_V_e_r_t_e_x(int incidentEdgeCountAtVertex, │ │ │ │ │ -133 float const* incidentEdgeSharpnessAroundVertex, │ │ │ │ │ -134 float* childEdgesSharpnessAroundVertex) const; │ │ │ │ │ -136 │ │ │ │ │ -138 │ │ │ │ │ -_1_4_4 _R_u_l_e _D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e(float vertexSharpness, │ │ │ │ │ -145 int incidentEdgeCount, │ │ │ │ │ -146 float const* incidentEdgeSharpness) const; │ │ │ │ │ -_1_4_7 _R_u_l_e _D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e(float vertexSharpness, │ │ │ │ │ -148 int sharpEdgeCount) const; │ │ │ │ │ -150 │ │ │ │ │ -_1_6_2 float _C_o_m_p_u_t_e_F_r_a_c_t_i_o_n_a_l_W_e_i_g_h_t_A_t_V_e_r_t_e_x(float vertexSharpness, │ │ │ │ │ -163 float childVertexSharpness, │ │ │ │ │ -164 int incidentEdgeCount, │ │ │ │ │ -165 float const* incidentEdgeSharpness, │ │ │ │ │ -166 float const* childEdgesSharpness) const; │ │ │ │ │ -167 │ │ │ │ │ -168 void _G_e_t_S_h_a_r_p_E_d_g_e_P_a_i_r_O_f_C_r_e_a_s_e(float const * incidentEdgeSharpness, │ │ │ │ │ -169 int incidentEdgeCount, │ │ │ │ │ -170 int sharpEdgePair[2]) const; │ │ │ │ │ -171 │ │ │ │ │ -172 // Would these really help? Maybe only need Rules for the vertex-vertex │ │ │ │ │ -case... │ │ │ │ │ -173 // │ │ │ │ │ -174 // Rule DetermineEdgeVertexRule(float parentEdgeSharpness) const; │ │ │ │ │ -175 // Rule DetermineEdgeVertexRule(float childEdge1Sharpness, float │ │ │ │ │ -childEdge2Sharpness) const; │ │ │ │ │ +132 mask.VertexWeight(0) = vWeight; │ │ │ │ │ +133 mask.VertexWeight(1) = vWeight; │ │ │ │ │ +134 │ │ │ │ │ +135 mask.FaceWeight(0) = fWeight; │ │ │ │ │ +136 mask.FaceWeight(1) = fWeight; │ │ │ │ │ +137 } │ │ │ │ │ +138} │ │ │ │ │ +139 │ │ │ │ │ +140 │ │ │ │ │ +141// │ │ │ │ │ +142// Masks for vertex-vertices: the hard Corner mask does not need to be │ │ │ │ │ +specialized │ │ │ │ │ +143// (simply the vertex itself), leaving the Crease and Smooth cases (Dart is │ │ │ │ │ +smooth): │ │ │ │ │ +144// │ │ │ │ │ +145template <> │ │ │ │ │ +146template │ │ │ │ │ +147inline void │ │ │ │ │ +_1_4_8_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_r_e_a_s_e_M_a_s_k_F_o_r_V_e_r_t_e_x(VERTEX const& vertex, │ │ │ │ │ +MASK& mask, │ │ │ │ │ +149 int const creaseEnds[2]) const { │ │ │ │ │ +150 typedef typename MASK::Weight Weight; │ │ │ │ │ +151 │ │ │ │ │ +152 int valence = vertex.GetNumEdges(); │ │ │ │ │ +153 │ │ │ │ │ +154 mask.SetNumVertexWeights(1); │ │ │ │ │ +155 mask.SetNumEdgeWeights(valence); │ │ │ │ │ +156 mask.SetNumFaceWeights(0); │ │ │ │ │ +157 mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +158 │ │ │ │ │ +159 Weight vWeight = 0.75f; │ │ │ │ │ +160 Weight eWeight = 0.125f; │ │ │ │ │ +161 │ │ │ │ │ +162 mask.VertexWeight(0) = vWeight; │ │ │ │ │ +163 for (int i = 0; i < valence; ++i) { │ │ │ │ │ +164 mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +165 } │ │ │ │ │ +166 mask.EdgeWeight(creaseEnds[0]) = eWeight; │ │ │ │ │ +167 mask.EdgeWeight(creaseEnds[1]) = eWeight; │ │ │ │ │ +168} │ │ │ │ │ +169 │ │ │ │ │ +170template <> │ │ │ │ │ +171template │ │ │ │ │ +172inline void │ │ │ │ │ +_1_7_3_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_V_e_r_t_e_x(VERTEX const& vertex, │ │ │ │ │ +MASK& mask) const { │ │ │ │ │ +174 │ │ │ │ │ +175 typedef typename MASK::Weight Weight; │ │ │ │ │ 176 │ │ │ │ │ -177protected: │ │ │ │ │ -178 float _d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(float sharpness) const; │ │ │ │ │ -179 │ │ │ │ │ -180private: │ │ │ │ │ -181 _O_p_t_i_o_n_s _options; │ │ │ │ │ -182}; │ │ │ │ │ +177 // │ │ │ │ │ +178 // A Smooth vertex must be manifold and interior -- manifold boundary │ │ │ │ │ +vertices will be │ │ │ │ │ +179 // Creases and non-manifold vertices of any kind will be Corners or │ │ │ │ │ +Creases. If smooth │ │ │ │ │ +180 // rules for non-manifold vertices are ever defined, this will need │ │ │ │ │ +adjusting: │ │ │ │ │ +181 // │ │ │ │ │ +182 assert(vertex.GetNumFaces() == vertex.GetNumEdges()); │ │ │ │ │ 183 │ │ │ │ │ -184 │ │ │ │ │ -185// │ │ │ │ │ -186// Inline declarations: │ │ │ │ │ -187// │ │ │ │ │ -188inline float │ │ │ │ │ -_1_8_9_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_E_d_g_e(float /* edgeSharpness */) const { │ │ │ │ │ +184 int valence = vertex.GetNumFaces(); │ │ │ │ │ +185 │ │ │ │ │ +186 mask.SetNumVertexWeights(1); │ │ │ │ │ +187 mask.SetNumEdgeWeights(valence); │ │ │ │ │ +188 mask.SetNumFaceWeights(valence); │ │ │ │ │ +189 mask.SetFaceWeightsForFaceCenters(true); │ │ │ │ │ 190 │ │ │ │ │ -191 // │ │ │ │ │ -192 // Despite the presence of the BOUNDARY_NONE option, boundary edges are │ │ │ │ │ -always sharpened. │ │ │ │ │ -193 // Much of the code relies on sharpness to indicate boundaries to avoid the │ │ │ │ │ -more complex │ │ │ │ │ -194 // topological inspection │ │ │ │ │ -195 // │ │ │ │ │ -196 return _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; │ │ │ │ │ -197} │ │ │ │ │ -198 │ │ │ │ │ -199inline float │ │ │ │ │ -_2_0_0_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_V_e_r_t_e_x(float vertexSharpness) const { │ │ │ │ │ +191 Weight vWeight = (Weight)(valence - 2) / (Weight)valence; │ │ │ │ │ +192 Weight fWeight = 1.0f / (Weight)(valence * valence); │ │ │ │ │ +193 Weight eWeight = fWeight; │ │ │ │ │ +194 │ │ │ │ │ +195 mask.VertexWeight(0) = vWeight; │ │ │ │ │ +196 for (int i = 0; i < valence; ++i) { │ │ │ │ │ +197 mask.EdgeWeight(i) = eWeight; │ │ │ │ │ +198 mask.FaceWeight(i) = fWeight; │ │ │ │ │ +199 } │ │ │ │ │ +200} │ │ │ │ │ 201 │ │ │ │ │ -202 return (_options._G_e_t_V_t_x_B_o_u_n_d_a_r_y_I_n_t_e_r_p_o_l_a_t_i_o_n() == _O_p_t_i_o_n_s_:_: │ │ │ │ │ -_V_T_X___B_O_U_N_D_A_R_Y___E_D_G_E___A_N_D___C_O_R_N_E_R) ? │ │ │ │ │ -203 _S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E : vertexSharpness; │ │ │ │ │ -204} │ │ │ │ │ -205 │ │ │ │ │ -206inline float │ │ │ │ │ -_2_0_7_C_r_e_a_s_e_:_:_d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(float sharpness) const { │ │ │ │ │ -208 │ │ │ │ │ -209 if (_I_s_S_m_o_o_t_h(sharpness)) return _C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; // redundant but │ │ │ │ │ -most common │ │ │ │ │ -210 if (_I_s_I_n_f_i_n_i_t_e(sharpness)) return _C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E; │ │ │ │ │ -211 if (sharpness > 1.0f) return (sharpness - 1.0f); │ │ │ │ │ -212 return _C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H; │ │ │ │ │ -213} │ │ │ │ │ +202// │ │ │ │ │ +203// Limit masks for position: │ │ │ │ │ +204// │ │ │ │ │ +205template <> │ │ │ │ │ +206template │ │ │ │ │ +207inline void │ │ │ │ │ +_2_0_8_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_M_a_s_k(VERTEX const& /* vertex */, │ │ │ │ │ +MASK& posMask) const { │ │ │ │ │ +209 │ │ │ │ │ +210 posMask.SetNumVertexWeights(1); │ │ │ │ │ +211 posMask.SetNumEdgeWeights(0); │ │ │ │ │ +212 posMask.SetNumFaceWeights(0); │ │ │ │ │ +213 posMask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ 214 │ │ │ │ │ -215inline float │ │ │ │ │ -_2_1_6_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_U_n_i_f_o_r_m_S_h_a_r_p_n_e_s_s(float vertexOrEdgeSharpness) const { │ │ │ │ │ +215 posMask.VertexWeight(0) = 1.0f; │ │ │ │ │ +216} │ │ │ │ │ 217 │ │ │ │ │ -218 return _d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(vertexOrEdgeSharpness); │ │ │ │ │ -219} │ │ │ │ │ -220 │ │ │ │ │ -221inline float │ │ │ │ │ -_2_2_2_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s(float vertexSharpness) const { │ │ │ │ │ +218template <> │ │ │ │ │ +219template │ │ │ │ │ +220inline void │ │ │ │ │ +_2_2_1_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_M_a_s_k(VERTEX const& vertex, MASK& │ │ │ │ │ +posMask, │ │ │ │ │ +222 int const creaseEnds[2]) const { │ │ │ │ │ 223 │ │ │ │ │ -224 return _d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s(vertexSharpness); │ │ │ │ │ -225} │ │ │ │ │ -226 │ │ │ │ │ -227inline void │ │ │ │ │ -_2_2_8_C_r_e_a_s_e_:_:_G_e_t_S_h_a_r_p_E_d_g_e_P_a_i_r_O_f_C_r_e_a_s_e(float const * incidentEdgeSharpness, int │ │ │ │ │ -incidentEdgeCount, │ │ │ │ │ -229 int sharpEdgePair[2]) const { │ │ │ │ │ -230 │ │ │ │ │ -231 // Only to be called when a crease is present at a vertex -- exactly two │ │ │ │ │ -sharp │ │ │ │ │ -232 // edges are expected here: │ │ │ │ │ -233 // │ │ │ │ │ -234 sharpEdgePair[0] = 0; │ │ │ │ │ -235 while (_I_s_S_m_o_o_t_h(incidentEdgeSharpness[sharpEdgePair[0]])) ++ sharpEdgePair │ │ │ │ │ -[0]; │ │ │ │ │ -236 │ │ │ │ │ -237 sharpEdgePair[1] = incidentEdgeCount - 1; │ │ │ │ │ -238 while (_I_s_S_m_o_o_t_h(incidentEdgeSharpness[sharpEdgePair[1]])) -- sharpEdgePair │ │ │ │ │ -[1]; │ │ │ │ │ -239} │ │ │ │ │ -240 │ │ │ │ │ -241} // end namespace sdc │ │ │ │ │ -242 │ │ │ │ │ -243} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -244using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -245} // end namespace OpenSubdiv │ │ │ │ │ -246 │ │ │ │ │ -247#endif /* OPENSUBDIV3_SDC_CREASE_H */ │ │ │ │ │ +224 typedef typename MASK::Weight Weight; │ │ │ │ │ +225 │ │ │ │ │ +226 int valence = vertex.GetNumEdges(); │ │ │ │ │ +227 │ │ │ │ │ +228 posMask.SetNumVertexWeights(1); │ │ │ │ │ +229 posMask.SetNumEdgeWeights(valence); │ │ │ │ │ +230 posMask.SetNumFaceWeights(0); │ │ │ │ │ +231 posMask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +232 │ │ │ │ │ +233 Weight vWeight = (Weight)(2.0 / 3.0); │ │ │ │ │ +234 Weight eWeight = (Weight)(1.0 / 6.0); │ │ │ │ │ +235 │ │ │ │ │ +236 posMask.VertexWeight(0) = vWeight; │ │ │ │ │ +237 for (int i = 0; i < valence; ++i) { │ │ │ │ │ +238 posMask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +239 } │ │ │ │ │ +240 posMask.EdgeWeight(creaseEnds[0]) = eWeight; │ │ │ │ │ +241 posMask.EdgeWeight(creaseEnds[1]) = eWeight; │ │ │ │ │ +242} │ │ │ │ │ +243 │ │ │ │ │ +244template <> │ │ │ │ │ +245template │ │ │ │ │ +246inline void │ │ │ │ │ +_2_4_7_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_M_a_s_k(VERTEX const& vertex, MASK& │ │ │ │ │ +posMask) const { │ │ │ │ │ +248 │ │ │ │ │ +249 typedef typename MASK::Weight Weight; │ │ │ │ │ +250 │ │ │ │ │ +251 int valence = vertex.GetNumFaces(); │ │ │ │ │ +252 if (valence == 2) { │ │ │ │ │ +253 assignCornerLimitMask(vertex, posMask); │ │ │ │ │ +254 return; │ │ │ │ │ +255 } │ │ │ │ │ +256 │ │ │ │ │ +257 posMask.SetNumVertexWeights(1); │ │ │ │ │ +258 posMask.SetNumEdgeWeights(valence); │ │ │ │ │ +259 posMask.SetNumFaceWeights(valence); │ │ │ │ │ +260 posMask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +261 │ │ │ │ │ +262 // Specialize for the regular case: │ │ │ │ │ +263 if (valence == 4) { │ │ │ │ │ +264 Weight fWeight = (Weight)(1.0 / 36.0); │ │ │ │ │ +265 Weight eWeight = (Weight)(1.0 / 9.0); │ │ │ │ │ +266 Weight vWeight = (Weight)(4.0 / 9.0); │ │ │ │ │ +267 │ │ │ │ │ +268 posMask.VertexWeight(0) = vWeight; │ │ │ │ │ +269 │ │ │ │ │ +270 posMask.EdgeWeight(0) = eWeight; │ │ │ │ │ +271 posMask.EdgeWeight(1) = eWeight; │ │ │ │ │ +272 posMask.EdgeWeight(2) = eWeight; │ │ │ │ │ +273 posMask.EdgeWeight(3) = eWeight; │ │ │ │ │ +274 │ │ │ │ │ +275 posMask.FaceWeight(0) = fWeight; │ │ │ │ │ +276 posMask.FaceWeight(1) = fWeight; │ │ │ │ │ +277 posMask.FaceWeight(2) = fWeight; │ │ │ │ │ +278 posMask.FaceWeight(3) = fWeight; │ │ │ │ │ +279 } else { │ │ │ │ │ +280 Weight Valence = (Weight) valence; │ │ │ │ │ +281 │ │ │ │ │ +282 Weight fWeight = 1.0f / (Valence * (Valence + 5.0f)); │ │ │ │ │ +283 Weight eWeight = 4.0f * fWeight; │ │ │ │ │ +284 Weight vWeight = 1.0f - Valence * (eWeight + fWeight); │ │ │ │ │ +285 │ │ │ │ │ +286 posMask.VertexWeight(0) = vWeight; │ │ │ │ │ +287 for (int i = 0; i < valence; ++i) { │ │ │ │ │ +288 posMask.EdgeWeight(i) = eWeight; │ │ │ │ │ +289 posMask.FaceWeight(i) = fWeight; │ │ │ │ │ +290 } │ │ │ │ │ +291 } │ │ │ │ │ +292} │ │ │ │ │ +293 │ │ │ │ │ +294// │ │ │ │ │ +295// Limit masks for tangents -- these are stubs for now, or have a temporary │ │ │ │ │ +296// implementation │ │ │ │ │ +297// │ │ │ │ │ +298template <> │ │ │ │ │ +299template │ │ │ │ │ +300inline void │ │ │ │ │ +_3_0_1_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s(VERTEX const& vertex, │ │ │ │ │ +302 MASK& tan1Mask, MASK& tan2Mask) const { │ │ │ │ │ +303 │ │ │ │ │ +304 int valence = vertex.GetNumEdges(); │ │ │ │ │ +305 │ │ │ │ │ +306 tan1Mask.SetNumVertexWeights(1); │ │ │ │ │ +307 tan1Mask.SetNumEdgeWeights(valence); │ │ │ │ │ +308 tan1Mask.SetNumFaceWeights(0); │ │ │ │ │ +309 tan1Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +310 │ │ │ │ │ +311 tan2Mask.SetNumVertexWeights(1); │ │ │ │ │ +312 tan2Mask.SetNumEdgeWeights(valence); │ │ │ │ │ +313 tan2Mask.SetNumFaceWeights(0); │ │ │ │ │ +314 tan2Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +315 │ │ │ │ │ +316 // Should be at least 2 edges -- be sure to clear weights for any more: │ │ │ │ │ +317 tan1Mask.VertexWeight(0) = -1.0f; │ │ │ │ │ +318 tan1Mask.EdgeWeight(0) = 1.0f; │ │ │ │ │ +319 tan1Mask.EdgeWeight(1) = 0.0f; │ │ │ │ │ +320 │ │ │ │ │ +321 tan2Mask.VertexWeight(0) = -1.0f; │ │ │ │ │ +322 tan2Mask.EdgeWeight(0) = 0.0f; │ │ │ │ │ +323 tan2Mask.EdgeWeight(1) = 1.0f; │ │ │ │ │ +324 │ │ │ │ │ +325 for (int i = 2; i < valence; ++i) { │ │ │ │ │ +326 tan1Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +327 tan2Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +328 } │ │ │ │ │ +329} │ │ │ │ │ +330 │ │ │ │ │ +331template <> │ │ │ │ │ +332template │ │ │ │ │ +333inline void │ │ │ │ │ +_3_3_4_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s(VERTEX const& vertex, │ │ │ │ │ +335 MASK& tan1Mask, MASK& tan2Mask, int const creaseEnds[2]) const { │ │ │ │ │ +336 │ │ │ │ │ +337 typedef typename MASK::Weight Weight; │ │ │ │ │ +338 │ │ │ │ │ +339 // │ │ │ │ │ +340 // First, the tangent along the crease: │ │ │ │ │ +341 // The first crease edge is considered the "leading" edge of the span │ │ │ │ │ +342 // of surface for which we are evaluating tangents and the second edge the │ │ │ │ │ +343 // "trailing edge". By convention, the tangent along the crease is oriented │ │ │ │ │ +344 // in the direction of the leading edge. │ │ │ │ │ +345 // │ │ │ │ │ +346 int numEdges = vertex.GetNumEdges(); │ │ │ │ │ +347 int numFaces = vertex.GetNumFaces(); │ │ │ │ │ +348 │ │ │ │ │ +349 tan1Mask.SetNumVertexWeights(1); │ │ │ │ │ +350 tan1Mask.SetNumEdgeWeights(numEdges); │ │ │ │ │ +351 tan1Mask.SetNumFaceWeights(numFaces); │ │ │ │ │ +352 tan1Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +353 │ │ │ │ │ +354 tan1Mask.VertexWeight(0) = 0.0f; │ │ │ │ │ +355 for (int i = 0; i < numEdges; ++i) { │ │ │ │ │ +356 tan1Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +357 } │ │ │ │ │ +358 for (int i = 0; i < numFaces; ++i) { │ │ │ │ │ +359 tan1Mask.FaceWeight(i) = 0.0f; │ │ │ │ │ +360 } │ │ │ │ │ +361 │ │ │ │ │ +362 tan1Mask.EdgeWeight(creaseEnds[0]) = 0.5f; │ │ │ │ │ +363 tan1Mask.EdgeWeight(creaseEnds[1]) = -0.5f; │ │ │ │ │ +364 │ │ │ │ │ +365 // │ │ │ │ │ +366 // Second, the tangent across the interior faces: │ │ │ │ │ +367 // Note this is ambiguous for an interior vertex. We currently return │ │ │ │ │ +368 // the tangent for the surface in the counter-clockwise span between the │ │ │ │ │ +369 // leading and trailing edges that form the crease. Given the expected │ │ │ │ │ +370 // computation of a surface normal as Tan1 X Tan2, this tangent should be │ │ │ │ │ +371 // oriented "inward" from the crease/boundary -- across the surface rather │ │ │ │ │ +372 // than outward and away from it. │ │ │ │ │ +373 // │ │ │ │ │ +374 tan2Mask.SetNumVertexWeights(1); │ │ │ │ │ +375 tan2Mask.SetNumEdgeWeights(numEdges); │ │ │ │ │ +376 tan2Mask.SetNumFaceWeights(numFaces); │ │ │ │ │ +377 tan2Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +378 │ │ │ │ │ +379 // Prepend weights of 0 preceding the crease: │ │ │ │ │ +380 for (int i = 0; i < creaseEnds[0]; ++i) { │ │ │ │ │ +381 tan2Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +382 tan2Mask.FaceWeight(i) = 0.0f; │ │ │ │ │ +383 } │ │ │ │ │ +384 │ │ │ │ │ +385 // Assign weights to crease edge and interior points: │ │ │ │ │ +386 int interiorEdgeCount = creaseEnds[1] - creaseEnds[0] - 1; │ │ │ │ │ +387 if (interiorEdgeCount == 1) { │ │ │ │ │ +388 // The regular case -- uniform B-spline cross-tangent: │ │ │ │ │ +389 │ │ │ │ │ +390 tan2Mask.VertexWeight(0) = (Weight)(-4.0 / 6.0); │ │ │ │ │ +391 │ │ │ │ │ +392 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight)(-1.0 / 6.0); │ │ │ │ │ +393 tan2Mask.EdgeWeight(creaseEnds[0] + 1) = (Weight)( 4.0 / 6.0); │ │ │ │ │ +394 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight)(-1.0 / 6.0); │ │ │ │ │ +395 │ │ │ │ │ +396 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight)(1.0 / 6.0); │ │ │ │ │ +397 tan2Mask.FaceWeight(creaseEnds[0] + 1) = (Weight)(1.0 / 6.0); │ │ │ │ │ +398 } else if (interiorEdgeCount > 1) { │ │ │ │ │ +399 // The irregular case -- formulae from Biermann et al: │ │ │ │ │ +400 │ │ │ │ │ +401 double k = (double) (interiorEdgeCount + 1); │ │ │ │ │ +402 double theta = M_PI / k; │ │ │ │ │ +403 │ │ │ │ │ +404 double cosTheta = std::cos(theta); │ │ │ │ │ +405 double sinTheta = std::sin(theta); │ │ │ │ │ +406 │ │ │ │ │ +407 // Loop/Schaefer use a different divisor here (3*k + cos(theta)): │ │ │ │ │ +408 double commonDenom = 1.0f / (k * (3.0f + cosTheta)); │ │ │ │ │ +409 double R = (cosTheta + 1.0f) / sinTheta; │ │ │ │ │ +410 │ │ │ │ │ +411 double vertexWeight = 4.0f * R * (cosTheta - 1.0f); │ │ │ │ │ +412 double creaseWeight = -R * (1.0f + 2.0f * cosTheta); │ │ │ │ │ +413 │ │ │ │ │ +414 tan2Mask.VertexWeight(0) = (Weight) (vertexWeight * commonDenom); │ │ │ │ │ +415 │ │ │ │ │ +416 tan2Mask.EdgeWeight(creaseEnds[0]) = (Weight) (creaseWeight * commonDenom); │ │ │ │ │ +417 tan2Mask.EdgeWeight(creaseEnds[1]) = (Weight) (creaseWeight * commonDenom); │ │ │ │ │ +418 │ │ │ │ │ +419 tan2Mask.FaceWeight(creaseEnds[0]) = (Weight) (sinTheta * commonDenom); │ │ │ │ │ +420 │ │ │ │ │ +421 double sinThetaI = 0.0f; │ │ │ │ │ +422 double sinThetaIplus1 = sinTheta; │ │ │ │ │ +423 for (int i = 1; i < k; ++i) { │ │ │ │ │ +424 sinThetaI = sinThetaIplus1; │ │ │ │ │ +425 sinThetaIplus1 = std::sin((i+1)*theta); │ │ │ │ │ +426 │ │ │ │ │ +427 tan2Mask.EdgeWeight(creaseEnds[0] + i) = (Weight) ((4.0f * sinThetaI) * │ │ │ │ │ +commonDenom); │ │ │ │ │ +428 tan2Mask.FaceWeight(creaseEnds[0] + i) = (Weight) ((sinThetaI + │ │ │ │ │ +sinThetaIplus1) * commonDenom); │ │ │ │ │ +429 } │ │ │ │ │ +430 } else { │ │ │ │ │ +431 // Special case for a single face -- simple average of boundary edges: │ │ │ │ │ +432 │ │ │ │ │ +433 tan2Mask.VertexWeight(0) = -6.0f; │ │ │ │ │ +434 │ │ │ │ │ +435 tan2Mask.EdgeWeight(creaseEnds[0]) = 3.0f; │ │ │ │ │ +436 tan2Mask.EdgeWeight(creaseEnds[1]) = 3.0f; │ │ │ │ │ +437 │ │ │ │ │ +438 tan2Mask.FaceWeight(creaseEnds[0]) = 0.0f; │ │ │ │ │ +439 } │ │ │ │ │ +440 │ │ │ │ │ +441 // Append weights of 0 following the crease: │ │ │ │ │ +442 for (int i = creaseEnds[1]; i < numFaces; ++i) { │ │ │ │ │ +443 tan2Mask.FaceWeight(i) = 0.0f; │ │ │ │ │ +444 } │ │ │ │ │ +445 for (int i = creaseEnds[1] + 1; i < numEdges; ++i) { │ │ │ │ │ +446 tan2Mask.EdgeWeight(i) = 0.0f; │ │ │ │ │ +447 } │ │ │ │ │ +448} │ │ │ │ │ +449 │ │ │ │ │ +450template <> │ │ │ │ │ +451template │ │ │ │ │ +452inline void │ │ │ │ │ +_4_5_3_S_c_h_e_m_e_<_S_C_H_E_M_E___C_A_T_M_A_R_K_>_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s(VERTEX const& vertex, │ │ │ │ │ +454 MASK& tan1Mask, MASK& tan2Mask) const { │ │ │ │ │ +455 │ │ │ │ │ +456 typedef typename MASK::Weight Weight; │ │ │ │ │ +457 │ │ │ │ │ +458 int valence = vertex.GetNumFaces(); │ │ │ │ │ +459 if (valence == 2) { │ │ │ │ │ +460 assignCornerLimitTangentMasks(vertex, tan1Mask, tan2Mask); │ │ │ │ │ +461 return; │ │ │ │ │ +462 } │ │ │ │ │ +463 │ │ │ │ │ +464 // Compute tan1 initially -- tan2 is simply a rotation: │ │ │ │ │ +465 tan1Mask.SetNumVertexWeights(1); │ │ │ │ │ +466 tan1Mask.SetNumEdgeWeights(valence); │ │ │ │ │ +467 tan1Mask.SetNumFaceWeights(valence); │ │ │ │ │ +468 tan1Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +469 │ │ │ │ │ +470 tan1Mask.VertexWeight(0) = 0.0f; │ │ │ │ │ +471 │ │ │ │ │ +472 if (valence == 4) { │ │ │ │ │ +473 tan1Mask.EdgeWeight(0) = 4.0f; │ │ │ │ │ +474 tan1Mask.EdgeWeight(1) = 0.0f; │ │ │ │ │ +475 tan1Mask.EdgeWeight(2) = -4.0f; │ │ │ │ │ +476 tan1Mask.EdgeWeight(3) = 0.0f; │ │ │ │ │ +477 │ │ │ │ │ +478 tan1Mask.FaceWeight(0) = 1.0f; │ │ │ │ │ +479 tan1Mask.FaceWeight(1) = -1.0f; │ │ │ │ │ +480 tan1Mask.FaceWeight(2) = -1.0f; │ │ │ │ │ +481 tan1Mask.FaceWeight(3) = 1.0f; │ │ │ │ │ +482 } else { │ │ │ │ │ +483 double theta = 2.0f * M_PI / (double)valence; │ │ │ │ │ +484 │ │ │ │ │ +485 double cosTheta = std::cos(theta); │ │ │ │ │ +486 double cosHalfTheta = std::cos(theta * 0.5f); │ │ │ │ │ +487 │ │ │ │ │ +488 double lambda = (5.0 / 16.0) + (1.0 / 16.0) * │ │ │ │ │ +489 (cosTheta + cosHalfTheta * std::sqrt(2.0f * (9.0f + cosTheta))); │ │ │ │ │ +490 │ │ │ │ │ +491 double edgeWeightScale = 4.0f; │ │ │ │ │ +492 double faceWeightScale = 1.0f / (4.0f * lambda - 1.0f); │ │ │ │ │ +493 │ │ │ │ │ +494 for (int i = 0; i < valence; ++i) { │ │ │ │ │ +495 double cosThetaI = std::cos( i * theta); │ │ │ │ │ +496 double cosThetaIplus1 = std::cos((i+1)* theta); │ │ │ │ │ +497 │ │ │ │ │ +498 tan1Mask.EdgeWeight(i) = (Weight) (edgeWeightScale * cosThetaI); │ │ │ │ │ +499 tan1Mask.FaceWeight(i) = (Weight) (faceWeightScale * (cosThetaI + │ │ │ │ │ +cosThetaIplus1)); │ │ │ │ │ +500 } │ │ │ │ │ +501 } │ │ │ │ │ +502 │ │ │ │ │ +503 // Now rotate/copy tan1 weights to tan2: │ │ │ │ │ +504 tan2Mask.SetNumVertexWeights(1); │ │ │ │ │ +505 tan2Mask.SetNumEdgeWeights(valence); │ │ │ │ │ +506 tan2Mask.SetNumFaceWeights(valence); │ │ │ │ │ +507 tan2Mask.SetFaceWeightsForFaceCenters(false); │ │ │ │ │ +508 │ │ │ │ │ +509 tan2Mask.VertexWeight(0) = 0.0f; │ │ │ │ │ +510 if (valence == 4) { │ │ │ │ │ +511 tan2Mask.EdgeWeight(0) = 0.0f; │ │ │ │ │ +512 tan2Mask.EdgeWeight(1) = 4.0f; │ │ │ │ │ +513 tan2Mask.EdgeWeight(2) = 0.0f; │ │ │ │ │ +514 tan2Mask.EdgeWeight(3) = -4.0f; │ │ │ │ │ +515 │ │ │ │ │ +516 tan2Mask.FaceWeight(0) = 1.0f; │ │ │ │ │ +517 tan2Mask.FaceWeight(1) = 1.0f; │ │ │ │ │ +518 tan2Mask.FaceWeight(2) = -1.0f; │ │ │ │ │ +519 tan2Mask.FaceWeight(3) = -1.0f; │ │ │ │ │ +520 } else { │ │ │ │ │ +521 tan2Mask.EdgeWeight(0) = tan1Mask.EdgeWeight(valence-1); │ │ │ │ │ +522 tan2Mask.FaceWeight(0) = tan1Mask.FaceWeight(valence-1); │ │ │ │ │ +523 for (int i = 1; i < valence; ++i) { │ │ │ │ │ +524 tan2Mask.EdgeWeight(i) = tan1Mask.EdgeWeight(i-1); │ │ │ │ │ +525 tan2Mask.FaceWeight(i) = tan1Mask.FaceWeight(i-1); │ │ │ │ │ +526 } │ │ │ │ │ +527 } │ │ │ │ │ +528} │ │ │ │ │ +529 │ │ │ │ │ +530} // end namespace sdc │ │ │ │ │ +531 │ │ │ │ │ +532} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +533using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +534} // end namespace OpenSubdiv │ │ │ │ │ +535 │ │ │ │ │ +536#endif /* OPENSUBDIV3_SDC_CATMARK_SCHEME_H */ │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e │ │ │ │ │ -Types, constants and utilities related to semi-sharp creasing – whose │ │ │ │ │ -implementation is independent o... │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_V_e_r_t_e_x_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float SubdivideVertexSharpness(float vertexSharpness) const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_2_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_I_n_f_i_n_i_t_e │ │ │ │ │ -static bool IsInfinite(float sharpness) │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_u_l_e │ │ │ │ │ -Rule │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_O_R_N_E_R │ │ │ │ │ -@ RULE_CORNER │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___D_A_R_T │ │ │ │ │ -@ RULE_DART │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___S_M_O_O_T_H │ │ │ │ │ -@ RULE_SMOOTH │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___C_R_E_A_S_E │ │ │ │ │ -@ RULE_CREASE │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_R_U_L_E___U_N_K_N_O_W_N │ │ │ │ │ -@ RULE_UNKNOWN │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_V_e_r_t_e_x │ │ │ │ │ -float SharpenBoundaryVertex(float edgeSharpness) const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___S_M_O_O_T_H │ │ │ │ │ -static float const SHARPNESS_SMOOTH │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_G_e_t_S_h_a_r_p_E_d_g_e_P_a_i_r_O_f_C_r_e_a_s_e │ │ │ │ │ -void GetSharpEdgePairOfCrease(float const *incidentEdgeSharpness, int │ │ │ │ │ -incidentEdgeCount, int sharpEdgePair[2]) const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_2_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_H_A_R_P_N_E_S_S___I_N_F_I_N_I_T_E │ │ │ │ │ -static float const SHARPNESS_INFINITE │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e │ │ │ │ │ -Rule DetermineVertexVertexRule(float vertexSharpness, int incidentEdgeCount, │ │ │ │ │ -float const *incidentEdgeSharpness) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_d_e_c_r_e_m_e_n_t_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float decrementSharpness(float sharpness) const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_0_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_S_m_o_o_t_h │ │ │ │ │ -static bool IsSmooth(float sharpness) │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_D_e_t_e_r_m_i_n_e_V_e_r_t_e_x_V_e_r_t_e_x_R_u_l_e │ │ │ │ │ -Rule DetermineVertexVertexRule(float vertexSharpness, int sharpEdgeCount) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_U_n_i_f_o_r_m │ │ │ │ │ -bool IsUniform() const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_S_e_m_i_S_h_a_r_p │ │ │ │ │ -static bool IsSemiSharp(float sharpness) │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_C_r_e_a_s_e │ │ │ │ │ -Crease(Options const &options) │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_: │ │ │ │ │ -_S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_e_s_A_r_o_u_n_d_V_e_r_t_e_x │ │ │ │ │ -void SubdivideEdgeSharpnessesAroundVertex(int incidentEdgeCountAtVertex, float │ │ │ │ │ -const *incidentEdgeSharpnessAroundVertex, float │ │ │ │ │ -*childEdgesSharpnessAroundVertex) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_U_n_i_f_o_r_m_S_h_a_r_p_n_e_s_s │ │ │ │ │ -float SubdivideUniformSharpness(float vertexOrEdgeSharpness) const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_2_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_C_r_e_a_s_e │ │ │ │ │ -Crease() │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_h_a_r_p_e_n_B_o_u_n_d_a_r_y_E_d_g_e │ │ │ │ │ -float SharpenBoundaryEdge(float edgeSharpness) const │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_1_8_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_C_o_m_p_u_t_e_F_r_a_c_t_i_o_n_a_l_W_e_i_g_h_t_A_t_V_e_r_t_e_x │ │ │ │ │ -float ComputeFractionalWeightAtVertex(float vertexSharpness, float │ │ │ │ │ -childVertexSharpness, int incidentEdgeCount, float const │ │ │ │ │ -*incidentEdgeSharpness, float const *childEdgesSharpness) const │ │ │ │ │ -Transitional weighting: When the rules applicable to a parent vertex and its │ │ │ │ │ -child differ,... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_S_u_b_d_i_v_i_d_e_E_d_g_e_S_h_a_r_p_n_e_s_s_A_t_V_e_r_t_e_x │ │ │ │ │ -float SubdivideEdgeSharpnessAtVertex(float edgeSharpness, int │ │ │ │ │ -incidentEdgeCountAtEndVertex, float const *edgeSharpnessAroundEndVertex) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_I_s_S_h_a_r_p │ │ │ │ │ -static bool IsSharp(float sharpness) │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_C_r_e_a_s_e_:_:_~_C_r_e_a_s_e │ │ │ │ │ -~Crease() │ │ │ │ │ -DDeeffiinniittiioonn _c_r_e_a_s_e_._h_:_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s │ │ │ │ │ -All supported options applying to subdivision scheme. │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_C_R_E_A_S_E___U_N_I_F_O_R_M │ │ │ │ │ -@ CREASE_UNIFORM │ │ │ │ │ -Catmark rule. │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_G_e_t_C_r_e_a_s_i_n_g_M_e_t_h_o_d │ │ │ │ │ -CreasingMethod GetCreasingMethod() const │ │ │ │ │ -Get edge crease rule. │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_1_0_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_G_e_t_V_t_x_B_o_u_n_d_a_r_y_I_n_t_e_r_p_o_l_a_t_i_o_n │ │ │ │ │ -VtxBoundaryInterpolation GetVtxBoundaryInterpolation() const │ │ │ │ │ -Get vertex boundary interpolation rule. │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_8_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_V_T_X___B_O_U_N_D_A_R_Y___E_D_G_E___A_N_D___C_O_R_N_E_R │ │ │ │ │ -@ VTX_BOUNDARY_EDGE_AND_CORNER │ │ │ │ │ -DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_5_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_p_l_i_t │ │ │ │ │ +Split │ │ │ │ │ +Enumerated type for all face splitting schemes. │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_P_L_I_T___T_O___Q_U_A_D_S │ │ │ │ │ +@ SPLIT_TO_QUADS │ │ │ │ │ +Used by Catmark and Bilinear. │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_O_p_t_i_o_n_s_:_:_T_R_I___S_U_B___S_M_O_O_T_H │ │ │ │ │ +@ TRI_SUB_SMOOTH │ │ │ │ │ +"smooth triangle" weights (Catmark scheme only) │ │ │ │ │ +DDeeffiinniittiioonn _o_p_t_i_o_n_s_._h_:_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_E_d_g_e │ │ │ │ │ +void assignSmoothMaskForEdge(EDGE const &edge, MASK &mask) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_T_o_p_o_l_o_g_i_c_a_l_S_p_l_i_t_T_y_p_e │ │ │ │ │ +static Split GetTopologicalSplitType() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_r_e_a_s_e_M_a_s_k_F_o_r_V_e_r_t_e_x │ │ │ │ │ +void assignCreaseMaskForVertex(VERTEX const &edge, MASK &mask, int const │ │ │ │ │ +creaseEnds[2]) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s │ │ │ │ │ +void assignCreaseLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK │ │ │ │ │ +&tan2, int const creaseEnds[2]) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_R_e_g_u_l_a_r_F_a_c_e_S_i_z_e │ │ │ │ │ +static int GetRegularFaceSize() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_M_a_s_k │ │ │ │ │ +void assignSmoothLimitMask(VERTEX const &vertex, MASK &pos) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_L_o_c_a_l_N_e_i_g_h_b_o_r_h_o_o_d_S_i_z_e │ │ │ │ │ +static int GetLocalNeighborhoodSize() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_r_e_a_s_e_L_i_m_i_t_M_a_s_k │ │ │ │ │ +void assignCreaseLimitMask(VERTEX const &vertex, MASK &pos, int const │ │ │ │ │ +creaseEnds[2]) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_M_a_s_k_F_o_r_V_e_r_t_e_x │ │ │ │ │ +void assignSmoothMaskForVertex(VERTEX const &edge, MASK &mask) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_G_e_t_R_e_g_u_l_a_r_V_e_r_t_e_x_V_a_l_e_n_c_e │ │ │ │ │ +static int GetRegularVertexValence() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_S_m_o_o_t_h_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s │ │ │ │ │ +void assignSmoothLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK │ │ │ │ │ +&tan2) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_M_a_s_k │ │ │ │ │ +void assignCornerLimitMask(VERTEX const &vertex, MASK &pos) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_S_d_c_:_:_S_c_h_e_m_e_:_:_a_s_s_i_g_n_C_o_r_n_e_r_L_i_m_i_t_T_a_n_g_e_n_t_M_a_s_k_s │ │ │ │ │ +void assignCornerLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK │ │ │ │ │ +&tan2) const │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _s_d_c │ │ │ │ │ - * _c_r_e_a_s_e_._h │ │ │ │ │ + * _c_a_t_m_a_r_k_S_c_h_e_m_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00785_source.html │ │ │ │ @@ -280,15 +280,15 @@ │ │ │ │
161using namespace OPENSUBDIV_VERSION;
│ │ │ │
162} // end namespace OpenSubdiv
│ │ │ │
163
│ │ │ │
164#endif /* OPENSUBDIV3_SDC_BILINEAR_SCHEME_H */
│ │ │ │ │ │ │ │
Split
Enumerated type for all face splitting schemes.
Definition types.h:47
│ │ │ │
@ SPLIT_TO_QUADS
Used by Catmark and Bilinear.
Definition types.h:48
│ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │
void ComputeVertexVertexMask(VERTEX const &vertexNeighborhood, MASK &vertexVertexMask, Crease::Rule parentRule=Crease::RULE_UNKNOWN, Crease::Rule childRule=Crease::RULE_UNKNOWN) const
Vertex-vertex masks If known, a single Rule or pair of Rules can be specified (indicating a crease tr...
Definition scheme.h:512
│ │ │ │
void assignCreaseLimitTangentMasks(VERTEX const &vertex, MASK &tan1, MASK &tan2, int const creaseEnds[2]) const
│ │ │ │ │ │ │ │
void ComputeEdgeVertexMask(EDGE const &edgeNeighborhood, MASK &edgeVertexMask, Crease::Rule parentRule=Crease::RULE_UNKNOWN, Crease::Rule childRule=Crease::RULE_UNKNOWN) const
Edge-vertex masks If known, the Rule for the edge and/or the derived vertex can be specified to accel...
Definition scheme.h:392
│ │ │ │
void assignSmoothLimitMask(VERTEX const &vertex, MASK &pos) const
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00788_source.html │ │ │ │ @@ -209,15 +209,15 @@ │ │ │ │
114} // end namespace OPENSUBDIV_VERSION
│ │ │ │
115using namespace OPENSUBDIV_VERSION;
│ │ │ │
116
│ │ │ │
117} // end namespace OpenSubdiv
│ │ │ │
118
│ │ │ │
119#endif // OPENSUBDIV3_OSD_CUDA_PATCH_TABLE_H
│ │ │ │ │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │
void * GetFVarPatchArrayBuffer(int fvarChannel) const
Returns the cuda memory of the array of Osd::PatchArray buffer.
│ │ │ │ │ │ │ │
static CudaPatchTable * Create(Far::PatchTable const *patchTable, void *deviceContext=NULL)
Creator. Returns NULL if error.
│ │ │ │ │ │ │ │
void * GetVaryingPatchIndexBuffer() const
Returns the cuda memory of the array of varying control vertices.
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00791.html │ │ │ │ @@ -95,15 +95,15 @@ │ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │
cudaEvaluator.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include <vector>
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00791_source.html │ │ │ │ @@ -641,17 +641,17 @@ │ │ │ │
1268using namespace OPENSUBDIV_VERSION;
│ │ │ │
1269
│ │ │ │
1270} // end namespace OpenSubdiv
│ │ │ │
1271
│ │ │ │
1272
│ │ │ │
1273#endif // OPENSUBDIV3_OSD_CUDA_EVALUATOR_H
│ │ │ │ │ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
CudaStencilTable(Far::LimitStencilTable const *limitStencilTable)
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00800_source.html │ │ │ │ @@ -201,15 +201,15 @@ │ │ │ │
114} // end namespace OPENSUBDIV_VERSION
│ │ │ │
115using namespace OPENSUBDIV_VERSION;
│ │ │ │
116
│ │ │ │
117} // end namespace OpenSubdiv
│ │ │ │
118
│ │ │ │
119#endif // OPENSUBDIV3_OSD_CL_PATCH_TABLE_H
│ │ │ │ │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
cl_mem GetPatchParamBuffer() const
Returns the CL memory of the array of Osd::PatchParam buffer.
│ │ │ │ │ │ │ │
cl_mem GetFVarPatchArrayBuffer(int fvarChannel=0) const
Returns the CL memory of the array of Osd::PatchArray buffer.
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00803.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/clEvaluator.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlCommon.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,47 +90,40 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
clEvaluator.h File Reference
│ │ │ │ +
mtlCommon.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/opencl.h"
│ │ │ │ -#include "../osd/types.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include <cstddef>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  CudaStencilTable
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  CLStencilTable
 OpenCL stencil table. More...
 
class  CLEvaluator
class  MTLContext
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,30 +1,23 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -clEvaluator.h File Reference │ │ │ │ │ +mtlCommon.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_o_p_e_n_c_l_._h" │ │ │ │ │ -#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ -#include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -  OpenCL stencil table. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -class   _C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ +class   _M_T_L_C_o_n_t_e_x_t │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ -namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │ -  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _c_l_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _m_t_l_C_o_m_m_o_n_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00803.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,3 @@ │ │ │ │ │ var a00803 = [ │ │ │ │ │ - ["CLStencilTable", "a01145.html", "a01145"], │ │ │ │ │ - ["CLEvaluator", "a01149.html", "a01149"] │ │ │ │ │ + ["MTLContext", "a01285.html", "a01285"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00803_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/clEvaluator.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlCommon.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
clEvaluator.h
│ │ │ │ +
mtlCommon.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2015 Pixar
│ │ │ │ +
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -119,1283 +119,53 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_CL_EVALUATOR_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_CL_EVALUATOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_MTL_COMMON_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_MTL_COMMON_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../osd/opencl.h"
│ │ │ │ -
31#include "../osd/types.h"
│ │ │ │ -
32#include "../osd/bufferDescriptor.h"
│ │ │ │ -
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Far {
│ │ │ │ -
38 class PatchTable;
│ │ │ │ -
39 class StencilTable;
│ │ │ │ -
40 class LimitStencilTable;
│ │ │ │ -
41}
│ │ │ │ -
42
│ │ │ │ -
43namespace Osd {
│ │ │ │ -
44
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
53public:
│ │ │ │ -
54 template <typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
55 static CLStencilTable *Create(Far::StencilTable const *stencilTable,
│ │ │ │ -
56 DEVICE_CONTEXT context) {
│ │ │ │ -
57 return new CLStencilTable(stencilTable, context->GetContext());
│ │ │ │ -
58 }
│ │ │ │ -
│ │ │ │ -
59
│ │ │ │ -
60 template <typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
62 Far::LimitStencilTable const *limitStencilTable,
│ │ │ │ -
63 DEVICE_CONTEXT context) {
│ │ │ │ -
64 return new CLStencilTable(limitStencilTable, context->GetContext());
│ │ │ │ -
65 }
│ │ │ │ -
│ │ │ │ -
66
│ │ │ │ -
67 CLStencilTable(Far::StencilTable const *stencilTable,
│ │ │ │ -
68 cl_context clContext);
│ │ │ │ -
69 CLStencilTable(Far::LimitStencilTable const *limitStencilTable,
│ │ │ │ -
70 cl_context clContext);
│ │ │ │ - │ │ │ │ -
72
│ │ │ │ -
73 // interfaces needed for CLComputeKernel
│ │ │ │ -
74 cl_mem GetSizesBuffer() const { return _sizes; }
│ │ │ │ -
75 cl_mem GetOffsetsBuffer() const { return _offsets; }
│ │ │ │ -
76 cl_mem GetIndicesBuffer() const { return _indices; }
│ │ │ │ -
77 cl_mem GetWeightsBuffer() const { return _weights; }
│ │ │ │ -
78 cl_mem GetDuWeightsBuffer() const { return _duWeights; }
│ │ │ │ -
79 cl_mem GetDvWeightsBuffer() const { return _dvWeights; }
│ │ │ │ -
80 cl_mem GetDuuWeightsBuffer() const { return _duuWeights; }
│ │ │ │ -
81 cl_mem GetDuvWeightsBuffer() const { return _duvWeights; }
│ │ │ │ -
82 cl_mem GetDvvWeightsBuffer() const { return _dvvWeights; }
│ │ │ │ -
83 int GetNumStencils() const { return _numStencils; }
│ │ │ │ -
84
│ │ │ │ -
85private:
│ │ │ │ -
86 cl_mem _sizes;
│ │ │ │ -
87 cl_mem _offsets;
│ │ │ │ -
88 cl_mem _indices;
│ │ │ │ -
89 cl_mem _weights;
│ │ │ │ -
90 cl_mem _duWeights;
│ │ │ │ -
91 cl_mem _dvWeights;
│ │ │ │ -
92 cl_mem _duuWeights;
│ │ │ │ -
93 cl_mem _duvWeights;
│ │ │ │ -
94 cl_mem _dvvWeights;
│ │ │ │ -
95 int _numStencils;
│ │ │ │ -
96};
│ │ │ │ -
│ │ │ │ -
97
│ │ │ │ -
98// ---------------------------------------------------------------------------
│ │ │ │ -
99
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
101public:
│ │ │ │ -
102 typedef bool Instantiatable;
│ │ │ │ -
103
│ │ │ │ -
105 template <typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
106 static CLEvaluator *Create(BufferDescriptor const &srcDesc,
│ │ │ │ -
107 BufferDescriptor const &dstDesc,
│ │ │ │ -
108 BufferDescriptor const &duDesc,
│ │ │ │ -
109 BufferDescriptor const &dvDesc,
│ │ │ │ -
110 DEVICE_CONTEXT deviceContext) {
│ │ │ │ -
111 return Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ -
112 deviceContext->GetContext(),
│ │ │ │ -
113 deviceContext->GetCommandQueue());
│ │ │ │ -
114 }
│ │ │ │ -
│ │ │ │ -
115
│ │ │ │ -
│ │ │ │ -
116 static CLEvaluator * Create(BufferDescriptor const &srcDesc,
│ │ │ │ -
117 BufferDescriptor const &dstDesc,
│ │ │ │ -
118 BufferDescriptor const &duDesc,
│ │ │ │ -
119 BufferDescriptor const &dvDesc,
│ │ │ │ -
120 cl_context clContext,
│ │ │ │ -
121 cl_command_queue clCommandQueue) {
│ │ │ │ -
122 CLEvaluator *instance = new CLEvaluator(clContext, clCommandQueue);
│ │ │ │ -
123 if (instance->Compile(srcDesc, dstDesc, duDesc, dvDesc))
│ │ │ │ -
124 return instance;
│ │ │ │ -
125 delete instance;
│ │ │ │ -
126 return NULL;
│ │ │ │ -
127 }
│ │ │ │ -
│ │ │ │ -
128
│ │ │ │ -
130 template <typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
131 static CLEvaluator *Create(BufferDescriptor const &srcDesc,
│ │ │ │ -
132 BufferDescriptor const &dstDesc,
│ │ │ │ -
133 BufferDescriptor const &duDesc,
│ │ │ │ -
134 BufferDescriptor const &dvDesc,
│ │ │ │ -
135 BufferDescriptor const &duuDesc,
│ │ │ │ -
136 BufferDescriptor const &duvDesc,
│ │ │ │ -
137 BufferDescriptor const &dvvDesc,
│ │ │ │ -
138 DEVICE_CONTEXT deviceContext) {
│ │ │ │ -
139 return Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ -
140 duuDesc, duvDesc, dvvDesc,
│ │ │ │ -
141 deviceContext->GetContext(),
│ │ │ │ -
142 deviceContext->GetCommandQueue());
│ │ │ │ -
143 }
│ │ │ │ -
│ │ │ │ -
144
│ │ │ │ -
│ │ │ │ -
145 static CLEvaluator * Create(BufferDescriptor const &srcDesc,
│ │ │ │ -
146 BufferDescriptor const &dstDesc,
│ │ │ │ -
147 BufferDescriptor const &duDesc,
│ │ │ │ -
148 BufferDescriptor const &dvDesc,
│ │ │ │ -
149 BufferDescriptor const &duuDesc,
│ │ │ │ -
150 BufferDescriptor const &duvDesc,
│ │ │ │ -
151 BufferDescriptor const &dvvDesc,
│ │ │ │ -
152 cl_context clContext,
│ │ │ │ -
153 cl_command_queue clCommandQueue) {
│ │ │ │ -
154 CLEvaluator *instance = new CLEvaluator(clContext, clCommandQueue);
│ │ │ │ -
155 if (instance->Compile(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ -
156 duuDesc, duvDesc, dvvDesc))
│ │ │ │ -
157 return instance;
│ │ │ │ -
158 delete instance;
│ │ │ │ -
159 return NULL;
│ │ │ │ -
160 }
│ │ │ │ -
│ │ │ │ -
161
│ │ │ │ -
163 CLEvaluator(cl_context context, cl_command_queue queue);
│ │ │ │ -
164
│ │ │ │ - │ │ │ │ -
167
│ │ │ │ -
173
│ │ │ │ -
217 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
218 typename STENCIL_TABLE, typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
219 static bool EvalStencils(
│ │ │ │ -
220 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
221 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
222 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
223 CLEvaluator const *instance,
│ │ │ │ -
224 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
225 unsigned int numStartEvents=0,
│ │ │ │ -
226 const cl_event* startEvents=NULL,
│ │ │ │ -
227 cl_event* endEvent=NULL) {
│ │ │ │ -
228
│ │ │ │ -
229 if (instance) {
│ │ │ │ -
230 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
231 dstBuffer, dstDesc,
│ │ │ │ -
232 stencilTable,
│ │ │ │ -
233 numStartEvents, startEvents, endEvent);
│ │ │ │ -
234 } else {
│ │ │ │ -
235 // Create an instance on demand (slow)
│ │ │ │ -
236 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
239 deviceContext);
│ │ │ │ -
240 if (instance) {
│ │ │ │ -
241 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
242 dstBuffer, dstDesc,
│ │ │ │ -
243 stencilTable,
│ │ │ │ -
244 numStartEvents, startEvents, endEvent);
│ │ │ │ -
245 delete instance;
│ │ │ │ -
246 return r;
│ │ │ │ -
247 }
│ │ │ │ -
248 return false;
│ │ │ │ -
249 }
│ │ │ │ -
250 }
│ │ │ │ -
│ │ │ │ -
251
│ │ │ │ -
307 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
308 typename STENCIL_TABLE, typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
309 static bool EvalStencils(
│ │ │ │ -
310 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
311 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
312 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
313 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
314 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
315 CLEvaluator const *instance,
│ │ │ │ -
316 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
317 unsigned int numStartEvents=0,
│ │ │ │ -
318 const cl_event* startEvents=NULL,
│ │ │ │ -
319 cl_event* endEvent=NULL) {
│ │ │ │ -
320
│ │ │ │ -
321 if (instance) {
│ │ │ │ -
322 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
323 dstBuffer, dstDesc,
│ │ │ │ -
324 duBuffer, duDesc,
│ │ │ │ -
325 dvBuffer, dvDesc,
│ │ │ │ -
326 stencilTable,
│ │ │ │ -
327 numStartEvents, startEvents, endEvent);
│ │ │ │ -
328 } else {
│ │ │ │ -
329 // Create an instance on demand (slow)
│ │ │ │ -
330 instance = Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ -
331 deviceContext);
│ │ │ │ -
332 if (instance) {
│ │ │ │ -
333 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
334 dstBuffer, dstDesc,
│ │ │ │ -
335 duBuffer, duDesc,
│ │ │ │ -
336 dvBuffer, dvDesc,
│ │ │ │ -
337 stencilTable,
│ │ │ │ -
338 numStartEvents, startEvents, endEvent);
│ │ │ │ -
339 delete instance;
│ │ │ │ -
340 return r;
│ │ │ │ -
341 }
│ │ │ │ -
342 return false;
│ │ │ │ -
343 }
│ │ │ │ -
344 }
│ │ │ │ -
│ │ │ │ -
345
│ │ │ │ -
419 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
420 typename STENCIL_TABLE, typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
421 static bool EvalStencils(
│ │ │ │ -
422 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
423 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
424 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
425 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
426 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
427 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
428 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
429 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
430 CLEvaluator const *instance,
│ │ │ │ -
431 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
432 unsigned int numStartEvents=0,
│ │ │ │ -
433 const cl_event* startEvents=NULL,
│ │ │ │ -
434 cl_event* endEvent=NULL) {
│ │ │ │ -
435
│ │ │ │ -
436 if (instance) {
│ │ │ │ -
437 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
438 dstBuffer, dstDesc,
│ │ │ │ -
439 duBuffer, duDesc,
│ │ │ │ -
440 dvBuffer, dvDesc,
│ │ │ │ -
441 duuBuffer, duuDesc,
│ │ │ │ -
442 duvBuffer, duvDesc,
│ │ │ │ -
443 dvvBuffer, dvvDesc,
│ │ │ │ -
444 stencilTable,
│ │ │ │ -
445 numStartEvents, startEvents, endEvent);
│ │ │ │ -
446 } else {
│ │ │ │ -
447 // Create an instance on demand (slow)
│ │ │ │ -
448 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
449 duDesc, dvDesc,
│ │ │ │ -
450 duuDesc, duvDesc, dvvDesc,
│ │ │ │ -
451 deviceContext);
│ │ │ │ -
452 if (instance) {
│ │ │ │ -
453 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
454 dstBuffer, dstDesc,
│ │ │ │ -
455 duBuffer, duDesc,
│ │ │ │ -
456 dvBuffer, dvDesc,
│ │ │ │ -
457 duuBuffer, duuDesc,
│ │ │ │ -
458 duvBuffer, duvDesc,
│ │ │ │ -
459 dvvBuffer, dvvDesc,
│ │ │ │ -
460 stencilTable,
│ │ │ │ -
461 numStartEvents, startEvents, endEvent);
│ │ │ │ -
462 delete instance;
│ │ │ │ -
463 return r;
│ │ │ │ -
464 }
│ │ │ │ -
465 return false;
│ │ │ │ -
466 }
│ │ │ │ -
467 }
│ │ │ │ -
│ │ │ │ -
468
│ │ │ │ -
499 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
501 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
502 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
503 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
504 unsigned int numStartEvents=0,
│ │ │ │ -
505 const cl_event* startEvents=NULL,
│ │ │ │ -
506 cl_event* endEvent=NULL) const {
│ │ │ │ -
507 return EvalStencils(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
508 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
509 stencilTable->GetSizesBuffer(),
│ │ │ │ -
510 stencilTable->GetOffsetsBuffer(),
│ │ │ │ -
511 stencilTable->GetIndicesBuffer(),
│ │ │ │ -
512 stencilTable->GetWeightsBuffer(),
│ │ │ │ -
513 0,
│ │ │ │ -
514 stencilTable->GetNumStencils(),
│ │ │ │ -
515 numStartEvents, startEvents, endEvent);
│ │ │ │ -
516 }
│ │ │ │ -
│ │ │ │ -
517
│ │ │ │ -
560 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
562 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
563 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
564 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
565 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
566 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
567 unsigned int numStartEvents=0,
│ │ │ │ -
568 const cl_event* startEvents=NULL,
│ │ │ │ -
569 cl_event* endEvent=NULL) const {
│ │ │ │ -
570 return EvalStencils(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
571 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
572 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
573 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
574 stencilTable->GetSizesBuffer(),
│ │ │ │ -
575 stencilTable->GetOffsetsBuffer(),
│ │ │ │ -
576 stencilTable->GetIndicesBuffer(),
│ │ │ │ -
577 stencilTable->GetWeightsBuffer(),
│ │ │ │ -
578 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ -
579 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ -
580 0,
│ │ │ │ -
581 stencilTable->GetNumStencils(),
│ │ │ │ -
582 numStartEvents, startEvents, endEvent);
│ │ │ │ -
583 }
│ │ │ │ -
│ │ │ │ -
584
│ │ │ │ -
645 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
647 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
648 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
649 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
650 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
651 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
652 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
653 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
654 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
655 unsigned int numStartEvents=0,
│ │ │ │ -
656 const cl_event* startEvents=NULL,
│ │ │ │ -
657 cl_event* endEvent=NULL) const {
│ │ │ │ -
658 return EvalStencils(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
659 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
660 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
661 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
662 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ -
663 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ -
664 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ -
665 stencilTable->GetSizesBuffer(),
│ │ │ │ -
666 stencilTable->GetOffsetsBuffer(),
│ │ │ │ -
667 stencilTable->GetIndicesBuffer(),
│ │ │ │ -
668 stencilTable->GetWeightsBuffer(),
│ │ │ │ -
669 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ -
670 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ -
671 stencilTable->GetDuuWeightsBuffer(),
│ │ │ │ -
672 stencilTable->GetDuvWeightsBuffer(),
│ │ │ │ -
673 stencilTable->GetDvvWeightsBuffer(),
│ │ │ │ -
674 0,
│ │ │ │ -
675 stencilTable->GetNumStencils(),
│ │ │ │ -
676 numStartEvents, startEvents, endEvent);
│ │ │ │ -
677 }
│ │ │ │ -
│ │ │ │ -
678
│ │ │ │ -
681 bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ -
682 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
683 cl_mem sizes,
│ │ │ │ -
684 cl_mem offsets,
│ │ │ │ -
685 cl_mem indices,
│ │ │ │ -
686 cl_mem weights,
│ │ │ │ -
687 int start,
│ │ │ │ -
688 int end,
│ │ │ │ -
689 unsigned int numStartEvents=0,
│ │ │ │ -
690 const cl_event* startEvents=NULL,
│ │ │ │ -
691 cl_event* endEvent=NULL) const;
│ │ │ │ -
692
│ │ │ │ -
741 bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ -
742 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
743 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ -
744 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
745 cl_mem sizes,
│ │ │ │ -
746 cl_mem offsets,
│ │ │ │ -
747 cl_mem indices,
│ │ │ │ -
748 cl_mem weights,
│ │ │ │ -
749 cl_mem duWeights,
│ │ │ │ -
750 cl_mem dvWeights,
│ │ │ │ -
751 int start,
│ │ │ │ -
752 int end,
│ │ │ │ -
753 unsigned int numStartEvents=0,
│ │ │ │ -
754 const cl_event* startEvents=NULL,
│ │ │ │ -
755 cl_event* endEvent=NULL) const;
│ │ │ │ -
756
│ │ │ │ -
823 bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ -
824 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
825 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ -
826 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
827 cl_mem duu, BufferDescriptor const &duuDesc,
│ │ │ │ -
828 cl_mem duv, BufferDescriptor const &duvDesc,
│ │ │ │ -
829 cl_mem dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ -
830 cl_mem sizes,
│ │ │ │ -
831 cl_mem offsets,
│ │ │ │ -
832 cl_mem indices,
│ │ │ │ -
833 cl_mem weights,
│ │ │ │ -
834 cl_mem duWeights,
│ │ │ │ -
835 cl_mem dvWeights,
│ │ │ │ -
836 cl_mem duuWeights,
│ │ │ │ -
837 cl_mem duvWeights,
│ │ │ │ -
838 cl_mem dvvWeights,
│ │ │ │ -
839 int start,
│ │ │ │ -
840 int end,
│ │ │ │ -
841 unsigned int numStartEvents=0,
│ │ │ │ -
842 const cl_event* startEvents=NULL,
│ │ │ │ -
843 cl_event* endEvent=NULL) const;
│ │ │ │ -
844
│ │ │ │ -
850
│ │ │ │ -
899 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
900 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
901 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
902 static bool EvalPatches(
│ │ │ │ -
903 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
904 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
905 int numPatchCoords,
│ │ │ │ -
906 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
907 PATCH_TABLE *patchTable,
│ │ │ │ -
908 CLEvaluator const *instance,
│ │ │ │ -
909 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
910 unsigned int numStartEvents=0,
│ │ │ │ -
911 const cl_event* startEvents=NULL,
│ │ │ │ -
912 cl_event* endEvent=NULL) {
│ │ │ │ -
913
│ │ │ │ -
914 if (instance) {
│ │ │ │ -
915 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
916 dstBuffer, dstDesc,
│ │ │ │ -
917 numPatchCoords, patchCoords,
│ │ │ │ -
918 patchTable,
│ │ │ │ -
919 numStartEvents, startEvents, endEvent);
│ │ │ │ -
920 } else {
│ │ │ │ -
921 // Create an instance on demand (slow)
│ │ │ │ -
922 (void)deviceContext; // unused
│ │ │ │ -
923 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
926 deviceContext);
│ │ │ │ -
927 if (instance) {
│ │ │ │ -
928 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
929 dstBuffer, dstDesc,
│ │ │ │ -
930 numPatchCoords, patchCoords,
│ │ │ │ -
931 patchTable,
│ │ │ │ -
932 numStartEvents, startEvents, endEvent);
│ │ │ │ -
933 delete instance;
│ │ │ │ -
934 return r;
│ │ │ │ -
935 }
│ │ │ │ -
936 return false;
│ │ │ │ -
937 }
│ │ │ │ -
938 }
│ │ │ │ -
│ │ │ │ -
939
│ │ │ │ -
1000 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1001 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
1002 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
1003 static bool EvalPatches(
│ │ │ │ -
1004 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1005 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1006 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1007 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1008 int numPatchCoords,
│ │ │ │ -
1009 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1010 PATCH_TABLE *patchTable,
│ │ │ │ -
1011 CLEvaluator const *instance,
│ │ │ │ -
1012 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
1013 unsigned int numStartEvents=0,
│ │ │ │ -
1014 const cl_event* startEvents=NULL,
│ │ │ │ -
1015 cl_event* endEvent=NULL) {
│ │ │ │ -
1016
│ │ │ │ -
1017 if (instance) {
│ │ │ │ -
1018 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
1019 dstBuffer, dstDesc,
│ │ │ │ -
1020 duBuffer, duDesc,
│ │ │ │ -
1021 dvBuffer, dvDesc,
│ │ │ │ -
1022 numPatchCoords, patchCoords,
│ │ │ │ -
1023 patchTable,
│ │ │ │ -
1024 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1025 } else {
│ │ │ │ -
1026 // Create an instance on demand (slow)
│ │ │ │ -
1027 (void)deviceContext; // unused
│ │ │ │ -
1028 instance = Create(srcDesc, dstDesc, duDesc, dvDesc, deviceContext);
│ │ │ │ -
1029 if (instance) {
│ │ │ │ -
1030 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
1031 dstBuffer, dstDesc,
│ │ │ │ -
1032 duBuffer, duDesc,
│ │ │ │ -
1033 dvBuffer, dvDesc,
│ │ │ │ -
1034 numPatchCoords, patchCoords,
│ │ │ │ -
1035 patchTable,
│ │ │ │ -
1036 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1037 delete instance;
│ │ │ │ -
1038 return r;
│ │ │ │ -
1039 }
│ │ │ │ -
1040 return false;
│ │ │ │ -
1041 }
│ │ │ │ -
1042 }
│ │ │ │ -
│ │ │ │ -
1043
│ │ │ │ -
1122 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1123 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
1124 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
1125 static bool EvalPatches(
│ │ │ │ -
1126 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1127 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1128 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1129 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1130 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1131 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1132 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1133 int numPatchCoords,
│ │ │ │ -
1134 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1135 PATCH_TABLE *patchTable,
│ │ │ │ -
1136 CLEvaluator const *instance,
│ │ │ │ -
1137 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
1138 unsigned int numStartEvents=0,
│ │ │ │ -
1139 const cl_event* startEvents=NULL,
│ │ │ │ -
1140 cl_event* endEvent=NULL) {
│ │ │ │ -
1141
│ │ │ │ -
1142 if (instance) {
│ │ │ │ -
1143 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
1144 dstBuffer, dstDesc,
│ │ │ │ -
1145 duBuffer, duDesc,
│ │ │ │ -
1146 dvBuffer, dvDesc,
│ │ │ │ -
1147 duuBuffer, duuDesc,
│ │ │ │ -
1148 duvBuffer, duvDesc,
│ │ │ │ -
1149 dvvBuffer, dvvDesc,
│ │ │ │ -
1150 numPatchCoords, patchCoords,
│ │ │ │ -
1151 patchTable,
│ │ │ │ -
1152 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1153 } else {
│ │ │ │ -
1154 // Create an instance on demand (slow)
│ │ │ │ -
1155 (void)deviceContext; // unused
│ │ │ │ -
1156 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1157 duDesc, dvDesc,
│ │ │ │ -
1158 duuDesc, duvDesc, dvvDesc,
│ │ │ │ -
1159 deviceContext);
│ │ │ │ -
1160 if (instance) {
│ │ │ │ -
1161 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
1162 dstBuffer, dstDesc,
│ │ │ │ -
1163 duBuffer, duDesc,
│ │ │ │ -
1164 dvBuffer, dvDesc,
│ │ │ │ -
1165 duuBuffer, duuDesc,
│ │ │ │ -
1166 duvBuffer, duvDesc,
│ │ │ │ -
1167 dvvBuffer, dvvDesc,
│ │ │ │ -
1168 numPatchCoords, patchCoords,
│ │ │ │ -
1169 patchTable,
│ │ │ │ -
1170 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1171 delete instance;
│ │ │ │ -
1172 return r;
│ │ │ │ -
1173 }
│ │ │ │ -
1174 return false;
│ │ │ │ -
1175 }
│ │ │ │ -
1176 }
│ │ │ │ -
│ │ │ │ -
1177
│ │ │ │ -
1215 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1216 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1218 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1219 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1220 int numPatchCoords,
│ │ │ │ -
1221 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1222 PATCH_TABLE *patchTable,
│ │ │ │ -
1223 unsigned int numStartEvents=0,
│ │ │ │ -
1224 const cl_event* startEvents=NULL,
│ │ │ │ -
1225 cl_event* endEvent=NULL) const {
│ │ │ │ -
1226
│ │ │ │ -
1227 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
1228 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
1229 0, BufferDescriptor(),
│ │ │ │ -
1230 0, BufferDescriptor(),
│ │ │ │ -
1231 numPatchCoords,
│ │ │ │ -
1232 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
1233 patchTable->GetPatchArrayBuffer(),
│ │ │ │ -
1234 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
1235 patchTable->GetPatchParamBuffer(),
│ │ │ │ -
1236 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1237 }
│ │ │ │ -
│ │ │ │ -
1238
│ │ │ │ -
1286 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1287 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1289 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1290 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1291 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1292 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1293 int numPatchCoords,
│ │ │ │ -
1294 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1295 PATCH_TABLE *patchTable,
│ │ │ │ -
1296 unsigned int numStartEvents=0,
│ │ │ │ -
1297 const cl_event* startEvents=NULL,
│ │ │ │ -
1298 cl_event* endEvent=NULL) const {
│ │ │ │ -
1299
│ │ │ │ -
1300 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
1301 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
1302 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
1303 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
1304 numPatchCoords,
│ │ │ │ -
1305 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
1306 patchTable->GetPatchArrayBuffer(),
│ │ │ │ -
1307 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
1308 patchTable->GetPatchParamBuffer(),
│ │ │ │ -
1309 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1310 }
│ │ │ │ -
│ │ │ │ -
1311
│ │ │ │ -
1377 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1378 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1380 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1381 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1382 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1383 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1384 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1385 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1386 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1387 int numPatchCoords,
│ │ │ │ -
1388 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1389 PATCH_TABLE *patchTable,
│ │ │ │ -
1390 unsigned int numStartEvents=0,
│ │ │ │ -
1391 const cl_event* startEvents=NULL,
│ │ │ │ -
1392 cl_event* endEvent=NULL) const {
│ │ │ │ -
1393
│ │ │ │ -
1394 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
1395 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
1396 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
1397 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
1398 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ -
1399 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ -
1400 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ -
1401 numPatchCoords,
│ │ │ │ -
1402 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
1403 patchTable->GetPatchArrayBuffer(),
│ │ │ │ -
1404 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
1405 patchTable->GetPatchParamBuffer(),
│ │ │ │ -
1406 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1407 }
│ │ │ │ -
│ │ │ │ -
1408
│ │ │ │ -
1409 bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ -
1410 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
1411 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ -
1412 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
1413 int numPatchCoords,
│ │ │ │ -
1414 cl_mem patchCoordsBuffer,
│ │ │ │ -
1415 cl_mem patchArrayBuffer,
│ │ │ │ -
1416 cl_mem patchIndexBuffer,
│ │ │ │ -
1417 cl_mem patchParamsBuffer,
│ │ │ │ -
1418 unsigned int numStartEvents=0,
│ │ │ │ -
1419 const cl_event* startEvents=NULL,
│ │ │ │ -
1420 cl_event* endEvent=NULL) const;
│ │ │ │ -
1421
│ │ │ │ -
1422 bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ -
1423 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
1424 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ -
1425 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
1426 cl_mem duu, BufferDescriptor const &duuDesc,
│ │ │ │ -
1427 cl_mem duv, BufferDescriptor const &duvDesc,
│ │ │ │ -
1428 cl_mem dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1429 int numPatchCoords,
│ │ │ │ -
1430 cl_mem patchCoordsBuffer,
│ │ │ │ -
1431 cl_mem patchArrayBuffer,
│ │ │ │ -
1432 cl_mem patchIndexBuffer,
│ │ │ │ -
1433 cl_mem patchParamsBuffer,
│ │ │ │ -
1434 unsigned int numStartEvents=0,
│ │ │ │ -
1435 const cl_event* startEvents=NULL,
│ │ │ │ -
1436 cl_event* endEvent=NULL) const;
│ │ │ │ -
1437
│ │ │ │ -
1486 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1487 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
1488 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1490 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1491 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1492 int numPatchCoords,
│ │ │ │ -
1493 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1494 PATCH_TABLE *patchTable,
│ │ │ │ -
1495 CLEvaluator const *instance,
│ │ │ │ -
1496 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
1497 unsigned int numStartEvents=0,
│ │ │ │ -
1498 const cl_event* startEvents=NULL,
│ │ │ │ -
1499 cl_event* endEvent=NULL) {
│ │ │ │ -
1500
│ │ │ │ -
1501 if (instance) {
│ │ │ │ -
1502 return instance->EvalPatchesVarying(
│ │ │ │ -
1503 srcBuffer, srcDesc,
│ │ │ │ -
1504 dstBuffer, dstDesc,
│ │ │ │ -
1505 numPatchCoords, patchCoords,
│ │ │ │ -
1506 patchTable,
│ │ │ │ -
1507 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1508 } else {
│ │ │ │ -
1509 // Create an instance on demand (slow)
│ │ │ │ -
1510 (void)deviceContext; // unused
│ │ │ │ -
1511 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
1514 deviceContext);
│ │ │ │ -
1515 if (instance) {
│ │ │ │ -
1516 bool r = instance->EvalPatchesVarying(
│ │ │ │ -
1517 srcBuffer, srcDesc,
│ │ │ │ -
1518 dstBuffer, dstDesc,
│ │ │ │ -
1519 numPatchCoords, patchCoords,
│ │ │ │ -
1520 patchTable,
│ │ │ │ -
1521 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1522 delete instance;
│ │ │ │ -
1523 return r;
│ │ │ │ -
1524 }
│ │ │ │ -
1525 return false;
│ │ │ │ -
1526 }
│ │ │ │ -
1527 }
│ │ │ │ -
│ │ │ │ -
1528
│ │ │ │ -
1566 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1567 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1569 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1570 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1571 int numPatchCoords,
│ │ │ │ -
1572 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1573 PATCH_TABLE *patchTable,
│ │ │ │ -
1574 unsigned int numStartEvents=0,
│ │ │ │ -
1575 const cl_event* startEvents=NULL,
│ │ │ │ -
1576 cl_event* endEvent=NULL) const {
│ │ │ │ -
1577
│ │ │ │ -
1578 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
1579 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
1580 0, BufferDescriptor(),
│ │ │ │ -
1581 0, BufferDescriptor(),
│ │ │ │ -
1582 numPatchCoords,
│ │ │ │ -
1583 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
1584 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ -
1585 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
1586 patchTable->GetPatchParamBuffer(),
│ │ │ │ -
1587 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1588 }
│ │ │ │ -
│ │ │ │ -
1589
│ │ │ │ -
1650 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1651 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
1652 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1654 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1655 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1656 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1657 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1658 int numPatchCoords,
│ │ │ │ -
1659 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1660 PATCH_TABLE *patchTable,
│ │ │ │ -
1661 CLEvaluator const *instance,
│ │ │ │ -
1662 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
1663 unsigned int numStartEvents=0,
│ │ │ │ -
1664 const cl_event* startEvents=NULL,
│ │ │ │ -
1665 cl_event* endEvent=NULL) {
│ │ │ │ -
1666
│ │ │ │ -
1667 if (instance) {
│ │ │ │ -
1668 return instance->EvalPatchesVarying(
│ │ │ │ -
1669 srcBuffer, srcDesc,
│ │ │ │ -
1670 dstBuffer, dstDesc,
│ │ │ │ -
1671 duBuffer, duDesc,
│ │ │ │ -
1672 dvBuffer, dvDesc,
│ │ │ │ -
1673 numPatchCoords, patchCoords,
│ │ │ │ -
1674 patchTable,
│ │ │ │ -
1675 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1676 } else {
│ │ │ │ -
1677 // Create an instance on demand (slow)
│ │ │ │ -
1678 (void)deviceContext; // unused
│ │ │ │ -
1679 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1680 duDesc, dvDesc,
│ │ │ │ -
1681 deviceContext);
│ │ │ │ -
1682 if (instance) {
│ │ │ │ -
1683 bool r = instance->EvalPatchesVarying(
│ │ │ │ -
1684 srcBuffer, srcDesc,
│ │ │ │ -
1685 dstBuffer, dstDesc,
│ │ │ │ -
1686 duBuffer, duDesc,
│ │ │ │ -
1687 dvBuffer, dvDesc,
│ │ │ │ -
1688 numPatchCoords, patchCoords,
│ │ │ │ -
1689 patchTable,
│ │ │ │ -
1690 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1691 delete instance;
│ │ │ │ -
1692 return r;
│ │ │ │ -
1693 }
│ │ │ │ -
1694 return false;
│ │ │ │ -
1695 }
│ │ │ │ -
1696 }
│ │ │ │ -
│ │ │ │ -
1697
│ │ │ │ -
1747 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1748 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1750 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1751 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1752 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1753 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1754 int numPatchCoords,
│ │ │ │ -
1755 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1756 PATCH_TABLE *patchTable,
│ │ │ │ -
1757 unsigned int numStartEvents=0,
│ │ │ │ -
1758 const cl_event* startEvents=NULL,
│ │ │ │ -
1759 cl_event* endEvent=NULL) const {
│ │ │ │ -
1760
│ │ │ │ -
1761 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
1762 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
1763 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
1764 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
1765 numPatchCoords,
│ │ │ │ -
1766 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
1767 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ -
1768 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
1769 patchTable->GetPatchParamBuffer(),
│ │ │ │ -
1770 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1771 }
│ │ │ │ -
│ │ │ │ -
1772
│ │ │ │ -
1851 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1852 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
1853 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1855 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1856 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1857 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1858 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1859 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1860 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1861 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1862 int numPatchCoords,
│ │ │ │ -
1863 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1864 PATCH_TABLE *patchTable,
│ │ │ │ -
1865 CLEvaluator const *instance,
│ │ │ │ -
1866 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
1867 unsigned int numStartEvents=0,
│ │ │ │ -
1868 const cl_event* startEvents=NULL,
│ │ │ │ -
1869 cl_event* endEvent=NULL) {
│ │ │ │ -
1870
│ │ │ │ -
1871 if (instance) {
│ │ │ │ -
1872 return instance->EvalPatchesVarying(
│ │ │ │ -
1873 srcBuffer, srcDesc,
│ │ │ │ -
1874 dstBuffer, dstDesc,
│ │ │ │ -
1875 duBuffer, duDesc,
│ │ │ │ -
1876 dvBuffer, dvDesc,
│ │ │ │ -
1877 duuBuffer, duuDesc,
│ │ │ │ -
1878 duvBuffer, duvDesc,
│ │ │ │ -
1879 dvvBuffer, dvvDesc,
│ │ │ │ -
1880 numPatchCoords, patchCoords,
│ │ │ │ -
1881 patchTable,
│ │ │ │ -
1882 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1883 } else {
│ │ │ │ -
1884 // Create an instance on demand (slow)
│ │ │ │ -
1885 (void)deviceContext; // unused
│ │ │ │ -
1886 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1887 duDesc, dvDesc,
│ │ │ │ -
1888 duuDesc, duvDesc, dvvDesc,
│ │ │ │ -
1889 deviceContext);
│ │ │ │ -
1890 if (instance) {
│ │ │ │ -
1891 bool r = instance->EvalPatchesVarying(
│ │ │ │ -
1892 srcBuffer, srcDesc,
│ │ │ │ -
1893 dstBuffer, dstDesc,
│ │ │ │ -
1894 duBuffer, duDesc,
│ │ │ │ -
1895 dvBuffer, dvDesc,
│ │ │ │ -
1896 duuBuffer, duuDesc,
│ │ │ │ -
1897 duvBuffer, duvDesc,
│ │ │ │ -
1898 dvvBuffer, dvvDesc,
│ │ │ │ -
1899 numPatchCoords, patchCoords,
│ │ │ │ -
1900 patchTable,
│ │ │ │ -
1901 numStartEvents, startEvents, endEvent);
│ │ │ │ -
1902 delete instance;
│ │ │ │ -
1903 return r;
│ │ │ │ -
1904 }
│ │ │ │ -
1905 return false;
│ │ │ │ -
1906 }
│ │ │ │ -
1907 }
│ │ │ │ -
│ │ │ │ -
1908
│ │ │ │ -
1976 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1977 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1979 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1980 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1981 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1982 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1983 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1984 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1985 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1986 int numPatchCoords,
│ │ │ │ -
1987 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1988 PATCH_TABLE *patchTable,
│ │ │ │ -
1989 unsigned int numStartEvents=0,
│ │ │ │ -
1990 const cl_event* startEvents=NULL,
│ │ │ │ -
1991 cl_event* endEvent=NULL) const {
│ │ │ │ -
1992
│ │ │ │ -
1993 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
1994 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
1995 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
1996 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
1997 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ -
1998 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ -
1999 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ -
2000 numPatchCoords,
│ │ │ │ -
2001 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
2002 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ -
2003 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
2004 patchTable->GetPatchParamBuffer(),
│ │ │ │ -
2005 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2006 }
│ │ │ │ -
│ │ │ │ -
2007
│ │ │ │ -
2058 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2059 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
2060 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2062 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2063 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2064 int numPatchCoords,
│ │ │ │ -
2065 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2066 PATCH_TABLE *patchTable,
│ │ │ │ -
2067 int fvarChannel,
│ │ │ │ -
2068 CLEvaluator const *instance,
│ │ │ │ -
2069 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
2070 unsigned int numStartEvents=0,
│ │ │ │ -
2071 const cl_event* startEvents=NULL,
│ │ │ │ -
2072 cl_event* endEvent=NULL) {
│ │ │ │ -
2073
│ │ │ │ -
2074 if (instance) {
│ │ │ │ -
2075 return instance->EvalPatchesFaceVarying(
│ │ │ │ -
2076 srcBuffer, srcDesc,
│ │ │ │ -
2077 dstBuffer, dstDesc,
│ │ │ │ -
2078 numPatchCoords, patchCoords,
│ │ │ │ -
2079 patchTable, fvarChannel,
│ │ │ │ -
2080 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2081 } else {
│ │ │ │ -
2082 // Create an instance on demand (slow)
│ │ │ │ -
2083 (void)deviceContext; // unused
│ │ │ │ -
2084 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
2087 deviceContext);
│ │ │ │ -
2088 if (instance) {
│ │ │ │ -
2089 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ -
2090 srcBuffer, srcDesc,
│ │ │ │ -
2091 dstBuffer, dstDesc,
│ │ │ │ -
2092 numPatchCoords, patchCoords,
│ │ │ │ -
2093 patchTable, fvarChannel,
│ │ │ │ -
2094 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2095 delete instance;
│ │ │ │ -
2096 return r;
│ │ │ │ -
2097 }
│ │ │ │ -
2098 return false;
│ │ │ │ -
2099 }
│ │ │ │ -
2100 }
│ │ │ │ -
│ │ │ │ -
2101
│ │ │ │ -
2141 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2142 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2144 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2145 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2146 int numPatchCoords,
│ │ │ │ -
2147 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2148 PATCH_TABLE *patchTable,
│ │ │ │ -
2149 int fvarChannel = 0,
│ │ │ │ -
2150 unsigned int numStartEvents=0,
│ │ │ │ -
2151 const cl_event* startEvents=NULL,
│ │ │ │ -
2152 cl_event* endEvent=NULL) const {
│ │ │ │ -
2153
│ │ │ │ -
2154 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
2155 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
2156 0, BufferDescriptor(),
│ │ │ │ -
2157 0, BufferDescriptor(),
│ │ │ │ -
2158 numPatchCoords,
│ │ │ │ -
2159 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
2160 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ -
2161 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
2162 patchTable->GetFVarPatchParamBuffer(fvarChannel),
│ │ │ │ -
2163 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2164 }
│ │ │ │ -
│ │ │ │ -
2165
│ │ │ │ -
2228 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2229 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
2230 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2232 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2233 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2234 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
2235 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
2236 int numPatchCoords,
│ │ │ │ -
2237 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2238 PATCH_TABLE *patchTable,
│ │ │ │ -
2239 int fvarChannel,
│ │ │ │ -
2240 CLEvaluator const *instance,
│ │ │ │ -
2241 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
2242 unsigned int numStartEvents=0,
│ │ │ │ -
2243 const cl_event* startEvents=NULL,
│ │ │ │ -
2244 cl_event* endEvent=NULL) {
│ │ │ │ -
2245
│ │ │ │ -
2246 if (instance) {
│ │ │ │ -
2247 return instance->EvalPatchesFaceVarying(
│ │ │ │ -
2248 srcBuffer, srcDesc,
│ │ │ │ -
2249 dstBuffer, dstDesc,
│ │ │ │ -
2250 duBuffer, duDesc,
│ │ │ │ -
2251 dvBuffer, dvDesc,
│ │ │ │ -
2252 numPatchCoords, patchCoords,
│ │ │ │ -
2253 patchTable, fvarChannel,
│ │ │ │ -
2254 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2255 } else {
│ │ │ │ -
2256 // Create an instance on demand (slow)
│ │ │ │ -
2257 (void)deviceContext; // unused
│ │ │ │ -
2258 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
2259 duDesc, dvDesc, deviceContext);
│ │ │ │ -
2260 if (instance) {
│ │ │ │ -
2261 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ -
2262 srcBuffer, srcDesc,
│ │ │ │ -
2263 dstBuffer, dstDesc,
│ │ │ │ -
2264 duBuffer, duDesc,
│ │ │ │ -
2265 dvBuffer, dvDesc,
│ │ │ │ -
2266 numPatchCoords, patchCoords,
│ │ │ │ -
2267 patchTable, fvarChannel,
│ │ │ │ -
2268 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2269 delete instance;
│ │ │ │ -
2270 return r;
│ │ │ │ -
2271 }
│ │ │ │ -
2272 return false;
│ │ │ │ -
2273 }
│ │ │ │ -
2274 }
│ │ │ │ -
│ │ │ │ -
2275
│ │ │ │ -
2327 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2328 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2330 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2331 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2332 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
2333 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
2334 int numPatchCoords,
│ │ │ │ -
2335 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2336 PATCH_TABLE *patchTable,
│ │ │ │ -
2337 int fvarChannel = 0,
│ │ │ │ -
2338 unsigned int numStartEvents=0,
│ │ │ │ -
2339 const cl_event* startEvents=NULL,
│ │ │ │ -
2340 cl_event* endEvent=NULL) const {
│ │ │ │ -
2341
│ │ │ │ -
2342 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
2343 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
2344 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
2345 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
2346 numPatchCoords,
│ │ │ │ -
2347 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
2348 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ -
2349 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
2350 patchTable->GetFVarPatchParamBuffer(fvarChannel),
│ │ │ │ -
2351 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2352 }
│ │ │ │ -
│ │ │ │ -
2353
│ │ │ │ -
2434 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2435 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ -
2436 typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2438 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2439 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2440 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
2441 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
2442 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
2443 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
2444 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
2445 int numPatchCoords,
│ │ │ │ -
2446 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2447 PATCH_TABLE *patchTable,
│ │ │ │ -
2448 int fvarChannel,
│ │ │ │ -
2449 CLEvaluator const *instance,
│ │ │ │ -
2450 DEVICE_CONTEXT deviceContext,
│ │ │ │ -
2451 unsigned int numStartEvents=0,
│ │ │ │ -
2452 const cl_event* startEvents=NULL,
│ │ │ │ -
2453 cl_event* endEvent=NULL) {
│ │ │ │ -
2454
│ │ │ │ -
2455 if (instance) {
│ │ │ │ -
2456 return instance->EvalPatchesFaceVarying(
│ │ │ │ -
2457 srcBuffer, srcDesc,
│ │ │ │ -
2458 dstBuffer, dstDesc,
│ │ │ │ -
2459 duBuffer, duDesc,
│ │ │ │ -
2460 dvBuffer, dvDesc,
│ │ │ │ -
2461 duuBuffer, duuDesc,
│ │ │ │ -
2462 duvBuffer, duvDesc,
│ │ │ │ -
2463 dvvBuffer, dvvDesc,
│ │ │ │ -
2464 numPatchCoords, patchCoords,
│ │ │ │ -
2465 patchTable, fvarChannel,
│ │ │ │ -
2466 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2467 } else {
│ │ │ │ -
2468 // Create an instance on demand (slow)
│ │ │ │ -
2469 (void)deviceContext; // unused
│ │ │ │ -
2470 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
2471 duDesc, dvDesc,
│ │ │ │ -
2472 duuDesc, duvDesc, dvvDesc,
│ │ │ │ -
2473 deviceContext);
│ │ │ │ -
2474 if (instance) {
│ │ │ │ -
2475 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ -
2476 srcBuffer, srcDesc,
│ │ │ │ -
2477 dstBuffer, dstDesc,
│ │ │ │ -
2478 duBuffer, duDesc,
│ │ │ │ -
2479 dvBuffer, dvDesc,
│ │ │ │ -
2480 duuBuffer, duuDesc,
│ │ │ │ -
2481 duvBuffer, duvDesc,
│ │ │ │ -
2482 dvvBuffer, dvvDesc,
│ │ │ │ -
2483 numPatchCoords, patchCoords,
│ │ │ │ -
2484 patchTable, fvarChannel,
│ │ │ │ -
2485 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2486 delete instance;
│ │ │ │ -
2487 return r;
│ │ │ │ -
2488 }
│ │ │ │ -
2489 return false;
│ │ │ │ -
2490 }
│ │ │ │ -
2491 }
│ │ │ │ -
│ │ │ │ -
2492
│ │ │ │ -
2562 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2563 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2565 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2566 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2567 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
2568 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
2569 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
2570 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
2571 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
2572 int numPatchCoords,
│ │ │ │ -
2573 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2574 PATCH_TABLE *patchTable,
│ │ │ │ -
2575 int fvarChannel = 0,
│ │ │ │ -
2576 unsigned int numStartEvents=0,
│ │ │ │ -
2577 const cl_event* startEvents=NULL,
│ │ │ │ -
2578 cl_event* endEvent=NULL) const {
│ │ │ │ -
2579
│ │ │ │ -
2580 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ -
2581 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ -
2582 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ -
2583 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ -
2584 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ -
2585 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ -
2586 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ -
2587 numPatchCoords,
│ │ │ │ -
2588 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ -
2589 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ -
2590 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
2591 patchTable->GetFVarPatchParamBuffer(fvarChannel),
│ │ │ │ -
2592 numStartEvents, startEvents, endEvent);
│ │ │ │ -
2593 }
│ │ │ │ -
│ │ │ │ -
2594
│ │ │ │ -
2600
│ │ │ │ -
2603 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ -
2604 BufferDescriptor const &dstDesc,
│ │ │ │ -
2605 BufferDescriptor const &duDesc = BufferDescriptor(),
│ │ │ │ -
2606 BufferDescriptor const &dvDesc = BufferDescriptor(),
│ │ │ │ -
2607 BufferDescriptor const &duuDesc = BufferDescriptor(),
│ │ │ │ -
2608 BufferDescriptor const &duvDesc = BufferDescriptor(),
│ │ │ │ -
2609 BufferDescriptor const &dvvDesc = BufferDescriptor());
│ │ │ │ -
2610
│ │ │ │ -
2612 template <typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
2613 static void Synchronize(DEVICE_CONTEXT deviceContext) {
│ │ │ │ -
2614 Synchronize(deviceContext->GetCommandQueue());
│ │ │ │ -
2615 }
│ │ │ │ -
│ │ │ │ -
2616
│ │ │ │ -
2617 static void Synchronize(cl_command_queue queue);
│ │ │ │ -
2618
│ │ │ │ -
2619private:
│ │ │ │ -
2620 cl_context _clContext;
│ │ │ │ -
2621 cl_command_queue _clCommandQueue;
│ │ │ │ -
2622 cl_program _program;
│ │ │ │ -
2623 cl_kernel _stencilKernel;
│ │ │ │ -
2624 cl_kernel _stencilDerivKernel;
│ │ │ │ -
2625 cl_kernel _patchKernel;
│ │ │ │ -
2626};
│ │ │ │ -
│ │ │ │ -
2627
│ │ │ │ -
2628} // end namespace Osd
│ │ │ │ -
2629
│ │ │ │ -
2630} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
2631using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
2632
│ │ │ │ -
2633} // end namespace OpenSubdiv
│ │ │ │ -
2634
│ │ │ │ -
2635
│ │ │ │ -
2636#endif // OPENSUBDIV3_OSD_CL_EVALUATOR_H
│ │ │ │ +
30#include <cstddef>
│ │ │ │ +
31
│ │ │ │ +
32@protocol MTLDevice;
│ │ │ │ +
33@protocol MTLCommandQueue;
│ │ │ │ +
34
│ │ │ │ +
35namespace OpenSubdiv {
│ │ │ │ +
36namespace OPENSUBDIV_VERSION {
│ │ │ │ +
37
│ │ │ │ +
38namespace Osd {
│ │ │ │ +
39
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
41public:
│ │ │ │ +
42 id<MTLDevice> device = nullptr;
│ │ │ │ +
43 id<MTLCommandQueue> commandQueue = nullptr;
│ │ │ │ +
44};
│ │ │ │ +
│ │ │ │ +
45
│ │ │ │ +
46} // end namespace Osd
│ │ │ │ +
47
│ │ │ │ +
48} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
49using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
50
│ │ │ │ +
51} // end namespace OpenSubdiv
│ │ │ │ +
52
│ │ │ │ +
53#endif //OPENSUBDIV3_OSD_MTL_COMMON_H
│ │ │ │ │ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ - │ │ │ │ -
CLStencilTable(Far::StencilTable const *stencilTable, cl_context clContext)
│ │ │ │ - │ │ │ │ -
static CLStencilTable * Create(Far::LimitStencilTable const *limitStencilTable, DEVICE_CONTEXT context)
Definition clEvaluator.h:61
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
static CLStencilTable * Create(Far::StencilTable const *stencilTable, DEVICE_CONTEXT context)
Definition clEvaluator.h:55
│ │ │ │ -
CLStencilTable(Far::LimitStencilTable const *limitStencilTable, cl_context clContext)
│ │ │ │ - │ │ │ │ - │ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
static void Synchronize(cl_command_queue queue)
│ │ │ │ - │ │ │ │ -
bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, cl_mem weights, cl_mem duWeights, cl_mem dvWeights, int start, int end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Dispatch the CL compute kernel asynchronously. returns false if the kernel hasn't been compiled yet.
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, cl_context clContext, cl_command_queue clCommandQueue)
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, int numPatchCoords, cl_mem patchCoordsBuffer, cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem patchParamsBuffer, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
│ │ │ │ -
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic stencil function.
│ │ │ │ -
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ - │ │ │ │ -
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, DEVICE_CONTEXT deviceContext)
Generic creator template.
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, DEVICE_CONTEXT deviceContext)
Generic creator template.
│ │ │ │ -
bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const &duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, BufferDescriptor const &dvvDesc, int numPatchCoords, cl_mem patchCoordsBuffer, cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem patchParamsBuffer, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
│ │ │ │ -
bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const &duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, BufferDescriptor const &dvvDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, cl_mem weights, cl_mem duWeights, cl_mem dvWeights, cl_mem duuWeights, cl_mem duvWeights, cl_mem dvvWeights, int start, int end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Dispatch the CL compute kernel asynchronously. returns false if the kernel hasn't been compiled yet.
│ │ │ │ -
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic stencil function.
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static void Synchronize(DEVICE_CONTEXT deviceContext)
Wait the OpenCL kernels finish.
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, cl_mem weights, int start, int end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, cl_context clContext, cl_command_queue clCommandQueue)
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic stencil function.
│ │ │ │ -
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ -
CLEvaluator(cl_context context, cl_command_queue queue)
Constructor.
│ │ │ │ -
bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const &dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const &dvvDesc=BufferDescriptor())
│ │ │ │ -
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -clEvaluator.h │ │ │ │ │ +mtlCommon.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2015 Pixar │ │ │ │ │ +2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -24,1553 +24,50 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_CL_EVALUATOR_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_CL_EVALUATOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_MTL_COMMON_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_MTL_COMMON_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../osd/opencl.h" │ │ │ │ │ -31#include "../osd/types.h" │ │ │ │ │ -32#include "../osd/bufferDescriptor.h" │ │ │ │ │ -33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Far { │ │ │ │ │ -38 class PatchTable; │ │ │ │ │ -39 class StencilTable; │ │ │ │ │ -40 class LimitStencilTable; │ │ │ │ │ -41} │ │ │ │ │ -42 │ │ │ │ │ -43namespace Osd { │ │ │ │ │ -44 │ │ │ │ │ -_5_2class _C_L_S_t_e_n_c_i_l_T_a_b_l_e { │ │ │ │ │ -53public: │ │ │ │ │ -54 template │ │ │ │ │ -_5_5 static _C_L_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ -56 DEVICE_CONTEXT context) { │ │ │ │ │ -57 return new _C_L_S_t_e_n_c_i_l_T_a_b_l_e(stencilTable, context->GetContext()); │ │ │ │ │ -58 } │ │ │ │ │ -59 │ │ │ │ │ -60 template │ │ │ │ │ -_6_1 static _C_L_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e( │ │ │ │ │ -62 _F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *limitStencilTable, │ │ │ │ │ -63 DEVICE_CONTEXT context) { │ │ │ │ │ -64 return new _C_L_S_t_e_n_c_i_l_T_a_b_l_e(limitStencilTable, context->GetContext()); │ │ │ │ │ -65 } │ │ │ │ │ -66 │ │ │ │ │ -_6_7 _C_L_S_t_e_n_c_i_l_T_a_b_l_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ -68 cl_context clContext); │ │ │ │ │ -_6_9 _C_L_S_t_e_n_c_i_l_T_a_b_l_e(_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *limitStencilTable, │ │ │ │ │ -70 cl_context clContext); │ │ │ │ │ -_7_1 _~_C_L_S_t_e_n_c_i_l_T_a_b_l_e(); │ │ │ │ │ -72 │ │ │ │ │ -73 // interfaces needed for CLComputeKernel │ │ │ │ │ -_7_4 cl_mem _G_e_t_S_i_z_e_s_B_u_f_f_e_r() const { return _sizes; } │ │ │ │ │ -_7_5 cl_mem _G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r() const { return _offsets; } │ │ │ │ │ -_7_6 cl_mem _G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r() const { return _indices; } │ │ │ │ │ -_7_7 cl_mem _G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _weights; } │ │ │ │ │ -_7_8 cl_mem _G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duWeights; } │ │ │ │ │ -_7_9 cl_mem _G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvWeights; } │ │ │ │ │ -_8_0 cl_mem _G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duuWeights; } │ │ │ │ │ -_8_1 cl_mem _G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duvWeights; } │ │ │ │ │ -_8_2 cl_mem _G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvvWeights; } │ │ │ │ │ -_8_3 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { return _numStencils; } │ │ │ │ │ -84 │ │ │ │ │ -85private: │ │ │ │ │ -86 cl_mem _sizes; │ │ │ │ │ -87 cl_mem _offsets; │ │ │ │ │ -88 cl_mem _indices; │ │ │ │ │ -89 cl_mem _weights; │ │ │ │ │ -90 cl_mem _duWeights; │ │ │ │ │ -91 cl_mem _dvWeights; │ │ │ │ │ -92 cl_mem _duuWeights; │ │ │ │ │ -93 cl_mem _duvWeights; │ │ │ │ │ -94 cl_mem _dvvWeights; │ │ │ │ │ -95 int _numStencils; │ │ │ │ │ -96}; │ │ │ │ │ -97 │ │ │ │ │ -98// -------------------------------------------------------------------------- │ │ │ │ │ -- │ │ │ │ │ -99 │ │ │ │ │ -_1_0_0class _C_L_E_v_a_l_u_a_t_o_r { │ │ │ │ │ -101public: │ │ │ │ │ -_1_0_2 typedef bool _I_n_s_t_a_n_t_i_a_t_a_b_l_e; │ │ │ │ │ -103 │ │ │ │ │ -105 template │ │ │ │ │ -_1_0_6 static _C_L_E_v_a_l_u_a_t_o_r *_C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -107 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -108 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -109 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -110 DEVICE_CONTEXT deviceContext) { │ │ │ │ │ -111 return _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -112 deviceContext->GetContext(), │ │ │ │ │ -113 deviceContext->GetCommandQueue()); │ │ │ │ │ -114 } │ │ │ │ │ -115 │ │ │ │ │ -_1_1_6 static _C_L_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -117 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -118 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -119 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -120 cl_context clContext, │ │ │ │ │ -121 cl_command_queue clCommandQueue) { │ │ │ │ │ -122 _C_L_E_v_a_l_u_a_t_o_r *instance = new _C_L_E_v_a_l_u_a_t_o_r(clContext, clCommandQueue); │ │ │ │ │ -123 if (instance->_C_o_m_p_i_l_e(srcDesc, dstDesc, duDesc, dvDesc)) │ │ │ │ │ -124 return instance; │ │ │ │ │ -125 delete instance; │ │ │ │ │ -126 return NULL; │ │ │ │ │ -127 } │ │ │ │ │ -128 │ │ │ │ │ -130 template │ │ │ │ │ -_1_3_1 static _C_L_E_v_a_l_u_a_t_o_r *_C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -132 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -133 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -134 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -135 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -136 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -137 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -138 DEVICE_CONTEXT deviceContext) { │ │ │ │ │ -139 return _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -140 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ -141 deviceContext->GetContext(), │ │ │ │ │ -142 deviceContext->GetCommandQueue()); │ │ │ │ │ -143 } │ │ │ │ │ -144 │ │ │ │ │ -_1_4_5 static _C_L_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -146 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -147 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -148 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -149 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -150 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -151 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -152 cl_context clContext, │ │ │ │ │ -153 cl_command_queue clCommandQueue) { │ │ │ │ │ -154 _C_L_E_v_a_l_u_a_t_o_r *instance = new _C_L_E_v_a_l_u_a_t_o_r(clContext, clCommandQueue); │ │ │ │ │ -155 if (instance->_C_o_m_p_i_l_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -156 duuDesc, duvDesc, dvvDesc)) │ │ │ │ │ -157 return instance; │ │ │ │ │ -158 delete instance; │ │ │ │ │ -159 return NULL; │ │ │ │ │ -160 } │ │ │ │ │ -161 │ │ │ │ │ -_1_6_3 _C_L_E_v_a_l_u_a_t_o_r(cl_context context, cl_command_queue queue); │ │ │ │ │ -164 │ │ │ │ │ -_1_6_6 _~_C_L_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ -167 │ │ │ │ │ -173 │ │ │ │ │ -217 template │ │ │ │ │ -_2_1_9 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -220 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -221 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -222 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -223 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -224 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -225 unsigned int numStartEvents=0, │ │ │ │ │ -226 const cl_event* startEvents=NULL, │ │ │ │ │ -227 cl_event* endEvent=NULL) { │ │ │ │ │ -228 │ │ │ │ │ -229 if (instance) { │ │ │ │ │ -230 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -231 dstBuffer, dstDesc, │ │ │ │ │ -232 stencilTable, │ │ │ │ │ -233 numStartEvents, startEvents, endEvent); │ │ │ │ │ -234 } else { │ │ │ │ │ -235 // Create an instance on demand (slow) │ │ │ │ │ -236 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -237 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -238 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -239 deviceContext); │ │ │ │ │ -240 if (instance) { │ │ │ │ │ -241 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -242 dstBuffer, dstDesc, │ │ │ │ │ -243 stencilTable, │ │ │ │ │ -244 numStartEvents, startEvents, endEvent); │ │ │ │ │ -245 delete instance; │ │ │ │ │ -246 return r; │ │ │ │ │ -247 } │ │ │ │ │ -248 return false; │ │ │ │ │ -249 } │ │ │ │ │ -250 } │ │ │ │ │ -251 │ │ │ │ │ -307 template │ │ │ │ │ -_3_0_9 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -310 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -311 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -312 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -313 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -314 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -315 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -316 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -317 unsigned int numStartEvents=0, │ │ │ │ │ -318 const cl_event* startEvents=NULL, │ │ │ │ │ -319 cl_event* endEvent=NULL) { │ │ │ │ │ -320 │ │ │ │ │ -321 if (instance) { │ │ │ │ │ -322 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -323 dstBuffer, dstDesc, │ │ │ │ │ -324 duBuffer, duDesc, │ │ │ │ │ -325 dvBuffer, dvDesc, │ │ │ │ │ -326 stencilTable, │ │ │ │ │ -327 numStartEvents, startEvents, endEvent); │ │ │ │ │ -328 } else { │ │ │ │ │ -329 // Create an instance on demand (slow) │ │ │ │ │ -330 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -331 deviceContext); │ │ │ │ │ -332 if (instance) { │ │ │ │ │ -333 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -334 dstBuffer, dstDesc, │ │ │ │ │ -335 duBuffer, duDesc, │ │ │ │ │ -336 dvBuffer, dvDesc, │ │ │ │ │ -337 stencilTable, │ │ │ │ │ -338 numStartEvents, startEvents, endEvent); │ │ │ │ │ -339 delete instance; │ │ │ │ │ -340 return r; │ │ │ │ │ -341 } │ │ │ │ │ -342 return false; │ │ │ │ │ -343 } │ │ │ │ │ -344 } │ │ │ │ │ -345 │ │ │ │ │ -419 template │ │ │ │ │ -_4_2_1 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -422 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -423 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -424 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -425 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -426 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -427 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -428 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -429 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -430 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -431 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -432 unsigned int numStartEvents=0, │ │ │ │ │ -433 const cl_event* startEvents=NULL, │ │ │ │ │ -434 cl_event* endEvent=NULL) { │ │ │ │ │ -435 │ │ │ │ │ -436 if (instance) { │ │ │ │ │ -437 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -438 dstBuffer, dstDesc, │ │ │ │ │ -439 duBuffer, duDesc, │ │ │ │ │ -440 dvBuffer, dvDesc, │ │ │ │ │ -441 duuBuffer, duuDesc, │ │ │ │ │ -442 duvBuffer, duvDesc, │ │ │ │ │ -443 dvvBuffer, dvvDesc, │ │ │ │ │ -444 stencilTable, │ │ │ │ │ -445 numStartEvents, startEvents, endEvent); │ │ │ │ │ -446 } else { │ │ │ │ │ -447 // Create an instance on demand (slow) │ │ │ │ │ -448 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -449 duDesc, dvDesc, │ │ │ │ │ -450 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ -451 deviceContext); │ │ │ │ │ -452 if (instance) { │ │ │ │ │ -453 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -454 dstBuffer, dstDesc, │ │ │ │ │ -455 duBuffer, duDesc, │ │ │ │ │ -456 dvBuffer, dvDesc, │ │ │ │ │ -457 duuBuffer, duuDesc, │ │ │ │ │ -458 duvBuffer, duvDesc, │ │ │ │ │ -459 dvvBuffer, dvvDesc, │ │ │ │ │ -460 stencilTable, │ │ │ │ │ -461 numStartEvents, startEvents, endEvent); │ │ │ │ │ -462 delete instance; │ │ │ │ │ -463 return r; │ │ │ │ │ -464 } │ │ │ │ │ -465 return false; │ │ │ │ │ -466 } │ │ │ │ │ -467 } │ │ │ │ │ -468 │ │ │ │ │ -499 template │ │ │ │ │ -_5_0_0 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -501 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -502 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -503 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -504 unsigned int numStartEvents=0, │ │ │ │ │ -505 const cl_event* startEvents=NULL, │ │ │ │ │ -506 cl_event* endEvent=NULL) const { │ │ │ │ │ -507 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -508 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -509 stencilTable->GetSizesBuffer(), │ │ │ │ │ -510 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ -511 stencilTable->GetIndicesBuffer(), │ │ │ │ │ -512 stencilTable->GetWeightsBuffer(), │ │ │ │ │ -513 0, │ │ │ │ │ -514 stencilTable->GetNumStencils(), │ │ │ │ │ -515 numStartEvents, startEvents, endEvent); │ │ │ │ │ -516 } │ │ │ │ │ -517 │ │ │ │ │ -560 template │ │ │ │ │ -_5_6_1 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -562 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -563 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -564 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -565 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -566 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -567 unsigned int numStartEvents=0, │ │ │ │ │ -568 const cl_event* startEvents=NULL, │ │ │ │ │ -569 cl_event* endEvent=NULL) const { │ │ │ │ │ -570 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -571 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -572 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -573 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -574 stencilTable->GetSizesBuffer(), │ │ │ │ │ -575 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ -576 stencilTable->GetIndicesBuffer(), │ │ │ │ │ -577 stencilTable->GetWeightsBuffer(), │ │ │ │ │ -578 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ -579 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ -580 0, │ │ │ │ │ -581 stencilTable->GetNumStencils(), │ │ │ │ │ -582 numStartEvents, startEvents, endEvent); │ │ │ │ │ -583 } │ │ │ │ │ -584 │ │ │ │ │ -645 template │ │ │ │ │ -_6_4_6 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -647 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -648 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -649 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -650 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -651 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -652 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -653 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -654 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -655 unsigned int numStartEvents=0, │ │ │ │ │ -656 const cl_event* startEvents=NULL, │ │ │ │ │ -657 cl_event* endEvent=NULL) const { │ │ │ │ │ -658 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -659 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -660 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -661 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -662 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ -663 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ -664 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ -665 stencilTable->GetSizesBuffer(), │ │ │ │ │ -666 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ -667 stencilTable->GetIndicesBuffer(), │ │ │ │ │ -668 stencilTable->GetWeightsBuffer(), │ │ │ │ │ -669 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ -670 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ -671 stencilTable->GetDuuWeightsBuffer(), │ │ │ │ │ -672 stencilTable->GetDuvWeightsBuffer(), │ │ │ │ │ -673 stencilTable->GetDvvWeightsBuffer(), │ │ │ │ │ -674 0, │ │ │ │ │ -675 stencilTable->GetNumStencils(), │ │ │ │ │ -676 numStartEvents, startEvents, endEvent); │ │ │ │ │ -677 } │ │ │ │ │ -678 │ │ │ │ │ -_6_8_1 bool _E_v_a_l_S_t_e_n_c_i_l_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -682 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -683 cl_mem sizes, │ │ │ │ │ -684 cl_mem offsets, │ │ │ │ │ -685 cl_mem indices, │ │ │ │ │ -686 cl_mem weights, │ │ │ │ │ -687 int start, │ │ │ │ │ -688 int end, │ │ │ │ │ -689 unsigned int numStartEvents=0, │ │ │ │ │ -690 const cl_event* startEvents=NULL, │ │ │ │ │ -691 cl_event* endEvent=NULL) const; │ │ │ │ │ -692 │ │ │ │ │ -_7_4_1 bool _E_v_a_l_S_t_e_n_c_i_l_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -742 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -743 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -744 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -745 cl_mem sizes, │ │ │ │ │ -746 cl_mem offsets, │ │ │ │ │ -747 cl_mem indices, │ │ │ │ │ -748 cl_mem weights, │ │ │ │ │ -749 cl_mem duWeights, │ │ │ │ │ -750 cl_mem dvWeights, │ │ │ │ │ -751 int start, │ │ │ │ │ -752 int end, │ │ │ │ │ -753 unsigned int numStartEvents=0, │ │ │ │ │ -754 const cl_event* startEvents=NULL, │ │ │ │ │ -755 cl_event* endEvent=NULL) const; │ │ │ │ │ -756 │ │ │ │ │ -_8_2_3 bool _E_v_a_l_S_t_e_n_c_i_l_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -824 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -825 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -826 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -827 cl_mem duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -828 cl_mem duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -829 cl_mem dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -830 cl_mem sizes, │ │ │ │ │ -831 cl_mem offsets, │ │ │ │ │ -832 cl_mem indices, │ │ │ │ │ -833 cl_mem weights, │ │ │ │ │ -834 cl_mem duWeights, │ │ │ │ │ -835 cl_mem dvWeights, │ │ │ │ │ -836 cl_mem duuWeights, │ │ │ │ │ -837 cl_mem duvWeights, │ │ │ │ │ -838 cl_mem dvvWeights, │ │ │ │ │ -839 int start, │ │ │ │ │ -840 int end, │ │ │ │ │ -841 unsigned int numStartEvents=0, │ │ │ │ │ -842 const cl_event* startEvents=NULL, │ │ │ │ │ -843 cl_event* endEvent=NULL) const; │ │ │ │ │ -844 │ │ │ │ │ -850 │ │ │ │ │ -899 template │ │ │ │ │ -_9_0_2 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -903 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -904 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -905 int numPatchCoords, │ │ │ │ │ -906 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -907 PATCH_TABLE *patchTable, │ │ │ │ │ -908 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -909 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -910 unsigned int numStartEvents=0, │ │ │ │ │ -911 const cl_event* startEvents=NULL, │ │ │ │ │ -912 cl_event* endEvent=NULL) { │ │ │ │ │ -913 │ │ │ │ │ -914 if (instance) { │ │ │ │ │ -915 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -916 dstBuffer, dstDesc, │ │ │ │ │ -917 numPatchCoords, patchCoords, │ │ │ │ │ -918 patchTable, │ │ │ │ │ -919 numStartEvents, startEvents, endEvent); │ │ │ │ │ -920 } else { │ │ │ │ │ -921 // Create an instance on demand (slow) │ │ │ │ │ -922 (void)deviceContext; // unused │ │ │ │ │ -923 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -924 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -925 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -926 deviceContext); │ │ │ │ │ -927 if (instance) { │ │ │ │ │ -928 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -929 dstBuffer, dstDesc, │ │ │ │ │ -930 numPatchCoords, patchCoords, │ │ │ │ │ -931 patchTable, │ │ │ │ │ -932 numStartEvents, startEvents, endEvent); │ │ │ │ │ -933 delete instance; │ │ │ │ │ -934 return r; │ │ │ │ │ -935 } │ │ │ │ │ -936 return false; │ │ │ │ │ -937 } │ │ │ │ │ -938 } │ │ │ │ │ -939 │ │ │ │ │ -1000 template │ │ │ │ │ -_1_0_0_3 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -1004 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1005 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1006 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1007 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1008 int numPatchCoords, │ │ │ │ │ -1009 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1010 PATCH_TABLE *patchTable, │ │ │ │ │ -1011 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1012 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -1013 unsigned int numStartEvents=0, │ │ │ │ │ -1014 const cl_event* startEvents=NULL, │ │ │ │ │ -1015 cl_event* endEvent=NULL) { │ │ │ │ │ -1016 │ │ │ │ │ -1017 if (instance) { │ │ │ │ │ -1018 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -1019 dstBuffer, dstDesc, │ │ │ │ │ -1020 duBuffer, duDesc, │ │ │ │ │ -1021 dvBuffer, dvDesc, │ │ │ │ │ -1022 numPatchCoords, patchCoords, │ │ │ │ │ -1023 patchTable, │ │ │ │ │ -1024 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1025 } else { │ │ │ │ │ -1026 // Create an instance on demand (slow) │ │ │ │ │ -1027 (void)deviceContext; // unused │ │ │ │ │ -1028 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, deviceContext); │ │ │ │ │ -1029 if (instance) { │ │ │ │ │ -1030 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -1031 dstBuffer, dstDesc, │ │ │ │ │ -1032 duBuffer, duDesc, │ │ │ │ │ -1033 dvBuffer, dvDesc, │ │ │ │ │ -1034 numPatchCoords, patchCoords, │ │ │ │ │ -1035 patchTable, │ │ │ │ │ -1036 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1037 delete instance; │ │ │ │ │ -1038 return r; │ │ │ │ │ -1039 } │ │ │ │ │ -1040 return false; │ │ │ │ │ -1041 } │ │ │ │ │ -1042 } │ │ │ │ │ -1043 │ │ │ │ │ -1122 template │ │ │ │ │ -_1_1_2_5 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -1126 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1127 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1128 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1129 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1130 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1131 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1132 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1133 int numPatchCoords, │ │ │ │ │ -1134 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1135 PATCH_TABLE *patchTable, │ │ │ │ │ -1136 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1137 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -1138 unsigned int numStartEvents=0, │ │ │ │ │ -1139 const cl_event* startEvents=NULL, │ │ │ │ │ -1140 cl_event* endEvent=NULL) { │ │ │ │ │ -1141 │ │ │ │ │ -1142 if (instance) { │ │ │ │ │ -1143 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -1144 dstBuffer, dstDesc, │ │ │ │ │ -1145 duBuffer, duDesc, │ │ │ │ │ -1146 dvBuffer, dvDesc, │ │ │ │ │ -1147 duuBuffer, duuDesc, │ │ │ │ │ -1148 duvBuffer, duvDesc, │ │ │ │ │ -1149 dvvBuffer, dvvDesc, │ │ │ │ │ -1150 numPatchCoords, patchCoords, │ │ │ │ │ -1151 patchTable, │ │ │ │ │ -1152 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1153 } else { │ │ │ │ │ -1154 // Create an instance on demand (slow) │ │ │ │ │ -1155 (void)deviceContext; // unused │ │ │ │ │ -1156 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1157 duDesc, dvDesc, │ │ │ │ │ -1158 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ -1159 deviceContext); │ │ │ │ │ -1160 if (instance) { │ │ │ │ │ -1161 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -1162 dstBuffer, dstDesc, │ │ │ │ │ -1163 duBuffer, duDesc, │ │ │ │ │ -1164 dvBuffer, dvDesc, │ │ │ │ │ -1165 duuBuffer, duuDesc, │ │ │ │ │ -1166 duvBuffer, duvDesc, │ │ │ │ │ -1167 dvvBuffer, dvvDesc, │ │ │ │ │ -1168 numPatchCoords, patchCoords, │ │ │ │ │ -1169 patchTable, │ │ │ │ │ -1170 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1171 delete instance; │ │ │ │ │ -1172 return r; │ │ │ │ │ -1173 } │ │ │ │ │ -1174 return false; │ │ │ │ │ -1175 } │ │ │ │ │ -1176 } │ │ │ │ │ -1177 │ │ │ │ │ -1215 template │ │ │ │ │ -_1_2_1_7 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -1218 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1219 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1220 int numPatchCoords, │ │ │ │ │ -1221 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1222 PATCH_TABLE *patchTable, │ │ │ │ │ -1223 unsigned int numStartEvents=0, │ │ │ │ │ -1224 const cl_event* startEvents=NULL, │ │ │ │ │ -1225 cl_event* endEvent=NULL) const { │ │ │ │ │ -1226 │ │ │ │ │ -1227 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -1228 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -1229 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1230 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1231 numPatchCoords, │ │ │ │ │ -1232 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -1233 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ -1234 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -1235 patchTable->GetPatchParamBuffer(), │ │ │ │ │ -1236 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1237 } │ │ │ │ │ -1238 │ │ │ │ │ -1286 template │ │ │ │ │ -_1_2_8_8 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -1289 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1290 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1291 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1292 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1293 int numPatchCoords, │ │ │ │ │ -1294 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1295 PATCH_TABLE *patchTable, │ │ │ │ │ -1296 unsigned int numStartEvents=0, │ │ │ │ │ -1297 const cl_event* startEvents=NULL, │ │ │ │ │ -1298 cl_event* endEvent=NULL) const { │ │ │ │ │ -1299 │ │ │ │ │ -1300 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -1301 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -1302 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -1303 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -1304 numPatchCoords, │ │ │ │ │ -1305 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -1306 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ -1307 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -1308 patchTable->GetPatchParamBuffer(), │ │ │ │ │ -1309 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1310 } │ │ │ │ │ -1311 │ │ │ │ │ -1377 template │ │ │ │ │ -_1_3_7_9 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -1380 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1381 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1382 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1383 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1384 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1385 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1386 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1387 int numPatchCoords, │ │ │ │ │ -1388 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1389 PATCH_TABLE *patchTable, │ │ │ │ │ -1390 unsigned int numStartEvents=0, │ │ │ │ │ -1391 const cl_event* startEvents=NULL, │ │ │ │ │ -1392 cl_event* endEvent=NULL) const { │ │ │ │ │ -1393 │ │ │ │ │ -1394 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -1395 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -1396 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -1397 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -1398 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ -1399 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ -1400 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ -1401 numPatchCoords, │ │ │ │ │ -1402 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -1403 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ -1404 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -1405 patchTable->GetPatchParamBuffer(), │ │ │ │ │ -1406 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1407 } │ │ │ │ │ -1408 │ │ │ │ │ -_1_4_0_9 bool _E_v_a_l_P_a_t_c_h_e_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1410 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1411 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1412 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1413 int numPatchCoords, │ │ │ │ │ -1414 cl_mem patchCoordsBuffer, │ │ │ │ │ -1415 cl_mem patchArrayBuffer, │ │ │ │ │ -1416 cl_mem patchIndexBuffer, │ │ │ │ │ -1417 cl_mem patchParamsBuffer, │ │ │ │ │ -1418 unsigned int numStartEvents=0, │ │ │ │ │ -1419 const cl_event* startEvents=NULL, │ │ │ │ │ -1420 cl_event* endEvent=NULL) const; │ │ │ │ │ -1421 │ │ │ │ │ -_1_4_2_2 bool _E_v_a_l_P_a_t_c_h_e_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1423 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1424 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1425 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1426 cl_mem duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1427 cl_mem duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1428 cl_mem dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1429 int numPatchCoords, │ │ │ │ │ -1430 cl_mem patchCoordsBuffer, │ │ │ │ │ -1431 cl_mem patchArrayBuffer, │ │ │ │ │ -1432 cl_mem patchIndexBuffer, │ │ │ │ │ -1433 cl_mem patchParamsBuffer, │ │ │ │ │ -1434 unsigned int numStartEvents=0, │ │ │ │ │ -1435 const cl_event* startEvents=NULL, │ │ │ │ │ -1436 cl_event* endEvent=NULL) const; │ │ │ │ │ -1437 │ │ │ │ │ -1486 template │ │ │ │ │ -_1_4_8_9 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1490 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1491 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1492 int numPatchCoords, │ │ │ │ │ -1493 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1494 PATCH_TABLE *patchTable, │ │ │ │ │ -1495 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1496 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -1497 unsigned int numStartEvents=0, │ │ │ │ │ -1498 const cl_event* startEvents=NULL, │ │ │ │ │ -1499 cl_event* endEvent=NULL) { │ │ │ │ │ -1500 │ │ │ │ │ -1501 if (instance) { │ │ │ │ │ -1502 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1503 srcBuffer, srcDesc, │ │ │ │ │ -1504 dstBuffer, dstDesc, │ │ │ │ │ -1505 numPatchCoords, patchCoords, │ │ │ │ │ -1506 patchTable, │ │ │ │ │ -1507 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1508 } else { │ │ │ │ │ -1509 // Create an instance on demand (slow) │ │ │ │ │ -1510 (void)deviceContext; // unused │ │ │ │ │ -1511 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1512 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1513 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1514 deviceContext); │ │ │ │ │ -1515 if (instance) { │ │ │ │ │ -1516 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1517 srcBuffer, srcDesc, │ │ │ │ │ -1518 dstBuffer, dstDesc, │ │ │ │ │ -1519 numPatchCoords, patchCoords, │ │ │ │ │ -1520 patchTable, │ │ │ │ │ -1521 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1522 delete instance; │ │ │ │ │ -1523 return r; │ │ │ │ │ -1524 } │ │ │ │ │ -1525 return false; │ │ │ │ │ -1526 } │ │ │ │ │ -1527 } │ │ │ │ │ -1528 │ │ │ │ │ -1566 template │ │ │ │ │ -_1_5_6_8 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1569 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1570 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1571 int numPatchCoords, │ │ │ │ │ -1572 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1573 PATCH_TABLE *patchTable, │ │ │ │ │ -1574 unsigned int numStartEvents=0, │ │ │ │ │ -1575 const cl_event* startEvents=NULL, │ │ │ │ │ -1576 cl_event* endEvent=NULL) const { │ │ │ │ │ -1577 │ │ │ │ │ -1578 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -1579 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -1580 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1581 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1582 numPatchCoords, │ │ │ │ │ -1583 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -1584 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ -1585 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -1586 patchTable->GetPatchParamBuffer(), │ │ │ │ │ -1587 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1588 } │ │ │ │ │ -1589 │ │ │ │ │ -1650 template │ │ │ │ │ -_1_6_5_3 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1654 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1655 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1656 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1657 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1658 int numPatchCoords, │ │ │ │ │ -1659 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1660 PATCH_TABLE *patchTable, │ │ │ │ │ -1661 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1662 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -1663 unsigned int numStartEvents=0, │ │ │ │ │ -1664 const cl_event* startEvents=NULL, │ │ │ │ │ -1665 cl_event* endEvent=NULL) { │ │ │ │ │ -1666 │ │ │ │ │ -1667 if (instance) { │ │ │ │ │ -1668 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1669 srcBuffer, srcDesc, │ │ │ │ │ -1670 dstBuffer, dstDesc, │ │ │ │ │ -1671 duBuffer, duDesc, │ │ │ │ │ -1672 dvBuffer, dvDesc, │ │ │ │ │ -1673 numPatchCoords, patchCoords, │ │ │ │ │ -1674 patchTable, │ │ │ │ │ -1675 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1676 } else { │ │ │ │ │ -1677 // Create an instance on demand (slow) │ │ │ │ │ -1678 (void)deviceContext; // unused │ │ │ │ │ -1679 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1680 duDesc, dvDesc, │ │ │ │ │ -1681 deviceContext); │ │ │ │ │ -1682 if (instance) { │ │ │ │ │ -1683 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1684 srcBuffer, srcDesc, │ │ │ │ │ -1685 dstBuffer, dstDesc, │ │ │ │ │ -1686 duBuffer, duDesc, │ │ │ │ │ -1687 dvBuffer, dvDesc, │ │ │ │ │ -1688 numPatchCoords, patchCoords, │ │ │ │ │ -1689 patchTable, │ │ │ │ │ -1690 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1691 delete instance; │ │ │ │ │ -1692 return r; │ │ │ │ │ -1693 } │ │ │ │ │ -1694 return false; │ │ │ │ │ -1695 } │ │ │ │ │ -1696 } │ │ │ │ │ -1697 │ │ │ │ │ -1747 template │ │ │ │ │ -_1_7_4_9 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1750 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1751 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1752 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1753 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1754 int numPatchCoords, │ │ │ │ │ -1755 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1756 PATCH_TABLE *patchTable, │ │ │ │ │ -1757 unsigned int numStartEvents=0, │ │ │ │ │ -1758 const cl_event* startEvents=NULL, │ │ │ │ │ -1759 cl_event* endEvent=NULL) const { │ │ │ │ │ -1760 │ │ │ │ │ -1761 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -1762 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -1763 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -1764 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -1765 numPatchCoords, │ │ │ │ │ -1766 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -1767 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ -1768 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -1769 patchTable->GetPatchParamBuffer(), │ │ │ │ │ -1770 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1771 } │ │ │ │ │ -1772 │ │ │ │ │ -1851 template │ │ │ │ │ -_1_8_5_4 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1855 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1856 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1857 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1858 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1859 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1860 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1861 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1862 int numPatchCoords, │ │ │ │ │ -1863 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1864 PATCH_TABLE *patchTable, │ │ │ │ │ -1865 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1866 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -1867 unsigned int numStartEvents=0, │ │ │ │ │ -1868 const cl_event* startEvents=NULL, │ │ │ │ │ -1869 cl_event* endEvent=NULL) { │ │ │ │ │ -1870 │ │ │ │ │ -1871 if (instance) { │ │ │ │ │ -1872 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1873 srcBuffer, srcDesc, │ │ │ │ │ -1874 dstBuffer, dstDesc, │ │ │ │ │ -1875 duBuffer, duDesc, │ │ │ │ │ -1876 dvBuffer, dvDesc, │ │ │ │ │ -1877 duuBuffer, duuDesc, │ │ │ │ │ -1878 duvBuffer, duvDesc, │ │ │ │ │ -1879 dvvBuffer, dvvDesc, │ │ │ │ │ -1880 numPatchCoords, patchCoords, │ │ │ │ │ -1881 patchTable, │ │ │ │ │ -1882 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1883 } else { │ │ │ │ │ -1884 // Create an instance on demand (slow) │ │ │ │ │ -1885 (void)deviceContext; // unused │ │ │ │ │ -1886 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1887 duDesc, dvDesc, │ │ │ │ │ -1888 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ -1889 deviceContext); │ │ │ │ │ -1890 if (instance) { │ │ │ │ │ -1891 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1892 srcBuffer, srcDesc, │ │ │ │ │ -1893 dstBuffer, dstDesc, │ │ │ │ │ -1894 duBuffer, duDesc, │ │ │ │ │ -1895 dvBuffer, dvDesc, │ │ │ │ │ -1896 duuBuffer, duuDesc, │ │ │ │ │ -1897 duvBuffer, duvDesc, │ │ │ │ │ -1898 dvvBuffer, dvvDesc, │ │ │ │ │ -1899 numPatchCoords, patchCoords, │ │ │ │ │ -1900 patchTable, │ │ │ │ │ -1901 numStartEvents, startEvents, endEvent); │ │ │ │ │ -1902 delete instance; │ │ │ │ │ -1903 return r; │ │ │ │ │ -1904 } │ │ │ │ │ -1905 return false; │ │ │ │ │ -1906 } │ │ │ │ │ -1907 } │ │ │ │ │ -1908 │ │ │ │ │ -1976 template │ │ │ │ │ -_1_9_7_8 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1979 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1980 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1981 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1982 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1983 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1984 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1985 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1986 int numPatchCoords, │ │ │ │ │ -1987 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1988 PATCH_TABLE *patchTable, │ │ │ │ │ -1989 unsigned int numStartEvents=0, │ │ │ │ │ -1990 const cl_event* startEvents=NULL, │ │ │ │ │ -1991 cl_event* endEvent=NULL) const { │ │ │ │ │ -1992 │ │ │ │ │ -1993 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -1994 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -1995 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -1996 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -1997 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ -1998 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ -1999 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ -2000 numPatchCoords, │ │ │ │ │ -2001 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -2002 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ -2003 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -2004 patchTable->GetPatchParamBuffer(), │ │ │ │ │ -2005 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2006 } │ │ │ │ │ -2007 │ │ │ │ │ -2058 template │ │ │ │ │ -_2_0_6_1 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2062 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2063 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2064 int numPatchCoords, │ │ │ │ │ -2065 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2066 PATCH_TABLE *patchTable, │ │ │ │ │ -2067 int fvarChannel, │ │ │ │ │ -2068 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -2069 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -2070 unsigned int numStartEvents=0, │ │ │ │ │ -2071 const cl_event* startEvents=NULL, │ │ │ │ │ -2072 cl_event* endEvent=NULL) { │ │ │ │ │ -2073 │ │ │ │ │ -2074 if (instance) { │ │ │ │ │ -2075 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2076 srcBuffer, srcDesc, │ │ │ │ │ -2077 dstBuffer, dstDesc, │ │ │ │ │ -2078 numPatchCoords, patchCoords, │ │ │ │ │ -2079 patchTable, fvarChannel, │ │ │ │ │ -2080 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2081 } else { │ │ │ │ │ -2082 // Create an instance on demand (slow) │ │ │ │ │ -2083 (void)deviceContext; // unused │ │ │ │ │ -2084 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -2085 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2086 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2087 deviceContext); │ │ │ │ │ -2088 if (instance) { │ │ │ │ │ -2089 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2090 srcBuffer, srcDesc, │ │ │ │ │ -2091 dstBuffer, dstDesc, │ │ │ │ │ -2092 numPatchCoords, patchCoords, │ │ │ │ │ -2093 patchTable, fvarChannel, │ │ │ │ │ -2094 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2095 delete instance; │ │ │ │ │ -2096 return r; │ │ │ │ │ -2097 } │ │ │ │ │ -2098 return false; │ │ │ │ │ -2099 } │ │ │ │ │ -2100 } │ │ │ │ │ -2101 │ │ │ │ │ -2141 template │ │ │ │ │ -_2_1_4_3 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2144 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2145 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2146 int numPatchCoords, │ │ │ │ │ -2147 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2148 PATCH_TABLE *patchTable, │ │ │ │ │ -2149 int fvarChannel = 0, │ │ │ │ │ -2150 unsigned int numStartEvents=0, │ │ │ │ │ -2151 const cl_event* startEvents=NULL, │ │ │ │ │ -2152 cl_event* endEvent=NULL) const { │ │ │ │ │ -2153 │ │ │ │ │ -2154 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -2155 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -2156 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2157 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2158 numPatchCoords, │ │ │ │ │ -2159 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -2160 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ -2161 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -2162 patchTable->GetFVarPatchParamBuffer(fvarChannel), │ │ │ │ │ -2163 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2164 } │ │ │ │ │ -2165 │ │ │ │ │ -2228 template │ │ │ │ │ -_2_2_3_1 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2232 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2233 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2234 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2235 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2236 int numPatchCoords, │ │ │ │ │ -2237 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2238 PATCH_TABLE *patchTable, │ │ │ │ │ -2239 int fvarChannel, │ │ │ │ │ -2240 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -2241 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -2242 unsigned int numStartEvents=0, │ │ │ │ │ -2243 const cl_event* startEvents=NULL, │ │ │ │ │ -2244 cl_event* endEvent=NULL) { │ │ │ │ │ -2245 │ │ │ │ │ -2246 if (instance) { │ │ │ │ │ -2247 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2248 srcBuffer, srcDesc, │ │ │ │ │ -2249 dstBuffer, dstDesc, │ │ │ │ │ -2250 duBuffer, duDesc, │ │ │ │ │ -2251 dvBuffer, dvDesc, │ │ │ │ │ -2252 numPatchCoords, patchCoords, │ │ │ │ │ -2253 patchTable, fvarChannel, │ │ │ │ │ -2254 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2255 } else { │ │ │ │ │ -2256 // Create an instance on demand (slow) │ │ │ │ │ -2257 (void)deviceContext; // unused │ │ │ │ │ -2258 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -2259 duDesc, dvDesc, deviceContext); │ │ │ │ │ -2260 if (instance) { │ │ │ │ │ -2261 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2262 srcBuffer, srcDesc, │ │ │ │ │ -2263 dstBuffer, dstDesc, │ │ │ │ │ -2264 duBuffer, duDesc, │ │ │ │ │ -2265 dvBuffer, dvDesc, │ │ │ │ │ -2266 numPatchCoords, patchCoords, │ │ │ │ │ -2267 patchTable, fvarChannel, │ │ │ │ │ -2268 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2269 delete instance; │ │ │ │ │ -2270 return r; │ │ │ │ │ -2271 } │ │ │ │ │ -2272 return false; │ │ │ │ │ -2273 } │ │ │ │ │ -2274 } │ │ │ │ │ -2275 │ │ │ │ │ -2327 template │ │ │ │ │ -_2_3_2_9 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2330 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2331 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2332 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2333 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2334 int numPatchCoords, │ │ │ │ │ -2335 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2336 PATCH_TABLE *patchTable, │ │ │ │ │ -2337 int fvarChannel = 0, │ │ │ │ │ -2338 unsigned int numStartEvents=0, │ │ │ │ │ -2339 const cl_event* startEvents=NULL, │ │ │ │ │ -2340 cl_event* endEvent=NULL) const { │ │ │ │ │ -2341 │ │ │ │ │ -2342 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -2343 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -2344 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -2345 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -2346 numPatchCoords, │ │ │ │ │ -2347 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -2348 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ -2349 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -2350 patchTable->GetFVarPatchParamBuffer(fvarChannel), │ │ │ │ │ -2351 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2352 } │ │ │ │ │ -2353 │ │ │ │ │ -2434 template │ │ │ │ │ -_2_4_3_7 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2438 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2439 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2440 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2441 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2442 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -2443 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -2444 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -2445 int numPatchCoords, │ │ │ │ │ -2446 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2447 PATCH_TABLE *patchTable, │ │ │ │ │ -2448 int fvarChannel, │ │ │ │ │ -2449 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -2450 DEVICE_CONTEXT deviceContext, │ │ │ │ │ -2451 unsigned int numStartEvents=0, │ │ │ │ │ -2452 const cl_event* startEvents=NULL, │ │ │ │ │ -2453 cl_event* endEvent=NULL) { │ │ │ │ │ -2454 │ │ │ │ │ -2455 if (instance) { │ │ │ │ │ -2456 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2457 srcBuffer, srcDesc, │ │ │ │ │ -2458 dstBuffer, dstDesc, │ │ │ │ │ -2459 duBuffer, duDesc, │ │ │ │ │ -2460 dvBuffer, dvDesc, │ │ │ │ │ -2461 duuBuffer, duuDesc, │ │ │ │ │ -2462 duvBuffer, duvDesc, │ │ │ │ │ -2463 dvvBuffer, dvvDesc, │ │ │ │ │ -2464 numPatchCoords, patchCoords, │ │ │ │ │ -2465 patchTable, fvarChannel, │ │ │ │ │ -2466 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2467 } else { │ │ │ │ │ -2468 // Create an instance on demand (slow) │ │ │ │ │ -2469 (void)deviceContext; // unused │ │ │ │ │ -2470 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -2471 duDesc, dvDesc, │ │ │ │ │ -2472 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ -2473 deviceContext); │ │ │ │ │ -2474 if (instance) { │ │ │ │ │ -2475 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2476 srcBuffer, srcDesc, │ │ │ │ │ -2477 dstBuffer, dstDesc, │ │ │ │ │ -2478 duBuffer, duDesc, │ │ │ │ │ -2479 dvBuffer, dvDesc, │ │ │ │ │ -2480 duuBuffer, duuDesc, │ │ │ │ │ -2481 duvBuffer, duvDesc, │ │ │ │ │ -2482 dvvBuffer, dvvDesc, │ │ │ │ │ -2483 numPatchCoords, patchCoords, │ │ │ │ │ -2484 patchTable, fvarChannel, │ │ │ │ │ -2485 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2486 delete instance; │ │ │ │ │ -2487 return r; │ │ │ │ │ -2488 } │ │ │ │ │ -2489 return false; │ │ │ │ │ -2490 } │ │ │ │ │ -2491 } │ │ │ │ │ -2492 │ │ │ │ │ -2562 template │ │ │ │ │ -_2_5_6_4 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2565 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2566 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2567 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2568 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2569 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -2570 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -2571 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -2572 int numPatchCoords, │ │ │ │ │ -2573 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2574 PATCH_TABLE *patchTable, │ │ │ │ │ -2575 int fvarChannel = 0, │ │ │ │ │ -2576 unsigned int numStartEvents=0, │ │ │ │ │ -2577 const cl_event* startEvents=NULL, │ │ │ │ │ -2578 cl_event* endEvent=NULL) const { │ │ │ │ │ -2579 │ │ │ │ │ -2580 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ -2581 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ -2582 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ -2583 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ -2584 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ -2585 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ -2586 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ -2587 numPatchCoords, │ │ │ │ │ -2588 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ -2589 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ -2590 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -2591 patchTable->GetFVarPatchParamBuffer(fvarChannel), │ │ │ │ │ -2592 numStartEvents, startEvents, endEvent); │ │ │ │ │ -2593 } │ │ │ │ │ -2594 │ │ │ │ │ -2600 │ │ │ │ │ -_2_6_0_3 bool _C_o_m_p_i_l_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2604 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2605 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2606 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2607 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2608 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2609 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ -2610 │ │ │ │ │ -2612 template │ │ │ │ │ -_2_6_1_3 static void _S_y_n_c_h_r_o_n_i_z_e(DEVICE_CONTEXT deviceContext) { │ │ │ │ │ -2614 _S_y_n_c_h_r_o_n_i_z_e(deviceContext->GetCommandQueue()); │ │ │ │ │ -2615 } │ │ │ │ │ -2616 │ │ │ │ │ -_2_6_1_7 static void _S_y_n_c_h_r_o_n_i_z_e(cl_command_queue queue); │ │ │ │ │ -2618 │ │ │ │ │ -2619private: │ │ │ │ │ -2620 cl_context _clContext; │ │ │ │ │ -2621 cl_command_queue _clCommandQueue; │ │ │ │ │ -2622 cl_program _program; │ │ │ │ │ -2623 cl_kernel _stencilKernel; │ │ │ │ │ -2624 cl_kernel _stencilDerivKernel; │ │ │ │ │ -2625 cl_kernel _patchKernel; │ │ │ │ │ -2626}; │ │ │ │ │ -2627 │ │ │ │ │ -2628} // end namespace Osd │ │ │ │ │ -2629 │ │ │ │ │ -2630} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -2631using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -2632 │ │ │ │ │ -2633} // end namespace OpenSubdiv │ │ │ │ │ -2634 │ │ │ │ │ -2635 │ │ │ │ │ -2636#endif // OPENSUBDIV3_OSD_CL_EVALUATOR_H │ │ │ │ │ +30#include │ │ │ │ │ +31 │ │ │ │ │ +32@protocol MTLDevice; │ │ │ │ │ +33@protocol MTLCommandQueue; │ │ │ │ │ +34 │ │ │ │ │ +35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +36namespace OPENSUBDIV_VERSION { │ │ │ │ │ +37 │ │ │ │ │ +38namespace Osd { │ │ │ │ │ +39 │ │ │ │ │ +_4_0class _M_T_L_C_o_n_t_e_x_t { │ │ │ │ │ +41public: │ │ │ │ │ +_4_2 id _d_e_v_i_c_e = nullptr; │ │ │ │ │ +_4_3 id _c_o_m_m_a_n_d_Q_u_e_u_e = nullptr; │ │ │ │ │ +44}; │ │ │ │ │ +45 │ │ │ │ │ +46} // end namespace Osd │ │ │ │ │ +47 │ │ │ │ │ +48} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +49using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +50 │ │ │ │ │ +51} // end namespace OpenSubdiv │ │ │ │ │ +52 │ │ │ │ │ +53#endif //OPENSUBDIV3_OSD_MTL_COMMON_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ -data buffers.... │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -OpenCL stencil table. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetDvvWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -CLStencilTable(Far::StencilTable const *stencilTable, cl_context clContext) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetOffsetsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static CLStencilTable * Create(Far::LimitStencilTable const *limitStencilTable, │ │ │ │ │ -DEVICE_CONTEXT context) │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetIndicesBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ -int GetNumStencils() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_S_i_z_e_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetSizesBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetDuuWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetDvWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetDuvWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetDuWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_~_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -~CLStencilTable() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static CLStencilTable * Create(Far::StencilTable const *stencilTable, │ │ │ │ │ -DEVICE_CONTEXT context) │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -CLStencilTable(Far::LimitStencilTable const *limitStencilTable, cl_context │ │ │ │ │ -clContext) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -cl_mem GetWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, CLEvaluator │ │ │ │ │ -const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, │ │ │ │ │ -const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic static stencil function. This function has a same signature as other │ │ │ │ │ -device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_3_0_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ -static void Synchronize(cl_command_queue queue) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_~_C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ -~CLEvaluator() │ │ │ │ │ -Destructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ -BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ -cl_mem dv, BufferDescriptor const &dvDesc, cl_mem sizes, cl_mem offsets, cl_mem │ │ │ │ │ -indices, cl_mem weights, cl_mem duWeights, cl_mem dvWeights, int start, int │ │ │ │ │ -end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) const │ │ │ │ │ -Dispatch the CL compute kernel asynchronously. returns false if the kernel │ │ │ │ │ -hasn't been compiled yet. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ -const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, │ │ │ │ │ -unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) │ │ │ │ │ -Generic static stencil function. This function has a same signature as other │ │ │ │ │ -device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_1_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ -const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ -cl_context clContext, cl_command_queue clCommandQueue) │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ -DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const │ │ │ │ │ -*instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const │ │ │ │ │ -cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_2_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ -BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ -cl_mem dv, BufferDescriptor const &dvDesc, int numPatchCoords, cl_mem │ │ │ │ │ -patchCoordsBuffer, cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem │ │ │ │ │ -patchParamsBuffer, unsigned int numStartEvents=0, const cl_event │ │ │ │ │ -*startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const │ │ │ │ │ -cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_9_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, │ │ │ │ │ -const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ -Generic stencil function. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const │ │ │ │ │ -cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ -Generic limit eval function with derivatives. This function has a same │ │ │ │ │ -signature as other device kern... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_3_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_I_n_s_t_a_n_t_i_a_t_a_b_l_e │ │ │ │ │ -bool Instantiatable │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ -const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ -DEVICE_CONTEXT deviceContext) │ │ │ │ │ -Generic creator template. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ -fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, │ │ │ │ │ -unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_0_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ -const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ -BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, │ │ │ │ │ -BufferDescriptor const &dvvDesc, DEVICE_CONTEXT deviceContext) │ │ │ │ │ -Generic creator template. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_3_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ -BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ -cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const │ │ │ │ │ -&duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, cl_mem patchCoordsBuffer, │ │ │ │ │ -cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem patchParamsBuffer, │ │ │ │ │ -unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ -BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ -cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const │ │ │ │ │ -&duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, │ │ │ │ │ -BufferDescriptor const &dvvDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, │ │ │ │ │ -cl_mem weights, cl_mem duWeights, cl_mem dvWeights, cl_mem duuWeights, cl_mem │ │ │ │ │ -duvWeights, cl_mem dvvWeights, int start, int end, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -const │ │ │ │ │ -Dispatch the CL compute kernel asynchronously. returns false if the kernel │ │ │ │ │ -hasn't been compiled yet. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, │ │ │ │ │ -unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_5_6_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_2_1_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, unsigned │ │ │ │ │ -int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) const │ │ │ │ │ -Generic stencil function. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_6_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, │ │ │ │ │ -DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event │ │ │ │ │ -*startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_6_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ -static void Synchronize(DEVICE_CONTEXT deviceContext) │ │ │ │ │ -Wait the OpenCL kernels finish. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_6_1_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, │ │ │ │ │ -DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event │ │ │ │ │ -*startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_1_2_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ -CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic static stencil function. This function has a same signature as other │ │ │ │ │ -device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_4_2_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ -BufferDescriptor const &dstDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, │ │ │ │ │ -cl_mem weights, int start, int end, unsigned int numStartEvents=0, const │ │ │ │ │ -cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, │ │ │ │ │ -CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_4_8_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_3_2_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ -DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, │ │ │ │ │ -CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_4_3_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ -const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ -BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, │ │ │ │ │ -BufferDescriptor const &dvvDesc, cl_context clContext, cl_command_queue │ │ │ │ │ -clCommandQueue) │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_4_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, │ │ │ │ │ -unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ -*endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_0_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ -cl_event *endEvent=NULL) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_7_4_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const │ │ │ │ │ -*instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const │ │ │ │ │ -cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_9_0_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int │ │ │ │ │ -numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_5_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const │ │ │ │ │ -*instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const │ │ │ │ │ -cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_8_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const │ │ │ │ │ -*stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ -cl_event *endEvent=NULL) const │ │ │ │ │ -Generic stencil function. │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ -cl_event *endEvent=NULL) const │ │ │ │ │ -Generic limit eval function with derivatives. This function has a same │ │ │ │ │ -signature as other device kern... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_2_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ -CLEvaluator(cl_context context, cl_command_queue queue) │ │ │ │ │ -Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_o_m_p_i_l_e │ │ │ │ │ -bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, │ │ │ │ │ -BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ -&dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), │ │ │ │ │ -BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ -&dvvDesc=BufferDescriptor()) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ -fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ -cl_event *endEvent=NULL) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_1_4_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t_:_:_c_o_m_m_a_n_d_Q_u_e_u_e │ │ │ │ │ +id< MTLCommandQueue > commandQueue │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t_:_:_d_e_v_i_c_e │ │ │ │ │ +id< MTLDevice > device │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_2 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _c_l_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _m_t_l_C_o_m_m_o_n_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00806.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlCommon.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/clEvaluator.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,40 +90,47 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
mtlCommon.h File Reference
│ │ │ │ +
clEvaluator.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include <cstddef>
│ │ │ │ +#include "../osd/opencl.h"
│ │ │ │ +#include "../osd/types.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  MTLContext
class  CLStencilTable
 OpenCL stencil table. More...
 
class  CLEvaluator
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,23 +1,30 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -mtlCommon.h File Reference │ │ │ │ │ +clEvaluator.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_o_s_d_/_o_p_e_n_c_l_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _M_T_L_C_o_n_t_e_x_t │ │ │ │ │ +class   _C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +  OpenCL stencil table. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ +namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │ +  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_C_o_m_m_o_n_._h │ │ │ │ │ + * _c_l_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00806.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,4 @@ │ │ │ │ │ var a00806 = [ │ │ │ │ │ - ["MTLContext", "a01285.html", "a01285"] │ │ │ │ │ + ["CLStencilTable", "a01145.html", "a01145"], │ │ │ │ │ + ["CLEvaluator", "a01149.html", "a01149"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00806_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlCommon.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/clEvaluator.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
mtlCommon.h
│ │ │ │ +
clEvaluator.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2013 Pixar
│ │ │ │ +
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -119,53 +119,1283 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_MTL_COMMON_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_MTL_COMMON_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_CL_EVALUATOR_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_CL_EVALUATOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include <cstddef>
│ │ │ │ -
31
│ │ │ │ -
32@protocol MTLDevice;
│ │ │ │ -
33@protocol MTLCommandQueue;
│ │ │ │ -
34
│ │ │ │ -
35namespace OpenSubdiv {
│ │ │ │ -
36namespace OPENSUBDIV_VERSION {
│ │ │ │ -
37
│ │ │ │ -
38namespace Osd {
│ │ │ │ -
39
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
41public:
│ │ │ │ -
42 id<MTLDevice> device = nullptr;
│ │ │ │ -
43 id<MTLCommandQueue> commandQueue = nullptr;
│ │ │ │ -
44};
│ │ │ │ -
│ │ │ │ -
45
│ │ │ │ -
46} // end namespace Osd
│ │ │ │ -
47
│ │ │ │ -
48} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
49using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
50
│ │ │ │ -
51} // end namespace OpenSubdiv
│ │ │ │ -
52
│ │ │ │ -
53#endif //OPENSUBDIV3_OSD_MTL_COMMON_H
│ │ │ │ +
30#include "../osd/opencl.h"
│ │ │ │ +
31#include "../osd/types.h"
│ │ │ │ +
32#include "../osd/bufferDescriptor.h"
│ │ │ │ +
33
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Far {
│ │ │ │ +
38 class PatchTable;
│ │ │ │ +
39 class StencilTable;
│ │ │ │ +
40 class LimitStencilTable;
│ │ │ │ +
41}
│ │ │ │ +
42
│ │ │ │ +
43namespace Osd {
│ │ │ │ +
44
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
53public:
│ │ │ │ +
54 template <typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
55 static CLStencilTable *Create(Far::StencilTable const *stencilTable,
│ │ │ │ +
56 DEVICE_CONTEXT context) {
│ │ │ │ +
57 return new CLStencilTable(stencilTable, context->GetContext());
│ │ │ │ +
58 }
│ │ │ │ +
│ │ │ │ +
59
│ │ │ │ +
60 template <typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
62 Far::LimitStencilTable const *limitStencilTable,
│ │ │ │ +
63 DEVICE_CONTEXT context) {
│ │ │ │ +
64 return new CLStencilTable(limitStencilTable, context->GetContext());
│ │ │ │ +
65 }
│ │ │ │ +
│ │ │ │ +
66
│ │ │ │ +
67 CLStencilTable(Far::StencilTable const *stencilTable,
│ │ │ │ +
68 cl_context clContext);
│ │ │ │ +
69 CLStencilTable(Far::LimitStencilTable const *limitStencilTable,
│ │ │ │ +
70 cl_context clContext);
│ │ │ │ + │ │ │ │ +
72
│ │ │ │ +
73 // interfaces needed for CLComputeKernel
│ │ │ │ +
74 cl_mem GetSizesBuffer() const { return _sizes; }
│ │ │ │ +
75 cl_mem GetOffsetsBuffer() const { return _offsets; }
│ │ │ │ +
76 cl_mem GetIndicesBuffer() const { return _indices; }
│ │ │ │ +
77 cl_mem GetWeightsBuffer() const { return _weights; }
│ │ │ │ +
78 cl_mem GetDuWeightsBuffer() const { return _duWeights; }
│ │ │ │ +
79 cl_mem GetDvWeightsBuffer() const { return _dvWeights; }
│ │ │ │ +
80 cl_mem GetDuuWeightsBuffer() const { return _duuWeights; }
│ │ │ │ +
81 cl_mem GetDuvWeightsBuffer() const { return _duvWeights; }
│ │ │ │ +
82 cl_mem GetDvvWeightsBuffer() const { return _dvvWeights; }
│ │ │ │ +
83 int GetNumStencils() const { return _numStencils; }
│ │ │ │ +
84
│ │ │ │ +
85private:
│ │ │ │ +
86 cl_mem _sizes;
│ │ │ │ +
87 cl_mem _offsets;
│ │ │ │ +
88 cl_mem _indices;
│ │ │ │ +
89 cl_mem _weights;
│ │ │ │ +
90 cl_mem _duWeights;
│ │ │ │ +
91 cl_mem _dvWeights;
│ │ │ │ +
92 cl_mem _duuWeights;
│ │ │ │ +
93 cl_mem _duvWeights;
│ │ │ │ +
94 cl_mem _dvvWeights;
│ │ │ │ +
95 int _numStencils;
│ │ │ │ +
96};
│ │ │ │ +
│ │ │ │ +
97
│ │ │ │ +
98// ---------------------------------------------------------------------------
│ │ │ │ +
99
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
101public:
│ │ │ │ +
102 typedef bool Instantiatable;
│ │ │ │ +
103
│ │ │ │ +
105 template <typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
106 static CLEvaluator *Create(BufferDescriptor const &srcDesc,
│ │ │ │ +
107 BufferDescriptor const &dstDesc,
│ │ │ │ +
108 BufferDescriptor const &duDesc,
│ │ │ │ +
109 BufferDescriptor const &dvDesc,
│ │ │ │ +
110 DEVICE_CONTEXT deviceContext) {
│ │ │ │ +
111 return Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ +
112 deviceContext->GetContext(),
│ │ │ │ +
113 deviceContext->GetCommandQueue());
│ │ │ │ +
114 }
│ │ │ │ +
│ │ │ │ +
115
│ │ │ │ +
│ │ │ │ +
116 static CLEvaluator * Create(BufferDescriptor const &srcDesc,
│ │ │ │ +
117 BufferDescriptor const &dstDesc,
│ │ │ │ +
118 BufferDescriptor const &duDesc,
│ │ │ │ +
119 BufferDescriptor const &dvDesc,
│ │ │ │ +
120 cl_context clContext,
│ │ │ │ +
121 cl_command_queue clCommandQueue) {
│ │ │ │ +
122 CLEvaluator *instance = new CLEvaluator(clContext, clCommandQueue);
│ │ │ │ +
123 if (instance->Compile(srcDesc, dstDesc, duDesc, dvDesc))
│ │ │ │ +
124 return instance;
│ │ │ │ +
125 delete instance;
│ │ │ │ +
126 return NULL;
│ │ │ │ +
127 }
│ │ │ │ +
│ │ │ │ +
128
│ │ │ │ +
130 template <typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
131 static CLEvaluator *Create(BufferDescriptor const &srcDesc,
│ │ │ │ +
132 BufferDescriptor const &dstDesc,
│ │ │ │ +
133 BufferDescriptor const &duDesc,
│ │ │ │ +
134 BufferDescriptor const &dvDesc,
│ │ │ │ +
135 BufferDescriptor const &duuDesc,
│ │ │ │ +
136 BufferDescriptor const &duvDesc,
│ │ │ │ +
137 BufferDescriptor const &dvvDesc,
│ │ │ │ +
138 DEVICE_CONTEXT deviceContext) {
│ │ │ │ +
139 return Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ +
140 duuDesc, duvDesc, dvvDesc,
│ │ │ │ +
141 deviceContext->GetContext(),
│ │ │ │ +
142 deviceContext->GetCommandQueue());
│ │ │ │ +
143 }
│ │ │ │ +
│ │ │ │ +
144
│ │ │ │ +
│ │ │ │ +
145 static CLEvaluator * Create(BufferDescriptor const &srcDesc,
│ │ │ │ +
146 BufferDescriptor const &dstDesc,
│ │ │ │ +
147 BufferDescriptor const &duDesc,
│ │ │ │ +
148 BufferDescriptor const &dvDesc,
│ │ │ │ +
149 BufferDescriptor const &duuDesc,
│ │ │ │ +
150 BufferDescriptor const &duvDesc,
│ │ │ │ +
151 BufferDescriptor const &dvvDesc,
│ │ │ │ +
152 cl_context clContext,
│ │ │ │ +
153 cl_command_queue clCommandQueue) {
│ │ │ │ +
154 CLEvaluator *instance = new CLEvaluator(clContext, clCommandQueue);
│ │ │ │ +
155 if (instance->Compile(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ +
156 duuDesc, duvDesc, dvvDesc))
│ │ │ │ +
157 return instance;
│ │ │ │ +
158 delete instance;
│ │ │ │ +
159 return NULL;
│ │ │ │ +
160 }
│ │ │ │ +
│ │ │ │ +
161
│ │ │ │ +
163 CLEvaluator(cl_context context, cl_command_queue queue);
│ │ │ │ +
164
│ │ │ │ + │ │ │ │ +
167
│ │ │ │ +
173
│ │ │ │ +
217 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
218 typename STENCIL_TABLE, typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
219 static bool EvalStencils(
│ │ │ │ +
220 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
221 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
222 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
223 CLEvaluator const *instance,
│ │ │ │ +
224 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
225 unsigned int numStartEvents=0,
│ │ │ │ +
226 const cl_event* startEvents=NULL,
│ │ │ │ +
227 cl_event* endEvent=NULL) {
│ │ │ │ +
228
│ │ │ │ +
229 if (instance) {
│ │ │ │ +
230 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
231 dstBuffer, dstDesc,
│ │ │ │ +
232 stencilTable,
│ │ │ │ +
233 numStartEvents, startEvents, endEvent);
│ │ │ │ +
234 } else {
│ │ │ │ +
235 // Create an instance on demand (slow)
│ │ │ │ +
236 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
239 deviceContext);
│ │ │ │ +
240 if (instance) {
│ │ │ │ +
241 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
242 dstBuffer, dstDesc,
│ │ │ │ +
243 stencilTable,
│ │ │ │ +
244 numStartEvents, startEvents, endEvent);
│ │ │ │ +
245 delete instance;
│ │ │ │ +
246 return r;
│ │ │ │ +
247 }
│ │ │ │ +
248 return false;
│ │ │ │ +
249 }
│ │ │ │ +
250 }
│ │ │ │ +
│ │ │ │ +
251
│ │ │ │ +
307 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
308 typename STENCIL_TABLE, typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
309 static bool EvalStencils(
│ │ │ │ +
310 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
311 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
312 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
313 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
314 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
315 CLEvaluator const *instance,
│ │ │ │ +
316 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
317 unsigned int numStartEvents=0,
│ │ │ │ +
318 const cl_event* startEvents=NULL,
│ │ │ │ +
319 cl_event* endEvent=NULL) {
│ │ │ │ +
320
│ │ │ │ +
321 if (instance) {
│ │ │ │ +
322 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
323 dstBuffer, dstDesc,
│ │ │ │ +
324 duBuffer, duDesc,
│ │ │ │ +
325 dvBuffer, dvDesc,
│ │ │ │ +
326 stencilTable,
│ │ │ │ +
327 numStartEvents, startEvents, endEvent);
│ │ │ │ +
328 } else {
│ │ │ │ +
329 // Create an instance on demand (slow)
│ │ │ │ +
330 instance = Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ +
331 deviceContext);
│ │ │ │ +
332 if (instance) {
│ │ │ │ +
333 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
334 dstBuffer, dstDesc,
│ │ │ │ +
335 duBuffer, duDesc,
│ │ │ │ +
336 dvBuffer, dvDesc,
│ │ │ │ +
337 stencilTable,
│ │ │ │ +
338 numStartEvents, startEvents, endEvent);
│ │ │ │ +
339 delete instance;
│ │ │ │ +
340 return r;
│ │ │ │ +
341 }
│ │ │ │ +
342 return false;
│ │ │ │ +
343 }
│ │ │ │ +
344 }
│ │ │ │ +
│ │ │ │ +
345
│ │ │ │ +
419 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
420 typename STENCIL_TABLE, typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
421 static bool EvalStencils(
│ │ │ │ +
422 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
423 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
424 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
425 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
426 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
427 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
428 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
429 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
430 CLEvaluator const *instance,
│ │ │ │ +
431 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
432 unsigned int numStartEvents=0,
│ │ │ │ +
433 const cl_event* startEvents=NULL,
│ │ │ │ +
434 cl_event* endEvent=NULL) {
│ │ │ │ +
435
│ │ │ │ +
436 if (instance) {
│ │ │ │ +
437 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
438 dstBuffer, dstDesc,
│ │ │ │ +
439 duBuffer, duDesc,
│ │ │ │ +
440 dvBuffer, dvDesc,
│ │ │ │ +
441 duuBuffer, duuDesc,
│ │ │ │ +
442 duvBuffer, duvDesc,
│ │ │ │ +
443 dvvBuffer, dvvDesc,
│ │ │ │ +
444 stencilTable,
│ │ │ │ +
445 numStartEvents, startEvents, endEvent);
│ │ │ │ +
446 } else {
│ │ │ │ +
447 // Create an instance on demand (slow)
│ │ │ │ +
448 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
449 duDesc, dvDesc,
│ │ │ │ +
450 duuDesc, duvDesc, dvvDesc,
│ │ │ │ +
451 deviceContext);
│ │ │ │ +
452 if (instance) {
│ │ │ │ +
453 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
454 dstBuffer, dstDesc,
│ │ │ │ +
455 duBuffer, duDesc,
│ │ │ │ +
456 dvBuffer, dvDesc,
│ │ │ │ +
457 duuBuffer, duuDesc,
│ │ │ │ +
458 duvBuffer, duvDesc,
│ │ │ │ +
459 dvvBuffer, dvvDesc,
│ │ │ │ +
460 stencilTable,
│ │ │ │ +
461 numStartEvents, startEvents, endEvent);
│ │ │ │ +
462 delete instance;
│ │ │ │ +
463 return r;
│ │ │ │ +
464 }
│ │ │ │ +
465 return false;
│ │ │ │ +
466 }
│ │ │ │ +
467 }
│ │ │ │ +
│ │ │ │ +
468
│ │ │ │ +
499 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
501 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
502 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
503 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
504 unsigned int numStartEvents=0,
│ │ │ │ +
505 const cl_event* startEvents=NULL,
│ │ │ │ +
506 cl_event* endEvent=NULL) const {
│ │ │ │ +
507 return EvalStencils(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
508 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
509 stencilTable->GetSizesBuffer(),
│ │ │ │ +
510 stencilTable->GetOffsetsBuffer(),
│ │ │ │ +
511 stencilTable->GetIndicesBuffer(),
│ │ │ │ +
512 stencilTable->GetWeightsBuffer(),
│ │ │ │ +
513 0,
│ │ │ │ +
514 stencilTable->GetNumStencils(),
│ │ │ │ +
515 numStartEvents, startEvents, endEvent);
│ │ │ │ +
516 }
│ │ │ │ +
│ │ │ │ +
517
│ │ │ │ +
560 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
562 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
563 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
564 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
565 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
566 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
567 unsigned int numStartEvents=0,
│ │ │ │ +
568 const cl_event* startEvents=NULL,
│ │ │ │ +
569 cl_event* endEvent=NULL) const {
│ │ │ │ +
570 return EvalStencils(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
571 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
572 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
573 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
574 stencilTable->GetSizesBuffer(),
│ │ │ │ +
575 stencilTable->GetOffsetsBuffer(),
│ │ │ │ +
576 stencilTable->GetIndicesBuffer(),
│ │ │ │ +
577 stencilTable->GetWeightsBuffer(),
│ │ │ │ +
578 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ +
579 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ +
580 0,
│ │ │ │ +
581 stencilTable->GetNumStencils(),
│ │ │ │ +
582 numStartEvents, startEvents, endEvent);
│ │ │ │ +
583 }
│ │ │ │ +
│ │ │ │ +
584
│ │ │ │ +
645 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
647 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
648 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
649 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
650 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
651 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
652 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
653 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
654 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
655 unsigned int numStartEvents=0,
│ │ │ │ +
656 const cl_event* startEvents=NULL,
│ │ │ │ +
657 cl_event* endEvent=NULL) const {
│ │ │ │ +
658 return EvalStencils(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
659 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
660 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
661 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
662 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ +
663 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ +
664 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ +
665 stencilTable->GetSizesBuffer(),
│ │ │ │ +
666 stencilTable->GetOffsetsBuffer(),
│ │ │ │ +
667 stencilTable->GetIndicesBuffer(),
│ │ │ │ +
668 stencilTable->GetWeightsBuffer(),
│ │ │ │ +
669 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ +
670 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ +
671 stencilTable->GetDuuWeightsBuffer(),
│ │ │ │ +
672 stencilTable->GetDuvWeightsBuffer(),
│ │ │ │ +
673 stencilTable->GetDvvWeightsBuffer(),
│ │ │ │ +
674 0,
│ │ │ │ +
675 stencilTable->GetNumStencils(),
│ │ │ │ +
676 numStartEvents, startEvents, endEvent);
│ │ │ │ +
677 }
│ │ │ │ +
│ │ │ │ +
678
│ │ │ │ +
681 bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ +
682 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
683 cl_mem sizes,
│ │ │ │ +
684 cl_mem offsets,
│ │ │ │ +
685 cl_mem indices,
│ │ │ │ +
686 cl_mem weights,
│ │ │ │ +
687 int start,
│ │ │ │ +
688 int end,
│ │ │ │ +
689 unsigned int numStartEvents=0,
│ │ │ │ +
690 const cl_event* startEvents=NULL,
│ │ │ │ +
691 cl_event* endEvent=NULL) const;
│ │ │ │ +
692
│ │ │ │ +
741 bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ +
742 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
743 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ +
744 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
745 cl_mem sizes,
│ │ │ │ +
746 cl_mem offsets,
│ │ │ │ +
747 cl_mem indices,
│ │ │ │ +
748 cl_mem weights,
│ │ │ │ +
749 cl_mem duWeights,
│ │ │ │ +
750 cl_mem dvWeights,
│ │ │ │ +
751 int start,
│ │ │ │ +
752 int end,
│ │ │ │ +
753 unsigned int numStartEvents=0,
│ │ │ │ +
754 const cl_event* startEvents=NULL,
│ │ │ │ +
755 cl_event* endEvent=NULL) const;
│ │ │ │ +
756
│ │ │ │ +
823 bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ +
824 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
825 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ +
826 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
827 cl_mem duu, BufferDescriptor const &duuDesc,
│ │ │ │ +
828 cl_mem duv, BufferDescriptor const &duvDesc,
│ │ │ │ +
829 cl_mem dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ +
830 cl_mem sizes,
│ │ │ │ +
831 cl_mem offsets,
│ │ │ │ +
832 cl_mem indices,
│ │ │ │ +
833 cl_mem weights,
│ │ │ │ +
834 cl_mem duWeights,
│ │ │ │ +
835 cl_mem dvWeights,
│ │ │ │ +
836 cl_mem duuWeights,
│ │ │ │ +
837 cl_mem duvWeights,
│ │ │ │ +
838 cl_mem dvvWeights,
│ │ │ │ +
839 int start,
│ │ │ │ +
840 int end,
│ │ │ │ +
841 unsigned int numStartEvents=0,
│ │ │ │ +
842 const cl_event* startEvents=NULL,
│ │ │ │ +
843 cl_event* endEvent=NULL) const;
│ │ │ │ +
844
│ │ │ │ +
850
│ │ │ │ +
899 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
900 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
901 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
902 static bool EvalPatches(
│ │ │ │ +
903 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
904 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
905 int numPatchCoords,
│ │ │ │ +
906 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
907 PATCH_TABLE *patchTable,
│ │ │ │ +
908 CLEvaluator const *instance,
│ │ │ │ +
909 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
910 unsigned int numStartEvents=0,
│ │ │ │ +
911 const cl_event* startEvents=NULL,
│ │ │ │ +
912 cl_event* endEvent=NULL) {
│ │ │ │ +
913
│ │ │ │ +
914 if (instance) {
│ │ │ │ +
915 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
916 dstBuffer, dstDesc,
│ │ │ │ +
917 numPatchCoords, patchCoords,
│ │ │ │ +
918 patchTable,
│ │ │ │ +
919 numStartEvents, startEvents, endEvent);
│ │ │ │ +
920 } else {
│ │ │ │ +
921 // Create an instance on demand (slow)
│ │ │ │ +
922 (void)deviceContext; // unused
│ │ │ │ +
923 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
926 deviceContext);
│ │ │ │ +
927 if (instance) {
│ │ │ │ +
928 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
929 dstBuffer, dstDesc,
│ │ │ │ +
930 numPatchCoords, patchCoords,
│ │ │ │ +
931 patchTable,
│ │ │ │ +
932 numStartEvents, startEvents, endEvent);
│ │ │ │ +
933 delete instance;
│ │ │ │ +
934 return r;
│ │ │ │ +
935 }
│ │ │ │ +
936 return false;
│ │ │ │ +
937 }
│ │ │ │ +
938 }
│ │ │ │ +
│ │ │ │ +
939
│ │ │ │ +
1000 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1001 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
1002 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
1003 static bool EvalPatches(
│ │ │ │ +
1004 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1005 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1006 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1007 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1008 int numPatchCoords,
│ │ │ │ +
1009 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1010 PATCH_TABLE *patchTable,
│ │ │ │ +
1011 CLEvaluator const *instance,
│ │ │ │ +
1012 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
1013 unsigned int numStartEvents=0,
│ │ │ │ +
1014 const cl_event* startEvents=NULL,
│ │ │ │ +
1015 cl_event* endEvent=NULL) {
│ │ │ │ +
1016
│ │ │ │ +
1017 if (instance) {
│ │ │ │ +
1018 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
1019 dstBuffer, dstDesc,
│ │ │ │ +
1020 duBuffer, duDesc,
│ │ │ │ +
1021 dvBuffer, dvDesc,
│ │ │ │ +
1022 numPatchCoords, patchCoords,
│ │ │ │ +
1023 patchTable,
│ │ │ │ +
1024 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1025 } else {
│ │ │ │ +
1026 // Create an instance on demand (slow)
│ │ │ │ +
1027 (void)deviceContext; // unused
│ │ │ │ +
1028 instance = Create(srcDesc, dstDesc, duDesc, dvDesc, deviceContext);
│ │ │ │ +
1029 if (instance) {
│ │ │ │ +
1030 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
1031 dstBuffer, dstDesc,
│ │ │ │ +
1032 duBuffer, duDesc,
│ │ │ │ +
1033 dvBuffer, dvDesc,
│ │ │ │ +
1034 numPatchCoords, patchCoords,
│ │ │ │ +
1035 patchTable,
│ │ │ │ +
1036 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1037 delete instance;
│ │ │ │ +
1038 return r;
│ │ │ │ +
1039 }
│ │ │ │ +
1040 return false;
│ │ │ │ +
1041 }
│ │ │ │ +
1042 }
│ │ │ │ +
│ │ │ │ +
1043
│ │ │ │ +
1122 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1123 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
1124 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
1125 static bool EvalPatches(
│ │ │ │ +
1126 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1127 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1128 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1129 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1130 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1131 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1132 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1133 int numPatchCoords,
│ │ │ │ +
1134 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1135 PATCH_TABLE *patchTable,
│ │ │ │ +
1136 CLEvaluator const *instance,
│ │ │ │ +
1137 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
1138 unsigned int numStartEvents=0,
│ │ │ │ +
1139 const cl_event* startEvents=NULL,
│ │ │ │ +
1140 cl_event* endEvent=NULL) {
│ │ │ │ +
1141
│ │ │ │ +
1142 if (instance) {
│ │ │ │ +
1143 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
1144 dstBuffer, dstDesc,
│ │ │ │ +
1145 duBuffer, duDesc,
│ │ │ │ +
1146 dvBuffer, dvDesc,
│ │ │ │ +
1147 duuBuffer, duuDesc,
│ │ │ │ +
1148 duvBuffer, duvDesc,
│ │ │ │ +
1149 dvvBuffer, dvvDesc,
│ │ │ │ +
1150 numPatchCoords, patchCoords,
│ │ │ │ +
1151 patchTable,
│ │ │ │ +
1152 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1153 } else {
│ │ │ │ +
1154 // Create an instance on demand (slow)
│ │ │ │ +
1155 (void)deviceContext; // unused
│ │ │ │ +
1156 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1157 duDesc, dvDesc,
│ │ │ │ +
1158 duuDesc, duvDesc, dvvDesc,
│ │ │ │ +
1159 deviceContext);
│ │ │ │ +
1160 if (instance) {
│ │ │ │ +
1161 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
1162 dstBuffer, dstDesc,
│ │ │ │ +
1163 duBuffer, duDesc,
│ │ │ │ +
1164 dvBuffer, dvDesc,
│ │ │ │ +
1165 duuBuffer, duuDesc,
│ │ │ │ +
1166 duvBuffer, duvDesc,
│ │ │ │ +
1167 dvvBuffer, dvvDesc,
│ │ │ │ +
1168 numPatchCoords, patchCoords,
│ │ │ │ +
1169 patchTable,
│ │ │ │ +
1170 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1171 delete instance;
│ │ │ │ +
1172 return r;
│ │ │ │ +
1173 }
│ │ │ │ +
1174 return false;
│ │ │ │ +
1175 }
│ │ │ │ +
1176 }
│ │ │ │ +
│ │ │ │ +
1177
│ │ │ │ +
1215 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1216 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1218 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1219 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1220 int numPatchCoords,
│ │ │ │ +
1221 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1222 PATCH_TABLE *patchTable,
│ │ │ │ +
1223 unsigned int numStartEvents=0,
│ │ │ │ +
1224 const cl_event* startEvents=NULL,
│ │ │ │ +
1225 cl_event* endEvent=NULL) const {
│ │ │ │ +
1226
│ │ │ │ +
1227 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
1228 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
1229 0, BufferDescriptor(),
│ │ │ │ +
1230 0, BufferDescriptor(),
│ │ │ │ +
1231 numPatchCoords,
│ │ │ │ +
1232 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
1233 patchTable->GetPatchArrayBuffer(),
│ │ │ │ +
1234 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
1235 patchTable->GetPatchParamBuffer(),
│ │ │ │ +
1236 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1237 }
│ │ │ │ +
│ │ │ │ +
1238
│ │ │ │ +
1286 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1287 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1289 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1290 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1291 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1292 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1293 int numPatchCoords,
│ │ │ │ +
1294 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1295 PATCH_TABLE *patchTable,
│ │ │ │ +
1296 unsigned int numStartEvents=0,
│ │ │ │ +
1297 const cl_event* startEvents=NULL,
│ │ │ │ +
1298 cl_event* endEvent=NULL) const {
│ │ │ │ +
1299
│ │ │ │ +
1300 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
1301 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
1302 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
1303 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
1304 numPatchCoords,
│ │ │ │ +
1305 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
1306 patchTable->GetPatchArrayBuffer(),
│ │ │ │ +
1307 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
1308 patchTable->GetPatchParamBuffer(),
│ │ │ │ +
1309 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1310 }
│ │ │ │ +
│ │ │ │ +
1311
│ │ │ │ +
1377 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1378 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1380 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1381 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1382 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1383 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1384 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1385 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1386 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1387 int numPatchCoords,
│ │ │ │ +
1388 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1389 PATCH_TABLE *patchTable,
│ │ │ │ +
1390 unsigned int numStartEvents=0,
│ │ │ │ +
1391 const cl_event* startEvents=NULL,
│ │ │ │ +
1392 cl_event* endEvent=NULL) const {
│ │ │ │ +
1393
│ │ │ │ +
1394 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
1395 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
1396 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
1397 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
1398 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ +
1399 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ +
1400 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ +
1401 numPatchCoords,
│ │ │ │ +
1402 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
1403 patchTable->GetPatchArrayBuffer(),
│ │ │ │ +
1404 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
1405 patchTable->GetPatchParamBuffer(),
│ │ │ │ +
1406 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1407 }
│ │ │ │ +
│ │ │ │ +
1408
│ │ │ │ +
1409 bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ +
1410 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
1411 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ +
1412 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
1413 int numPatchCoords,
│ │ │ │ +
1414 cl_mem patchCoordsBuffer,
│ │ │ │ +
1415 cl_mem patchArrayBuffer,
│ │ │ │ +
1416 cl_mem patchIndexBuffer,
│ │ │ │ +
1417 cl_mem patchParamsBuffer,
│ │ │ │ +
1418 unsigned int numStartEvents=0,
│ │ │ │ +
1419 const cl_event* startEvents=NULL,
│ │ │ │ +
1420 cl_event* endEvent=NULL) const;
│ │ │ │ +
1421
│ │ │ │ +
1422 bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc,
│ │ │ │ +
1423 cl_mem dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
1424 cl_mem du, BufferDescriptor const &duDesc,
│ │ │ │ +
1425 cl_mem dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
1426 cl_mem duu, BufferDescriptor const &duuDesc,
│ │ │ │ +
1427 cl_mem duv, BufferDescriptor const &duvDesc,
│ │ │ │ +
1428 cl_mem dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1429 int numPatchCoords,
│ │ │ │ +
1430 cl_mem patchCoordsBuffer,
│ │ │ │ +
1431 cl_mem patchArrayBuffer,
│ │ │ │ +
1432 cl_mem patchIndexBuffer,
│ │ │ │ +
1433 cl_mem patchParamsBuffer,
│ │ │ │ +
1434 unsigned int numStartEvents=0,
│ │ │ │ +
1435 const cl_event* startEvents=NULL,
│ │ │ │ +
1436 cl_event* endEvent=NULL) const;
│ │ │ │ +
1437
│ │ │ │ +
1486 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1487 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
1488 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1490 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1491 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1492 int numPatchCoords,
│ │ │ │ +
1493 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1494 PATCH_TABLE *patchTable,
│ │ │ │ +
1495 CLEvaluator const *instance,
│ │ │ │ +
1496 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
1497 unsigned int numStartEvents=0,
│ │ │ │ +
1498 const cl_event* startEvents=NULL,
│ │ │ │ +
1499 cl_event* endEvent=NULL) {
│ │ │ │ +
1500
│ │ │ │ +
1501 if (instance) {
│ │ │ │ +
1502 return instance->EvalPatchesVarying(
│ │ │ │ +
1503 srcBuffer, srcDesc,
│ │ │ │ +
1504 dstBuffer, dstDesc,
│ │ │ │ +
1505 numPatchCoords, patchCoords,
│ │ │ │ +
1506 patchTable,
│ │ │ │ +
1507 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1508 } else {
│ │ │ │ +
1509 // Create an instance on demand (slow)
│ │ │ │ +
1510 (void)deviceContext; // unused
│ │ │ │ +
1511 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
1514 deviceContext);
│ │ │ │ +
1515 if (instance) {
│ │ │ │ +
1516 bool r = instance->EvalPatchesVarying(
│ │ │ │ +
1517 srcBuffer, srcDesc,
│ │ │ │ +
1518 dstBuffer, dstDesc,
│ │ │ │ +
1519 numPatchCoords, patchCoords,
│ │ │ │ +
1520 patchTable,
│ │ │ │ +
1521 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1522 delete instance;
│ │ │ │ +
1523 return r;
│ │ │ │ +
1524 }
│ │ │ │ +
1525 return false;
│ │ │ │ +
1526 }
│ │ │ │ +
1527 }
│ │ │ │ +
│ │ │ │ +
1528
│ │ │ │ +
1566 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1567 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1569 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1570 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1571 int numPatchCoords,
│ │ │ │ +
1572 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1573 PATCH_TABLE *patchTable,
│ │ │ │ +
1574 unsigned int numStartEvents=0,
│ │ │ │ +
1575 const cl_event* startEvents=NULL,
│ │ │ │ +
1576 cl_event* endEvent=NULL) const {
│ │ │ │ +
1577
│ │ │ │ +
1578 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
1579 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
1580 0, BufferDescriptor(),
│ │ │ │ +
1581 0, BufferDescriptor(),
│ │ │ │ +
1582 numPatchCoords,
│ │ │ │ +
1583 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
1584 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ +
1585 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
1586 patchTable->GetPatchParamBuffer(),
│ │ │ │ +
1587 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1588 }
│ │ │ │ +
│ │ │ │ +
1589
│ │ │ │ +
1650 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1651 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
1652 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1654 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1655 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1656 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1657 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1658 int numPatchCoords,
│ │ │ │ +
1659 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1660 PATCH_TABLE *patchTable,
│ │ │ │ +
1661 CLEvaluator const *instance,
│ │ │ │ +
1662 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
1663 unsigned int numStartEvents=0,
│ │ │ │ +
1664 const cl_event* startEvents=NULL,
│ │ │ │ +
1665 cl_event* endEvent=NULL) {
│ │ │ │ +
1666
│ │ │ │ +
1667 if (instance) {
│ │ │ │ +
1668 return instance->EvalPatchesVarying(
│ │ │ │ +
1669 srcBuffer, srcDesc,
│ │ │ │ +
1670 dstBuffer, dstDesc,
│ │ │ │ +
1671 duBuffer, duDesc,
│ │ │ │ +
1672 dvBuffer, dvDesc,
│ │ │ │ +
1673 numPatchCoords, patchCoords,
│ │ │ │ +
1674 patchTable,
│ │ │ │ +
1675 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1676 } else {
│ │ │ │ +
1677 // Create an instance on demand (slow)
│ │ │ │ +
1678 (void)deviceContext; // unused
│ │ │ │ +
1679 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1680 duDesc, dvDesc,
│ │ │ │ +
1681 deviceContext);
│ │ │ │ +
1682 if (instance) {
│ │ │ │ +
1683 bool r = instance->EvalPatchesVarying(
│ │ │ │ +
1684 srcBuffer, srcDesc,
│ │ │ │ +
1685 dstBuffer, dstDesc,
│ │ │ │ +
1686 duBuffer, duDesc,
│ │ │ │ +
1687 dvBuffer, dvDesc,
│ │ │ │ +
1688 numPatchCoords, patchCoords,
│ │ │ │ +
1689 patchTable,
│ │ │ │ +
1690 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1691 delete instance;
│ │ │ │ +
1692 return r;
│ │ │ │ +
1693 }
│ │ │ │ +
1694 return false;
│ │ │ │ +
1695 }
│ │ │ │ +
1696 }
│ │ │ │ +
│ │ │ │ +
1697
│ │ │ │ +
1747 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1748 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1750 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1751 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1752 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1753 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1754 int numPatchCoords,
│ │ │ │ +
1755 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1756 PATCH_TABLE *patchTable,
│ │ │ │ +
1757 unsigned int numStartEvents=0,
│ │ │ │ +
1758 const cl_event* startEvents=NULL,
│ │ │ │ +
1759 cl_event* endEvent=NULL) const {
│ │ │ │ +
1760
│ │ │ │ +
1761 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
1762 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
1763 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
1764 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
1765 numPatchCoords,
│ │ │ │ +
1766 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
1767 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ +
1768 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
1769 patchTable->GetPatchParamBuffer(),
│ │ │ │ +
1770 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1771 }
│ │ │ │ +
│ │ │ │ +
1772
│ │ │ │ +
1851 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1852 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
1853 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1855 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1856 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1857 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1858 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1859 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1860 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1861 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1862 int numPatchCoords,
│ │ │ │ +
1863 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1864 PATCH_TABLE *patchTable,
│ │ │ │ +
1865 CLEvaluator const *instance,
│ │ │ │ +
1866 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
1867 unsigned int numStartEvents=0,
│ │ │ │ +
1868 const cl_event* startEvents=NULL,
│ │ │ │ +
1869 cl_event* endEvent=NULL) {
│ │ │ │ +
1870
│ │ │ │ +
1871 if (instance) {
│ │ │ │ +
1872 return instance->EvalPatchesVarying(
│ │ │ │ +
1873 srcBuffer, srcDesc,
│ │ │ │ +
1874 dstBuffer, dstDesc,
│ │ │ │ +
1875 duBuffer, duDesc,
│ │ │ │ +
1876 dvBuffer, dvDesc,
│ │ │ │ +
1877 duuBuffer, duuDesc,
│ │ │ │ +
1878 duvBuffer, duvDesc,
│ │ │ │ +
1879 dvvBuffer, dvvDesc,
│ │ │ │ +
1880 numPatchCoords, patchCoords,
│ │ │ │ +
1881 patchTable,
│ │ │ │ +
1882 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1883 } else {
│ │ │ │ +
1884 // Create an instance on demand (slow)
│ │ │ │ +
1885 (void)deviceContext; // unused
│ │ │ │ +
1886 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1887 duDesc, dvDesc,
│ │ │ │ +
1888 duuDesc, duvDesc, dvvDesc,
│ │ │ │ +
1889 deviceContext);
│ │ │ │ +
1890 if (instance) {
│ │ │ │ +
1891 bool r = instance->EvalPatchesVarying(
│ │ │ │ +
1892 srcBuffer, srcDesc,
│ │ │ │ +
1893 dstBuffer, dstDesc,
│ │ │ │ +
1894 duBuffer, duDesc,
│ │ │ │ +
1895 dvBuffer, dvDesc,
│ │ │ │ +
1896 duuBuffer, duuDesc,
│ │ │ │ +
1897 duvBuffer, duvDesc,
│ │ │ │ +
1898 dvvBuffer, dvvDesc,
│ │ │ │ +
1899 numPatchCoords, patchCoords,
│ │ │ │ +
1900 patchTable,
│ │ │ │ +
1901 numStartEvents, startEvents, endEvent);
│ │ │ │ +
1902 delete instance;
│ │ │ │ +
1903 return r;
│ │ │ │ +
1904 }
│ │ │ │ +
1905 return false;
│ │ │ │ +
1906 }
│ │ │ │ +
1907 }
│ │ │ │ +
│ │ │ │ +
1908
│ │ │ │ +
1976 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1977 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1979 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1980 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1981 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1982 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1983 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1984 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1985 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1986 int numPatchCoords,
│ │ │ │ +
1987 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1988 PATCH_TABLE *patchTable,
│ │ │ │ +
1989 unsigned int numStartEvents=0,
│ │ │ │ +
1990 const cl_event* startEvents=NULL,
│ │ │ │ +
1991 cl_event* endEvent=NULL) const {
│ │ │ │ +
1992
│ │ │ │ +
1993 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
1994 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
1995 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
1996 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
1997 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ +
1998 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ +
1999 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ +
2000 numPatchCoords,
│ │ │ │ +
2001 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
2002 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ +
2003 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
2004 patchTable->GetPatchParamBuffer(),
│ │ │ │ +
2005 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2006 }
│ │ │ │ +
│ │ │ │ +
2007
│ │ │ │ +
2058 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2059 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
2060 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2062 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2063 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2064 int numPatchCoords,
│ │ │ │ +
2065 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2066 PATCH_TABLE *patchTable,
│ │ │ │ +
2067 int fvarChannel,
│ │ │ │ +
2068 CLEvaluator const *instance,
│ │ │ │ +
2069 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
2070 unsigned int numStartEvents=0,
│ │ │ │ +
2071 const cl_event* startEvents=NULL,
│ │ │ │ +
2072 cl_event* endEvent=NULL) {
│ │ │ │ +
2073
│ │ │ │ +
2074 if (instance) {
│ │ │ │ +
2075 return instance->EvalPatchesFaceVarying(
│ │ │ │ +
2076 srcBuffer, srcDesc,
│ │ │ │ +
2077 dstBuffer, dstDesc,
│ │ │ │ +
2078 numPatchCoords, patchCoords,
│ │ │ │ +
2079 patchTable, fvarChannel,
│ │ │ │ +
2080 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2081 } else {
│ │ │ │ +
2082 // Create an instance on demand (slow)
│ │ │ │ +
2083 (void)deviceContext; // unused
│ │ │ │ +
2084 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
2087 deviceContext);
│ │ │ │ +
2088 if (instance) {
│ │ │ │ +
2089 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ +
2090 srcBuffer, srcDesc,
│ │ │ │ +
2091 dstBuffer, dstDesc,
│ │ │ │ +
2092 numPatchCoords, patchCoords,
│ │ │ │ +
2093 patchTable, fvarChannel,
│ │ │ │ +
2094 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2095 delete instance;
│ │ │ │ +
2096 return r;
│ │ │ │ +
2097 }
│ │ │ │ +
2098 return false;
│ │ │ │ +
2099 }
│ │ │ │ +
2100 }
│ │ │ │ +
│ │ │ │ +
2101
│ │ │ │ +
2141 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2142 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2144 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2145 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2146 int numPatchCoords,
│ │ │ │ +
2147 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2148 PATCH_TABLE *patchTable,
│ │ │ │ +
2149 int fvarChannel = 0,
│ │ │ │ +
2150 unsigned int numStartEvents=0,
│ │ │ │ +
2151 const cl_event* startEvents=NULL,
│ │ │ │ +
2152 cl_event* endEvent=NULL) const {
│ │ │ │ +
2153
│ │ │ │ +
2154 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
2155 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
2156 0, BufferDescriptor(),
│ │ │ │ +
2157 0, BufferDescriptor(),
│ │ │ │ +
2158 numPatchCoords,
│ │ │ │ +
2159 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
2160 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ +
2161 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
2162 patchTable->GetFVarPatchParamBuffer(fvarChannel),
│ │ │ │ +
2163 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2164 }
│ │ │ │ +
│ │ │ │ +
2165
│ │ │ │ +
2228 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2229 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
2230 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2232 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2233 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2234 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
2235 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
2236 int numPatchCoords,
│ │ │ │ +
2237 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2238 PATCH_TABLE *patchTable,
│ │ │ │ +
2239 int fvarChannel,
│ │ │ │ +
2240 CLEvaluator const *instance,
│ │ │ │ +
2241 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
2242 unsigned int numStartEvents=0,
│ │ │ │ +
2243 const cl_event* startEvents=NULL,
│ │ │ │ +
2244 cl_event* endEvent=NULL) {
│ │ │ │ +
2245
│ │ │ │ +
2246 if (instance) {
│ │ │ │ +
2247 return instance->EvalPatchesFaceVarying(
│ │ │ │ +
2248 srcBuffer, srcDesc,
│ │ │ │ +
2249 dstBuffer, dstDesc,
│ │ │ │ +
2250 duBuffer, duDesc,
│ │ │ │ +
2251 dvBuffer, dvDesc,
│ │ │ │ +
2252 numPatchCoords, patchCoords,
│ │ │ │ +
2253 patchTable, fvarChannel,
│ │ │ │ +
2254 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2255 } else {
│ │ │ │ +
2256 // Create an instance on demand (slow)
│ │ │ │ +
2257 (void)deviceContext; // unused
│ │ │ │ +
2258 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
2259 duDesc, dvDesc, deviceContext);
│ │ │ │ +
2260 if (instance) {
│ │ │ │ +
2261 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ +
2262 srcBuffer, srcDesc,
│ │ │ │ +
2263 dstBuffer, dstDesc,
│ │ │ │ +
2264 duBuffer, duDesc,
│ │ │ │ +
2265 dvBuffer, dvDesc,
│ │ │ │ +
2266 numPatchCoords, patchCoords,
│ │ │ │ +
2267 patchTable, fvarChannel,
│ │ │ │ +
2268 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2269 delete instance;
│ │ │ │ +
2270 return r;
│ │ │ │ +
2271 }
│ │ │ │ +
2272 return false;
│ │ │ │ +
2273 }
│ │ │ │ +
2274 }
│ │ │ │ +
│ │ │ │ +
2275
│ │ │ │ +
2327 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2328 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2330 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2331 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2332 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
2333 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
2334 int numPatchCoords,
│ │ │ │ +
2335 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2336 PATCH_TABLE *patchTable,
│ │ │ │ +
2337 int fvarChannel = 0,
│ │ │ │ +
2338 unsigned int numStartEvents=0,
│ │ │ │ +
2339 const cl_event* startEvents=NULL,
│ │ │ │ +
2340 cl_event* endEvent=NULL) const {
│ │ │ │ +
2341
│ │ │ │ +
2342 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
2343 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
2344 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
2345 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
2346 numPatchCoords,
│ │ │ │ +
2347 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
2348 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ +
2349 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
2350 patchTable->GetFVarPatchParamBuffer(fvarChannel),
│ │ │ │ +
2351 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2352 }
│ │ │ │ +
│ │ │ │ +
2353
│ │ │ │ +
2434 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2435 typename PATCHCOORD_BUFFER, typename PATCH_TABLE,
│ │ │ │ +
2436 typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2438 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2439 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2440 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
2441 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
2442 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
2443 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
2444 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
2445 int numPatchCoords,
│ │ │ │ +
2446 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2447 PATCH_TABLE *patchTable,
│ │ │ │ +
2448 int fvarChannel,
│ │ │ │ +
2449 CLEvaluator const *instance,
│ │ │ │ +
2450 DEVICE_CONTEXT deviceContext,
│ │ │ │ +
2451 unsigned int numStartEvents=0,
│ │ │ │ +
2452 const cl_event* startEvents=NULL,
│ │ │ │ +
2453 cl_event* endEvent=NULL) {
│ │ │ │ +
2454
│ │ │ │ +
2455 if (instance) {
│ │ │ │ +
2456 return instance->EvalPatchesFaceVarying(
│ │ │ │ +
2457 srcBuffer, srcDesc,
│ │ │ │ +
2458 dstBuffer, dstDesc,
│ │ │ │ +
2459 duBuffer, duDesc,
│ │ │ │ +
2460 dvBuffer, dvDesc,
│ │ │ │ +
2461 duuBuffer, duuDesc,
│ │ │ │ +
2462 duvBuffer, duvDesc,
│ │ │ │ +
2463 dvvBuffer, dvvDesc,
│ │ │ │ +
2464 numPatchCoords, patchCoords,
│ │ │ │ +
2465 patchTable, fvarChannel,
│ │ │ │ +
2466 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2467 } else {
│ │ │ │ +
2468 // Create an instance on demand (slow)
│ │ │ │ +
2469 (void)deviceContext; // unused
│ │ │ │ +
2470 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
2471 duDesc, dvDesc,
│ │ │ │ +
2472 duuDesc, duvDesc, dvvDesc,
│ │ │ │ +
2473 deviceContext);
│ │ │ │ +
2474 if (instance) {
│ │ │ │ +
2475 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ +
2476 srcBuffer, srcDesc,
│ │ │ │ +
2477 dstBuffer, dstDesc,
│ │ │ │ +
2478 duBuffer, duDesc,
│ │ │ │ +
2479 dvBuffer, dvDesc,
│ │ │ │ +
2480 duuBuffer, duuDesc,
│ │ │ │ +
2481 duvBuffer, duvDesc,
│ │ │ │ +
2482 dvvBuffer, dvvDesc,
│ │ │ │ +
2483 numPatchCoords, patchCoords,
│ │ │ │ +
2484 patchTable, fvarChannel,
│ │ │ │ +
2485 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2486 delete instance;
│ │ │ │ +
2487 return r;
│ │ │ │ +
2488 }
│ │ │ │ +
2489 return false;
│ │ │ │ +
2490 }
│ │ │ │ +
2491 }
│ │ │ │ +
│ │ │ │ +
2492
│ │ │ │ +
2562 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2563 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2565 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2566 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2567 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
2568 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
2569 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
2570 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
2571 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
2572 int numPatchCoords,
│ │ │ │ +
2573 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2574 PATCH_TABLE *patchTable,
│ │ │ │ +
2575 int fvarChannel = 0,
│ │ │ │ +
2576 unsigned int numStartEvents=0,
│ │ │ │ +
2577 const cl_event* startEvents=NULL,
│ │ │ │ +
2578 cl_event* endEvent=NULL) const {
│ │ │ │ +
2579
│ │ │ │ +
2580 return EvalPatches(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc,
│ │ │ │ +
2581 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc,
│ │ │ │ +
2582 duBuffer->BindCLBuffer(_clCommandQueue), duDesc,
│ │ │ │ +
2583 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc,
│ │ │ │ +
2584 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc,
│ │ │ │ +
2585 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc,
│ │ │ │ +
2586 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc,
│ │ │ │ +
2587 numPatchCoords,
│ │ │ │ +
2588 patchCoords->BindCLBuffer(_clCommandQueue),
│ │ │ │ +
2589 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ +
2590 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
2591 patchTable->GetFVarPatchParamBuffer(fvarChannel),
│ │ │ │ +
2592 numStartEvents, startEvents, endEvent);
│ │ │ │ +
2593 }
│ │ │ │ +
│ │ │ │ +
2594
│ │ │ │ +
2600
│ │ │ │ +
2603 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ +
2604 BufferDescriptor const &dstDesc,
│ │ │ │ +
2605 BufferDescriptor const &duDesc = BufferDescriptor(),
│ │ │ │ +
2606 BufferDescriptor const &dvDesc = BufferDescriptor(),
│ │ │ │ +
2607 BufferDescriptor const &duuDesc = BufferDescriptor(),
│ │ │ │ +
2608 BufferDescriptor const &duvDesc = BufferDescriptor(),
│ │ │ │ +
2609 BufferDescriptor const &dvvDesc = BufferDescriptor());
│ │ │ │ +
2610
│ │ │ │ +
2612 template <typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
2613 static void Synchronize(DEVICE_CONTEXT deviceContext) {
│ │ │ │ +
2614 Synchronize(deviceContext->GetCommandQueue());
│ │ │ │ +
2615 }
│ │ │ │ +
│ │ │ │ +
2616
│ │ │ │ +
2617 static void Synchronize(cl_command_queue queue);
│ │ │ │ +
2618
│ │ │ │ +
2619private:
│ │ │ │ +
2620 cl_context _clContext;
│ │ │ │ +
2621 cl_command_queue _clCommandQueue;
│ │ │ │ +
2622 cl_program _program;
│ │ │ │ +
2623 cl_kernel _stencilKernel;
│ │ │ │ +
2624 cl_kernel _stencilDerivKernel;
│ │ │ │ +
2625 cl_kernel _patchKernel;
│ │ │ │ +
2626};
│ │ │ │ +
│ │ │ │ +
2627
│ │ │ │ +
2628} // end namespace Osd
│ │ │ │ +
2629
│ │ │ │ +
2630} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
2631using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
2632
│ │ │ │ +
2633} // end namespace OpenSubdiv
│ │ │ │ +
2634
│ │ │ │ +
2635
│ │ │ │ +
2636#endif // OPENSUBDIV3_OSD_CL_EVALUATOR_H
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ + │ │ │ │ +
CLStencilTable(Far::StencilTable const *stencilTable, cl_context clContext)
│ │ │ │ + │ │ │ │ +
static CLStencilTable * Create(Far::LimitStencilTable const *limitStencilTable, DEVICE_CONTEXT context)
Definition clEvaluator.h:61
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
static CLStencilTable * Create(Far::StencilTable const *stencilTable, DEVICE_CONTEXT context)
Definition clEvaluator.h:55
│ │ │ │ +
CLStencilTable(Far::LimitStencilTable const *limitStencilTable, cl_context clContext)
│ │ │ │ + │ │ │ │ + │ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
static void Synchronize(cl_command_queue queue)
│ │ │ │ + │ │ │ │ +
bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, cl_mem weights, cl_mem duWeights, cl_mem dvWeights, int start, int end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Dispatch the CL compute kernel asynchronously. returns false if the kernel hasn't been compiled yet.
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, cl_context clContext, cl_command_queue clCommandQueue)
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, int numPatchCoords, cl_mem patchCoordsBuffer, cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem patchParamsBuffer, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
│ │ │ │ +
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic stencil function.
│ │ │ │ +
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ + │ │ │ │ +
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, DEVICE_CONTEXT deviceContext)
Generic creator template.
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, DEVICE_CONTEXT deviceContext)
Generic creator template.
│ │ │ │ +
bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const &duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, BufferDescriptor const &dvvDesc, int numPatchCoords, cl_mem patchCoordsBuffer, cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem patchParamsBuffer, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
│ │ │ │ +
bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const &duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, BufferDescriptor const &dvvDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, cl_mem weights, cl_mem duWeights, cl_mem dvWeights, cl_mem duuWeights, cl_mem duvWeights, cl_mem dvvWeights, int start, int end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Dispatch the CL compute kernel asynchronously. returns false if the kernel hasn't been compiled yet.
│ │ │ │ +
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic stencil function.
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static void Synchronize(DEVICE_CONTEXT deviceContext)
Wait the OpenCL kernels finish.
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, BufferDescriptor const &dstDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, cl_mem weights, int start, int end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, cl_context clContext, cl_command_queue clCommandQueue)
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic stencil function.
│ │ │ │ +
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ +
CLEvaluator(cl_context context, cl_command_queue queue)
Constructor.
│ │ │ │ +
bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const &dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const &dvvDesc=BufferDescriptor())
│ │ │ │ +
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -mtlCommon.h │ │ │ │ │ +clEvaluator.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2013 Pixar │ │ │ │ │ +2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -24,50 +24,1553 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_MTL_COMMON_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_MTL_COMMON_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_CL_EVALUATOR_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_CL_EVALUATOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include │ │ │ │ │ -31 │ │ │ │ │ -32@protocol MTLDevice; │ │ │ │ │ -33@protocol MTLCommandQueue; │ │ │ │ │ -34 │ │ │ │ │ -35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -36namespace OPENSUBDIV_VERSION { │ │ │ │ │ -37 │ │ │ │ │ -38namespace Osd { │ │ │ │ │ -39 │ │ │ │ │ -_4_0class _M_T_L_C_o_n_t_e_x_t { │ │ │ │ │ -41public: │ │ │ │ │ -_4_2 id _d_e_v_i_c_e = nullptr; │ │ │ │ │ -_4_3 id _c_o_m_m_a_n_d_Q_u_e_u_e = nullptr; │ │ │ │ │ -44}; │ │ │ │ │ -45 │ │ │ │ │ -46} // end namespace Osd │ │ │ │ │ -47 │ │ │ │ │ -48} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -49using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -50 │ │ │ │ │ -51} // end namespace OpenSubdiv │ │ │ │ │ -52 │ │ │ │ │ -53#endif //OPENSUBDIV3_OSD_MTL_COMMON_H │ │ │ │ │ +30#include "../osd/opencl.h" │ │ │ │ │ +31#include "../osd/types.h" │ │ │ │ │ +32#include "../osd/bufferDescriptor.h" │ │ │ │ │ +33 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Far { │ │ │ │ │ +38 class PatchTable; │ │ │ │ │ +39 class StencilTable; │ │ │ │ │ +40 class LimitStencilTable; │ │ │ │ │ +41} │ │ │ │ │ +42 │ │ │ │ │ +43namespace Osd { │ │ │ │ │ +44 │ │ │ │ │ +_5_2class _C_L_S_t_e_n_c_i_l_T_a_b_l_e { │ │ │ │ │ +53public: │ │ │ │ │ +54 template │ │ │ │ │ +_5_5 static _C_L_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ +56 DEVICE_CONTEXT context) { │ │ │ │ │ +57 return new _C_L_S_t_e_n_c_i_l_T_a_b_l_e(stencilTable, context->GetContext()); │ │ │ │ │ +58 } │ │ │ │ │ +59 │ │ │ │ │ +60 template │ │ │ │ │ +_6_1 static _C_L_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e( │ │ │ │ │ +62 _F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *limitStencilTable, │ │ │ │ │ +63 DEVICE_CONTEXT context) { │ │ │ │ │ +64 return new _C_L_S_t_e_n_c_i_l_T_a_b_l_e(limitStencilTable, context->GetContext()); │ │ │ │ │ +65 } │ │ │ │ │ +66 │ │ │ │ │ +_6_7 _C_L_S_t_e_n_c_i_l_T_a_b_l_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ +68 cl_context clContext); │ │ │ │ │ +_6_9 _C_L_S_t_e_n_c_i_l_T_a_b_l_e(_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *limitStencilTable, │ │ │ │ │ +70 cl_context clContext); │ │ │ │ │ +_7_1 _~_C_L_S_t_e_n_c_i_l_T_a_b_l_e(); │ │ │ │ │ +72 │ │ │ │ │ +73 // interfaces needed for CLComputeKernel │ │ │ │ │ +_7_4 cl_mem _G_e_t_S_i_z_e_s_B_u_f_f_e_r() const { return _sizes; } │ │ │ │ │ +_7_5 cl_mem _G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r() const { return _offsets; } │ │ │ │ │ +_7_6 cl_mem _G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r() const { return _indices; } │ │ │ │ │ +_7_7 cl_mem _G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _weights; } │ │ │ │ │ +_7_8 cl_mem _G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duWeights; } │ │ │ │ │ +_7_9 cl_mem _G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvWeights; } │ │ │ │ │ +_8_0 cl_mem _G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duuWeights; } │ │ │ │ │ +_8_1 cl_mem _G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duvWeights; } │ │ │ │ │ +_8_2 cl_mem _G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvvWeights; } │ │ │ │ │ +_8_3 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { return _numStencils; } │ │ │ │ │ +84 │ │ │ │ │ +85private: │ │ │ │ │ +86 cl_mem _sizes; │ │ │ │ │ +87 cl_mem _offsets; │ │ │ │ │ +88 cl_mem _indices; │ │ │ │ │ +89 cl_mem _weights; │ │ │ │ │ +90 cl_mem _duWeights; │ │ │ │ │ +91 cl_mem _dvWeights; │ │ │ │ │ +92 cl_mem _duuWeights; │ │ │ │ │ +93 cl_mem _duvWeights; │ │ │ │ │ +94 cl_mem _dvvWeights; │ │ │ │ │ +95 int _numStencils; │ │ │ │ │ +96}; │ │ │ │ │ +97 │ │ │ │ │ +98// -------------------------------------------------------------------------- │ │ │ │ │ +- │ │ │ │ │ +99 │ │ │ │ │ +_1_0_0class _C_L_E_v_a_l_u_a_t_o_r { │ │ │ │ │ +101public: │ │ │ │ │ +_1_0_2 typedef bool _I_n_s_t_a_n_t_i_a_t_a_b_l_e; │ │ │ │ │ +103 │ │ │ │ │ +105 template │ │ │ │ │ +_1_0_6 static _C_L_E_v_a_l_u_a_t_o_r *_C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +107 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +108 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +109 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +110 DEVICE_CONTEXT deviceContext) { │ │ │ │ │ +111 return _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +112 deviceContext->GetContext(), │ │ │ │ │ +113 deviceContext->GetCommandQueue()); │ │ │ │ │ +114 } │ │ │ │ │ +115 │ │ │ │ │ +_1_1_6 static _C_L_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +117 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +118 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +119 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +120 cl_context clContext, │ │ │ │ │ +121 cl_command_queue clCommandQueue) { │ │ │ │ │ +122 _C_L_E_v_a_l_u_a_t_o_r *instance = new _C_L_E_v_a_l_u_a_t_o_r(clContext, clCommandQueue); │ │ │ │ │ +123 if (instance->_C_o_m_p_i_l_e(srcDesc, dstDesc, duDesc, dvDesc)) │ │ │ │ │ +124 return instance; │ │ │ │ │ +125 delete instance; │ │ │ │ │ +126 return NULL; │ │ │ │ │ +127 } │ │ │ │ │ +128 │ │ │ │ │ +130 template │ │ │ │ │ +_1_3_1 static _C_L_E_v_a_l_u_a_t_o_r *_C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +132 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +133 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +134 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +135 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +136 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +137 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +138 DEVICE_CONTEXT deviceContext) { │ │ │ │ │ +139 return _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +140 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ +141 deviceContext->GetContext(), │ │ │ │ │ +142 deviceContext->GetCommandQueue()); │ │ │ │ │ +143 } │ │ │ │ │ +144 │ │ │ │ │ +_1_4_5 static _C_L_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +146 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +147 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +148 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +149 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +150 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +151 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +152 cl_context clContext, │ │ │ │ │ +153 cl_command_queue clCommandQueue) { │ │ │ │ │ +154 _C_L_E_v_a_l_u_a_t_o_r *instance = new _C_L_E_v_a_l_u_a_t_o_r(clContext, clCommandQueue); │ │ │ │ │ +155 if (instance->_C_o_m_p_i_l_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +156 duuDesc, duvDesc, dvvDesc)) │ │ │ │ │ +157 return instance; │ │ │ │ │ +158 delete instance; │ │ │ │ │ +159 return NULL; │ │ │ │ │ +160 } │ │ │ │ │ +161 │ │ │ │ │ +_1_6_3 _C_L_E_v_a_l_u_a_t_o_r(cl_context context, cl_command_queue queue); │ │ │ │ │ +164 │ │ │ │ │ +_1_6_6 _~_C_L_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ +167 │ │ │ │ │ +173 │ │ │ │ │ +217 template │ │ │ │ │ +_2_1_9 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +220 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +221 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +222 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +223 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +224 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +225 unsigned int numStartEvents=0, │ │ │ │ │ +226 const cl_event* startEvents=NULL, │ │ │ │ │ +227 cl_event* endEvent=NULL) { │ │ │ │ │ +228 │ │ │ │ │ +229 if (instance) { │ │ │ │ │ +230 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +231 dstBuffer, dstDesc, │ │ │ │ │ +232 stencilTable, │ │ │ │ │ +233 numStartEvents, startEvents, endEvent); │ │ │ │ │ +234 } else { │ │ │ │ │ +235 // Create an instance on demand (slow) │ │ │ │ │ +236 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +237 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +238 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +239 deviceContext); │ │ │ │ │ +240 if (instance) { │ │ │ │ │ +241 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +242 dstBuffer, dstDesc, │ │ │ │ │ +243 stencilTable, │ │ │ │ │ +244 numStartEvents, startEvents, endEvent); │ │ │ │ │ +245 delete instance; │ │ │ │ │ +246 return r; │ │ │ │ │ +247 } │ │ │ │ │ +248 return false; │ │ │ │ │ +249 } │ │ │ │ │ +250 } │ │ │ │ │ +251 │ │ │ │ │ +307 template │ │ │ │ │ +_3_0_9 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +310 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +311 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +312 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +313 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +314 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +315 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +316 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +317 unsigned int numStartEvents=0, │ │ │ │ │ +318 const cl_event* startEvents=NULL, │ │ │ │ │ +319 cl_event* endEvent=NULL) { │ │ │ │ │ +320 │ │ │ │ │ +321 if (instance) { │ │ │ │ │ +322 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +323 dstBuffer, dstDesc, │ │ │ │ │ +324 duBuffer, duDesc, │ │ │ │ │ +325 dvBuffer, dvDesc, │ │ │ │ │ +326 stencilTable, │ │ │ │ │ +327 numStartEvents, startEvents, endEvent); │ │ │ │ │ +328 } else { │ │ │ │ │ +329 // Create an instance on demand (slow) │ │ │ │ │ +330 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +331 deviceContext); │ │ │ │ │ +332 if (instance) { │ │ │ │ │ +333 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +334 dstBuffer, dstDesc, │ │ │ │ │ +335 duBuffer, duDesc, │ │ │ │ │ +336 dvBuffer, dvDesc, │ │ │ │ │ +337 stencilTable, │ │ │ │ │ +338 numStartEvents, startEvents, endEvent); │ │ │ │ │ +339 delete instance; │ │ │ │ │ +340 return r; │ │ │ │ │ +341 } │ │ │ │ │ +342 return false; │ │ │ │ │ +343 } │ │ │ │ │ +344 } │ │ │ │ │ +345 │ │ │ │ │ +419 template │ │ │ │ │ +_4_2_1 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +422 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +423 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +424 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +425 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +426 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +427 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +428 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +429 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +430 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +431 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +432 unsigned int numStartEvents=0, │ │ │ │ │ +433 const cl_event* startEvents=NULL, │ │ │ │ │ +434 cl_event* endEvent=NULL) { │ │ │ │ │ +435 │ │ │ │ │ +436 if (instance) { │ │ │ │ │ +437 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +438 dstBuffer, dstDesc, │ │ │ │ │ +439 duBuffer, duDesc, │ │ │ │ │ +440 dvBuffer, dvDesc, │ │ │ │ │ +441 duuBuffer, duuDesc, │ │ │ │ │ +442 duvBuffer, duvDesc, │ │ │ │ │ +443 dvvBuffer, dvvDesc, │ │ │ │ │ +444 stencilTable, │ │ │ │ │ +445 numStartEvents, startEvents, endEvent); │ │ │ │ │ +446 } else { │ │ │ │ │ +447 // Create an instance on demand (slow) │ │ │ │ │ +448 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +449 duDesc, dvDesc, │ │ │ │ │ +450 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ +451 deviceContext); │ │ │ │ │ +452 if (instance) { │ │ │ │ │ +453 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +454 dstBuffer, dstDesc, │ │ │ │ │ +455 duBuffer, duDesc, │ │ │ │ │ +456 dvBuffer, dvDesc, │ │ │ │ │ +457 duuBuffer, duuDesc, │ │ │ │ │ +458 duvBuffer, duvDesc, │ │ │ │ │ +459 dvvBuffer, dvvDesc, │ │ │ │ │ +460 stencilTable, │ │ │ │ │ +461 numStartEvents, startEvents, endEvent); │ │ │ │ │ +462 delete instance; │ │ │ │ │ +463 return r; │ │ │ │ │ +464 } │ │ │ │ │ +465 return false; │ │ │ │ │ +466 } │ │ │ │ │ +467 } │ │ │ │ │ +468 │ │ │ │ │ +499 template │ │ │ │ │ +_5_0_0 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +501 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +502 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +503 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +504 unsigned int numStartEvents=0, │ │ │ │ │ +505 const cl_event* startEvents=NULL, │ │ │ │ │ +506 cl_event* endEvent=NULL) const { │ │ │ │ │ +507 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +508 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +509 stencilTable->GetSizesBuffer(), │ │ │ │ │ +510 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ +511 stencilTable->GetIndicesBuffer(), │ │ │ │ │ +512 stencilTable->GetWeightsBuffer(), │ │ │ │ │ +513 0, │ │ │ │ │ +514 stencilTable->GetNumStencils(), │ │ │ │ │ +515 numStartEvents, startEvents, endEvent); │ │ │ │ │ +516 } │ │ │ │ │ +517 │ │ │ │ │ +560 template │ │ │ │ │ +_5_6_1 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +562 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +563 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +564 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +565 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +566 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +567 unsigned int numStartEvents=0, │ │ │ │ │ +568 const cl_event* startEvents=NULL, │ │ │ │ │ +569 cl_event* endEvent=NULL) const { │ │ │ │ │ +570 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +571 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +572 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +573 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +574 stencilTable->GetSizesBuffer(), │ │ │ │ │ +575 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ +576 stencilTable->GetIndicesBuffer(), │ │ │ │ │ +577 stencilTable->GetWeightsBuffer(), │ │ │ │ │ +578 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ +579 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ +580 0, │ │ │ │ │ +581 stencilTable->GetNumStencils(), │ │ │ │ │ +582 numStartEvents, startEvents, endEvent); │ │ │ │ │ +583 } │ │ │ │ │ +584 │ │ │ │ │ +645 template │ │ │ │ │ +_6_4_6 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +647 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +648 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +649 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +650 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +651 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +652 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +653 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +654 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +655 unsigned int numStartEvents=0, │ │ │ │ │ +656 const cl_event* startEvents=NULL, │ │ │ │ │ +657 cl_event* endEvent=NULL) const { │ │ │ │ │ +658 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +659 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +660 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +661 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +662 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ +663 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ +664 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ +665 stencilTable->GetSizesBuffer(), │ │ │ │ │ +666 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ +667 stencilTable->GetIndicesBuffer(), │ │ │ │ │ +668 stencilTable->GetWeightsBuffer(), │ │ │ │ │ +669 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ +670 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ +671 stencilTable->GetDuuWeightsBuffer(), │ │ │ │ │ +672 stencilTable->GetDuvWeightsBuffer(), │ │ │ │ │ +673 stencilTable->GetDvvWeightsBuffer(), │ │ │ │ │ +674 0, │ │ │ │ │ +675 stencilTable->GetNumStencils(), │ │ │ │ │ +676 numStartEvents, startEvents, endEvent); │ │ │ │ │ +677 } │ │ │ │ │ +678 │ │ │ │ │ +_6_8_1 bool _E_v_a_l_S_t_e_n_c_i_l_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +682 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +683 cl_mem sizes, │ │ │ │ │ +684 cl_mem offsets, │ │ │ │ │ +685 cl_mem indices, │ │ │ │ │ +686 cl_mem weights, │ │ │ │ │ +687 int start, │ │ │ │ │ +688 int end, │ │ │ │ │ +689 unsigned int numStartEvents=0, │ │ │ │ │ +690 const cl_event* startEvents=NULL, │ │ │ │ │ +691 cl_event* endEvent=NULL) const; │ │ │ │ │ +692 │ │ │ │ │ +_7_4_1 bool _E_v_a_l_S_t_e_n_c_i_l_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +742 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +743 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +744 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +745 cl_mem sizes, │ │ │ │ │ +746 cl_mem offsets, │ │ │ │ │ +747 cl_mem indices, │ │ │ │ │ +748 cl_mem weights, │ │ │ │ │ +749 cl_mem duWeights, │ │ │ │ │ +750 cl_mem dvWeights, │ │ │ │ │ +751 int start, │ │ │ │ │ +752 int end, │ │ │ │ │ +753 unsigned int numStartEvents=0, │ │ │ │ │ +754 const cl_event* startEvents=NULL, │ │ │ │ │ +755 cl_event* endEvent=NULL) const; │ │ │ │ │ +756 │ │ │ │ │ +_8_2_3 bool _E_v_a_l_S_t_e_n_c_i_l_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +824 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +825 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +826 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +827 cl_mem duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +828 cl_mem duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +829 cl_mem dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +830 cl_mem sizes, │ │ │ │ │ +831 cl_mem offsets, │ │ │ │ │ +832 cl_mem indices, │ │ │ │ │ +833 cl_mem weights, │ │ │ │ │ +834 cl_mem duWeights, │ │ │ │ │ +835 cl_mem dvWeights, │ │ │ │ │ +836 cl_mem duuWeights, │ │ │ │ │ +837 cl_mem duvWeights, │ │ │ │ │ +838 cl_mem dvvWeights, │ │ │ │ │ +839 int start, │ │ │ │ │ +840 int end, │ │ │ │ │ +841 unsigned int numStartEvents=0, │ │ │ │ │ +842 const cl_event* startEvents=NULL, │ │ │ │ │ +843 cl_event* endEvent=NULL) const; │ │ │ │ │ +844 │ │ │ │ │ +850 │ │ │ │ │ +899 template │ │ │ │ │ +_9_0_2 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +903 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +904 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +905 int numPatchCoords, │ │ │ │ │ +906 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +907 PATCH_TABLE *patchTable, │ │ │ │ │ +908 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +909 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +910 unsigned int numStartEvents=0, │ │ │ │ │ +911 const cl_event* startEvents=NULL, │ │ │ │ │ +912 cl_event* endEvent=NULL) { │ │ │ │ │ +913 │ │ │ │ │ +914 if (instance) { │ │ │ │ │ +915 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +916 dstBuffer, dstDesc, │ │ │ │ │ +917 numPatchCoords, patchCoords, │ │ │ │ │ +918 patchTable, │ │ │ │ │ +919 numStartEvents, startEvents, endEvent); │ │ │ │ │ +920 } else { │ │ │ │ │ +921 // Create an instance on demand (slow) │ │ │ │ │ +922 (void)deviceContext; // unused │ │ │ │ │ +923 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +924 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +925 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +926 deviceContext); │ │ │ │ │ +927 if (instance) { │ │ │ │ │ +928 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +929 dstBuffer, dstDesc, │ │ │ │ │ +930 numPatchCoords, patchCoords, │ │ │ │ │ +931 patchTable, │ │ │ │ │ +932 numStartEvents, startEvents, endEvent); │ │ │ │ │ +933 delete instance; │ │ │ │ │ +934 return r; │ │ │ │ │ +935 } │ │ │ │ │ +936 return false; │ │ │ │ │ +937 } │ │ │ │ │ +938 } │ │ │ │ │ +939 │ │ │ │ │ +1000 template │ │ │ │ │ +_1_0_0_3 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +1004 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1005 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1006 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1007 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1008 int numPatchCoords, │ │ │ │ │ +1009 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1010 PATCH_TABLE *patchTable, │ │ │ │ │ +1011 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1012 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +1013 unsigned int numStartEvents=0, │ │ │ │ │ +1014 const cl_event* startEvents=NULL, │ │ │ │ │ +1015 cl_event* endEvent=NULL) { │ │ │ │ │ +1016 │ │ │ │ │ +1017 if (instance) { │ │ │ │ │ +1018 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +1019 dstBuffer, dstDesc, │ │ │ │ │ +1020 duBuffer, duDesc, │ │ │ │ │ +1021 dvBuffer, dvDesc, │ │ │ │ │ +1022 numPatchCoords, patchCoords, │ │ │ │ │ +1023 patchTable, │ │ │ │ │ +1024 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1025 } else { │ │ │ │ │ +1026 // Create an instance on demand (slow) │ │ │ │ │ +1027 (void)deviceContext; // unused │ │ │ │ │ +1028 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, deviceContext); │ │ │ │ │ +1029 if (instance) { │ │ │ │ │ +1030 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +1031 dstBuffer, dstDesc, │ │ │ │ │ +1032 duBuffer, duDesc, │ │ │ │ │ +1033 dvBuffer, dvDesc, │ │ │ │ │ +1034 numPatchCoords, patchCoords, │ │ │ │ │ +1035 patchTable, │ │ │ │ │ +1036 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1037 delete instance; │ │ │ │ │ +1038 return r; │ │ │ │ │ +1039 } │ │ │ │ │ +1040 return false; │ │ │ │ │ +1041 } │ │ │ │ │ +1042 } │ │ │ │ │ +1043 │ │ │ │ │ +1122 template │ │ │ │ │ +_1_1_2_5 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +1126 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1127 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1128 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1129 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1130 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1131 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1132 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1133 int numPatchCoords, │ │ │ │ │ +1134 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1135 PATCH_TABLE *patchTable, │ │ │ │ │ +1136 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1137 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +1138 unsigned int numStartEvents=0, │ │ │ │ │ +1139 const cl_event* startEvents=NULL, │ │ │ │ │ +1140 cl_event* endEvent=NULL) { │ │ │ │ │ +1141 │ │ │ │ │ +1142 if (instance) { │ │ │ │ │ +1143 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +1144 dstBuffer, dstDesc, │ │ │ │ │ +1145 duBuffer, duDesc, │ │ │ │ │ +1146 dvBuffer, dvDesc, │ │ │ │ │ +1147 duuBuffer, duuDesc, │ │ │ │ │ +1148 duvBuffer, duvDesc, │ │ │ │ │ +1149 dvvBuffer, dvvDesc, │ │ │ │ │ +1150 numPatchCoords, patchCoords, │ │ │ │ │ +1151 patchTable, │ │ │ │ │ +1152 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1153 } else { │ │ │ │ │ +1154 // Create an instance on demand (slow) │ │ │ │ │ +1155 (void)deviceContext; // unused │ │ │ │ │ +1156 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1157 duDesc, dvDesc, │ │ │ │ │ +1158 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ +1159 deviceContext); │ │ │ │ │ +1160 if (instance) { │ │ │ │ │ +1161 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +1162 dstBuffer, dstDesc, │ │ │ │ │ +1163 duBuffer, duDesc, │ │ │ │ │ +1164 dvBuffer, dvDesc, │ │ │ │ │ +1165 duuBuffer, duuDesc, │ │ │ │ │ +1166 duvBuffer, duvDesc, │ │ │ │ │ +1167 dvvBuffer, dvvDesc, │ │ │ │ │ +1168 numPatchCoords, patchCoords, │ │ │ │ │ +1169 patchTable, │ │ │ │ │ +1170 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1171 delete instance; │ │ │ │ │ +1172 return r; │ │ │ │ │ +1173 } │ │ │ │ │ +1174 return false; │ │ │ │ │ +1175 } │ │ │ │ │ +1176 } │ │ │ │ │ +1177 │ │ │ │ │ +1215 template │ │ │ │ │ +_1_2_1_7 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +1218 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1219 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1220 int numPatchCoords, │ │ │ │ │ +1221 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1222 PATCH_TABLE *patchTable, │ │ │ │ │ +1223 unsigned int numStartEvents=0, │ │ │ │ │ +1224 const cl_event* startEvents=NULL, │ │ │ │ │ +1225 cl_event* endEvent=NULL) const { │ │ │ │ │ +1226 │ │ │ │ │ +1227 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +1228 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +1229 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1230 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1231 numPatchCoords, │ │ │ │ │ +1232 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +1233 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ +1234 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +1235 patchTable->GetPatchParamBuffer(), │ │ │ │ │ +1236 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1237 } │ │ │ │ │ +1238 │ │ │ │ │ +1286 template │ │ │ │ │ +_1_2_8_8 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +1289 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1290 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1291 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1292 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1293 int numPatchCoords, │ │ │ │ │ +1294 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1295 PATCH_TABLE *patchTable, │ │ │ │ │ +1296 unsigned int numStartEvents=0, │ │ │ │ │ +1297 const cl_event* startEvents=NULL, │ │ │ │ │ +1298 cl_event* endEvent=NULL) const { │ │ │ │ │ +1299 │ │ │ │ │ +1300 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +1301 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +1302 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +1303 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +1304 numPatchCoords, │ │ │ │ │ +1305 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +1306 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ +1307 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +1308 patchTable->GetPatchParamBuffer(), │ │ │ │ │ +1309 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1310 } │ │ │ │ │ +1311 │ │ │ │ │ +1377 template │ │ │ │ │ +_1_3_7_9 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +1380 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1381 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1382 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1383 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1384 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1385 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1386 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1387 int numPatchCoords, │ │ │ │ │ +1388 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1389 PATCH_TABLE *patchTable, │ │ │ │ │ +1390 unsigned int numStartEvents=0, │ │ │ │ │ +1391 const cl_event* startEvents=NULL, │ │ │ │ │ +1392 cl_event* endEvent=NULL) const { │ │ │ │ │ +1393 │ │ │ │ │ +1394 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +1395 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +1396 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +1397 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +1398 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ +1399 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ +1400 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ +1401 numPatchCoords, │ │ │ │ │ +1402 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +1403 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ +1404 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +1405 patchTable->GetPatchParamBuffer(), │ │ │ │ │ +1406 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1407 } │ │ │ │ │ +1408 │ │ │ │ │ +_1_4_0_9 bool _E_v_a_l_P_a_t_c_h_e_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1410 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1411 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1412 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1413 int numPatchCoords, │ │ │ │ │ +1414 cl_mem patchCoordsBuffer, │ │ │ │ │ +1415 cl_mem patchArrayBuffer, │ │ │ │ │ +1416 cl_mem patchIndexBuffer, │ │ │ │ │ +1417 cl_mem patchParamsBuffer, │ │ │ │ │ +1418 unsigned int numStartEvents=0, │ │ │ │ │ +1419 const cl_event* startEvents=NULL, │ │ │ │ │ +1420 cl_event* endEvent=NULL) const; │ │ │ │ │ +1421 │ │ │ │ │ +_1_4_2_2 bool _E_v_a_l_P_a_t_c_h_e_s(cl_mem src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1423 cl_mem dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1424 cl_mem du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1425 cl_mem dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1426 cl_mem duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1427 cl_mem duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1428 cl_mem dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1429 int numPatchCoords, │ │ │ │ │ +1430 cl_mem patchCoordsBuffer, │ │ │ │ │ +1431 cl_mem patchArrayBuffer, │ │ │ │ │ +1432 cl_mem patchIndexBuffer, │ │ │ │ │ +1433 cl_mem patchParamsBuffer, │ │ │ │ │ +1434 unsigned int numStartEvents=0, │ │ │ │ │ +1435 const cl_event* startEvents=NULL, │ │ │ │ │ +1436 cl_event* endEvent=NULL) const; │ │ │ │ │ +1437 │ │ │ │ │ +1486 template │ │ │ │ │ +_1_4_8_9 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1490 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1491 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1492 int numPatchCoords, │ │ │ │ │ +1493 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1494 PATCH_TABLE *patchTable, │ │ │ │ │ +1495 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1496 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +1497 unsigned int numStartEvents=0, │ │ │ │ │ +1498 const cl_event* startEvents=NULL, │ │ │ │ │ +1499 cl_event* endEvent=NULL) { │ │ │ │ │ +1500 │ │ │ │ │ +1501 if (instance) { │ │ │ │ │ +1502 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1503 srcBuffer, srcDesc, │ │ │ │ │ +1504 dstBuffer, dstDesc, │ │ │ │ │ +1505 numPatchCoords, patchCoords, │ │ │ │ │ +1506 patchTable, │ │ │ │ │ +1507 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1508 } else { │ │ │ │ │ +1509 // Create an instance on demand (slow) │ │ │ │ │ +1510 (void)deviceContext; // unused │ │ │ │ │ +1511 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1512 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1513 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1514 deviceContext); │ │ │ │ │ +1515 if (instance) { │ │ │ │ │ +1516 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1517 srcBuffer, srcDesc, │ │ │ │ │ +1518 dstBuffer, dstDesc, │ │ │ │ │ +1519 numPatchCoords, patchCoords, │ │ │ │ │ +1520 patchTable, │ │ │ │ │ +1521 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1522 delete instance; │ │ │ │ │ +1523 return r; │ │ │ │ │ +1524 } │ │ │ │ │ +1525 return false; │ │ │ │ │ +1526 } │ │ │ │ │ +1527 } │ │ │ │ │ +1528 │ │ │ │ │ +1566 template │ │ │ │ │ +_1_5_6_8 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1569 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1570 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1571 int numPatchCoords, │ │ │ │ │ +1572 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1573 PATCH_TABLE *patchTable, │ │ │ │ │ +1574 unsigned int numStartEvents=0, │ │ │ │ │ +1575 const cl_event* startEvents=NULL, │ │ │ │ │ +1576 cl_event* endEvent=NULL) const { │ │ │ │ │ +1577 │ │ │ │ │ +1578 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +1579 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +1580 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1581 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1582 numPatchCoords, │ │ │ │ │ +1583 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +1584 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ +1585 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +1586 patchTable->GetPatchParamBuffer(), │ │ │ │ │ +1587 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1588 } │ │ │ │ │ +1589 │ │ │ │ │ +1650 template │ │ │ │ │ +_1_6_5_3 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1654 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1655 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1656 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1657 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1658 int numPatchCoords, │ │ │ │ │ +1659 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1660 PATCH_TABLE *patchTable, │ │ │ │ │ +1661 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1662 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +1663 unsigned int numStartEvents=0, │ │ │ │ │ +1664 const cl_event* startEvents=NULL, │ │ │ │ │ +1665 cl_event* endEvent=NULL) { │ │ │ │ │ +1666 │ │ │ │ │ +1667 if (instance) { │ │ │ │ │ +1668 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1669 srcBuffer, srcDesc, │ │ │ │ │ +1670 dstBuffer, dstDesc, │ │ │ │ │ +1671 duBuffer, duDesc, │ │ │ │ │ +1672 dvBuffer, dvDesc, │ │ │ │ │ +1673 numPatchCoords, patchCoords, │ │ │ │ │ +1674 patchTable, │ │ │ │ │ +1675 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1676 } else { │ │ │ │ │ +1677 // Create an instance on demand (slow) │ │ │ │ │ +1678 (void)deviceContext; // unused │ │ │ │ │ +1679 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1680 duDesc, dvDesc, │ │ │ │ │ +1681 deviceContext); │ │ │ │ │ +1682 if (instance) { │ │ │ │ │ +1683 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1684 srcBuffer, srcDesc, │ │ │ │ │ +1685 dstBuffer, dstDesc, │ │ │ │ │ +1686 duBuffer, duDesc, │ │ │ │ │ +1687 dvBuffer, dvDesc, │ │ │ │ │ +1688 numPatchCoords, patchCoords, │ │ │ │ │ +1689 patchTable, │ │ │ │ │ +1690 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1691 delete instance; │ │ │ │ │ +1692 return r; │ │ │ │ │ +1693 } │ │ │ │ │ +1694 return false; │ │ │ │ │ +1695 } │ │ │ │ │ +1696 } │ │ │ │ │ +1697 │ │ │ │ │ +1747 template │ │ │ │ │ +_1_7_4_9 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1750 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1751 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1752 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1753 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1754 int numPatchCoords, │ │ │ │ │ +1755 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1756 PATCH_TABLE *patchTable, │ │ │ │ │ +1757 unsigned int numStartEvents=0, │ │ │ │ │ +1758 const cl_event* startEvents=NULL, │ │ │ │ │ +1759 cl_event* endEvent=NULL) const { │ │ │ │ │ +1760 │ │ │ │ │ +1761 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +1762 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +1763 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +1764 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +1765 numPatchCoords, │ │ │ │ │ +1766 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +1767 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ +1768 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +1769 patchTable->GetPatchParamBuffer(), │ │ │ │ │ +1770 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1771 } │ │ │ │ │ +1772 │ │ │ │ │ +1851 template │ │ │ │ │ +_1_8_5_4 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1855 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1856 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1857 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1858 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1859 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1860 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1861 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1862 int numPatchCoords, │ │ │ │ │ +1863 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1864 PATCH_TABLE *patchTable, │ │ │ │ │ +1865 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1866 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +1867 unsigned int numStartEvents=0, │ │ │ │ │ +1868 const cl_event* startEvents=NULL, │ │ │ │ │ +1869 cl_event* endEvent=NULL) { │ │ │ │ │ +1870 │ │ │ │ │ +1871 if (instance) { │ │ │ │ │ +1872 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1873 srcBuffer, srcDesc, │ │ │ │ │ +1874 dstBuffer, dstDesc, │ │ │ │ │ +1875 duBuffer, duDesc, │ │ │ │ │ +1876 dvBuffer, dvDesc, │ │ │ │ │ +1877 duuBuffer, duuDesc, │ │ │ │ │ +1878 duvBuffer, duvDesc, │ │ │ │ │ +1879 dvvBuffer, dvvDesc, │ │ │ │ │ +1880 numPatchCoords, patchCoords, │ │ │ │ │ +1881 patchTable, │ │ │ │ │ +1882 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1883 } else { │ │ │ │ │ +1884 // Create an instance on demand (slow) │ │ │ │ │ +1885 (void)deviceContext; // unused │ │ │ │ │ +1886 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1887 duDesc, dvDesc, │ │ │ │ │ +1888 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ +1889 deviceContext); │ │ │ │ │ +1890 if (instance) { │ │ │ │ │ +1891 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1892 srcBuffer, srcDesc, │ │ │ │ │ +1893 dstBuffer, dstDesc, │ │ │ │ │ +1894 duBuffer, duDesc, │ │ │ │ │ +1895 dvBuffer, dvDesc, │ │ │ │ │ +1896 duuBuffer, duuDesc, │ │ │ │ │ +1897 duvBuffer, duvDesc, │ │ │ │ │ +1898 dvvBuffer, dvvDesc, │ │ │ │ │ +1899 numPatchCoords, patchCoords, │ │ │ │ │ +1900 patchTable, │ │ │ │ │ +1901 numStartEvents, startEvents, endEvent); │ │ │ │ │ +1902 delete instance; │ │ │ │ │ +1903 return r; │ │ │ │ │ +1904 } │ │ │ │ │ +1905 return false; │ │ │ │ │ +1906 } │ │ │ │ │ +1907 } │ │ │ │ │ +1908 │ │ │ │ │ +1976 template │ │ │ │ │ +_1_9_7_8 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1979 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1980 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1981 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1982 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1983 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1984 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1985 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1986 int numPatchCoords, │ │ │ │ │ +1987 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1988 PATCH_TABLE *patchTable, │ │ │ │ │ +1989 unsigned int numStartEvents=0, │ │ │ │ │ +1990 const cl_event* startEvents=NULL, │ │ │ │ │ +1991 cl_event* endEvent=NULL) const { │ │ │ │ │ +1992 │ │ │ │ │ +1993 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +1994 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +1995 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +1996 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +1997 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ +1998 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ +1999 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ +2000 numPatchCoords, │ │ │ │ │ +2001 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +2002 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ +2003 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +2004 patchTable->GetPatchParamBuffer(), │ │ │ │ │ +2005 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2006 } │ │ │ │ │ +2007 │ │ │ │ │ +2058 template │ │ │ │ │ +_2_0_6_1 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2062 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2063 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2064 int numPatchCoords, │ │ │ │ │ +2065 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2066 PATCH_TABLE *patchTable, │ │ │ │ │ +2067 int fvarChannel, │ │ │ │ │ +2068 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +2069 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +2070 unsigned int numStartEvents=0, │ │ │ │ │ +2071 const cl_event* startEvents=NULL, │ │ │ │ │ +2072 cl_event* endEvent=NULL) { │ │ │ │ │ +2073 │ │ │ │ │ +2074 if (instance) { │ │ │ │ │ +2075 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2076 srcBuffer, srcDesc, │ │ │ │ │ +2077 dstBuffer, dstDesc, │ │ │ │ │ +2078 numPatchCoords, patchCoords, │ │ │ │ │ +2079 patchTable, fvarChannel, │ │ │ │ │ +2080 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2081 } else { │ │ │ │ │ +2082 // Create an instance on demand (slow) │ │ │ │ │ +2083 (void)deviceContext; // unused │ │ │ │ │ +2084 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +2085 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2086 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2087 deviceContext); │ │ │ │ │ +2088 if (instance) { │ │ │ │ │ +2089 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2090 srcBuffer, srcDesc, │ │ │ │ │ +2091 dstBuffer, dstDesc, │ │ │ │ │ +2092 numPatchCoords, patchCoords, │ │ │ │ │ +2093 patchTable, fvarChannel, │ │ │ │ │ +2094 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2095 delete instance; │ │ │ │ │ +2096 return r; │ │ │ │ │ +2097 } │ │ │ │ │ +2098 return false; │ │ │ │ │ +2099 } │ │ │ │ │ +2100 } │ │ │ │ │ +2101 │ │ │ │ │ +2141 template │ │ │ │ │ +_2_1_4_3 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2144 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2145 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2146 int numPatchCoords, │ │ │ │ │ +2147 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2148 PATCH_TABLE *patchTable, │ │ │ │ │ +2149 int fvarChannel = 0, │ │ │ │ │ +2150 unsigned int numStartEvents=0, │ │ │ │ │ +2151 const cl_event* startEvents=NULL, │ │ │ │ │ +2152 cl_event* endEvent=NULL) const { │ │ │ │ │ +2153 │ │ │ │ │ +2154 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +2155 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +2156 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2157 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2158 numPatchCoords, │ │ │ │ │ +2159 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +2160 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ +2161 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +2162 patchTable->GetFVarPatchParamBuffer(fvarChannel), │ │ │ │ │ +2163 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2164 } │ │ │ │ │ +2165 │ │ │ │ │ +2228 template │ │ │ │ │ +_2_2_3_1 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2232 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2233 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2234 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2235 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2236 int numPatchCoords, │ │ │ │ │ +2237 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2238 PATCH_TABLE *patchTable, │ │ │ │ │ +2239 int fvarChannel, │ │ │ │ │ +2240 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +2241 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +2242 unsigned int numStartEvents=0, │ │ │ │ │ +2243 const cl_event* startEvents=NULL, │ │ │ │ │ +2244 cl_event* endEvent=NULL) { │ │ │ │ │ +2245 │ │ │ │ │ +2246 if (instance) { │ │ │ │ │ +2247 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2248 srcBuffer, srcDesc, │ │ │ │ │ +2249 dstBuffer, dstDesc, │ │ │ │ │ +2250 duBuffer, duDesc, │ │ │ │ │ +2251 dvBuffer, dvDesc, │ │ │ │ │ +2252 numPatchCoords, patchCoords, │ │ │ │ │ +2253 patchTable, fvarChannel, │ │ │ │ │ +2254 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2255 } else { │ │ │ │ │ +2256 // Create an instance on demand (slow) │ │ │ │ │ +2257 (void)deviceContext; // unused │ │ │ │ │ +2258 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +2259 duDesc, dvDesc, deviceContext); │ │ │ │ │ +2260 if (instance) { │ │ │ │ │ +2261 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2262 srcBuffer, srcDesc, │ │ │ │ │ +2263 dstBuffer, dstDesc, │ │ │ │ │ +2264 duBuffer, duDesc, │ │ │ │ │ +2265 dvBuffer, dvDesc, │ │ │ │ │ +2266 numPatchCoords, patchCoords, │ │ │ │ │ +2267 patchTable, fvarChannel, │ │ │ │ │ +2268 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2269 delete instance; │ │ │ │ │ +2270 return r; │ │ │ │ │ +2271 } │ │ │ │ │ +2272 return false; │ │ │ │ │ +2273 } │ │ │ │ │ +2274 } │ │ │ │ │ +2275 │ │ │ │ │ +2327 template │ │ │ │ │ +_2_3_2_9 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2330 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2331 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2332 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2333 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2334 int numPatchCoords, │ │ │ │ │ +2335 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2336 PATCH_TABLE *patchTable, │ │ │ │ │ +2337 int fvarChannel = 0, │ │ │ │ │ +2338 unsigned int numStartEvents=0, │ │ │ │ │ +2339 const cl_event* startEvents=NULL, │ │ │ │ │ +2340 cl_event* endEvent=NULL) const { │ │ │ │ │ +2341 │ │ │ │ │ +2342 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +2343 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +2344 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +2345 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +2346 numPatchCoords, │ │ │ │ │ +2347 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +2348 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ +2349 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +2350 patchTable->GetFVarPatchParamBuffer(fvarChannel), │ │ │ │ │ +2351 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2352 } │ │ │ │ │ +2353 │ │ │ │ │ +2434 template │ │ │ │ │ +_2_4_3_7 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2438 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2439 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2440 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2441 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2442 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +2443 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +2444 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +2445 int numPatchCoords, │ │ │ │ │ +2446 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2447 PATCH_TABLE *patchTable, │ │ │ │ │ +2448 int fvarChannel, │ │ │ │ │ +2449 _C_L_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +2450 DEVICE_CONTEXT deviceContext, │ │ │ │ │ +2451 unsigned int numStartEvents=0, │ │ │ │ │ +2452 const cl_event* startEvents=NULL, │ │ │ │ │ +2453 cl_event* endEvent=NULL) { │ │ │ │ │ +2454 │ │ │ │ │ +2455 if (instance) { │ │ │ │ │ +2456 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2457 srcBuffer, srcDesc, │ │ │ │ │ +2458 dstBuffer, dstDesc, │ │ │ │ │ +2459 duBuffer, duDesc, │ │ │ │ │ +2460 dvBuffer, dvDesc, │ │ │ │ │ +2461 duuBuffer, duuDesc, │ │ │ │ │ +2462 duvBuffer, duvDesc, │ │ │ │ │ +2463 dvvBuffer, dvvDesc, │ │ │ │ │ +2464 numPatchCoords, patchCoords, │ │ │ │ │ +2465 patchTable, fvarChannel, │ │ │ │ │ +2466 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2467 } else { │ │ │ │ │ +2468 // Create an instance on demand (slow) │ │ │ │ │ +2469 (void)deviceContext; // unused │ │ │ │ │ +2470 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +2471 duDesc, dvDesc, │ │ │ │ │ +2472 duuDesc, duvDesc, dvvDesc, │ │ │ │ │ +2473 deviceContext); │ │ │ │ │ +2474 if (instance) { │ │ │ │ │ +2475 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2476 srcBuffer, srcDesc, │ │ │ │ │ +2477 dstBuffer, dstDesc, │ │ │ │ │ +2478 duBuffer, duDesc, │ │ │ │ │ +2479 dvBuffer, dvDesc, │ │ │ │ │ +2480 duuBuffer, duuDesc, │ │ │ │ │ +2481 duvBuffer, duvDesc, │ │ │ │ │ +2482 dvvBuffer, dvvDesc, │ │ │ │ │ +2483 numPatchCoords, patchCoords, │ │ │ │ │ +2484 patchTable, fvarChannel, │ │ │ │ │ +2485 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2486 delete instance; │ │ │ │ │ +2487 return r; │ │ │ │ │ +2488 } │ │ │ │ │ +2489 return false; │ │ │ │ │ +2490 } │ │ │ │ │ +2491 } │ │ │ │ │ +2492 │ │ │ │ │ +2562 template │ │ │ │ │ +_2_5_6_4 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2565 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2566 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2567 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2568 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2569 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +2570 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +2571 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +2572 int numPatchCoords, │ │ │ │ │ +2573 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2574 PATCH_TABLE *patchTable, │ │ │ │ │ +2575 int fvarChannel = 0, │ │ │ │ │ +2576 unsigned int numStartEvents=0, │ │ │ │ │ +2577 const cl_event* startEvents=NULL, │ │ │ │ │ +2578 cl_event* endEvent=NULL) const { │ │ │ │ │ +2579 │ │ │ │ │ +2580 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCLBuffer(_clCommandQueue), srcDesc, │ │ │ │ │ +2581 dstBuffer->BindCLBuffer(_clCommandQueue), dstDesc, │ │ │ │ │ +2582 duBuffer->BindCLBuffer(_clCommandQueue), duDesc, │ │ │ │ │ +2583 dvBuffer->BindCLBuffer(_clCommandQueue), dvDesc, │ │ │ │ │ +2584 duuBuffer->BindCLBuffer(_clCommandQueue), duuDesc, │ │ │ │ │ +2585 duvBuffer->BindCLBuffer(_clCommandQueue), duvDesc, │ │ │ │ │ +2586 dvvBuffer->BindCLBuffer(_clCommandQueue), dvvDesc, │ │ │ │ │ +2587 numPatchCoords, │ │ │ │ │ +2588 patchCoords->BindCLBuffer(_clCommandQueue), │ │ │ │ │ +2589 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ +2590 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +2591 patchTable->GetFVarPatchParamBuffer(fvarChannel), │ │ │ │ │ +2592 numStartEvents, startEvents, endEvent); │ │ │ │ │ +2593 } │ │ │ │ │ +2594 │ │ │ │ │ +2600 │ │ │ │ │ +_2_6_0_3 bool _C_o_m_p_i_l_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2604 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2605 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2606 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2607 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2608 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2609 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ +2610 │ │ │ │ │ +2612 template │ │ │ │ │ +_2_6_1_3 static void _S_y_n_c_h_r_o_n_i_z_e(DEVICE_CONTEXT deviceContext) { │ │ │ │ │ +2614 _S_y_n_c_h_r_o_n_i_z_e(deviceContext->GetCommandQueue()); │ │ │ │ │ +2615 } │ │ │ │ │ +2616 │ │ │ │ │ +_2_6_1_7 static void _S_y_n_c_h_r_o_n_i_z_e(cl_command_queue queue); │ │ │ │ │ +2618 │ │ │ │ │ +2619private: │ │ │ │ │ +2620 cl_context _clContext; │ │ │ │ │ +2621 cl_command_queue _clCommandQueue; │ │ │ │ │ +2622 cl_program _program; │ │ │ │ │ +2623 cl_kernel _stencilKernel; │ │ │ │ │ +2624 cl_kernel _stencilDerivKernel; │ │ │ │ │ +2625 cl_kernel _patchKernel; │ │ │ │ │ +2626}; │ │ │ │ │ +2627 │ │ │ │ │ +2628} // end namespace Osd │ │ │ │ │ +2629 │ │ │ │ │ +2630} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +2631using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +2632 │ │ │ │ │ +2633} // end namespace OpenSubdiv │ │ │ │ │ +2634 │ │ │ │ │ +2635 │ │ │ │ │ +2636#endif // OPENSUBDIV3_OSD_CL_EVALUATOR_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t_:_:_c_o_m_m_a_n_d_Q_u_e_u_e │ │ │ │ │ -id< MTLCommandQueue > commandQueue │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t_:_:_d_e_v_i_c_e │ │ │ │ │ -id< MTLDevice > device │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ +data buffers.... │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +OpenCL stencil table. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetDvvWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +CLStencilTable(Far::StencilTable const *stencilTable, cl_context clContext) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetOffsetsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static CLStencilTable * Create(Far::LimitStencilTable const *limitStencilTable, │ │ │ │ │ +DEVICE_CONTEXT context) │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetIndicesBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ +int GetNumStencils() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_S_i_z_e_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetSizesBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetDuuWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetDvWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetDuvWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetDuWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_~_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +~CLStencilTable() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static CLStencilTable * Create(Far::StencilTable const *stencilTable, │ │ │ │ │ +DEVICE_CONTEXT context) │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +CLStencilTable(Far::LimitStencilTable const *limitStencilTable, cl_context │ │ │ │ │ +clContext) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +cl_mem GetWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, CLEvaluator │ │ │ │ │ +const *instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, │ │ │ │ │ +const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic static stencil function. This function has a same signature as other │ │ │ │ │ +device kernels have so t... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_3_0_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ +static void Synchronize(cl_command_queue queue) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_~_C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ +~CLEvaluator() │ │ │ │ │ +Destructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ +BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ +cl_mem dv, BufferDescriptor const &dvDesc, cl_mem sizes, cl_mem offsets, cl_mem │ │ │ │ │ +indices, cl_mem weights, cl_mem duWeights, cl_mem dvWeights, int start, int │ │ │ │ │ +end, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) const │ │ │ │ │ +Dispatch the CL compute kernel asynchronously. returns false if the kernel │ │ │ │ │ +hasn't been compiled yet. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ +const *stencilTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, │ │ │ │ │ +unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) │ │ │ │ │ +Generic static stencil function. This function has a same signature as other │ │ │ │ │ +device kernels have so t... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_1_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ +const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ +cl_context clContext, cl_command_queue clCommandQueue) │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_1_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ +DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CLEvaluator const │ │ │ │ │ +*instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const │ │ │ │ │ +cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_2_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ +BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ +cl_mem dv, BufferDescriptor const &dvDesc, int numPatchCoords, cl_mem │ │ │ │ │ +patchCoordsBuffer, cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem │ │ │ │ │ +patchParamsBuffer, unsigned int numStartEvents=0, const cl_event │ │ │ │ │ +*startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const │ │ │ │ │ +cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_9_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, STENCIL_TABLE const *stencilTable, unsigned int numStartEvents=0, │ │ │ │ │ +const cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ +Generic stencil function. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, unsigned int numStartEvents=0, const │ │ │ │ │ +cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ +Generic limit eval function with derivatives. This function has a same │ │ │ │ │ +signature as other device kern... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_3_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_I_n_s_t_a_n_t_i_a_t_a_b_l_e │ │ │ │ │ +bool Instantiatable │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ +const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ +DEVICE_CONTEXT deviceContext) │ │ │ │ │ +Generic creator template. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ +fvarChannel, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, │ │ │ │ │ +unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_0_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ +const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ +BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, │ │ │ │ │ +BufferDescriptor const &dvvDesc, DEVICE_CONTEXT deviceContext) │ │ │ │ │ +Generic creator template. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_3_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ +BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ +cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const │ │ │ │ │ +&duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, cl_mem patchCoordsBuffer, │ │ │ │ │ +cl_mem patchArrayBuffer, cl_mem patchIndexBuffer, cl_mem patchParamsBuffer, │ │ │ │ │ +unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ +BufferDescriptor const &dstDesc, cl_mem du, BufferDescriptor const &duDesc, │ │ │ │ │ +cl_mem dv, BufferDescriptor const &dvDesc, cl_mem duu, BufferDescriptor const │ │ │ │ │ +&duuDesc, cl_mem duv, BufferDescriptor const &duvDesc, cl_mem dvv, │ │ │ │ │ +BufferDescriptor const &dvvDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, │ │ │ │ │ +cl_mem weights, cl_mem duWeights, cl_mem dvWeights, cl_mem duuWeights, cl_mem │ │ │ │ │ +duvWeights, cl_mem dvvWeights, int start, int end, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +const │ │ │ │ │ +Dispatch the CL compute kernel asynchronously. returns false if the kernel │ │ │ │ │ +hasn't been compiled yet. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, │ │ │ │ │ +unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_5_6_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_2_1_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, unsigned │ │ │ │ │ +int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) const │ │ │ │ │ +Generic stencil function. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_6_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, │ │ │ │ │ +DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event │ │ │ │ │ +*startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_6_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ +static void Synchronize(DEVICE_CONTEXT deviceContext) │ │ │ │ │ +Wait the OpenCL kernels finish. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_6_1_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, CLEvaluator const *instance, │ │ │ │ │ +DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const cl_event │ │ │ │ │ +*startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_1_2_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ +CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic static stencil function. This function has a same signature as other │ │ │ │ │ +device kernels have so t... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_4_2_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(cl_mem src, BufferDescriptor const &srcDesc, cl_mem dst, │ │ │ │ │ +BufferDescriptor const &dstDesc, cl_mem sizes, cl_mem offsets, cl_mem indices, │ │ │ │ │ +cl_mem weights, int start, int end, unsigned int numStartEvents=0, const │ │ │ │ │ +cl_event *startEvents=NULL, cl_event *endEvent=NULL) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, │ │ │ │ │ +CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_4_8_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_3_2_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ +DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, │ │ │ │ │ +CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_4_3_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static CLEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor │ │ │ │ │ +const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, │ │ │ │ │ +BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, │ │ │ │ │ +BufferDescriptor const &dvvDesc, cl_context clContext, cl_command_queue │ │ │ │ │ +clCommandQueue) │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_4_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable, CLEvaluator const *instance, DEVICE_CONTEXT deviceContext, │ │ │ │ │ +unsigned int numStartEvents=0, const cl_event *startEvents=NULL, cl_event │ │ │ │ │ +*endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_0_0_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ +cl_event *endEvent=NULL) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_7_4_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const │ │ │ │ │ +*instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const │ │ │ │ │ +cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_9_0_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, unsigned int │ │ │ │ │ +numStartEvents=0, const cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_5_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CLEvaluator const │ │ │ │ │ +*instance, DEVICE_CONTEXT deviceContext, unsigned int numStartEvents=0, const │ │ │ │ │ +cl_event *startEvents=NULL, cl_event *endEvent=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_8_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const │ │ │ │ │ +*stencilTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ +cl_event *endEvent=NULL) const │ │ │ │ │ +Generic stencil function. │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_5_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ +cl_event *endEvent=NULL) const │ │ │ │ │ +Generic limit eval function with derivatives. This function has a same │ │ │ │ │ +signature as other device kern... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_1_2_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_L_E_v_a_l_u_a_t_o_r │ │ │ │ │ +CLEvaluator(cl_context context, cl_command_queue queue) │ │ │ │ │ +Constructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_C_o_m_p_i_l_e │ │ │ │ │ +bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, │ │ │ │ │ +BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ +&dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), │ │ │ │ │ +BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ +&dvvDesc=BufferDescriptor()) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_L_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ +fvarChannel=0, unsigned int numStartEvents=0, const cl_event *startEvents=NULL, │ │ │ │ │ +cl_event *endEvent=NULL) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_l_E_v_a_l_u_a_t_o_r_._h_:_2_1_4_3 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_C_o_m_m_o_n_._h │ │ │ │ │ + * _c_l_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00809.html │ │ │ │ @@ -94,15 +94,15 @@ │ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │
mtlPatchShaderSource.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
import "../version.h"
│ │ │ │ -import "../far/patchDescriptor.h"
│ │ │ │ +import "../far/patchDescriptor.h"
│ │ │ │ import <string>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00809_source.html │ │ │ │ @@ -172,15 +172,15 @@ │ │ │ │
88} // end namespace OPENSUBDIV_VERSION
│ │ │ │
89using namespace OPENSUBDIV_VERSION;
│ │ │ │
90
│ │ │ │
91} // end namespace OpenSubdiv
│ │ │ │
92
│ │ │ │
93#endif // OPENSUBDIV3_OSD_MTL_PATCH_SHADER_SOURCE
│ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │
Provides shader source which can be used by client code.
│ │ │ │
static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │
static std::string GetPatchDrawingShaderSource()
Returns shader source which can be used while drawing piecewise parametric patches resulting from sub...
│ │ │ │
static std::string GetHullShaderSource(Far::PatchDescriptor::Type type, Far::PatchDescriptor::Type fvarType)
│ │ │ │
static std::string GetDomainShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │
static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type, Far::PatchDescriptor::Type fvarType)
Deprecated.
│ │ │ │
static std::string GetDomainShaderSource(Far::PatchDescriptor::Type type, Far::PatchDescriptor::Type fvarType)
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00812.html │ │ │ │ @@ -95,15 +95,15 @@ │ │ │ │ Namespaces | │ │ │ │ Typedefs │ │ │ │
mtlMesh.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../osd/mesh.h"
│ │ │ │ -#include "../osd/mtlPatchTable.h"
│ │ │ │ +#include "../osd/mtlPatchTable.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  MTLPatchShaderSource
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00815.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlLegacyGregoryPatchTable.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlPatchTable.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,42 +90,45 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
mtlLegacyGregoryPatchTable.h File Reference
│ │ │ │ +
mtlPatchTable.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ #include "../osd/nonCopyable.h"
│ │ │ │ -#include "../osd/mtlCommon.h"
│ │ │ │ +#include "../osd/types.h"
│ │ │ │ +#include "../osd/mtlCommon.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
│ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  MTLLegacyGregoryPatchTable
class  MTLPatchTable
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,25 +1,28 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -mtlLegacyGregoryPatchTable.h File Reference │ │ │ │ │ +mtlPatchTable.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ #include "../osd/nonCopyable.h" │ │ │ │ │ +#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ #include "_._._/_o_s_d_/_m_t_l_C_o_m_m_o_n_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +class   _M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ +namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │ +  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ + * _m_t_l_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00815.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00815 = [ │ │ │ │ │ - ["MTLLegacyGregoryPatchTable", "a01297.html", "a01297"] │ │ │ │ │ + ["MTLPatchTable", "a01305.html", "a01305"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00815_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlLegacyGregoryPatchTable.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlPatchTable.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
mtlLegacyGregoryPatchTable.h
│ │ │ │ +
mtlPatchTable.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,112 +119,123 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29#include "../far/patchTable.h"
│ │ │ │ +
29#include "../far/patchDescriptor.h"
│ │ │ │
30#include "../osd/nonCopyable.h"
│ │ │ │ -
31#include "../osd/mtlCommon.h"
│ │ │ │ -
32
│ │ │ │ -
33@protocol MTLDevice;
│ │ │ │ -
34@protocol MTLBuffer;
│ │ │ │ -
35
│ │ │ │ -
36namespace OpenSubdiv {
│ │ │ │ -
37namespace OPENSUBDIV_VERSION {
│ │ │ │ -
38
│ │ │ │ -
39namespace Osd {
│ │ │ │ -
40
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
42: private NonCopyable<MTLLegacyGregoryPatchTable>
│ │ │ │ -
43{
│ │ │ │ -
44public:
│ │ │ │ - │ │ │ │ -
46
│ │ │ │ -
47 template<typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
48 static MTLLegacyGregoryPatchTable* Create(Far::PatchTable const* farPatchTable, DEVICE_CONTEXT context) {
│ │ │ │ -
49 return Create(farPatchTable, context);
│ │ │ │ -
50 }
│ │ │ │ -
│ │ │ │ -
51
│ │ │ │ -
52 static MTLLegacyGregoryPatchTable* Create(Far::PatchTable const* farPatchTable, MTLContext* context);
│ │ │ │ -
53
│ │ │ │ -
54 void UpdateVertexBuffer(id<MTLBuffer> vbo, int numVertices, int numVertexElements, MTLContext* context);
│ │ │ │ -
55
│ │ │ │ -
│ │ │ │ -
56 id<MTLBuffer> GetVertexBuffer() const
│ │ │ │ -
57 {
│ │ │ │ -
58 return _vertexBuffer;
│ │ │ │ -
59 }
│ │ │ │ +
31#include "../osd/types.h"
│ │ │ │ +
32#include "../osd/mtlCommon.h"
│ │ │ │ +
33
│ │ │ │ +
34@protocol MTLDevice;
│ │ │ │ +
35@protocol MTLBuffer;
│ │ │ │ +
36
│ │ │ │ +
37namespace OpenSubdiv {
│ │ │ │ +
38namespace OPENSUBDIV_VERSION {
│ │ │ │ +
39
│ │ │ │ +
40namespace Far {
│ │ │ │ +
41 class PatchTable;
│ │ │ │ +
42};
│ │ │ │ +
43
│ │ │ │ +
44namespace Osd {
│ │ │ │ +
45
│ │ │ │ +
│ │ │ │ +
46class MTLPatchTable : private NonCopyable<MTLPatchTable> {
│ │ │ │ +
47public:
│ │ │ │ +
48 typedef id<MTLBuffer> VertexBufferBinding;
│ │ │ │ +
49
│ │ │ │ + │ │ │ │ + │ │ │ │ +
52
│ │ │ │ +
53 template<typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
54 static MTLPatchTable *Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ +
55 {
│ │ │ │ +
56 return Create(farPatchTable, context);
│ │ │ │ +
57 }
│ │ │ │
│ │ │ │ +
58
│ │ │ │ +
59 static MTLPatchTable *Create(Far::PatchTable const *farPatchTable, MTLContext* context);
│ │ │ │
60
│ │ │ │ -
│ │ │ │ -
61 id<MTLBuffer> GetVertexValenceBuffer() const
│ │ │ │ -
62 {
│ │ │ │ -
63 return _vertexValenceBuffer;
│ │ │ │ -
64 }
│ │ │ │ -
│ │ │ │ -
65
│ │ │ │ -
│ │ │ │ -
66 id<MTLBuffer> GetQuadOffsetsBuffer() const
│ │ │ │ -
67 {
│ │ │ │ -
68 return _quadOffsetsBuffer;
│ │ │ │ -
69 }
│ │ │ │ -
│ │ │ │ -
70
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
72 {
│ │ │ │ - │ │ │ │ -
74 return _quadOffsetsBase[1];
│ │ │ │ -
75 return _quadOffsetsBase[0];
│ │ │ │ -
76 }
│ │ │ │ -
│ │ │ │ +
61 PatchArrayVector const &GetPatchArrays() const { return _patchArrays; }
│ │ │ │ +
62 id<MTLBuffer> GetPatchIndexBuffer() const { return _indexBuffer; }
│ │ │ │ +
63 id<MTLBuffer> GetPatchParamBuffer() const { return _patchParamBuffer; }
│ │ │ │ +
64
│ │ │ │ + │ │ │ │ +
66 id<MTLBuffer> GetVaryingPatchIndexBuffer() const { return _varyingPatchIndexBuffer; }
│ │ │ │ +
67
│ │ │ │ +
68 int GetNumFVarChannels() const { return (int)_fvarPatchArrays.size(); }
│ │ │ │ +
69 PatchArrayVector const &GetFVarPatchArrays(int fvarChannel = 0) const { return _fvarPatchArrays[fvarChannel]; }
│ │ │ │ +
70 id<MTLBuffer> GetFVarPatchIndexBuffer(int fvarChannel = 0) const { return _fvarIndexBuffers[fvarChannel]; }
│ │ │ │ +
71 id<MTLBuffer> GetFVarPatchParamBuffer(int fvarChannel = 0) const { return _fvarParamBuffers[fvarChannel]; }
│ │ │ │ +
72
│ │ │ │ +
73protected:
│ │ │ │ +
74 bool allocate(Far::PatchTable const *farPatchTable, MTLContext* context);
│ │ │ │ +
75
│ │ │ │ + │ │ │ │
77
│ │ │ │ -
78private:
│ │ │ │ -
79 id<MTLBuffer> _vertexBuffer;
│ │ │ │ -
80 id<MTLBuffer> _vertexValenceBuffer;
│ │ │ │ -
81 id<MTLBuffer> _quadOffsetsBuffer;
│ │ │ │ -
82 int _quadOffsetsBase[2];
│ │ │ │ -
83};
│ │ │ │ -
│ │ │ │ +
78 id<MTLBuffer> _indexBuffer;
│ │ │ │ +
79 id<MTLBuffer> _patchParamBuffer;
│ │ │ │ +
80
│ │ │ │ + │ │ │ │ +
82
│ │ │ │ + │ │ │ │
84
│ │ │ │ -
85} //end namespace Osd
│ │ │ │ -
86
│ │ │ │ -
87} //end namespace OPENSUBDIV_VERSION
│ │ │ │ -
88using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
85 std::vector<PatchArrayVector> _fvarPatchArrays;
│ │ │ │ +
86 std::vector<id<MTLBuffer>> _fvarIndexBuffers;
│ │ │ │ +
87 std::vector<id<MTLBuffer>> _fvarParamBuffers;
│ │ │ │ +
88};
│ │ │ │ +
│ │ │ │
89
│ │ │ │ -
90} //end namespace OpenSuddiv
│ │ │ │ +
90} // end namespace Osd
│ │ │ │
91
│ │ │ │ -
92#endif // OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ +
92} //end namespace OPENSUBDIV_VERSION
│ │ │ │ +
93using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
94
│ │ │ │ +
95} //end namespace OpenSubdiv
│ │ │ │ +
96
│ │ │ │ +
97#endif //end OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ - │ │ │ │ - │ │ │ │ -
static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, MTLContext *context)
│ │ │ │ -
void UpdateVertexBuffer(id< MTLBuffer > vbo, int numVertices, int numVertexElements, MTLContext *context)
│ │ │ │ - │ │ │ │ - │ │ │ │ +
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ + │ │ │ │ + │ │ │ │ +
PatchArrayVector const & GetPatchArrays() const
│ │ │ │ +
bool allocate(Far::PatchTable const *farPatchTable, MTLContext *context)
│ │ │ │ +
static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, MTLContext *context)
│ │ │ │ + │ │ │ │ +
std::vector< id< MTLBuffer > > _fvarIndexBuffers
│ │ │ │ +
id< MTLBuffer > GetFVarPatchParamBuffer(int fvarChannel=0) const
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
PatchArrayVector const & GetFVarPatchArrays(int fvarChannel=0) const
│ │ │ │ + │ │ │ │ +
std::vector< id< MTLBuffer > > _fvarParamBuffers
│ │ │ │ +
std::vector< PatchArrayVector > _fvarPatchArrays
│ │ │ │ + │ │ │ │ + │ │ │ │ +
static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ + │ │ │ │ +
id< MTLBuffer > GetFVarPatchIndexBuffer(int fvarChannel=0) const
│ │ │ │ +
PatchArrayVector const & GetVaryingPatchArrays() const
│ │ │ │ + │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -mtlLegacyGregoryPatchTable.h │ │ │ │ │ +mtlPatchTable.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,127 +24,170 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29#include "../far/patchTable.h" │ │ │ │ │ +29#include "../far/patchDescriptor.h" │ │ │ │ │ 30#include "../osd/nonCopyable.h" │ │ │ │ │ -31#include "../osd/mtlCommon.h" │ │ │ │ │ -32 │ │ │ │ │ -33@protocol MTLDevice; │ │ │ │ │ -34@protocol MTLBuffer; │ │ │ │ │ -35 │ │ │ │ │ -36namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -37namespace OPENSUBDIV_VERSION { │ │ │ │ │ -38 │ │ │ │ │ -39namespace Osd { │ │ │ │ │ -40 │ │ │ │ │ -_4_1class _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -42: private NonCopyable │ │ │ │ │ -43{ │ │ │ │ │ -44public: │ │ │ │ │ -_4_5 _~_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ -46 │ │ │ │ │ -47 template │ │ │ │ │ -_4_8 static _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e* _C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const* │ │ │ │ │ -farPatchTable, DEVICE_CONTEXT context) { │ │ │ │ │ -49 return Create(farPatchTable, context); │ │ │ │ │ -50 } │ │ │ │ │ -51 │ │ │ │ │ -_5_2 static _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e* _C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const* │ │ │ │ │ -farPatchTable, _M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ -53 │ │ │ │ │ -_5_4 void _U_p_d_a_t_e_V_e_r_t_e_x_B_u_f_f_e_r(id vbo, int numVertices, int │ │ │ │ │ -numVertexElements, _M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ -55 │ │ │ │ │ -_5_6 id _G_e_t_V_e_r_t_e_x_B_u_f_f_e_r() const │ │ │ │ │ -57 { │ │ │ │ │ -58 return _vertexBuffer; │ │ │ │ │ -59 } │ │ │ │ │ +31#include "../osd/types.h" │ │ │ │ │ +32#include "../osd/mtlCommon.h" │ │ │ │ │ +33 │ │ │ │ │ +34@protocol MTLDevice; │ │ │ │ │ +35@protocol MTLBuffer; │ │ │ │ │ +36 │ │ │ │ │ +37namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +38namespace OPENSUBDIV_VERSION { │ │ │ │ │ +39 │ │ │ │ │ +40namespace Far { │ │ │ │ │ +41 class PatchTable; │ │ │ │ │ +42}; │ │ │ │ │ +43 │ │ │ │ │ +44namespace Osd { │ │ │ │ │ +45 │ │ │ │ │ +_4_6class _M_T_L_P_a_t_c_h_T_a_b_l_e : private NonCopyable { │ │ │ │ │ +47public: │ │ │ │ │ +_4_8 typedef id _V_e_r_t_e_x_B_u_f_f_e_r_B_i_n_d_i_n_g; │ │ │ │ │ +49 │ │ │ │ │ +_5_0 _M_T_L_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ +_5_1 _~_M_T_L_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ +52 │ │ │ │ │ +53 template │ │ │ │ │ +_5_4 static _M_T_L_P_a_t_c_h_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const *farPatchTable, │ │ │ │ │ +DEVICE_CONTEXT context) │ │ │ │ │ +55 { │ │ │ │ │ +56 return _C_r_e_a_t_e(farPatchTable, context); │ │ │ │ │ +57 } │ │ │ │ │ +58 │ │ │ │ │ +_5_9 static _M_T_L_P_a_t_c_h_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const *farPatchTable, │ │ │ │ │ +_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ 60 │ │ │ │ │ -_6_1 id _G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_B_u_f_f_e_r() const │ │ │ │ │ -62 { │ │ │ │ │ -63 return _vertexValenceBuffer; │ │ │ │ │ -64 } │ │ │ │ │ -65 │ │ │ │ │ -_6_6 id _G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_u_f_f_e_r() const │ │ │ │ │ -67 { │ │ │ │ │ -68 return _quadOffsetsBuffer; │ │ │ │ │ -69 } │ │ │ │ │ -70 │ │ │ │ │ -_7_1 int _G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_a_s_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type) │ │ │ │ │ -72 { │ │ │ │ │ -73 if(type == _F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y) │ │ │ │ │ -74 return _quadOffsetsBase[1]; │ │ │ │ │ -75 return _quadOffsetsBase[0]; │ │ │ │ │ -76 } │ │ │ │ │ +_6_1 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r const &_G_e_t_P_a_t_c_h_A_r_r_a_y_s() const { return ___p_a_t_c_h_A_r_r_a_y_s; } │ │ │ │ │ +_6_2 id _G_e_t_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r() const { return ___i_n_d_e_x_B_u_f_f_e_r; } │ │ │ │ │ +_6_3 id _G_e_t_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r() const { return ___p_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r; } │ │ │ │ │ +64 │ │ │ │ │ +_6_5 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r const &_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s() const { return │ │ │ │ │ +___v_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s; } │ │ │ │ │ +_6_6 id _G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r() const { return │ │ │ │ │ +___v_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r; } │ │ │ │ │ +67 │ │ │ │ │ +_6_8 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const { return (int)___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s.size(); } │ │ │ │ │ +_6_9 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r const &_G_e_t_F_V_a_r_P_a_t_c_h_A_r_r_a_y_s(int fvarChannel = 0) const │ │ │ │ │ +{ return ___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s[fvarChannel]; } │ │ │ │ │ +_7_0 id _G_e_t_F_V_a_r_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r(int fvarChannel = 0) const { return │ │ │ │ │ +___f_v_a_r_I_n_d_e_x_B_u_f_f_e_r_s[fvarChannel]; } │ │ │ │ │ +_7_1 id _G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r(int fvarChannel = 0) const { return │ │ │ │ │ +___f_v_a_r_P_a_r_a_m_B_u_f_f_e_r_s[fvarChannel]; } │ │ │ │ │ +72 │ │ │ │ │ +73protected: │ │ │ │ │ +_7_4 bool _a_l_l_o_c_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const *farPatchTable, _M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +75 │ │ │ │ │ +_7_6 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r ___p_a_t_c_h_A_r_r_a_y_s; │ │ │ │ │ 77 │ │ │ │ │ -78private: │ │ │ │ │ -79 id _vertexBuffer; │ │ │ │ │ -80 id _vertexValenceBuffer; │ │ │ │ │ -81 id _quadOffsetsBuffer; │ │ │ │ │ -82 int _quadOffsetsBase[2]; │ │ │ │ │ -83}; │ │ │ │ │ +_7_8 id ___i_n_d_e_x_B_u_f_f_e_r; │ │ │ │ │ +_7_9 id ___p_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r; │ │ │ │ │ +80 │ │ │ │ │ +_8_1 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r ___v_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s; │ │ │ │ │ +82 │ │ │ │ │ +_8_3 id ___v_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r; │ │ │ │ │ 84 │ │ │ │ │ -85} //end namespace Osd │ │ │ │ │ -86 │ │ │ │ │ -87} //end namespace OPENSUBDIV_VERSION │ │ │ │ │ -88using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +_8_5 std::vector ___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s; │ │ │ │ │ +_8_6 std::vector> ___f_v_a_r_I_n_d_e_x_B_u_f_f_e_r_s; │ │ │ │ │ +_8_7 std::vector> ___f_v_a_r_P_a_r_a_m_B_u_f_f_e_r_s; │ │ │ │ │ +88}; │ │ │ │ │ 89 │ │ │ │ │ -90} //end namespace OpenSuddiv │ │ │ │ │ +90} // end namespace Osd │ │ │ │ │ 91 │ │ │ │ │ -92#endif // OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H │ │ │ │ │ +92} //end namespace OPENSUBDIV_VERSION │ │ │ │ │ +93using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +94 │ │ │ │ │ +95} //end namespace OpenSubdiv │ │ │ │ │ +96 │ │ │ │ │ +97#endif //end OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e │ │ │ │ │ -Type │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y │ │ │ │ │ -@ GREGORY_BOUNDARY │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r │ │ │ │ │ +std::vector< PatchArray > PatchArrayVector │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_3_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ Container for arrays of parametric patches. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t │ │ │ │ │ DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_4_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_a_s_e │ │ │ │ │ -int GetQuadOffsetsBase(Far::PatchDescriptor::Type type) │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const │ │ │ │ │ -*farPatchTable, DEVICE_CONTEXT context) │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetVertexValenceBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetQuadOffsetsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_6_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const │ │ │ │ │ -*farPatchTable, MTLContext *context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_U_p_d_a_t_e_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -void UpdateVertexBuffer(id< MTLBuffer > vbo, int numVertices, int │ │ │ │ │ -numVertexElements, MTLContext *context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_~_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -~MTLLegacyGregoryPatchTable() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ -_G_e_t_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetVertexBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_4_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +PatchArrayVector const & GetPatchArrays() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_a_l_l_o_c_a_t_e │ │ │ │ │ +bool allocate(Far::PatchTable const *farPatchTable, MTLContext *context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, MTLContext │ │ │ │ │ +*context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetVaryingPatchIndexBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___f_v_a_r_I_n_d_e_x_B_u_f_f_e_r_s │ │ │ │ │ +std::vector< id< MTLBuffer > > _fvarIndexBuffers │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetFVarPatchParamBuffer(int fvarChannel=0) const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +MTLPatchTable() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetPatchParamBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetPatchIndexBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___p_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +PatchArrayVector _patchArrays │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_V_e_r_t_e_x_B_u_f_f_e_r_B_i_n_d_i_n_g │ │ │ │ │ +id< MTLBuffer > VertexBufferBinding │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ +int GetNumFVarChannels() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +PatchArrayVector const & GetFVarPatchArrays(int fvarChannel=0) const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___v_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > _varyingPatchIndexBuffer │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___f_v_a_r_P_a_r_a_m_B_u_f_f_e_r_s │ │ │ │ │ +std::vector< id< MTLBuffer > > _fvarParamBuffers │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +std::vector< PatchArrayVector > _fvarPatchArrays │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___p_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > _patchParamBuffer │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___v_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +PatchArrayVector _varyingPatchArrays │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, │ │ │ │ │ +DEVICE_CONTEXT context) │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_~_M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +~MTLPatchTable() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetFVarPatchIndexBuffer(int fvarChannel=0) const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ +PatchArrayVector const & GetVaryingPatchArrays() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___i_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > _indexBuffer │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_8 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ + * _m_t_l_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00818.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlPatchTable.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlLegacyGregoryPatchTable.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,45 +90,42 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
mtlPatchTable.h File Reference
│ │ │ │ +
mtlLegacyGregoryPatchTable.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │ #include "../osd/nonCopyable.h"
│ │ │ │ -#include "../osd/types.h"
│ │ │ │ -#include "../osd/mtlCommon.h"
│ │ │ │ +#include "../osd/mtlCommon.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  MTLPatchTable
class  MTLLegacyGregoryPatchTable
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,28 +1,25 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -mtlPatchTable.h File Reference │ │ │ │ │ +mtlLegacyGregoryPatchTable.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ #include "../osd/nonCopyable.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ #include "_._._/_o_s_d_/_m_t_l_C_o_m_m_o_n_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +class   _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ -namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │ -  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ + * _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00818.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00818 = [ │ │ │ │ │ - ["MTLPatchTable", "a01305.html", "a01305"] │ │ │ │ │ + ["MTLLegacyGregoryPatchTable", "a01297.html", "a01297"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00818_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlPatchTable.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlLegacyGregoryPatchTable.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
mtlPatchTable.h
│ │ │ │ +
mtlLegacyGregoryPatchTable.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,123 +119,112 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29#include "../far/patchDescriptor.h"
│ │ │ │ +
29#include "../far/patchTable.h"
│ │ │ │
30#include "../osd/nonCopyable.h"
│ │ │ │ -
31#include "../osd/types.h"
│ │ │ │ -
32#include "../osd/mtlCommon.h"
│ │ │ │ -
33
│ │ │ │ -
34@protocol MTLDevice;
│ │ │ │ -
35@protocol MTLBuffer;
│ │ │ │ -
36
│ │ │ │ -
37namespace OpenSubdiv {
│ │ │ │ -
38namespace OPENSUBDIV_VERSION {
│ │ │ │ -
39
│ │ │ │ -
40namespace Far {
│ │ │ │ -
41 class PatchTable;
│ │ │ │ -
42};
│ │ │ │ -
43
│ │ │ │ -
44namespace Osd {
│ │ │ │ -
45
│ │ │ │ -
│ │ │ │ -
46class MTLPatchTable : private NonCopyable<MTLPatchTable> {
│ │ │ │ -
47public:
│ │ │ │ -
48 typedef id<MTLBuffer> VertexBufferBinding;
│ │ │ │ -
49
│ │ │ │ - │ │ │ │ - │ │ │ │ -
52
│ │ │ │ -
53 template<typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
54 static MTLPatchTable *Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ -
55 {
│ │ │ │ -
56 return Create(farPatchTable, context);
│ │ │ │ -
57 }
│ │ │ │ +
31#include "../osd/mtlCommon.h"
│ │ │ │ +
32
│ │ │ │ +
33@protocol MTLDevice;
│ │ │ │ +
34@protocol MTLBuffer;
│ │ │ │ +
35
│ │ │ │ +
36namespace OpenSubdiv {
│ │ │ │ +
37namespace OPENSUBDIV_VERSION {
│ │ │ │ +
38
│ │ │ │ +
39namespace Osd {
│ │ │ │ +
40
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
42: private NonCopyable<MTLLegacyGregoryPatchTable>
│ │ │ │ +
43{
│ │ │ │ +
44public:
│ │ │ │ + │ │ │ │ +
46
│ │ │ │ +
47 template<typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
48 static MTLLegacyGregoryPatchTable* Create(Far::PatchTable const* farPatchTable, DEVICE_CONTEXT context) {
│ │ │ │ +
49 return Create(farPatchTable, context);
│ │ │ │ +
50 }
│ │ │ │ +
│ │ │ │ +
51
│ │ │ │ +
52 static MTLLegacyGregoryPatchTable* Create(Far::PatchTable const* farPatchTable, MTLContext* context);
│ │ │ │ +
53
│ │ │ │ +
54 void UpdateVertexBuffer(id<MTLBuffer> vbo, int numVertices, int numVertexElements, MTLContext* context);
│ │ │ │ +
55
│ │ │ │ +
│ │ │ │ +
56 id<MTLBuffer> GetVertexBuffer() const
│ │ │ │ +
57 {
│ │ │ │ +
58 return _vertexBuffer;
│ │ │ │ +
59 }
│ │ │ │
│ │ │ │ -
58
│ │ │ │ -
59 static MTLPatchTable *Create(Far::PatchTable const *farPatchTable, MTLContext* context);
│ │ │ │
60
│ │ │ │ -
61 PatchArrayVector const &GetPatchArrays() const { return _patchArrays; }
│ │ │ │ -
62 id<MTLBuffer> GetPatchIndexBuffer() const { return _indexBuffer; }
│ │ │ │ -
63 id<MTLBuffer> GetPatchParamBuffer() const { return _patchParamBuffer; }
│ │ │ │ -
64
│ │ │ │ - │ │ │ │ -
66 id<MTLBuffer> GetVaryingPatchIndexBuffer() const { return _varyingPatchIndexBuffer; }
│ │ │ │ -
67
│ │ │ │ -
68 int GetNumFVarChannels() const { return (int)_fvarPatchArrays.size(); }
│ │ │ │ -
69 PatchArrayVector const &GetFVarPatchArrays(int fvarChannel = 0) const { return _fvarPatchArrays[fvarChannel]; }
│ │ │ │ -
70 id<MTLBuffer> GetFVarPatchIndexBuffer(int fvarChannel = 0) const { return _fvarIndexBuffers[fvarChannel]; }
│ │ │ │ -
71 id<MTLBuffer> GetFVarPatchParamBuffer(int fvarChannel = 0) const { return _fvarParamBuffers[fvarChannel]; }
│ │ │ │ -
72
│ │ │ │ -
73protected:
│ │ │ │ -
74 bool allocate(Far::PatchTable const *farPatchTable, MTLContext* context);
│ │ │ │ -
75
│ │ │ │ - │ │ │ │ +
│ │ │ │ +
61 id<MTLBuffer> GetVertexValenceBuffer() const
│ │ │ │ +
62 {
│ │ │ │ +
63 return _vertexValenceBuffer;
│ │ │ │ +
64 }
│ │ │ │ +
│ │ │ │ +
65
│ │ │ │ +
│ │ │ │ +
66 id<MTLBuffer> GetQuadOffsetsBuffer() const
│ │ │ │ +
67 {
│ │ │ │ +
68 return _quadOffsetsBuffer;
│ │ │ │ +
69 }
│ │ │ │ +
│ │ │ │ +
70
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
72 {
│ │ │ │ + │ │ │ │ +
74 return _quadOffsetsBase[1];
│ │ │ │ +
75 return _quadOffsetsBase[0];
│ │ │ │ +
76 }
│ │ │ │ +
│ │ │ │
77
│ │ │ │ -
78 id<MTLBuffer> _indexBuffer;
│ │ │ │ -
79 id<MTLBuffer> _patchParamBuffer;
│ │ │ │ -
80
│ │ │ │ - │ │ │ │ -
82
│ │ │ │ - │ │ │ │ -
84
│ │ │ │ -
85 std::vector<PatchArrayVector> _fvarPatchArrays;
│ │ │ │ -
86 std::vector<id<MTLBuffer>> _fvarIndexBuffers;
│ │ │ │ -
87 std::vector<id<MTLBuffer>> _fvarParamBuffers;
│ │ │ │ -
88};
│ │ │ │ +
78private:
│ │ │ │ +
79 id<MTLBuffer> _vertexBuffer;
│ │ │ │ +
80 id<MTLBuffer> _vertexValenceBuffer;
│ │ │ │ +
81 id<MTLBuffer> _quadOffsetsBuffer;
│ │ │ │ +
82 int _quadOffsetsBase[2];
│ │ │ │ +
83};
│ │ │ │
│ │ │ │ +
84
│ │ │ │ +
85} //end namespace Osd
│ │ │ │ +
86
│ │ │ │ +
87} //end namespace OPENSUBDIV_VERSION
│ │ │ │ +
88using namespace OPENSUBDIV_VERSION;
│ │ │ │
89
│ │ │ │ -
90} // end namespace Osd
│ │ │ │ +
90} //end namespace OpenSuddiv
│ │ │ │
91
│ │ │ │ -
92} //end namespace OPENSUBDIV_VERSION
│ │ │ │ -
93using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
94
│ │ │ │ -
95} //end namespace OpenSubdiv
│ │ │ │ -
96
│ │ │ │ -
97#endif //end OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H
│ │ │ │ +
92#endif // OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ │ │ │ │ -
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ - │ │ │ │ - │ │ │ │ -
PatchArrayVector const & GetPatchArrays() const
│ │ │ │ -
bool allocate(Far::PatchTable const *farPatchTable, MTLContext *context)
│ │ │ │ -
static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, MTLContext *context)
│ │ │ │ - │ │ │ │ -
std::vector< id< MTLBuffer > > _fvarIndexBuffers
│ │ │ │ -
id< MTLBuffer > GetFVarPatchParamBuffer(int fvarChannel=0) const
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
PatchArrayVector const & GetFVarPatchArrays(int fvarChannel=0) const
│ │ │ │ - │ │ │ │ -
std::vector< id< MTLBuffer > > _fvarParamBuffers
│ │ │ │ -
std::vector< PatchArrayVector > _fvarPatchArrays
│ │ │ │ - │ │ │ │ - │ │ │ │ -
static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ - │ │ │ │ -
id< MTLBuffer > GetFVarPatchIndexBuffer(int fvarChannel=0) const
│ │ │ │ -
PatchArrayVector const & GetVaryingPatchArrays() const
│ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ + │ │ │ │ + │ │ │ │ +
static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, MTLContext *context)
│ │ │ │ +
void UpdateVertexBuffer(id< MTLBuffer > vbo, int numVertices, int numVertexElements, MTLContext *context)
│ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -mtlPatchTable.h │ │ │ │ │ +mtlLegacyGregoryPatchTable.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,170 +24,127 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29#include "../far/patchDescriptor.h" │ │ │ │ │ +29#include "../far/patchTable.h" │ │ │ │ │ 30#include "../osd/nonCopyable.h" │ │ │ │ │ -31#include "../osd/types.h" │ │ │ │ │ -32#include "../osd/mtlCommon.h" │ │ │ │ │ -33 │ │ │ │ │ -34@protocol MTLDevice; │ │ │ │ │ -35@protocol MTLBuffer; │ │ │ │ │ -36 │ │ │ │ │ -37namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -38namespace OPENSUBDIV_VERSION { │ │ │ │ │ -39 │ │ │ │ │ -40namespace Far { │ │ │ │ │ -41 class PatchTable; │ │ │ │ │ -42}; │ │ │ │ │ -43 │ │ │ │ │ -44namespace Osd { │ │ │ │ │ -45 │ │ │ │ │ -_4_6class _M_T_L_P_a_t_c_h_T_a_b_l_e : private NonCopyable { │ │ │ │ │ -47public: │ │ │ │ │ -_4_8 typedef id _V_e_r_t_e_x_B_u_f_f_e_r_B_i_n_d_i_n_g; │ │ │ │ │ -49 │ │ │ │ │ -_5_0 _M_T_L_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ -_5_1 _~_M_T_L_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ -52 │ │ │ │ │ -53 template │ │ │ │ │ -_5_4 static _M_T_L_P_a_t_c_h_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const *farPatchTable, │ │ │ │ │ -DEVICE_CONTEXT context) │ │ │ │ │ -55 { │ │ │ │ │ -56 return _C_r_e_a_t_e(farPatchTable, context); │ │ │ │ │ -57 } │ │ │ │ │ -58 │ │ │ │ │ -_5_9 static _M_T_L_P_a_t_c_h_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const *farPatchTable, │ │ │ │ │ -_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +31#include "../osd/mtlCommon.h" │ │ │ │ │ +32 │ │ │ │ │ +33@protocol MTLDevice; │ │ │ │ │ +34@protocol MTLBuffer; │ │ │ │ │ +35 │ │ │ │ │ +36namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +37namespace OPENSUBDIV_VERSION { │ │ │ │ │ +38 │ │ │ │ │ +39namespace Osd { │ │ │ │ │ +40 │ │ │ │ │ +_4_1class _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +42: private NonCopyable │ │ │ │ │ +43{ │ │ │ │ │ +44public: │ │ │ │ │ +_4_5 _~_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e(); │ │ │ │ │ +46 │ │ │ │ │ +47 template │ │ │ │ │ +_4_8 static _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e* _C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const* │ │ │ │ │ +farPatchTable, DEVICE_CONTEXT context) { │ │ │ │ │ +49 return Create(farPatchTable, context); │ │ │ │ │ +50 } │ │ │ │ │ +51 │ │ │ │ │ +_5_2 static _M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e* _C_r_e_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const* │ │ │ │ │ +farPatchTable, _M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +53 │ │ │ │ │ +_5_4 void _U_p_d_a_t_e_V_e_r_t_e_x_B_u_f_f_e_r(id vbo, int numVertices, int │ │ │ │ │ +numVertexElements, _M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +55 │ │ │ │ │ +_5_6 id _G_e_t_V_e_r_t_e_x_B_u_f_f_e_r() const │ │ │ │ │ +57 { │ │ │ │ │ +58 return _vertexBuffer; │ │ │ │ │ +59 } │ │ │ │ │ 60 │ │ │ │ │ -_6_1 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r const &_G_e_t_P_a_t_c_h_A_r_r_a_y_s() const { return ___p_a_t_c_h_A_r_r_a_y_s; } │ │ │ │ │ -_6_2 id _G_e_t_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r() const { return ___i_n_d_e_x_B_u_f_f_e_r; } │ │ │ │ │ -_6_3 id _G_e_t_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r() const { return ___p_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r; } │ │ │ │ │ -64 │ │ │ │ │ -_6_5 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r const &_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s() const { return │ │ │ │ │ -___v_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s; } │ │ │ │ │ -_6_6 id _G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r() const { return │ │ │ │ │ -___v_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r; } │ │ │ │ │ -67 │ │ │ │ │ -_6_8 int _G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s() const { return (int)___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s.size(); } │ │ │ │ │ -_6_9 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r const &_G_e_t_F_V_a_r_P_a_t_c_h_A_r_r_a_y_s(int fvarChannel = 0) const │ │ │ │ │ -{ return ___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s[fvarChannel]; } │ │ │ │ │ -_7_0 id _G_e_t_F_V_a_r_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r(int fvarChannel = 0) const { return │ │ │ │ │ -___f_v_a_r_I_n_d_e_x_B_u_f_f_e_r_s[fvarChannel]; } │ │ │ │ │ -_7_1 id _G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r(int fvarChannel = 0) const { return │ │ │ │ │ -___f_v_a_r_P_a_r_a_m_B_u_f_f_e_r_s[fvarChannel]; } │ │ │ │ │ -72 │ │ │ │ │ -73protected: │ │ │ │ │ -_7_4 bool _a_l_l_o_c_a_t_e(_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e const *farPatchTable, _M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ -75 │ │ │ │ │ -_7_6 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r ___p_a_t_c_h_A_r_r_a_y_s; │ │ │ │ │ +_6_1 id _G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_B_u_f_f_e_r() const │ │ │ │ │ +62 { │ │ │ │ │ +63 return _vertexValenceBuffer; │ │ │ │ │ +64 } │ │ │ │ │ +65 │ │ │ │ │ +_6_6 id _G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_u_f_f_e_r() const │ │ │ │ │ +67 { │ │ │ │ │ +68 return _quadOffsetsBuffer; │ │ │ │ │ +69 } │ │ │ │ │ +70 │ │ │ │ │ +_7_1 int _G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_a_s_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type) │ │ │ │ │ +72 { │ │ │ │ │ +73 if(type == _F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y) │ │ │ │ │ +74 return _quadOffsetsBase[1]; │ │ │ │ │ +75 return _quadOffsetsBase[0]; │ │ │ │ │ +76 } │ │ │ │ │ 77 │ │ │ │ │ -_7_8 id ___i_n_d_e_x_B_u_f_f_e_r; │ │ │ │ │ -_7_9 id ___p_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r; │ │ │ │ │ -80 │ │ │ │ │ -_8_1 _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r ___v_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s; │ │ │ │ │ -82 │ │ │ │ │ -_8_3 id ___v_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r; │ │ │ │ │ +78private: │ │ │ │ │ +79 id _vertexBuffer; │ │ │ │ │ +80 id _vertexValenceBuffer; │ │ │ │ │ +81 id _quadOffsetsBuffer; │ │ │ │ │ +82 int _quadOffsetsBase[2]; │ │ │ │ │ +83}; │ │ │ │ │ 84 │ │ │ │ │ -_8_5 std::vector ___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s; │ │ │ │ │ -_8_6 std::vector> ___f_v_a_r_I_n_d_e_x_B_u_f_f_e_r_s; │ │ │ │ │ -_8_7 std::vector> ___f_v_a_r_P_a_r_a_m_B_u_f_f_e_r_s; │ │ │ │ │ -88}; │ │ │ │ │ +85} //end namespace Osd │ │ │ │ │ +86 │ │ │ │ │ +87} //end namespace OPENSUBDIV_VERSION │ │ │ │ │ +88using namespace OPENSUBDIV_VERSION; │ │ │ │ │ 89 │ │ │ │ │ -90} // end namespace Osd │ │ │ │ │ +90} //end namespace OpenSuddiv │ │ │ │ │ 91 │ │ │ │ │ -92} //end namespace OPENSUBDIV_VERSION │ │ │ │ │ -93using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -94 │ │ │ │ │ -95} //end namespace OpenSubdiv │ │ │ │ │ -96 │ │ │ │ │ -97#endif //end OPENSUBDIV3_OSD_MTL_PATCH_TABLE_H │ │ │ │ │ +92#endif // OPENSUBDIV3_OSD_MTL_LEGACY_GREGORY_PATCH_TABLE_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r │ │ │ │ │ -std::vector< PatchArray > PatchArrayVector │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e │ │ │ │ │ +Type │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_G_R_E_G_O_R_Y___B_O_U_N_D_A_R_Y │ │ │ │ │ +@ GREGORY_BOUNDARY │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ Container for arrays of parametric patches. │ │ │ │ │ DDeeffiinniittiioonn _p_a_t_c_h_T_a_b_l_e_._h_:_5_5 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t │ │ │ │ │ DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_4_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -PatchArrayVector const & GetPatchArrays() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_a_l_l_o_c_a_t_e │ │ │ │ │ -bool allocate(Far::PatchTable const *farPatchTable, MTLContext *context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, MTLContext │ │ │ │ │ -*context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetVaryingPatchIndexBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___f_v_a_r_I_n_d_e_x_B_u_f_f_e_r_s │ │ │ │ │ -std::vector< id< MTLBuffer > > _fvarIndexBuffers │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetFVarPatchParamBuffer(int fvarChannel=0) const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -MTLPatchTable() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetPatchParamBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetPatchIndexBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___p_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -PatchArrayVector _patchArrays │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_V_e_r_t_e_x_B_u_f_f_e_r_B_i_n_d_i_n_g │ │ │ │ │ -id< MTLBuffer > VertexBufferBinding │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_N_u_m_F_V_a_r_C_h_a_n_n_e_l_s │ │ │ │ │ -int GetNumFVarChannels() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -PatchArrayVector const & GetFVarPatchArrays(int fvarChannel=0) const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___v_a_r_y_i_n_g_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > _varyingPatchIndexBuffer │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___f_v_a_r_P_a_r_a_m_B_u_f_f_e_r_s │ │ │ │ │ -std::vector< id< MTLBuffer > > _fvarParamBuffers │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___f_v_a_r_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -std::vector< PatchArrayVector > _fvarPatchArrays │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___p_a_t_c_h_P_a_r_a_m_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > _patchParamBuffer │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___v_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -PatchArrayVector _varyingPatchArrays │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static MTLPatchTable * Create(Far::PatchTable const *farPatchTable, │ │ │ │ │ -DEVICE_CONTEXT context) │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_~_M_T_L_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ -~MTLPatchTable() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_F_V_a_r_P_a_t_c_h_I_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > GetFVarPatchIndexBuffer(int fvarChannel=0) const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:_G_e_t_V_a_r_y_i_n_g_P_a_t_c_h_A_r_r_a_y_s │ │ │ │ │ -PatchArrayVector const & GetVaryingPatchArrays() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_6_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_P_a_t_c_h_T_a_b_l_e_:_:___i_n_d_e_x_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > _indexBuffer │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_P_a_t_c_h_T_a_b_l_e_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_4_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_a_s_e │ │ │ │ │ +int GetQuadOffsetsBase(Far::PatchDescriptor::Type type) │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const │ │ │ │ │ +*farPatchTable, DEVICE_CONTEXT context) │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_V_e_r_t_e_x_V_a_l_e_n_c_e_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetVertexValenceBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_Q_u_a_d_O_f_f_s_e_t_s_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetQuadOffsetsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static MTLLegacyGregoryPatchTable * Create(Far::PatchTable const │ │ │ │ │ +*farPatchTable, MTLContext *context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_U_p_d_a_t_e_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +void UpdateVertexBuffer(id< MTLBuffer > vbo, int numVertices, int │ │ │ │ │ +numVertexElements, MTLContext *context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_~_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e │ │ │ │ │ +~MTLLegacyGregoryPatchTable() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_:_: │ │ │ │ │ +_G_e_t_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > GetVertexBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h_:_5_6 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ + * _m_t_l_L_e_g_a_c_y_G_r_e_g_o_r_y_P_a_t_c_h_T_a_b_l_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00821.html │ │ │ │ @@ -95,16 +95,16 @@ │ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │
mtlComputeEvaluator.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ -#include "../osd/mtlCommon.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/mtlCommon.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00821_source.html │ │ │ │ @@ -1184,18 +1184,18 @@ │ │ │ │
2163using namespace OPENSUBDIV_VERSION;
│ │ │ │
2164
│ │ │ │
2165} //end namespace OpenSubdiv
│ │ │ │
2166
│ │ │ │
2167#endif // OPENSUBDIV3_OSD_MTL_COMPUTE_EVALUATOR_H
│ │ │ │ │ │ │ │
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ │ │ │ │
MTLStencilTable(Far::LimitStencilTable const *stencilTable, MTLContext *context)
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
MTLStencilTable(Far::StencilTable const *stencilTable, MTLContext *context)
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00824.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/hlslPatchShaderSource.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlVertexBuffer.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,27 +90,25 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
hlslPatchShaderSource.h File Reference
│ │ │ │ +
mtlVertexBuffer.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ -#include <string>
│ │ │ │ +#include "../osd/mtlCommon.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  MTLStencilTable
 
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  HLSLPatchShaderSource
 Provides shader source which can be used by client code. More...
class  CPUMTLVertexBuffer
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -119,13 +117,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,25 +1,23 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -hlslPatchShaderSource.h File Reference │ │ │ │ │ +mtlVertexBuffer.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_o_s_d_/_m_t_l_C_o_m_m_o_n_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -  Provides shader source which can be used by client code. _M_o_r_e_._._. │ │ │ │ │ +class   _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _h_l_s_l_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_._h │ │ │ │ │ + * _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00824.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00824 = [ │ │ │ │ │ - ["HLSLPatchShaderSource", "a01265.html", null] │ │ │ │ │ + ["CPUMTLVertexBuffer", "a01309.html", "a01309"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00824_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/hlslPatchShaderSource.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/mtlVertexBuffer.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
hlslPatchShaderSource.h
│ │ │ │ +
mtlVertexBuffer.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2015 Pixar
│ │ │ │ +
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -119,68 +119,97 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29
│ │ │ │ -
30#include "../far/patchDescriptor.h"
│ │ │ │ -
31
│ │ │ │ -
32#include <string>
│ │ │ │ +
29#include "../osd/mtlCommon.h"
│ │ │ │ +
30
│ │ │ │ +
31@protocol MTLDevice;
│ │ │ │ +
32@protocol MTLBuffer;
│ │ │ │
33
│ │ │ │
34namespace OpenSubdiv {
│ │ │ │
35namespace OPENSUBDIV_VERSION {
│ │ │ │
36
│ │ │ │
37namespace Osd {
│ │ │ │
38
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
41public:
│ │ │ │ -
45 static std::string GetPatchBasisShaderSource();
│ │ │ │ -
46
│ │ │ │ -
50 static std::string GetPatchDrawingShaderSource();
│ │ │ │ -
51
│ │ │ │ -
59
│ │ │ │ -
60 static std::string GetCommonShaderSource();
│ │ │ │ -
61
│ │ │ │ - │ │ │ │ -
63
│ │ │ │ - │ │ │ │ -
65
│ │ │ │ - │ │ │ │ -
67
│ │ │ │ -
69};
│ │ │ │ -
│ │ │ │ -
70
│ │ │ │ -
71} // end namespace Osd
│ │ │ │ -
72
│ │ │ │ -
73} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
74using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
40public:
│ │ │ │ +
41 static CPUMTLVertexBuffer* Create(int numElements, int numVertices, MTLContext* context);
│ │ │ │ +
42
│ │ │ │ +
43 void UpdateData(const float* src, int startVertex, int numVertices, MTLContext* context);
│ │ │ │ +
44
│ │ │ │ +
│ │ │ │ +
45 int GetNumElements() const
│ │ │ │ +
46 {
│ │ │ │ +
47 return _numElements;
│ │ │ │ +
48 }
│ │ │ │ +
│ │ │ │ +
49
│ │ │ │ +
│ │ │ │ +
50 int GetNumVertices() const
│ │ │ │ +
51 {
│ │ │ │ +
52 return _numVertices;
│ │ │ │ +
53 }
│ │ │ │ +
│ │ │ │ +
54
│ │ │ │ +
55 float* BindCpuBuffer();
│ │ │ │ +
56 id<MTLBuffer> BindMTLBuffer(MTLContext* context);
│ │ │ │ +
57
│ │ │ │ +
│ │ │ │ +
58 id<MTLBuffer> BindVBO(MTLContext* context)
│ │ │ │ +
59 {
│ │ │ │ +
60 return BindMTLBuffer(context);
│ │ │ │ +
61 }
│ │ │ │ +
│ │ │ │ +
62
│ │ │ │ +
63protected:
│ │ │ │ +
64
│ │ │ │ +
65 CPUMTLVertexBuffer(int numElements, int numVertices);
│ │ │ │ +
66
│ │ │ │ +
67 bool allocate(MTLContext* context);
│ │ │ │ +
68
│ │ │ │ +
69private:
│ │ │ │ +
70 int _numElements;
│ │ │ │ +
71 int _numVertices;
│ │ │ │ +
72 id<MTLBuffer> _buffer;
│ │ │ │ +
73 bool _dirty;
│ │ │ │ +
74};
│ │ │ │ +
│ │ │ │
75
│ │ │ │ -
76} // end namespace OpenSubdiv
│ │ │ │ +
76} //end namespace Osd
│ │ │ │
77
│ │ │ │ -
78#endif // OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H
│ │ │ │ +
78} //end namespace OPENSUBDIV_VERSION
│ │ │ │ +
79 using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
80
│ │ │ │ +
81} //end namespace OpenSubdiv
│ │ │ │ +
82
│ │ │ │ +
83#endif // OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H
│ │ │ │ │ │ │ │ - │ │ │ │ -
Provides shader source which can be used by client code.
│ │ │ │ -
static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │ -
static std::string GetPatchDrawingShaderSource()
Returns shader source which can be used while drawing piecewise parametric patches resulting from sub...
│ │ │ │ -
static std::string GetDomainShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │ -
static std::string GetHullShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │ -
static std::string GetPatchBasisShaderSource()
Returns shader source which can be used to evaluate position and first and second derivatives on piec...
│ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
CPUMTLVertexBuffer(int numElements, int numVertices)
│ │ │ │ +
static CPUMTLVertexBuffer * Create(int numElements, int numVertices, MTLContext *context)
│ │ │ │ + │ │ │ │ +
void UpdateData(const float *src, int startVertex, int numVertices, MTLContext *context)
│ │ │ │ + │ │ │ │ +
id< MTLBuffer > BindMTLBuffer(MTLContext *context)
│ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -hlslPatchShaderSource.h │ │ │ │ │ +mtlVertexBuffer.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2015 Pixar │ │ │ │ │ +2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -24,79 +24,101 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29 │ │ │ │ │ -30#include "../far/patchDescriptor.h" │ │ │ │ │ -31 │ │ │ │ │ -32#include │ │ │ │ │ +29#include "../osd/mtlCommon.h" │ │ │ │ │ +30 │ │ │ │ │ +31@protocol MTLDevice; │ │ │ │ │ +32@protocol MTLBuffer; │ │ │ │ │ 33 │ │ │ │ │ 34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ 35namespace OPENSUBDIV_VERSION { │ │ │ │ │ 36 │ │ │ │ │ 37namespace Osd { │ │ │ │ │ 38 │ │ │ │ │ -_4_0class _H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e { │ │ │ │ │ -41public: │ │ │ │ │ -_4_5 static std::string _G_e_t_P_a_t_c_h_B_a_s_i_s_S_h_a_d_e_r_S_o_u_r_c_e(); │ │ │ │ │ -46 │ │ │ │ │ -_5_0 static std::string _G_e_t_P_a_t_c_h_D_r_a_w_i_n_g_S_h_a_d_e_r_S_o_u_r_c_e(); │ │ │ │ │ -51 │ │ │ │ │ -59 │ │ │ │ │ -_6_0 static std::string _G_e_t_C_o_m_m_o_n_S_h_a_d_e_r_S_o_u_r_c_e(); │ │ │ │ │ -61 │ │ │ │ │ -_6_2 static std::string _G_e_t_V_e_r_t_e_x_S_h_a_d_e_r_S_o_u_r_c_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type); │ │ │ │ │ -63 │ │ │ │ │ -_6_4 static std::string _G_e_t_H_u_l_l_S_h_a_d_e_r_S_o_u_r_c_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type); │ │ │ │ │ -65 │ │ │ │ │ -_6_6 static std::string _G_e_t_D_o_m_a_i_n_S_h_a_d_e_r_S_o_u_r_c_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type); │ │ │ │ │ -67 │ │ │ │ │ -69}; │ │ │ │ │ -70 │ │ │ │ │ -71} // end namespace Osd │ │ │ │ │ -72 │ │ │ │ │ -73} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -74using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +_3_9class _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r { │ │ │ │ │ +40public: │ │ │ │ │ +_4_1 static _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r* _C_r_e_a_t_e(int numElements, int numVertices, │ │ │ │ │ +_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +42 │ │ │ │ │ +_4_3 void _U_p_d_a_t_e_D_a_t_a(const float* src, int startVertex, int numVertices, │ │ │ │ │ +_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +44 │ │ │ │ │ +_4_5 int _G_e_t_N_u_m_E_l_e_m_e_n_t_s() const │ │ │ │ │ +46 { │ │ │ │ │ +47 return _numElements; │ │ │ │ │ +48 } │ │ │ │ │ +49 │ │ │ │ │ +_5_0 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s() const │ │ │ │ │ +51 { │ │ │ │ │ +52 return _numVertices; │ │ │ │ │ +53 } │ │ │ │ │ +54 │ │ │ │ │ +_5_5 float* _B_i_n_d_C_p_u_B_u_f_f_e_r(); │ │ │ │ │ +_5_6 id _B_i_n_d_M_T_L_B_u_f_f_e_r(_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +57 │ │ │ │ │ +_5_8 id _B_i_n_d_V_B_O(_M_T_L_C_o_n_t_e_x_t* context) │ │ │ │ │ +59 { │ │ │ │ │ +60 return _B_i_n_d_M_T_L_B_u_f_f_e_r(context); │ │ │ │ │ +61 } │ │ │ │ │ +62 │ │ │ │ │ +63protected: │ │ │ │ │ +64 │ │ │ │ │ +_6_5 _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r(int numElements, int numVertices); │ │ │ │ │ +66 │ │ │ │ │ +_6_7 bool _a_l_l_o_c_a_t_e(_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +68 │ │ │ │ │ +69private: │ │ │ │ │ +70 int _numElements; │ │ │ │ │ +71 int _numVertices; │ │ │ │ │ +72 id _buffer; │ │ │ │ │ +73 bool _dirty; │ │ │ │ │ +74}; │ │ │ │ │ 75 │ │ │ │ │ -76} // end namespace OpenSubdiv │ │ │ │ │ +76} //end namespace Osd │ │ │ │ │ 77 │ │ │ │ │ -78#endif // OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H │ │ │ │ │ +78} //end namespace OPENSUBDIV_VERSION │ │ │ │ │ +79 using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +80 │ │ │ │ │ +81} //end namespace OpenSubdiv │ │ │ │ │ +82 │ │ │ │ │ +83#endif // OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e │ │ │ │ │ -Type │ │ │ │ │ -DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -Provides shader source which can be used by client code. │ │ │ │ │ -DDeeffiinniittiioonn _h_l_s_l_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ -_G_e_t_V_e_r_t_e_x_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ -_G_e_t_P_a_t_c_h_D_r_a_w_i_n_g_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -static std::string GetPatchDrawingShaderSource() │ │ │ │ │ -Returns shader source which can be used while drawing piecewise parametric │ │ │ │ │ -patches resulting from sub... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ -_G_e_t_D_o_m_a_i_n_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -static std::string GetDomainShaderSource(Far::PatchDescriptor::Type type) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_:_G_e_t_H_u_l_l_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -static std::string GetHullShaderSource(Far::PatchDescriptor::Type type) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ -_G_e_t_P_a_t_c_h_B_a_s_i_s_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -static std::string GetPatchBasisShaderSource() │ │ │ │ │ -Returns shader source which can be used to evaluate position and first and │ │ │ │ │ -second derivatives on piec... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ -_G_e_t_C_o_m_m_o_n_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ -static std::string GetCommonShaderSource() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_V_B_O │ │ │ │ │ +id< MTLBuffer > BindVBO(MTLContext *context) │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +CPUMTLVertexBuffer(int numElements, int numVertices) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static CPUMTLVertexBuffer * Create(int numElements, int numVertices, MTLContext │ │ │ │ │ +*context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_E_l_e_m_e_n_t_s │ │ │ │ │ +int GetNumElements() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_4_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_U_p_d_a_t_e_D_a_t_a │ │ │ │ │ +void UpdateData(const float *src, int startVertex, int numVertices, MTLContext │ │ │ │ │ +*context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ +int GetNumVertices() const │ │ │ │ │ +DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_5_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_M_T_L_B_u_f_f_e_r │ │ │ │ │ +id< MTLBuffer > BindMTLBuffer(MTLContext *context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_C_p_u_B_u_f_f_e_r │ │ │ │ │ +float * BindCpuBuffer() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_a_l_l_o_c_a_t_e │ │ │ │ │ +bool allocate(MTLContext *context) │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _h_l_s_l_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_._h │ │ │ │ │ + * _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00827.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlVertexBuffer.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/d3d11Mesh.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -88,42 +88,43 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ -Classes | │ │ │ │ -Namespaces
│ │ │ │ -
mtlVertexBuffer.h File Reference
│ │ │ │ +Namespaces | │ │ │ │ +Typedefs
│ │ │ │ +
d3d11Mesh.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/mtlCommon.h"
│ │ │ │ +#include "../osd/mesh.h"
│ │ │ │ +#include "../osd/d3d11PatchTable.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -

│ │ │ │ -Classes

class  CPUMTLVertexBuffer
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ +

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │

│ │ │ │ +Typedefs

typedef MeshInterface< D3D11PatchTableD3D11MeshInterface
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,23 +1,24 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -mtlVertexBuffer.h File Reference │ │ │ │ │ +_N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s │ │ │ │ │ +d3d11Mesh.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_m_t_l_C_o_m_m_o_n_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_m_e_s_h_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_d_3_d_1_1_P_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ -CCllaasssseess │ │ │ │ │ -class   _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -  │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ +TTyyppeeddeeffss │ │ │ │ │ +typedef _M_e_s_h_I_n_t_e_r_f_a_c_e< _D_3_D_1_1_P_a_t_c_h_T_a_b_l_e >  _D_3_D_1_1_M_e_s_h_I_n_t_e_r_f_a_c_e │ │ │ │ │ +  │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ + * _d_3_d_1_1_M_e_s_h_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00827.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00827 = [ │ │ │ │ │ - ["CPUMTLVertexBuffer", "a01309.html", "a01309"] │ │ │ │ │ + ["D3D11MeshInterface", "a00827.html#ae5c8e80d05d6eaee105d8eecfa9ab609", null] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00827_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/mtlVertexBuffer.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/d3d11Mesh.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
mtlVertexBuffer.h
│ │ │ │ +
d3d11Mesh.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,97 +119,45 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_D3D11MESH_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_D3D11MESH_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29#include "../osd/mtlCommon.h"
│ │ │ │ -
30
│ │ │ │ -
31@protocol MTLDevice;
│ │ │ │ -
32@protocol MTLBuffer;
│ │ │ │ -
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Osd {
│ │ │ │ -
38
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
40public:
│ │ │ │ -
41 static CPUMTLVertexBuffer* Create(int numElements, int numVertices, MTLContext* context);
│ │ │ │ +
29
│ │ │ │ +
30#include "../osd/mesh.h"
│ │ │ │ +
31#include "../osd/d3d11PatchTable.h"
│ │ │ │ +
32
│ │ │ │ +
33namespace OpenSubdiv {
│ │ │ │ +
34namespace OPENSUBDIV_VERSION {
│ │ │ │ +
35
│ │ │ │ +
36namespace Osd {
│ │ │ │ +
37
│ │ │ │ + │ │ │ │ +
39
│ │ │ │ +
40
│ │ │ │ +
41} // end namespace Osd
│ │ │ │
42
│ │ │ │ -
43 void UpdateData(const float* src, int startVertex, int numVertices, MTLContext* context);
│ │ │ │ -
44
│ │ │ │ -
│ │ │ │ -
45 int GetNumElements() const
│ │ │ │ -
46 {
│ │ │ │ -
47 return _numElements;
│ │ │ │ -
48 }
│ │ │ │ -
│ │ │ │ -
49
│ │ │ │ -
│ │ │ │ -
50 int GetNumVertices() const
│ │ │ │ -
51 {
│ │ │ │ -
52 return _numVertices;
│ │ │ │ -
53 }
│ │ │ │ -
│ │ │ │ -
54
│ │ │ │ -
55 float* BindCpuBuffer();
│ │ │ │ -
56 id<MTLBuffer> BindMTLBuffer(MTLContext* context);
│ │ │ │ -
57
│ │ │ │ -
│ │ │ │ -
58 id<MTLBuffer> BindVBO(MTLContext* context)
│ │ │ │ -
59 {
│ │ │ │ -
60 return BindMTLBuffer(context);
│ │ │ │ -
61 }
│ │ │ │ -
│ │ │ │ -
62
│ │ │ │ -
63protected:
│ │ │ │ -
64
│ │ │ │ -
65 CPUMTLVertexBuffer(int numElements, int numVertices);
│ │ │ │ -
66
│ │ │ │ -
67 bool allocate(MTLContext* context);
│ │ │ │ -
68
│ │ │ │ -
69private:
│ │ │ │ -
70 int _numElements;
│ │ │ │ -
71 int _numVertices;
│ │ │ │ -
72 id<MTLBuffer> _buffer;
│ │ │ │ -
73 bool _dirty;
│ │ │ │ -
74};
│ │ │ │ -
│ │ │ │ -
75
│ │ │ │ -
76} //end namespace Osd
│ │ │ │ -
77
│ │ │ │ -
78} //end namespace OPENSUBDIV_VERSION
│ │ │ │ -
79 using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
80
│ │ │ │ -
81} //end namespace OpenSubdiv
│ │ │ │ -
82
│ │ │ │ -
83#endif // OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H
│ │ │ │ +
43} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
44using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
45
│ │ │ │ +
46} // end namespace OpenSubdiv
│ │ │ │ +
47
│ │ │ │ +
48#endif // OPENSUBDIV3_OSD_D3D11MESH_H
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
CPUMTLVertexBuffer(int numElements, int numVertices)
│ │ │ │ -
static CPUMTLVertexBuffer * Create(int numElements, int numVertices, MTLContext *context)
│ │ │ │ - │ │ │ │ -
void UpdateData(const float *src, int startVertex, int numVertices, MTLContext *context)
│ │ │ │ - │ │ │ │ -
id< MTLBuffer > BindMTLBuffer(MTLContext *context)
│ │ │ │ - │ │ │ │ - │ │ │ │ +
MeshInterface< D3D11PatchTable > D3D11MeshInterface
Definition d3d11Mesh.h:38
│ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -mtlVertexBuffer.h │ │ │ │ │ +d3d11Mesh.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,101 +24,42 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_D3D11MESH_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_D3D11MESH_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29#include "../osd/mtlCommon.h" │ │ │ │ │ -30 │ │ │ │ │ -31@protocol MTLDevice; │ │ │ │ │ -32@protocol MTLBuffer; │ │ │ │ │ -33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Osd { │ │ │ │ │ -38 │ │ │ │ │ -_3_9class _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r { │ │ │ │ │ -40public: │ │ │ │ │ -_4_1 static _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r* _C_r_e_a_t_e(int numElements, int numVertices, │ │ │ │ │ -_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ +29 │ │ │ │ │ +30#include "../osd/mesh.h" │ │ │ │ │ +31#include "../osd/d3d11PatchTable.h" │ │ │ │ │ +32 │ │ │ │ │ +33namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +34namespace OPENSUBDIV_VERSION { │ │ │ │ │ +35 │ │ │ │ │ +36namespace Osd { │ │ │ │ │ +37 │ │ │ │ │ +_3_8typedef _M_e_s_h_I_n_t_e_r_f_a_c_e_<_D_3_D_1_1_P_a_t_c_h_T_a_b_l_e_> _D_3_D_1_1_M_e_s_h_I_n_t_e_r_f_a_c_e; │ │ │ │ │ +39 │ │ │ │ │ +40 │ │ │ │ │ +41} // end namespace Osd │ │ │ │ │ 42 │ │ │ │ │ -_4_3 void _U_p_d_a_t_e_D_a_t_a(const float* src, int startVertex, int numVertices, │ │ │ │ │ -_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ -44 │ │ │ │ │ -_4_5 int _G_e_t_N_u_m_E_l_e_m_e_n_t_s() const │ │ │ │ │ -46 { │ │ │ │ │ -47 return _numElements; │ │ │ │ │ -48 } │ │ │ │ │ -49 │ │ │ │ │ -_5_0 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s() const │ │ │ │ │ -51 { │ │ │ │ │ -52 return _numVertices; │ │ │ │ │ -53 } │ │ │ │ │ -54 │ │ │ │ │ -_5_5 float* _B_i_n_d_C_p_u_B_u_f_f_e_r(); │ │ │ │ │ -_5_6 id _B_i_n_d_M_T_L_B_u_f_f_e_r(_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ -57 │ │ │ │ │ -_5_8 id _B_i_n_d_V_B_O(_M_T_L_C_o_n_t_e_x_t* context) │ │ │ │ │ -59 { │ │ │ │ │ -60 return _B_i_n_d_M_T_L_B_u_f_f_e_r(context); │ │ │ │ │ -61 } │ │ │ │ │ -62 │ │ │ │ │ -63protected: │ │ │ │ │ -64 │ │ │ │ │ -_6_5 _C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r(int numElements, int numVertices); │ │ │ │ │ -66 │ │ │ │ │ -_6_7 bool _a_l_l_o_c_a_t_e(_M_T_L_C_o_n_t_e_x_t* context); │ │ │ │ │ -68 │ │ │ │ │ -69private: │ │ │ │ │ -70 int _numElements; │ │ │ │ │ -71 int _numVertices; │ │ │ │ │ -72 id _buffer; │ │ │ │ │ -73 bool _dirty; │ │ │ │ │ -74}; │ │ │ │ │ -75 │ │ │ │ │ -76} //end namespace Osd │ │ │ │ │ -77 │ │ │ │ │ -78} //end namespace OPENSUBDIV_VERSION │ │ │ │ │ -79 using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -80 │ │ │ │ │ -81} //end namespace OpenSubdiv │ │ │ │ │ -82 │ │ │ │ │ -83#endif // OPENSUBDIV3_OSD_MTL_VERTEX_BUFFER_H │ │ │ │ │ +43} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +44using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +45 │ │ │ │ │ +46} // end namespace OpenSubdiv │ │ │ │ │ +47 │ │ │ │ │ +48#endif // OPENSUBDIV3_OSD_D3D11MESH_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_T_L_C_o_n_t_e_x_t │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_C_o_m_m_o_n_._h_:_4_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_V_B_O │ │ │ │ │ -id< MTLBuffer > BindVBO(MTLContext *context) │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -CPUMTLVertexBuffer(int numElements, int numVertices) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static CPUMTLVertexBuffer * Create(int numElements, int numVertices, MTLContext │ │ │ │ │ -*context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_E_l_e_m_e_n_t_s │ │ │ │ │ -int GetNumElements() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_4_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_U_p_d_a_t_e_D_a_t_a │ │ │ │ │ -void UpdateData(const float *src, int startVertex, int numVertices, MTLContext │ │ │ │ │ -*context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ -int GetNumVertices() const │ │ │ │ │ -DDeeffiinniittiioonn _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_5_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_M_T_L_B_u_f_f_e_r │ │ │ │ │ -id< MTLBuffer > BindMTLBuffer(MTLContext *context) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_C_p_u_B_u_f_f_e_r │ │ │ │ │ -float * BindCpuBuffer() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_P_U_M_T_L_V_e_r_t_e_x_B_u_f_f_e_r_:_:_a_l_l_o_c_a_t_e │ │ │ │ │ -bool allocate(MTLContext *context) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_M_e_s_h_I_n_t_e_r_f_a_c_e │ │ │ │ │ +MeshInterface< D3D11PatchTable > D3D11MeshInterface │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_M_e_s_h_._h_:_3_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_e_s_h_I_n_t_e_r_f_a_c_e │ │ │ │ │ +DDeeffiinniittiioonn _m_e_s_h_._h_:_6_8 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _m_t_l_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ + * _d_3_d_1_1_M_e_s_h_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00830.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/d3d11Mesh.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/hlslPatchShaderSource.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -88,43 +88,44 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ -Namespaces | │ │ │ │ -Typedefs
│ │ │ │ -
d3d11Mesh.h File Reference
│ │ │ │ +Classes | │ │ │ │ +Namespaces
│ │ │ │ +
hlslPatchShaderSource.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/mesh.h"
│ │ │ │ -#include "../osd/d3d11PatchTable.h"
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ +#include <string>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +

│ │ │ │ +Classes

class  HLSLPatchShaderSource
 Provides shader source which can be used by client code. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │

│ │ │ │ -Typedefs

typedef MeshInterface< D3D11PatchTableD3D11MeshInterface
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,24 +1,25 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -_N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s │ │ │ │ │ -d3d11Mesh.h File Reference │ │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ +hlslPatchShaderSource.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_m_e_s_h_._h" │ │ │ │ │ -#include "_._._/_o_s_d_/_d_3_d_1_1_P_a_t_c_h_T_a_b_l_e_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ +CCllaasssseess │ │ │ │ │ +class   _H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +  Provides shader source which can be used by client code. _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ -TTyyppeeddeeffss │ │ │ │ │ -typedef _M_e_s_h_I_n_t_e_r_f_a_c_e< _D_3_D_1_1_P_a_t_c_h_T_a_b_l_e >  _D_3_D_1_1_M_e_s_h_I_n_t_e_r_f_a_c_e │ │ │ │ │ -  │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _d_3_d_1_1_M_e_s_h_._h │ │ │ │ │ + * _h_l_s_l_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00830.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00830 = [ │ │ │ │ │ - ["D3D11MeshInterface", "a00830.html#ae5c8e80d05d6eaee105d8eecfa9ab609", null] │ │ │ │ │ + ["HLSLPatchShaderSource", "a01265.html", null] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00830_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/d3d11Mesh.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/hlslPatchShaderSource.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
d3d11Mesh.h
│ │ │ │ +
hlslPatchShaderSource.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2013 Pixar
│ │ │ │ +
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -119,45 +119,68 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_D3D11MESH_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_D3D11MESH_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../osd/mesh.h"
│ │ │ │ -
31#include "../osd/d3d11PatchTable.h"
│ │ │ │ -
32
│ │ │ │ -
33namespace OpenSubdiv {
│ │ │ │ -
34namespace OPENSUBDIV_VERSION {
│ │ │ │ -
35
│ │ │ │ -
36namespace Osd {
│ │ │ │ -
37
│ │ │ │ - │ │ │ │ -
39
│ │ │ │ -
40
│ │ │ │ -
41} // end namespace Osd
│ │ │ │ -
42
│ │ │ │ -
43} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
44using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
45
│ │ │ │ -
46} // end namespace OpenSubdiv
│ │ │ │ -
47
│ │ │ │ -
48#endif // OPENSUBDIV3_OSD_D3D11MESH_H
│ │ │ │ +
30#include "../far/patchDescriptor.h"
│ │ │ │ +
31
│ │ │ │ +
32#include <string>
│ │ │ │ +
33
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Osd {
│ │ │ │ +
38
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
41public:
│ │ │ │ +
45 static std::string GetPatchBasisShaderSource();
│ │ │ │ +
46
│ │ │ │ +
50 static std::string GetPatchDrawingShaderSource();
│ │ │ │ +
51
│ │ │ │ +
59
│ │ │ │ +
60 static std::string GetCommonShaderSource();
│ │ │ │ +
61
│ │ │ │ + │ │ │ │ +
63
│ │ │ │ + │ │ │ │ +
65
│ │ │ │ + │ │ │ │ +
67
│ │ │ │ +
69};
│ │ │ │ +
│ │ │ │ +
70
│ │ │ │ +
71} // end namespace Osd
│ │ │ │ +
72
│ │ │ │ +
73} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
74using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
75
│ │ │ │ +
76} // end namespace OpenSubdiv
│ │ │ │ +
77
│ │ │ │ +
78#endif // OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H
│ │ │ │ │ │ │ │ -
MeshInterface< D3D11PatchTable > D3D11MeshInterface
Definition d3d11Mesh.h:38
│ │ │ │ - │ │ │ │ + │ │ │ │ +
Provides shader source which can be used by client code.
│ │ │ │ +
static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │ +
static std::string GetPatchDrawingShaderSource()
Returns shader source which can be used while drawing piecewise parametric patches resulting from sub...
│ │ │ │ +
static std::string GetDomainShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │ +
static std::string GetHullShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │ +
static std::string GetPatchBasisShaderSource()
Returns shader source which can be used to evaluate position and first and second derivatives on piec...
│ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -d3d11Mesh.h │ │ │ │ │ +hlslPatchShaderSource.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2013 Pixar │ │ │ │ │ +2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -24,42 +24,79 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_D3D11MESH_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_D3D11MESH_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../osd/mesh.h" │ │ │ │ │ -31#include "../osd/d3d11PatchTable.h" │ │ │ │ │ -32 │ │ │ │ │ -33namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -34namespace OPENSUBDIV_VERSION { │ │ │ │ │ -35 │ │ │ │ │ -36namespace Osd { │ │ │ │ │ -37 │ │ │ │ │ -_3_8typedef _M_e_s_h_I_n_t_e_r_f_a_c_e_<_D_3_D_1_1_P_a_t_c_h_T_a_b_l_e_> _D_3_D_1_1_M_e_s_h_I_n_t_e_r_f_a_c_e; │ │ │ │ │ -39 │ │ │ │ │ -40 │ │ │ │ │ -41} // end namespace Osd │ │ │ │ │ -42 │ │ │ │ │ -43} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -44using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -45 │ │ │ │ │ -46} // end namespace OpenSubdiv │ │ │ │ │ -47 │ │ │ │ │ -48#endif // OPENSUBDIV3_OSD_D3D11MESH_H │ │ │ │ │ +30#include "../far/patchDescriptor.h" │ │ │ │ │ +31 │ │ │ │ │ +32#include │ │ │ │ │ +33 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Osd { │ │ │ │ │ +38 │ │ │ │ │ +_4_0class _H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e { │ │ │ │ │ +41public: │ │ │ │ │ +_4_5 static std::string _G_e_t_P_a_t_c_h_B_a_s_i_s_S_h_a_d_e_r_S_o_u_r_c_e(); │ │ │ │ │ +46 │ │ │ │ │ +_5_0 static std::string _G_e_t_P_a_t_c_h_D_r_a_w_i_n_g_S_h_a_d_e_r_S_o_u_r_c_e(); │ │ │ │ │ +51 │ │ │ │ │ +59 │ │ │ │ │ +_6_0 static std::string _G_e_t_C_o_m_m_o_n_S_h_a_d_e_r_S_o_u_r_c_e(); │ │ │ │ │ +61 │ │ │ │ │ +_6_2 static std::string _G_e_t_V_e_r_t_e_x_S_h_a_d_e_r_S_o_u_r_c_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type); │ │ │ │ │ +63 │ │ │ │ │ +_6_4 static std::string _G_e_t_H_u_l_l_S_h_a_d_e_r_S_o_u_r_c_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type); │ │ │ │ │ +65 │ │ │ │ │ +_6_6 static std::string _G_e_t_D_o_m_a_i_n_S_h_a_d_e_r_S_o_u_r_c_e(_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e type); │ │ │ │ │ +67 │ │ │ │ │ +69}; │ │ │ │ │ +70 │ │ │ │ │ +71} // end namespace Osd │ │ │ │ │ +72 │ │ │ │ │ +73} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +74using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +75 │ │ │ │ │ +76} // end namespace OpenSubdiv │ │ │ │ │ +77 │ │ │ │ │ +78#endif // OPENSUBDIV3_OSD_HLSL_PATCH_SHADER_SOURCE_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_M_e_s_h_I_n_t_e_r_f_a_c_e │ │ │ │ │ -MeshInterface< D3D11PatchTable > D3D11MeshInterface │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_M_e_s_h_._h_:_3_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_M_e_s_h_I_n_t_e_r_f_a_c_e │ │ │ │ │ -DDeeffiinniittiioonn _m_e_s_h_._h_:_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_P_a_t_c_h_D_e_s_c_r_i_p_t_o_r_:_:_T_y_p_e │ │ │ │ │ +Type │ │ │ │ │ +DDeeffiinniittiioonn _p_a_t_c_h_D_e_s_c_r_i_p_t_o_r_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +Provides shader source which can be used by client code. │ │ │ │ │ +DDeeffiinniittiioonn _h_l_s_l_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_._h_:_4_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ +_G_e_t_V_e_r_t_e_x_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ +_G_e_t_P_a_t_c_h_D_r_a_w_i_n_g_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +static std::string GetPatchDrawingShaderSource() │ │ │ │ │ +Returns shader source which can be used while drawing piecewise parametric │ │ │ │ │ +patches resulting from sub... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ +_G_e_t_D_o_m_a_i_n_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +static std::string GetDomainShaderSource(Far::PatchDescriptor::Type type) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_:_G_e_t_H_u_l_l_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +static std::string GetHullShaderSource(Far::PatchDescriptor::Type type) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ +_G_e_t_P_a_t_c_h_B_a_s_i_s_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +static std::string GetPatchBasisShaderSource() │ │ │ │ │ +Returns shader source which can be used to evaluate position and first and │ │ │ │ │ +second derivatives on piec... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_H_L_S_L_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_:_: │ │ │ │ │ +_G_e_t_C_o_m_m_o_n_S_h_a_d_e_r_S_o_u_r_c_e │ │ │ │ │ +static std::string GetCommonShaderSource() │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _d_3_d_1_1_M_e_s_h_._h │ │ │ │ │ + * _h_l_s_l_P_a_t_c_h_S_h_a_d_e_r_S_o_u_r_c_e_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00836.html │ │ │ │ @@ -95,15 +95,15 @@ │ │ │ │ Classes | │ │ │ │ Namespaces │ │ │ │
d3d11PatchTable.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include <vector>
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ #include "../osd/nonCopyable.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00836_source.html │ │ │ │ @@ -204,15 +204,15 @@ │ │ │ │
95using namespace OPENSUBDIV_VERSION;
│ │ │ │
96
│ │ │ │
97} // end namespace OpenSubdiv
│ │ │ │
98
│ │ │ │
99#endif // OPENSUBDIV3_OSD_GL_PATCH_TABLE_H
│ │ │ │ │ │ │ │
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │
static D3D11PatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ │ │ │ │ │
bool allocate(Far::PatchTable const *farPatchTable, ID3D11DeviceContext *deviceContext)
│ │ │ │ │ │ │ │ │ │ │ │
ID3D11Buffer * GetPatchIndexBuffer() const
Returns the index buffer containing the patch control vertices.
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00839.html │ │ │ │ @@ -94,15 +94,15 @@ │ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │
d3d11LegacyGregoryPatchTable.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │ #include "../osd/nonCopyable.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

│ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00839_source.html │ │ │ │ @@ -210,17 +210,17 @@ │ │ │ │
97} // end namespace OPENSUBDIV_VERSION
│ │ │ │
98using namespace OPENSUBDIV_VERSION;
│ │ │ │
99
│ │ │ │
100} // end namespace OpenSubdiv
│ │ │ │
101
│ │ │ │
102#endif // OPENSUBDIV3_OSD_D3D11_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ + │ │ │ │ + │ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │
void UpdateVertexBuffer(ID3D11Buffer *vbo, int numVertices, int numVertexElements, ID3D11DeviceContext *pd3d11DeviceContext)
│ │ │ │ │ │ │ │ │ │ │ │
static D3D11LegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, ID3D11DeviceContext *deviceContext)
│ │ │ │ │ │ │ │
static D3D11LegacyGregoryPatchTable * Create(Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00842.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/d3d11ComputeEvaluator.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/cpuD3D11VertexBuffer.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,45 +90,41 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
d3d11ComputeEvaluator.h File Reference
│ │ │ │ +
cpuD3D11VertexBuffer.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include <cstddef>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  D3D11LegacyGregoryPatchTable
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  D3D11StencilTable
 D3D11 stencil table. More...
 
class  D3D11ComputeEvaluator
class  CpuD3D11VertexBuffer
 Concrete vertex buffer class for Cpu subdivision and DirectX drawing. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,28 +1,25 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -d3d11ComputeEvaluator.h File Reference │ │ │ │ │ +cpuD3D11VertexBuffer.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -  D3D11 stencil table. _M_o_r_e_._._. │ │ │ │ │ -  │ │ │ │ │ -class   _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +class   _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +  Concrete vertex buffer class for Cpu subdivision and DirectX drawing. │ │ │ │ │ + _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ -namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │ -  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00842.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,3 @@ │ │ │ │ │ var a00842 = [ │ │ │ │ │ - ["D3D11StencilTable", "a01197.html", "a01197"], │ │ │ │ │ - ["D3D11ComputeEvaluator", "a01201.html", "a01201"] │ │ │ │ │ + ["CpuD3D11VertexBuffer", "a01161.html", "a01161"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00842_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/d3d11ComputeEvaluator.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/cpuD3D11VertexBuffer.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
d3d11ComputeEvaluator.h
│ │ │ │ +
cpuD3D11VertexBuffer.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2015 Pixar
│ │ │ │ +
2// Copyright 2013 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -119,225 +119,91 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29
│ │ │ │ -
30struct ID3D11DeviceContext;
│ │ │ │ +
29#include <cstddef>
│ │ │ │ +
30
│ │ │ │
31struct ID3D11Buffer;
│ │ │ │ -
32struct ID3D11ComputeShader;
│ │ │ │ -
33struct ID3D11ClassLinkage;
│ │ │ │ -
34struct ID3D11ClassInstance;
│ │ │ │ -
35struct ID3D11ShaderResourceView;
│ │ │ │ -
36struct ID3D11UnorderedAccessView;
│ │ │ │ +
32struct ID3D11Device;
│ │ │ │ +
33struct ID3D11DeviceContext;
│ │ │ │ +
34
│ │ │ │ +
35namespace OpenSubdiv {
│ │ │ │ +
36namespace OPENSUBDIV_VERSION {
│ │ │ │
37
│ │ │ │ -
38#include "../osd/bufferDescriptor.h"
│ │ │ │ +
38namespace Osd {
│ │ │ │
39
│ │ │ │ -
40namespace OpenSubdiv {
│ │ │ │ -
41namespace OPENSUBDIV_VERSION {
│ │ │ │ -
42
│ │ │ │ -
43namespace Far {
│ │ │ │ -
44 class StencilTable;
│ │ │ │ -
45}
│ │ │ │ -
46
│ │ │ │ -
47namespace Osd {
│ │ │ │ -
48
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
57public:
│ │ │ │ -
58 template <typename DEVICE_CONTEXT>
│ │ │ │ -
│ │ │ │ -
59 static D3D11StencilTable *Create(Far::StencilTable const *stencilTable,
│ │ │ │ -
60 DEVICE_CONTEXT context) {
│ │ │ │ -
61 return new D3D11StencilTable(stencilTable, context->GetDeviceContext());
│ │ │ │ -
62 }
│ │ │ │ -
│ │ │ │ -
63
│ │ │ │ -
│ │ │ │ -
64 static D3D11StencilTable *Create(Far::StencilTable const *stencilTable,
│ │ │ │ -
65 ID3D11DeviceContext *deviceContext) {
│ │ │ │ -
66 return new D3D11StencilTable(stencilTable, deviceContext);
│ │ │ │ -
67 }
│ │ │ │ -
│ │ │ │ -
68
│ │ │ │ - │ │ │ │ -
70 ID3D11DeviceContext *deviceContext);
│ │ │ │ -
71
│ │ │ │ - │ │ │ │ +
│ │ │ │ + │ │ │ │ +
49public:
│ │ │ │ +
51 static CpuD3D11VertexBuffer * Create(int numElements, int numVertices,
│ │ │ │ +
52 ID3D11DeviceContext *deviceContext);
│ │ │ │ +
53
│ │ │ │ + │ │ │ │ +
56
│ │ │ │ +
59 void UpdateData(const float *src, int startVertex, int numVertices,
│ │ │ │ +
60 void *deviceContext = NULL);
│ │ │ │ +
61
│ │ │ │ +
63 int GetNumElements() const;
│ │ │ │ +
64
│ │ │ │ +
66 int GetNumVertices() const;
│ │ │ │ +
67
│ │ │ │ +
69 float * BindCpuBuffer();
│ │ │ │ +
70
│ │ │ │ +
72 ID3D11Buffer *BindD3D11Buffer(ID3D11DeviceContext *deviceContext);
│ │ │ │
73
│ │ │ │ -
74 // interfaces needed for D3D11ComputeEvaluator
│ │ │ │ -
75 ID3D11ShaderResourceView *GetSizesSRV() const { return _sizes; }
│ │ │ │ -
76 ID3D11ShaderResourceView *GetOffsetsSRV() const { return _offsets; }
│ │ │ │ -
77 ID3D11ShaderResourceView *GetIndicesSRV() const { return _indices; }
│ │ │ │ -
78 ID3D11ShaderResourceView *GetWeightsSRV() const { return _weights; }
│ │ │ │ -
79 int GetNumStencils() const { return _numStencils; }
│ │ │ │ -
80
│ │ │ │ -
81private:
│ │ │ │ -
82 ID3D11ShaderResourceView *_sizes;
│ │ │ │ -
83 ID3D11ShaderResourceView *_offsets;
│ │ │ │ -
84 ID3D11ShaderResourceView *_indices;
│ │ │ │ -
85 ID3D11ShaderResourceView *_weights;
│ │ │ │ -
86 ID3D11Buffer *_sizesBuffer;
│ │ │ │ -
87 ID3D11Buffer *_offsetsBuffer;
│ │ │ │ -
88 ID3D11Buffer *_indicesBuffer;
│ │ │ │ -
89 ID3D11Buffer *_weightsBuffer;
│ │ │ │ -
90
│ │ │ │ -
91 int _numStencils;
│ │ │ │ -
92};
│ │ │ │ +
│ │ │ │ +
75 ID3D11Buffer *BindVBO(ID3D11DeviceContext *deviceContext) {
│ │ │ │ +
76 return BindD3D11Buffer(deviceContext);
│ │ │ │ +
77 }
│ │ │ │ +
│ │ │ │ +
78
│ │ │ │ +
79protected:
│ │ │ │ +
81 CpuD3D11VertexBuffer(int numElements, int numVertices);
│ │ │ │ +
82
│ │ │ │ +
83 bool allocate(ID3D11Device *device);
│ │ │ │ +
84
│ │ │ │ +
85private:
│ │ │ │ +
86 int _numElements;
│ │ │ │ +
87 int _numVertices;
│ │ │ │ +
88 ID3D11Buffer *_d3d11Buffer;
│ │ │ │ +
89 float *_cpuBuffer;
│ │ │ │ +
90};
│ │ │ │
│ │ │ │ +
91
│ │ │ │ +
92} // end namespace Osd
│ │ │ │
93
│ │ │ │ -
94// ---------------------------------------------------------------------------
│ │ │ │ -
95
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
97public:
│ │ │ │ -
98 typedef bool Instantiatable;
│ │ │ │ - │ │ │ │ -
100 BufferDescriptor const &dstDesc,
│ │ │ │ -
101 BufferDescriptor const &duDesc,
│ │ │ │ -
102 BufferDescriptor const &dvDesc,
│ │ │ │ -
103 ID3D11DeviceContext *deviceContext);
│ │ │ │ -
104
│ │ │ │ - │ │ │ │ -
106 BufferDescriptor const &dstDesc,
│ │ │ │ -
107 BufferDescriptor const &duDesc,
│ │ │ │ -
108 BufferDescriptor const &dvDesc,
│ │ │ │ -
109 BufferDescriptor const &duuDesc,
│ │ │ │ -
110 BufferDescriptor const &duvDesc,
│ │ │ │ -
111 BufferDescriptor const &dvvDesc,
│ │ │ │ -
112 ID3D11DeviceContext *deviceContext);
│ │ │ │ -
113
│ │ │ │ - │ │ │ │ -
116
│ │ │ │ - │ │ │ │ -
119
│ │ │ │ -
147 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
148 static bool EvalStencils(
│ │ │ │ -
149 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
150 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
151 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
152 D3D11ComputeEvaluator const *instance,
│ │ │ │ -
153 ID3D11DeviceContext * deviceContext) {
│ │ │ │ -
154 if (instance) {
│ │ │ │ -
155 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
156 dstBuffer, dstDesc,
│ │ │ │ -
157 stencilTable,
│ │ │ │ -
158 deviceContext);
│ │ │ │ -
159 } else {
│ │ │ │ -
160 // Create an instance on demand (slow)
│ │ │ │ -
161 (void)deviceContext; // unused
│ │ │ │ -
162 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
165 deviceContext);
│ │ │ │ -
166 if (instance) {
│ │ │ │ -
167 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
168 dstBuffer, dstDesc,
│ │ │ │ -
169 stencilTable,
│ │ │ │ -
170 deviceContext);
│ │ │ │ -
171 delete instance;
│ │ │ │ -
172 return r;
│ │ │ │ -
173 }
│ │ │ │ -
174 return false;
│ │ │ │ -
175 }
│ │ │ │ -
176 }
│ │ │ │ -
│ │ │ │ -
177
│ │ │ │ -
180 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
182 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
183 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
184 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
185 ID3D11DeviceContext *deviceContext) const {
│ │ │ │ -
186 return EvalStencils(srcBuffer->BindD3D11UAV(deviceContext), srcDesc,
│ │ │ │ -
187 dstBuffer->BindD3D11UAV(deviceContext), dstDesc,
│ │ │ │ -
188 stencilTable->GetSizesSRV(),
│ │ │ │ -
189 stencilTable->GetOffsetsSRV(),
│ │ │ │ -
190 stencilTable->GetIndicesSRV(),
│ │ │ │ -
191 stencilTable->GetWeightsSRV(),
│ │ │ │ -
192 /* start = */ 0,
│ │ │ │ -
193 /* end = */ stencilTable->GetNumStencils(),
│ │ │ │ -
194 deviceContext);
│ │ │ │ -
195 }
│ │ │ │ -
│ │ │ │ -
196
│ │ │ │ -
199 bool EvalStencils(ID3D11UnorderedAccessView *srcSRV,
│ │ │ │ -
200 BufferDescriptor const &srcDesc,
│ │ │ │ -
201 ID3D11UnorderedAccessView *dstUAV,
│ │ │ │ -
202 BufferDescriptor const &dstDesc,
│ │ │ │ -
203 ID3D11ShaderResourceView *sizesSRV,
│ │ │ │ -
204 ID3D11ShaderResourceView *offsetsSRV,
│ │ │ │ -
205 ID3D11ShaderResourceView *indicesSRV,
│ │ │ │ -
206 ID3D11ShaderResourceView *weightsSRV,
│ │ │ │ -
207 int start,
│ │ │ │ -
208 int end,
│ │ │ │ -
209 ID3D11DeviceContext *deviceContext) const;
│ │ │ │ -
210
│ │ │ │ -
212 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ -
213 BufferDescriptor const &dstDesc,
│ │ │ │ -
214 ID3D11DeviceContext *deviceContext);
│ │ │ │ -
215
│ │ │ │ -
217 static void Synchronize(ID3D11DeviceContext *deviceContext);
│ │ │ │ -
218
│ │ │ │ -
219private:
│ │ │ │ -
220 ID3D11ComputeShader * _computeShader;
│ │ │ │ -
221 ID3D11ClassLinkage * _classLinkage;
│ │ │ │ -
222 ID3D11ClassInstance * _singleBufferKernel;
│ │ │ │ -
223 ID3D11ClassInstance * _separateBufferKernel;
│ │ │ │ -
224 ID3D11Buffer * _uniformArgs; // uniform parameters for kernels
│ │ │ │ -
225
│ │ │ │ -
226 int _workGroupSize;
│ │ │ │ -
227};
│ │ │ │ -
│ │ │ │ -
228
│ │ │ │ -
229} // end namespace Osd
│ │ │ │ -
230
│ │ │ │ -
231} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
232using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
233
│ │ │ │ -
234} // end namespace OpenSubdiv
│ │ │ │ -
235
│ │ │ │ -
236
│ │ │ │ -
237#endif // OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H
│ │ │ │ +
94} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
95using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
96
│ │ │ │ +
97} // end namespace OpenSubdiv
│ │ │ │ +
98
│ │ │ │ +
99#endif // OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H
│ │ │ │ │ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ -
static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, DEVICE_CONTEXT context)
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
D3D11StencilTable(Far::StencilTable const *stencilTable, ID3D11DeviceContext *deviceContext)
│ │ │ │ -
static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, ID3D11DeviceContext *deviceContext)
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, ID3D11DeviceContext *deviceContext)
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, D3D11ComputeEvaluator const *instance, ID3D11DeviceContext *deviceContext)
Generic static compute function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, ID3D11DeviceContext *deviceContext)
│ │ │ │ - │ │ │ │ -
static void Synchronize(ID3D11DeviceContext *deviceContext)
Wait the dispatched kernel finishes.
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, ID3D11DeviceContext *deviceContext) const
│ │ │ │ -
bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, ID3D11DeviceContext *deviceContext)
Configure DX kernel. Returns false if it fails to compile the kernel.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
bool EvalStencils(ID3D11UnorderedAccessView *srcSRV, BufferDescriptor const &srcDesc, ID3D11UnorderedAccessView *dstUAV, BufferDescriptor const &dstDesc, ID3D11ShaderResourceView *sizesSRV, ID3D11ShaderResourceView *offsetsSRV, ID3D11ShaderResourceView *indicesSRV, ID3D11ShaderResourceView *weightsSRV, int start, int end, ID3D11DeviceContext *deviceContext) const
│ │ │ │ +
Concrete vertex buffer class for Cpu subdivision and DirectX drawing.
│ │ │ │ +
static CpuD3D11VertexBuffer * Create(int numElements, int numVertices, ID3D11DeviceContext *deviceContext)
Creator. Returns NULL if error.
│ │ │ │ +
CpuD3D11VertexBuffer(int numElements, int numVertices)
Constructor.
│ │ │ │ +
int GetNumElements() const
Returns how many elements defined in this vertex buffer.
│ │ │ │ +
void UpdateData(const float *src, int startVertex, int numVertices, void *deviceContext=NULL)
│ │ │ │ +
int GetNumVertices() const
Returns how many vertices allocated in this vertex buffer.
│ │ │ │ +
ID3D11Buffer * BindD3D11Buffer(ID3D11DeviceContext *deviceContext)
Returns the D3D11 buffer object.
│ │ │ │ +
float * BindCpuBuffer()
Returns the address of CPU buffer.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
ID3D11Buffer * BindVBO(ID3D11DeviceContext *deviceContext)
Returns the D3D11 buffer object (for Osd::Mesh interface)
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -d3d11ComputeEvaluator.h │ │ │ │ │ +cpuD3D11VertexBuffer.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2015 Pixar │ │ │ │ │ +2// Copyright 2013 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -24,272 +24,105 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29 │ │ │ │ │ -30struct ID3D11DeviceContext; │ │ │ │ │ +29#include │ │ │ │ │ +30 │ │ │ │ │ 31struct ID3D11Buffer; │ │ │ │ │ -32struct ID3D11ComputeShader; │ │ │ │ │ -33struct ID3D11ClassLinkage; │ │ │ │ │ -34struct ID3D11ClassInstance; │ │ │ │ │ -35struct ID3D11ShaderResourceView; │ │ │ │ │ -36struct ID3D11UnorderedAccessView; │ │ │ │ │ +32struct ID3D11Device; │ │ │ │ │ +33struct ID3D11DeviceContext; │ │ │ │ │ +34 │ │ │ │ │ +35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +36namespace OPENSUBDIV_VERSION { │ │ │ │ │ 37 │ │ │ │ │ -38#include "../osd/bufferDescriptor.h" │ │ │ │ │ +38namespace Osd { │ │ │ │ │ 39 │ │ │ │ │ -40namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -41namespace OPENSUBDIV_VERSION { │ │ │ │ │ -42 │ │ │ │ │ -43namespace Far { │ │ │ │ │ -44 class StencilTable; │ │ │ │ │ -45} │ │ │ │ │ -46 │ │ │ │ │ -47namespace Osd { │ │ │ │ │ -48 │ │ │ │ │ -_5_6class _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e { │ │ │ │ │ -57public: │ │ │ │ │ -58 template │ │ │ │ │ -_5_9 static _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ -60 DEVICE_CONTEXT context) { │ │ │ │ │ -61 return new _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(stencilTable, context->GetDeviceContext()); │ │ │ │ │ -62 } │ │ │ │ │ -63 │ │ │ │ │ -_6_4 static _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ -65 ID3D11DeviceContext *deviceContext) { │ │ │ │ │ -66 return new _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(stencilTable, deviceContext); │ │ │ │ │ -67 } │ │ │ │ │ -68 │ │ │ │ │ -_6_9 _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ -70 ID3D11DeviceContext *deviceContext); │ │ │ │ │ -71 │ │ │ │ │ -_7_2 _~_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(); │ │ │ │ │ +_4_8class _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r { │ │ │ │ │ +49public: │ │ │ │ │ +_5_1 static _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r * _C_r_e_a_t_e(int numElements, int numVertices, │ │ │ │ │ +52 ID3D11DeviceContext *deviceContext); │ │ │ │ │ +53 │ │ │ │ │ +_5_5 virtual _~_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r(); │ │ │ │ │ +56 │ │ │ │ │ +_5_9 void _U_p_d_a_t_e_D_a_t_a(const float *src, int startVertex, int numVertices, │ │ │ │ │ +60 void *deviceContext = NULL); │ │ │ │ │ +61 │ │ │ │ │ +_6_3 int _G_e_t_N_u_m_E_l_e_m_e_n_t_s() const; │ │ │ │ │ +64 │ │ │ │ │ +_6_6 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s() const; │ │ │ │ │ +67 │ │ │ │ │ +_6_9 float * _B_i_n_d_C_p_u_B_u_f_f_e_r(); │ │ │ │ │ +70 │ │ │ │ │ +_7_2 ID3D11Buffer *_B_i_n_d_D_3_D_1_1_B_u_f_f_e_r(ID3D11DeviceContext *deviceContext); │ │ │ │ │ 73 │ │ │ │ │ -74 // interfaces needed for D3D11ComputeEvaluator │ │ │ │ │ -_7_5 ID3D11ShaderResourceView *_G_e_t_S_i_z_e_s_S_R_V() const { return _sizes; } │ │ │ │ │ -_7_6 ID3D11ShaderResourceView *_G_e_t_O_f_f_s_e_t_s_S_R_V() const { return _offsets; } │ │ │ │ │ -_7_7 ID3D11ShaderResourceView *_G_e_t_I_n_d_i_c_e_s_S_R_V() const { return _indices; } │ │ │ │ │ -_7_8 ID3D11ShaderResourceView *_G_e_t_W_e_i_g_h_t_s_S_R_V() const { return _weights; } │ │ │ │ │ -_7_9 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { return _numStencils; } │ │ │ │ │ -80 │ │ │ │ │ -81private: │ │ │ │ │ -82 ID3D11ShaderResourceView *_sizes; │ │ │ │ │ -83 ID3D11ShaderResourceView *_offsets; │ │ │ │ │ -84 ID3D11ShaderResourceView *_indices; │ │ │ │ │ -85 ID3D11ShaderResourceView *_weights; │ │ │ │ │ -86 ID3D11Buffer *_sizesBuffer; │ │ │ │ │ -87 ID3D11Buffer *_offsetsBuffer; │ │ │ │ │ -88 ID3D11Buffer *_indicesBuffer; │ │ │ │ │ -89 ID3D11Buffer *_weightsBuffer; │ │ │ │ │ -90 │ │ │ │ │ -91 int _numStencils; │ │ │ │ │ -92}; │ │ │ │ │ +_7_5 ID3D11Buffer *_B_i_n_d_V_B_O(ID3D11DeviceContext *deviceContext) { │ │ │ │ │ +76 return _B_i_n_d_D_3_D_1_1_B_u_f_f_e_r(deviceContext); │ │ │ │ │ +77 } │ │ │ │ │ +78 │ │ │ │ │ +79protected: │ │ │ │ │ +_8_1 _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r(int numElements, int numVertices); │ │ │ │ │ +82 │ │ │ │ │ +_8_3 bool _a_l_l_o_c_a_t_e(ID3D11Device *device); │ │ │ │ │ +84 │ │ │ │ │ +85private: │ │ │ │ │ +86 int _numElements; │ │ │ │ │ +87 int _numVertices; │ │ │ │ │ +88 ID3D11Buffer *_d3d11Buffer; │ │ │ │ │ +89 float *_cpuBuffer; │ │ │ │ │ +90}; │ │ │ │ │ +91 │ │ │ │ │ +92} // end namespace Osd │ │ │ │ │ 93 │ │ │ │ │ -94// -------------------------------------------------------------------------- │ │ │ │ │ -- │ │ │ │ │ -95 │ │ │ │ │ -_9_6class _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r { │ │ │ │ │ -97public: │ │ │ │ │ -_9_8 typedef bool _I_n_s_t_a_n_t_i_a_t_a_b_l_e; │ │ │ │ │ -_9_9 static _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -100 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -101 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -102 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -103 ID3D11DeviceContext *deviceContext); │ │ │ │ │ -104 │ │ │ │ │ -_1_0_5 static _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -106 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -107 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -108 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -109 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -110 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -111 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -112 ID3D11DeviceContext *deviceContext); │ │ │ │ │ -113 │ │ │ │ │ -_1_1_5 _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ -116 │ │ │ │ │ -_1_1_8 _~_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ -119 │ │ │ │ │ -147 template │ │ │ │ │ -_1_4_8 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -149 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -150 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -151 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -152 _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -153 ID3D11DeviceContext * deviceContext) { │ │ │ │ │ -154 if (instance) { │ │ │ │ │ -155 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -156 dstBuffer, dstDesc, │ │ │ │ │ -157 stencilTable, │ │ │ │ │ -158 deviceContext); │ │ │ │ │ -159 } else { │ │ │ │ │ -160 // Create an instance on demand (slow) │ │ │ │ │ -161 (void)deviceContext; // unused │ │ │ │ │ -162 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -163 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -164 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -165 deviceContext); │ │ │ │ │ -166 if (instance) { │ │ │ │ │ -167 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -168 dstBuffer, dstDesc, │ │ │ │ │ -169 stencilTable, │ │ │ │ │ -170 deviceContext); │ │ │ │ │ -171 delete instance; │ │ │ │ │ -172 return r; │ │ │ │ │ -173 } │ │ │ │ │ -174 return false; │ │ │ │ │ -175 } │ │ │ │ │ -176 } │ │ │ │ │ -177 │ │ │ │ │ -180 template │ │ │ │ │ -_1_8_1 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -182 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -183 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -184 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -185 ID3D11DeviceContext *deviceContext) const { │ │ │ │ │ -186 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindD3D11UAV(deviceContext), srcDesc, │ │ │ │ │ -187 dstBuffer->BindD3D11UAV(deviceContext), dstDesc, │ │ │ │ │ -188 stencilTable->GetSizesSRV(), │ │ │ │ │ -189 stencilTable->GetOffsetsSRV(), │ │ │ │ │ -190 stencilTable->GetIndicesSRV(), │ │ │ │ │ -191 stencilTable->GetWeightsSRV(), │ │ │ │ │ -192 /* start = */ 0, │ │ │ │ │ -193 /* end = */ stencilTable->GetNumStencils(), │ │ │ │ │ -194 deviceContext); │ │ │ │ │ -195 } │ │ │ │ │ -196 │ │ │ │ │ -_1_9_9 bool _E_v_a_l_S_t_e_n_c_i_l_s(ID3D11UnorderedAccessView *srcSRV, │ │ │ │ │ -200 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -201 ID3D11UnorderedAccessView *dstUAV, │ │ │ │ │ -202 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -203 ID3D11ShaderResourceView *sizesSRV, │ │ │ │ │ -204 ID3D11ShaderResourceView *offsetsSRV, │ │ │ │ │ -205 ID3D11ShaderResourceView *indicesSRV, │ │ │ │ │ -206 ID3D11ShaderResourceView *weightsSRV, │ │ │ │ │ -207 int start, │ │ │ │ │ -208 int end, │ │ │ │ │ -209 ID3D11DeviceContext *deviceContext) const; │ │ │ │ │ -210 │ │ │ │ │ -_2_1_2 bool _C_o_m_p_i_l_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -213 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -214 ID3D11DeviceContext *deviceContext); │ │ │ │ │ -215 │ │ │ │ │ -_2_1_7 static void _S_y_n_c_h_r_o_n_i_z_e(ID3D11DeviceContext *deviceContext); │ │ │ │ │ -218 │ │ │ │ │ -219private: │ │ │ │ │ -220 ID3D11ComputeShader * _computeShader; │ │ │ │ │ -221 ID3D11ClassLinkage * _classLinkage; │ │ │ │ │ -222 ID3D11ClassInstance * _singleBufferKernel; │ │ │ │ │ -223 ID3D11ClassInstance * _separateBufferKernel; │ │ │ │ │ -224 ID3D11Buffer * _uniformArgs; // uniform parameters for kernels │ │ │ │ │ -225 │ │ │ │ │ -226 int _workGroupSize; │ │ │ │ │ -227}; │ │ │ │ │ -228 │ │ │ │ │ -229} // end namespace Osd │ │ │ │ │ -230 │ │ │ │ │ -231} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -232using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -233 │ │ │ │ │ -234} // end namespace OpenSubdiv │ │ │ │ │ -235 │ │ │ │ │ -236 │ │ │ │ │ -237#endif // OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H │ │ │ │ │ +94} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +95using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +96 │ │ │ │ │ +97} // end namespace OpenSubdiv │ │ │ │ │ +98 │ │ │ │ │ +99#endif // OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ -data buffers.... │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -D3D11 stencil table. │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, │ │ │ │ │ -DEVICE_CONTEXT context) │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_O_f_f_s_e_t_s_S_R_V │ │ │ │ │ -ID3D11ShaderResourceView * GetOffsetsSRV() const │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ -int GetNumStencils() const │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_I_n_d_i_c_e_s_S_R_V │ │ │ │ │ -ID3D11ShaderResourceView * GetIndicesSRV() const │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_~_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -~D3D11StencilTable() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -D3D11StencilTable(Far::StencilTable const *stencilTable, ID3D11DeviceContext │ │ │ │ │ -*deviceContext) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ -static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +Concrete vertex buffer class for Cpu subdivision and DirectX drawing. │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static CpuD3D11VertexBuffer * Create(int numElements, int numVertices, │ │ │ │ │ ID3D11DeviceContext *deviceContext) │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_6_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_S_i_z_e_s_S_R_V │ │ │ │ │ -ID3D11ShaderResourceView * GetSizesSRV() const │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_W_e_i_g_h_t_s_S_R_V │ │ │ │ │ -ID3D11ShaderResourceView * GetWeightsSRV() const │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ -BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ -BufferDescriptor const &dvDesc, ID3D11DeviceContext *deviceContext) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ -const *stencilTable, D3D11ComputeEvaluator const *instance, ID3D11DeviceContext │ │ │ │ │ -*deviceContext) │ │ │ │ │ -Generic static compute function. This function has a same signature as other │ │ │ │ │ -device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ -BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ -BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, │ │ │ │ │ -BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, │ │ │ │ │ -ID3D11DeviceContext *deviceContext) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_I_n_s_t_a_n_t_i_a_t_a_b_l_e │ │ │ │ │ -bool Instantiatable │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ -static void Synchronize(ID3D11DeviceContext *deviceContext) │ │ │ │ │ -Wait the dispatched kernel finishes. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const │ │ │ │ │ -*stencilTable, ID3D11DeviceContext *deviceContext) const │ │ │ │ │ -DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_o_m_p_i_l_e │ │ │ │ │ -bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, │ │ │ │ │ -ID3D11DeviceContext *deviceContext) │ │ │ │ │ -Configure DX kernel. Returns false if it fails to compile the kernel. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_: │ │ │ │ │ -_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ -D3D11ComputeEvaluator() │ │ │ │ │ +Creator. Returns NULL if error. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +CpuD3D11VertexBuffer(int numElements, int numVertices) │ │ │ │ │ Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_: │ │ │ │ │ -_~_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ -~D3D11ComputeEvaluator() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_E_l_e_m_e_n_t_s │ │ │ │ │ +int GetNumElements() const │ │ │ │ │ +Returns how many elements defined in this vertex buffer. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_U_p_d_a_t_e_D_a_t_a │ │ │ │ │ +void UpdateData(const float *src, int startVertex, int numVertices, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ +int GetNumVertices() const │ │ │ │ │ +Returns how many vertices allocated in this vertex buffer. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_D_3_D_1_1_B_u_f_f_e_r │ │ │ │ │ +ID3D11Buffer * BindD3D11Buffer(ID3D11DeviceContext *deviceContext) │ │ │ │ │ +Returns the D3D11 buffer object. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_C_p_u_B_u_f_f_e_r │ │ │ │ │ +float * BindCpuBuffer() │ │ │ │ │ +Returns the address of CPU buffer. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_a_l_l_o_c_a_t_e │ │ │ │ │ +bool allocate(ID3D11Device *device) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_: │ │ │ │ │ +_~_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ +virtual ~CpuD3D11VertexBuffer() │ │ │ │ │ Destructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(ID3D11UnorderedAccessView *srcSRV, BufferDescriptor const │ │ │ │ │ -&srcDesc, ID3D11UnorderedAccessView *dstUAV, BufferDescriptor const &dstDesc, │ │ │ │ │ -ID3D11ShaderResourceView *sizesSRV, ID3D11ShaderResourceView *offsetsSRV, │ │ │ │ │ -ID3D11ShaderResourceView *indicesSRV, ID3D11ShaderResourceView *weightsSRV, int │ │ │ │ │ -start, int end, ID3D11DeviceContext *deviceContext) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_V_B_O │ │ │ │ │ +ID3D11Buffer * BindVBO(ID3D11DeviceContext *deviceContext) │ │ │ │ │ +Returns the D3D11 buffer object (for Osd::Mesh interface) │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_7_5 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00845.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/cpuD3D11VertexBuffer.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/glComputeEvaluator.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,41 +90,47 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
cpuD3D11VertexBuffer.h File Reference
│ │ │ │ +
glComputeEvaluator.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include <cstddef>
│ │ │ │ +#include "../osd/opengl.h"
│ │ │ │ +#include "../osd/types.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  CpuD3D11VertexBuffer
 Concrete vertex buffer class for Cpu subdivision and DirectX drawing. More...
class  GLStencilTableSSBO
 GL stencil table (Shader Storage buffer) More...
 
class  GLComputeEvaluator
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Osd
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,25 +1,30 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -cpuD3D11VertexBuffer.h File Reference │ │ │ │ │ +glComputeEvaluator.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_o_s_d_/_o_p_e_n_g_l_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -  Concrete vertex buffer class for Cpu subdivision and DirectX drawing. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ +class   _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ +  GL stencil table (Shader Storage buffer) _M_o_r_e_._._. │ │ │ │ │ +  │ │ │ │ │ +class   _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ +namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │ +  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ + * _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00845.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,4 @@ │ │ │ │ │ var a00845 = [ │ │ │ │ │ - ["CpuD3D11VertexBuffer", "a01161.html", "a01161"] │ │ │ │ │ + ["GLStencilTableSSBO", "a01217.html", "a01217"], │ │ │ │ │ + ["GLComputeEvaluator", "a01221.html", "a01221"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00845_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/cpuD3D11VertexBuffer.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/glComputeEvaluator.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,19 +92,19 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
cpuD3D11VertexBuffer.h
│ │ │ │ +
glComputeEvaluator.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │ -
2// Copyright 2013 Pixar
│ │ │ │ +
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │
6// compliance with the Apache License and the following modification to it:
│ │ │ │
7// Section 6. Trademarks. is deleted and replaced with:
│ │ │ │
8//
│ │ │ │
9// 6. Trademarks. This License does not grant permission to use the trade
│ │ │ │ @@ -119,91 +119,1132 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29#include <cstddef>
│ │ │ │ -
30
│ │ │ │ -
31struct ID3D11Buffer;
│ │ │ │ -
32struct ID3D11Device;
│ │ │ │ -
33struct ID3D11DeviceContext;
│ │ │ │ -
34
│ │ │ │ -
35namespace OpenSubdiv {
│ │ │ │ -
36namespace OPENSUBDIV_VERSION {
│ │ │ │ -
37
│ │ │ │ -
38namespace Osd {
│ │ │ │ -
39
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
49public:
│ │ │ │ -
51 static CpuD3D11VertexBuffer * Create(int numElements, int numVertices,
│ │ │ │ -
52 ID3D11DeviceContext *deviceContext);
│ │ │ │ -
53
│ │ │ │ - │ │ │ │ -
56
│ │ │ │ -
59 void UpdateData(const float *src, int startVertex, int numVertices,
│ │ │ │ -
60 void *deviceContext = NULL);
│ │ │ │ -
61
│ │ │ │ -
63 int GetNumElements() const;
│ │ │ │ +
29
│ │ │ │ +
30#include "../osd/opengl.h"
│ │ │ │ +
31#include "../osd/types.h"
│ │ │ │ +
32#include "../osd/bufferDescriptor.h"
│ │ │ │ +
33
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Far {
│ │ │ │ +
38 class PatchTable;
│ │ │ │ +
39 class StencilTable;
│ │ │ │ +
40 class LimitStencilTable;
│ │ │ │ +
41}
│ │ │ │ +
42
│ │ │ │ +
43namespace Osd {
│ │ │ │ +
44
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
52public:
│ │ │ │ +
│ │ │ │ +
53 static GLStencilTableSSBO *Create(Far::StencilTable const *stencilTable,
│ │ │ │ +
54 void *deviceContext = NULL) {
│ │ │ │ +
55 (void)deviceContext; // unused
│ │ │ │ +
56 return new GLStencilTableSSBO(stencilTable);
│ │ │ │ +
57 }
│ │ │ │ +
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
59 Far::LimitStencilTable const *limitStencilTable,
│ │ │ │ +
60 void *deviceContext = NULL) {
│ │ │ │ +
61 (void)deviceContext; // unused
│ │ │ │ +
62 return new GLStencilTableSSBO(limitStencilTable);
│ │ │ │ +
63 }
│ │ │ │ +
│ │ │ │
64
│ │ │ │ -
66 int GetNumVertices() const;
│ │ │ │ -
67
│ │ │ │ -
69 float * BindCpuBuffer();
│ │ │ │ -
70
│ │ │ │ -
72 ID3D11Buffer *BindD3D11Buffer(ID3D11DeviceContext *deviceContext);
│ │ │ │ -
73
│ │ │ │ -
│ │ │ │ -
75 ID3D11Buffer *BindVBO(ID3D11DeviceContext *deviceContext) {
│ │ │ │ -
76 return BindD3D11Buffer(deviceContext);
│ │ │ │ -
77 }
│ │ │ │ -
│ │ │ │ -
78
│ │ │ │ -
79protected:
│ │ │ │ -
81 CpuD3D11VertexBuffer(int numElements, int numVertices);
│ │ │ │ -
82
│ │ │ │ -
83 bool allocate(ID3D11Device *device);
│ │ │ │ -
84
│ │ │ │ -
85private:
│ │ │ │ -
86 int _numElements;
│ │ │ │ -
87 int _numVertices;
│ │ │ │ -
88 ID3D11Buffer *_d3d11Buffer;
│ │ │ │ -
89 float *_cpuBuffer;
│ │ │ │ -
90};
│ │ │ │ +
65 explicit GLStencilTableSSBO(Far::StencilTable const *stencilTable);
│ │ │ │ +
66 explicit GLStencilTableSSBO(Far::LimitStencilTable const *limitStencilTable);
│ │ │ │ + │ │ │ │ +
68
│ │ │ │ +
69 // interfaces needed for GLSLComputeKernel
│ │ │ │ +
70 GLuint GetSizesBuffer() const { return _sizes; }
│ │ │ │ +
71 GLuint GetOffsetsBuffer() const { return _offsets; }
│ │ │ │ +
72 GLuint GetIndicesBuffer() const { return _indices; }
│ │ │ │ +
73 GLuint GetWeightsBuffer() const { return _weights; }
│ │ │ │ +
74 GLuint GetDuWeightsBuffer() const { return _duWeights; }
│ │ │ │ +
75 GLuint GetDvWeightsBuffer() const { return _dvWeights; }
│ │ │ │ +
76 GLuint GetDuuWeightsBuffer() const { return _duuWeights; }
│ │ │ │ +
77 GLuint GetDuvWeightsBuffer() const { return _duvWeights; }
│ │ │ │ +
78 GLuint GetDvvWeightsBuffer() const { return _dvvWeights; }
│ │ │ │ +
79 int GetNumStencils() const { return _numStencils; }
│ │ │ │ +
80
│ │ │ │ +
81private:
│ │ │ │ +
82 GLuint _sizes;
│ │ │ │ +
83 GLuint _offsets;
│ │ │ │ +
84 GLuint _indices;
│ │ │ │ +
85 GLuint _weights;
│ │ │ │ +
86 GLuint _duWeights;
│ │ │ │ +
87 GLuint _dvWeights;
│ │ │ │ +
88 GLuint _duuWeights;
│ │ │ │ +
89 GLuint _duvWeights;
│ │ │ │ +
90 GLuint _dvvWeights;
│ │ │ │ +
91 int _numStencils;
│ │ │ │ +
92};
│ │ │ │
│ │ │ │ -
91
│ │ │ │ -
92} // end namespace Osd
│ │ │ │
93
│ │ │ │ -
94} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
95using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
96
│ │ │ │ -
97} // end namespace OpenSubdiv
│ │ │ │ -
98
│ │ │ │ -
99#endif // OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H
│ │ │ │ +
94// ---------------------------------------------------------------------------
│ │ │ │ +
95
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
97public:
│ │ │ │ +
98 typedef bool Instantiatable;
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
100 BufferDescriptor const &dstDesc,
│ │ │ │ +
101 BufferDescriptor const &duDesc,
│ │ │ │ +
102 BufferDescriptor const &dvDesc,
│ │ │ │ +
103 void * deviceContext = NULL) {
│ │ │ │ +
104 return Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
108 deviceContext);
│ │ │ │ +
109 }
│ │ │ │ +
│ │ │ │ +
110
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
112 BufferDescriptor const &dstDesc,
│ │ │ │ +
113 BufferDescriptor const &duDesc,
│ │ │ │ +
114 BufferDescriptor const &dvDesc,
│ │ │ │ +
115 BufferDescriptor const &duuDesc,
│ │ │ │ +
116 BufferDescriptor const &duvDesc,
│ │ │ │ +
117 BufferDescriptor const &dvvDesc,
│ │ │ │ +
118 void * deviceContext = NULL) {
│ │ │ │ +
119 (void)deviceContext; // not used
│ │ │ │ +
120 GLComputeEvaluator *instance = new GLComputeEvaluator();
│ │ │ │ +
121 if (instance->Compile(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ +
122 duuDesc, duvDesc, dvvDesc))
│ │ │ │ +
123 return instance;
│ │ │ │ +
124 delete instance;
│ │ │ │ +
125 return NULL;
│ │ │ │ +
126 }
│ │ │ │ +
│ │ │ │ +
127
│ │ │ │ + │ │ │ │ +
130
│ │ │ │ + │ │ │ │ +
133
│ │ │ │ +
139
│ │ │ │ +
167 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
168 static bool EvalStencils(
│ │ │ │ +
169 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
170 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
171 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
172 GLComputeEvaluator const *instance,
│ │ │ │ +
173 void * deviceContext = NULL) {
│ │ │ │ +
174
│ │ │ │ +
175 if (instance) {
│ │ │ │ +
176 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
177 dstBuffer, dstDesc,
│ │ │ │ +
178 stencilTable);
│ │ │ │ +
179 } else {
│ │ │ │ +
180 // Create an instance on demand (slow)
│ │ │ │ +
181 (void)deviceContext; // unused
│ │ │ │ +
182 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
185 if (instance) {
│ │ │ │ +
186 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
187 dstBuffer, dstDesc,
│ │ │ │ +
188 stencilTable);
│ │ │ │ +
189 delete instance;
│ │ │ │ +
190 return r;
│ │ │ │ +
191 }
│ │ │ │ +
192 return false;
│ │ │ │ +
193 }
│ │ │ │ +
194 }
│ │ │ │ +
│ │ │ │ +
195
│ │ │ │ +
235 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
236 static bool EvalStencils(
│ │ │ │ +
237 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
238 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
239 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
240 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
241 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
242 GLComputeEvaluator const *instance,
│ │ │ │ +
243 void * deviceContext = NULL) {
│ │ │ │ +
244
│ │ │ │ +
245 if (instance) {
│ │ │ │ +
246 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
247 dstBuffer, dstDesc,
│ │ │ │ +
248 duBuffer, duDesc,
│ │ │ │ +
249 dvBuffer, dvDesc,
│ │ │ │ +
250 stencilTable);
│ │ │ │ +
251 } else {
│ │ │ │ +
252 // Create an instance on demand (slow)
│ │ │ │ +
253 (void)deviceContext; // unused
│ │ │ │ +
254 instance = Create(srcDesc, dstDesc, duDesc, dvDesc);
│ │ │ │ +
255 if (instance) {
│ │ │ │ +
256 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
257 dstBuffer, dstDesc,
│ │ │ │ +
258 duBuffer, duDesc,
│ │ │ │ +
259 dvBuffer, dvDesc,
│ │ │ │ +
260 stencilTable);
│ │ │ │ +
261 delete instance;
│ │ │ │ +
262 return r;
│ │ │ │ +
263 }
│ │ │ │ +
264 return false;
│ │ │ │ +
265 }
│ │ │ │ +
266 }
│ │ │ │ +
│ │ │ │ +
267
│ │ │ │ +
325 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
326 static bool EvalStencils(
│ │ │ │ +
327 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
328 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
329 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
330 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
331 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
332 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
333 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
334 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
335 GLComputeEvaluator const *instance,
│ │ │ │ +
336 void * deviceContext = NULL) {
│ │ │ │ +
337
│ │ │ │ +
338 if (instance) {
│ │ │ │ +
339 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
340 dstBuffer, dstDesc,
│ │ │ │ +
341 duBuffer, duDesc,
│ │ │ │ +
342 dvBuffer, dvDesc,
│ │ │ │ +
343 duuBuffer, duuDesc,
│ │ │ │ +
344 duvBuffer, duvDesc,
│ │ │ │ +
345 dvvBuffer, dvvDesc,
│ │ │ │ +
346 stencilTable);
│ │ │ │ +
347 } else {
│ │ │ │ +
348 // Create an instance on demand (slow)
│ │ │ │ +
349 (void)deviceContext; // unused
│ │ │ │ +
350 instance = Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ +
351 duuDesc, duvDesc, dvvDesc);
│ │ │ │ +
352 if (instance) {
│ │ │ │ +
353 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
354 dstBuffer, dstDesc,
│ │ │ │ +
355 duBuffer, duDesc,
│ │ │ │ +
356 dvBuffer, dvDesc,
│ │ │ │ +
357 duuBuffer, duuDesc,
│ │ │ │ +
358 duvBuffer, duvDesc,
│ │ │ │ +
359 dvvBuffer, dvvDesc,
│ │ │ │ +
360 stencilTable);
│ │ │ │ +
361 delete instance;
│ │ │ │ +
362 return r;
│ │ │ │ +
363 }
│ │ │ │ +
364 return false;
│ │ │ │ +
365 }
│ │ │ │ +
366 }
│ │ │ │ +
│ │ │ │ +
367
│ │ │ │ +
385 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
387 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
388 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
389 STENCIL_TABLE const *stencilTable) const {
│ │ │ │ +
390 return EvalStencils(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
391 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
392 0, BufferDescriptor(),
│ │ │ │ +
393 0, BufferDescriptor(),
│ │ │ │ +
394 stencilTable->GetSizesBuffer(),
│ │ │ │ +
395 stencilTable->GetOffsetsBuffer(),
│ │ │ │ +
396 stencilTable->GetIndicesBuffer(),
│ │ │ │ +
397 stencilTable->GetWeightsBuffer(),
│ │ │ │ +
398 0,
│ │ │ │ +
399 0,
│ │ │ │ +
400 /* start = */ 0,
│ │ │ │ +
401 /* end = */ stencilTable->GetNumStencils());
│ │ │ │ +
402 }
│ │ │ │ +
│ │ │ │ +
403
│ │ │ │ +
433 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
435 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
436 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
437 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
438 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
439 STENCIL_TABLE const *stencilTable) const {
│ │ │ │ +
440 return EvalStencils(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
441 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
442 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
443 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
444 stencilTable->GetSizesBuffer(),
│ │ │ │ +
445 stencilTable->GetOffsetsBuffer(),
│ │ │ │ +
446 stencilTable->GetIndicesBuffer(),
│ │ │ │ +
447 stencilTable->GetWeightsBuffer(),
│ │ │ │ +
448 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ +
449 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ +
450 /* start = */ 0,
│ │ │ │ +
451 /* end = */ stencilTable->GetNumStencils());
│ │ │ │ +
452 }
│ │ │ │ +
│ │ │ │ +
453
│ │ │ │ +
501 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
503 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
504 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
505 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
506 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
507 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
508 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
509 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
510 STENCIL_TABLE const *stencilTable) const {
│ │ │ │ +
511 return EvalStencils(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
512 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
513 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
514 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
515 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ +
516 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ +
517 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ +
518 stencilTable->GetSizesBuffer(),
│ │ │ │ +
519 stencilTable->GetOffsetsBuffer(),
│ │ │ │ +
520 stencilTable->GetIndicesBuffer(),
│ │ │ │ +
521 stencilTable->GetWeightsBuffer(),
│ │ │ │ +
522 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ +
523 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ +
524 stencilTable->GetDuuWeightsBuffer(),
│ │ │ │ +
525 stencilTable->GetDuvWeightsBuffer(),
│ │ │ │ +
526 stencilTable->GetDvvWeightsBuffer(),
│ │ │ │ +
527 /* start = */ 0,
│ │ │ │ +
528 /* end = */ stencilTable->GetNumStencils());
│ │ │ │ +
529 }
│ │ │ │ +
│ │ │ │ +
530
│ │ │ │ +
566 bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
567 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
568 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
569 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
570 GLuint sizesBuffer,
│ │ │ │ +
571 GLuint offsetsBuffer,
│ │ │ │ +
572 GLuint indicesBuffer,
│ │ │ │ +
573 GLuint weightsBuffer,
│ │ │ │ +
574 GLuint duWeightsBuffer,
│ │ │ │ +
575 GLuint dvWeightsBuffer,
│ │ │ │ +
576 int start,
│ │ │ │ +
577 int end) const;
│ │ │ │ +
578
│ │ │ │ +
632 bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
633 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
634 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
635 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
636 GLuint duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
637 GLuint duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
638 GLuint dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
639 GLuint sizesBuffer,
│ │ │ │ +
640 GLuint offsetsBuffer,
│ │ │ │ +
641 GLuint indicesBuffer,
│ │ │ │ +
642 GLuint weightsBuffer,
│ │ │ │ +
643 GLuint duWeightsBuffer,
│ │ │ │ +
644 GLuint dvWeightsBuffer,
│ │ │ │ +
645 GLuint duuWeightsBuffer,
│ │ │ │ +
646 GLuint duvWeightsBuffer,
│ │ │ │ +
647 GLuint dvvWeightsBuffer,
│ │ │ │ +
648 int start,
│ │ │ │ +
649 int end) const;
│ │ │ │ +
650
│ │ │ │ +
656
│ │ │ │ +
689 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
690 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ +
691 static bool EvalPatches(
│ │ │ │ +
692 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
693 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
694 int numPatchCoords,
│ │ │ │ +
695 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
696 PATCH_TABLE *patchTable,
│ │ │ │ +
697 GLComputeEvaluator const *instance,
│ │ │ │ +
698 void * deviceContext = NULL) {
│ │ │ │ +
699
│ │ │ │ +
700 if (instance) {
│ │ │ │ +
701 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
702 dstBuffer, dstDesc,
│ │ │ │ +
703 numPatchCoords, patchCoords,
│ │ │ │ +
704 patchTable);
│ │ │ │ +
705 } else {
│ │ │ │ +
706 // Create an instance on demand (slow)
│ │ │ │ +
707 (void)deviceContext; // unused
│ │ │ │ +
708 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
711 if (instance) {
│ │ │ │ +
712 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
713 dstBuffer, dstDesc,
│ │ │ │ +
714 numPatchCoords, patchCoords,
│ │ │ │ +
715 patchTable);
│ │ │ │ +
716 delete instance;
│ │ │ │ +
717 return r;
│ │ │ │ +
718 }
│ │ │ │ +
719 return false;
│ │ │ │ +
720 }
│ │ │ │ +
721 }
│ │ │ │ +
│ │ │ │ +
722
│ │ │ │ +
767 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
768 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ +
769 static bool EvalPatches(
│ │ │ │ +
770 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
771 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
772 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
773 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
774 int numPatchCoords,
│ │ │ │ +
775 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
776 PATCH_TABLE *patchTable,
│ │ │ │ +
777 GLComputeEvaluator const *instance,
│ │ │ │ +
778 void * deviceContext = NULL) {
│ │ │ │ +
779
│ │ │ │ +
780 if (instance) {
│ │ │ │ +
781 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
782 dstBuffer, dstDesc,
│ │ │ │ +
783 duBuffer, duDesc,
│ │ │ │ +
784 dvBuffer, dvDesc,
│ │ │ │ +
785 numPatchCoords, patchCoords,
│ │ │ │ +
786 patchTable);
│ │ │ │ +
787 } else {
│ │ │ │ +
788 // Create an instance on demand (slow)
│ │ │ │ +
789 (void)deviceContext; // unused
│ │ │ │ +
790 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
791 duDesc, dvDesc);
│ │ │ │ +
792 if (instance) {
│ │ │ │ +
793 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
794 dstBuffer, dstDesc,
│ │ │ │ +
795 duBuffer, duDesc,
│ │ │ │ +
796 dvBuffer, dvDesc,
│ │ │ │ +
797 numPatchCoords, patchCoords,
│ │ │ │ +
798 patchTable);
│ │ │ │ +
799 delete instance;
│ │ │ │ +
800 return r;
│ │ │ │ +
801 }
│ │ │ │ +
802 return false;
│ │ │ │ +
803 }
│ │ │ │ +
804 }
│ │ │ │ +
│ │ │ │ +
805
│ │ │ │ +
868 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
869 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ +
870 static bool EvalPatches(
│ │ │ │ +
871 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
872 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
873 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
874 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
875 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
876 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
877 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
878 int numPatchCoords,
│ │ │ │ +
879 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
880 PATCH_TABLE *patchTable,
│ │ │ │ +
881 GLComputeEvaluator const *instance,
│ │ │ │ +
882 void * deviceContext = NULL) {
│ │ │ │ +
883
│ │ │ │ +
884 if (instance) {
│ │ │ │ +
885 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
886 dstBuffer, dstDesc,
│ │ │ │ +
887 duBuffer, duDesc,
│ │ │ │ +
888 dvBuffer, dvDesc,
│ │ │ │ +
889 duuBuffer, duuDesc,
│ │ │ │ +
890 duvBuffer, duvDesc,
│ │ │ │ +
891 dvvBuffer, dvvDesc,
│ │ │ │ +
892 numPatchCoords, patchCoords,
│ │ │ │ +
893 patchTable);
│ │ │ │ +
894 } else {
│ │ │ │ +
895 // Create an instance on demand (slow)
│ │ │ │ +
896 (void)deviceContext; // unused
│ │ │ │ +
897 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
898 duDesc, dvDesc,
│ │ │ │ +
899 duuDesc, duvDesc, dvvDesc);
│ │ │ │ +
900 if (instance) {
│ │ │ │ +
901 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ +
902 dstBuffer, dstDesc,
│ │ │ │ +
903 duBuffer, duDesc,
│ │ │ │ +
904 dvBuffer, dvDesc,
│ │ │ │ +
905 duuBuffer, duuDesc,
│ │ │ │ +
906 duvBuffer, duvDesc,
│ │ │ │ +
907 dvvBuffer, dvvDesc,
│ │ │ │ +
908 numPatchCoords, patchCoords,
│ │ │ │ +
909 patchTable);
│ │ │ │ +
910 delete instance;
│ │ │ │ +
911 return r;
│ │ │ │ +
912 }
│ │ │ │ +
913 return false;
│ │ │ │ +
914 }
│ │ │ │ +
915 }
│ │ │ │ +
│ │ │ │ +
916
│ │ │ │ +
941 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
942 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
944 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
945 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
946 int numPatchCoords,
│ │ │ │ +
947 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
948 PATCH_TABLE *patchTable) const {
│ │ │ │ +
949
│ │ │ │ +
950 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
951 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
952 0, BufferDescriptor(),
│ │ │ │ +
953 0, BufferDescriptor(),
│ │ │ │ +
954 numPatchCoords,
│ │ │ │ +
955 patchCoords->BindVBO(),
│ │ │ │ +
956 patchTable->GetPatchArrays(),
│ │ │ │ +
957 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
958 patchTable->GetPatchParamBuffer());
│ │ │ │ +
959 }
│ │ │ │ +
│ │ │ │ +
960
│ │ │ │ +
995 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
996 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
998 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
999 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1000 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1001 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1002 int numPatchCoords,
│ │ │ │ +
1003 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1004 PATCH_TABLE *patchTable) const {
│ │ │ │ +
1005
│ │ │ │ +
1006 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1007 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1008 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
1009 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
1010 numPatchCoords,
│ │ │ │ +
1011 patchCoords->BindVBO(),
│ │ │ │ +
1012 patchTable->GetPatchArrays(),
│ │ │ │ +
1013 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
1014 patchTable->GetPatchParamBuffer());
│ │ │ │ +
1015 }
│ │ │ │ +
│ │ │ │ +
1016
│ │ │ │ +
1069 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1070 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1072 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1073 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1074 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1075 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1076 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1077 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1078 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1079 int numPatchCoords,
│ │ │ │ +
1080 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1081 PATCH_TABLE *patchTable) const {
│ │ │ │ +
1082
│ │ │ │ +
1083 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1084 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1085 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
1086 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
1087 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ +
1088 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ +
1089 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ +
1090 numPatchCoords,
│ │ │ │ +
1091 patchCoords->BindVBO(),
│ │ │ │ +
1092 patchTable->GetPatchArrays(),
│ │ │ │ +
1093 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
1094 patchTable->GetPatchParamBuffer());
│ │ │ │ +
1095 }
│ │ │ │ +
│ │ │ │ +
1096
│ │ │ │ +
1097 bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1098 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1099 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1100 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1101 int numPatchCoords,
│ │ │ │ +
1102 GLuint patchCoordsBuffer,
│ │ │ │ +
1103 const PatchArrayVector &patchArrays,
│ │ │ │ +
1104 GLuint patchIndexBuffer,
│ │ │ │ +
1105 GLuint patchParamsBuffer) const;
│ │ │ │ +
1106
│ │ │ │ +
1107 bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1108 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1109 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1110 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1111 GLuint duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1112 GLuint duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1113 GLuint dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1114 int numPatchCoords,
│ │ │ │ +
1115 GLuint patchCoordsBuffer,
│ │ │ │ +
1116 const PatchArrayVector &patchArrays,
│ │ │ │ +
1117 GLuint patchIndexBuffer,
│ │ │ │ +
1118 GLuint patchParamsBuffer) const;
│ │ │ │ +
1119
│ │ │ │ +
1152 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1153 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1155 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1156 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1157 int numPatchCoords,
│ │ │ │ +
1158 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1159 PATCH_TABLE *patchTable,
│ │ │ │ +
1160 GLComputeEvaluator const *instance,
│ │ │ │ +
1161 void * deviceContext = NULL) {
│ │ │ │ +
1162
│ │ │ │ +
1163 if (instance) {
│ │ │ │ +
1164 return instance->EvalPatchesVarying(
│ │ │ │ +
1165 srcBuffer, srcDesc,
│ │ │ │ +
1166 dstBuffer, dstDesc,
│ │ │ │ +
1167 numPatchCoords, patchCoords,
│ │ │ │ +
1168 patchTable);
│ │ │ │ +
1169 } else {
│ │ │ │ +
1170 // Create an instance on demand (slow)
│ │ │ │ +
1171 (void)deviceContext; // unused
│ │ │ │ +
1172 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
1175 if (instance) {
│ │ │ │ +
1176 bool r = instance->EvalPatchesVarying(
│ │ │ │ +
1177 srcBuffer, srcDesc,
│ │ │ │ +
1178 dstBuffer, dstDesc,
│ │ │ │ +
1179 numPatchCoords, patchCoords,
│ │ │ │ +
1180 patchTable);
│ │ │ │ +
1181 delete instance;
│ │ │ │ +
1182 return r;
│ │ │ │ +
1183 }
│ │ │ │ +
1184 return false;
│ │ │ │ +
1185 }
│ │ │ │ +
1186 }
│ │ │ │ +
│ │ │ │ +
1187
│ │ │ │ +
1212 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1213 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1215 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1216 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1217 int numPatchCoords,
│ │ │ │ +
1218 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1219 PATCH_TABLE *patchTable) const {
│ │ │ │ +
1220
│ │ │ │ +
1221 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1222 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1223 0, BufferDescriptor(),
│ │ │ │ +
1224 0, BufferDescriptor(),
│ │ │ │ +
1225 numPatchCoords,
│ │ │ │ +
1226 patchCoords->BindVBO(),
│ │ │ │ +
1227 patchTable->GetVaryingPatchArrays(),
│ │ │ │ +
1228 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
1229 patchTable->GetPatchParamBuffer());
│ │ │ │ +
1230 }
│ │ │ │ +
│ │ │ │ +
1231
│ │ │ │ +
1276 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1277 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1279 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1280 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1281 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1282 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1283 int numPatchCoords,
│ │ │ │ +
1284 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1285 PATCH_TABLE *patchTable,
│ │ │ │ +
1286 GLComputeEvaluator const *instance,
│ │ │ │ +
1287 void * deviceContext = NULL) {
│ │ │ │ +
1288
│ │ │ │ +
1289 if (instance) {
│ │ │ │ +
1290 return instance->EvalPatchesVarying(
│ │ │ │ +
1291 srcBuffer, srcDesc,
│ │ │ │ +
1292 dstBuffer, dstDesc,
│ │ │ │ +
1293 duBuffer, duDesc,
│ │ │ │ +
1294 dvBuffer, dvDesc,
│ │ │ │ +
1295 numPatchCoords, patchCoords,
│ │ │ │ +
1296 patchTable);
│ │ │ │ +
1297 } else {
│ │ │ │ +
1298 // Create an instance on demand (slow)
│ │ │ │ +
1299 (void)deviceContext; // unused
│ │ │ │ +
1300 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1301 duDesc, dvDesc);
│ │ │ │ +
1302 if (instance) {
│ │ │ │ +
1303 bool r = instance->EvalPatchesVarying(
│ │ │ │ +
1304 srcBuffer, srcDesc,
│ │ │ │ +
1305 dstBuffer, dstDesc,
│ │ │ │ +
1306 duBuffer, duDesc,
│ │ │ │ +
1307 dvBuffer, dvDesc,
│ │ │ │ +
1308 numPatchCoords, patchCoords,
│ │ │ │ +
1309 patchTable);
│ │ │ │ +
1310 delete instance;
│ │ │ │ +
1311 return r;
│ │ │ │ +
1312 }
│ │ │ │ +
1313 return false;
│ │ │ │ +
1314 }
│ │ │ │ +
1315 }
│ │ │ │ +
│ │ │ │ +
1316
│ │ │ │ +
1353 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1354 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1356 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1357 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1358 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1359 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1360 int numPatchCoords,
│ │ │ │ +
1361 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1362 PATCH_TABLE *patchTable) const {
│ │ │ │ +
1363
│ │ │ │ +
1364 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1365 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1366 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
1367 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
1368 numPatchCoords,
│ │ │ │ +
1369 patchCoords->BindVBO(),
│ │ │ │ +
1370 patchTable->GetVaryingPatchArrays(),
│ │ │ │ +
1371 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
1372 patchTable->GetPatchParamBuffer());
│ │ │ │ +
1373 }
│ │ │ │ +
│ │ │ │ +
1374
│ │ │ │ +
1437 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1438 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1440 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1441 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1442 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1443 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1444 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1445 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1446 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1447 int numPatchCoords,
│ │ │ │ +
1448 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1449 PATCH_TABLE *patchTable,
│ │ │ │ +
1450 GLComputeEvaluator const *instance,
│ │ │ │ +
1451 void * deviceContext = NULL) {
│ │ │ │ +
1452
│ │ │ │ +
1453 if (instance) {
│ │ │ │ +
1454 return instance->EvalPatchesVarying(
│ │ │ │ +
1455 srcBuffer, srcDesc,
│ │ │ │ +
1456 dstBuffer, dstDesc,
│ │ │ │ +
1457 duBuffer, duDesc,
│ │ │ │ +
1458 dvBuffer, dvDesc,
│ │ │ │ +
1459 duuBuffer, duuDesc,
│ │ │ │ +
1460 duvBuffer, duvDesc,
│ │ │ │ +
1461 dvvBuffer, dvvDesc,
│ │ │ │ +
1462 numPatchCoords, patchCoords,
│ │ │ │ +
1463 patchTable);
│ │ │ │ +
1464 } else {
│ │ │ │ +
1465 // Create an instance on demand (slow)
│ │ │ │ +
1466 (void)deviceContext; // unused
│ │ │ │ +
1467 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1468 duDesc, dvDesc,
│ │ │ │ +
1469 duuDesc, duvDesc, dvvDesc);
│ │ │ │ +
1470 if (instance) {
│ │ │ │ +
1471 bool r = instance->EvalPatchesVarying(
│ │ │ │ +
1472 srcBuffer, srcDesc,
│ │ │ │ +
1473 dstBuffer, dstDesc,
│ │ │ │ +
1474 duBuffer, duDesc,
│ │ │ │ +
1475 dvBuffer, dvDesc,
│ │ │ │ +
1476 duuBuffer, duuDesc,
│ │ │ │ +
1477 duvBuffer, duvDesc,
│ │ │ │ +
1478 dvvBuffer, dvvDesc,
│ │ │ │ +
1479 numPatchCoords, patchCoords,
│ │ │ │ +
1480 patchTable);
│ │ │ │ +
1481 delete instance;
│ │ │ │ +
1482 return r;
│ │ │ │ +
1483 }
│ │ │ │ +
1484 return false;
│ │ │ │ +
1485 }
│ │ │ │ +
1486 }
│ │ │ │ +
│ │ │ │ +
1487
│ │ │ │ +
1542 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1543 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1545 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1546 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1547 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1548 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1549 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1550 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1551 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1552 int numPatchCoords,
│ │ │ │ +
1553 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1554 PATCH_TABLE *patchTable) const {
│ │ │ │ +
1555
│ │ │ │ +
1556 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1557 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1558 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
1559 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
1560 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ +
1561 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ +
1562 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ +
1563 numPatchCoords,
│ │ │ │ +
1564 patchCoords->BindVBO(),
│ │ │ │ +
1565 patchTable->GetVaryingPatchArrays(),
│ │ │ │ +
1566 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
1567 patchTable->GetPatchParamBuffer());
│ │ │ │ +
1568 }
│ │ │ │ +
│ │ │ │ +
1569
│ │ │ │ +
1604 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1605 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1607 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1608 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1609 int numPatchCoords,
│ │ │ │ +
1610 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1611 PATCH_TABLE *patchTable,
│ │ │ │ +
1612 int fvarChannel,
│ │ │ │ +
1613 GLComputeEvaluator const *instance,
│ │ │ │ +
1614 void * deviceContext = NULL) {
│ │ │ │ +
1615
│ │ │ │ +
1616 if (instance) {
│ │ │ │ +
1617 return instance->EvalPatchesFaceVarying(
│ │ │ │ +
1618 srcBuffer, srcDesc,
│ │ │ │ +
1619 dstBuffer, dstDesc,
│ │ │ │ +
1620 numPatchCoords, patchCoords,
│ │ │ │ +
1621 patchTable, fvarChannel);
│ │ │ │ +
1622 } else {
│ │ │ │ +
1623 // Create an instance on demand (slow)
│ │ │ │ +
1624 (void)deviceContext; // unused
│ │ │ │ +
1625 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
1628 if (instance) {
│ │ │ │ +
1629 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ +
1630 srcBuffer, srcDesc,
│ │ │ │ +
1631 dstBuffer, dstDesc,
│ │ │ │ +
1632 numPatchCoords, patchCoords,
│ │ │ │ +
1633 patchTable, fvarChannel);
│ │ │ │ +
1634 delete instance;
│ │ │ │ +
1635 return r;
│ │ │ │ +
1636 }
│ │ │ │ +
1637 return false;
│ │ │ │ +
1638 }
│ │ │ │ +
1639 }
│ │ │ │ +
│ │ │ │ +
1640
│ │ │ │ +
1667 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1668 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1670 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1671 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1672 int numPatchCoords,
│ │ │ │ +
1673 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1674 PATCH_TABLE *patchTable,
│ │ │ │ +
1675 int fvarChannel = 0) const {
│ │ │ │ +
1676
│ │ │ │ +
1677 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1678 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1679 0, BufferDescriptor(),
│ │ │ │ +
1680 0, BufferDescriptor(),
│ │ │ │ +
1681 numPatchCoords,
│ │ │ │ +
1682 patchCoords->BindVBO(),
│ │ │ │ +
1683 patchTable->GetFVarPatchArrays(fvarChannel),
│ │ │ │ +
1684 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
1685 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ +
1686 }
│ │ │ │ +
│ │ │ │ +
1687
│ │ │ │ +
1734 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1735 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1737 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1738 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1739 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1740 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1741 int numPatchCoords,
│ │ │ │ +
1742 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1743 PATCH_TABLE *patchTable,
│ │ │ │ +
1744 int fvarChannel,
│ │ │ │ +
1745 GLComputeEvaluator const *instance,
│ │ │ │ +
1746 void * deviceContext = NULL) {
│ │ │ │ +
1747
│ │ │ │ +
1748 if (instance) {
│ │ │ │ +
1749 return instance->EvalPatchesFaceVarying(
│ │ │ │ +
1750 srcBuffer, srcDesc,
│ │ │ │ +
1751 dstBuffer, dstDesc,
│ │ │ │ +
1752 duBuffer, duDesc,
│ │ │ │ +
1753 dvBuffer, dvDesc,
│ │ │ │ +
1754 numPatchCoords, patchCoords,
│ │ │ │ +
1755 patchTable, fvarChannel);
│ │ │ │ +
1756 } else {
│ │ │ │ +
1757 // Create an instance on demand (slow)
│ │ │ │ +
1758 (void)deviceContext; // unused
│ │ │ │ +
1759 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1760 duDesc, dvDesc);
│ │ │ │ +
1761 if (instance) {
│ │ │ │ +
1762 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ +
1763 srcBuffer, srcDesc,
│ │ │ │ +
1764 dstBuffer, dstDesc,
│ │ │ │ +
1765 duBuffer, duDesc,
│ │ │ │ +
1766 dvBuffer, dvDesc,
│ │ │ │ +
1767 numPatchCoords, patchCoords,
│ │ │ │ +
1768 patchTable, fvarChannel);
│ │ │ │ +
1769 delete instance;
│ │ │ │ +
1770 return r;
│ │ │ │ +
1771 }
│ │ │ │ +
1772 return false;
│ │ │ │ +
1773 }
│ │ │ │ +
1774 }
│ │ │ │ +
│ │ │ │ +
1775
│ │ │ │ +
1814 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1815 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1817 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1818 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1819 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1820 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1821 int numPatchCoords,
│ │ │ │ +
1822 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1823 PATCH_TABLE *patchTable,
│ │ │ │ +
1824 int fvarChannel = 0) const {
│ │ │ │ +
1825
│ │ │ │ +
1826 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
1827 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
1828 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
1829 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
1830 numPatchCoords,
│ │ │ │ +
1831 patchCoords->BindVBO(),
│ │ │ │ +
1832 patchTable->GetFVarPatchArrays(fvarChannel),
│ │ │ │ +
1833 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
1834 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ +
1835 }
│ │ │ │ +
│ │ │ │ +
1836
│ │ │ │ +
1901 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1902 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1904 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1905 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1906 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1907 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1908 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1909 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1910 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1911 int numPatchCoords,
│ │ │ │ +
1912 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1913 PATCH_TABLE *patchTable,
│ │ │ │ +
1914 int fvarChannel,
│ │ │ │ +
1915 GLComputeEvaluator const *instance,
│ │ │ │ +
1916 void * deviceContext = NULL) {
│ │ │ │ +
1917
│ │ │ │ +
1918 if (instance) {
│ │ │ │ +
1919 return instance->EvalPatchesFaceVarying(
│ │ │ │ +
1920 srcBuffer, srcDesc,
│ │ │ │ +
1921 dstBuffer, dstDesc,
│ │ │ │ +
1922 duBuffer, duDesc,
│ │ │ │ +
1923 dvBuffer, dvDesc,
│ │ │ │ +
1924 duuBuffer, duuDesc,
│ │ │ │ +
1925 duvBuffer, duvDesc,
│ │ │ │ +
1926 dvvBuffer, dvvDesc,
│ │ │ │ +
1927 numPatchCoords, patchCoords,
│ │ │ │ +
1928 patchTable, fvarChannel);
│ │ │ │ +
1929 } else {
│ │ │ │ +
1930 // Create an instance on demand (slow)
│ │ │ │ +
1931 (void)deviceContext; // unused
│ │ │ │ +
1932 instance = Create(srcDesc, dstDesc,
│ │ │ │ +
1933 duDesc, dvDesc,
│ │ │ │ +
1934 duuDesc, duvDesc, dvvDesc);
│ │ │ │ +
1935 if (instance) {
│ │ │ │ +
1936 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ +
1937 srcBuffer, srcDesc,
│ │ │ │ +
1938 dstBuffer, dstDesc,
│ │ │ │ +
1939 duBuffer, duDesc,
│ │ │ │ +
1940 dvBuffer, dvDesc,
│ │ │ │ +
1941 duuBuffer, duuDesc,
│ │ │ │ +
1942 duvBuffer, duvDesc,
│ │ │ │ +
1943 dvvBuffer, dvvDesc,
│ │ │ │ +
1944 numPatchCoords, patchCoords,
│ │ │ │ +
1945 patchTable, fvarChannel);
│ │ │ │ +
1946 delete instance;
│ │ │ │ +
1947 return r;
│ │ │ │ +
1948 }
│ │ │ │ +
1949 return false;
│ │ │ │ +
1950 }
│ │ │ │ +
1951 }
│ │ │ │ +
│ │ │ │ +
1952
│ │ │ │ +
2009 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
2010 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
2012 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
2013 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
2014 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
2015 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
2016 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
2017 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
2018 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
2019 int numPatchCoords,
│ │ │ │ +
2020 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
2021 PATCH_TABLE *patchTable,
│ │ │ │ +
2022 int fvarChannel = 0) const {
│ │ │ │ +
2023
│ │ │ │ +
2024 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ +
2025 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ +
2026 duBuffer->BindVBO(), duDesc,
│ │ │ │ +
2027 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ +
2028 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ +
2029 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ +
2030 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ +
2031 numPatchCoords,
│ │ │ │ +
2032 patchCoords->BindVBO(),
│ │ │ │ +
2033 patchTable->GetFVarPatchArrays(fvarChannel),
│ │ │ │ +
2034 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
2035 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ +
2036 }
│ │ │ │ +
│ │ │ │ +
2037
│ │ │ │ +
2043
│ │ │ │ +
2046 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ +
2047 BufferDescriptor const &dstDesc,
│ │ │ │ +
2048 BufferDescriptor const &duDesc = BufferDescriptor(),
│ │ │ │ +
2049 BufferDescriptor const &dvDesc = BufferDescriptor(),
│ │ │ │ +
2050 BufferDescriptor const &duuDesc = BufferDescriptor(),
│ │ │ │ +
2051 BufferDescriptor const &duvDesc = BufferDescriptor(),
│ │ │ │ +
2052 BufferDescriptor const &dvvDesc = BufferDescriptor());
│ │ │ │ +
2053
│ │ │ │ +
2055 static void Synchronize(void *deviceContext);
│ │ │ │ +
2056
│ │ │ │ +
2057private:
│ │ │ │ +
2058 struct _StencilKernel {
│ │ │ │ +
2059 _StencilKernel();
│ │ │ │ +
2060 ~_StencilKernel();
│ │ │ │ +
2061 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ +
2062 BufferDescriptor const &dstDesc,
│ │ │ │ +
2063 BufferDescriptor const &duDesc,
│ │ │ │ +
2064 BufferDescriptor const &dvDesc,
│ │ │ │ +
2065 BufferDescriptor const &duuDesc,
│ │ │ │ +
2066 BufferDescriptor const &duvDesc,
│ │ │ │ +
2067 BufferDescriptor const &dvvDesc,
│ │ │ │ +
2068 int workGroupSize);
│ │ │ │ +
2069 GLuint program;
│ │ │ │ +
2070 GLuint uniformStart;
│ │ │ │ +
2071 GLuint uniformEnd;
│ │ │ │ +
2072 GLuint uniformSrcOffset;
│ │ │ │ +
2073 GLuint uniformDstOffset;
│ │ │ │ +
2074 GLuint uniformDuDesc;
│ │ │ │ +
2075 GLuint uniformDvDesc;
│ │ │ │ +
2076 GLuint uniformDuuDesc;
│ │ │ │ +
2077 GLuint uniformDuvDesc;
│ │ │ │ +
2078 GLuint uniformDvvDesc;
│ │ │ │ +
2079 } _stencilKernel;
│ │ │ │ +
2080
│ │ │ │ +
2081 struct _PatchKernel {
│ │ │ │ +
2082 _PatchKernel();
│ │ │ │ +
2083 ~_PatchKernel();
│ │ │ │ +
2084 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ +
2085 BufferDescriptor const &dstDesc,
│ │ │ │ +
2086 BufferDescriptor const &duDesc,
│ │ │ │ +
2087 BufferDescriptor const &dvDesc,
│ │ │ │ +
2088 BufferDescriptor const &duuDesc,
│ │ │ │ +
2089 BufferDescriptor const &duvDesc,
│ │ │ │ +
2090 BufferDescriptor const &dvvDesc,
│ │ │ │ +
2091 int workGroupSize);
│ │ │ │ +
2092 GLuint program;
│ │ │ │ +
2093 GLuint uniformSrcOffset;
│ │ │ │ +
2094 GLuint uniformDstOffset;
│ │ │ │ +
2095 GLuint uniformPatchArray;
│ │ │ │ +
2096 GLuint uniformDuDesc;
│ │ │ │ +
2097 GLuint uniformDvDesc;
│ │ │ │ +
2098 GLuint uniformDuuDesc;
│ │ │ │ +
2099 GLuint uniformDuvDesc;
│ │ │ │ +
2100 GLuint uniformDvvDesc;
│ │ │ │ +
2101 } _patchKernel;
│ │ │ │ +
2102
│ │ │ │ +
2103 int _workGroupSize;
│ │ │ │ +
2104 GLuint _patchArraysSSBO;
│ │ │ │ +
2105};
│ │ │ │ +
│ │ │ │ +
2106
│ │ │ │ +
2107} // end namespace Osd
│ │ │ │ +
2108
│ │ │ │ +
2109} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
2110using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
2111
│ │ │ │ +
2112} // end namespace OpenSubdiv
│ │ │ │ +
2113
│ │ │ │ +
2114
│ │ │ │ +
2115#endif // OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H
│ │ │ │ │ │ │ │ -
Concrete vertex buffer class for Cpu subdivision and DirectX drawing.
│ │ │ │ -
static CpuD3D11VertexBuffer * Create(int numElements, int numVertices, ID3D11DeviceContext *deviceContext)
Creator. Returns NULL if error.
│ │ │ │ -
CpuD3D11VertexBuffer(int numElements, int numVertices)
Constructor.
│ │ │ │ -
int GetNumElements() const
Returns how many elements defined in this vertex buffer.
│ │ │ │ -
void UpdateData(const float *src, int startVertex, int numVertices, void *deviceContext=NULL)
│ │ │ │ -
int GetNumVertices() const
Returns how many vertices allocated in this vertex buffer.
│ │ │ │ -
ID3D11Buffer * BindD3D11Buffer(ID3D11DeviceContext *deviceContext)
Returns the D3D11 buffer object.
│ │ │ │ -
float * BindCpuBuffer()
Returns the address of CPU buffer.
│ │ │ │ - │ │ │ │ - │ │ │ │ -
ID3D11Buffer * BindVBO(ID3D11DeviceContext *deviceContext)
Returns the D3D11 buffer object (for Osd::Mesh interface)
│ │ │ │ +
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
GLStencilTableSSBO(Far::LimitStencilTable const *limitStencilTable)
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
GLStencilTableSSBO(Far::StencilTable const *stencilTable)
│ │ │ │ + │ │ │ │ + │ │ │ │ +
static GLStencilTableSSBO * Create(Far::LimitStencilTable const *limitStencilTable, void *deviceContext=NULL)
│ │ │ │ + │ │ │ │ + │ │ │ │ +
static GLStencilTableSSBO * Create(Far::StencilTable const *stencilTable, void *deviceContext=NULL)
│ │ │ │ + │ │ │ │ +
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable) const
Generic stencil function.
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable) const
Generic stencil function.
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ + │ │ │ │ +
bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, GLuint patchIndexBuffer, GLuint patchParamsBuffer) const
│ │ │ │ +
~GLComputeEvaluator()
Destructor. note that the GL context must be made current.
│ │ │ │ +
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, GLuint sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, GLuint duWeightsBuffer, GLuint dvWeightsBuffer, GLuint duuWeightsBuffer, GLuint duvWeightsBuffer, GLuint dvvWeightsBuffer, int start, int end) const
Dispatch the GLSL compute kernel on GPU asynchronously returns false if the kernel hasn't been compil...
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ + │ │ │ │ +
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable) const
Generic stencil function.
│ │ │ │ +
bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, GLuint patchIndexBuffer, GLuint patchParamsBuffer) const
│ │ │ │ +
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, void *deviceContext=NULL)
│ │ │ │ +
bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, GLuint duWeightsBuffer, GLuint dvWeightsBuffer, int start, int end) const
Dispatch the GLSL compute kernel on GPU asynchronously returns false if the kernel hasn't been compil...
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
static void Synchronize(void *deviceContext)
Wait the dispatched kernel finishes.
│ │ │ │ +
bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const &dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const &dvvDesc=BufferDescriptor())
│ │ │ │ +
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, void *deviceContext=NULL)
│ │ │ │ +
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -cpuD3D11VertexBuffer.h │ │ │ │ │ +glComputeEvaluator.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ -2// Copyright 2013 Pixar │ │ │ │ │ +2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ 7// Section 6. Trademarks. is deleted and replaced with: │ │ │ │ │ 8// │ │ │ │ │ 9// 6. Trademarks. This License does not grant permission to use the trade │ │ │ │ │ @@ -24,105 +24,1359 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29#include │ │ │ │ │ -30 │ │ │ │ │ -31struct ID3D11Buffer; │ │ │ │ │ -32struct ID3D11Device; │ │ │ │ │ -33struct ID3D11DeviceContext; │ │ │ │ │ -34 │ │ │ │ │ -35namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -36namespace OPENSUBDIV_VERSION { │ │ │ │ │ -37 │ │ │ │ │ -38namespace Osd { │ │ │ │ │ -39 │ │ │ │ │ -_4_8class _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r { │ │ │ │ │ -49public: │ │ │ │ │ -_5_1 static _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r * _C_r_e_a_t_e(int numElements, int numVertices, │ │ │ │ │ -52 ID3D11DeviceContext *deviceContext); │ │ │ │ │ -53 │ │ │ │ │ -_5_5 virtual _~_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r(); │ │ │ │ │ -56 │ │ │ │ │ -_5_9 void _U_p_d_a_t_e_D_a_t_a(const float *src, int startVertex, int numVertices, │ │ │ │ │ -60 void *deviceContext = NULL); │ │ │ │ │ -61 │ │ │ │ │ -_6_3 int _G_e_t_N_u_m_E_l_e_m_e_n_t_s() const; │ │ │ │ │ +29 │ │ │ │ │ +30#include "../osd/opengl.h" │ │ │ │ │ +31#include "../osd/types.h" │ │ │ │ │ +32#include "../osd/bufferDescriptor.h" │ │ │ │ │ +33 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Far { │ │ │ │ │ +38 class PatchTable; │ │ │ │ │ +39 class StencilTable; │ │ │ │ │ +40 class LimitStencilTable; │ │ │ │ │ +41} │ │ │ │ │ +42 │ │ │ │ │ +43namespace Osd { │ │ │ │ │ +44 │ │ │ │ │ +_5_1class _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O { │ │ │ │ │ +52public: │ │ │ │ │ +_5_3 static _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ +54 void *deviceContext = NULL) { │ │ │ │ │ +55 (void)deviceContext; // unused │ │ │ │ │ +56 return new _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(stencilTable); │ │ │ │ │ +57 } │ │ │ │ │ +_5_8 static _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O *_C_r_e_a_t_e( │ │ │ │ │ +59 _F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *limitStencilTable, │ │ │ │ │ +60 void *deviceContext = NULL) { │ │ │ │ │ +61 (void)deviceContext; // unused │ │ │ │ │ +62 return new _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(limitStencilTable); │ │ │ │ │ +63 } │ │ │ │ │ 64 │ │ │ │ │ -_6_6 int _G_e_t_N_u_m_V_e_r_t_i_c_e_s() const; │ │ │ │ │ -67 │ │ │ │ │ -_6_9 float * _B_i_n_d_C_p_u_B_u_f_f_e_r(); │ │ │ │ │ -70 │ │ │ │ │ -_7_2 ID3D11Buffer *_B_i_n_d_D_3_D_1_1_B_u_f_f_e_r(ID3D11DeviceContext *deviceContext); │ │ │ │ │ -73 │ │ │ │ │ -_7_5 ID3D11Buffer *_B_i_n_d_V_B_O(ID3D11DeviceContext *deviceContext) { │ │ │ │ │ -76 return _B_i_n_d_D_3_D_1_1_B_u_f_f_e_r(deviceContext); │ │ │ │ │ -77 } │ │ │ │ │ -78 │ │ │ │ │ -79protected: │ │ │ │ │ -_8_1 _C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r(int numElements, int numVertices); │ │ │ │ │ -82 │ │ │ │ │ -_8_3 bool _a_l_l_o_c_a_t_e(ID3D11Device *device); │ │ │ │ │ -84 │ │ │ │ │ -85private: │ │ │ │ │ -86 int _numElements; │ │ │ │ │ -87 int _numVertices; │ │ │ │ │ -88 ID3D11Buffer *_d3d11Buffer; │ │ │ │ │ -89 float *_cpuBuffer; │ │ │ │ │ -90}; │ │ │ │ │ -91 │ │ │ │ │ -92} // end namespace Osd │ │ │ │ │ +_6_5 explicit _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable); │ │ │ │ │ +_6_6 explicit _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const │ │ │ │ │ +*limitStencilTable); │ │ │ │ │ +_6_7 _~_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(); │ │ │ │ │ +68 │ │ │ │ │ +69 // interfaces needed for GLSLComputeKernel │ │ │ │ │ +_7_0 GLuint _G_e_t_S_i_z_e_s_B_u_f_f_e_r() const { return _sizes; } │ │ │ │ │ +_7_1 GLuint _G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r() const { return _offsets; } │ │ │ │ │ +_7_2 GLuint _G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r() const { return _indices; } │ │ │ │ │ +_7_3 GLuint _G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _weights; } │ │ │ │ │ +_7_4 GLuint _G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duWeights; } │ │ │ │ │ +_7_5 GLuint _G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvWeights; } │ │ │ │ │ +_7_6 GLuint _G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duuWeights; } │ │ │ │ │ +_7_7 GLuint _G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duvWeights; } │ │ │ │ │ +_7_8 GLuint _G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvvWeights; } │ │ │ │ │ +_7_9 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { return _numStencils; } │ │ │ │ │ +80 │ │ │ │ │ +81private: │ │ │ │ │ +82 GLuint _sizes; │ │ │ │ │ +83 GLuint _offsets; │ │ │ │ │ +84 GLuint _indices; │ │ │ │ │ +85 GLuint _weights; │ │ │ │ │ +86 GLuint _duWeights; │ │ │ │ │ +87 GLuint _dvWeights; │ │ │ │ │ +88 GLuint _duuWeights; │ │ │ │ │ +89 GLuint _duvWeights; │ │ │ │ │ +90 GLuint _dvvWeights; │ │ │ │ │ +91 int _numStencils; │ │ │ │ │ +92}; │ │ │ │ │ 93 │ │ │ │ │ -94} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -95using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -96 │ │ │ │ │ -97} // end namespace OpenSubdiv │ │ │ │ │ -98 │ │ │ │ │ -99#endif // OPENSUBDIV3_OSD_CPU_D3D11_VERTEX_BUFFER_H │ │ │ │ │ +94// -------------------------------------------------------------------------- │ │ │ │ │ +- │ │ │ │ │ +95 │ │ │ │ │ +_9_6class _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r { │ │ │ │ │ +97public: │ │ │ │ │ +_9_8 typedef bool _I_n_s_t_a_n_t_i_a_t_a_b_l_e; │ │ │ │ │ +_9_9 static _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +100 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +101 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +102 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +103 void * deviceContext = NULL) { │ │ │ │ │ +104 return _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +105 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +106 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +107 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +108 deviceContext); │ │ │ │ │ +109 } │ │ │ │ │ +110 │ │ │ │ │ +_1_1_1 static _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +112 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +113 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +114 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +115 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +116 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +117 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +118 void * deviceContext = NULL) { │ │ │ │ │ +119 (void)deviceContext; // not used │ │ │ │ │ +120 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r *instance = new _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ +121 if (instance->_C_o_m_p_i_l_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +122 duuDesc, duvDesc, dvvDesc)) │ │ │ │ │ +123 return instance; │ │ │ │ │ +124 delete instance; │ │ │ │ │ +125 return NULL; │ │ │ │ │ +126 } │ │ │ │ │ +127 │ │ │ │ │ +_1_2_9 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ +130 │ │ │ │ │ +_1_3_2 _~_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ +133 │ │ │ │ │ +139 │ │ │ │ │ +167 template │ │ │ │ │ +_1_6_8 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +169 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +170 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +171 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +172 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +173 void * deviceContext = NULL) { │ │ │ │ │ +174 │ │ │ │ │ +175 if (instance) { │ │ │ │ │ +176 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +177 dstBuffer, dstDesc, │ │ │ │ │ +178 stencilTable); │ │ │ │ │ +179 } else { │ │ │ │ │ +180 // Create an instance on demand (slow) │ │ │ │ │ +181 (void)deviceContext; // unused │ │ │ │ │ +182 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +183 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +184 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ +185 if (instance) { │ │ │ │ │ +186 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +187 dstBuffer, dstDesc, │ │ │ │ │ +188 stencilTable); │ │ │ │ │ +189 delete instance; │ │ │ │ │ +190 return r; │ │ │ │ │ +191 } │ │ │ │ │ +192 return false; │ │ │ │ │ +193 } │ │ │ │ │ +194 } │ │ │ │ │ +195 │ │ │ │ │ +235 template │ │ │ │ │ +_2_3_6 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +237 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +238 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +239 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +240 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +241 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +242 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +243 void * deviceContext = NULL) { │ │ │ │ │ +244 │ │ │ │ │ +245 if (instance) { │ │ │ │ │ +246 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +247 dstBuffer, dstDesc, │ │ │ │ │ +248 duBuffer, duDesc, │ │ │ │ │ +249 dvBuffer, dvDesc, │ │ │ │ │ +250 stencilTable); │ │ │ │ │ +251 } else { │ │ │ │ │ +252 // Create an instance on demand (slow) │ │ │ │ │ +253 (void)deviceContext; // unused │ │ │ │ │ +254 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc); │ │ │ │ │ +255 if (instance) { │ │ │ │ │ +256 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +257 dstBuffer, dstDesc, │ │ │ │ │ +258 duBuffer, duDesc, │ │ │ │ │ +259 dvBuffer, dvDesc, │ │ │ │ │ +260 stencilTable); │ │ │ │ │ +261 delete instance; │ │ │ │ │ +262 return r; │ │ │ │ │ +263 } │ │ │ │ │ +264 return false; │ │ │ │ │ +265 } │ │ │ │ │ +266 } │ │ │ │ │ +267 │ │ │ │ │ +325 template │ │ │ │ │ +_3_2_6 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +327 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +328 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +329 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +330 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +331 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +332 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +333 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +334 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +335 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +336 void * deviceContext = NULL) { │ │ │ │ │ +337 │ │ │ │ │ +338 if (instance) { │ │ │ │ │ +339 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +340 dstBuffer, dstDesc, │ │ │ │ │ +341 duBuffer, duDesc, │ │ │ │ │ +342 dvBuffer, dvDesc, │ │ │ │ │ +343 duuBuffer, duuDesc, │ │ │ │ │ +344 duvBuffer, duvDesc, │ │ │ │ │ +345 dvvBuffer, dvvDesc, │ │ │ │ │ +346 stencilTable); │ │ │ │ │ +347 } else { │ │ │ │ │ +348 // Create an instance on demand (slow) │ │ │ │ │ +349 (void)deviceContext; // unused │ │ │ │ │ +350 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ +351 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ +352 if (instance) { │ │ │ │ │ +353 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +354 dstBuffer, dstDesc, │ │ │ │ │ +355 duBuffer, duDesc, │ │ │ │ │ +356 dvBuffer, dvDesc, │ │ │ │ │ +357 duuBuffer, duuDesc, │ │ │ │ │ +358 duvBuffer, duvDesc, │ │ │ │ │ +359 dvvBuffer, dvvDesc, │ │ │ │ │ +360 stencilTable); │ │ │ │ │ +361 delete instance; │ │ │ │ │ +362 return r; │ │ │ │ │ +363 } │ │ │ │ │ +364 return false; │ │ │ │ │ +365 } │ │ │ │ │ +366 } │ │ │ │ │ +367 │ │ │ │ │ +385 template │ │ │ │ │ +_3_8_6 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +387 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +388 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +389 STENCIL_TABLE const *stencilTable) const { │ │ │ │ │ +390 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +391 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +392 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +393 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +394 stencilTable->GetSizesBuffer(), │ │ │ │ │ +395 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ +396 stencilTable->GetIndicesBuffer(), │ │ │ │ │ +397 stencilTable->GetWeightsBuffer(), │ │ │ │ │ +398 0, │ │ │ │ │ +399 0, │ │ │ │ │ +400 /* start = */ 0, │ │ │ │ │ +401 /* end = */ stencilTable->GetNumStencils()); │ │ │ │ │ +402 } │ │ │ │ │ +403 │ │ │ │ │ +433 template │ │ │ │ │ +_4_3_4 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +435 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +436 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +437 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +438 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +439 STENCIL_TABLE const *stencilTable) const { │ │ │ │ │ +440 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +441 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +442 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +443 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +444 stencilTable->GetSizesBuffer(), │ │ │ │ │ +445 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ +446 stencilTable->GetIndicesBuffer(), │ │ │ │ │ +447 stencilTable->GetWeightsBuffer(), │ │ │ │ │ +448 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ +449 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ +450 /* start = */ 0, │ │ │ │ │ +451 /* end = */ stencilTable->GetNumStencils()); │ │ │ │ │ +452 } │ │ │ │ │ +453 │ │ │ │ │ +501 template │ │ │ │ │ +_5_0_2 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +503 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +504 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +505 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +506 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +507 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +508 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +509 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +510 STENCIL_TABLE const *stencilTable) const { │ │ │ │ │ +511 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +512 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +513 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +514 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +515 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ +516 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ +517 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ +518 stencilTable->GetSizesBuffer(), │ │ │ │ │ +519 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ +520 stencilTable->GetIndicesBuffer(), │ │ │ │ │ +521 stencilTable->GetWeightsBuffer(), │ │ │ │ │ +522 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ +523 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ +524 stencilTable->GetDuuWeightsBuffer(), │ │ │ │ │ +525 stencilTable->GetDuvWeightsBuffer(), │ │ │ │ │ +526 stencilTable->GetDvvWeightsBuffer(), │ │ │ │ │ +527 /* start = */ 0, │ │ │ │ │ +528 /* end = */ stencilTable->GetNumStencils()); │ │ │ │ │ +529 } │ │ │ │ │ +530 │ │ │ │ │ +_5_6_6 bool _E_v_a_l_S_t_e_n_c_i_l_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +567 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +568 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +569 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +570 GLuint sizesBuffer, │ │ │ │ │ +571 GLuint offsetsBuffer, │ │ │ │ │ +572 GLuint indicesBuffer, │ │ │ │ │ +573 GLuint weightsBuffer, │ │ │ │ │ +574 GLuint duWeightsBuffer, │ │ │ │ │ +575 GLuint dvWeightsBuffer, │ │ │ │ │ +576 int start, │ │ │ │ │ +577 int end) const; │ │ │ │ │ +578 │ │ │ │ │ +_6_3_2 bool _E_v_a_l_S_t_e_n_c_i_l_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +633 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +634 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +635 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +636 GLuint duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +637 GLuint duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +638 GLuint dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +639 GLuint sizesBuffer, │ │ │ │ │ +640 GLuint offsetsBuffer, │ │ │ │ │ +641 GLuint indicesBuffer, │ │ │ │ │ +642 GLuint weightsBuffer, │ │ │ │ │ +643 GLuint duWeightsBuffer, │ │ │ │ │ +644 GLuint dvWeightsBuffer, │ │ │ │ │ +645 GLuint duuWeightsBuffer, │ │ │ │ │ +646 GLuint duvWeightsBuffer, │ │ │ │ │ +647 GLuint dvvWeightsBuffer, │ │ │ │ │ +648 int start, │ │ │ │ │ +649 int end) const; │ │ │ │ │ +650 │ │ │ │ │ +656 │ │ │ │ │ +689 template │ │ │ │ │ +_6_9_1 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +692 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +693 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +694 int numPatchCoords, │ │ │ │ │ +695 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +696 PATCH_TABLE *patchTable, │ │ │ │ │ +697 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +698 void * deviceContext = NULL) { │ │ │ │ │ +699 │ │ │ │ │ +700 if (instance) { │ │ │ │ │ +701 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +702 dstBuffer, dstDesc, │ │ │ │ │ +703 numPatchCoords, patchCoords, │ │ │ │ │ +704 patchTable); │ │ │ │ │ +705 } else { │ │ │ │ │ +706 // Create an instance on demand (slow) │ │ │ │ │ +707 (void)deviceContext; // unused │ │ │ │ │ +708 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +709 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +710 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ +711 if (instance) { │ │ │ │ │ +712 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +713 dstBuffer, dstDesc, │ │ │ │ │ +714 numPatchCoords, patchCoords, │ │ │ │ │ +715 patchTable); │ │ │ │ │ +716 delete instance; │ │ │ │ │ +717 return r; │ │ │ │ │ +718 } │ │ │ │ │ +719 return false; │ │ │ │ │ +720 } │ │ │ │ │ +721 } │ │ │ │ │ +722 │ │ │ │ │ +767 template │ │ │ │ │ +_7_6_9 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +770 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +771 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +772 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +773 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +774 int numPatchCoords, │ │ │ │ │ +775 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +776 PATCH_TABLE *patchTable, │ │ │ │ │ +777 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +778 void * deviceContext = NULL) { │ │ │ │ │ +779 │ │ │ │ │ +780 if (instance) { │ │ │ │ │ +781 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +782 dstBuffer, dstDesc, │ │ │ │ │ +783 duBuffer, duDesc, │ │ │ │ │ +784 dvBuffer, dvDesc, │ │ │ │ │ +785 numPatchCoords, patchCoords, │ │ │ │ │ +786 patchTable); │ │ │ │ │ +787 } else { │ │ │ │ │ +788 // Create an instance on demand (slow) │ │ │ │ │ +789 (void)deviceContext; // unused │ │ │ │ │ +790 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +791 duDesc, dvDesc); │ │ │ │ │ +792 if (instance) { │ │ │ │ │ +793 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +794 dstBuffer, dstDesc, │ │ │ │ │ +795 duBuffer, duDesc, │ │ │ │ │ +796 dvBuffer, dvDesc, │ │ │ │ │ +797 numPatchCoords, patchCoords, │ │ │ │ │ +798 patchTable); │ │ │ │ │ +799 delete instance; │ │ │ │ │ +800 return r; │ │ │ │ │ +801 } │ │ │ │ │ +802 return false; │ │ │ │ │ +803 } │ │ │ │ │ +804 } │ │ │ │ │ +805 │ │ │ │ │ +868 template │ │ │ │ │ +_8_7_0 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +871 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +872 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +873 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +874 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +875 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +876 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +877 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +878 int numPatchCoords, │ │ │ │ │ +879 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +880 PATCH_TABLE *patchTable, │ │ │ │ │ +881 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +882 void * deviceContext = NULL) { │ │ │ │ │ +883 │ │ │ │ │ +884 if (instance) { │ │ │ │ │ +885 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +886 dstBuffer, dstDesc, │ │ │ │ │ +887 duBuffer, duDesc, │ │ │ │ │ +888 dvBuffer, dvDesc, │ │ │ │ │ +889 duuBuffer, duuDesc, │ │ │ │ │ +890 duvBuffer, duvDesc, │ │ │ │ │ +891 dvvBuffer, dvvDesc, │ │ │ │ │ +892 numPatchCoords, patchCoords, │ │ │ │ │ +893 patchTable); │ │ │ │ │ +894 } else { │ │ │ │ │ +895 // Create an instance on demand (slow) │ │ │ │ │ +896 (void)deviceContext; // unused │ │ │ │ │ +897 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +898 duDesc, dvDesc, │ │ │ │ │ +899 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ +900 if (instance) { │ │ │ │ │ +901 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ +902 dstBuffer, dstDesc, │ │ │ │ │ +903 duBuffer, duDesc, │ │ │ │ │ +904 dvBuffer, dvDesc, │ │ │ │ │ +905 duuBuffer, duuDesc, │ │ │ │ │ +906 duvBuffer, duvDesc, │ │ │ │ │ +907 dvvBuffer, dvvDesc, │ │ │ │ │ +908 numPatchCoords, patchCoords, │ │ │ │ │ +909 patchTable); │ │ │ │ │ +910 delete instance; │ │ │ │ │ +911 return r; │ │ │ │ │ +912 } │ │ │ │ │ +913 return false; │ │ │ │ │ +914 } │ │ │ │ │ +915 } │ │ │ │ │ +916 │ │ │ │ │ +941 template │ │ │ │ │ +_9_4_3 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +944 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +945 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +946 int numPatchCoords, │ │ │ │ │ +947 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +948 PATCH_TABLE *patchTable) const { │ │ │ │ │ +949 │ │ │ │ │ +950 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +951 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +952 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +953 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +954 numPatchCoords, │ │ │ │ │ +955 patchCoords->BindVBO(), │ │ │ │ │ +956 patchTable->GetPatchArrays(), │ │ │ │ │ +957 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +958 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +959 } │ │ │ │ │ +960 │ │ │ │ │ +995 template │ │ │ │ │ +_9_9_7 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +998 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +999 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1000 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1001 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1002 int numPatchCoords, │ │ │ │ │ +1003 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1004 PATCH_TABLE *patchTable) const { │ │ │ │ │ +1005 │ │ │ │ │ +1006 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1007 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1008 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +1009 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +1010 numPatchCoords, │ │ │ │ │ +1011 patchCoords->BindVBO(), │ │ │ │ │ +1012 patchTable->GetPatchArrays(), │ │ │ │ │ +1013 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +1014 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +1015 } │ │ │ │ │ +1016 │ │ │ │ │ +1069 template │ │ │ │ │ +_1_0_7_1 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +1072 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1073 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1074 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1075 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1076 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1077 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1078 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1079 int numPatchCoords, │ │ │ │ │ +1080 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1081 PATCH_TABLE *patchTable) const { │ │ │ │ │ +1082 │ │ │ │ │ +1083 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1084 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1085 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +1086 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +1087 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ +1088 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ +1089 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ +1090 numPatchCoords, │ │ │ │ │ +1091 patchCoords->BindVBO(), │ │ │ │ │ +1092 patchTable->GetPatchArrays(), │ │ │ │ │ +1093 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +1094 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +1095 } │ │ │ │ │ +1096 │ │ │ │ │ +_1_0_9_7 bool _E_v_a_l_P_a_t_c_h_e_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1098 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1099 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1100 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1101 int numPatchCoords, │ │ │ │ │ +1102 GLuint patchCoordsBuffer, │ │ │ │ │ +1103 const _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r &patchArrays, │ │ │ │ │ +1104 GLuint patchIndexBuffer, │ │ │ │ │ +1105 GLuint patchParamsBuffer) const; │ │ │ │ │ +1106 │ │ │ │ │ +_1_1_0_7 bool _E_v_a_l_P_a_t_c_h_e_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1108 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1109 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1110 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1111 GLuint duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1112 GLuint duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1113 GLuint dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1114 int numPatchCoords, │ │ │ │ │ +1115 GLuint patchCoordsBuffer, │ │ │ │ │ +1116 const _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r &patchArrays, │ │ │ │ │ +1117 GLuint patchIndexBuffer, │ │ │ │ │ +1118 GLuint patchParamsBuffer) const; │ │ │ │ │ +1119 │ │ │ │ │ +1152 template │ │ │ │ │ +_1_1_5_4 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1155 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1156 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1157 int numPatchCoords, │ │ │ │ │ +1158 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1159 PATCH_TABLE *patchTable, │ │ │ │ │ +1160 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1161 void * deviceContext = NULL) { │ │ │ │ │ +1162 │ │ │ │ │ +1163 if (instance) { │ │ │ │ │ +1164 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1165 srcBuffer, srcDesc, │ │ │ │ │ +1166 dstBuffer, dstDesc, │ │ │ │ │ +1167 numPatchCoords, patchCoords, │ │ │ │ │ +1168 patchTable); │ │ │ │ │ +1169 } else { │ │ │ │ │ +1170 // Create an instance on demand (slow) │ │ │ │ │ +1171 (void)deviceContext; // unused │ │ │ │ │ +1172 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1173 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1174 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ +1175 if (instance) { │ │ │ │ │ +1176 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1177 srcBuffer, srcDesc, │ │ │ │ │ +1178 dstBuffer, dstDesc, │ │ │ │ │ +1179 numPatchCoords, patchCoords, │ │ │ │ │ +1180 patchTable); │ │ │ │ │ +1181 delete instance; │ │ │ │ │ +1182 return r; │ │ │ │ │ +1183 } │ │ │ │ │ +1184 return false; │ │ │ │ │ +1185 } │ │ │ │ │ +1186 } │ │ │ │ │ +1187 │ │ │ │ │ +1212 template │ │ │ │ │ +_1_2_1_4 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1215 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1216 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1217 int numPatchCoords, │ │ │ │ │ +1218 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1219 PATCH_TABLE *patchTable) const { │ │ │ │ │ +1220 │ │ │ │ │ +1221 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1222 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1223 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1224 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1225 numPatchCoords, │ │ │ │ │ +1226 patchCoords->BindVBO(), │ │ │ │ │ +1227 patchTable->GetVaryingPatchArrays(), │ │ │ │ │ +1228 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +1229 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +1230 } │ │ │ │ │ +1231 │ │ │ │ │ +1276 template │ │ │ │ │ +_1_2_7_8 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1279 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1280 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1281 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1282 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1283 int numPatchCoords, │ │ │ │ │ +1284 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1285 PATCH_TABLE *patchTable, │ │ │ │ │ +1286 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1287 void * deviceContext = NULL) { │ │ │ │ │ +1288 │ │ │ │ │ +1289 if (instance) { │ │ │ │ │ +1290 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1291 srcBuffer, srcDesc, │ │ │ │ │ +1292 dstBuffer, dstDesc, │ │ │ │ │ +1293 duBuffer, duDesc, │ │ │ │ │ +1294 dvBuffer, dvDesc, │ │ │ │ │ +1295 numPatchCoords, patchCoords, │ │ │ │ │ +1296 patchTable); │ │ │ │ │ +1297 } else { │ │ │ │ │ +1298 // Create an instance on demand (slow) │ │ │ │ │ +1299 (void)deviceContext; // unused │ │ │ │ │ +1300 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1301 duDesc, dvDesc); │ │ │ │ │ +1302 if (instance) { │ │ │ │ │ +1303 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1304 srcBuffer, srcDesc, │ │ │ │ │ +1305 dstBuffer, dstDesc, │ │ │ │ │ +1306 duBuffer, duDesc, │ │ │ │ │ +1307 dvBuffer, dvDesc, │ │ │ │ │ +1308 numPatchCoords, patchCoords, │ │ │ │ │ +1309 patchTable); │ │ │ │ │ +1310 delete instance; │ │ │ │ │ +1311 return r; │ │ │ │ │ +1312 } │ │ │ │ │ +1313 return false; │ │ │ │ │ +1314 } │ │ │ │ │ +1315 } │ │ │ │ │ +1316 │ │ │ │ │ +1353 template │ │ │ │ │ +_1_3_5_5 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1356 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1357 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1358 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1359 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1360 int numPatchCoords, │ │ │ │ │ +1361 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1362 PATCH_TABLE *patchTable) const { │ │ │ │ │ +1363 │ │ │ │ │ +1364 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1365 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1366 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +1367 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +1368 numPatchCoords, │ │ │ │ │ +1369 patchCoords->BindVBO(), │ │ │ │ │ +1370 patchTable->GetVaryingPatchArrays(), │ │ │ │ │ +1371 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +1372 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +1373 } │ │ │ │ │ +1374 │ │ │ │ │ +1437 template │ │ │ │ │ +_1_4_3_9 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1440 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1441 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1442 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1443 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1444 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1445 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1446 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1447 int numPatchCoords, │ │ │ │ │ +1448 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1449 PATCH_TABLE *patchTable, │ │ │ │ │ +1450 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1451 void * deviceContext = NULL) { │ │ │ │ │ +1452 │ │ │ │ │ +1453 if (instance) { │ │ │ │ │ +1454 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1455 srcBuffer, srcDesc, │ │ │ │ │ +1456 dstBuffer, dstDesc, │ │ │ │ │ +1457 duBuffer, duDesc, │ │ │ │ │ +1458 dvBuffer, dvDesc, │ │ │ │ │ +1459 duuBuffer, duuDesc, │ │ │ │ │ +1460 duvBuffer, duvDesc, │ │ │ │ │ +1461 dvvBuffer, dvvDesc, │ │ │ │ │ +1462 numPatchCoords, patchCoords, │ │ │ │ │ +1463 patchTable); │ │ │ │ │ +1464 } else { │ │ │ │ │ +1465 // Create an instance on demand (slow) │ │ │ │ │ +1466 (void)deviceContext; // unused │ │ │ │ │ +1467 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1468 duDesc, dvDesc, │ │ │ │ │ +1469 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ +1470 if (instance) { │ │ │ │ │ +1471 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1472 srcBuffer, srcDesc, │ │ │ │ │ +1473 dstBuffer, dstDesc, │ │ │ │ │ +1474 duBuffer, duDesc, │ │ │ │ │ +1475 dvBuffer, dvDesc, │ │ │ │ │ +1476 duuBuffer, duuDesc, │ │ │ │ │ +1477 duvBuffer, duvDesc, │ │ │ │ │ +1478 dvvBuffer, dvvDesc, │ │ │ │ │ +1479 numPatchCoords, patchCoords, │ │ │ │ │ +1480 patchTable); │ │ │ │ │ +1481 delete instance; │ │ │ │ │ +1482 return r; │ │ │ │ │ +1483 } │ │ │ │ │ +1484 return false; │ │ │ │ │ +1485 } │ │ │ │ │ +1486 } │ │ │ │ │ +1487 │ │ │ │ │ +1542 template │ │ │ │ │ +_1_5_4_4 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +1545 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1546 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1547 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1548 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1549 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1550 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1551 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1552 int numPatchCoords, │ │ │ │ │ +1553 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1554 PATCH_TABLE *patchTable) const { │ │ │ │ │ +1555 │ │ │ │ │ +1556 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1557 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1558 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +1559 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +1560 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ +1561 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ +1562 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ +1563 numPatchCoords, │ │ │ │ │ +1564 patchCoords->BindVBO(), │ │ │ │ │ +1565 patchTable->GetVaryingPatchArrays(), │ │ │ │ │ +1566 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +1567 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +1568 } │ │ │ │ │ +1569 │ │ │ │ │ +1604 template │ │ │ │ │ +_1_6_0_6 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1607 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1608 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1609 int numPatchCoords, │ │ │ │ │ +1610 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1611 PATCH_TABLE *patchTable, │ │ │ │ │ +1612 int fvarChannel, │ │ │ │ │ +1613 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1614 void * deviceContext = NULL) { │ │ │ │ │ +1615 │ │ │ │ │ +1616 if (instance) { │ │ │ │ │ +1617 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1618 srcBuffer, srcDesc, │ │ │ │ │ +1619 dstBuffer, dstDesc, │ │ │ │ │ +1620 numPatchCoords, patchCoords, │ │ │ │ │ +1621 patchTable, fvarChannel); │ │ │ │ │ +1622 } else { │ │ │ │ │ +1623 // Create an instance on demand (slow) │ │ │ │ │ +1624 (void)deviceContext; // unused │ │ │ │ │ +1625 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1626 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1627 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ +1628 if (instance) { │ │ │ │ │ +1629 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1630 srcBuffer, srcDesc, │ │ │ │ │ +1631 dstBuffer, dstDesc, │ │ │ │ │ +1632 numPatchCoords, patchCoords, │ │ │ │ │ +1633 patchTable, fvarChannel); │ │ │ │ │ +1634 delete instance; │ │ │ │ │ +1635 return r; │ │ │ │ │ +1636 } │ │ │ │ │ +1637 return false; │ │ │ │ │ +1638 } │ │ │ │ │ +1639 } │ │ │ │ │ +1640 │ │ │ │ │ +1667 template │ │ │ │ │ +_1_6_6_9 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1670 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1671 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1672 int numPatchCoords, │ │ │ │ │ +1673 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1674 PATCH_TABLE *patchTable, │ │ │ │ │ +1675 int fvarChannel = 0) const { │ │ │ │ │ +1676 │ │ │ │ │ +1677 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1678 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1679 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1680 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +1681 numPatchCoords, │ │ │ │ │ +1682 patchCoords->BindVBO(), │ │ │ │ │ +1683 patchTable->GetFVarPatchArrays(fvarChannel), │ │ │ │ │ +1684 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +1685 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ +1686 } │ │ │ │ │ +1687 │ │ │ │ │ +1734 template │ │ │ │ │ +_1_7_3_6 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1737 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1738 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1739 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1740 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1741 int numPatchCoords, │ │ │ │ │ +1742 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1743 PATCH_TABLE *patchTable, │ │ │ │ │ +1744 int fvarChannel, │ │ │ │ │ +1745 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1746 void * deviceContext = NULL) { │ │ │ │ │ +1747 │ │ │ │ │ +1748 if (instance) { │ │ │ │ │ +1749 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1750 srcBuffer, srcDesc, │ │ │ │ │ +1751 dstBuffer, dstDesc, │ │ │ │ │ +1752 duBuffer, duDesc, │ │ │ │ │ +1753 dvBuffer, dvDesc, │ │ │ │ │ +1754 numPatchCoords, patchCoords, │ │ │ │ │ +1755 patchTable, fvarChannel); │ │ │ │ │ +1756 } else { │ │ │ │ │ +1757 // Create an instance on demand (slow) │ │ │ │ │ +1758 (void)deviceContext; // unused │ │ │ │ │ +1759 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1760 duDesc, dvDesc); │ │ │ │ │ +1761 if (instance) { │ │ │ │ │ +1762 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1763 srcBuffer, srcDesc, │ │ │ │ │ +1764 dstBuffer, dstDesc, │ │ │ │ │ +1765 duBuffer, duDesc, │ │ │ │ │ +1766 dvBuffer, dvDesc, │ │ │ │ │ +1767 numPatchCoords, patchCoords, │ │ │ │ │ +1768 patchTable, fvarChannel); │ │ │ │ │ +1769 delete instance; │ │ │ │ │ +1770 return r; │ │ │ │ │ +1771 } │ │ │ │ │ +1772 return false; │ │ │ │ │ +1773 } │ │ │ │ │ +1774 } │ │ │ │ │ +1775 │ │ │ │ │ +1814 template │ │ │ │ │ +_1_8_1_6 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1817 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1818 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1819 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1820 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1821 int numPatchCoords, │ │ │ │ │ +1822 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1823 PATCH_TABLE *patchTable, │ │ │ │ │ +1824 int fvarChannel = 0) const { │ │ │ │ │ +1825 │ │ │ │ │ +1826 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +1827 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +1828 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +1829 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +1830 numPatchCoords, │ │ │ │ │ +1831 patchCoords->BindVBO(), │ │ │ │ │ +1832 patchTable->GetFVarPatchArrays(fvarChannel), │ │ │ │ │ +1833 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +1834 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ +1835 } │ │ │ │ │ +1836 │ │ │ │ │ +1901 template │ │ │ │ │ +_1_9_0_3 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1904 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1905 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1906 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1907 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1908 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1909 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1910 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1911 int numPatchCoords, │ │ │ │ │ +1912 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1913 PATCH_TABLE *patchTable, │ │ │ │ │ +1914 int fvarChannel, │ │ │ │ │ +1915 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +1916 void * deviceContext = NULL) { │ │ │ │ │ +1917 │ │ │ │ │ +1918 if (instance) { │ │ │ │ │ +1919 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1920 srcBuffer, srcDesc, │ │ │ │ │ +1921 dstBuffer, dstDesc, │ │ │ │ │ +1922 duBuffer, duDesc, │ │ │ │ │ +1923 dvBuffer, dvDesc, │ │ │ │ │ +1924 duuBuffer, duuDesc, │ │ │ │ │ +1925 duvBuffer, duvDesc, │ │ │ │ │ +1926 dvvBuffer, dvvDesc, │ │ │ │ │ +1927 numPatchCoords, patchCoords, │ │ │ │ │ +1928 patchTable, fvarChannel); │ │ │ │ │ +1929 } else { │ │ │ │ │ +1930 // Create an instance on demand (slow) │ │ │ │ │ +1931 (void)deviceContext; // unused │ │ │ │ │ +1932 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +1933 duDesc, dvDesc, │ │ │ │ │ +1934 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ +1935 if (instance) { │ │ │ │ │ +1936 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1937 srcBuffer, srcDesc, │ │ │ │ │ +1938 dstBuffer, dstDesc, │ │ │ │ │ +1939 duBuffer, duDesc, │ │ │ │ │ +1940 dvBuffer, dvDesc, │ │ │ │ │ +1941 duuBuffer, duuDesc, │ │ │ │ │ +1942 duvBuffer, duvDesc, │ │ │ │ │ +1943 dvvBuffer, dvvDesc, │ │ │ │ │ +1944 numPatchCoords, patchCoords, │ │ │ │ │ +1945 patchTable, fvarChannel); │ │ │ │ │ +1946 delete instance; │ │ │ │ │ +1947 return r; │ │ │ │ │ +1948 } │ │ │ │ │ +1949 return false; │ │ │ │ │ +1950 } │ │ │ │ │ +1951 } │ │ │ │ │ +1952 │ │ │ │ │ +2009 template │ │ │ │ │ +_2_0_1_1 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +2012 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2013 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2014 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2015 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2016 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +2017 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +2018 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +2019 int numPatchCoords, │ │ │ │ │ +2020 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +2021 PATCH_TABLE *patchTable, │ │ │ │ │ +2022 int fvarChannel = 0) const { │ │ │ │ │ +2023 │ │ │ │ │ +2024 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ +2025 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ +2026 duBuffer->BindVBO(), duDesc, │ │ │ │ │ +2027 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ +2028 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ +2029 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ +2030 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ +2031 numPatchCoords, │ │ │ │ │ +2032 patchCoords->BindVBO(), │ │ │ │ │ +2033 patchTable->GetFVarPatchArrays(fvarChannel), │ │ │ │ │ +2034 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +2035 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ +2036 } │ │ │ │ │ +2037 │ │ │ │ │ +2043 │ │ │ │ │ +_2_0_4_6 bool _C_o_m_p_i_l_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2047 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2048 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2049 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2050 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2051 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +2052 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ +2053 │ │ │ │ │ +_2_0_5_5 static void _S_y_n_c_h_r_o_n_i_z_e(void *deviceContext); │ │ │ │ │ +2056 │ │ │ │ │ +2057private: │ │ │ │ │ +2058 struct _StencilKernel { │ │ │ │ │ +2059 _StencilKernel(); │ │ │ │ │ +2060 ~_StencilKernel(); │ │ │ │ │ +2061 bool Compile(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2062 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2063 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2064 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2065 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +2066 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +2067 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +2068 int workGroupSize); │ │ │ │ │ +2069 GLuint program; │ │ │ │ │ +2070 GLuint uniformStart; │ │ │ │ │ +2071 GLuint uniformEnd; │ │ │ │ │ +2072 GLuint uniformSrcOffset; │ │ │ │ │ +2073 GLuint uniformDstOffset; │ │ │ │ │ +2074 GLuint uniformDuDesc; │ │ │ │ │ +2075 GLuint uniformDvDesc; │ │ │ │ │ +2076 GLuint uniformDuuDesc; │ │ │ │ │ +2077 GLuint uniformDuvDesc; │ │ │ │ │ +2078 GLuint uniformDvvDesc; │ │ │ │ │ +2079 } _stencilKernel; │ │ │ │ │ +2080 │ │ │ │ │ +2081 struct _PatchKernel { │ │ │ │ │ +2082 _PatchKernel(); │ │ │ │ │ +2083 ~_PatchKernel(); │ │ │ │ │ +2084 bool Compile(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +2085 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +2086 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +2087 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +2088 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +2089 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +2090 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +2091 int workGroupSize); │ │ │ │ │ +2092 GLuint program; │ │ │ │ │ +2093 GLuint uniformSrcOffset; │ │ │ │ │ +2094 GLuint uniformDstOffset; │ │ │ │ │ +2095 GLuint uniformPatchArray; │ │ │ │ │ +2096 GLuint uniformDuDesc; │ │ │ │ │ +2097 GLuint uniformDvDesc; │ │ │ │ │ +2098 GLuint uniformDuuDesc; │ │ │ │ │ +2099 GLuint uniformDuvDesc; │ │ │ │ │ +2100 GLuint uniformDvvDesc; │ │ │ │ │ +2101 } _patchKernel; │ │ │ │ │ +2102 │ │ │ │ │ +2103 int _workGroupSize; │ │ │ │ │ +2104 GLuint _patchArraysSSBO; │ │ │ │ │ +2105}; │ │ │ │ │ +2106 │ │ │ │ │ +2107} // end namespace Osd │ │ │ │ │ +2108 │ │ │ │ │ +2109} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +2110using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +2111 │ │ │ │ │ +2112} // end namespace OpenSubdiv │ │ │ │ │ +2113 │ │ │ │ │ +2114 │ │ │ │ │ +2115#endif // OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -Concrete vertex buffer class for Cpu subdivision and DirectX drawing. │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_4_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static CpuD3D11VertexBuffer * Create(int numElements, int numVertices, │ │ │ │ │ -ID3D11DeviceContext *deviceContext) │ │ │ │ │ -Creator. Returns NULL if error. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -CpuD3D11VertexBuffer(int numElements, int numVertices) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r │ │ │ │ │ +std::vector< PatchArray > PatchArrayVector │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_3_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ +DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ +data buffers.... │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ +GL stencil table (Shader Storage buffer) │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetDuvWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ +GLStencilTableSSBO(Far::LimitStencilTable const *limitStencilTable) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetDuWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_~_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ +~GLStencilTableSSBO() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ +int GetNumStencils() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetIndicesBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetOffsetsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ +GLStencilTableSSBO(Far::StencilTable const *stencilTable) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetDvvWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_S_i_z_e_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetSizesBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_C_r_e_a_t_e │ │ │ │ │ +static GLStencilTableSSBO * Create(Far::LimitStencilTable const │ │ │ │ │ +*limitStencilTable, void *deviceContext=NULL) │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetDuuWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ +GLuint GetDvWeightsBuffer() const │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_C_r_e_a_t_e │ │ │ │ │ +static GLStencilTableSSBO * Create(Far::StencilTable const *stencilTable, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_2_1_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ +DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator │ │ │ │ │ +const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_7_3_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, STENCIL_TABLE const *stencilTable) const │ │ │ │ │ +Generic stencil function. │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_4_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, │ │ │ │ │ +GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_1_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ +fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_6_0_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable) const │ │ │ │ │ +Generic stencil function. │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_0_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_2_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_I_n_s_t_a_n_t_i_a_t_a_b_l_e │ │ │ │ │ +bool Instantiatable │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ +dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ +const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint │ │ │ │ │ +duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor │ │ │ │ │ +const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, int │ │ │ │ │ +numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, │ │ │ │ │ +GLuint patchIndexBuffer, GLuint patchParamsBuffer) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_~_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +~GLComputeEvaluator() │ │ │ │ │ +Destructor. note that the GL context must be made current. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ +Generic limit eval function with derivatives. This function has a same │ │ │ │ │ +signature as other device kern... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_0_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ +GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic static stencil function. This function has a same signature as other │ │ │ │ │ +device kernels have so t... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_2_3_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ +dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ +const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint │ │ │ │ │ +duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor │ │ │ │ │ +const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, GLuint │ │ │ │ │ +sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, │ │ │ │ │ +GLuint duWeightsBuffer, GLuint dvWeightsBuffer, GLuint duuWeightsBuffer, GLuint │ │ │ │ │ +duvWeightsBuffer, GLuint dvvWeightsBuffer, int start, int end) const │ │ │ │ │ +Dispatch the GLSL compute kernel on GPU asynchronously returns false if the │ │ │ │ │ +kernel hasn't been compil... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ +const *stencilTable, GLComputeEvaluator const *instance, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +Generic static stencil function. This function has a same signature as other │ │ │ │ │ +device kernels have so t... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator │ │ │ │ │ +const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_4_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ +DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, │ │ │ │ │ +GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_9_0_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_5_4_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_8_1_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_4_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +GLComputeEvaluator() │ │ │ │ │ Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_E_l_e_m_e_n_t_s │ │ │ │ │ -int GetNumElements() const │ │ │ │ │ -Returns how many elements defined in this vertex buffer. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_U_p_d_a_t_e_D_a_t_a │ │ │ │ │ -void UpdateData(const float *src, int startVertex, int numVertices, void │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable) const │ │ │ │ │ +Generic limit eval function with derivatives. This function has a same │ │ │ │ │ +signature as other device kern... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_9_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator │ │ │ │ │ +const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_6_9_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const │ │ │ │ │ +*stencilTable) const │ │ │ │ │ +Generic stencil function. │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_3_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ +dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ +const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, int │ │ │ │ │ +numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, │ │ │ │ │ +GLuint patchIndexBuffer, GLuint patchParamsBuffer) const │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) │ │ │ │ │ +const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_2_0_1_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ +BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ +BufferDescriptor const &dvDesc, void *deviceContext=NULL) │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ +dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ +const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint │ │ │ │ │ +sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, │ │ │ │ │ +GLuint duWeightsBuffer, GLuint dvWeightsBuffer, int start, int end) const │ │ │ │ │ +Dispatch the GLSL compute kernel on GPU asynchronously returns false if the │ │ │ │ │ +kernel hasn't been compil... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ +GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ +Generic static stencil function. This function has a same signature as other │ │ │ │ │ +device kernels have so t... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_3_2_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ +static void Synchronize(void *deviceContext) │ │ │ │ │ +Wait the dispatched kernel finishes. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_o_m_p_i_l_e │ │ │ │ │ +bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, │ │ │ │ │ +BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ +&dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), │ │ │ │ │ +BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ +&dvvDesc=BufferDescriptor()) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_3_5_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ +BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ +BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, │ │ │ │ │ +BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_1_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ +fvarChannel=0) const │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_6_6_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void │ │ │ │ │ *deviceContext=NULL) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_G_e_t_N_u_m_V_e_r_t_i_c_e_s │ │ │ │ │ -int GetNumVertices() const │ │ │ │ │ -Returns how many vertices allocated in this vertex buffer. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_D_3_D_1_1_B_u_f_f_e_r │ │ │ │ │ -ID3D11Buffer * BindD3D11Buffer(ID3D11DeviceContext *deviceContext) │ │ │ │ │ -Returns the D3D11 buffer object. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_C_p_u_B_u_f_f_e_r │ │ │ │ │ -float * BindCpuBuffer() │ │ │ │ │ -Returns the address of CPU buffer. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_a_l_l_o_c_a_t_e │ │ │ │ │ -bool allocate(ID3D11Device *device) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_: │ │ │ │ │ -_~_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r │ │ │ │ │ -virtual ~CpuD3D11VertexBuffer() │ │ │ │ │ -Destructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_:_:_B_i_n_d_V_B_O │ │ │ │ │ -ID3D11Buffer * BindVBO(ID3D11DeviceContext *deviceContext) │ │ │ │ │ -Returns the D3D11 buffer object (for Osd::Mesh interface) │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h_:_7_5 │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_8_7_0 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _c_p_u_D_3_D_1_1_V_e_r_t_e_x_B_u_f_f_e_r_._h │ │ │ │ │ + * _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00848.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/glComputeEvaluator.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/d3d11ComputeEvaluator.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,30 +90,28 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
glComputeEvaluator.h File Reference
│ │ │ │ +
d3d11ComputeEvaluator.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/opengl.h"
│ │ │ │ -#include "../osd/types.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  GLStencilTableSSBO
 GL stencil table (Shader Storage buffer) More...
class  D3D11StencilTable
 D3D11 stencil table. More...
 
class  GLComputeEvaluator
class  D3D11ComputeEvaluator
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -124,13 +122,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,30 +1,28 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -glComputeEvaluator.h File Reference │ │ │ │ │ +d3d11ComputeEvaluator.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_o_p_e_n_g_l_._h" │ │ │ │ │ -#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ #include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ -  GL stencil table (Shader Storage buffer) _M_o_r_e_._._. │ │ │ │ │ +class   _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +  D3D11 stencil table. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -class   _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +class   _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00848.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,4 +1,4 @@ │ │ │ │ │ var a00848 = [ │ │ │ │ │ - ["GLStencilTableSSBO", "a01217.html", "a01217"], │ │ │ │ │ - ["GLComputeEvaluator", "a01221.html", "a01221"] │ │ │ │ │ + ["D3D11StencilTable", "a01197.html", "a01197"], │ │ │ │ │ + ["D3D11ComputeEvaluator", "a01201.html", "a01201"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00848_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/glComputeEvaluator.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/d3d11ComputeEvaluator.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
glComputeEvaluator.h
│ │ │ │ +
d3d11ComputeEvaluator.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,1132 +119,225 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │
29
│ │ │ │ -
30#include "../osd/opengl.h"
│ │ │ │ -
31#include "../osd/types.h"
│ │ │ │ -
32#include "../osd/bufferDescriptor.h"
│ │ │ │ -
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Far {
│ │ │ │ -
38 class PatchTable;
│ │ │ │ -
39 class StencilTable;
│ │ │ │ -
40 class LimitStencilTable;
│ │ │ │ -
41}
│ │ │ │ +
30struct ID3D11DeviceContext;
│ │ │ │ +
31struct ID3D11Buffer;
│ │ │ │ +
32struct ID3D11ComputeShader;
│ │ │ │ +
33struct ID3D11ClassLinkage;
│ │ │ │ +
34struct ID3D11ClassInstance;
│ │ │ │ +
35struct ID3D11ShaderResourceView;
│ │ │ │ +
36struct ID3D11UnorderedAccessView;
│ │ │ │ +
37
│ │ │ │ +
38#include "../osd/bufferDescriptor.h"
│ │ │ │ +
39
│ │ │ │ +
40namespace OpenSubdiv {
│ │ │ │ +
41namespace OPENSUBDIV_VERSION {
│ │ │ │
42
│ │ │ │ -
43namespace Osd {
│ │ │ │ -
44
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
52public:
│ │ │ │ -
│ │ │ │ -
53 static GLStencilTableSSBO *Create(Far::StencilTable const *stencilTable,
│ │ │ │ -
54 void *deviceContext = NULL) {
│ │ │ │ -
55 (void)deviceContext; // unused
│ │ │ │ -
56 return new GLStencilTableSSBO(stencilTable);
│ │ │ │ -
57 }
│ │ │ │ +
43namespace Far {
│ │ │ │ +
44 class StencilTable;
│ │ │ │ +
45}
│ │ │ │ +
46
│ │ │ │ +
47namespace Osd {
│ │ │ │ +
48
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
57public:
│ │ │ │ +
58 template <typename DEVICE_CONTEXT>
│ │ │ │ +
│ │ │ │ +
59 static D3D11StencilTable *Create(Far::StencilTable const *stencilTable,
│ │ │ │ +
60 DEVICE_CONTEXT context) {
│ │ │ │ +
61 return new D3D11StencilTable(stencilTable, context->GetDeviceContext());
│ │ │ │ +
62 }
│ │ │ │ +
│ │ │ │ +
63
│ │ │ │ +
│ │ │ │ +
64 static D3D11StencilTable *Create(Far::StencilTable const *stencilTable,
│ │ │ │ +
65 ID3D11DeviceContext *deviceContext) {
│ │ │ │ +
66 return new D3D11StencilTable(stencilTable, deviceContext);
│ │ │ │ +
67 }
│ │ │ │
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
59 Far::LimitStencilTable const *limitStencilTable,
│ │ │ │ -
60 void *deviceContext = NULL) {
│ │ │ │ -
61 (void)deviceContext; // unused
│ │ │ │ -
62 return new GLStencilTableSSBO(limitStencilTable);
│ │ │ │ -
63 }
│ │ │ │ -
│ │ │ │ -
64
│ │ │ │ -
65 explicit GLStencilTableSSBO(Far::StencilTable const *stencilTable);
│ │ │ │ -
66 explicit GLStencilTableSSBO(Far::LimitStencilTable const *limitStencilTable);
│ │ │ │ - │ │ │ │
68
│ │ │ │ -
69 // interfaces needed for GLSLComputeKernel
│ │ │ │ -
70 GLuint GetSizesBuffer() const { return _sizes; }
│ │ │ │ -
71 GLuint GetOffsetsBuffer() const { return _offsets; }
│ │ │ │ -
72 GLuint GetIndicesBuffer() const { return _indices; }
│ │ │ │ -
73 GLuint GetWeightsBuffer() const { return _weights; }
│ │ │ │ -
74 GLuint GetDuWeightsBuffer() const { return _duWeights; }
│ │ │ │ -
75 GLuint GetDvWeightsBuffer() const { return _dvWeights; }
│ │ │ │ -
76 GLuint GetDuuWeightsBuffer() const { return _duuWeights; }
│ │ │ │ -
77 GLuint GetDuvWeightsBuffer() const { return _duvWeights; }
│ │ │ │ -
78 GLuint GetDvvWeightsBuffer() const { return _dvvWeights; }
│ │ │ │ -
79 int GetNumStencils() const { return _numStencils; }
│ │ │ │ + │ │ │ │ +
70 ID3D11DeviceContext *deviceContext);
│ │ │ │ +
71
│ │ │ │ + │ │ │ │ +
73
│ │ │ │ +
74 // interfaces needed for D3D11ComputeEvaluator
│ │ │ │ +
75 ID3D11ShaderResourceView *GetSizesSRV() const { return _sizes; }
│ │ │ │ +
76 ID3D11ShaderResourceView *GetOffsetsSRV() const { return _offsets; }
│ │ │ │ +
77 ID3D11ShaderResourceView *GetIndicesSRV() const { return _indices; }
│ │ │ │ +
78 ID3D11ShaderResourceView *GetWeightsSRV() const { return _weights; }
│ │ │ │ +
79 int GetNumStencils() const { return _numStencils; }
│ │ │ │
80
│ │ │ │
81private:
│ │ │ │ -
82 GLuint _sizes;
│ │ │ │ -
83 GLuint _offsets;
│ │ │ │ -
84 GLuint _indices;
│ │ │ │ -
85 GLuint _weights;
│ │ │ │ -
86 GLuint _duWeights;
│ │ │ │ -
87 GLuint _dvWeights;
│ │ │ │ -
88 GLuint _duuWeights;
│ │ │ │ -
89 GLuint _duvWeights;
│ │ │ │ -
90 GLuint _dvvWeights;
│ │ │ │ +
82 ID3D11ShaderResourceView *_sizes;
│ │ │ │ +
83 ID3D11ShaderResourceView *_offsets;
│ │ │ │ +
84 ID3D11ShaderResourceView *_indices;
│ │ │ │ +
85 ID3D11ShaderResourceView *_weights;
│ │ │ │ +
86 ID3D11Buffer *_sizesBuffer;
│ │ │ │ +
87 ID3D11Buffer *_offsetsBuffer;
│ │ │ │ +
88 ID3D11Buffer *_indicesBuffer;
│ │ │ │ +
89 ID3D11Buffer *_weightsBuffer;
│ │ │ │ +
90
│ │ │ │
91 int _numStencils;
│ │ │ │
92};
│ │ │ │
│ │ │ │
93
│ │ │ │
94// ---------------------------------------------------------------------------
│ │ │ │
95
│ │ │ │
│ │ │ │ - │ │ │ │ + │ │ │ │
97public:
│ │ │ │ -
98 typedef bool Instantiatable;
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
100 BufferDescriptor const &dstDesc,
│ │ │ │ -
101 BufferDescriptor const &duDesc,
│ │ │ │ -
102 BufferDescriptor const &dvDesc,
│ │ │ │ -
103 void * deviceContext = NULL) {
│ │ │ │ -
104 return Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
108 deviceContext);
│ │ │ │ -
109 }
│ │ │ │ -
│ │ │ │ -
110
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
112 BufferDescriptor const &dstDesc,
│ │ │ │ -
113 BufferDescriptor const &duDesc,
│ │ │ │ -
114 BufferDescriptor const &dvDesc,
│ │ │ │ -
115 BufferDescriptor const &duuDesc,
│ │ │ │ -
116 BufferDescriptor const &duvDesc,
│ │ │ │ -
117 BufferDescriptor const &dvvDesc,
│ │ │ │ -
118 void * deviceContext = NULL) {
│ │ │ │ -
119 (void)deviceContext; // not used
│ │ │ │ -
120 GLComputeEvaluator *instance = new GLComputeEvaluator();
│ │ │ │ -
121 if (instance->Compile(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ -
122 duuDesc, duvDesc, dvvDesc))
│ │ │ │ -
123 return instance;
│ │ │ │ -
124 delete instance;
│ │ │ │ -
125 return NULL;
│ │ │ │ -
126 }
│ │ │ │ -
│ │ │ │ -
127
│ │ │ │ - │ │ │ │ -
130
│ │ │ │ - │ │ │ │ -
133
│ │ │ │ -
139
│ │ │ │ -
167 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
168 static bool EvalStencils(
│ │ │ │ -
169 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
170 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
171 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
172 GLComputeEvaluator const *instance,
│ │ │ │ -
173 void * deviceContext = NULL) {
│ │ │ │ -
174
│ │ │ │ -
175 if (instance) {
│ │ │ │ -
176 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
177 dstBuffer, dstDesc,
│ │ │ │ -
178 stencilTable);
│ │ │ │ -
179 } else {
│ │ │ │ -
180 // Create an instance on demand (slow)
│ │ │ │ -
181 (void)deviceContext; // unused
│ │ │ │ -
182 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
185 if (instance) {
│ │ │ │ -
186 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
187 dstBuffer, dstDesc,
│ │ │ │ -
188 stencilTable);
│ │ │ │ -
189 delete instance;
│ │ │ │ -
190 return r;
│ │ │ │ -
191 }
│ │ │ │ -
192 return false;
│ │ │ │ -
193 }
│ │ │ │ -
194 }
│ │ │ │ -
│ │ │ │ -
195
│ │ │ │ -
235 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
236 static bool EvalStencils(
│ │ │ │ -
237 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
238 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
239 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
240 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
241 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
242 GLComputeEvaluator const *instance,
│ │ │ │ -
243 void * deviceContext = NULL) {
│ │ │ │ -
244
│ │ │ │ -
245 if (instance) {
│ │ │ │ -
246 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
247 dstBuffer, dstDesc,
│ │ │ │ -
248 duBuffer, duDesc,
│ │ │ │ -
249 dvBuffer, dvDesc,
│ │ │ │ -
250 stencilTable);
│ │ │ │ -
251 } else {
│ │ │ │ -
252 // Create an instance on demand (slow)
│ │ │ │ -
253 (void)deviceContext; // unused
│ │ │ │ -
254 instance = Create(srcDesc, dstDesc, duDesc, dvDesc);
│ │ │ │ -
255 if (instance) {
│ │ │ │ -
256 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
257 dstBuffer, dstDesc,
│ │ │ │ -
258 duBuffer, duDesc,
│ │ │ │ -
259 dvBuffer, dvDesc,
│ │ │ │ -
260 stencilTable);
│ │ │ │ -
261 delete instance;
│ │ │ │ -
262 return r;
│ │ │ │ -
263 }
│ │ │ │ -
264 return false;
│ │ │ │ -
265 }
│ │ │ │ -
266 }
│ │ │ │ -
│ │ │ │ -
267
│ │ │ │ -
325 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
326 static bool EvalStencils(
│ │ │ │ -
327 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
328 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
329 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
330 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
331 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
332 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
333 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
334 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
335 GLComputeEvaluator const *instance,
│ │ │ │ -
336 void * deviceContext = NULL) {
│ │ │ │ -
337
│ │ │ │ -
338 if (instance) {
│ │ │ │ -
339 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
340 dstBuffer, dstDesc,
│ │ │ │ -
341 duBuffer, duDesc,
│ │ │ │ -
342 dvBuffer, dvDesc,
│ │ │ │ -
343 duuBuffer, duuDesc,
│ │ │ │ -
344 duvBuffer, duvDesc,
│ │ │ │ -
345 dvvBuffer, dvvDesc,
│ │ │ │ -
346 stencilTable);
│ │ │ │ -
347 } else {
│ │ │ │ -
348 // Create an instance on demand (slow)
│ │ │ │ -
349 (void)deviceContext; // unused
│ │ │ │ -
350 instance = Create(srcDesc, dstDesc, duDesc, dvDesc,
│ │ │ │ -
351 duuDesc, duvDesc, dvvDesc);
│ │ │ │ -
352 if (instance) {
│ │ │ │ -
353 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ -
354 dstBuffer, dstDesc,
│ │ │ │ -
355 duBuffer, duDesc,
│ │ │ │ -
356 dvBuffer, dvDesc,
│ │ │ │ -
357 duuBuffer, duuDesc,
│ │ │ │ -
358 duvBuffer, duvDesc,
│ │ │ │ -
359 dvvBuffer, dvvDesc,
│ │ │ │ -
360 stencilTable);
│ │ │ │ -
361 delete instance;
│ │ │ │ -
362 return r;
│ │ │ │ -
363 }
│ │ │ │ -
364 return false;
│ │ │ │ -
365 }
│ │ │ │ -
366 }
│ │ │ │ -
│ │ │ │ -
367
│ │ │ │ -
385 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
387 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
388 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
389 STENCIL_TABLE const *stencilTable) const {
│ │ │ │ -
390 return EvalStencils(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
391 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
392 0, BufferDescriptor(),
│ │ │ │ -
393 0, BufferDescriptor(),
│ │ │ │ -
394 stencilTable->GetSizesBuffer(),
│ │ │ │ -
395 stencilTable->GetOffsetsBuffer(),
│ │ │ │ -
396 stencilTable->GetIndicesBuffer(),
│ │ │ │ -
397 stencilTable->GetWeightsBuffer(),
│ │ │ │ -
398 0,
│ │ │ │ -
399 0,
│ │ │ │ -
400 /* start = */ 0,
│ │ │ │ -
401 /* end = */ stencilTable->GetNumStencils());
│ │ │ │ -
402 }
│ │ │ │ -
│ │ │ │ -
403
│ │ │ │ -
433 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
435 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
436 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
437 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
438 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
439 STENCIL_TABLE const *stencilTable) const {
│ │ │ │ -
440 return EvalStencils(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
441 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
442 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
443 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
444 stencilTable->GetSizesBuffer(),
│ │ │ │ -
445 stencilTable->GetOffsetsBuffer(),
│ │ │ │ -
446 stencilTable->GetIndicesBuffer(),
│ │ │ │ -
447 stencilTable->GetWeightsBuffer(),
│ │ │ │ -
448 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ -
449 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ -
450 /* start = */ 0,
│ │ │ │ -
451 /* end = */ stencilTable->GetNumStencils());
│ │ │ │ -
452 }
│ │ │ │ -
│ │ │ │ -
453
│ │ │ │ -
501 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
503 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
504 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
505 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
506 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
507 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
508 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
509 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
510 STENCIL_TABLE const *stencilTable) const {
│ │ │ │ -
511 return EvalStencils(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
512 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
513 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
514 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
515 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ -
516 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ -
517 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ -
518 stencilTable->GetSizesBuffer(),
│ │ │ │ -
519 stencilTable->GetOffsetsBuffer(),
│ │ │ │ -
520 stencilTable->GetIndicesBuffer(),
│ │ │ │ -
521 stencilTable->GetWeightsBuffer(),
│ │ │ │ -
522 stencilTable->GetDuWeightsBuffer(),
│ │ │ │ -
523 stencilTable->GetDvWeightsBuffer(),
│ │ │ │ -
524 stencilTable->GetDuuWeightsBuffer(),
│ │ │ │ -
525 stencilTable->GetDuvWeightsBuffer(),
│ │ │ │ -
526 stencilTable->GetDvvWeightsBuffer(),
│ │ │ │ -
527 /* start = */ 0,
│ │ │ │ -
528 /* end = */ stencilTable->GetNumStencils());
│ │ │ │ -
529 }
│ │ │ │ -
│ │ │ │ -
530
│ │ │ │ -
566 bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
567 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
568 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
569 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
570 GLuint sizesBuffer,
│ │ │ │ -
571 GLuint offsetsBuffer,
│ │ │ │ -
572 GLuint indicesBuffer,
│ │ │ │ -
573 GLuint weightsBuffer,
│ │ │ │ -
574 GLuint duWeightsBuffer,
│ │ │ │ -
575 GLuint dvWeightsBuffer,
│ │ │ │ -
576 int start,
│ │ │ │ -
577 int end) const;
│ │ │ │ -
578
│ │ │ │ -
632 bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
633 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
634 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
635 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
636 GLuint duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
637 GLuint duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
638 GLuint dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
639 GLuint sizesBuffer,
│ │ │ │ -
640 GLuint offsetsBuffer,
│ │ │ │ -
641 GLuint indicesBuffer,
│ │ │ │ -
642 GLuint weightsBuffer,
│ │ │ │ -
643 GLuint duWeightsBuffer,
│ │ │ │ -
644 GLuint dvWeightsBuffer,
│ │ │ │ -
645 GLuint duuWeightsBuffer,
│ │ │ │ -
646 GLuint duvWeightsBuffer,
│ │ │ │ -
647 GLuint dvvWeightsBuffer,
│ │ │ │ -
648 int start,
│ │ │ │ -
649 int end) const;
│ │ │ │ -
650
│ │ │ │ -
656
│ │ │ │ -
689 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
690 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ -
691 static bool EvalPatches(
│ │ │ │ -
692 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
693 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
694 int numPatchCoords,
│ │ │ │ -
695 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
696 PATCH_TABLE *patchTable,
│ │ │ │ -
697 GLComputeEvaluator const *instance,
│ │ │ │ -
698 void * deviceContext = NULL) {
│ │ │ │ -
699
│ │ │ │ -
700 if (instance) {
│ │ │ │ -
701 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
702 dstBuffer, dstDesc,
│ │ │ │ -
703 numPatchCoords, patchCoords,
│ │ │ │ -
704 patchTable);
│ │ │ │ -
705 } else {
│ │ │ │ -
706 // Create an instance on demand (slow)
│ │ │ │ -
707 (void)deviceContext; // unused
│ │ │ │ -
708 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
711 if (instance) {
│ │ │ │ -
712 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
713 dstBuffer, dstDesc,
│ │ │ │ -
714 numPatchCoords, patchCoords,
│ │ │ │ -
715 patchTable);
│ │ │ │ -
716 delete instance;
│ │ │ │ -
717 return r;
│ │ │ │ -
718 }
│ │ │ │ -
719 return false;
│ │ │ │ -
720 }
│ │ │ │ -
721 }
│ │ │ │ -
│ │ │ │ -
722
│ │ │ │ -
767 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
768 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ -
769 static bool EvalPatches(
│ │ │ │ -
770 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
771 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
772 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
773 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
774 int numPatchCoords,
│ │ │ │ -
775 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
776 PATCH_TABLE *patchTable,
│ │ │ │ -
777 GLComputeEvaluator const *instance,
│ │ │ │ -
778 void * deviceContext = NULL) {
│ │ │ │ -
779
│ │ │ │ -
780 if (instance) {
│ │ │ │ -
781 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
782 dstBuffer, dstDesc,
│ │ │ │ -
783 duBuffer, duDesc,
│ │ │ │ -
784 dvBuffer, dvDesc,
│ │ │ │ -
785 numPatchCoords, patchCoords,
│ │ │ │ -
786 patchTable);
│ │ │ │ -
787 } else {
│ │ │ │ -
788 // Create an instance on demand (slow)
│ │ │ │ -
789 (void)deviceContext; // unused
│ │ │ │ -
790 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
791 duDesc, dvDesc);
│ │ │ │ -
792 if (instance) {
│ │ │ │ -
793 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
794 dstBuffer, dstDesc,
│ │ │ │ -
795 duBuffer, duDesc,
│ │ │ │ -
796 dvBuffer, dvDesc,
│ │ │ │ -
797 numPatchCoords, patchCoords,
│ │ │ │ -
798 patchTable);
│ │ │ │ -
799 delete instance;
│ │ │ │ -
800 return r;
│ │ │ │ -
801 }
│ │ │ │ -
802 return false;
│ │ │ │ -
803 }
│ │ │ │ -
804 }
│ │ │ │ -
│ │ │ │ -
805
│ │ │ │ -
868 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
869 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ -
870 static bool EvalPatches(
│ │ │ │ -
871 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
872 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
873 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
874 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
875 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
876 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
877 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
878 int numPatchCoords,
│ │ │ │ -
879 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
880 PATCH_TABLE *patchTable,
│ │ │ │ -
881 GLComputeEvaluator const *instance,
│ │ │ │ -
882 void * deviceContext = NULL) {
│ │ │ │ -
883
│ │ │ │ -
884 if (instance) {
│ │ │ │ -
885 return instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
886 dstBuffer, dstDesc,
│ │ │ │ -
887 duBuffer, duDesc,
│ │ │ │ -
888 dvBuffer, dvDesc,
│ │ │ │ -
889 duuBuffer, duuDesc,
│ │ │ │ -
890 duvBuffer, duvDesc,
│ │ │ │ -
891 dvvBuffer, dvvDesc,
│ │ │ │ -
892 numPatchCoords, patchCoords,
│ │ │ │ -
893 patchTable);
│ │ │ │ -
894 } else {
│ │ │ │ -
895 // Create an instance on demand (slow)
│ │ │ │ -
896 (void)deviceContext; // unused
│ │ │ │ -
897 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
898 duDesc, dvDesc,
│ │ │ │ -
899 duuDesc, duvDesc, dvvDesc);
│ │ │ │ -
900 if (instance) {
│ │ │ │ -
901 bool r = instance->EvalPatches(srcBuffer, srcDesc,
│ │ │ │ -
902 dstBuffer, dstDesc,
│ │ │ │ -
903 duBuffer, duDesc,
│ │ │ │ -
904 dvBuffer, dvDesc,
│ │ │ │ -
905 duuBuffer, duuDesc,
│ │ │ │ -
906 duvBuffer, duvDesc,
│ │ │ │ -
907 dvvBuffer, dvvDesc,
│ │ │ │ -
908 numPatchCoords, patchCoords,
│ │ │ │ -
909 patchTable);
│ │ │ │ -
910 delete instance;
│ │ │ │ -
911 return r;
│ │ │ │ -
912 }
│ │ │ │ -
913 return false;
│ │ │ │ -
914 }
│ │ │ │ -
915 }
│ │ │ │ -
│ │ │ │ -
916
│ │ │ │ -
941 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
942 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
944 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
945 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
946 int numPatchCoords,
│ │ │ │ -
947 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
948 PATCH_TABLE *patchTable) const {
│ │ │ │ -
949
│ │ │ │ -
950 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
951 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
952 0, BufferDescriptor(),
│ │ │ │ -
953 0, BufferDescriptor(),
│ │ │ │ -
954 numPatchCoords,
│ │ │ │ -
955 patchCoords->BindVBO(),
│ │ │ │ -
956 patchTable->GetPatchArrays(),
│ │ │ │ -
957 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
958 patchTable->GetPatchParamBuffer());
│ │ │ │ -
959 }
│ │ │ │ -
│ │ │ │ -
960
│ │ │ │ -
995 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
996 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
998 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
999 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1000 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1001 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1002 int numPatchCoords,
│ │ │ │ -
1003 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1004 PATCH_TABLE *patchTable) const {
│ │ │ │ -
1005
│ │ │ │ -
1006 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1007 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1008 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
1009 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
1010 numPatchCoords,
│ │ │ │ -
1011 patchCoords->BindVBO(),
│ │ │ │ -
1012 patchTable->GetPatchArrays(),
│ │ │ │ -
1013 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
1014 patchTable->GetPatchParamBuffer());
│ │ │ │ -
1015 }
│ │ │ │ -
│ │ │ │ -
1016
│ │ │ │ -
1069 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1070 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1072 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1073 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1074 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1075 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1076 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1077 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1078 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1079 int numPatchCoords,
│ │ │ │ -
1080 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1081 PATCH_TABLE *patchTable) const {
│ │ │ │ -
1082
│ │ │ │ -
1083 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1084 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1085 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
1086 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
1087 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ -
1088 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ -
1089 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ -
1090 numPatchCoords,
│ │ │ │ -
1091 patchCoords->BindVBO(),
│ │ │ │ -
1092 patchTable->GetPatchArrays(),
│ │ │ │ -
1093 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
1094 patchTable->GetPatchParamBuffer());
│ │ │ │ -
1095 }
│ │ │ │ -
│ │ │ │ -
1096
│ │ │ │ -
1097 bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1098 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1099 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1100 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1101 int numPatchCoords,
│ │ │ │ -
1102 GLuint patchCoordsBuffer,
│ │ │ │ -
1103 const PatchArrayVector &patchArrays,
│ │ │ │ -
1104 GLuint patchIndexBuffer,
│ │ │ │ -
1105 GLuint patchParamsBuffer) const;
│ │ │ │ -
1106
│ │ │ │ -
1107 bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1108 GLuint dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1109 GLuint duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1110 GLuint dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1111 GLuint duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1112 GLuint duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1113 GLuint dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1114 int numPatchCoords,
│ │ │ │ -
1115 GLuint patchCoordsBuffer,
│ │ │ │ -
1116 const PatchArrayVector &patchArrays,
│ │ │ │ -
1117 GLuint patchIndexBuffer,
│ │ │ │ -
1118 GLuint patchParamsBuffer) const;
│ │ │ │ -
1119
│ │ │ │ -
1152 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1153 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1155 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1156 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1157 int numPatchCoords,
│ │ │ │ -
1158 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1159 PATCH_TABLE *patchTable,
│ │ │ │ -
1160 GLComputeEvaluator const *instance,
│ │ │ │ -
1161 void * deviceContext = NULL) {
│ │ │ │ -
1162
│ │ │ │ -
1163 if (instance) {
│ │ │ │ -
1164 return instance->EvalPatchesVarying(
│ │ │ │ -
1165 srcBuffer, srcDesc,
│ │ │ │ -
1166 dstBuffer, dstDesc,
│ │ │ │ -
1167 numPatchCoords, patchCoords,
│ │ │ │ -
1168 patchTable);
│ │ │ │ -
1169 } else {
│ │ │ │ -
1170 // Create an instance on demand (slow)
│ │ │ │ -
1171 (void)deviceContext; // unused
│ │ │ │ -
1172 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
1175 if (instance) {
│ │ │ │ -
1176 bool r = instance->EvalPatchesVarying(
│ │ │ │ -
1177 srcBuffer, srcDesc,
│ │ │ │ -
1178 dstBuffer, dstDesc,
│ │ │ │ -
1179 numPatchCoords, patchCoords,
│ │ │ │ -
1180 patchTable);
│ │ │ │ -
1181 delete instance;
│ │ │ │ -
1182 return r;
│ │ │ │ -
1183 }
│ │ │ │ -
1184 return false;
│ │ │ │ -
1185 }
│ │ │ │ -
1186 }
│ │ │ │ -
│ │ │ │ -
1187
│ │ │ │ -
1212 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1213 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1215 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1216 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1217 int numPatchCoords,
│ │ │ │ -
1218 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1219 PATCH_TABLE *patchTable) const {
│ │ │ │ -
1220
│ │ │ │ -
1221 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1222 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1223 0, BufferDescriptor(),
│ │ │ │ -
1224 0, BufferDescriptor(),
│ │ │ │ -
1225 numPatchCoords,
│ │ │ │ -
1226 patchCoords->BindVBO(),
│ │ │ │ -
1227 patchTable->GetVaryingPatchArrays(),
│ │ │ │ -
1228 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
1229 patchTable->GetPatchParamBuffer());
│ │ │ │ -
1230 }
│ │ │ │ -
│ │ │ │ -
1231
│ │ │ │ -
1276 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1277 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1279 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1280 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1281 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1282 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1283 int numPatchCoords,
│ │ │ │ -
1284 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1285 PATCH_TABLE *patchTable,
│ │ │ │ -
1286 GLComputeEvaluator const *instance,
│ │ │ │ -
1287 void * deviceContext = NULL) {
│ │ │ │ -
1288
│ │ │ │ -
1289 if (instance) {
│ │ │ │ -
1290 return instance->EvalPatchesVarying(
│ │ │ │ -
1291 srcBuffer, srcDesc,
│ │ │ │ -
1292 dstBuffer, dstDesc,
│ │ │ │ -
1293 duBuffer, duDesc,
│ │ │ │ -
1294 dvBuffer, dvDesc,
│ │ │ │ -
1295 numPatchCoords, patchCoords,
│ │ │ │ -
1296 patchTable);
│ │ │ │ -
1297 } else {
│ │ │ │ -
1298 // Create an instance on demand (slow)
│ │ │ │ -
1299 (void)deviceContext; // unused
│ │ │ │ -
1300 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1301 duDesc, dvDesc);
│ │ │ │ -
1302 if (instance) {
│ │ │ │ -
1303 bool r = instance->EvalPatchesVarying(
│ │ │ │ -
1304 srcBuffer, srcDesc,
│ │ │ │ -
1305 dstBuffer, dstDesc,
│ │ │ │ -
1306 duBuffer, duDesc,
│ │ │ │ -
1307 dvBuffer, dvDesc,
│ │ │ │ -
1308 numPatchCoords, patchCoords,
│ │ │ │ -
1309 patchTable);
│ │ │ │ -
1310 delete instance;
│ │ │ │ -
1311 return r;
│ │ │ │ -
1312 }
│ │ │ │ -
1313 return false;
│ │ │ │ -
1314 }
│ │ │ │ -
1315 }
│ │ │ │ -
│ │ │ │ -
1316
│ │ │ │ -
1353 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1354 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1356 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1357 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1358 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1359 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1360 int numPatchCoords,
│ │ │ │ -
1361 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1362 PATCH_TABLE *patchTable) const {
│ │ │ │ -
1363
│ │ │ │ -
1364 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1365 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1366 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
1367 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
1368 numPatchCoords,
│ │ │ │ -
1369 patchCoords->BindVBO(),
│ │ │ │ -
1370 patchTable->GetVaryingPatchArrays(),
│ │ │ │ -
1371 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
1372 patchTable->GetPatchParamBuffer());
│ │ │ │ -
1373 }
│ │ │ │ -
│ │ │ │ -
1374
│ │ │ │ -
1437 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1438 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1440 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1441 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1442 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1443 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1444 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1445 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1446 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1447 int numPatchCoords,
│ │ │ │ -
1448 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1449 PATCH_TABLE *patchTable,
│ │ │ │ -
1450 GLComputeEvaluator const *instance,
│ │ │ │ -
1451 void * deviceContext = NULL) {
│ │ │ │ -
1452
│ │ │ │ -
1453 if (instance) {
│ │ │ │ -
1454 return instance->EvalPatchesVarying(
│ │ │ │ -
1455 srcBuffer, srcDesc,
│ │ │ │ -
1456 dstBuffer, dstDesc,
│ │ │ │ -
1457 duBuffer, duDesc,
│ │ │ │ -
1458 dvBuffer, dvDesc,
│ │ │ │ -
1459 duuBuffer, duuDesc,
│ │ │ │ -
1460 duvBuffer, duvDesc,
│ │ │ │ -
1461 dvvBuffer, dvvDesc,
│ │ │ │ -
1462 numPatchCoords, patchCoords,
│ │ │ │ -
1463 patchTable);
│ │ │ │ -
1464 } else {
│ │ │ │ -
1465 // Create an instance on demand (slow)
│ │ │ │ -
1466 (void)deviceContext; // unused
│ │ │ │ -
1467 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1468 duDesc, dvDesc,
│ │ │ │ -
1469 duuDesc, duvDesc, dvvDesc);
│ │ │ │ -
1470 if (instance) {
│ │ │ │ -
1471 bool r = instance->EvalPatchesVarying(
│ │ │ │ -
1472 srcBuffer, srcDesc,
│ │ │ │ -
1473 dstBuffer, dstDesc,
│ │ │ │ -
1474 duBuffer, duDesc,
│ │ │ │ -
1475 dvBuffer, dvDesc,
│ │ │ │ -
1476 duuBuffer, duuDesc,
│ │ │ │ -
1477 duvBuffer, duvDesc,
│ │ │ │ -
1478 dvvBuffer, dvvDesc,
│ │ │ │ -
1479 numPatchCoords, patchCoords,
│ │ │ │ -
1480 patchTable);
│ │ │ │ -
1481 delete instance;
│ │ │ │ -
1482 return r;
│ │ │ │ -
1483 }
│ │ │ │ -
1484 return false;
│ │ │ │ -
1485 }
│ │ │ │ -
1486 }
│ │ │ │ -
│ │ │ │ -
1487
│ │ │ │ -
1542 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1543 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1545 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1546 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1547 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1548 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1549 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1550 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1551 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1552 int numPatchCoords,
│ │ │ │ -
1553 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1554 PATCH_TABLE *patchTable) const {
│ │ │ │ -
1555
│ │ │ │ -
1556 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1557 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1558 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
1559 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
1560 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ -
1561 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ -
1562 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ -
1563 numPatchCoords,
│ │ │ │ -
1564 patchCoords->BindVBO(),
│ │ │ │ -
1565 patchTable->GetVaryingPatchArrays(),
│ │ │ │ -
1566 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
1567 patchTable->GetPatchParamBuffer());
│ │ │ │ -
1568 }
│ │ │ │ -
│ │ │ │ -
1569
│ │ │ │ -
1604 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1605 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1607 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1608 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1609 int numPatchCoords,
│ │ │ │ -
1610 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1611 PATCH_TABLE *patchTable,
│ │ │ │ -
1612 int fvarChannel,
│ │ │ │ -
1613 GLComputeEvaluator const *instance,
│ │ │ │ -
1614 void * deviceContext = NULL) {
│ │ │ │ -
1615
│ │ │ │ -
1616 if (instance) {
│ │ │ │ -
1617 return instance->EvalPatchesFaceVarying(
│ │ │ │ -
1618 srcBuffer, srcDesc,
│ │ │ │ -
1619 dstBuffer, dstDesc,
│ │ │ │ -
1620 numPatchCoords, patchCoords,
│ │ │ │ -
1621 patchTable, fvarChannel);
│ │ │ │ -
1622 } else {
│ │ │ │ -
1623 // Create an instance on demand (slow)
│ │ │ │ -
1624 (void)deviceContext; // unused
│ │ │ │ -
1625 instance = Create(srcDesc, dstDesc,
│ │ │ │ - │ │ │ │ - │ │ │ │ -
1628 if (instance) {
│ │ │ │ -
1629 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ -
1630 srcBuffer, srcDesc,
│ │ │ │ -
1631 dstBuffer, dstDesc,
│ │ │ │ -
1632 numPatchCoords, patchCoords,
│ │ │ │ -
1633 patchTable, fvarChannel);
│ │ │ │ -
1634 delete instance;
│ │ │ │ -
1635 return r;
│ │ │ │ -
1636 }
│ │ │ │ -
1637 return false;
│ │ │ │ -
1638 }
│ │ │ │ -
1639 }
│ │ │ │ -
│ │ │ │ -
1640
│ │ │ │ -
1667 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1668 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1670 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1671 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1672 int numPatchCoords,
│ │ │ │ -
1673 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1674 PATCH_TABLE *patchTable,
│ │ │ │ -
1675 int fvarChannel = 0) const {
│ │ │ │ -
1676
│ │ │ │ -
1677 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1678 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1679 0, BufferDescriptor(),
│ │ │ │ -
1680 0, BufferDescriptor(),
│ │ │ │ -
1681 numPatchCoords,
│ │ │ │ -
1682 patchCoords->BindVBO(),
│ │ │ │ -
1683 patchTable->GetFVarPatchArrays(fvarChannel),
│ │ │ │ -
1684 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
1685 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ -
1686 }
│ │ │ │ -
│ │ │ │ -
1687
│ │ │ │ -
1734 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1735 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1737 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1738 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1739 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1740 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1741 int numPatchCoords,
│ │ │ │ -
1742 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1743 PATCH_TABLE *patchTable,
│ │ │ │ -
1744 int fvarChannel,
│ │ │ │ -
1745 GLComputeEvaluator const *instance,
│ │ │ │ -
1746 void * deviceContext = NULL) {
│ │ │ │ -
1747
│ │ │ │ -
1748 if (instance) {
│ │ │ │ -
1749 return instance->EvalPatchesFaceVarying(
│ │ │ │ -
1750 srcBuffer, srcDesc,
│ │ │ │ -
1751 dstBuffer, dstDesc,
│ │ │ │ -
1752 duBuffer, duDesc,
│ │ │ │ -
1753 dvBuffer, dvDesc,
│ │ │ │ -
1754 numPatchCoords, patchCoords,
│ │ │ │ -
1755 patchTable, fvarChannel);
│ │ │ │ -
1756 } else {
│ │ │ │ -
1757 // Create an instance on demand (slow)
│ │ │ │ -
1758 (void)deviceContext; // unused
│ │ │ │ -
1759 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1760 duDesc, dvDesc);
│ │ │ │ -
1761 if (instance) {
│ │ │ │ -
1762 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ -
1763 srcBuffer, srcDesc,
│ │ │ │ -
1764 dstBuffer, dstDesc,
│ │ │ │ -
1765 duBuffer, duDesc,
│ │ │ │ -
1766 dvBuffer, dvDesc,
│ │ │ │ -
1767 numPatchCoords, patchCoords,
│ │ │ │ -
1768 patchTable, fvarChannel);
│ │ │ │ -
1769 delete instance;
│ │ │ │ -
1770 return r;
│ │ │ │ -
1771 }
│ │ │ │ -
1772 return false;
│ │ │ │ -
1773 }
│ │ │ │ -
1774 }
│ │ │ │ -
│ │ │ │ -
1775
│ │ │ │ -
1814 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1815 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1817 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1818 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1819 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1820 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1821 int numPatchCoords,
│ │ │ │ -
1822 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1823 PATCH_TABLE *patchTable,
│ │ │ │ -
1824 int fvarChannel = 0) const {
│ │ │ │ -
1825
│ │ │ │ -
1826 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
1827 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
1828 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
1829 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
1830 numPatchCoords,
│ │ │ │ -
1831 patchCoords->BindVBO(),
│ │ │ │ -
1832 patchTable->GetFVarPatchArrays(fvarChannel),
│ │ │ │ -
1833 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
1834 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ -
1835 }
│ │ │ │ -
│ │ │ │ -
1836
│ │ │ │ -
1901 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1902 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1904 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1905 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1906 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1907 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1908 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1909 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1910 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1911 int numPatchCoords,
│ │ │ │ -
1912 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1913 PATCH_TABLE *patchTable,
│ │ │ │ -
1914 int fvarChannel,
│ │ │ │ -
1915 GLComputeEvaluator const *instance,
│ │ │ │ -
1916 void * deviceContext = NULL) {
│ │ │ │ -
1917
│ │ │ │ -
1918 if (instance) {
│ │ │ │ -
1919 return instance->EvalPatchesFaceVarying(
│ │ │ │ -
1920 srcBuffer, srcDesc,
│ │ │ │ -
1921 dstBuffer, dstDesc,
│ │ │ │ -
1922 duBuffer, duDesc,
│ │ │ │ -
1923 dvBuffer, dvDesc,
│ │ │ │ -
1924 duuBuffer, duuDesc,
│ │ │ │ -
1925 duvBuffer, duvDesc,
│ │ │ │ -
1926 dvvBuffer, dvvDesc,
│ │ │ │ -
1927 numPatchCoords, patchCoords,
│ │ │ │ -
1928 patchTable, fvarChannel);
│ │ │ │ -
1929 } else {
│ │ │ │ -
1930 // Create an instance on demand (slow)
│ │ │ │ -
1931 (void)deviceContext; // unused
│ │ │ │ -
1932 instance = Create(srcDesc, dstDesc,
│ │ │ │ -
1933 duDesc, dvDesc,
│ │ │ │ -
1934 duuDesc, duvDesc, dvvDesc);
│ │ │ │ -
1935 if (instance) {
│ │ │ │ -
1936 bool r = instance->EvalPatchesFaceVarying(
│ │ │ │ -
1937 srcBuffer, srcDesc,
│ │ │ │ -
1938 dstBuffer, dstDesc,
│ │ │ │ -
1939 duBuffer, duDesc,
│ │ │ │ -
1940 dvBuffer, dvDesc,
│ │ │ │ -
1941 duuBuffer, duuDesc,
│ │ │ │ -
1942 duvBuffer, duvDesc,
│ │ │ │ -
1943 dvvBuffer, dvvDesc,
│ │ │ │ -
1944 numPatchCoords, patchCoords,
│ │ │ │ -
1945 patchTable, fvarChannel);
│ │ │ │ -
1946 delete instance;
│ │ │ │ -
1947 return r;
│ │ │ │ -
1948 }
│ │ │ │ -
1949 return false;
│ │ │ │ -
1950 }
│ │ │ │ -
1951 }
│ │ │ │ -
│ │ │ │ -
1952
│ │ │ │ -
2009 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
2010 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
2012 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
2013 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
2014 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
2015 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
2016 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
2017 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
2018 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
2019 int numPatchCoords,
│ │ │ │ -
2020 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
2021 PATCH_TABLE *patchTable,
│ │ │ │ -
2022 int fvarChannel = 0) const {
│ │ │ │ -
2023
│ │ │ │ -
2024 return EvalPatches(srcBuffer->BindVBO(), srcDesc,
│ │ │ │ -
2025 dstBuffer->BindVBO(), dstDesc,
│ │ │ │ -
2026 duBuffer->BindVBO(), duDesc,
│ │ │ │ -
2027 dvBuffer->BindVBO(), dvDesc,
│ │ │ │ -
2028 duuBuffer->BindVBO(), duuDesc,
│ │ │ │ -
2029 duvBuffer->BindVBO(), duvDesc,
│ │ │ │ -
2030 dvvBuffer->BindVBO(), dvvDesc,
│ │ │ │ -
2031 numPatchCoords,
│ │ │ │ -
2032 patchCoords->BindVBO(),
│ │ │ │ -
2033 patchTable->GetFVarPatchArrays(fvarChannel),
│ │ │ │ -
2034 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
2035 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ -
2036 }
│ │ │ │ -
│ │ │ │ -
2037
│ │ │ │ -
2043
│ │ │ │ -
2046 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ -
2047 BufferDescriptor const &dstDesc,
│ │ │ │ -
2048 BufferDescriptor const &duDesc = BufferDescriptor(),
│ │ │ │ -
2049 BufferDescriptor const &dvDesc = BufferDescriptor(),
│ │ │ │ -
2050 BufferDescriptor const &duuDesc = BufferDescriptor(),
│ │ │ │ -
2051 BufferDescriptor const &duvDesc = BufferDescriptor(),
│ │ │ │ -
2052 BufferDescriptor const &dvvDesc = BufferDescriptor());
│ │ │ │ -
2053
│ │ │ │ -
2055 static void Synchronize(void *deviceContext);
│ │ │ │ -
2056
│ │ │ │ -
2057private:
│ │ │ │ -
2058 struct _StencilKernel {
│ │ │ │ -
2059 _StencilKernel();
│ │ │ │ -
2060 ~_StencilKernel();
│ │ │ │ -
2061 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ -
2062 BufferDescriptor const &dstDesc,
│ │ │ │ -
2063 BufferDescriptor const &duDesc,
│ │ │ │ -
2064 BufferDescriptor const &dvDesc,
│ │ │ │ -
2065 BufferDescriptor const &duuDesc,
│ │ │ │ -
2066 BufferDescriptor const &duvDesc,
│ │ │ │ -
2067 BufferDescriptor const &dvvDesc,
│ │ │ │ -
2068 int workGroupSize);
│ │ │ │ -
2069 GLuint program;
│ │ │ │ -
2070 GLuint uniformStart;
│ │ │ │ -
2071 GLuint uniformEnd;
│ │ │ │ -
2072 GLuint uniformSrcOffset;
│ │ │ │ -
2073 GLuint uniformDstOffset;
│ │ │ │ -
2074 GLuint uniformDuDesc;
│ │ │ │ -
2075 GLuint uniformDvDesc;
│ │ │ │ -
2076 GLuint uniformDuuDesc;
│ │ │ │ -
2077 GLuint uniformDuvDesc;
│ │ │ │ -
2078 GLuint uniformDvvDesc;
│ │ │ │ -
2079 } _stencilKernel;
│ │ │ │ -
2080
│ │ │ │ -
2081 struct _PatchKernel {
│ │ │ │ -
2082 _PatchKernel();
│ │ │ │ -
2083 ~_PatchKernel();
│ │ │ │ -
2084 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ -
2085 BufferDescriptor const &dstDesc,
│ │ │ │ -
2086 BufferDescriptor const &duDesc,
│ │ │ │ -
2087 BufferDescriptor const &dvDesc,
│ │ │ │ -
2088 BufferDescriptor const &duuDesc,
│ │ │ │ -
2089 BufferDescriptor const &duvDesc,
│ │ │ │ -
2090 BufferDescriptor const &dvvDesc,
│ │ │ │ -
2091 int workGroupSize);
│ │ │ │ -
2092 GLuint program;
│ │ │ │ -
2093 GLuint uniformSrcOffset;
│ │ │ │ -
2094 GLuint uniformDstOffset;
│ │ │ │ -
2095 GLuint uniformPatchArray;
│ │ │ │ -
2096 GLuint uniformDuDesc;
│ │ │ │ -
2097 GLuint uniformDvDesc;
│ │ │ │ -
2098 GLuint uniformDuuDesc;
│ │ │ │ -
2099 GLuint uniformDuvDesc;
│ │ │ │ -
2100 GLuint uniformDvvDesc;
│ │ │ │ -
2101 } _patchKernel;
│ │ │ │ -
2102
│ │ │ │ -
2103 int _workGroupSize;
│ │ │ │ -
2104 GLuint _patchArraysSSBO;
│ │ │ │ -
2105};
│ │ │ │ -
│ │ │ │ -
2106
│ │ │ │ -
2107} // end namespace Osd
│ │ │ │ -
2108
│ │ │ │ -
2109} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
2110using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
2111
│ │ │ │ -
2112} // end namespace OpenSubdiv
│ │ │ │ -
2113
│ │ │ │ -
2114
│ │ │ │ -
2115#endif // OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H
│ │ │ │ +
98 typedef bool Instantiatable;
│ │ │ │ + │ │ │ │ +
100 BufferDescriptor const &dstDesc,
│ │ │ │ +
101 BufferDescriptor const &duDesc,
│ │ │ │ +
102 BufferDescriptor const &dvDesc,
│ │ │ │ +
103 ID3D11DeviceContext *deviceContext);
│ │ │ │ +
104
│ │ │ │ + │ │ │ │ +
106 BufferDescriptor const &dstDesc,
│ │ │ │ +
107 BufferDescriptor const &duDesc,
│ │ │ │ +
108 BufferDescriptor const &dvDesc,
│ │ │ │ +
109 BufferDescriptor const &duuDesc,
│ │ │ │ +
110 BufferDescriptor const &duvDesc,
│ │ │ │ +
111 BufferDescriptor const &dvvDesc,
│ │ │ │ +
112 ID3D11DeviceContext *deviceContext);
│ │ │ │ +
113
│ │ │ │ + │ │ │ │ +
116
│ │ │ │ + │ │ │ │ +
119
│ │ │ │ +
147 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
148 static bool EvalStencils(
│ │ │ │ +
149 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
150 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
151 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
152 D3D11ComputeEvaluator const *instance,
│ │ │ │ +
153 ID3D11DeviceContext * deviceContext) {
│ │ │ │ +
154 if (instance) {
│ │ │ │ +
155 return instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
156 dstBuffer, dstDesc,
│ │ │ │ +
157 stencilTable,
│ │ │ │ +
158 deviceContext);
│ │ │ │ +
159 } else {
│ │ │ │ +
160 // Create an instance on demand (slow)
│ │ │ │ +
161 (void)deviceContext; // unused
│ │ │ │ +
162 instance = Create(srcDesc, dstDesc,
│ │ │ │ + │ │ │ │ + │ │ │ │ +
165 deviceContext);
│ │ │ │ +
166 if (instance) {
│ │ │ │ +
167 bool r = instance->EvalStencils(srcBuffer, srcDesc,
│ │ │ │ +
168 dstBuffer, dstDesc,
│ │ │ │ +
169 stencilTable,
│ │ │ │ +
170 deviceContext);
│ │ │ │ +
171 delete instance;
│ │ │ │ +
172 return r;
│ │ │ │ +
173 }
│ │ │ │ +
174 return false;
│ │ │ │ +
175 }
│ │ │ │ +
176 }
│ │ │ │ +
│ │ │ │ +
177
│ │ │ │ +
180 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
182 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
183 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
184 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
185 ID3D11DeviceContext *deviceContext) const {
│ │ │ │ +
186 return EvalStencils(srcBuffer->BindD3D11UAV(deviceContext), srcDesc,
│ │ │ │ +
187 dstBuffer->BindD3D11UAV(deviceContext), dstDesc,
│ │ │ │ +
188 stencilTable->GetSizesSRV(),
│ │ │ │ +
189 stencilTable->GetOffsetsSRV(),
│ │ │ │ +
190 stencilTable->GetIndicesSRV(),
│ │ │ │ +
191 stencilTable->GetWeightsSRV(),
│ │ │ │ +
192 /* start = */ 0,
│ │ │ │ +
193 /* end = */ stencilTable->GetNumStencils(),
│ │ │ │ +
194 deviceContext);
│ │ │ │ +
195 }
│ │ │ │ +
│ │ │ │ +
196
│ │ │ │ +
199 bool EvalStencils(ID3D11UnorderedAccessView *srcSRV,
│ │ │ │ +
200 BufferDescriptor const &srcDesc,
│ │ │ │ +
201 ID3D11UnorderedAccessView *dstUAV,
│ │ │ │ +
202 BufferDescriptor const &dstDesc,
│ │ │ │ +
203 ID3D11ShaderResourceView *sizesSRV,
│ │ │ │ +
204 ID3D11ShaderResourceView *offsetsSRV,
│ │ │ │ +
205 ID3D11ShaderResourceView *indicesSRV,
│ │ │ │ +
206 ID3D11ShaderResourceView *weightsSRV,
│ │ │ │ +
207 int start,
│ │ │ │ +
208 int end,
│ │ │ │ +
209 ID3D11DeviceContext *deviceContext) const;
│ │ │ │ +
210
│ │ │ │ +
212 bool Compile(BufferDescriptor const &srcDesc,
│ │ │ │ +
213 BufferDescriptor const &dstDesc,
│ │ │ │ +
214 ID3D11DeviceContext *deviceContext);
│ │ │ │ +
215
│ │ │ │ +
217 static void Synchronize(ID3D11DeviceContext *deviceContext);
│ │ │ │ +
218
│ │ │ │ +
219private:
│ │ │ │ +
220 ID3D11ComputeShader * _computeShader;
│ │ │ │ +
221 ID3D11ClassLinkage * _classLinkage;
│ │ │ │ +
222 ID3D11ClassInstance * _singleBufferKernel;
│ │ │ │ +
223 ID3D11ClassInstance * _separateBufferKernel;
│ │ │ │ +
224 ID3D11Buffer * _uniformArgs; // uniform parameters for kernels
│ │ │ │ +
225
│ │ │ │ +
226 int _workGroupSize;
│ │ │ │ +
227};
│ │ │ │ +
│ │ │ │ +
228
│ │ │ │ +
229} // end namespace Osd
│ │ │ │ +
230
│ │ │ │ +
231} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
232using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
233
│ │ │ │ +
234} // end namespace OpenSubdiv
│ │ │ │ +
235
│ │ │ │ +
236
│ │ │ │ +
237#endif // OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H
│ │ │ │ │ │ │ │ -
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
GLStencilTableSSBO(Far::LimitStencilTable const *limitStencilTable)
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
GLStencilTableSSBO(Far::StencilTable const *stencilTable)
│ │ │ │ - │ │ │ │ - │ │ │ │ -
static GLStencilTableSSBO * Create(Far::LimitStencilTable const *limitStencilTable, void *deviceContext=NULL)
│ │ │ │ - │ │ │ │ - │ │ │ │ -
static GLStencilTableSSBO * Create(Far::StencilTable const *stencilTable, void *deviceContext=NULL)
│ │ │ │ - │ │ │ │ -
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable) const
Generic stencil function.
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable) const
Generic stencil function.
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ - │ │ │ │ -
bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, GLuint patchIndexBuffer, GLuint patchParamsBuffer) const
│ │ │ │ -
~GLComputeEvaluator()
Destructor. note that the GL context must be made current.
│ │ │ │ -
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, GLuint sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, GLuint duWeightsBuffer, GLuint dvWeightsBuffer, GLuint duuWeightsBuffer, GLuint duvWeightsBuffer, GLuint dvvWeightsBuffer, int start, int end) const
Dispatch the GLSL compute kernel on GPU asynchronously returns false if the kernel hasn't been compil...
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ - │ │ │ │ -
bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable) const
Generic stencil function.
│ │ │ │ -
bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, GLuint patchIndexBuffer, GLuint patchParamsBuffer) const
│ │ │ │ -
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, void *deviceContext=NULL)
│ │ │ │ -
bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, GLuint duWeightsBuffer, GLuint dvWeightsBuffer, int start, int end) const
Dispatch the GLSL compute kernel on GPU asynchronously returns false if the kernel hasn't been compil...
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic static stencil function. This function has a same signature as other device kernels have so t...
│ │ │ │ -
static void Synchronize(void *deviceContext)
Wait the dispatched kernel finishes.
│ │ │ │ -
bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const &dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const &dvvDesc=BufferDescriptor())
│ │ │ │ -
bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, void *deviceContext=NULL)
│ │ │ │ -
bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ +
static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, DEVICE_CONTEXT context)
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
D3D11StencilTable(Far::StencilTable const *stencilTable, ID3D11DeviceContext *deviceContext)
│ │ │ │ +
static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, ID3D11DeviceContext *deviceContext)
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, ID3D11DeviceContext *deviceContext)
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, D3D11ComputeEvaluator const *instance, ID3D11DeviceContext *deviceContext)
Generic static compute function. This function has a same signature as other device kernels have so t...
│ │ │ │ +
static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, ID3D11DeviceContext *deviceContext)
│ │ │ │ + │ │ │ │ +
static void Synchronize(ID3D11DeviceContext *deviceContext)
Wait the dispatched kernel finishes.
│ │ │ │ +
bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, ID3D11DeviceContext *deviceContext) const
│ │ │ │ +
bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, ID3D11DeviceContext *deviceContext)
Configure DX kernel. Returns false if it fails to compile the kernel.
│ │ │ │ + │ │ │ │ + │ │ │ │ +
bool EvalStencils(ID3D11UnorderedAccessView *srcSRV, BufferDescriptor const &srcDesc, ID3D11UnorderedAccessView *dstUAV, BufferDescriptor const &dstDesc, ID3D11ShaderResourceView *sizesSRV, ID3D11ShaderResourceView *offsetsSRV, ID3D11ShaderResourceView *indicesSRV, ID3D11ShaderResourceView *weightsSRV, int start, int end, ID3D11DeviceContext *deviceContext) const
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -glComputeEvaluator.h │ │ │ │ │ +d3d11ComputeEvaluator.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,1359 +24,272 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ 29 │ │ │ │ │ -30#include "../osd/opengl.h" │ │ │ │ │ -31#include "../osd/types.h" │ │ │ │ │ -32#include "../osd/bufferDescriptor.h" │ │ │ │ │ -33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Far { │ │ │ │ │ -38 class PatchTable; │ │ │ │ │ -39 class StencilTable; │ │ │ │ │ -40 class LimitStencilTable; │ │ │ │ │ -41} │ │ │ │ │ +30struct ID3D11DeviceContext; │ │ │ │ │ +31struct ID3D11Buffer; │ │ │ │ │ +32struct ID3D11ComputeShader; │ │ │ │ │ +33struct ID3D11ClassLinkage; │ │ │ │ │ +34struct ID3D11ClassInstance; │ │ │ │ │ +35struct ID3D11ShaderResourceView; │ │ │ │ │ +36struct ID3D11UnorderedAccessView; │ │ │ │ │ +37 │ │ │ │ │ +38#include "../osd/bufferDescriptor.h" │ │ │ │ │ +39 │ │ │ │ │ +40namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +41namespace OPENSUBDIV_VERSION { │ │ │ │ │ 42 │ │ │ │ │ -43namespace Osd { │ │ │ │ │ -44 │ │ │ │ │ -_5_1class _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O { │ │ │ │ │ -52public: │ │ │ │ │ -_5_3 static _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ -54 void *deviceContext = NULL) { │ │ │ │ │ -55 (void)deviceContext; // unused │ │ │ │ │ -56 return new _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(stencilTable); │ │ │ │ │ -57 } │ │ │ │ │ -_5_8 static _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O *_C_r_e_a_t_e( │ │ │ │ │ -59 _F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const *limitStencilTable, │ │ │ │ │ -60 void *deviceContext = NULL) { │ │ │ │ │ -61 (void)deviceContext; // unused │ │ │ │ │ -62 return new _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(limitStencilTable); │ │ │ │ │ -63 } │ │ │ │ │ -64 │ │ │ │ │ -_6_5 explicit _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable); │ │ │ │ │ -_6_6 explicit _G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e const │ │ │ │ │ -*limitStencilTable); │ │ │ │ │ -_6_7 _~_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O(); │ │ │ │ │ +43namespace Far { │ │ │ │ │ +44 class StencilTable; │ │ │ │ │ +45} │ │ │ │ │ +46 │ │ │ │ │ +47namespace Osd { │ │ │ │ │ +48 │ │ │ │ │ +_5_6class _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e { │ │ │ │ │ +57public: │ │ │ │ │ +58 template │ │ │ │ │ +_5_9 static _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ +60 DEVICE_CONTEXT context) { │ │ │ │ │ +61 return new _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(stencilTable, context->GetDeviceContext()); │ │ │ │ │ +62 } │ │ │ │ │ +63 │ │ │ │ │ +_6_4 static _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e *_C_r_e_a_t_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ +65 ID3D11DeviceContext *deviceContext) { │ │ │ │ │ +66 return new _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(stencilTable, deviceContext); │ │ │ │ │ +67 } │ │ │ │ │ 68 │ │ │ │ │ -69 // interfaces needed for GLSLComputeKernel │ │ │ │ │ -_7_0 GLuint _G_e_t_S_i_z_e_s_B_u_f_f_e_r() const { return _sizes; } │ │ │ │ │ -_7_1 GLuint _G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r() const { return _offsets; } │ │ │ │ │ -_7_2 GLuint _G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r() const { return _indices; } │ │ │ │ │ -_7_3 GLuint _G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _weights; } │ │ │ │ │ -_7_4 GLuint _G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duWeights; } │ │ │ │ │ -_7_5 GLuint _G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvWeights; } │ │ │ │ │ -_7_6 GLuint _G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duuWeights; } │ │ │ │ │ -_7_7 GLuint _G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _duvWeights; } │ │ │ │ │ -_7_8 GLuint _G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r() const { return _dvvWeights; } │ │ │ │ │ +_6_9 _D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e const *stencilTable, │ │ │ │ │ +70 ID3D11DeviceContext *deviceContext); │ │ │ │ │ +71 │ │ │ │ │ +_7_2 _~_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e(); │ │ │ │ │ +73 │ │ │ │ │ +74 // interfaces needed for D3D11ComputeEvaluator │ │ │ │ │ +_7_5 ID3D11ShaderResourceView *_G_e_t_S_i_z_e_s_S_R_V() const { return _sizes; } │ │ │ │ │ +_7_6 ID3D11ShaderResourceView *_G_e_t_O_f_f_s_e_t_s_S_R_V() const { return _offsets; } │ │ │ │ │ +_7_7 ID3D11ShaderResourceView *_G_e_t_I_n_d_i_c_e_s_S_R_V() const { return _indices; } │ │ │ │ │ +_7_8 ID3D11ShaderResourceView *_G_e_t_W_e_i_g_h_t_s_S_R_V() const { return _weights; } │ │ │ │ │ _7_9 int _G_e_t_N_u_m_S_t_e_n_c_i_l_s() const { return _numStencils; } │ │ │ │ │ 80 │ │ │ │ │ 81private: │ │ │ │ │ -82 GLuint _sizes; │ │ │ │ │ -83 GLuint _offsets; │ │ │ │ │ -84 GLuint _indices; │ │ │ │ │ -85 GLuint _weights; │ │ │ │ │ -86 GLuint _duWeights; │ │ │ │ │ -87 GLuint _dvWeights; │ │ │ │ │ -88 GLuint _duuWeights; │ │ │ │ │ -89 GLuint _duvWeights; │ │ │ │ │ -90 GLuint _dvvWeights; │ │ │ │ │ +82 ID3D11ShaderResourceView *_sizes; │ │ │ │ │ +83 ID3D11ShaderResourceView *_offsets; │ │ │ │ │ +84 ID3D11ShaderResourceView *_indices; │ │ │ │ │ +85 ID3D11ShaderResourceView *_weights; │ │ │ │ │ +86 ID3D11Buffer *_sizesBuffer; │ │ │ │ │ +87 ID3D11Buffer *_offsetsBuffer; │ │ │ │ │ +88 ID3D11Buffer *_indicesBuffer; │ │ │ │ │ +89 ID3D11Buffer *_weightsBuffer; │ │ │ │ │ +90 │ │ │ │ │ 91 int _numStencils; │ │ │ │ │ 92}; │ │ │ │ │ 93 │ │ │ │ │ 94// -------------------------------------------------------------------------- │ │ │ │ │ - │ │ │ │ │ 95 │ │ │ │ │ -_9_6class _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r { │ │ │ │ │ +_9_6class _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r { │ │ │ │ │ 97public: │ │ │ │ │ _9_8 typedef bool _I_n_s_t_a_n_t_i_a_t_a_b_l_e; │ │ │ │ │ -_9_9 static _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +_9_9 static _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ 100 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ 101 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ 102 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -103 void * deviceContext = NULL) { │ │ │ │ │ -104 return _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -105 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -106 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -107 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -108 deviceContext); │ │ │ │ │ -109 } │ │ │ │ │ -110 │ │ │ │ │ -_1_1_1 static _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -112 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -113 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -114 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -115 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -116 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -117 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -118 void * deviceContext = NULL) { │ │ │ │ │ -119 (void)deviceContext; // not used │ │ │ │ │ -120 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r *instance = new _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ -121 if (instance->_C_o_m_p_i_l_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -122 duuDesc, duvDesc, dvvDesc)) │ │ │ │ │ -123 return instance; │ │ │ │ │ -124 delete instance; │ │ │ │ │ -125 return NULL; │ │ │ │ │ -126 } │ │ │ │ │ -127 │ │ │ │ │ -_1_2_9 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ -130 │ │ │ │ │ -_1_3_2 _~_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ -133 │ │ │ │ │ -139 │ │ │ │ │ -167 template │ │ │ │ │ -_1_6_8 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -169 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -170 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -171 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -172 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -173 void * deviceContext = NULL) { │ │ │ │ │ -174 │ │ │ │ │ -175 if (instance) { │ │ │ │ │ -176 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -177 dstBuffer, dstDesc, │ │ │ │ │ -178 stencilTable); │ │ │ │ │ -179 } else { │ │ │ │ │ -180 // Create an instance on demand (slow) │ │ │ │ │ -181 (void)deviceContext; // unused │ │ │ │ │ -182 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -183 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -184 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ -185 if (instance) { │ │ │ │ │ -186 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -187 dstBuffer, dstDesc, │ │ │ │ │ -188 stencilTable); │ │ │ │ │ -189 delete instance; │ │ │ │ │ -190 return r; │ │ │ │ │ -191 } │ │ │ │ │ -192 return false; │ │ │ │ │ -193 } │ │ │ │ │ -194 } │ │ │ │ │ -195 │ │ │ │ │ -235 template │ │ │ │ │ -_2_3_6 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -237 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -238 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -239 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -240 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -241 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -242 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -243 void * deviceContext = NULL) { │ │ │ │ │ -244 │ │ │ │ │ -245 if (instance) { │ │ │ │ │ -246 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -247 dstBuffer, dstDesc, │ │ │ │ │ -248 duBuffer, duDesc, │ │ │ │ │ -249 dvBuffer, dvDesc, │ │ │ │ │ -250 stencilTable); │ │ │ │ │ -251 } else { │ │ │ │ │ -252 // Create an instance on demand (slow) │ │ │ │ │ -253 (void)deviceContext; // unused │ │ │ │ │ -254 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc); │ │ │ │ │ -255 if (instance) { │ │ │ │ │ -256 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -257 dstBuffer, dstDesc, │ │ │ │ │ -258 duBuffer, duDesc, │ │ │ │ │ -259 dvBuffer, dvDesc, │ │ │ │ │ -260 stencilTable); │ │ │ │ │ -261 delete instance; │ │ │ │ │ -262 return r; │ │ │ │ │ -263 } │ │ │ │ │ -264 return false; │ │ │ │ │ -265 } │ │ │ │ │ -266 } │ │ │ │ │ -267 │ │ │ │ │ -325 template │ │ │ │ │ -_3_2_6 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -327 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -328 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -329 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -330 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -331 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -332 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -333 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -334 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -335 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -336 void * deviceContext = NULL) { │ │ │ │ │ -337 │ │ │ │ │ -338 if (instance) { │ │ │ │ │ -339 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -340 dstBuffer, dstDesc, │ │ │ │ │ -341 duBuffer, duDesc, │ │ │ │ │ -342 dvBuffer, dvDesc, │ │ │ │ │ -343 duuBuffer, duuDesc, │ │ │ │ │ -344 duvBuffer, duvDesc, │ │ │ │ │ -345 dvvBuffer, dvvDesc, │ │ │ │ │ -346 stencilTable); │ │ │ │ │ -347 } else { │ │ │ │ │ -348 // Create an instance on demand (slow) │ │ │ │ │ -349 (void)deviceContext; // unused │ │ │ │ │ -350 instance = _C_r_e_a_t_e(srcDesc, dstDesc, duDesc, dvDesc, │ │ │ │ │ -351 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ -352 if (instance) { │ │ │ │ │ -353 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ -354 dstBuffer, dstDesc, │ │ │ │ │ -355 duBuffer, duDesc, │ │ │ │ │ -356 dvBuffer, dvDesc, │ │ │ │ │ -357 duuBuffer, duuDesc, │ │ │ │ │ -358 duvBuffer, duvDesc, │ │ │ │ │ -359 dvvBuffer, dvvDesc, │ │ │ │ │ -360 stencilTable); │ │ │ │ │ -361 delete instance; │ │ │ │ │ -362 return r; │ │ │ │ │ -363 } │ │ │ │ │ -364 return false; │ │ │ │ │ -365 } │ │ │ │ │ -366 } │ │ │ │ │ -367 │ │ │ │ │ -385 template │ │ │ │ │ -_3_8_6 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -387 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -388 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -389 STENCIL_TABLE const *stencilTable) const { │ │ │ │ │ -390 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -391 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -392 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -393 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -394 stencilTable->GetSizesBuffer(), │ │ │ │ │ -395 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ -396 stencilTable->GetIndicesBuffer(), │ │ │ │ │ -397 stencilTable->GetWeightsBuffer(), │ │ │ │ │ -398 0, │ │ │ │ │ -399 0, │ │ │ │ │ -400 /* start = */ 0, │ │ │ │ │ -401 /* end = */ stencilTable->GetNumStencils()); │ │ │ │ │ -402 } │ │ │ │ │ -403 │ │ │ │ │ -433 template │ │ │ │ │ -_4_3_4 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -435 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -436 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -437 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -438 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -439 STENCIL_TABLE const *stencilTable) const { │ │ │ │ │ -440 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -441 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -442 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -443 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -444 stencilTable->GetSizesBuffer(), │ │ │ │ │ -445 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ -446 stencilTable->GetIndicesBuffer(), │ │ │ │ │ -447 stencilTable->GetWeightsBuffer(), │ │ │ │ │ -448 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ -449 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ -450 /* start = */ 0, │ │ │ │ │ -451 /* end = */ stencilTable->GetNumStencils()); │ │ │ │ │ -452 } │ │ │ │ │ -453 │ │ │ │ │ -501 template │ │ │ │ │ -_5_0_2 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -503 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -504 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -505 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -506 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -507 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -508 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -509 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -510 STENCIL_TABLE const *stencilTable) const { │ │ │ │ │ -511 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -512 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -513 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -514 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -515 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ -516 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ -517 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ -518 stencilTable->GetSizesBuffer(), │ │ │ │ │ -519 stencilTable->GetOffsetsBuffer(), │ │ │ │ │ -520 stencilTable->GetIndicesBuffer(), │ │ │ │ │ -521 stencilTable->GetWeightsBuffer(), │ │ │ │ │ -522 stencilTable->GetDuWeightsBuffer(), │ │ │ │ │ -523 stencilTable->GetDvWeightsBuffer(), │ │ │ │ │ -524 stencilTable->GetDuuWeightsBuffer(), │ │ │ │ │ -525 stencilTable->GetDuvWeightsBuffer(), │ │ │ │ │ -526 stencilTable->GetDvvWeightsBuffer(), │ │ │ │ │ -527 /* start = */ 0, │ │ │ │ │ -528 /* end = */ stencilTable->GetNumStencils()); │ │ │ │ │ -529 } │ │ │ │ │ -530 │ │ │ │ │ -_5_6_6 bool _E_v_a_l_S_t_e_n_c_i_l_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -567 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -568 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -569 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -570 GLuint sizesBuffer, │ │ │ │ │ -571 GLuint offsetsBuffer, │ │ │ │ │ -572 GLuint indicesBuffer, │ │ │ │ │ -573 GLuint weightsBuffer, │ │ │ │ │ -574 GLuint duWeightsBuffer, │ │ │ │ │ -575 GLuint dvWeightsBuffer, │ │ │ │ │ -576 int start, │ │ │ │ │ -577 int end) const; │ │ │ │ │ -578 │ │ │ │ │ -_6_3_2 bool _E_v_a_l_S_t_e_n_c_i_l_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -633 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -634 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -635 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -636 GLuint duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -637 GLuint duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -638 GLuint dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -639 GLuint sizesBuffer, │ │ │ │ │ -640 GLuint offsetsBuffer, │ │ │ │ │ -641 GLuint indicesBuffer, │ │ │ │ │ -642 GLuint weightsBuffer, │ │ │ │ │ -643 GLuint duWeightsBuffer, │ │ │ │ │ -644 GLuint dvWeightsBuffer, │ │ │ │ │ -645 GLuint duuWeightsBuffer, │ │ │ │ │ -646 GLuint duvWeightsBuffer, │ │ │ │ │ -647 GLuint dvvWeightsBuffer, │ │ │ │ │ -648 int start, │ │ │ │ │ -649 int end) const; │ │ │ │ │ -650 │ │ │ │ │ -656 │ │ │ │ │ -689 template │ │ │ │ │ -_6_9_1 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -692 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -693 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -694 int numPatchCoords, │ │ │ │ │ -695 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -696 PATCH_TABLE *patchTable, │ │ │ │ │ -697 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -698 void * deviceContext = NULL) { │ │ │ │ │ -699 │ │ │ │ │ -700 if (instance) { │ │ │ │ │ -701 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -702 dstBuffer, dstDesc, │ │ │ │ │ -703 numPatchCoords, patchCoords, │ │ │ │ │ -704 patchTable); │ │ │ │ │ -705 } else { │ │ │ │ │ -706 // Create an instance on demand (slow) │ │ │ │ │ -707 (void)deviceContext; // unused │ │ │ │ │ -708 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -709 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -710 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ -711 if (instance) { │ │ │ │ │ -712 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -713 dstBuffer, dstDesc, │ │ │ │ │ -714 numPatchCoords, patchCoords, │ │ │ │ │ -715 patchTable); │ │ │ │ │ -716 delete instance; │ │ │ │ │ -717 return r; │ │ │ │ │ -718 } │ │ │ │ │ -719 return false; │ │ │ │ │ -720 } │ │ │ │ │ -721 } │ │ │ │ │ -722 │ │ │ │ │ -767 template │ │ │ │ │ -_7_6_9 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -770 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -771 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -772 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -773 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -774 int numPatchCoords, │ │ │ │ │ -775 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -776 PATCH_TABLE *patchTable, │ │ │ │ │ -777 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -778 void * deviceContext = NULL) { │ │ │ │ │ -779 │ │ │ │ │ -780 if (instance) { │ │ │ │ │ -781 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -782 dstBuffer, dstDesc, │ │ │ │ │ -783 duBuffer, duDesc, │ │ │ │ │ -784 dvBuffer, dvDesc, │ │ │ │ │ -785 numPatchCoords, patchCoords, │ │ │ │ │ -786 patchTable); │ │ │ │ │ -787 } else { │ │ │ │ │ -788 // Create an instance on demand (slow) │ │ │ │ │ -789 (void)deviceContext; // unused │ │ │ │ │ -790 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -791 duDesc, dvDesc); │ │ │ │ │ -792 if (instance) { │ │ │ │ │ -793 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -794 dstBuffer, dstDesc, │ │ │ │ │ -795 duBuffer, duDesc, │ │ │ │ │ -796 dvBuffer, dvDesc, │ │ │ │ │ -797 numPatchCoords, patchCoords, │ │ │ │ │ -798 patchTable); │ │ │ │ │ -799 delete instance; │ │ │ │ │ -800 return r; │ │ │ │ │ -801 } │ │ │ │ │ -802 return false; │ │ │ │ │ -803 } │ │ │ │ │ -804 } │ │ │ │ │ -805 │ │ │ │ │ -868 template │ │ │ │ │ -_8_7_0 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -871 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -872 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -873 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -874 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -875 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -876 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -877 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -878 int numPatchCoords, │ │ │ │ │ -879 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -880 PATCH_TABLE *patchTable, │ │ │ │ │ -881 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -882 void * deviceContext = NULL) { │ │ │ │ │ -883 │ │ │ │ │ -884 if (instance) { │ │ │ │ │ -885 return instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -886 dstBuffer, dstDesc, │ │ │ │ │ -887 duBuffer, duDesc, │ │ │ │ │ -888 dvBuffer, dvDesc, │ │ │ │ │ -889 duuBuffer, duuDesc, │ │ │ │ │ -890 duvBuffer, duvDesc, │ │ │ │ │ -891 dvvBuffer, dvvDesc, │ │ │ │ │ -892 numPatchCoords, patchCoords, │ │ │ │ │ -893 patchTable); │ │ │ │ │ -894 } else { │ │ │ │ │ -895 // Create an instance on demand (slow) │ │ │ │ │ -896 (void)deviceContext; // unused │ │ │ │ │ -897 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -898 duDesc, dvDesc, │ │ │ │ │ -899 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ -900 if (instance) { │ │ │ │ │ -901 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s(srcBuffer, srcDesc, │ │ │ │ │ -902 dstBuffer, dstDesc, │ │ │ │ │ -903 duBuffer, duDesc, │ │ │ │ │ -904 dvBuffer, dvDesc, │ │ │ │ │ -905 duuBuffer, duuDesc, │ │ │ │ │ -906 duvBuffer, duvDesc, │ │ │ │ │ -907 dvvBuffer, dvvDesc, │ │ │ │ │ -908 numPatchCoords, patchCoords, │ │ │ │ │ -909 patchTable); │ │ │ │ │ -910 delete instance; │ │ │ │ │ -911 return r; │ │ │ │ │ -912 } │ │ │ │ │ -913 return false; │ │ │ │ │ -914 } │ │ │ │ │ -915 } │ │ │ │ │ -916 │ │ │ │ │ -941 template │ │ │ │ │ -_9_4_3 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -944 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -945 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -946 int numPatchCoords, │ │ │ │ │ -947 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -948 PATCH_TABLE *patchTable) const { │ │ │ │ │ -949 │ │ │ │ │ -950 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -951 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -952 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -953 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -954 numPatchCoords, │ │ │ │ │ -955 patchCoords->BindVBO(), │ │ │ │ │ -956 patchTable->GetPatchArrays(), │ │ │ │ │ -957 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -958 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -959 } │ │ │ │ │ -960 │ │ │ │ │ -995 template │ │ │ │ │ -_9_9_7 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -998 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -999 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1000 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1001 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1002 int numPatchCoords, │ │ │ │ │ -1003 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1004 PATCH_TABLE *patchTable) const { │ │ │ │ │ -1005 │ │ │ │ │ -1006 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1007 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1008 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -1009 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -1010 numPatchCoords, │ │ │ │ │ -1011 patchCoords->BindVBO(), │ │ │ │ │ -1012 patchTable->GetPatchArrays(), │ │ │ │ │ -1013 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -1014 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -1015 } │ │ │ │ │ -1016 │ │ │ │ │ -1069 template │ │ │ │ │ -_1_0_7_1 bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -1072 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1073 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1074 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1075 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1076 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1077 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1078 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1079 int numPatchCoords, │ │ │ │ │ -1080 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1081 PATCH_TABLE *patchTable) const { │ │ │ │ │ -1082 │ │ │ │ │ -1083 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1084 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1085 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -1086 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -1087 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ -1088 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ -1089 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ -1090 numPatchCoords, │ │ │ │ │ -1091 patchCoords->BindVBO(), │ │ │ │ │ -1092 patchTable->GetPatchArrays(), │ │ │ │ │ -1093 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -1094 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -1095 } │ │ │ │ │ -1096 │ │ │ │ │ -_1_0_9_7 bool _E_v_a_l_P_a_t_c_h_e_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1098 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1099 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1100 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1101 int numPatchCoords, │ │ │ │ │ -1102 GLuint patchCoordsBuffer, │ │ │ │ │ -1103 const _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r &patchArrays, │ │ │ │ │ -1104 GLuint patchIndexBuffer, │ │ │ │ │ -1105 GLuint patchParamsBuffer) const; │ │ │ │ │ -1106 │ │ │ │ │ -_1_1_0_7 bool _E_v_a_l_P_a_t_c_h_e_s(GLuint srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1108 GLuint dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1109 GLuint duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1110 GLuint dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1111 GLuint duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1112 GLuint duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1113 GLuint dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1114 int numPatchCoords, │ │ │ │ │ -1115 GLuint patchCoordsBuffer, │ │ │ │ │ -1116 const _P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r &patchArrays, │ │ │ │ │ -1117 GLuint patchIndexBuffer, │ │ │ │ │ -1118 GLuint patchParamsBuffer) const; │ │ │ │ │ -1119 │ │ │ │ │ -1152 template │ │ │ │ │ -_1_1_5_4 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1155 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1156 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1157 int numPatchCoords, │ │ │ │ │ -1158 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1159 PATCH_TABLE *patchTable, │ │ │ │ │ -1160 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1161 void * deviceContext = NULL) { │ │ │ │ │ -1162 │ │ │ │ │ -1163 if (instance) { │ │ │ │ │ -1164 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1165 srcBuffer, srcDesc, │ │ │ │ │ -1166 dstBuffer, dstDesc, │ │ │ │ │ -1167 numPatchCoords, patchCoords, │ │ │ │ │ -1168 patchTable); │ │ │ │ │ -1169 } else { │ │ │ │ │ -1170 // Create an instance on demand (slow) │ │ │ │ │ -1171 (void)deviceContext; // unused │ │ │ │ │ -1172 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1173 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1174 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ -1175 if (instance) { │ │ │ │ │ -1176 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1177 srcBuffer, srcDesc, │ │ │ │ │ -1178 dstBuffer, dstDesc, │ │ │ │ │ -1179 numPatchCoords, patchCoords, │ │ │ │ │ -1180 patchTable); │ │ │ │ │ -1181 delete instance; │ │ │ │ │ -1182 return r; │ │ │ │ │ -1183 } │ │ │ │ │ -1184 return false; │ │ │ │ │ -1185 } │ │ │ │ │ -1186 } │ │ │ │ │ -1187 │ │ │ │ │ -1212 template │ │ │ │ │ -_1_2_1_4 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1215 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1216 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1217 int numPatchCoords, │ │ │ │ │ -1218 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1219 PATCH_TABLE *patchTable) const { │ │ │ │ │ -1220 │ │ │ │ │ -1221 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1222 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1223 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1224 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1225 numPatchCoords, │ │ │ │ │ -1226 patchCoords->BindVBO(), │ │ │ │ │ -1227 patchTable->GetVaryingPatchArrays(), │ │ │ │ │ -1228 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -1229 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -1230 } │ │ │ │ │ -1231 │ │ │ │ │ -1276 template │ │ │ │ │ -_1_2_7_8 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1279 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1280 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1281 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1282 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1283 int numPatchCoords, │ │ │ │ │ -1284 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1285 PATCH_TABLE *patchTable, │ │ │ │ │ -1286 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1287 void * deviceContext = NULL) { │ │ │ │ │ -1288 │ │ │ │ │ -1289 if (instance) { │ │ │ │ │ -1290 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1291 srcBuffer, srcDesc, │ │ │ │ │ -1292 dstBuffer, dstDesc, │ │ │ │ │ -1293 duBuffer, duDesc, │ │ │ │ │ -1294 dvBuffer, dvDesc, │ │ │ │ │ -1295 numPatchCoords, patchCoords, │ │ │ │ │ -1296 patchTable); │ │ │ │ │ -1297 } else { │ │ │ │ │ -1298 // Create an instance on demand (slow) │ │ │ │ │ -1299 (void)deviceContext; // unused │ │ │ │ │ -1300 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1301 duDesc, dvDesc); │ │ │ │ │ -1302 if (instance) { │ │ │ │ │ -1303 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1304 srcBuffer, srcDesc, │ │ │ │ │ -1305 dstBuffer, dstDesc, │ │ │ │ │ -1306 duBuffer, duDesc, │ │ │ │ │ -1307 dvBuffer, dvDesc, │ │ │ │ │ -1308 numPatchCoords, patchCoords, │ │ │ │ │ -1309 patchTable); │ │ │ │ │ -1310 delete instance; │ │ │ │ │ -1311 return r; │ │ │ │ │ -1312 } │ │ │ │ │ -1313 return false; │ │ │ │ │ -1314 } │ │ │ │ │ -1315 } │ │ │ │ │ -1316 │ │ │ │ │ -1353 template │ │ │ │ │ -_1_3_5_5 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1356 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1357 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1358 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1359 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1360 int numPatchCoords, │ │ │ │ │ -1361 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1362 PATCH_TABLE *patchTable) const { │ │ │ │ │ -1363 │ │ │ │ │ -1364 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1365 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1366 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -1367 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -1368 numPatchCoords, │ │ │ │ │ -1369 patchCoords->BindVBO(), │ │ │ │ │ -1370 patchTable->GetVaryingPatchArrays(), │ │ │ │ │ -1371 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -1372 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -1373 } │ │ │ │ │ -1374 │ │ │ │ │ -1437 template │ │ │ │ │ -_1_4_3_9 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1440 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1441 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1442 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1443 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1444 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1445 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1446 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1447 int numPatchCoords, │ │ │ │ │ -1448 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1449 PATCH_TABLE *patchTable, │ │ │ │ │ -1450 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1451 void * deviceContext = NULL) { │ │ │ │ │ -1452 │ │ │ │ │ -1453 if (instance) { │ │ │ │ │ -1454 return instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1455 srcBuffer, srcDesc, │ │ │ │ │ -1456 dstBuffer, dstDesc, │ │ │ │ │ -1457 duBuffer, duDesc, │ │ │ │ │ -1458 dvBuffer, dvDesc, │ │ │ │ │ -1459 duuBuffer, duuDesc, │ │ │ │ │ -1460 duvBuffer, duvDesc, │ │ │ │ │ -1461 dvvBuffer, dvvDesc, │ │ │ │ │ -1462 numPatchCoords, patchCoords, │ │ │ │ │ -1463 patchTable); │ │ │ │ │ -1464 } else { │ │ │ │ │ -1465 // Create an instance on demand (slow) │ │ │ │ │ -1466 (void)deviceContext; // unused │ │ │ │ │ -1467 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1468 duDesc, dvDesc, │ │ │ │ │ -1469 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ -1470 if (instance) { │ │ │ │ │ -1471 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1472 srcBuffer, srcDesc, │ │ │ │ │ -1473 dstBuffer, dstDesc, │ │ │ │ │ -1474 duBuffer, duDesc, │ │ │ │ │ -1475 dvBuffer, dvDesc, │ │ │ │ │ -1476 duuBuffer, duuDesc, │ │ │ │ │ -1477 duvBuffer, duvDesc, │ │ │ │ │ -1478 dvvBuffer, dvvDesc, │ │ │ │ │ -1479 numPatchCoords, patchCoords, │ │ │ │ │ -1480 patchTable); │ │ │ │ │ -1481 delete instance; │ │ │ │ │ -1482 return r; │ │ │ │ │ -1483 } │ │ │ │ │ -1484 return false; │ │ │ │ │ -1485 } │ │ │ │ │ -1486 } │ │ │ │ │ -1487 │ │ │ │ │ -1542 template │ │ │ │ │ -_1_5_4_4 bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -1545 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1546 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1547 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1548 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1549 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1550 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1551 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1552 int numPatchCoords, │ │ │ │ │ -1553 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1554 PATCH_TABLE *patchTable) const { │ │ │ │ │ -1555 │ │ │ │ │ -1556 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1557 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1558 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -1559 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -1560 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ -1561 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ -1562 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ -1563 numPatchCoords, │ │ │ │ │ -1564 patchCoords->BindVBO(), │ │ │ │ │ -1565 patchTable->GetVaryingPatchArrays(), │ │ │ │ │ -1566 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -1567 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -1568 } │ │ │ │ │ -1569 │ │ │ │ │ -1604 template │ │ │ │ │ -_1_6_0_6 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1607 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1608 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1609 int numPatchCoords, │ │ │ │ │ -1610 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1611 PATCH_TABLE *patchTable, │ │ │ │ │ -1612 int fvarChannel, │ │ │ │ │ -1613 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1614 void * deviceContext = NULL) { │ │ │ │ │ -1615 │ │ │ │ │ -1616 if (instance) { │ │ │ │ │ -1617 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1618 srcBuffer, srcDesc, │ │ │ │ │ -1619 dstBuffer, dstDesc, │ │ │ │ │ -1620 numPatchCoords, patchCoords, │ │ │ │ │ -1621 patchTable, fvarChannel); │ │ │ │ │ -1622 } else { │ │ │ │ │ -1623 // Create an instance on demand (slow) │ │ │ │ │ -1624 (void)deviceContext; // unused │ │ │ │ │ -1625 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1626 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1627 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ -1628 if (instance) { │ │ │ │ │ -1629 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1630 srcBuffer, srcDesc, │ │ │ │ │ -1631 dstBuffer, dstDesc, │ │ │ │ │ -1632 numPatchCoords, patchCoords, │ │ │ │ │ -1633 patchTable, fvarChannel); │ │ │ │ │ -1634 delete instance; │ │ │ │ │ -1635 return r; │ │ │ │ │ -1636 } │ │ │ │ │ -1637 return false; │ │ │ │ │ -1638 } │ │ │ │ │ -1639 } │ │ │ │ │ -1640 │ │ │ │ │ -1667 template │ │ │ │ │ -_1_6_6_9 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1670 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1671 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1672 int numPatchCoords, │ │ │ │ │ -1673 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1674 PATCH_TABLE *patchTable, │ │ │ │ │ -1675 int fvarChannel = 0) const { │ │ │ │ │ -1676 │ │ │ │ │ -1677 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1678 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1679 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1680 0, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -1681 numPatchCoords, │ │ │ │ │ -1682 patchCoords->BindVBO(), │ │ │ │ │ -1683 patchTable->GetFVarPatchArrays(fvarChannel), │ │ │ │ │ -1684 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -1685 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ -1686 } │ │ │ │ │ -1687 │ │ │ │ │ -1734 template │ │ │ │ │ -_1_7_3_6 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1737 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1738 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1739 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1740 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1741 int numPatchCoords, │ │ │ │ │ -1742 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1743 PATCH_TABLE *patchTable, │ │ │ │ │ -1744 int fvarChannel, │ │ │ │ │ -1745 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1746 void * deviceContext = NULL) { │ │ │ │ │ -1747 │ │ │ │ │ -1748 if (instance) { │ │ │ │ │ -1749 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1750 srcBuffer, srcDesc, │ │ │ │ │ -1751 dstBuffer, dstDesc, │ │ │ │ │ -1752 duBuffer, duDesc, │ │ │ │ │ -1753 dvBuffer, dvDesc, │ │ │ │ │ -1754 numPatchCoords, patchCoords, │ │ │ │ │ -1755 patchTable, fvarChannel); │ │ │ │ │ -1756 } else { │ │ │ │ │ -1757 // Create an instance on demand (slow) │ │ │ │ │ -1758 (void)deviceContext; // unused │ │ │ │ │ -1759 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1760 duDesc, dvDesc); │ │ │ │ │ -1761 if (instance) { │ │ │ │ │ -1762 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1763 srcBuffer, srcDesc, │ │ │ │ │ -1764 dstBuffer, dstDesc, │ │ │ │ │ -1765 duBuffer, duDesc, │ │ │ │ │ -1766 dvBuffer, dvDesc, │ │ │ │ │ -1767 numPatchCoords, patchCoords, │ │ │ │ │ -1768 patchTable, fvarChannel); │ │ │ │ │ -1769 delete instance; │ │ │ │ │ -1770 return r; │ │ │ │ │ -1771 } │ │ │ │ │ -1772 return false; │ │ │ │ │ -1773 } │ │ │ │ │ -1774 } │ │ │ │ │ -1775 │ │ │ │ │ -1814 template │ │ │ │ │ -_1_8_1_6 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1817 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1818 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1819 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1820 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1821 int numPatchCoords, │ │ │ │ │ -1822 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1823 PATCH_TABLE *patchTable, │ │ │ │ │ -1824 int fvarChannel = 0) const { │ │ │ │ │ -1825 │ │ │ │ │ -1826 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -1827 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -1828 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -1829 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -1830 numPatchCoords, │ │ │ │ │ -1831 patchCoords->BindVBO(), │ │ │ │ │ -1832 patchTable->GetFVarPatchArrays(fvarChannel), │ │ │ │ │ -1833 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -1834 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ -1835 } │ │ │ │ │ -1836 │ │ │ │ │ -1901 template │ │ │ │ │ -_1_9_0_3 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1904 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1905 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1906 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1907 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1908 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1909 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1910 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1911 int numPatchCoords, │ │ │ │ │ -1912 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1913 PATCH_TABLE *patchTable, │ │ │ │ │ -1914 int fvarChannel, │ │ │ │ │ -1915 _G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ -1916 void * deviceContext = NULL) { │ │ │ │ │ -1917 │ │ │ │ │ -1918 if (instance) { │ │ │ │ │ -1919 return instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1920 srcBuffer, srcDesc, │ │ │ │ │ -1921 dstBuffer, dstDesc, │ │ │ │ │ -1922 duBuffer, duDesc, │ │ │ │ │ -1923 dvBuffer, dvDesc, │ │ │ │ │ -1924 duuBuffer, duuDesc, │ │ │ │ │ -1925 duvBuffer, duvDesc, │ │ │ │ │ -1926 dvvBuffer, dvvDesc, │ │ │ │ │ -1927 numPatchCoords, patchCoords, │ │ │ │ │ -1928 patchTable, fvarChannel); │ │ │ │ │ -1929 } else { │ │ │ │ │ -1930 // Create an instance on demand (slow) │ │ │ │ │ -1931 (void)deviceContext; // unused │ │ │ │ │ -1932 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ -1933 duDesc, dvDesc, │ │ │ │ │ -1934 duuDesc, duvDesc, dvvDesc); │ │ │ │ │ -1935 if (instance) { │ │ │ │ │ -1936 bool r = instance->_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1937 srcBuffer, srcDesc, │ │ │ │ │ -1938 dstBuffer, dstDesc, │ │ │ │ │ -1939 duBuffer, duDesc, │ │ │ │ │ -1940 dvBuffer, dvDesc, │ │ │ │ │ -1941 duuBuffer, duuDesc, │ │ │ │ │ -1942 duvBuffer, duvDesc, │ │ │ │ │ -1943 dvvBuffer, dvvDesc, │ │ │ │ │ -1944 numPatchCoords, patchCoords, │ │ │ │ │ -1945 patchTable, fvarChannel); │ │ │ │ │ -1946 delete instance; │ │ │ │ │ -1947 return r; │ │ │ │ │ -1948 } │ │ │ │ │ -1949 return false; │ │ │ │ │ -1950 } │ │ │ │ │ -1951 } │ │ │ │ │ -1952 │ │ │ │ │ -2009 template │ │ │ │ │ -_2_0_1_1 bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -2012 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2013 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2014 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2015 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2016 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -2017 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -2018 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -2019 int numPatchCoords, │ │ │ │ │ -2020 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -2021 PATCH_TABLE *patchTable, │ │ │ │ │ -2022 int fvarChannel = 0) const { │ │ │ │ │ -2023 │ │ │ │ │ -2024 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindVBO(), srcDesc, │ │ │ │ │ -2025 dstBuffer->BindVBO(), dstDesc, │ │ │ │ │ -2026 duBuffer->BindVBO(), duDesc, │ │ │ │ │ -2027 dvBuffer->BindVBO(), dvDesc, │ │ │ │ │ -2028 duuBuffer->BindVBO(), duuDesc, │ │ │ │ │ -2029 duvBuffer->BindVBO(), duvDesc, │ │ │ │ │ -2030 dvvBuffer->BindVBO(), dvvDesc, │ │ │ │ │ -2031 numPatchCoords, │ │ │ │ │ -2032 patchCoords->BindVBO(), │ │ │ │ │ -2033 patchTable->GetFVarPatchArrays(fvarChannel), │ │ │ │ │ -2034 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -2035 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ -2036 } │ │ │ │ │ -2037 │ │ │ │ │ -2043 │ │ │ │ │ -_2_0_4_6 bool _C_o_m_p_i_l_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2047 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2048 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2049 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2050 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2051 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ -2052 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc = _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r()); │ │ │ │ │ -2053 │ │ │ │ │ -_2_0_5_5 static void _S_y_n_c_h_r_o_n_i_z_e(void *deviceContext); │ │ │ │ │ -2056 │ │ │ │ │ -2057private: │ │ │ │ │ -2058 struct _StencilKernel { │ │ │ │ │ -2059 _StencilKernel(); │ │ │ │ │ -2060 ~_StencilKernel(); │ │ │ │ │ -2061 bool Compile(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2062 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2063 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2064 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2065 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -2066 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -2067 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -2068 int workGroupSize); │ │ │ │ │ -2069 GLuint program; │ │ │ │ │ -2070 GLuint uniformStart; │ │ │ │ │ -2071 GLuint uniformEnd; │ │ │ │ │ -2072 GLuint uniformSrcOffset; │ │ │ │ │ -2073 GLuint uniformDstOffset; │ │ │ │ │ -2074 GLuint uniformDuDesc; │ │ │ │ │ -2075 GLuint uniformDvDesc; │ │ │ │ │ -2076 GLuint uniformDuuDesc; │ │ │ │ │ -2077 GLuint uniformDuvDesc; │ │ │ │ │ -2078 GLuint uniformDvvDesc; │ │ │ │ │ -2079 } _stencilKernel; │ │ │ │ │ -2080 │ │ │ │ │ -2081 struct _PatchKernel { │ │ │ │ │ -2082 _PatchKernel(); │ │ │ │ │ -2083 ~_PatchKernel(); │ │ │ │ │ -2084 bool Compile(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -2085 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -2086 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -2087 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -2088 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -2089 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -2090 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -2091 int workGroupSize); │ │ │ │ │ -2092 GLuint program; │ │ │ │ │ -2093 GLuint uniformSrcOffset; │ │ │ │ │ -2094 GLuint uniformDstOffset; │ │ │ │ │ -2095 GLuint uniformPatchArray; │ │ │ │ │ -2096 GLuint uniformDuDesc; │ │ │ │ │ -2097 GLuint uniformDvDesc; │ │ │ │ │ -2098 GLuint uniformDuuDesc; │ │ │ │ │ -2099 GLuint uniformDuvDesc; │ │ │ │ │ -2100 GLuint uniformDvvDesc; │ │ │ │ │ -2101 } _patchKernel; │ │ │ │ │ -2102 │ │ │ │ │ -2103 int _workGroupSize; │ │ │ │ │ -2104 GLuint _patchArraysSSBO; │ │ │ │ │ -2105}; │ │ │ │ │ -2106 │ │ │ │ │ -2107} // end namespace Osd │ │ │ │ │ -2108 │ │ │ │ │ -2109} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -2110using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -2111 │ │ │ │ │ -2112} // end namespace OpenSubdiv │ │ │ │ │ -2113 │ │ │ │ │ -2114 │ │ │ │ │ -2115#endif // OPENSUBDIV3_OSD_GL_COMPUTE_EVALUATOR_H │ │ │ │ │ +103 ID3D11DeviceContext *deviceContext); │ │ │ │ │ +104 │ │ │ │ │ +_1_0_5 static _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r * _C_r_e_a_t_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +106 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +107 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +108 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +109 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +110 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +111 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +112 ID3D11DeviceContext *deviceContext); │ │ │ │ │ +113 │ │ │ │ │ +_1_1_5 _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ +116 │ │ │ │ │ +_1_1_8 _~_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r(); │ │ │ │ │ +119 │ │ │ │ │ +147 template │ │ │ │ │ +_1_4_8 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +149 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +150 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +151 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +152 _D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r const *instance, │ │ │ │ │ +153 ID3D11DeviceContext * deviceContext) { │ │ │ │ │ +154 if (instance) { │ │ │ │ │ +155 return instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +156 dstBuffer, dstDesc, │ │ │ │ │ +157 stencilTable, │ │ │ │ │ +158 deviceContext); │ │ │ │ │ +159 } else { │ │ │ │ │ +160 // Create an instance on demand (slow) │ │ │ │ │ +161 (void)deviceContext; // unused │ │ │ │ │ +162 instance = _C_r_e_a_t_e(srcDesc, dstDesc, │ │ │ │ │ +163 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +164 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(), │ │ │ │ │ +165 deviceContext); │ │ │ │ │ +166 if (instance) { │ │ │ │ │ +167 bool r = instance->_E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer, srcDesc, │ │ │ │ │ +168 dstBuffer, dstDesc, │ │ │ │ │ +169 stencilTable, │ │ │ │ │ +170 deviceContext); │ │ │ │ │ +171 delete instance; │ │ │ │ │ +172 return r; │ │ │ │ │ +173 } │ │ │ │ │ +174 return false; │ │ │ │ │ +175 } │ │ │ │ │ +176 } │ │ │ │ │ +177 │ │ │ │ │ +180 template │ │ │ │ │ +_1_8_1 bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +182 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +183 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +184 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +185 ID3D11DeviceContext *deviceContext) const { │ │ │ │ │ +186 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindD3D11UAV(deviceContext), srcDesc, │ │ │ │ │ +187 dstBuffer->BindD3D11UAV(deviceContext), dstDesc, │ │ │ │ │ +188 stencilTable->GetSizesSRV(), │ │ │ │ │ +189 stencilTable->GetOffsetsSRV(), │ │ │ │ │ +190 stencilTable->GetIndicesSRV(), │ │ │ │ │ +191 stencilTable->GetWeightsSRV(), │ │ │ │ │ +192 /* start = */ 0, │ │ │ │ │ +193 /* end = */ stencilTable->GetNumStencils(), │ │ │ │ │ +194 deviceContext); │ │ │ │ │ +195 } │ │ │ │ │ +196 │ │ │ │ │ +_1_9_9 bool _E_v_a_l_S_t_e_n_c_i_l_s(ID3D11UnorderedAccessView *srcSRV, │ │ │ │ │ +200 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +201 ID3D11UnorderedAccessView *dstUAV, │ │ │ │ │ +202 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +203 ID3D11ShaderResourceView *sizesSRV, │ │ │ │ │ +204 ID3D11ShaderResourceView *offsetsSRV, │ │ │ │ │ +205 ID3D11ShaderResourceView *indicesSRV, │ │ │ │ │ +206 ID3D11ShaderResourceView *weightsSRV, │ │ │ │ │ +207 int start, │ │ │ │ │ +208 int end, │ │ │ │ │ +209 ID3D11DeviceContext *deviceContext) const; │ │ │ │ │ +210 │ │ │ │ │ +_2_1_2 bool _C_o_m_p_i_l_e(_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +213 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +214 ID3D11DeviceContext *deviceContext); │ │ │ │ │ +215 │ │ │ │ │ +_2_1_7 static void _S_y_n_c_h_r_o_n_i_z_e(ID3D11DeviceContext *deviceContext); │ │ │ │ │ +218 │ │ │ │ │ +219private: │ │ │ │ │ +220 ID3D11ComputeShader * _computeShader; │ │ │ │ │ +221 ID3D11ClassLinkage * _classLinkage; │ │ │ │ │ +222 ID3D11ClassInstance * _singleBufferKernel; │ │ │ │ │ +223 ID3D11ClassInstance * _separateBufferKernel; │ │ │ │ │ +224 ID3D11Buffer * _uniformArgs; // uniform parameters for kernels │ │ │ │ │ +225 │ │ │ │ │ +226 int _workGroupSize; │ │ │ │ │ +227}; │ │ │ │ │ +228 │ │ │ │ │ +229} // end namespace Osd │ │ │ │ │ +230 │ │ │ │ │ +231} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +232using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +233 │ │ │ │ │ +234} // end namespace OpenSubdiv │ │ │ │ │ +235 │ │ │ │ │ +236 │ │ │ │ │ +237#endif // OPENSUBDIV3_OSD_D3D11_COMPUTE_EVALUATOR_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y_V_e_c_t_o_r │ │ │ │ │ -std::vector< PatchArray > PatchArrayVector │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_3_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ Stencil table class wrapping the template for compatibility. │ │ │ │ │ DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_2_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r_:_:_L_i_m_i_t_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ -Limit stencil table class wrapping the template for compatibility. │ │ │ │ │ -DDeeffiinniittiioonn _s_t_e_n_c_i_l_T_a_b_l_e_._h_:_5_8_3 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ data buffers.... │ │ │ │ │ DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ -GL stencil table (Shader Storage buffer) │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_u_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetDuvWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ -GLStencilTableSSBO(Far::LimitStencilTable const *limitStencilTable) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetDuWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_~_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ -~GLStencilTableSSBO() │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +D3D11 stencil table. │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, │ │ │ │ │ +DEVICE_CONTEXT context) │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_O_f_f_s_e_t_s_S_R_V │ │ │ │ │ +ID3D11ShaderResourceView * GetOffsetsSRV() const │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_N_u_m_S_t_e_n_c_i_l_s │ │ │ │ │ int GetNumStencils() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_I_n_d_i_c_e_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetIndicesBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_O_f_f_s_e_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetOffsetsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O │ │ │ │ │ -GLStencilTableSSBO(Far::StencilTable const *stencilTable) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_v_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetDvvWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_S_i_z_e_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetSizesBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_C_r_e_a_t_e │ │ │ │ │ -static GLStencilTableSSBO * Create(Far::LimitStencilTable const │ │ │ │ │ -*limitStencilTable, void *deviceContext=NULL) │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_u_u_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetDuuWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_G_e_t_D_v_W_e_i_g_h_t_s_B_u_f_f_e_r │ │ │ │ │ -GLuint GetDvWeightsBuffer() const │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_S_t_e_n_c_i_l_T_a_b_l_e_S_S_B_O_:_:_C_r_e_a_t_e │ │ │ │ │ -static GLStencilTableSSBO * Create(Far::StencilTable const *stencilTable, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_2_1_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ -DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, int fvarChannel, GLComputeEvaluator │ │ │ │ │ -const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_7_3_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, STENCIL_TABLE const *stencilTable) const │ │ │ │ │ -Generic stencil function. │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_4_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, │ │ │ │ │ -GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_1_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ -fvarChannel, GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_6_0_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable) const │ │ │ │ │ -Generic stencil function. │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_5_0_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_2_7_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_I_n_s_t_a_n_t_i_a_t_a_b_l_e │ │ │ │ │ -bool Instantiatable │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ -dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ -const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint │ │ │ │ │ -duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor │ │ │ │ │ -const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, int │ │ │ │ │ -numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, │ │ │ │ │ -GLuint patchIndexBuffer, GLuint patchParamsBuffer) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_~_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ -~GLComputeEvaluator() │ │ │ │ │ -Destructor. note that the GL context must be made current. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ -Generic limit eval function with derivatives. This function has a same │ │ │ │ │ -signature as other device kern... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_0_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ -GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic static stencil function. This function has a same signature as other │ │ │ │ │ -device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_2_3_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ -dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ -const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint │ │ │ │ │ -duuBuffer, BufferDescriptor const &duuDesc, GLuint duvBuffer, BufferDescriptor │ │ │ │ │ -const &duvDesc, GLuint dvvBuffer, BufferDescriptor const &dvvDesc, GLuint │ │ │ │ │ -sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, │ │ │ │ │ -GLuint duWeightsBuffer, GLuint dvWeightsBuffer, GLuint duuWeightsBuffer, GLuint │ │ │ │ │ -duvWeightsBuffer, GLuint dvvWeightsBuffer, int start, int end) const │ │ │ │ │ -Dispatch the GLSL compute kernel on GPU asynchronously returns false if the │ │ │ │ │ -kernel hasn't been compil... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_I_n_d_i_c_e_s_S_R_V │ │ │ │ │ +ID3D11ShaderResourceView * GetIndicesSRV() const │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_~_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +~D3D11StencilTable() │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e │ │ │ │ │ +D3D11StencilTable(Far::StencilTable const *stencilTable, ID3D11DeviceContext │ │ │ │ │ +*deviceContext) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_C_r_e_a_t_e │ │ │ │ │ +static D3D11StencilTable * Create(Far::StencilTable const *stencilTable, │ │ │ │ │ +ID3D11DeviceContext *deviceContext) │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_6_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_S_i_z_e_s_S_R_V │ │ │ │ │ +ID3D11ShaderResourceView * GetSizesSRV() const │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_S_t_e_n_c_i_l_T_a_b_l_e_:_:_G_e_t_W_e_i_g_h_t_s_S_R_V │ │ │ │ │ +ID3D11ShaderResourceView * GetWeightsSRV() const │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ +BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ +BufferDescriptor const &dvDesc, ID3D11DeviceContext *deviceContext) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ -const *stencilTable, GLComputeEvaluator const *instance, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -Generic static stencil function. This function has a same signature as other │ │ │ │ │ +const *stencilTable, D3D11ComputeEvaluator const *instance, ID3D11DeviceContext │ │ │ │ │ +*deviceContext) │ │ │ │ │ +Generic static compute function. This function has a same signature as other │ │ │ │ │ device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator │ │ │ │ │ -const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_4_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable, GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_7_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ -DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, │ │ │ │ │ -GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_9_0_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_5_4_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_8_1_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_4_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ -GLComputeEvaluator() │ │ │ │ │ -Constructor. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable) const │ │ │ │ │ -Generic limit eval function with derivatives. This function has a same │ │ │ │ │ -signature as other device kern... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_9_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator │ │ │ │ │ -const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_6_9_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const │ │ │ │ │ -*stencilTable) const │ │ │ │ │ -Generic stencil function. │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_3_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -bool EvalPatches(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ -dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ -const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, int │ │ │ │ │ -numPatchCoords, GLuint patchCoordsBuffer, const PatchArrayVector &patchArrays, │ │ │ │ │ -GLuint patchIndexBuffer, GLuint patchParamsBuffer) const │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel=0) │ │ │ │ │ -const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_2_0_1_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_4_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ +static D3D11ComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ -BufferDescriptor const &dvDesc, void *deviceContext=NULL) │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -bool EvalStencils(GLuint srcBuffer, BufferDescriptor const &srcDesc, GLuint │ │ │ │ │ -dstBuffer, BufferDescriptor const &dstDesc, GLuint duBuffer, BufferDescriptor │ │ │ │ │ -const &duDesc, GLuint dvBuffer, BufferDescriptor const &dvDesc, GLuint │ │ │ │ │ -sizesBuffer, GLuint offsetsBuffer, GLuint indicesBuffer, GLuint weightsBuffer, │ │ │ │ │ -GLuint duWeightsBuffer, GLuint dvWeightsBuffer, int start, int end) const │ │ │ │ │ -Dispatch the GLSL compute kernel on GPU asynchronously returns false if the │ │ │ │ │ -kernel hasn't been compil... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ -GLComputeEvaluator const *instance, void *deviceContext=NULL) │ │ │ │ │ -Generic static stencil function. This function has a same signature as other │ │ │ │ │ -device kernels have so t... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_3_2_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ -static void Synchronize(void *deviceContext) │ │ │ │ │ +BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, │ │ │ │ │ +BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, │ │ │ │ │ +ID3D11DeviceContext *deviceContext) │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_I_n_s_t_a_n_t_i_a_t_a_b_l_e │ │ │ │ │ +bool Instantiatable │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ +static void Synchronize(ID3D11DeviceContext *deviceContext) │ │ │ │ │ Wait the dispatched kernel finishes. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_o_m_p_i_l_e │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const │ │ │ │ │ +*stencilTable, ID3D11DeviceContext *deviceContext) const │ │ │ │ │ +DDeeffiinniittiioonn _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_o_m_p_i_l_e │ │ │ │ │ bool Compile(BufferDescriptor const &srcDesc, BufferDescriptor const &dstDesc, │ │ │ │ │ -BufferDescriptor const &duDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ -&dvDesc=BufferDescriptor(), BufferDescriptor const &duuDesc=BufferDescriptor(), │ │ │ │ │ -BufferDescriptor const &duvDesc=BufferDescriptor(), BufferDescriptor const │ │ │ │ │ -&dvvDesc=BufferDescriptor()) │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_3_5_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_C_r_e_a_t_e │ │ │ │ │ -static GLComputeEvaluator * Create(BufferDescriptor const &srcDesc, │ │ │ │ │ -BufferDescriptor const &dstDesc, BufferDescriptor const &duDesc, │ │ │ │ │ -BufferDescriptor const &dvDesc, BufferDescriptor const &duuDesc, │ │ │ │ │ -BufferDescriptor const &duvDesc, BufferDescriptor const &dvvDesc, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_1_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ -fvarChannel=0) const │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_1_6_6_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_G_L_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, GLComputeEvaluator const *instance, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h_:_8_7_0 │ │ │ │ │ +ID3D11DeviceContext *deviceContext) │ │ │ │ │ +Configure DX kernel. Returns false if it fails to compile the kernel. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_: │ │ │ │ │ +_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +D3D11ComputeEvaluator() │ │ │ │ │ +Constructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_: │ │ │ │ │ +_~_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r │ │ │ │ │ +~D3D11ComputeEvaluator() │ │ │ │ │ +Destructor. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_D_3_D_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +bool EvalStencils(ID3D11UnorderedAccessView *srcSRV, BufferDescriptor const │ │ │ │ │ +&srcDesc, ID3D11UnorderedAccessView *dstUAV, BufferDescriptor const &dstDesc, │ │ │ │ │ +ID3D11ShaderResourceView *sizesSRV, ID3D11ShaderResourceView *offsetsSRV, │ │ │ │ │ +ID3D11ShaderResourceView *indicesSRV, ID3D11ShaderResourceView *weightsSRV, int │ │ │ │ │ +start, int end, ID3D11DeviceContext *deviceContext) const │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _g_l_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _d_3_d_1_1_C_o_m_p_u_t_e_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00851.html │ │ │ │ @@ -96,15 +96,15 @@ │ │ │ │ Namespaces │ │ │ │
glXFBEvaluator.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include "../osd/opengl.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00851_source.html │ │ │ │ @@ -1247,17 +1247,17 @@ │ │ │ │
2189
│ │ │ │
2190} // end namespace OpenSubdiv
│ │ │ │
2191
│ │ │ │
2192
│ │ │ │
2193#endif // OPENSUBDIV3_OSD_GL_XFB_EVALUATOR_H
│ │ │ │ │ │ │ │
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ │ │ │ │ │ │ │ │
static GLStencilTableTBO * Create(Far::StencilTable const *stencilTable, void *deviceContext=NULL)
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00854.html │ │ │ │ @@ -94,15 +94,15 @@ │ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │
glslPatchShaderSource.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ #include <string>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  GLStencilTableTBO
 GL TextureBuffer stencil table. More...
│ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00854_source.html │ │ │ │ @@ -164,15 +164,15 @@ │ │ │ │
76} // end namespace OPENSUBDIV_VERSION
│ │ │ │
77using namespace OPENSUBDIV_VERSION;
│ │ │ │
78
│ │ │ │
79} // end namespace OpenSubdiv
│ │ │ │
80
│ │ │ │
81#endif // OPENSUBDIV3_OSD_GLSL_PATCH_SHADER_SOURCE
│ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │
Provides shader source which can be used by client code.
│ │ │ │
static std::string GetVertexShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │
static std::string GetPatchDrawingShaderSource()
Returns shader source which can be used while drawing piecewise parametric patches resulting from sub...
│ │ │ │
static std::string GetTessEvalShaderSource(Far::PatchDescriptor::Type type)
│ │ │ │
static std::string GetPatchBasisShaderSource()
Returns shader source which can be used to evaluate position and first and second derivatives on piec...
│ │ │ │ │ │ │ │
static std::string GetTessControlShaderSource(Far::PatchDescriptor::Type type)
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00863_source.html │ │ │ │ @@ -267,15 +267,15 @@ │ │ │ │
152using namespace OPENSUBDIV_VERSION;
│ │ │ │
153
│ │ │ │
154} // end namespace OpenSubdiv
│ │ │ │
155
│ │ │ │
156#endif // OPENSUBDIV3_OSD_GL_PATCH_TABLE_H
│ │ │ │ │ │ │ │
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
PatchArrayVector const & GetPatchArrays() const
Returns the patch arrays for vertex index buffer data.
│ │ │ │
GLuint GetFVarPatchIndexBuffer(int fvarChannel=0) const
Returns the GL index buffer containing face-varying control vertices.
│ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00866.html │ │ │ │ @@ -94,15 +94,15 @@ │ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │
glLegacyGregoryPatchTable.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │ #include "../osd/nonCopyable.h"
│ │ │ │ #include "../osd/opengl.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  GLSLPatchShaderSource
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00866_source.html │ │ │ │ @@ -192,17 +192,17 @@ │ │ │ │
81} // end namespace OPENSUBDIV_VERSION
│ │ │ │
82using namespace OPENSUBDIV_VERSION;
│ │ │ │
83
│ │ │ │
84} // end namespace OpenSubdiv
│ │ │ │
85
│ │ │ │
86#endif // OPENSUBDIV3_OSD_GL_LEGACY_GREGORY_PATCH_TABLE_H
│ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ + │ │ │ │ + │ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00872.html │ │ │ │ @@ -94,16 +94,16 @@ │ │ │ │
│ │ │ │ Namespaces | │ │ │ │ Functions
│ │ │ │
tbbKernel.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ -#include "../far/patchParam.h"
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ +#include "../far/patchParam.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00872_source.html │ │ │ │ @@ -213,15 +213,15 @@ │ │ │ │
112
│ │ │ │
113} // end namespace OpenSubdiv
│ │ │ │
114
│ │ │ │
115#endif // OPENSUBDIV3_OSD_TBB_KERNEL_H
│ │ │ │ │ │ │ │
void TbbEvalPatches(float const *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *dstDu, BufferDescriptor const &dstDuDesc, float *dstDv, BufferDescriptor const &dstDvDesc, int numPatchCoords, const PatchCoord *patchCoords, const PatchArray *patchArrayBuffer, const int *patchIndexBuffer, const PatchParam *patchParamBuffer)
│ │ │ │
void TbbEvalStencils(float const *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, int const *sizes, int const *offsets, int const *indices, float const *weights, int start, int end)
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │
Coordinates set on a patch table.
Definition types.h:42
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │ #include <cstddef>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00875_source.html │ │ │ │ @@ -604,15 +604,15 @@ │ │ │ │
1240using namespace OPENSUBDIV_VERSION;
│ │ │ │
1241
│ │ │ │
1242} // end namespace OpenSubdiv
│ │ │ │
1243
│ │ │ │
1244
│ │ │ │
1245#endif // OPENSUBDIV3_OSD_TBB_EVALUATOR_H
│ │ │ │ │ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ │ │ │ │
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, TbbEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function. This function has a same signature as other device kernels hav...
│ │ │ │
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, TbbEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, const TbbEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function with derivatives. This function has a same signature as other d...
│ │ │ │
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, int start, int end)
Static eval stencils function which takes raw CPU pointers for input and output.
│ │ │ │
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, TbbEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, TbbEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00878_source.html │ │ │ │ @@ -182,15 +182,15 @@ │ │ │ │
81using namespace OPENSUBDIV_VERSION;
│ │ │ │
82
│ │ │ │
83} // end namespace OpenSubdiv
│ │ │ │
84
│ │ │ │
85#endif // OPENSUBDIV3_OSD_OMP_KERNEL_H
│ │ │ │ │ │ │ │
void OmpEvalStencils(float const *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, int const *sizes, int const *offsets, int const *indices, float const *weights, int start, int end)
│ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │ #include <cstddef>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00881_source.html │ │ │ │ @@ -604,15 +604,15 @@ │ │ │ │
1236using namespace OPENSUBDIV_VERSION;
│ │ │ │
1237
│ │ │ │
1238} // end namespace OpenSubdiv
│ │ │ │
1239
│ │ │ │
1240
│ │ │ │
1241#endif // OPENSUBDIV3_OSD_OMP_EVALUATOR_H
│ │ │ │ │ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ │ │ │ │
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, OmpEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, int start, int end)
Static eval stencils function which takes raw CPU pointers for input and output.
│ │ │ │
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, OmpEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, const OmpEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function with derivatives. This function has a same signature as other d...
│ │ │ │
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, const float *duWeights, const float *dvWeights, int start, int end)
Static eval stencils function with derivatives, which takes raw CPU pointers for input and output.
│ │ │ │
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, OmpEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00887.html │ │ │ │ @@ -101,19 +101,19 @@ │ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include <bitset>
│ │ │ │ #include <cassert>
│ │ │ │ #include <cstring>
│ │ │ │ #include <vector>
│ │ │ │ -#include "../far/topologyRefiner.h"
│ │ │ │ -#include "../far/patchTableFactory.h"
│ │ │ │ -#include "../far/stencilTable.h"
│ │ │ │ -#include "../far/stencilTableFactory.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../far/topologyRefiner.h"
│ │ │ │ +#include "../far/patchTableFactory.h"
│ │ │ │ +#include "../far/stencilTable.h"
│ │ │ │ +#include "../far/stencilTableFactory.h"
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00887_source.html │ │ │ │ @@ -895,48 +895,48 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Far::StencilTable const * convertToCompatibleStencilTable< Far::StencilTable, Far::StencilTable, void >(Far::StencilTable const *table, void *)
Definition mesh.h:149
│ │ │ │
Far::LimitStencilTable const * convertToCompatibleStencilTable< Far::LimitStencilTable, Far::LimitStencilTable, void >(Far::LimitStencilTable const *table, void *)
Definition mesh.h:159
│ │ │ │
std::bitset< NUM_MESH_BITS > MeshBitset
Definition mesh.h:63
│ │ │ │
Far::StencilTable const * convertToCompatibleStencilTable< Far::StencilTable, Far::StencilTable, ID3D11DeviceContext >(Far::StencilTable const *table, ID3D11DeviceContext *)
Definition mesh.h:169
│ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ -
int GetMaxValence() const
Returns max vertex valence.
Definition patchTable.h:92
│ │ │ │ -
StencilTable const * GetLocalPointStencilTable() const
Returns the stencil table to compute local point vertex values.
Definition patchTable.h:778
│ │ │ │ -
StencilTable const * GetLocalPointVaryingStencilTable() const
Returns the stencil table to compute local point varying values.
Definition patchTable.h:783
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
int GetMaxValence() const
Returns max vertex valence.
Definition patchTable.h:92
│ │ │ │ +
StencilTable const * GetLocalPointStencilTable() const
Returns the stencil table to compute local point vertex values.
Definition patchTable.h:778
│ │ │ │ +
StencilTable const * GetLocalPointVaryingStencilTable() const
Returns the stencil table to compute local point varying values.
Definition patchTable.h:783
│ │ │ │
static PatchTable * Create(TopologyRefiner const &refiner, Options options=Options(), ConstIndexArray selectedFaces=ConstIndexArray())
Instantiates a PatchTable from a client-provided TopologyRefiner.
│ │ │ │ - │ │ │ │ -
@ ENDCAP_LEGACY_GREGORY
legacy option for 2.x style Gregory patches (Catmark only)
│ │ │ │ -
@ ENDCAP_GREGORY_BASIS
use Gregory patches (highest quality, recommended default)
│ │ │ │ -
@ ENDCAP_BILINEAR_BASIS
use linear patches (simple quads or tris)
│ │ │ │ -
@ ENDCAP_BSPLINE_BASIS
use BSpline-like patches (same patch type as regular)
│ │ │ │ - │ │ │ │ -
int GetNumControlVertices() const
Returns the number of control vertices indexed in the table.
│ │ │ │ -
int GetNumStencils() const
Returns the number of stencils in the table.
│ │ │ │ -
Stencil table class wrapping the template for compatibility.
│ │ │ │ -
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ -
static StencilTable const * Create(TopologyRefiner const &refiner, Options options=Options())
│ │ │ │ -
static StencilTable const * AppendLocalPointStencilTable(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, bool factorize=true)
│ │ │ │ -
int GetNumVertices() const
Return the number of vertices in this level.
│ │ │ │ -
Stores topology data for a specified set of refinement options.
│ │ │ │ -
bool IsUniform() const
Returns true if uniform refinement has been applied.
│ │ │ │ -
int GetNumFVarChannels() const
Returns the number of face-varying channels in the tables.
│ │ │ │ + │ │ │ │ +
@ ENDCAP_LEGACY_GREGORY
legacy option for 2.x style Gregory patches (Catmark only)
│ │ │ │ +
@ ENDCAP_GREGORY_BASIS
use Gregory patches (highest quality, recommended default)
│ │ │ │ +
@ ENDCAP_BILINEAR_BASIS
use linear patches (simple quads or tris)
│ │ │ │ +
@ ENDCAP_BSPLINE_BASIS
use BSpline-like patches (same patch type as regular)
│ │ │ │ + │ │ │ │ +
int GetNumControlVertices() const
Returns the number of control vertices indexed in the table.
│ │ │ │ +
int GetNumStencils() const
Returns the number of stencils in the table.
│ │ │ │ +
Stencil table class wrapping the template for compatibility.
│ │ │ │ +
Limit stencil table class wrapping the template for compatibility.
│ │ │ │ +
static StencilTable const * Create(TopologyRefiner const &refiner, Options options=Options())
│ │ │ │ +
static StencilTable const * AppendLocalPointStencilTable(TopologyRefiner const &refiner, StencilTable const *baseStencilTable, StencilTable const *localPointStencilTable, bool factorize=true)
│ │ │ │ +
int GetNumVertices() const
Return the number of vertices in this level.
│ │ │ │ +
Stores topology data for a specified set of refinement options.
│ │ │ │ +
bool IsUniform() const
Returns true if uniform refinement has been applied.
│ │ │ │ +
int GetNumFVarChannels() const
Returns the number of face-varying channels in the tables.
│ │ │ │
void RefineUniform(UniformOptions options)
Refine the topology uniformly.
│ │ │ │ -
TopologyLevel const & GetLevel(int level) const
Returns a handle to access data specific to a particular level.
│ │ │ │ +
TopologyLevel const & GetLevel(int level) const
Returns a handle to access data specific to a particular level.
│ │ │ │
void RefineAdaptive(AdaptiveOptions options, ConstIndexArray selectedFaces=ConstIndexArray())
Feature Adaptive topology refinement.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │
virtual Far::PatchTable const * GetFarPatchTable() const =0
│ │ │ │
static void refineMesh(Far::TopologyRefiner &refiner, int level, MeshBitset bits)
Definition mesh.h:117
│ │ │ │ │ │ │ │ │ │ │ │
virtual void UpdateVaryingBuffer(float const *varyingData, int startVertex, int numVerts)=0
│ │ │ │
static void refineMesh(Far::TopologyRefiner &refiner, int level, bool adaptive, bool singleCreasePatch)
Definition mesh.h:101
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00893.html │ │ │ │ @@ -95,15 +95,15 @@ │ │ │ │ Classes | │ │ │ │ Namespaces │ │ │ │
cpuPatchTable.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ #include <vector>
│ │ │ │ -#include "../far/patchDescriptor.h"
│ │ │ │ +#include "../far/patchDescriptor.h"
│ │ │ │ #include "../osd/nonCopyable.h"
│ │ │ │ #include "../osd/types.h"
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

class  MeshInterface< PATCH_TABLE >
 
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00893_source.html │ │ │ │ @@ -264,15 +264,15 @@ │ │ │ │
142
│ │ │ │
143} // end namespace OpenSubdiv
│ │ │ │
144
│ │ │ │
145#endif // OPENSUBDIV3_OSD_CPU_PATCH_TABLE_H
│ │ │ │ │ │ │ │
std::vector< PatchParam > PatchParamVector
Definition types.h:133
│ │ │ │
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ -
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ +
Container for arrays of parametric patches.
Definition patchTable.h:55
│ │ │ │ │ │ │ │
const PatchArray * GetFVarPatchArrayBuffer(int fvarChannel=0) const
│ │ │ │ │ │ │ │ │ │ │ │
size_t GetFVarPatchParamSize(int fvarChannel=0) const
│ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00896.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/cpuEvaluator.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/bufferDescriptor.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,27 +90,26 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
cpuEvaluator.h File Reference
│ │ │ │ +
bufferDescriptor.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../osd/bufferDescriptor.h"
│ │ │ │ -#include "../osd/types.h"
│ │ │ │ -#include <cstddef>
│ │ │ │ +#include <string.h>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │

│ │ │ │ Classes

│ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  CpuEvaluator
struct  BufferDescriptor
 BufferDescriptor is a struct which describes buffer elements in interleaved data buffers. Almost all Osd Evaluator APIs take BufferDescriptors along with device-specific buffer objects. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -119,13 +118,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,25 +1,26 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -cpuEvaluator.h File Reference │ │ │ │ │ +bufferDescriptor.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ -#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -class   _C_p_u_E_v_a_l_u_a_t_o_r │ │ │ │ │ +struct   _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ + _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r is a struct which describes buffer elements in │ │ │ │ │ +  interleaved data buffers. Almost all _O_s_d Evaluator APIs take │ │ │ │ │ + BufferDescriptors along with device-specific buffer objects. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _c_p_u_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00896.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00896 = [ │ │ │ │ │ - ["CpuEvaluator", "a01165.html", null] │ │ │ │ │ + ["BufferDescriptor", "a01141.html", "a01141"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00896_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/cpuEvaluator.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/bufferDescriptor.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
cpuEvaluator.h
│ │ │ │ +
bufferDescriptor.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,529 +119,112 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_CPU_EVALUATOR_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_CPU_EVALUATOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29#include "../osd/bufferDescriptor.h"
│ │ │ │ -
30#include "../osd/types.h"
│ │ │ │ -
31
│ │ │ │ -
32#include <cstddef>
│ │ │ │ +
29#include <string.h>
│ │ │ │ +
30
│ │ │ │ +
31namespace OpenSubdiv {
│ │ │ │ +
32namespace OPENSUBDIV_VERSION {
│ │ │ │
33
│ │ │ │ -
34namespace OpenSubdiv {
│ │ │ │ -
35namespace OPENSUBDIV_VERSION {
│ │ │ │ -
36
│ │ │ │ -
37namespace Osd {
│ │ │ │ -
38
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
40public:
│ │ │ │ +
│ │ │ │ +
34namespace Osd {
│ │ │ │ +
35
│ │ │ │
46
│ │ │ │ -
71 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
72 static bool EvalStencils(
│ │ │ │ -
73 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
74 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
75 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
76 const CpuEvaluator *instance = NULL,
│ │ │ │ -
77 void * deviceContext = NULL) {
│ │ │ │ -
78
│ │ │ │ -
79 (void)instance; // unused
│ │ │ │ -
80 (void)deviceContext; // unused
│ │ │ │ -
81
│ │ │ │ -
82 if (stencilTable->GetNumStencils() == 0)
│ │ │ │ -
83 return false;
│ │ │ │ +
47// example:
│ │ │ │ +
48// n
│ │ │ │ +
49// -----+----------------------------------------+-------------------------
│ │ │ │ +
50// | vertex 0 |
│ │ │ │ +
51// -----+----------------------------------------+-------------------------
│ │ │ │ +
52// | X Y Z R G B A Xu Yu Zu Xv Yv Zv |
│ │ │ │ +
53// -----+----------------------------------------+-------------------------
│ │ │ │ +
54// <------------- stride = 13 -------------->
│ │ │ │ +
55//
│ │ │ │ +
56// - XYZ (offset = n+0, length = 3, stride = 13)
│ │ │ │ +
57// - RGBA (offset = n+3, length = 4, stride = 13)
│ │ │ │ +
58// - uTangent (offset = n+7, length = 3, stride = 13)
│ │ │ │ +
59// - vTangent (offset = n+10, length = 3, stride = 13)
│ │ │ │ +
60//
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
62
│ │ │ │ + │ │ │ │ +
65
│ │ │ │ +
67 BufferDescriptor(int o, int l, int s) : offset(o), length(l), stride(s) { }
│ │ │ │ +
68
│ │ │ │ +
│ │ │ │ +
70 int GetLocalOffset() const {
│ │ │ │ +
71 return stride > 0 ? offset % stride : 0;
│ │ │ │ +
72 }
│ │ │ │ +
│ │ │ │ +
73
│ │ │ │ +
│ │ │ │ +
75 bool IsValid() const {
│ │ │ │ +
76 return ((length > 0) &&
│ │ │ │ + │ │ │ │ +
78 }
│ │ │ │ +
│ │ │ │ +
79
│ │ │ │ +
│ │ │ │ +
81 void Reset() {
│ │ │ │ +
82 offset = length = stride = 0;
│ │ │ │ +
83 }
│ │ │ │ +
│ │ │ │
84
│ │ │ │ -
85 return EvalStencils(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
86 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
87 &stencilTable->GetSizes()[0],
│ │ │ │ -
88 &stencilTable->GetOffsets()[0],
│ │ │ │ -
89 &stencilTable->GetControlIndices()[0],
│ │ │ │ -
90 &stencilTable->GetWeights()[0],
│ │ │ │ -
91 /*start = */ 0,
│ │ │ │ -
92 /*end = */ stencilTable->GetNumStencils());
│ │ │ │ -
93 }
│ │ │ │ -
│ │ │ │ -
94
│ │ │ │ -
121 static bool EvalStencils(
│ │ │ │ -
122 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ -
123 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
124 const int * sizes,
│ │ │ │ -
125 const int * offsets,
│ │ │ │ -
126 const int * indices,
│ │ │ │ -
127 const float * weights,
│ │ │ │ -
128 int start, int end);
│ │ │ │ -
129
│ │ │ │ -
167 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
168 static bool EvalStencils(
│ │ │ │ -
169 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
170 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
171 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
172 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
173 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
174 const CpuEvaluator *instance = NULL,
│ │ │ │ -
175 void * deviceContext = NULL) {
│ │ │ │ -
176
│ │ │ │ -
177 (void)instance; // unused
│ │ │ │ -
178 (void)deviceContext; // unused
│ │ │ │ -
179
│ │ │ │ -
180 return EvalStencils(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
181 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
182 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
183 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
184 &stencilTable->GetSizes()[0],
│ │ │ │ -
185 &stencilTable->GetOffsets()[0],
│ │ │ │ -
186 &stencilTable->GetControlIndices()[0],
│ │ │ │ -
187 &stencilTable->GetWeights()[0],
│ │ │ │ -
188 &stencilTable->GetDuWeights()[0],
│ │ │ │ -
189 &stencilTable->GetDvWeights()[0],
│ │ │ │ -
190 /*start = */ 0,
│ │ │ │ -
191 /*end = */ stencilTable->GetNumStencils());
│ │ │ │ -
192 }
│ │ │ │ -
│ │ │ │ -
193
│ │ │ │ -
234 static bool EvalStencils(
│ │ │ │ -
235 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ -
236 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
237 float *du, BufferDescriptor const &duDesc,
│ │ │ │ -
238 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
239 const int * sizes,
│ │ │ │ -
240 const int * offsets,
│ │ │ │ -
241 const int * indices,
│ │ │ │ -
242 const float * weights,
│ │ │ │ -
243 const float * duWeights,
│ │ │ │ -
244 const float * dvWeights,
│ │ │ │ -
245 int start, int end);
│ │ │ │ -
246
│ │ │ │ -
302 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ -
│ │ │ │ -
303 static bool EvalStencils(
│ │ │ │ -
304 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
305 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
306 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
307 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
308 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
309 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
310 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
311 STENCIL_TABLE const *stencilTable,
│ │ │ │ -
312 const CpuEvaluator *instance = NULL,
│ │ │ │ -
313 void * deviceContext = NULL) {
│ │ │ │ -
314
│ │ │ │ -
315 (void)instance; // unused
│ │ │ │ -
316 (void)deviceContext; // unused
│ │ │ │ -
317
│ │ │ │ -
318 return EvalStencils(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
319 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
320 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
321 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
322 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ -
323 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ -
324 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ -
325 &stencilTable->GetSizes()[0],
│ │ │ │ -
326 &stencilTable->GetOffsets()[0],
│ │ │ │ -
327 &stencilTable->GetControlIndices()[0],
│ │ │ │ -
328 &stencilTable->GetWeights()[0],
│ │ │ │ -
329 &stencilTable->GetDuWeights()[0],
│ │ │ │ -
330 &stencilTable->GetDvWeights()[0],
│ │ │ │ -
331 &stencilTable->GetDuuWeights()[0],
│ │ │ │ -
332 &stencilTable->GetDuvWeights()[0],
│ │ │ │ -
333 &stencilTable->GetDvvWeights()[0],
│ │ │ │ -
334 /*start = */ 0,
│ │ │ │ -
335 /*end = */ stencilTable->GetNumStencils());
│ │ │ │ -
336 }
│ │ │ │ -
│ │ │ │ -
337
│ │ │ │ -
399 static bool EvalStencils(
│ │ │ │ -
400 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ -
401 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
402 float *du, BufferDescriptor const &duDesc,
│ │ │ │ -
403 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
404 float *duu, BufferDescriptor const &duuDesc,
│ │ │ │ -
405 float *duv, BufferDescriptor const &duvDesc,
│ │ │ │ -
406 float *dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ -
407 const int * sizes,
│ │ │ │ -
408 const int * offsets,
│ │ │ │ -
409 const int * indices,
│ │ │ │ -
410 const float * weights,
│ │ │ │ -
411 const float * duWeights,
│ │ │ │ -
412 const float * dvWeights,
│ │ │ │ -
413 const float * duuWeights,
│ │ │ │ -
414 const float * duvWeights,
│ │ │ │ -
415 const float * dvvWeights,
│ │ │ │ -
416 int start, int end);
│ │ │ │ -
417
│ │ │ │ -
423
│ │ │ │ -
452 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
453 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ -
454 static bool EvalPatches(
│ │ │ │ -
455 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
456 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
457 int numPatchCoords,
│ │ │ │ -
458 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
459 PATCH_TABLE *patchTable,
│ │ │ │ -
460 CpuEvaluator const *instance = NULL,
│ │ │ │ -
461 void * deviceContext = NULL) {
│ │ │ │ -
462
│ │ │ │ -
463 (void)instance; // unused
│ │ │ │ -
464 (void)deviceContext; // unused
│ │ │ │ -
465
│ │ │ │ -
466 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
467 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
468 numPatchCoords,
│ │ │ │ -
469 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
470 patchTable->GetPatchArrayBuffer(),
│ │ │ │ -
471 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
472 patchTable->GetPatchParamBuffer());
│ │ │ │ -
473 }
│ │ │ │ -
│ │ │ │ -
474
│ │ │ │ -
515 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
516 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ -
517 static bool EvalPatches(
│ │ │ │ -
518 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
519 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
520 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
521 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
522 int numPatchCoords,
│ │ │ │ -
523 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
524 PATCH_TABLE *patchTable,
│ │ │ │ -
525 CpuEvaluator const *instance = NULL,
│ │ │ │ -
526 void * deviceContext = NULL) {
│ │ │ │ -
527
│ │ │ │ -
528 (void)instance; // unused
│ │ │ │ -
529 (void)deviceContext; // unused
│ │ │ │ -
530
│ │ │ │ -
531 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop.
│ │ │ │ -
532 // ideally all buffer classes should have templated by datatype
│ │ │ │ -
533 // so that downcast isn't needed there.
│ │ │ │ -
534 // (e.g. Osd::CpuBuffer<PatchCoord> )
│ │ │ │ -
535 //
│ │ │ │ -
536 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
537 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
538 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
539 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
540 numPatchCoords,
│ │ │ │ -
541 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
542 patchTable->GetPatchArrayBuffer(),
│ │ │ │ -
543 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
544 patchTable->GetPatchParamBuffer());
│ │ │ │ -
545 }
│ │ │ │ -
│ │ │ │ -
546
│ │ │ │ -
605 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
606 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ -
607 static bool EvalPatches(
│ │ │ │ -
608 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
609 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
610 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
611 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
612 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
613 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
614 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
615 int numPatchCoords,
│ │ │ │ -
616 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
617 PATCH_TABLE *patchTable,
│ │ │ │ -
618 CpuEvaluator const *instance = NULL,
│ │ │ │ -
619 void * deviceContext = NULL) {
│ │ │ │ -
620
│ │ │ │ -
621 (void)instance; // unused
│ │ │ │ -
622 (void)deviceContext; // unused
│ │ │ │ -
623
│ │ │ │ -
624 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop.
│ │ │ │ -
625 // ideally all buffer classes should have templated by datatype
│ │ │ │ -
626 // so that downcast isn't needed there.
│ │ │ │ -
627 // (e.g. Osd::CpuBuffer<PatchCoord> )
│ │ │ │ -
628 //
│ │ │ │ -
629 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
630 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
631 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
632 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
633 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ -
634 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ -
635 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ -
636 numPatchCoords,
│ │ │ │ -
637 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
638 patchTable->GetPatchArrayBuffer(),
│ │ │ │ -
639 patchTable->GetPatchIndexBuffer(),
│ │ │ │ -
640 patchTable->GetPatchParamBuffer());
│ │ │ │ -
641 }
│ │ │ │ -
│ │ │ │ -
642
│ │ │ │ -
670 static bool EvalPatches(
│ │ │ │ -
671 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ -
672 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
673 int numPatchCoords,
│ │ │ │ -
674 const PatchCoord *patchCoords,
│ │ │ │ -
675 const PatchArray *patchArrays,
│ │ │ │ -
676 const int *patchIndexBuffer,
│ │ │ │ -
677 const PatchParam *patchParamBuffer);
│ │ │ │ -
678
│ │ │ │ -
716 static bool EvalPatches(
│ │ │ │ -
717 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ -
718 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
719 float *du, BufferDescriptor const &duDesc,
│ │ │ │ -
720 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
721 int numPatchCoords,
│ │ │ │ -
722 PatchCoord const *patchCoords,
│ │ │ │ -
723 PatchArray const *patchArrays,
│ │ │ │ -
724 const int *patchIndexBuffer,
│ │ │ │ -
725 PatchParam const *patchParamBuffer);
│ │ │ │ -
726
│ │ │ │ -
779 static bool EvalPatches(
│ │ │ │ -
780 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ -
781 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ -
782 float *du, BufferDescriptor const &duDesc,
│ │ │ │ -
783 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ -
784 float *duu, BufferDescriptor const &duuDesc,
│ │ │ │ -
785 float *duv, BufferDescriptor const &duvDesc,
│ │ │ │ -
786 float *dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ -
787 int numPatchCoords,
│ │ │ │ -
788 PatchCoord const *patchCoords,
│ │ │ │ -
789 PatchArray const *patchArrays,
│ │ │ │ -
790 const int *patchIndexBuffer,
│ │ │ │ -
791 PatchParam const *patchParamBuffer);
│ │ │ │ -
792
│ │ │ │ -
821 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
822 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
824 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
825 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
826 int numPatchCoords,
│ │ │ │ -
827 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
828 PATCH_TABLE *patchTable,
│ │ │ │ -
829 CpuEvaluator const *instance = NULL,
│ │ │ │ -
830 void * deviceContext = NULL) {
│ │ │ │ -
831
│ │ │ │ -
832 (void)instance; // unused
│ │ │ │ -
833 (void)deviceContext; // unused
│ │ │ │ -
834
│ │ │ │ -
835 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
836 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
837 numPatchCoords,
│ │ │ │ -
838 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
839 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ -
840 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
841 patchTable->GetPatchParamBuffer());
│ │ │ │ -
842 }
│ │ │ │ -
│ │ │ │ -
843
│ │ │ │ -
884 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
885 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
887 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
888 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
889 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
890 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
891 int numPatchCoords,
│ │ │ │ -
892 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
893 PATCH_TABLE *patchTable,
│ │ │ │ -
894 CpuEvaluator const *instance = NULL,
│ │ │ │ -
895 void * deviceContext = NULL) {
│ │ │ │ -
896
│ │ │ │ -
897 (void)instance; // unused
│ │ │ │ -
898 (void)deviceContext; // unused
│ │ │ │ -
899
│ │ │ │ -
900 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
901 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
902 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
903 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
904 numPatchCoords,
│ │ │ │ -
905 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
906 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ -
907 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
908 patchTable->GetPatchParamBuffer());
│ │ │ │ -
909 }
│ │ │ │ -
│ │ │ │ -
910
│ │ │ │ -
969 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
970 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
972 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
973 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
974 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
975 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
976 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
977 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
978 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
979 int numPatchCoords,
│ │ │ │ -
980 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
981 PATCH_TABLE *patchTable,
│ │ │ │ -
982 CpuEvaluator const *instance = NULL,
│ │ │ │ -
983 void * deviceContext = NULL) {
│ │ │ │ -
984
│ │ │ │ -
985 (void)instance; // unused
│ │ │ │ -
986 (void)deviceContext; // unused
│ │ │ │ -
987
│ │ │ │ -
988 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
989 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
990 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
991 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
992 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ -
993 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ -
994 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ -
995 numPatchCoords,
│ │ │ │ -
996 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
997 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ -
998 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ -
999 patchTable->GetPatchParamBuffer());
│ │ │ │ -
1000 }
│ │ │ │ -
│ │ │ │ -
1001
│ │ │ │ -
1032 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1033 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1035 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1036 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1037 int numPatchCoords,
│ │ │ │ -
1038 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1039 PATCH_TABLE *patchTable,
│ │ │ │ -
1040 int fvarChannel,
│ │ │ │ -
1041 CpuEvaluator const *instance = NULL,
│ │ │ │ -
1042 void * deviceContext = NULL) {
│ │ │ │ -
1043
│ │ │ │ -
1044 (void)instance; // unused
│ │ │ │ -
1045 (void)deviceContext; // unused
│ │ │ │ -
1046
│ │ │ │ -
1047 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
1048 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
1049 numPatchCoords,
│ │ │ │ -
1050 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
1051 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ -
1052 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
1053 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ -
1054 }
│ │ │ │ -
│ │ │ │ -
1055
│ │ │ │ -
1098 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1099 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1101 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1102 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1103 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1104 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1105 int numPatchCoords,
│ │ │ │ -
1106 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1107 PATCH_TABLE *patchTable,
│ │ │ │ -
1108 int fvarChannel,
│ │ │ │ -
1109 CpuEvaluator const *instance = NULL,
│ │ │ │ -
1110 void * deviceContext = NULL) {
│ │ │ │ -
1111
│ │ │ │ -
1112 (void)instance; // unused
│ │ │ │ -
1113 (void)deviceContext; // unused
│ │ │ │ -
1114
│ │ │ │ -
1115 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
1116 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
1117 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
1118 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
1119 numPatchCoords,
│ │ │ │ -
1120 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
1121 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ -
1122 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
1123 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ -
1124 }
│ │ │ │ -
│ │ │ │ -
1125
│ │ │ │ -
1186 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ -
1187 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
1189 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ -
1190 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ -
1191 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ -
1192 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ -
1193 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ -
1194 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ -
1195 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ -
1196 int numPatchCoords,
│ │ │ │ -
1197 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ -
1198 PATCH_TABLE *patchTable,
│ │ │ │ -
1199 int fvarChannel,
│ │ │ │ -
1200 CpuEvaluator const *instance = NULL,
│ │ │ │ -
1201 void * deviceContext = NULL) {
│ │ │ │ -
1202
│ │ │ │ -
1203 (void)instance; // unused
│ │ │ │ -
1204 (void)deviceContext; // unused
│ │ │ │ -
1205
│ │ │ │ -
1206 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ -
1207 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ -
1208 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ -
1209 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ -
1210 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ -
1211 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ -
1212 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ -
1213 numPatchCoords,
│ │ │ │ -
1214 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ -
1215 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ -
1216 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ -
1217 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ -
1218 }
│ │ │ │ -
│ │ │ │ -
1219
│ │ │ │ -
1225
│ │ │ │ -
│ │ │ │ -
1227 static void Synchronize(void * /*deviceContext = NULL*/) {
│ │ │ │ -
1228 // nothing.
│ │ │ │ -
1229 }
│ │ │ │ -
│ │ │ │ -
1230};
│ │ │ │ -
│ │ │ │ -
1231
│ │ │ │ -
1232
│ │ │ │ -
1233} // end namespace Osd
│ │ │ │ -
1234
│ │ │ │ -
1235} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
1236using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
1237
│ │ │ │ -
1238} // end namespace OpenSubdiv
│ │ │ │ -
1239
│ │ │ │ -
1240
│ │ │ │ -
1241#endif // OPENSUBDIV3_OSD_CPU_EVALUATOR_H
│ │ │ │ +
│ │ │ │ +
86 bool operator == (BufferDescriptor const &other) const {
│ │ │ │ +
87 return (offset == other.offset &&
│ │ │ │ +
88 length == other.length &&
│ │ │ │ +
89 stride == other.stride);
│ │ │ │ +
90 }
│ │ │ │ +
│ │ │ │ +
91
│ │ │ │ +
│ │ │ │ +
93 bool operator != (BufferDescriptor const &other) const {
│ │ │ │ +
94 return !(this->operator==(other));
│ │ │ │ +
95 }
│ │ │ │ +
│ │ │ │ +
96
│ │ │ │ +
98 int offset;
│ │ │ │ + │ │ │ │ + │ │ │ │ +
103};
│ │ │ │ +
│ │ │ │ +
104
│ │ │ │ +
105} // end namespace Osd
│ │ │ │ +
│ │ │ │ +
106
│ │ │ │ +
107} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
108using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
109
│ │ │ │ +
110} // end namespace OpenSubdiv
│ │ │ │ +
111
│ │ │ │ +
112#endif // OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H
│ │ │ │ │ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, int start, int end)
Static eval stencils function which takes raw CPU pointers for input and output.
│ │ │ │ -
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, const float *duWeights, const float *dvWeights, int start, int end)
Static eval stencils function with derivatives, which takes raw CPU pointers for input and output.
│ │ │ │ -
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, float *dvv, BufferDescriptor const &dvvDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, const float *duWeights, const float *dvWeights, const float *duuWeights, const float *duvWeights, const float *dvvWeights, int start, int end)
Static eval stencils function with derivatives, which takes raw CPU pointers for input and output.
│ │ │ │ -
static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, float *dvv, BufferDescriptor const &dvvDesc, int numPatchCoords, PatchCoord const *patchCoords, PatchArray const *patchArrays, const int *patchIndexBuffer, PatchParam const *patchParamBuffer)
Static limit eval function. It takes an array of PatchCoord and evaluate limit values on given PatchT...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ -
static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, int numPatchCoords, PatchCoord const *patchCoords, PatchArray const *patchArrays, const int *patchIndexBuffer, PatchParam const *patchParamBuffer)
Static limit eval function. It takes an array of PatchCoord and evaluate limit values on given PatchT...
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function with derivatives. This function has a same signature as other d...
│ │ │ │ -
static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, int numPatchCoords, const PatchCoord *patchCoords, const PatchArray *patchArrays, const int *patchIndexBuffer, const PatchParam *patchParamBuffer)
Static limit eval function. It takes an array of PatchCoord and evaluate limit values on given PatchT...
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ -
static void Synchronize(void *)
synchronize all asynchronous computation invoked on this device.
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function. This function has a same signature as other device kernels hav...
│ │ │ │ -
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ -
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function with derivatives. This function has a same signature as other d...
│ │ │ │ -
Coordinates set on a patch table.
Definition types.h:42
│ │ │ │ - │ │ │ │ - │ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ +
void Reset()
Resets the descriptor to default.
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │ +
bool operator!=(BufferDescriptor const &other) const
True if the descriptors are not identical.
│ │ │ │ +
bool operator==(BufferDescriptor const &other) const
True if the descriptors are identical.
│ │ │ │ +
bool IsValid() const
True if the descriptor values are internally consistent.
│ │ │ │ +
int GetLocalOffset() const
Returns the relative offset within a stride.
│ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -cpuEvaluator.h │ │ │ │ │ +bufferDescriptor.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,655 +24,125 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_CPU_EVALUATOR_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_CPU_EVALUATOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29#include "../osd/bufferDescriptor.h" │ │ │ │ │ -30#include "../osd/types.h" │ │ │ │ │ -31 │ │ │ │ │ -32#include │ │ │ │ │ +29#include │ │ │ │ │ +30 │ │ │ │ │ +31namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +32namespace OPENSUBDIV_VERSION { │ │ │ │ │ 33 │ │ │ │ │ -34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -35namespace OPENSUBDIV_VERSION { │ │ │ │ │ -36 │ │ │ │ │ -37namespace Osd { │ │ │ │ │ -38 │ │ │ │ │ -_3_9class _C_p_u_E_v_a_l_u_a_t_o_r { │ │ │ │ │ -40public: │ │ │ │ │ +_3_4namespace Osd { │ │ │ │ │ +35 │ │ │ │ │ 46 │ │ │ │ │ -71 template │ │ │ │ │ -_7_2 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -73 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -74 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -75 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -76 const _C_p_u_E_v_a_l_u_a_t_o_r *instance = NULL, │ │ │ │ │ -77 void * deviceContext = NULL) { │ │ │ │ │ -78 │ │ │ │ │ -79 (void)instance; // unused │ │ │ │ │ -80 (void)deviceContext; // unused │ │ │ │ │ -81 │ │ │ │ │ -82 if (stencilTable->GetNumStencils() == 0) │ │ │ │ │ -83 return false; │ │ │ │ │ +47// example: │ │ │ │ │ +48// n │ │ │ │ │ +49// -----+----------------------------------------+------------------------- │ │ │ │ │ +50// | vertex 0 | │ │ │ │ │ +51// -----+----------------------------------------+------------------------- │ │ │ │ │ +52// | X Y Z R G B A Xu Yu Zu Xv Yv Zv | │ │ │ │ │ +53// -----+----------------------------------------+------------------------- │ │ │ │ │ +54// <------------- stride = 13 --------------> │ │ │ │ │ +55// │ │ │ │ │ +56// - XYZ (offset = n+0, length = 3, stride = 13) │ │ │ │ │ +57// - RGBA (offset = n+3, length = 4, stride = 13) │ │ │ │ │ +58// - uTangent (offset = n+7, length = 3, stride = 13) │ │ │ │ │ +59// - vTangent (offset = n+10, length = 3, stride = 13) │ │ │ │ │ +60// │ │ │ │ │ +_6_1struct _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ +62 │ │ │ │ │ +_6_4 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r() : _o_f_f_s_e_t(0), _l_e_n_g_t_h(0), _s_t_r_i_d_e(0) { } │ │ │ │ │ +65 │ │ │ │ │ +_6_7 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(int o, int l, int s) : _o_f_f_s_e_t(o), _l_e_n_g_t_h(l), _s_t_r_i_d_e(s) { } │ │ │ │ │ +68 │ │ │ │ │ +_7_0 int _G_e_t_L_o_c_a_l_O_f_f_s_e_t() const { │ │ │ │ │ +71 return _s_t_r_i_d_e > 0 ? _o_f_f_s_e_t % _s_t_r_i_d_e : 0; │ │ │ │ │ +72 } │ │ │ │ │ +73 │ │ │ │ │ +_7_5 bool _I_s_V_a_l_i_d() const { │ │ │ │ │ +76 return ((_l_e_n_g_t_h > 0) && │ │ │ │ │ +77 (_l_e_n_g_t_h <= _s_t_r_i_d_e - _G_e_t_L_o_c_a_l_O_f_f_s_e_t())); │ │ │ │ │ +78 } │ │ │ │ │ +79 │ │ │ │ │ +_8_1 void _R_e_s_e_t() { │ │ │ │ │ +82 _o_f_f_s_e_t = _l_e_n_g_t_h = _s_t_r_i_d_e = 0; │ │ │ │ │ +83 } │ │ │ │ │ 84 │ │ │ │ │ -85 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -86 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -87 &stencilTable->GetSizes()[0], │ │ │ │ │ -88 &stencilTable->GetOffsets()[0], │ │ │ │ │ -89 &stencilTable->GetControlIndices()[0], │ │ │ │ │ -90 &stencilTable->GetWeights()[0], │ │ │ │ │ -91 /*start = */ 0, │ │ │ │ │ -92 /*end = */ stencilTable->GetNumStencils()); │ │ │ │ │ -93 } │ │ │ │ │ -94 │ │ │ │ │ -_1_2_1 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -122 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -123 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -124 const int * sizes, │ │ │ │ │ -125 const int * offsets, │ │ │ │ │ -126 const int * indices, │ │ │ │ │ -127 const float * weights, │ │ │ │ │ -128 int start, int end); │ │ │ │ │ -129 │ │ │ │ │ -167 template │ │ │ │ │ -_1_6_8 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -169 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -170 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -171 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -172 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -173 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -174 const _C_p_u_E_v_a_l_u_a_t_o_r *instance = NULL, │ │ │ │ │ -175 void * deviceContext = NULL) { │ │ │ │ │ -176 │ │ │ │ │ -177 (void)instance; // unused │ │ │ │ │ -178 (void)deviceContext; // unused │ │ │ │ │ -179 │ │ │ │ │ -180 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -181 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -182 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -183 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -184 &stencilTable->GetSizes()[0], │ │ │ │ │ -185 &stencilTable->GetOffsets()[0], │ │ │ │ │ -186 &stencilTable->GetControlIndices()[0], │ │ │ │ │ -187 &stencilTable->GetWeights()[0], │ │ │ │ │ -188 &stencilTable->GetDuWeights()[0], │ │ │ │ │ -189 &stencilTable->GetDvWeights()[0], │ │ │ │ │ -190 /*start = */ 0, │ │ │ │ │ -191 /*end = */ stencilTable->GetNumStencils()); │ │ │ │ │ -192 } │ │ │ │ │ -193 │ │ │ │ │ -_2_3_4 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -235 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -236 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -237 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -238 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -239 const int * sizes, │ │ │ │ │ -240 const int * offsets, │ │ │ │ │ -241 const int * indices, │ │ │ │ │ -242 const float * weights, │ │ │ │ │ -243 const float * duWeights, │ │ │ │ │ -244 const float * dvWeights, │ │ │ │ │ -245 int start, int end); │ │ │ │ │ -246 │ │ │ │ │ -302 template │ │ │ │ │ -_3_0_3 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -304 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -305 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -306 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -307 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -308 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -309 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -310 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -311 STENCIL_TABLE const *stencilTable, │ │ │ │ │ -312 const _C_p_u_E_v_a_l_u_a_t_o_r *instance = NULL, │ │ │ │ │ -313 void * deviceContext = NULL) { │ │ │ │ │ -314 │ │ │ │ │ -315 (void)instance; // unused │ │ │ │ │ -316 (void)deviceContext; // unused │ │ │ │ │ -317 │ │ │ │ │ -318 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -319 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -320 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -321 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -322 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ -323 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ -324 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ -325 &stencilTable->GetSizes()[0], │ │ │ │ │ -326 &stencilTable->GetOffsets()[0], │ │ │ │ │ -327 &stencilTable->GetControlIndices()[0], │ │ │ │ │ -328 &stencilTable->GetWeights()[0], │ │ │ │ │ -329 &stencilTable->GetDuWeights()[0], │ │ │ │ │ -330 &stencilTable->GetDvWeights()[0], │ │ │ │ │ -331 &stencilTable->GetDuuWeights()[0], │ │ │ │ │ -332 &stencilTable->GetDuvWeights()[0], │ │ │ │ │ -333 &stencilTable->GetDvvWeights()[0], │ │ │ │ │ -334 /*start = */ 0, │ │ │ │ │ -335 /*end = */ stencilTable->GetNumStencils()); │ │ │ │ │ -336 } │ │ │ │ │ -337 │ │ │ │ │ -_3_9_9 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ -400 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -401 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -402 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -403 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -404 float *duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -405 float *duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -406 float *dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -407 const int * sizes, │ │ │ │ │ -408 const int * offsets, │ │ │ │ │ -409 const int * indices, │ │ │ │ │ -410 const float * weights, │ │ │ │ │ -411 const float * duWeights, │ │ │ │ │ -412 const float * dvWeights, │ │ │ │ │ -413 const float * duuWeights, │ │ │ │ │ -414 const float * duvWeights, │ │ │ │ │ -415 const float * dvvWeights, │ │ │ │ │ -416 int start, int end); │ │ │ │ │ -417 │ │ │ │ │ -423 │ │ │ │ │ -452 template │ │ │ │ │ -_4_5_4 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -455 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -456 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -457 int numPatchCoords, │ │ │ │ │ -458 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -459 PATCH_TABLE *patchTable, │ │ │ │ │ -460 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -461 void * deviceContext = NULL) { │ │ │ │ │ -462 │ │ │ │ │ -463 (void)instance; // unused │ │ │ │ │ -464 (void)deviceContext; // unused │ │ │ │ │ -465 │ │ │ │ │ -466 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -467 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -468 numPatchCoords, │ │ │ │ │ -469 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -470 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ -471 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -472 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -473 } │ │ │ │ │ -474 │ │ │ │ │ -515 template │ │ │ │ │ -_5_1_7 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -518 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -519 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -520 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -521 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -522 int numPatchCoords, │ │ │ │ │ -523 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -524 PATCH_TABLE *patchTable, │ │ │ │ │ -525 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -526 void * deviceContext = NULL) { │ │ │ │ │ -527 │ │ │ │ │ -528 (void)instance; // unused │ │ │ │ │ -529 (void)deviceContext; // unused │ │ │ │ │ -530 │ │ │ │ │ -531 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop. │ │ │ │ │ -532 // ideally all buffer classes should have templated by datatype │ │ │ │ │ -533 // so that downcast isn't needed there. │ │ │ │ │ -534 // (e.g. Osd::CpuBuffer ) │ │ │ │ │ -535 // │ │ │ │ │ -536 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -537 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -538 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -539 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -540 numPatchCoords, │ │ │ │ │ -541 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -542 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ -543 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -544 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -545 } │ │ │ │ │ -546 │ │ │ │ │ -605 template │ │ │ │ │ -_6_0_7 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -608 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -609 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -610 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -611 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -612 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -613 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -614 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -615 int numPatchCoords, │ │ │ │ │ -616 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -617 PATCH_TABLE *patchTable, │ │ │ │ │ -618 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -619 void * deviceContext = NULL) { │ │ │ │ │ -620 │ │ │ │ │ -621 (void)instance; // unused │ │ │ │ │ -622 (void)deviceContext; // unused │ │ │ │ │ -623 │ │ │ │ │ -624 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop. │ │ │ │ │ -625 // ideally all buffer classes should have templated by datatype │ │ │ │ │ -626 // so that downcast isn't needed there. │ │ │ │ │ -627 // (e.g. Osd::CpuBuffer ) │ │ │ │ │ -628 // │ │ │ │ │ -629 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -630 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -631 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -632 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -633 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ -634 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ -635 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ -636 numPatchCoords, │ │ │ │ │ -637 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -638 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ -639 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ -640 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -641 } │ │ │ │ │ -642 │ │ │ │ │ -_6_7_0 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -671 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -672 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -673 int numPatchCoords, │ │ │ │ │ -674 const _P_a_t_c_h_C_o_o_r_d *patchCoords, │ │ │ │ │ -675 const _P_a_t_c_h_A_r_r_a_y *patchArrays, │ │ │ │ │ -676 const int *patchIndexBuffer, │ │ │ │ │ -677 const _P_a_t_c_h_P_a_r_a_m *patchParamBuffer); │ │ │ │ │ -678 │ │ │ │ │ -_7_1_6 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -717 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -718 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -719 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -720 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -721 int numPatchCoords, │ │ │ │ │ -722 _P_a_t_c_h_C_o_o_r_d const *patchCoords, │ │ │ │ │ -723 _P_a_t_c_h_A_r_r_a_y const *patchArrays, │ │ │ │ │ -724 const int *patchIndexBuffer, │ │ │ │ │ -725 _P_a_t_c_h_P_a_r_a_m const *patchParamBuffer); │ │ │ │ │ -726 │ │ │ │ │ -_7_7_9 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ -780 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -781 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -782 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -783 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -784 float *duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -785 float *duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -786 float *dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -787 int numPatchCoords, │ │ │ │ │ -788 _P_a_t_c_h_C_o_o_r_d const *patchCoords, │ │ │ │ │ -789 _P_a_t_c_h_A_r_r_a_y const *patchArrays, │ │ │ │ │ -790 const int *patchIndexBuffer, │ │ │ │ │ -791 _P_a_t_c_h_P_a_r_a_m const *patchParamBuffer); │ │ │ │ │ -792 │ │ │ │ │ -821 template │ │ │ │ │ -_8_2_3 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -824 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -825 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -826 int numPatchCoords, │ │ │ │ │ -827 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -828 PATCH_TABLE *patchTable, │ │ │ │ │ -829 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -830 void * deviceContext = NULL) { │ │ │ │ │ -831 │ │ │ │ │ -832 (void)instance; // unused │ │ │ │ │ -833 (void)deviceContext; // unused │ │ │ │ │ -834 │ │ │ │ │ -835 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -836 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -837 numPatchCoords, │ │ │ │ │ -838 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -839 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ -840 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -841 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -842 } │ │ │ │ │ -843 │ │ │ │ │ -884 template │ │ │ │ │ -_8_8_6 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -887 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -888 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -889 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -890 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -891 int numPatchCoords, │ │ │ │ │ -892 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -893 PATCH_TABLE *patchTable, │ │ │ │ │ -894 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -895 void * deviceContext = NULL) { │ │ │ │ │ -896 │ │ │ │ │ -897 (void)instance; // unused │ │ │ │ │ -898 (void)deviceContext; // unused │ │ │ │ │ -899 │ │ │ │ │ -900 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -901 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -902 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -903 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -904 numPatchCoords, │ │ │ │ │ -905 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -906 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ -907 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -908 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -909 } │ │ │ │ │ -910 │ │ │ │ │ -969 template │ │ │ │ │ -_9_7_1 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ -972 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -973 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -974 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -975 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -976 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -977 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -978 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -979 int numPatchCoords, │ │ │ │ │ -980 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -981 PATCH_TABLE *patchTable, │ │ │ │ │ -982 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -983 void * deviceContext = NULL) { │ │ │ │ │ -984 │ │ │ │ │ -985 (void)instance; // unused │ │ │ │ │ -986 (void)deviceContext; // unused │ │ │ │ │ -987 │ │ │ │ │ -988 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -989 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -990 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -991 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -992 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ -993 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ -994 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ -995 numPatchCoords, │ │ │ │ │ -996 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -997 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ -998 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ -999 patchTable->GetPatchParamBuffer()); │ │ │ │ │ -1000 } │ │ │ │ │ -1001 │ │ │ │ │ -1032 template │ │ │ │ │ -_1_0_3_4 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1035 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1036 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1037 int numPatchCoords, │ │ │ │ │ -1038 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1039 PATCH_TABLE *patchTable, │ │ │ │ │ -1040 int fvarChannel, │ │ │ │ │ -1041 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -1042 void * deviceContext = NULL) { │ │ │ │ │ -1043 │ │ │ │ │ -1044 (void)instance; // unused │ │ │ │ │ -1045 (void)deviceContext; // unused │ │ │ │ │ -1046 │ │ │ │ │ -1047 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -1048 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -1049 numPatchCoords, │ │ │ │ │ -1050 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -1051 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ -1052 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -1053 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ -1054 } │ │ │ │ │ -1055 │ │ │ │ │ -1098 template │ │ │ │ │ -_1_1_0_0 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1101 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1102 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1103 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1104 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1105 int numPatchCoords, │ │ │ │ │ -1106 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1107 PATCH_TABLE *patchTable, │ │ │ │ │ -1108 int fvarChannel, │ │ │ │ │ -1109 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -1110 void * deviceContext = NULL) { │ │ │ │ │ -1111 │ │ │ │ │ -1112 (void)instance; // unused │ │ │ │ │ -1113 (void)deviceContext; // unused │ │ │ │ │ -1114 │ │ │ │ │ -1115 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -1116 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -1117 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -1118 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -1119 numPatchCoords, │ │ │ │ │ -1120 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -1121 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ -1122 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -1123 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ -1124 } │ │ │ │ │ -1125 │ │ │ │ │ -1186 template │ │ │ │ │ -_1_1_8_8 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ -1189 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ -1190 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ -1191 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ -1192 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ -1193 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ -1194 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ -1195 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ -1196 int numPatchCoords, │ │ │ │ │ -1197 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ -1198 PATCH_TABLE *patchTable, │ │ │ │ │ -1199 int fvarChannel, │ │ │ │ │ -1200 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ -1201 void * deviceContext = NULL) { │ │ │ │ │ -1202 │ │ │ │ │ -1203 (void)instance; // unused │ │ │ │ │ -1204 (void)deviceContext; // unused │ │ │ │ │ -1205 │ │ │ │ │ -1206 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ -1207 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ -1208 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ -1209 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ -1210 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ -1211 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ -1212 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ -1213 numPatchCoords, │ │ │ │ │ -1214 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ -1215 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ -1216 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ -1217 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ -1218 } │ │ │ │ │ -1219 │ │ │ │ │ -1225 │ │ │ │ │ -_1_2_2_7 static void _S_y_n_c_h_r_o_n_i_z_e(void * /*deviceContext = NULL*/) { │ │ │ │ │ -1228 // nothing. │ │ │ │ │ -1229 } │ │ │ │ │ -1230}; │ │ │ │ │ -1231 │ │ │ │ │ -1232 │ │ │ │ │ -1233} // end namespace Osd │ │ │ │ │ -1234 │ │ │ │ │ -1235} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -1236using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -1237 │ │ │ │ │ -1238} // end namespace OpenSubdiv │ │ │ │ │ -1239 │ │ │ │ │ -1240 │ │ │ │ │ -1241#endif // OPENSUBDIV3_OSD_CPU_EVALUATOR_H │ │ │ │ │ +_8_6 bool _o_p_e_r_a_t_o_r_ _=_=_ (_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &other) const { │ │ │ │ │ +87 return (_o_f_f_s_e_t == other._o_f_f_s_e_t && │ │ │ │ │ +88 _l_e_n_g_t_h == other._l_e_n_g_t_h && │ │ │ │ │ +89 _s_t_r_i_d_e == other._s_t_r_i_d_e); │ │ │ │ │ +90 } │ │ │ │ │ +91 │ │ │ │ │ +_9_3 bool _o_p_e_r_a_t_o_r_ _!_=_ (_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &other) const { │ │ │ │ │ +94 return !(this->_o_p_e_r_a_t_o_r_=_=(other)); │ │ │ │ │ +95 } │ │ │ │ │ +96 │ │ │ │ │ +_9_8 int _o_f_f_s_e_t; │ │ │ │ │ +_1_0_0 int _l_e_n_g_t_h; │ │ │ │ │ +_1_0_2 int _s_t_r_i_d_e; │ │ │ │ │ +103}; │ │ │ │ │ +104 │ │ │ │ │ +105} // end namespace Osd │ │ │ │ │ +106 │ │ │ │ │ +107} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +108using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +109 │ │ │ │ │ +110} // end namespace OpenSubdiv │ │ │ │ │ +111 │ │ │ │ │ +112#endif // OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ data buffers.... │ │ │ │ │ DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_3_9 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ -fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_0_3_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ -DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const │ │ │ │ │ -*instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_1_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ -float *dst, BufferDescriptor const &dstDesc, const int *sizes, const int │ │ │ │ │ -*offsets, const int *indices, const float *weights, int start, int end) │ │ │ │ │ -Static eval stencils function which takes raw CPU pointers for input and │ │ │ │ │ -output. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ -const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ -DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, │ │ │ │ │ -CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_1_8_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const │ │ │ │ │ -*instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_9_7_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ -float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ -&duDesc, float *dv, BufferDescriptor const &dvDesc, const int *sizes, const int │ │ │ │ │ -*offsets, const int *indices, const float *weights, const float *duWeights, │ │ │ │ │ -const float *dvWeights, int start, int end) │ │ │ │ │ -Static eval stencils function with derivatives, which takes raw CPU pointers │ │ │ │ │ -for input and output. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ -float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ -&duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, │ │ │ │ │ -BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, │ │ │ │ │ -float *dvv, BufferDescriptor const &dvvDesc, const int *sizes, const int │ │ │ │ │ -*offsets, const int *indices, const float *weights, const float *duWeights, │ │ │ │ │ -const float *dvWeights, const float *duuWeights, const float *duvWeights, const │ │ │ │ │ -float *dvvWeights, int start, int end) │ │ │ │ │ -Static eval stencils function with derivatives, which takes raw CPU pointers │ │ │ │ │ -for input and output. │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ -float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ -&duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, │ │ │ │ │ -BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, │ │ │ │ │ -float *dvv, BufferDescriptor const &dvvDesc, int numPatchCoords, PatchCoord │ │ │ │ │ -const *patchCoords, PatchArray const *patchArrays, const int *patchIndexBuffer, │ │ │ │ │ -PatchParam const *patchParamBuffer) │ │ │ │ │ -Static limit eval function. It takes an array of PatchCoord and evaluate limit │ │ │ │ │ -values on given PatchT... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ -PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const │ │ │ │ │ -*instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_4_5_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ -*patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function with derivatives. This function has a same │ │ │ │ │ -signature as other device kern... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_5_1_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ -float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ -&duDesc, float *dv, BufferDescriptor const &dvDesc, int numPatchCoords, │ │ │ │ │ -PatchCoord const *patchCoords, PatchArray const *patchArrays, const int │ │ │ │ │ -*patchIndexBuffer, PatchParam const *patchParamBuffer) │ │ │ │ │ -Static limit eval function. It takes an array of PatchCoord and evaluate limit │ │ │ │ │ -values on given PatchT... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ -&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ -*dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ -const CpuEvaluator *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic static eval stencils function with derivatives. This function has a │ │ │ │ │ -same signature as other d... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_3_0_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ -float *dst, BufferDescriptor const &dstDesc, int numPatchCoords, const │ │ │ │ │ -PatchCoord *patchCoords, const PatchArray *patchArrays, const int │ │ │ │ │ -*patchIndexBuffer, const PatchParam *patchParamBuffer) │ │ │ │ │ -Static limit eval function. It takes an array of PatchCoord and evaluate limit │ │ │ │ │ -values on given PatchT... │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_8_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ -static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ -numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, │ │ │ │ │ -CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic limit eval function. This function has a same signature as other device │ │ │ │ │ -kernels have so that ... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_8_2_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ -static void Synchronize(void *) │ │ │ │ │ -synchronize all asynchronous computation invoked on this device. │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_2_2_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ -const *stencilTable, const CpuEvaluator *instance=NULL, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -Generic static eval stencils function. This function has a same signature as │ │ │ │ │ -other device kernels hav... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_7_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ -static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ -DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ -BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ -&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ -*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ -BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ -*patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void │ │ │ │ │ -*deviceContext=NULL) │ │ │ │ │ -Generic limit eval function with derivatives. This function has a same │ │ │ │ │ -signature as other device kern... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_6_0_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ -static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ -&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ -*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ -BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, const │ │ │ │ │ -CpuEvaluator *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ -Generic static eval stencils function with derivatives. This function has a │ │ │ │ │ -same signature as other d... │ │ │ │ │ -DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_6_8 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_C_o_o_r_d │ │ │ │ │ -Coordinates set on a patch table. │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_6_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ -DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_2_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_s_t_r_i_d_e │ │ │ │ │ +int stride │ │ │ │ │ +stride to the next element │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_1_0_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_R_e_s_e_t │ │ │ │ │ +void Reset() │ │ │ │ │ +Resets the descriptor to default. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_8_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +BufferDescriptor() │ │ │ │ │ +Default Constructor. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ +BufferDescriptor(int o, int l, int s) │ │ │ │ │ +Constructor. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_l_e_n_g_t_h │ │ │ │ │ +int length │ │ │ │ │ +number or length of the data │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_1_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_!_= │ │ │ │ │ +bool operator!=(BufferDescriptor const &other) const │ │ │ │ │ +True if the descriptors are not identical. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_9_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ │ +bool operator==(BufferDescriptor const &other) const │ │ │ │ │ +True if the descriptors are identical. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_I_s_V_a_l_i_d │ │ │ │ │ +bool IsValid() const │ │ │ │ │ +True if the descriptor values are internally consistent. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_7_5 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_L_o_c_a_l_O_f_f_s_e_t │ │ │ │ │ +int GetLocalOffset() const │ │ │ │ │ +Returns the relative offset within a stride. │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_7_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_o_f_f_s_e_t │ │ │ │ │ +int offset │ │ │ │ │ +offset to desired element data │ │ │ │ │ +DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_9_8 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _c_p_u_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ + * _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00899.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/bufferDescriptor.h File Reference │ │ │ │ +OpenSubdiv: opensubdiv/osd/cpuEvaluator.h File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -90,26 +90,27 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
bufferDescriptor.h File Reference
│ │ │ │ +
cpuEvaluator.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include <string.h>
│ │ │ │ +#include "../osd/bufferDescriptor.h"
│ │ │ │ +#include "../osd/types.h"
│ │ │ │ +#include <cstddef>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  BufferDescriptor
 BufferDescriptor is a struct which describes buffer elements in interleaved data buffers. Almost all Osd Evaluator APIs take BufferDescriptors along with device-specific buffer objects. More...
class  CpuEvaluator
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -118,13 +119,13 @@ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,26 +1,25 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -bufferDescriptor.h File Reference │ │ │ │ │ +cpuEvaluator.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_o_s_d_/_b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h" │ │ │ │ │ +#include "_._._/_o_s_d_/_t_y_p_e_s_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ -struct   _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ - _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r is a struct which describes buffer elements in │ │ │ │ │ -  interleaved data buffers. Almost all _O_s_d Evaluator APIs take │ │ │ │ │ - BufferDescriptors along with device-specific buffer objects. _M_o_r_e_._._. │ │ │ │ │ +class   _C_p_u_E_v_a_l_u_a_t_o_r │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _c_p_u_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00899.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,3 +1,3 @@ │ │ │ │ │ var a00899 = [ │ │ │ │ │ - ["BufferDescriptor", "a01141.html", "a01141"] │ │ │ │ │ + ["CpuEvaluator", "a01165.html", null] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00899_source.html │ │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -OpenSubdiv: opensubdiv/osd/bufferDescriptor.h Source File │ │ │ │ +OpenSubdiv: opensubdiv/osd/cpuEvaluator.h Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -92,15 +92,15 @@ │ │ │ │
No Matches
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ -
bufferDescriptor.h
│ │ │ │ +
cpuEvaluator.h
│ │ │ │
│ │ │ │
│ │ │ │ Go to the documentation of this file.
1//
│ │ │ │
2// Copyright 2015 Pixar
│ │ │ │
3//
│ │ │ │
4// Licensed under the Apache License, Version 2.0 (the "Apache License")
│ │ │ │
5// with the following modification; you may not use this file except in
│ │ │ │ @@ -119,112 +119,529 @@ │ │ │ │
18// Unless required by applicable law or agreed to in writing, software
│ │ │ │
19// distributed under the Apache License with the above modification is
│ │ │ │
20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
│ │ │ │
21// KIND, either express or implied. See the Apache License for the specific
│ │ │ │
22// language governing permissions and limitations under the Apache License.
│ │ │ │
23//
│ │ │ │
24
│ │ │ │ -
25#ifndef OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H
│ │ │ │ -
26#define OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H
│ │ │ │ +
25#ifndef OPENSUBDIV3_OSD_CPU_EVALUATOR_H
│ │ │ │ +
26#define OPENSUBDIV3_OSD_CPU_EVALUATOR_H
│ │ │ │
27
│ │ │ │
28#include "../version.h"
│ │ │ │ -
29#include <string.h>
│ │ │ │ -
30
│ │ │ │ -
31namespace OpenSubdiv {
│ │ │ │ -
32namespace OPENSUBDIV_VERSION {
│ │ │ │ +
29#include "../osd/bufferDescriptor.h"
│ │ │ │ +
30#include "../osd/types.h"
│ │ │ │ +
31
│ │ │ │ +
32#include <cstddef>
│ │ │ │
33
│ │ │ │ -
│ │ │ │ -
34namespace Osd {
│ │ │ │ -
35
│ │ │ │ +
34namespace OpenSubdiv {
│ │ │ │ +
35namespace OPENSUBDIV_VERSION {
│ │ │ │ +
36
│ │ │ │ +
37namespace Osd {
│ │ │ │ +
38
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
40public:
│ │ │ │
46
│ │ │ │ -
47// example:
│ │ │ │ -
48// n
│ │ │ │ -
49// -----+----------------------------------------+-------------------------
│ │ │ │ -
50// | vertex 0 |
│ │ │ │ -
51// -----+----------------------------------------+-------------------------
│ │ │ │ -
52// | X Y Z R G B A Xu Yu Zu Xv Yv Zv |
│ │ │ │ -
53// -----+----------------------------------------+-------------------------
│ │ │ │ -
54// <------------- stride = 13 -------------->
│ │ │ │ -
55//
│ │ │ │ -
56// - XYZ (offset = n+0, length = 3, stride = 13)
│ │ │ │ -
57// - RGBA (offset = n+3, length = 4, stride = 13)
│ │ │ │ -
58// - uTangent (offset = n+7, length = 3, stride = 13)
│ │ │ │ -
59// - vTangent (offset = n+10, length = 3, stride = 13)
│ │ │ │ -
60//
│ │ │ │ -
│ │ │ │ - │ │ │ │ -
62
│ │ │ │ - │ │ │ │ -
65
│ │ │ │ -
67 BufferDescriptor(int o, int l, int s) : offset(o), length(l), stride(s) { }
│ │ │ │ -
68
│ │ │ │ -
│ │ │ │ -
70 int GetLocalOffset() const {
│ │ │ │ -
71 return stride > 0 ? offset % stride : 0;
│ │ │ │ -
72 }
│ │ │ │ -
│ │ │ │ -
73
│ │ │ │ -
│ │ │ │ -
75 bool IsValid() const {
│ │ │ │ -
76 return ((length > 0) &&
│ │ │ │ - │ │ │ │ -
78 }
│ │ │ │ -
│ │ │ │ -
79
│ │ │ │ -
│ │ │ │ -
81 void Reset() {
│ │ │ │ -
82 offset = length = stride = 0;
│ │ │ │ -
83 }
│ │ │ │ -
│ │ │ │ +
71 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
72 static bool EvalStencils(
│ │ │ │ +
73 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
74 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
75 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
76 const CpuEvaluator *instance = NULL,
│ │ │ │ +
77 void * deviceContext = NULL) {
│ │ │ │ +
78
│ │ │ │ +
79 (void)instance; // unused
│ │ │ │ +
80 (void)deviceContext; // unused
│ │ │ │ +
81
│ │ │ │ +
82 if (stencilTable->GetNumStencils() == 0)
│ │ │ │ +
83 return false;
│ │ │ │
84
│ │ │ │ -
│ │ │ │ -
86 bool operator == (BufferDescriptor const &other) const {
│ │ │ │ -
87 return (offset == other.offset &&
│ │ │ │ -
88 length == other.length &&
│ │ │ │ -
89 stride == other.stride);
│ │ │ │ -
90 }
│ │ │ │ -
│ │ │ │ -
91
│ │ │ │ -
│ │ │ │ -
93 bool operator != (BufferDescriptor const &other) const {
│ │ │ │ -
94 return !(this->operator==(other));
│ │ │ │ -
95 }
│ │ │ │ -
│ │ │ │ -
96
│ │ │ │ -
98 int offset;
│ │ │ │ - │ │ │ │ - │ │ │ │ -
103};
│ │ │ │ -
│ │ │ │ -
104
│ │ │ │ -
105} // end namespace Osd
│ │ │ │ -
│ │ │ │ -
106
│ │ │ │ -
107} // end namespace OPENSUBDIV_VERSION
│ │ │ │ -
108using namespace OPENSUBDIV_VERSION;
│ │ │ │ -
109
│ │ │ │ -
110} // end namespace OpenSubdiv
│ │ │ │ -
111
│ │ │ │ -
112#endif // OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H
│ │ │ │ +
85 return EvalStencils(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
86 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
87 &stencilTable->GetSizes()[0],
│ │ │ │ +
88 &stencilTable->GetOffsets()[0],
│ │ │ │ +
89 &stencilTable->GetControlIndices()[0],
│ │ │ │ +
90 &stencilTable->GetWeights()[0],
│ │ │ │ +
91 /*start = */ 0,
│ │ │ │ +
92 /*end = */ stencilTable->GetNumStencils());
│ │ │ │ +
93 }
│ │ │ │ +
│ │ │ │ +
94
│ │ │ │ +
121 static bool EvalStencils(
│ │ │ │ +
122 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ +
123 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
124 const int * sizes,
│ │ │ │ +
125 const int * offsets,
│ │ │ │ +
126 const int * indices,
│ │ │ │ +
127 const float * weights,
│ │ │ │ +
128 int start, int end);
│ │ │ │ +
129
│ │ │ │ +
167 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
168 static bool EvalStencils(
│ │ │ │ +
169 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
170 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
171 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
172 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
173 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
174 const CpuEvaluator *instance = NULL,
│ │ │ │ +
175 void * deviceContext = NULL) {
│ │ │ │ +
176
│ │ │ │ +
177 (void)instance; // unused
│ │ │ │ +
178 (void)deviceContext; // unused
│ │ │ │ +
179
│ │ │ │ +
180 return EvalStencils(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
181 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
182 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
183 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
184 &stencilTable->GetSizes()[0],
│ │ │ │ +
185 &stencilTable->GetOffsets()[0],
│ │ │ │ +
186 &stencilTable->GetControlIndices()[0],
│ │ │ │ +
187 &stencilTable->GetWeights()[0],
│ │ │ │ +
188 &stencilTable->GetDuWeights()[0],
│ │ │ │ +
189 &stencilTable->GetDvWeights()[0],
│ │ │ │ +
190 /*start = */ 0,
│ │ │ │ +
191 /*end = */ stencilTable->GetNumStencils());
│ │ │ │ +
192 }
│ │ │ │ +
│ │ │ │ +
193
│ │ │ │ +
234 static bool EvalStencils(
│ │ │ │ +
235 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ +
236 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
237 float *du, BufferDescriptor const &duDesc,
│ │ │ │ +
238 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
239 const int * sizes,
│ │ │ │ +
240 const int * offsets,
│ │ │ │ +
241 const int * indices,
│ │ │ │ +
242 const float * weights,
│ │ │ │ +
243 const float * duWeights,
│ │ │ │ +
244 const float * dvWeights,
│ │ │ │ +
245 int start, int end);
│ │ │ │ +
246
│ │ │ │ +
302 template <typename SRC_BUFFER, typename DST_BUFFER, typename STENCIL_TABLE>
│ │ │ │ +
│ │ │ │ +
303 static bool EvalStencils(
│ │ │ │ +
304 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
305 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
306 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
307 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
308 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
309 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
310 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
311 STENCIL_TABLE const *stencilTable,
│ │ │ │ +
312 const CpuEvaluator *instance = NULL,
│ │ │ │ +
313 void * deviceContext = NULL) {
│ │ │ │ +
314
│ │ │ │ +
315 (void)instance; // unused
│ │ │ │ +
316 (void)deviceContext; // unused
│ │ │ │ +
317
│ │ │ │ +
318 return EvalStencils(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
319 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
320 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
321 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
322 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ +
323 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ +
324 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ +
325 &stencilTable->GetSizes()[0],
│ │ │ │ +
326 &stencilTable->GetOffsets()[0],
│ │ │ │ +
327 &stencilTable->GetControlIndices()[0],
│ │ │ │ +
328 &stencilTable->GetWeights()[0],
│ │ │ │ +
329 &stencilTable->GetDuWeights()[0],
│ │ │ │ +
330 &stencilTable->GetDvWeights()[0],
│ │ │ │ +
331 &stencilTable->GetDuuWeights()[0],
│ │ │ │ +
332 &stencilTable->GetDuvWeights()[0],
│ │ │ │ +
333 &stencilTable->GetDvvWeights()[0],
│ │ │ │ +
334 /*start = */ 0,
│ │ │ │ +
335 /*end = */ stencilTable->GetNumStencils());
│ │ │ │ +
336 }
│ │ │ │ +
│ │ │ │ +
337
│ │ │ │ +
399 static bool EvalStencils(
│ │ │ │ +
400 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ +
401 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
402 float *du, BufferDescriptor const &duDesc,
│ │ │ │ +
403 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
404 float *duu, BufferDescriptor const &duuDesc,
│ │ │ │ +
405 float *duv, BufferDescriptor const &duvDesc,
│ │ │ │ +
406 float *dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ +
407 const int * sizes,
│ │ │ │ +
408 const int * offsets,
│ │ │ │ +
409 const int * indices,
│ │ │ │ +
410 const float * weights,
│ │ │ │ +
411 const float * duWeights,
│ │ │ │ +
412 const float * dvWeights,
│ │ │ │ +
413 const float * duuWeights,
│ │ │ │ +
414 const float * duvWeights,
│ │ │ │ +
415 const float * dvvWeights,
│ │ │ │ +
416 int start, int end);
│ │ │ │ +
417
│ │ │ │ +
423
│ │ │ │ +
452 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
453 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ +
454 static bool EvalPatches(
│ │ │ │ +
455 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
456 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
457 int numPatchCoords,
│ │ │ │ +
458 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
459 PATCH_TABLE *patchTable,
│ │ │ │ +
460 CpuEvaluator const *instance = NULL,
│ │ │ │ +
461 void * deviceContext = NULL) {
│ │ │ │ +
462
│ │ │ │ +
463 (void)instance; // unused
│ │ │ │ +
464 (void)deviceContext; // unused
│ │ │ │ +
465
│ │ │ │ +
466 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
467 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
468 numPatchCoords,
│ │ │ │ +
469 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
470 patchTable->GetPatchArrayBuffer(),
│ │ │ │ +
471 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
472 patchTable->GetPatchParamBuffer());
│ │ │ │ +
473 }
│ │ │ │ +
│ │ │ │ +
474
│ │ │ │ +
515 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
516 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ +
517 static bool EvalPatches(
│ │ │ │ +
518 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
519 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
520 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
521 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
522 int numPatchCoords,
│ │ │ │ +
523 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
524 PATCH_TABLE *patchTable,
│ │ │ │ +
525 CpuEvaluator const *instance = NULL,
│ │ │ │ +
526 void * deviceContext = NULL) {
│ │ │ │ +
527
│ │ │ │ +
528 (void)instance; // unused
│ │ │ │ +
529 (void)deviceContext; // unused
│ │ │ │ +
530
│ │ │ │ +
531 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop.
│ │ │ │ +
532 // ideally all buffer classes should have templated by datatype
│ │ │ │ +
533 // so that downcast isn't needed there.
│ │ │ │ +
534 // (e.g. Osd::CpuBuffer<PatchCoord> )
│ │ │ │ +
535 //
│ │ │ │ +
536 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
537 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
538 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
539 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
540 numPatchCoords,
│ │ │ │ +
541 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
542 patchTable->GetPatchArrayBuffer(),
│ │ │ │ +
543 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
544 patchTable->GetPatchParamBuffer());
│ │ │ │ +
545 }
│ │ │ │ +
│ │ │ │ +
546
│ │ │ │ +
605 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
606 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ +
607 static bool EvalPatches(
│ │ │ │ +
608 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
609 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
610 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
611 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
612 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
613 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
614 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
615 int numPatchCoords,
│ │ │ │ +
616 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
617 PATCH_TABLE *patchTable,
│ │ │ │ +
618 CpuEvaluator const *instance = NULL,
│ │ │ │ +
619 void * deviceContext = NULL) {
│ │ │ │ +
620
│ │ │ │ +
621 (void)instance; // unused
│ │ │ │ +
622 (void)deviceContext; // unused
│ │ │ │ +
623
│ │ │ │ +
624 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop.
│ │ │ │ +
625 // ideally all buffer classes should have templated by datatype
│ │ │ │ +
626 // so that downcast isn't needed there.
│ │ │ │ +
627 // (e.g. Osd::CpuBuffer<PatchCoord> )
│ │ │ │ +
628 //
│ │ │ │ +
629 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
630 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
631 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
632 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
633 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ +
634 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ +
635 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ +
636 numPatchCoords,
│ │ │ │ +
637 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
638 patchTable->GetPatchArrayBuffer(),
│ │ │ │ +
639 patchTable->GetPatchIndexBuffer(),
│ │ │ │ +
640 patchTable->GetPatchParamBuffer());
│ │ │ │ +
641 }
│ │ │ │ +
│ │ │ │ +
642
│ │ │ │ +
670 static bool EvalPatches(
│ │ │ │ +
671 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ +
672 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
673 int numPatchCoords,
│ │ │ │ +
674 const PatchCoord *patchCoords,
│ │ │ │ +
675 const PatchArray *patchArrays,
│ │ │ │ +
676 const int *patchIndexBuffer,
│ │ │ │ +
677 const PatchParam *patchParamBuffer);
│ │ │ │ +
678
│ │ │ │ +
716 static bool EvalPatches(
│ │ │ │ +
717 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ +
718 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
719 float *du, BufferDescriptor const &duDesc,
│ │ │ │ +
720 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
721 int numPatchCoords,
│ │ │ │ +
722 PatchCoord const *patchCoords,
│ │ │ │ +
723 PatchArray const *patchArrays,
│ │ │ │ +
724 const int *patchIndexBuffer,
│ │ │ │ +
725 PatchParam const *patchParamBuffer);
│ │ │ │ +
726
│ │ │ │ +
779 static bool EvalPatches(
│ │ │ │ +
780 const float *src, BufferDescriptor const &srcDesc,
│ │ │ │ +
781 float *dst, BufferDescriptor const &dstDesc,
│ │ │ │ +
782 float *du, BufferDescriptor const &duDesc,
│ │ │ │ +
783 float *dv, BufferDescriptor const &dvDesc,
│ │ │ │ +
784 float *duu, BufferDescriptor const &duuDesc,
│ │ │ │ +
785 float *duv, BufferDescriptor const &duvDesc,
│ │ │ │ +
786 float *dvv, BufferDescriptor const &dvvDesc,
│ │ │ │ +
787 int numPatchCoords,
│ │ │ │ +
788 PatchCoord const *patchCoords,
│ │ │ │ +
789 PatchArray const *patchArrays,
│ │ │ │ +
790 const int *patchIndexBuffer,
│ │ │ │ +
791 PatchParam const *patchParamBuffer);
│ │ │ │ +
792
│ │ │ │ +
821 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
822 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
824 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
825 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
826 int numPatchCoords,
│ │ │ │ +
827 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
828 PATCH_TABLE *patchTable,
│ │ │ │ +
829 CpuEvaluator const *instance = NULL,
│ │ │ │ +
830 void * deviceContext = NULL) {
│ │ │ │ +
831
│ │ │ │ +
832 (void)instance; // unused
│ │ │ │ +
833 (void)deviceContext; // unused
│ │ │ │ +
834
│ │ │ │ +
835 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
836 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
837 numPatchCoords,
│ │ │ │ +
838 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
839 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ +
840 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
841 patchTable->GetPatchParamBuffer());
│ │ │ │ +
842 }
│ │ │ │ +
│ │ │ │ +
843
│ │ │ │ +
884 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
885 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
887 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
888 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
889 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
890 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
891 int numPatchCoords,
│ │ │ │ +
892 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
893 PATCH_TABLE *patchTable,
│ │ │ │ +
894 CpuEvaluator const *instance = NULL,
│ │ │ │ +
895 void * deviceContext = NULL) {
│ │ │ │ +
896
│ │ │ │ +
897 (void)instance; // unused
│ │ │ │ +
898 (void)deviceContext; // unused
│ │ │ │ +
899
│ │ │ │ +
900 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
901 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
902 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
903 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
904 numPatchCoords,
│ │ │ │ +
905 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
906 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ +
907 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
908 patchTable->GetPatchParamBuffer());
│ │ │ │ +
909 }
│ │ │ │ +
│ │ │ │ +
910
│ │ │ │ +
969 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
970 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
972 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
973 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
974 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
975 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
976 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
977 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
978 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
979 int numPatchCoords,
│ │ │ │ +
980 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
981 PATCH_TABLE *patchTable,
│ │ │ │ +
982 CpuEvaluator const *instance = NULL,
│ │ │ │ +
983 void * deviceContext = NULL) {
│ │ │ │ +
984
│ │ │ │ +
985 (void)instance; // unused
│ │ │ │ +
986 (void)deviceContext; // unused
│ │ │ │ +
987
│ │ │ │ +
988 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
989 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
990 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
991 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
992 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ +
993 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ +
994 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ +
995 numPatchCoords,
│ │ │ │ +
996 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
997 patchTable->GetVaryingPatchArrayBuffer(),
│ │ │ │ +
998 patchTable->GetVaryingPatchIndexBuffer(),
│ │ │ │ +
999 patchTable->GetPatchParamBuffer());
│ │ │ │ +
1000 }
│ │ │ │ +
│ │ │ │ +
1001
│ │ │ │ +
1032 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1033 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1035 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1036 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1037 int numPatchCoords,
│ │ │ │ +
1038 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1039 PATCH_TABLE *patchTable,
│ │ │ │ +
1040 int fvarChannel,
│ │ │ │ +
1041 CpuEvaluator const *instance = NULL,
│ │ │ │ +
1042 void * deviceContext = NULL) {
│ │ │ │ +
1043
│ │ │ │ +
1044 (void)instance; // unused
│ │ │ │ +
1045 (void)deviceContext; // unused
│ │ │ │ +
1046
│ │ │ │ +
1047 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
1048 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
1049 numPatchCoords,
│ │ │ │ +
1050 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
1051 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ +
1052 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
1053 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ +
1054 }
│ │ │ │ +
│ │ │ │ +
1055
│ │ │ │ +
1098 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1099 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1101 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1102 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1103 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1104 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1105 int numPatchCoords,
│ │ │ │ +
1106 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1107 PATCH_TABLE *patchTable,
│ │ │ │ +
1108 int fvarChannel,
│ │ │ │ +
1109 CpuEvaluator const *instance = NULL,
│ │ │ │ +
1110 void * deviceContext = NULL) {
│ │ │ │ +
1111
│ │ │ │ +
1112 (void)instance; // unused
│ │ │ │ +
1113 (void)deviceContext; // unused
│ │ │ │ +
1114
│ │ │ │ +
1115 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
1116 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
1117 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
1118 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
1119 numPatchCoords,
│ │ │ │ +
1120 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
1121 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ +
1122 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
1123 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ +
1124 }
│ │ │ │ +
│ │ │ │ +
1125
│ │ │ │ +
1186 template <typename SRC_BUFFER, typename DST_BUFFER,
│ │ │ │ +
1187 typename PATCHCOORD_BUFFER, typename PATCH_TABLE>
│ │ │ │ +
│ │ │ │ + │ │ │ │ +
1189 SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc,
│ │ │ │ +
1190 DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc,
│ │ │ │ +
1191 DST_BUFFER *duBuffer, BufferDescriptor const &duDesc,
│ │ │ │ +
1192 DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc,
│ │ │ │ +
1193 DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc,
│ │ │ │ +
1194 DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc,
│ │ │ │ +
1195 DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc,
│ │ │ │ +
1196 int numPatchCoords,
│ │ │ │ +
1197 PATCHCOORD_BUFFER *patchCoords,
│ │ │ │ +
1198 PATCH_TABLE *patchTable,
│ │ │ │ +
1199 int fvarChannel,
│ │ │ │ +
1200 CpuEvaluator const *instance = NULL,
│ │ │ │ +
1201 void * deviceContext = NULL) {
│ │ │ │ +
1202
│ │ │ │ +
1203 (void)instance; // unused
│ │ │ │ +
1204 (void)deviceContext; // unused
│ │ │ │ +
1205
│ │ │ │ +
1206 return EvalPatches(srcBuffer->BindCpuBuffer(), srcDesc,
│ │ │ │ +
1207 dstBuffer->BindCpuBuffer(), dstDesc,
│ │ │ │ +
1208 duBuffer->BindCpuBuffer(), duDesc,
│ │ │ │ +
1209 dvBuffer->BindCpuBuffer(), dvDesc,
│ │ │ │ +
1210 duuBuffer->BindCpuBuffer(), duuDesc,
│ │ │ │ +
1211 duvBuffer->BindCpuBuffer(), duvDesc,
│ │ │ │ +
1212 dvvBuffer->BindCpuBuffer(), dvvDesc,
│ │ │ │ +
1213 numPatchCoords,
│ │ │ │ +
1214 (const PatchCoord*)patchCoords->BindCpuBuffer(),
│ │ │ │ +
1215 patchTable->GetFVarPatchArrayBuffer(fvarChannel),
│ │ │ │ +
1216 patchTable->GetFVarPatchIndexBuffer(fvarChannel),
│ │ │ │ +
1217 patchTable->GetFVarPatchParamBuffer(fvarChannel));
│ │ │ │ +
1218 }
│ │ │ │ +
│ │ │ │ +
1219
│ │ │ │ +
1225
│ │ │ │ +
│ │ │ │ +
1227 static void Synchronize(void * /*deviceContext = NULL*/) {
│ │ │ │ +
1228 // nothing.
│ │ │ │ +
1229 }
│ │ │ │ +
│ │ │ │ +
1230};
│ │ │ │ +
│ │ │ │ +
1231
│ │ │ │ +
1232
│ │ │ │ +
1233} // end namespace Osd
│ │ │ │ +
1234
│ │ │ │ +
1235} // end namespace OPENSUBDIV_VERSION
│ │ │ │ +
1236using namespace OPENSUBDIV_VERSION;
│ │ │ │ +
1237
│ │ │ │ +
1238} // end namespace OpenSubdiv
│ │ │ │ +
1239
│ │ │ │ +
1240
│ │ │ │ +
1241#endif // OPENSUBDIV3_OSD_CPU_EVALUATOR_H
│ │ │ │ │ │ │ │ -
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ - │ │ │ │ -
void Reset()
Resets the descriptor to default.
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ -
bool operator!=(BufferDescriptor const &other) const
True if the descriptors are not identical.
│ │ │ │ -
bool operator==(BufferDescriptor const &other) const
True if the descriptors are identical.
│ │ │ │ -
bool IsValid() const
True if the descriptor values are internally consistent.
│ │ │ │ -
int GetLocalOffset() const
Returns the relative offset within a stride.
│ │ │ │ - │ │ │ │ +
BufferDescriptor is a struct which describes buffer elements in interleaved data buffers....
│ │ │ │ + │ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, int start, int end)
Static eval stencils function which takes raw CPU pointers for input and output.
│ │ │ │ +
static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, const float *duWeights, const float *dvWeights, int start, int end)
Static eval stencils function with derivatives, which takes raw CPU pointers for input and output.
│ │ │ │ +
static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, float *dvv, BufferDescriptor const &dvvDesc, const int *sizes, const int *offsets, const int *indices, const float *weights, const float *duWeights, const float *dvWeights, const float *duuWeights, const float *duvWeights, const float *dvvWeights, int start, int end)
Static eval stencils function with derivatives, which takes raw CPU pointers for input and output.
│ │ │ │ +
static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, float *dvv, BufferDescriptor const &dvvDesc, int numPatchCoords, PatchCoord const *patchCoords, PatchArray const *patchArrays, const int *patchIndexBuffer, PatchParam const *patchParamBuffer)
Static limit eval function. It takes an array of PatchCoord and evaluate limit values on given PatchT...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ +
static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const &duDesc, float *dv, BufferDescriptor const &dvDesc, int numPatchCoords, PatchCoord const *patchCoords, PatchArray const *patchArrays, const int *patchIndexBuffer, PatchParam const *patchParamBuffer)
Static limit eval function. It takes an array of PatchCoord and evaluate limit values on given PatchT...
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function with derivatives. This function has a same signature as other d...
│ │ │ │ +
static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, float *dst, BufferDescriptor const &dstDesc, int numPatchCoords, const PatchCoord *patchCoords, const PatchArray *patchArrays, const int *patchIndexBuffer, const PatchParam *patchParamBuffer)
Static limit eval function. It takes an array of PatchCoord and evaluate limit values on given PatchT...
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function. This function has a same signature as other device kernels have so that ...
│ │ │ │ +
static void Synchronize(void *)
synchronize all asynchronous computation invoked on this device.
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function. This function has a same signature as other device kernels hav...
│ │ │ │ +
static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL)
Generic limit eval function with derivatives. This function has a same signature as other device kern...
│ │ │ │ +
static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
Generic static eval stencils function with derivatives. This function has a same signature as other d...
│ │ │ │ +
Coordinates set on a patch table.
Definition types.h:42
│ │ │ │ + │ │ │ │ + │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ -bufferDescriptor.h │ │ │ │ │ +cpuEvaluator.h │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ 1// │ │ │ │ │ 2// Copyright 2015 Pixar │ │ │ │ │ 3// │ │ │ │ │ 4// Licensed under the Apache License, Version 2.0 (the "Apache License") │ │ │ │ │ 5// with the following modification; you may not use this file except in │ │ │ │ │ 6// compliance with the Apache License and the following modification to it: │ │ │ │ │ @@ -24,125 +24,655 @@ │ │ │ │ │ 18// Unless required by applicable law or agreed to in writing, software │ │ │ │ │ 19// distributed under the Apache License with the above modification is │ │ │ │ │ 20// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY │ │ │ │ │ 21// KIND, either express or implied. See the Apache License for the specific │ │ │ │ │ 22// language governing permissions and limitations under the Apache License. │ │ │ │ │ 23// │ │ │ │ │ 24 │ │ │ │ │ -25#ifndef OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H │ │ │ │ │ -26#define OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H │ │ │ │ │ +25#ifndef OPENSUBDIV3_OSD_CPU_EVALUATOR_H │ │ │ │ │ +26#define OPENSUBDIV3_OSD_CPU_EVALUATOR_H │ │ │ │ │ 27 │ │ │ │ │ 28#include "../version.h" │ │ │ │ │ -29#include │ │ │ │ │ -30 │ │ │ │ │ -31namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ -32namespace OPENSUBDIV_VERSION { │ │ │ │ │ +29#include "../osd/bufferDescriptor.h" │ │ │ │ │ +30#include "../osd/types.h" │ │ │ │ │ +31 │ │ │ │ │ +32#include │ │ │ │ │ 33 │ │ │ │ │ -_3_4namespace Osd { │ │ │ │ │ -35 │ │ │ │ │ +34namespace _O_p_e_n_S_u_b_d_i_v { │ │ │ │ │ +35namespace OPENSUBDIV_VERSION { │ │ │ │ │ +36 │ │ │ │ │ +37namespace Osd { │ │ │ │ │ +38 │ │ │ │ │ +_3_9class _C_p_u_E_v_a_l_u_a_t_o_r { │ │ │ │ │ +40public: │ │ │ │ │ 46 │ │ │ │ │ -47// example: │ │ │ │ │ -48// n │ │ │ │ │ -49// -----+----------------------------------------+------------------------- │ │ │ │ │ -50// | vertex 0 | │ │ │ │ │ -51// -----+----------------------------------------+------------------------- │ │ │ │ │ -52// | X Y Z R G B A Xu Yu Zu Xv Yv Zv | │ │ │ │ │ -53// -----+----------------------------------------+------------------------- │ │ │ │ │ -54// <------------- stride = 13 --------------> │ │ │ │ │ -55// │ │ │ │ │ -56// - XYZ (offset = n+0, length = 3, stride = 13) │ │ │ │ │ -57// - RGBA (offset = n+3, length = 4, stride = 13) │ │ │ │ │ -58// - uTangent (offset = n+7, length = 3, stride = 13) │ │ │ │ │ -59// - vTangent (offset = n+10, length = 3, stride = 13) │ │ │ │ │ -60// │ │ │ │ │ -_6_1struct _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r { │ │ │ │ │ -62 │ │ │ │ │ -_6_4 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r() : _o_f_f_s_e_t(0), _l_e_n_g_t_h(0), _s_t_r_i_d_e(0) { } │ │ │ │ │ -65 │ │ │ │ │ -_6_7 _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r(int o, int l, int s) : _o_f_f_s_e_t(o), _l_e_n_g_t_h(l), _s_t_r_i_d_e(s) { } │ │ │ │ │ -68 │ │ │ │ │ -_7_0 int _G_e_t_L_o_c_a_l_O_f_f_s_e_t() const { │ │ │ │ │ -71 return _s_t_r_i_d_e > 0 ? _o_f_f_s_e_t % _s_t_r_i_d_e : 0; │ │ │ │ │ -72 } │ │ │ │ │ -73 │ │ │ │ │ -_7_5 bool _I_s_V_a_l_i_d() const { │ │ │ │ │ -76 return ((_l_e_n_g_t_h > 0) && │ │ │ │ │ -77 (_l_e_n_g_t_h <= _s_t_r_i_d_e - _G_e_t_L_o_c_a_l_O_f_f_s_e_t())); │ │ │ │ │ -78 } │ │ │ │ │ -79 │ │ │ │ │ -_8_1 void _R_e_s_e_t() { │ │ │ │ │ -82 _o_f_f_s_e_t = _l_e_n_g_t_h = _s_t_r_i_d_e = 0; │ │ │ │ │ -83 } │ │ │ │ │ +71 template │ │ │ │ │ +_7_2 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +73 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +74 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +75 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +76 const _C_p_u_E_v_a_l_u_a_t_o_r *instance = NULL, │ │ │ │ │ +77 void * deviceContext = NULL) { │ │ │ │ │ +78 │ │ │ │ │ +79 (void)instance; // unused │ │ │ │ │ +80 (void)deviceContext; // unused │ │ │ │ │ +81 │ │ │ │ │ +82 if (stencilTable->GetNumStencils() == 0) │ │ │ │ │ +83 return false; │ │ │ │ │ 84 │ │ │ │ │ -_8_6 bool _o_p_e_r_a_t_o_r_ _=_=_ (_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &other) const { │ │ │ │ │ -87 return (_o_f_f_s_e_t == other._o_f_f_s_e_t && │ │ │ │ │ -88 _l_e_n_g_t_h == other._l_e_n_g_t_h && │ │ │ │ │ -89 _s_t_r_i_d_e == other._s_t_r_i_d_e); │ │ │ │ │ -90 } │ │ │ │ │ -91 │ │ │ │ │ -_9_3 bool _o_p_e_r_a_t_o_r_ _!_=_ (_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &other) const { │ │ │ │ │ -94 return !(this->_o_p_e_r_a_t_o_r_=_=(other)); │ │ │ │ │ -95 } │ │ │ │ │ -96 │ │ │ │ │ -_9_8 int _o_f_f_s_e_t; │ │ │ │ │ -_1_0_0 int _l_e_n_g_t_h; │ │ │ │ │ -_1_0_2 int _s_t_r_i_d_e; │ │ │ │ │ -103}; │ │ │ │ │ -104 │ │ │ │ │ -105} // end namespace Osd │ │ │ │ │ -106 │ │ │ │ │ -107} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ -108using namespace OPENSUBDIV_VERSION; │ │ │ │ │ -109 │ │ │ │ │ -110} // end namespace OpenSubdiv │ │ │ │ │ -111 │ │ │ │ │ -112#endif // OPENSUBDIV3_OSD_BUFFER_DESCRIPTOR_H │ │ │ │ │ +85 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +86 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +87 &stencilTable->GetSizes()[0], │ │ │ │ │ +88 &stencilTable->GetOffsets()[0], │ │ │ │ │ +89 &stencilTable->GetControlIndices()[0], │ │ │ │ │ +90 &stencilTable->GetWeights()[0], │ │ │ │ │ +91 /*start = */ 0, │ │ │ │ │ +92 /*end = */ stencilTable->GetNumStencils()); │ │ │ │ │ +93 } │ │ │ │ │ +94 │ │ │ │ │ +_1_2_1 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +122 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +123 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +124 const int * sizes, │ │ │ │ │ +125 const int * offsets, │ │ │ │ │ +126 const int * indices, │ │ │ │ │ +127 const float * weights, │ │ │ │ │ +128 int start, int end); │ │ │ │ │ +129 │ │ │ │ │ +167 template │ │ │ │ │ +_1_6_8 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +169 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +170 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +171 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +172 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +173 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +174 const _C_p_u_E_v_a_l_u_a_t_o_r *instance = NULL, │ │ │ │ │ +175 void * deviceContext = NULL) { │ │ │ │ │ +176 │ │ │ │ │ +177 (void)instance; // unused │ │ │ │ │ +178 (void)deviceContext; // unused │ │ │ │ │ +179 │ │ │ │ │ +180 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +181 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +182 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +183 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +184 &stencilTable->GetSizes()[0], │ │ │ │ │ +185 &stencilTable->GetOffsets()[0], │ │ │ │ │ +186 &stencilTable->GetControlIndices()[0], │ │ │ │ │ +187 &stencilTable->GetWeights()[0], │ │ │ │ │ +188 &stencilTable->GetDuWeights()[0], │ │ │ │ │ +189 &stencilTable->GetDvWeights()[0], │ │ │ │ │ +190 /*start = */ 0, │ │ │ │ │ +191 /*end = */ stencilTable->GetNumStencils()); │ │ │ │ │ +192 } │ │ │ │ │ +193 │ │ │ │ │ +_2_3_4 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +235 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +236 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +237 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +238 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +239 const int * sizes, │ │ │ │ │ +240 const int * offsets, │ │ │ │ │ +241 const int * indices, │ │ │ │ │ +242 const float * weights, │ │ │ │ │ +243 const float * duWeights, │ │ │ │ │ +244 const float * dvWeights, │ │ │ │ │ +245 int start, int end); │ │ │ │ │ +246 │ │ │ │ │ +302 template │ │ │ │ │ +_3_0_3 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +304 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +305 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +306 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +307 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +308 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +309 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +310 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +311 STENCIL_TABLE const *stencilTable, │ │ │ │ │ +312 const _C_p_u_E_v_a_l_u_a_t_o_r *instance = NULL, │ │ │ │ │ +313 void * deviceContext = NULL) { │ │ │ │ │ +314 │ │ │ │ │ +315 (void)instance; // unused │ │ │ │ │ +316 (void)deviceContext; // unused │ │ │ │ │ +317 │ │ │ │ │ +318 return _E_v_a_l_S_t_e_n_c_i_l_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +319 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +320 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +321 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +322 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ +323 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ +324 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ +325 &stencilTable->GetSizes()[0], │ │ │ │ │ +326 &stencilTable->GetOffsets()[0], │ │ │ │ │ +327 &stencilTable->GetControlIndices()[0], │ │ │ │ │ +328 &stencilTable->GetWeights()[0], │ │ │ │ │ +329 &stencilTable->GetDuWeights()[0], │ │ │ │ │ +330 &stencilTable->GetDvWeights()[0], │ │ │ │ │ +331 &stencilTable->GetDuuWeights()[0], │ │ │ │ │ +332 &stencilTable->GetDuvWeights()[0], │ │ │ │ │ +333 &stencilTable->GetDvvWeights()[0], │ │ │ │ │ +334 /*start = */ 0, │ │ │ │ │ +335 /*end = */ stencilTable->GetNumStencils()); │ │ │ │ │ +336 } │ │ │ │ │ +337 │ │ │ │ │ +_3_9_9 static bool _E_v_a_l_S_t_e_n_c_i_l_s( │ │ │ │ │ +400 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +401 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +402 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +403 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +404 float *duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +405 float *duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +406 float *dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +407 const int * sizes, │ │ │ │ │ +408 const int * offsets, │ │ │ │ │ +409 const int * indices, │ │ │ │ │ +410 const float * weights, │ │ │ │ │ +411 const float * duWeights, │ │ │ │ │ +412 const float * dvWeights, │ │ │ │ │ +413 const float * duuWeights, │ │ │ │ │ +414 const float * duvWeights, │ │ │ │ │ +415 const float * dvvWeights, │ │ │ │ │ +416 int start, int end); │ │ │ │ │ +417 │ │ │ │ │ +423 │ │ │ │ │ +452 template │ │ │ │ │ +_4_5_4 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +455 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +456 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +457 int numPatchCoords, │ │ │ │ │ +458 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +459 PATCH_TABLE *patchTable, │ │ │ │ │ +460 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +461 void * deviceContext = NULL) { │ │ │ │ │ +462 │ │ │ │ │ +463 (void)instance; // unused │ │ │ │ │ +464 (void)deviceContext; // unused │ │ │ │ │ +465 │ │ │ │ │ +466 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +467 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +468 numPatchCoords, │ │ │ │ │ +469 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +470 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ +471 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +472 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +473 } │ │ │ │ │ +474 │ │ │ │ │ +515 template │ │ │ │ │ +_5_1_7 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +518 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +519 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +520 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +521 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +522 int numPatchCoords, │ │ │ │ │ +523 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +524 PATCH_TABLE *patchTable, │ │ │ │ │ +525 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +526 void * deviceContext = NULL) { │ │ │ │ │ +527 │ │ │ │ │ +528 (void)instance; // unused │ │ │ │ │ +529 (void)deviceContext; // unused │ │ │ │ │ +530 │ │ │ │ │ +531 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop. │ │ │ │ │ +532 // ideally all buffer classes should have templated by datatype │ │ │ │ │ +533 // so that downcast isn't needed there. │ │ │ │ │ +534 // (e.g. Osd::CpuBuffer ) │ │ │ │ │ +535 // │ │ │ │ │ +536 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +537 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +538 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +539 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +540 numPatchCoords, │ │ │ │ │ +541 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +542 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ +543 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +544 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +545 } │ │ │ │ │ +546 │ │ │ │ │ +605 template │ │ │ │ │ +_6_0_7 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +608 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +609 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +610 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +611 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +612 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +613 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +614 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +615 int numPatchCoords, │ │ │ │ │ +616 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +617 PATCH_TABLE *patchTable, │ │ │ │ │ +618 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +619 void * deviceContext = NULL) { │ │ │ │ │ +620 │ │ │ │ │ +621 (void)instance; // unused │ │ │ │ │ +622 (void)deviceContext; // unused │ │ │ │ │ +623 │ │ │ │ │ +624 // XXX: PatchCoords is somewhat abusing vertex primvar buffer interop. │ │ │ │ │ +625 // ideally all buffer classes should have templated by datatype │ │ │ │ │ +626 // so that downcast isn't needed there. │ │ │ │ │ +627 // (e.g. Osd::CpuBuffer ) │ │ │ │ │ +628 // │ │ │ │ │ +629 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +630 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +631 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +632 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +633 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ +634 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ +635 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ +636 numPatchCoords, │ │ │ │ │ +637 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +638 patchTable->GetPatchArrayBuffer(), │ │ │ │ │ +639 patchTable->GetPatchIndexBuffer(), │ │ │ │ │ +640 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +641 } │ │ │ │ │ +642 │ │ │ │ │ +_6_7_0 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +671 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +672 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +673 int numPatchCoords, │ │ │ │ │ +674 const _P_a_t_c_h_C_o_o_r_d *patchCoords, │ │ │ │ │ +675 const _P_a_t_c_h_A_r_r_a_y *patchArrays, │ │ │ │ │ +676 const int *patchIndexBuffer, │ │ │ │ │ +677 const _P_a_t_c_h_P_a_r_a_m *patchParamBuffer); │ │ │ │ │ +678 │ │ │ │ │ +_7_1_6 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +717 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +718 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +719 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +720 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +721 int numPatchCoords, │ │ │ │ │ +722 _P_a_t_c_h_C_o_o_r_d const *patchCoords, │ │ │ │ │ +723 _P_a_t_c_h_A_r_r_a_y const *patchArrays, │ │ │ │ │ +724 const int *patchIndexBuffer, │ │ │ │ │ +725 _P_a_t_c_h_P_a_r_a_m const *patchParamBuffer); │ │ │ │ │ +726 │ │ │ │ │ +_7_7_9 static bool _E_v_a_l_P_a_t_c_h_e_s( │ │ │ │ │ +780 const float *src, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +781 float *dst, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +782 float *du, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +783 float *dv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +784 float *duu, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +785 float *duv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +786 float *dvv, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +787 int numPatchCoords, │ │ │ │ │ +788 _P_a_t_c_h_C_o_o_r_d const *patchCoords, │ │ │ │ │ +789 _P_a_t_c_h_A_r_r_a_y const *patchArrays, │ │ │ │ │ +790 const int *patchIndexBuffer, │ │ │ │ │ +791 _P_a_t_c_h_P_a_r_a_m const *patchParamBuffer); │ │ │ │ │ +792 │ │ │ │ │ +821 template │ │ │ │ │ +_8_2_3 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +824 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +825 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +826 int numPatchCoords, │ │ │ │ │ +827 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +828 PATCH_TABLE *patchTable, │ │ │ │ │ +829 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +830 void * deviceContext = NULL) { │ │ │ │ │ +831 │ │ │ │ │ +832 (void)instance; // unused │ │ │ │ │ +833 (void)deviceContext; // unused │ │ │ │ │ +834 │ │ │ │ │ +835 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +836 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +837 numPatchCoords, │ │ │ │ │ +838 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +839 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ +840 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +841 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +842 } │ │ │ │ │ +843 │ │ │ │ │ +884 template │ │ │ │ │ +_8_8_6 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +887 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +888 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +889 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +890 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +891 int numPatchCoords, │ │ │ │ │ +892 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +893 PATCH_TABLE *patchTable, │ │ │ │ │ +894 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +895 void * deviceContext = NULL) { │ │ │ │ │ +896 │ │ │ │ │ +897 (void)instance; // unused │ │ │ │ │ +898 (void)deviceContext; // unused │ │ │ │ │ +899 │ │ │ │ │ +900 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +901 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +902 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +903 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +904 numPatchCoords, │ │ │ │ │ +905 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +906 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ +907 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +908 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +909 } │ │ │ │ │ +910 │ │ │ │ │ +969 template │ │ │ │ │ +_9_7_1 static bool _E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g( │ │ │ │ │ +972 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +973 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +974 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +975 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +976 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +977 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +978 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +979 int numPatchCoords, │ │ │ │ │ +980 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +981 PATCH_TABLE *patchTable, │ │ │ │ │ +982 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +983 void * deviceContext = NULL) { │ │ │ │ │ +984 │ │ │ │ │ +985 (void)instance; // unused │ │ │ │ │ +986 (void)deviceContext; // unused │ │ │ │ │ +987 │ │ │ │ │ +988 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +989 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +990 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +991 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +992 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ +993 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ +994 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ +995 numPatchCoords, │ │ │ │ │ +996 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +997 patchTable->GetVaryingPatchArrayBuffer(), │ │ │ │ │ +998 patchTable->GetVaryingPatchIndexBuffer(), │ │ │ │ │ +999 patchTable->GetPatchParamBuffer()); │ │ │ │ │ +1000 } │ │ │ │ │ +1001 │ │ │ │ │ +1032 template │ │ │ │ │ +_1_0_3_4 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1035 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1036 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1037 int numPatchCoords, │ │ │ │ │ +1038 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1039 PATCH_TABLE *patchTable, │ │ │ │ │ +1040 int fvarChannel, │ │ │ │ │ +1041 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +1042 void * deviceContext = NULL) { │ │ │ │ │ +1043 │ │ │ │ │ +1044 (void)instance; // unused │ │ │ │ │ +1045 (void)deviceContext; // unused │ │ │ │ │ +1046 │ │ │ │ │ +1047 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +1048 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +1049 numPatchCoords, │ │ │ │ │ +1050 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +1051 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ +1052 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +1053 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ +1054 } │ │ │ │ │ +1055 │ │ │ │ │ +1098 template │ │ │ │ │ +_1_1_0_0 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1101 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1102 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1103 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1104 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1105 int numPatchCoords, │ │ │ │ │ +1106 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1107 PATCH_TABLE *patchTable, │ │ │ │ │ +1108 int fvarChannel, │ │ │ │ │ +1109 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +1110 void * deviceContext = NULL) { │ │ │ │ │ +1111 │ │ │ │ │ +1112 (void)instance; // unused │ │ │ │ │ +1113 (void)deviceContext; // unused │ │ │ │ │ +1114 │ │ │ │ │ +1115 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +1116 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +1117 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +1118 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +1119 numPatchCoords, │ │ │ │ │ +1120 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +1121 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ +1122 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +1123 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ +1124 } │ │ │ │ │ +1125 │ │ │ │ │ +1186 template │ │ │ │ │ +_1_1_8_8 static bool _E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g( │ │ │ │ │ +1189 SRC_BUFFER *srcBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &srcDesc, │ │ │ │ │ +1190 DST_BUFFER *dstBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dstDesc, │ │ │ │ │ +1191 DST_BUFFER *duBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duDesc, │ │ │ │ │ +1192 DST_BUFFER *dvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvDesc, │ │ │ │ │ +1193 DST_BUFFER *duuBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duuDesc, │ │ │ │ │ +1194 DST_BUFFER *duvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &duvDesc, │ │ │ │ │ +1195 DST_BUFFER *dvvBuffer, _B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r const &dvvDesc, │ │ │ │ │ +1196 int numPatchCoords, │ │ │ │ │ +1197 PATCHCOORD_BUFFER *patchCoords, │ │ │ │ │ +1198 PATCH_TABLE *patchTable, │ │ │ │ │ +1199 int fvarChannel, │ │ │ │ │ +1200 _C_p_u_E_v_a_l_u_a_t_o_r const *instance = NULL, │ │ │ │ │ +1201 void * deviceContext = NULL) { │ │ │ │ │ +1202 │ │ │ │ │ +1203 (void)instance; // unused │ │ │ │ │ +1204 (void)deviceContext; // unused │ │ │ │ │ +1205 │ │ │ │ │ +1206 return _E_v_a_l_P_a_t_c_h_e_s(srcBuffer->BindCpuBuffer(), srcDesc, │ │ │ │ │ +1207 dstBuffer->BindCpuBuffer(), dstDesc, │ │ │ │ │ +1208 duBuffer->BindCpuBuffer(), duDesc, │ │ │ │ │ +1209 dvBuffer->BindCpuBuffer(), dvDesc, │ │ │ │ │ +1210 duuBuffer->BindCpuBuffer(), duuDesc, │ │ │ │ │ +1211 duvBuffer->BindCpuBuffer(), duvDesc, │ │ │ │ │ +1212 dvvBuffer->BindCpuBuffer(), dvvDesc, │ │ │ │ │ +1213 numPatchCoords, │ │ │ │ │ +1214 (const _P_a_t_c_h_C_o_o_r_d*)patchCoords->BindCpuBuffer(), │ │ │ │ │ +1215 patchTable->GetFVarPatchArrayBuffer(fvarChannel), │ │ │ │ │ +1216 patchTable->GetFVarPatchIndexBuffer(fvarChannel), │ │ │ │ │ +1217 patchTable->GetFVarPatchParamBuffer(fvarChannel)); │ │ │ │ │ +1218 } │ │ │ │ │ +1219 │ │ │ │ │ +1225 │ │ │ │ │ +_1_2_2_7 static void _S_y_n_c_h_r_o_n_i_z_e(void * /*deviceContext = NULL*/) { │ │ │ │ │ +1228 // nothing. │ │ │ │ │ +1229 } │ │ │ │ │ +1230}; │ │ │ │ │ +1231 │ │ │ │ │ +1232 │ │ │ │ │ +1233} // end namespace Osd │ │ │ │ │ +1234 │ │ │ │ │ +1235} // end namespace OPENSUBDIV_VERSION │ │ │ │ │ +1236using namespace OPENSUBDIV_VERSION; │ │ │ │ │ +1237 │ │ │ │ │ +1238} // end namespace OpenSubdiv │ │ │ │ │ +1239 │ │ │ │ │ +1240 │ │ │ │ │ +1241#endif // OPENSUBDIV3_OSD_CPU_EVALUATOR_H │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v │ │ │ │ │ DDeeffiinniittiioonn _l_i_m_i_t_s_._h_:_3_2 │ │ │ │ │ _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ BufferDescriptor is a struct which describes buffer elements in interleaved │ │ │ │ │ data buffers.... │ │ │ │ │ DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_s_t_r_i_d_e │ │ │ │ │ -int stride │ │ │ │ │ -stride to the next element │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_1_0_2 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_R_e_s_e_t │ │ │ │ │ -void Reset() │ │ │ │ │ -Resets the descriptor to default. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_8_1 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -BufferDescriptor() │ │ │ │ │ -Default Constructor. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_4 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r │ │ │ │ │ -BufferDescriptor(int o, int l, int s) │ │ │ │ │ -Constructor. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_6_7 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_l_e_n_g_t_h │ │ │ │ │ -int length │ │ │ │ │ -number or length of the data │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_1_0_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_!_= │ │ │ │ │ -bool operator!=(BufferDescriptor const &other) const │ │ │ │ │ -True if the descriptors are not identical. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_9_3 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ │ -bool operator==(BufferDescriptor const &other) const │ │ │ │ │ -True if the descriptors are identical. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_8_6 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_I_s_V_a_l_i_d │ │ │ │ │ -bool IsValid() const │ │ │ │ │ -True if the descriptor values are internally consistent. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_7_5 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_G_e_t_L_o_c_a_l_O_f_f_s_e_t │ │ │ │ │ -int GetLocalOffset() const │ │ │ │ │ -Returns the relative offset within a stride. │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_7_0 │ │ │ │ │ -_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_B_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_:_:_o_f_f_s_e_t │ │ │ │ │ -int offset │ │ │ │ │ -offset to desired element data │ │ │ │ │ -DDeeffiinniittiioonn _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h_:_9_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_3_9 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int │ │ │ │ │ +fvarChannel, CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_0_3_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ +DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, int fvarChannel, CpuEvaluator const │ │ │ │ │ +*instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_1_0_0 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ +float *dst, BufferDescriptor const &dstDesc, const int *sizes, const int │ │ │ │ │ +*offsets, const int *indices, const float *weights, int start, int end) │ │ │ │ │ +Static eval stencils function which takes raw CPU pointers for input and │ │ │ │ │ +output. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_F_a_c_e_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesFaceVarying(SRC_BUFFER *srcBuffer, BufferDescriptor │ │ │ │ │ +const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, │ │ │ │ │ +DST_BUFFER *duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, int fvarChannel, │ │ │ │ │ +CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_1_8_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const │ │ │ │ │ +*instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_9_7_1 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ +float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ +&duDesc, float *dv, BufferDescriptor const &dvDesc, const int *sizes, const int │ │ │ │ │ +*offsets, const int *indices, const float *weights, const float *duWeights, │ │ │ │ │ +const float *dvWeights, int start, int end) │ │ │ │ │ +Static eval stencils function with derivatives, which takes raw CPU pointers │ │ │ │ │ +for input and output. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ +float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ +&duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, │ │ │ │ │ +BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, │ │ │ │ │ +float *dvv, BufferDescriptor const &dvvDesc, const int *sizes, const int │ │ │ │ │ +*offsets, const int *indices, const float *weights, const float *duWeights, │ │ │ │ │ +const float *dvWeights, const float *duuWeights, const float *duvWeights, const │ │ │ │ │ +float *dvvWeights, int start, int end) │ │ │ │ │ +Static eval stencils function with derivatives, which takes raw CPU pointers │ │ │ │ │ +for input and output. │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ +float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ +&duDesc, float *dv, BufferDescriptor const &dvDesc, float *duu, │ │ │ │ │ +BufferDescriptor const &duuDesc, float *duv, BufferDescriptor const &duvDesc, │ │ │ │ │ +float *dvv, BufferDescriptor const &dvvDesc, int numPatchCoords, PatchCoord │ │ │ │ │ +const *patchCoords, PatchArray const *patchArrays, const int *patchIndexBuffer, │ │ │ │ │ +PatchParam const *patchParamBuffer) │ │ │ │ │ +Static limit eval function. It takes an array of PatchCoord and evaluate limit │ │ │ │ │ +values on given PatchT... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int numPatchCoords, │ │ │ │ │ +PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const │ │ │ │ │ +*instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_4_5_4 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, int numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE │ │ │ │ │ +*patchTable, CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function with derivatives. This function has a same │ │ │ │ │ +signature as other device kern... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_5_1_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ +float *dst, BufferDescriptor const &dstDesc, float *du, BufferDescriptor const │ │ │ │ │ +&duDesc, float *dv, BufferDescriptor const &dvDesc, int numPatchCoords, │ │ │ │ │ +PatchCoord const *patchCoords, PatchArray const *patchArrays, const int │ │ │ │ │ +*patchIndexBuffer, PatchParam const *patchParamBuffer) │ │ │ │ │ +Static limit eval function. It takes an array of PatchCoord and evaluate limit │ │ │ │ │ +values on given PatchT... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const │ │ │ │ │ +&duuDesc, DST_BUFFER *duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER │ │ │ │ │ +*dvvBuffer, BufferDescriptor const &dvvDesc, STENCIL_TABLE const *stencilTable, │ │ │ │ │ +const CpuEvaluator *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic static eval stencils function with derivatives. This function has a │ │ │ │ │ +same signature as other d... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_3_0_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(const float *src, BufferDescriptor const &srcDesc, │ │ │ │ │ +float *dst, BufferDescriptor const &dstDesc, int numPatchCoords, const │ │ │ │ │ +PatchCoord *patchCoords, const PatchArray *patchArrays, const int │ │ │ │ │ +*patchIndexBuffer, const PatchParam *patchParamBuffer) │ │ │ │ │ +Static limit eval function. It takes an array of PatchCoord and evaluate limit │ │ │ │ │ +values on given PatchT... │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_8_8_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s_V_a_r_y_i_n_g │ │ │ │ │ +static bool EvalPatchesVarying(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, int │ │ │ │ │ +numPatchCoords, PATCHCOORD_BUFFER *patchCoords, PATCH_TABLE *patchTable, │ │ │ │ │ +CpuEvaluator const *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic limit eval function. This function has a same signature as other device │ │ │ │ │ +kernels have so that ... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_8_2_3 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_S_y_n_c_h_r_o_n_i_z_e │ │ │ │ │ +static void Synchronize(void *) │ │ │ │ │ +synchronize all asynchronous computation invoked on this device. │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_2_2_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE │ │ │ │ │ +const *stencilTable, const CpuEvaluator *instance=NULL, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +Generic static eval stencils function. This function has a same signature as │ │ │ │ │ +other device kernels hav... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_7_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_P_a_t_c_h_e_s │ │ │ │ │ +static bool EvalPatches(SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, │ │ │ │ │ +DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER *duBuffer, │ │ │ │ │ +BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, BufferDescriptor const │ │ │ │ │ +&dvDesc, DST_BUFFER *duuBuffer, BufferDescriptor const &duuDesc, DST_BUFFER │ │ │ │ │ +*duvBuffer, BufferDescriptor const &duvDesc, DST_BUFFER *dvvBuffer, │ │ │ │ │ +BufferDescriptor const &dvvDesc, int numPatchCoords, PATCHCOORD_BUFFER │ │ │ │ │ +*patchCoords, PATCH_TABLE *patchTable, CpuEvaluator const *instance=NULL, void │ │ │ │ │ +*deviceContext=NULL) │ │ │ │ │ +Generic limit eval function with derivatives. This function has a same │ │ │ │ │ +signature as other device kern... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_6_0_7 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_C_p_u_E_v_a_l_u_a_t_o_r_:_:_E_v_a_l_S_t_e_n_c_i_l_s │ │ │ │ │ +static bool EvalStencils(SRC_BUFFER *srcBuffer, BufferDescriptor const │ │ │ │ │ +&srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, DST_BUFFER │ │ │ │ │ +*duBuffer, BufferDescriptor const &duDesc, DST_BUFFER *dvBuffer, │ │ │ │ │ +BufferDescriptor const &dvDesc, STENCIL_TABLE const *stencilTable, const │ │ │ │ │ +CpuEvaluator *instance=NULL, void *deviceContext=NULL) │ │ │ │ │ +Generic static eval stencils function with derivatives. This function has a │ │ │ │ │ +same signature as other d... │ │ │ │ │ +DDeeffiinniittiioonn _c_p_u_E_v_a_l_u_a_t_o_r_._h_:_1_6_8 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_C_o_o_r_d │ │ │ │ │ +Coordinates set on a patch table. │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_4_2 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_A_r_r_a_y │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_6_6 │ │ │ │ │ +_O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_O_s_d_:_:_P_a_t_c_h_P_a_r_a_m │ │ │ │ │ +DDeeffiinniittiioonn _t_y_p_e_s_._h_:_1_2_7 │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _o_s_d │ │ │ │ │ - * _b_u_f_f_e_r_D_e_s_c_r_i_p_t_o_r_._h │ │ │ │ │ + * _c_p_u_E_v_a_l_u_a_t_o_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8 │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00908.html │ │ │ │ @@ -280,15 +280,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef Vtr::ConstArray<PatchDescriptor> ConstPatchDescriptorArray
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 146 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 146 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ ConstPatchParamArray

│ │ │ │ │ │ │ │
│ │ │ │ @@ -296,15 +296,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef Vtr::ConstArray<PatchParam> ConstPatchParamArray
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 246 of file patchParam.h.

│ │ │ │ +

Definition at line 246 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ ErrorCallbackFunc

│ │ │ │ │ │ │ │
│ │ │ │ @@ -394,15 +394,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef Vtr::Array<PatchParam> PatchParamArray
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 245 of file patchParam.h.

│ │ │ │ +

Definition at line 245 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PatchParamTable

│ │ │ │ │ │ │ │
│ │ │ │ @@ -410,15 +410,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef std::vector<PatchParam> PatchParamTable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 243 of file patchParam.h.

│ │ │ │ +

Definition at line 243 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ WarningCallbackFunc

│ │ │ │ │ │ │ │
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00912.html │ │ │ │ @@ -294,15 +294,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef MeshInterface<D3D11PatchTable> D3D11MeshInterface
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 38 of file d3d11Mesh.h.

│ │ │ │ +

Definition at line 38 of file d3d11Mesh.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GLMeshInterface

│ │ │ │ │ │ │ │
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a00961.html │ │ │ │ @@ -97,15 +97,15 @@ │ │ │ │
Tessellation Class Reference
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Encapsulates a specific tessellation pattern of a Parameterization. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <tessellation.h>

│ │ │ │ +

#include <tessellation.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  Options
 Options configure a Tessellation to specify the nature of both its results and the structure of the coordinate and facet index arrays that its methods will populate. More...
 
│ │ │ │ @@ -219,15 +219,15 @@ │ │ │ │ │ │ │ │
 
│ │ │ │

Detailed Description

│ │ │ │

Encapsulates a specific tessellation pattern of a Parameterization.

│ │ │ │

Tessellation is a simple class that encapsulates a specified tessellation pattern for a given Parameterization. Tessellation parameters are given on construction and are fixed for its lifetime.

│ │ │ │

Methods allow inspection of the pattern in terms of the 2D coordinates of the points comprising the pattern and the faces that connect them. The 2D coordinates are referred to both in the documentation and the interface as "coords" while the faces connecting them are referred to as "facets" (to distinguish from the faces of the mesh, to which a Tessellation is applied).

│ │ │ │ │ │ │ │ -

Definition at line 51 of file tessellation.h.

│ │ │ │ +

Definition at line 51 of file tessellation.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Tessellation() [1/4]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -445,15 +445,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Retrieve the coordinates for the entire pattern.

│ │ │ │ │ │ │ │ -

Definition at line 372 of file tessellation.h.

│ │ │ │ +

Definition at line 372 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetCoordStride()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -474,15 +474,15 @@ │ │ │ │ inline

│ │ │ │
│ │ │ │ │ │ │ │

Return the number of elements between each coordinate.

│ │ │ │ │ │ │ │ -

Definition at line 208 of file tessellation.h.

│ │ │ │ +

Definition at line 208 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeCoords()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -535,15 +535,15 @@ │ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │

Return the size of the face.

│ │ │ │ │ │ │ │ -

Definition at line 182 of file tessellation.h.

│ │ │ │ +

Definition at line 182 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFacets()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -584,15 +584,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of indices assigned to each facet.

│ │ │ │ │ │ │ │ -

Definition at line 258 of file tessellation.h.

│ │ │ │ +

Definition at line 258 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFacetStride()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -613,15 +613,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of elements between each facet.

│ │ │ │ │ │ │ │ -

Definition at line 261 of file tessellation.h.

│ │ │ │ +

Definition at line 261 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetInteriorCoords()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -664,15 +664,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of boundary coordinates.

│ │ │ │ │ │ │ │ -

Definition at line 211 of file tessellation.h.

│ │ │ │ +

Definition at line 211 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumCoords()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -693,15 +693,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of coordinates in the entire pattern.

│ │ │ │ │ │ │ │ -

Definition at line 205 of file tessellation.h.

│ │ │ │ +

Definition at line 205 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumEdgeCoords()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -723,15 +723,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of coordinates within a given edge (excluding those at its end vertices)

│ │ │ │ │ │ │ │ -

Definition at line 218 of file tessellation.h.

│ │ │ │ +

Definition at line 218 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFacets()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -752,15 +752,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of facets in the entire pattern.

│ │ │ │ │ │ │ │ -

Definition at line 255 of file tessellation.h.

│ │ │ │ +

Definition at line 255 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumInteriorCoords()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -781,15 +781,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of interior coordinates.

│ │ │ │ │ │ │ │ -

Definition at line 214 of file tessellation.h.

│ │ │ │ +

Definition at line 214 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetParameterization()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -810,15 +810,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the Parameterization.

│ │ │ │ │ │ │ │ -

Definition at line 179 of file tessellation.h.

│ │ │ │ +

Definition at line 179 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetRates()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -872,15 +872,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Retrieve the coordinate for a given vertex of the face.

│ │ │ │ │ │ │ │ -

Definition at line 365 of file tessellation.h.

│ │ │ │ +

Definition at line 365 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsUniform()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -901,15 +901,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the pattern is uniform.

│ │ │ │ │ │ │ │ -

Definition at line 188 of file tessellation.h.

│ │ │ │ +

Definition at line 188 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsValid()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -930,15 +930,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return true if correctly initialized.

│ │ │ │ │ │ │ │ -

Definition at line 162 of file tessellation.h.

│ │ │ │ +

Definition at line 162 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator=()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1063,15 +1063,15 @@ │ │ │ │
│ │ │ │ │ │ │ │

Reassign indices of boundary coordinates while offseting those of interior coordinates.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Options configure a Tessellation to specify the nature of both its results and the structure of the coordinate and facet index arrays that its methods will populate. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <tessellation.h>

│ │ │ │ +

#include <tessellation.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -132,15 +132,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 Options ()
 
OptionsPreserveQuads (bool on)
 Select preservation of quads for quad-based subdivision (requires 4-sided facets, default is off)
 
│ │ │ │

Detailed Description

│ │ │ │

Options configure a Tessellation to specify the nature of both its results and the structure of the coordinate and facet index arrays that its methods will populate.

│ │ │ │

The sizes and strides of the target arrays should be specified explicitly as they are not inferred by the presence of other options.

│ │ │ │

Modifiers of Options return a reference to itself to facilitate inline usage.

│ │ │ │ │ │ │ │ -

Definition at line 65 of file tessellation.h.

│ │ │ │ +

Definition at line 65 of file tessellation.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Options()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -157,15 +157,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 67 of file tessellation.h.

│ │ │ │ +

Definition at line 67 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetCoordStride()

│ │ │ │ │ │ │ │ @@ -187,15 +187,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the stride between (u,v) pairs.

│ │ │ │ │ │ │ │ -

Definition at line 90 of file tessellation.h.

│ │ │ │ +

Definition at line 90 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFacetSize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -214,15 +214,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 80 of file tessellation.h.

│ │ │ │ +

Definition at line 80 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFacetStride()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -243,15 +243,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the stride between facets.

│ │ │ │ │ │ │ │ -

Definition at line 85 of file tessellation.h.

│ │ │ │ +

Definition at line 85 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PreserveQuads() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -272,15 +272,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if preservation of quads is set.

│ │ │ │ │ │ │ │ -

Definition at line 74 of file tessellation.h.

│ │ │ │ +

Definition at line 74 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PreserveQuads() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -302,15 +302,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Select preservation of quads for quad-based subdivision (requires 4-sided facets, default is off)

│ │ │ │ │ │ │ │ -

Definition at line 343 of file tessellation.h.

│ │ │ │ +

Definition at line 343 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetCoordStride()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -332,15 +332,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the stride between (u,v) pairs (default is 2)

│ │ │ │ │ │ │ │ -

Definition at line 358 of file tessellation.h.

│ │ │ │ +

Definition at line 358 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetFacetSize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -362,15 +362,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the number of indices per facet (must be 3 or 4, default is 3)

│ │ │ │ │ │ │ │ -

Definition at line 348 of file tessellation.h.

│ │ │ │ +

Definition at line 348 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetFacetStride()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -392,20 +392,20 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the stride between facets (default is facet size)

│ │ │ │ │ │ │ │ -

Definition at line 353 of file tessellation.h.

│ │ │ │ +

Definition at line 353 of file tessellation.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Simple class used by subclasses of SurfaceFactory to describe a vertex. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <vertexDescriptor.h>

│ │ │ │ +

#include <vertexDescriptor.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -178,15 +178,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

Methods to begin and end specification

Partially constructed instances are populated using a set of methods between calls to Initialize() and Finalize(). Both return false to indicate failure due to invalid input, or the instance can be inspected after each to determine if valid.

│ │ │ │
bool Initialize (int numIncidentFaces)
 
│ │ │ │

Detailed Description

│ │ │ │

Simple class used by subclasses of SurfaceFactory to describe a vertex.

│ │ │ │

VertexDescriptor is a simple class used by SurfaceFactory and its subclasses to provide a complete topological description around the vertex of a face, i.e. its valence, the sizes of its incident faces, sharpness values, etc.

│ │ │ │

Instances are created and partially initialized by SurfaceFactory before being passed to its subclasses to be fully populated. So public construction is not available (or useful).

│ │ │ │ │ │ │ │ -

Definition at line 131 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 131 of file vertexDescriptor.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ ClearEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -205,15 +205,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Remove any sharpness assigned to the incident edges.

│ │ │ │ │ │ │ │ -

Definition at line 398 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 398 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ ClearIncidentFaceSizes()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -234,15 +234,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Remove any assigned sizes of incident faces.

│ │ │ │ │ │ │ │ -

Definition at line 350 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 350 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ ClearVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -263,15 +263,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Remove any sharpness assigned to the vertex.

│ │ │ │ │ │ │ │ -

Definition at line 377 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 377 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Finalize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -328,15 +328,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the sharpness assigned to edges of an incident face.

│ │ │ │ │ │ │ │ -

Definition at line 436 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 436 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetIncidentFaceSize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -358,15 +358,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the size of an incident face.

│ │ │ │ │ │ │ │ -

Definition at line 362 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 362 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetManifoldEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -388,15 +388,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the sharpness assigned to a manifold edge.

│ │ │ │ │ │ │ │ -

Definition at line 420 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 420 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -417,15 +417,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the sharpness of the vertex.

│ │ │ │ │ │ │ │ -

Definition at line 386 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 386 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ HasEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -446,15 +446,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if sharpness was assigned to the incident edges.

│ │ │ │ │ │ │ │ -

Definition at line 394 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 394 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ HasIncidentFaceSizes()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -475,15 +475,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the sizes of incident faces are assigned.

│ │ │ │ │ │ │ │ -

Definition at line 346 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 346 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ HasVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -504,15 +504,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if sharpness was assigned to the vertex.

│ │ │ │ │ │ │ │ -

Definition at line 373 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 373 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Initialize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -553,15 +553,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if vertex neighborhood is on a boundary.

│ │ │ │ │ │ │ │ -

Definition at line 338 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 338 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsManifold()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -582,15 +582,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if vertex neighborhood is manifold.

│ │ │ │ │ │ │ │ -

Definition at line 329 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 329 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsValid()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -611,15 +611,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if instance is valid.

│ │ │ │ │ │ │ │ -

Definition at line 320 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 320 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetBoundary()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -641,15 +641,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Declare the vertex neighborhood as being on a boundary.

│ │ │ │ │ │ │ │ -

Definition at line 334 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 334 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetIncidentFaceEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -696,15 +696,15 @@ │ │ │ │ faceIndexIndex of the incident face │ │ │ │ leadingEdgeSharpSharpness to assign to the leading edge of the incident face, i.e. the edge of the face following the vertex. │ │ │ │ trailingEdgeSharpSharpness to assign to the trailing edge of the incident face, i.e. the edge of the face preceding the vertex. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 427 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 427 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetIncidentFaceSize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -736,15 +736,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the size of an incident face.

│ │ │ │ │ │ │ │ -

Definition at line 355 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 355 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetManifold()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -766,15 +766,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Declare the vertex neighborhood as manifold (ordered)

│ │ │ │ │ │ │ │ -

Definition at line 325 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 325 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetManifoldEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -814,15 +814,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
edgeIndexIndex of the edge in the ordered sequence
edgeSharpnessSharpness to be assigned to the edge
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 403 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 403 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -844,20 +844,20 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign sharpness to the vertex.

│ │ │ │ │ │ │ │ -

Definition at line 382 of file vertexDescriptor.h.

│ │ │ │ +

Definition at line 382 of file vertexDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Describes the type of a patch. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchDescriptor.h>

│ │ │ │ +

#include <patchDescriptor.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

enum  Type {
│ │ │ │   NON_PATCH = 0 │ │ │ │ ,
│ │ │ │   POINTS │ │ │ │ @@ -192,15 +192,15 @@ │ │ │ │
 Returns a vector of all the legal patch descriptors for the given adaptive subdivision scheme.
 
│ │ │ │

Detailed Description

│ │ │ │

Describes the type of a patch.

│ │ │ │

Uniquely identifies all the different types of patches

│ │ │ │ │ │ │ │ -

Definition at line 44 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 44 of file patchDescriptor.h.

│ │ │ │

Member Enumeration Documentation

│ │ │ │ │ │ │ │

◆ Type

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -226,15 +226,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
GREGORY 
GREGORY_BOUNDARY 
GREGORY_BASIS 
GREGORY_TRIANGLE 
│ │ │ │ │ │ │ │ -

Definition at line 48 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 48 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ PatchDescriptor() [1/3]

│ │ │ │ │ │ │ │ @@ -256,15 +256,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Default constructor.

│ │ │ │ │ │ │ │ -

Definition at line 69 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 69 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PatchDescriptor() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -286,15 +286,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Constructor.

│ │ │ │ │ │ │ │ -

Definition at line 73 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 73 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PatchDescriptor() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -316,15 +316,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Copy Constructor.

│ │ │ │ │ │ │ │ -

Definition at line 77 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 77 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetAdaptivePatchDescriptors()

│ │ │ │ │ │ │ │ @@ -374,15 +374,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Number of control vertices of Gregory patch basis (20)

│ │ │ │ │ │ │ │ -

Definition at line 126 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 126 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetGregoryPatchSize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -403,15 +403,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Number of control vertices of Gregory (and Gregory Boundary) Patches in table.

│ │ │ │ │ │ │ │ -

Definition at line 123 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 123 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumControlVertices() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -432,15 +432,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of control vertices expected for a patch of the type described.

│ │ │ │ │ │ │ │ -

Definition at line 110 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 110 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumControlVertices() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -462,15 +462,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of control vertices expected for a patch of the type described.

│ │ │ │ │ │ │ │ -

Definition at line 150 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 150 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarControlVertices() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -492,15 +492,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Deprecated.

│ │ │ │
See also
PatchDescriptor::GetNumControlVertices
│ │ │ │ │ │ │ │ -

Definition at line 115 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 115 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarControlVertices() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -523,15 +523,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Deprecated.

│ │ │ │
See also
PatchDescriptor::GetNumControlVertices
│ │ │ │ │ │ │ │ -

Definition at line 168 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 168 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetRegularPatchSize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -552,15 +552,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Number of control vertices of Regular Patches in table.

│ │ │ │ │ │ │ │ -

Definition at line 120 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 120 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetType()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -581,15 +581,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the type of the patch.

│ │ │ │ │ │ │ │ -

Definition at line 87 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 87 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsAdaptive() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -610,15 +610,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns true if the type is an adaptive patch.

│ │ │ │ │ │ │ │ -

Definition at line 97 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 97 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsAdaptive() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -640,15 +640,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns true if the type is an adaptive (non-linear) patch.

│ │ │ │ │ │ │ │ -

Definition at line 92 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 92 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator<()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -670,15 +670,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Allows ordering of patches by type.

│ │ │ │ │ │ │ │ -

Definition at line 173 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 173 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator=()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -700,15 +700,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assignment operator.

│ │ │ │ │ │ │ │ -

Definition at line 81 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 81 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator==()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -730,15 +730,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

True if the descriptors are identical.

│ │ │ │ │ │ │ │ -

Definition at line 180 of file patchDescriptor.h.

│ │ │ │ +

Definition at line 180 of file patchDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ print()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -752,15 +752,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An quadtree-based map connecting coarse faces to their sub-patches. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchMap.h>

│ │ │ │ +

#include <patchMap.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

typedef PatchTable::PatchHandle Handle
 
│ │ │ │ │ │ │ │

│ │ │ │ @@ -120,29 +120,29 @@ │ │ │ │

 
│ │ │ │

Detailed Description

│ │ │ │

An quadtree-based map connecting coarse faces to their sub-patches.

│ │ │ │

PatchTable::PatchArrays contain lists of patches that represent the limit surface of a mesh, sorted by their topological type. These arrays break the connection between coarse faces and their sub-patches.

│ │ │ │

The PatchMap provides a quad-tree based lookup structure that, given a singular parametric location, can efficiently return a handle to the sub-patch that contains this location.

│ │ │ │ │ │ │ │ -

Definition at line 49 of file patchMap.h.

│ │ │ │ +

Definition at line 49 of file patchMap.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ Handle

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef PatchTable::PatchHandle Handle
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 52 of file patchMap.h.

│ │ │ │ +

Definition at line 52 of file patchMap.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ PatchMap()

│ │ │ │ │ │ │ │ @@ -218,20 +218,20 @@ │ │ │ │ uLocal u parameter │ │ │ │ vLocal v parameter │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Returns
A patch handle or 0 if the face is not supported (index out of bounds) or is tagged as a hole
│ │ │ │ │ │ │ │ -

Definition at line 193 of file patchMap.h.

│ │ │ │ +

Definition at line 193 of file patchMap.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file:
    │ │ │ │ -
  • opensubdiv/far/patchMap.h
  • │ │ │ │ +
  • opensubdiv/far/patchMap.h
  • │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <patchMap.h>

│ │ │ │ +

#include <patchMap.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Attributes

unsigned int isSet: 1
 
unsigned int isLeaf: 1
 
unsigned int index: 30
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 85 of file patchMap.h.

│ │ │ │ +

Definition at line 85 of file patchMap.h.

│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ index

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int index
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 88 of file patchMap.h.

│ │ │ │ +

Definition at line 88 of file patchMap.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ isLeaf

│ │ │ │ │ │ │ │
│ │ │ │ @@ -137,15 +137,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int isLeaf
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 87 of file patchMap.h.

│ │ │ │ +

Definition at line 87 of file patchMap.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ isSet

│ │ │ │ │ │ │ │
│ │ │ │ @@ -153,20 +153,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int isSet
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 86 of file patchMap.h.

│ │ │ │ +

Definition at line 86 of file patchMap.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file:
    │ │ │ │ -
  • opensubdiv/far/patchMap.h
  • │ │ │ │ +
  • opensubdiv/far/patchMap.h
  • │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Patch parameterization. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchParam.h>

│ │ │ │ +

#include <patchParam.h>

│ │ │ │
│ │ │ │ Inheritance diagram for PatchParam:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ PatchParam │ │ │ │ @@ -249,15 +249,15 @@ │ │ │ │ | \ | \ | | \ | \ │ │ │ │ | L1 \ | L1 \ | | L1 \ | L1 \ │ │ │ │ | \ | \ | | \ | \ │ │ │ │ |0,0 \ |1,0 \ | | \ | \ │ │ │ │ +---------------+---------------+ +---------------+---------------+ │ │ │ │ (0,0) (1,0) (0,0,1) (1,0,0) │ │ │ │ │ │ │ │ -

Definition at line 152 of file patchParam.h.

│ │ │ │ +

Definition at line 152 of file patchParam.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ Clear()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -276,15 +276,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Resets everything to 0.

│ │ │ │ │ │ │ │ -

Definition at line 174 of file patchParam.h.

│ │ │ │ +

Definition at line 174 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetBoundary()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -305,15 +305,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the boundary edge encoding for the patch.

│ │ │ │ │ │ │ │ -

Definition at line 191 of file patchParam.h.

│ │ │ │ +

Definition at line 191 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDepth()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -334,15 +334,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the level of subdivision of the patch.

│ │ │ │ │ │ │ │ -

Definition at line 197 of file patchParam.h.

│ │ │ │ +

Definition at line 197 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetFaceId()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -363,15 +363,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the faceid.

│ │ │ │ │ │ │ │ -

Definition at line 177 of file patchParam.h.

│ │ │ │ +

Definition at line 177 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetParamFraction()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -392,15 +392,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the fraction of unit parametric space covered by this face.

│ │ │ │ │ │ │ │ -

Definition at line 265 of file patchParam.h.

│ │ │ │ +

Definition at line 265 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetTransition()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -421,15 +421,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the transition edge encoding for the patch.

│ │ │ │ │ │ │ │ -

Definition at line 188 of file patchParam.h.

│ │ │ │ +

Definition at line 188 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetU()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -450,15 +450,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the log2 value of the u parameter at the first corner of the patch.

│ │ │ │ │ │ │ │ -

Definition at line 181 of file patchParam.h.

│ │ │ │ +

Definition at line 181 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetV()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -479,15 +479,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the log2 value of the v parameter at the first corner of the patch.

│ │ │ │ │ │ │ │ -

Definition at line 185 of file patchParam.h.

│ │ │ │ +

Definition at line 185 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsRegular()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -508,15 +508,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns whether the patch is regular.

│ │ │ │ │ │ │ │ -

Definition at line 228 of file patchParam.h.

│ │ │ │ +

Definition at line 228 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsTriangleRotated()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -537,15 +537,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns if a triangular patch is parametrically rotated 180 degrees.

│ │ │ │ │ │ │ │ -

Definition at line 290 of file patchParam.h.

│ │ │ │ +

Definition at line 290 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ NonQuadRoot()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -566,15 +566,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

True if the parent base face is a non-quad.

│ │ │ │ │ │ │ │ -

Definition at line 194 of file patchParam.h.

│ │ │ │ +

Definition at line 194 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Normalize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -615,15 +615,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
uu parameter
vv parameter
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 271 of file patchParam.h.

│ │ │ │ +

Definition at line 271 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ NormalizeTriangle()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -655,15 +655,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 297 of file patchParam.h.

│ │ │ │ +

Definition at line 297 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Set()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -744,15 +744,15 @@ │ │ │ │ boundary5-bits identifying boundary edges (and verts for tris) │ │ │ │ transition4-bits identifying transition edges │ │ │ │ regularwhether the patch is regular │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 249 of file patchParam.h.

│ │ │ │ +

Definition at line 249 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Unnormalize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -793,15 +793,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
uu parameter
vv parameter
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 281 of file patchParam.h.

│ │ │ │ +

Definition at line 281 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UnnormalizeTriangle()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -833,15 +833,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 312 of file patchParam.h.

│ │ │ │ +

Definition at line 312 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ field0

│ │ │ │ │ │ │ │ @@ -850,15 +850,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int field0
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 230 of file patchParam.h.

│ │ │ │ +

Definition at line 230 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ field1

│ │ │ │ │ │ │ │
│ │ │ │ @@ -866,20 +866,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int field1
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 231 of file patchParam.h.

│ │ │ │ +

Definition at line 231 of file patchParam.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Container for arrays of parametric patches. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchTable.h>

│ │ │ │ +

#include <patchTable.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  PatchHandle
 Handle that can be used as unique patch identifier within PatchTable. More...
 
│ │ │ │ @@ -420,15 +420,15 @@ │ │ │ │
│ │ │ │

Detailed Description

│ │ │ │

Container for arrays of parametric patches.

│ │ │ │

PatchTable contains topology and parametric information about the patches generated by the Refinement process. Patches in the table are sorted into arrays based on their PatchDescriptor Type.

│ │ │ │

Note : PatchTable can be accessed either using a PatchHandle or a combination of array and patch indices.

│ │ │ │

XXXX manuelk we should add a PatchIterator that can dereference into a PatchHandle for fast linear traversal of the table

│ │ │ │ │ │ │ │ -

Definition at line 55 of file patchTable.h.

│ │ │ │ +

Definition at line 55 of file patchTable.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ ConstQuadOffsetsArray

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -436,15 +436,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
typedef Vtr::ConstArray<unsigned int> ConstQuadOffsetsArray
│ │ │ │
│ │ │ │ │ │ │ │

Accessors for the gregory patch evaluation buffers. These methods will be deprecated.

│ │ │ │ │ │ │ │ -

Definition at line 259 of file patchTable.h.

│ │ │ │ +

Definition at line 259 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ PatchVertsTable

│ │ │ │ │ │ │ │
│ │ │ │ @@ -452,15 +452,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef std::vector<Index> PatchVertsTable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 375 of file patchTable.h.

│ │ │ │ +

Definition at line 375 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ QuadOffsetsTable

│ │ │ │ │ │ │ │
│ │ │ │ @@ -468,15 +468,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef std::vector<unsigned int> QuadOffsetsTable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 389 of file patchTable.h.

│ │ │ │ +

Definition at line 389 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ VertexValenceTable

│ │ │ │ │ │ │ │
│ │ │ │ @@ -484,15 +484,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef std::vector<Index> VertexValenceTable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 264 of file patchTable.h.

│ │ │ │ +

Definition at line 264 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ PatchTable() [1/2]

│ │ │ │ │ │ │ │ @@ -601,15 +601,15 @@ │ │ │ │ srcBuffer with primvar data for the base and refined vertex values │ │ │ │ dstDestination buffer for the computed local point vertex values │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

For more flexibility computing local vertex points, retrieval of the local point stencil table and use of its public methods is recommended or often required.

│ │ │ │ │ │ │ │ -

Definition at line 826 of file patchTable.h.

│ │ │ │ +

Definition at line 826 of file patchTable.h.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

◆ ComputeLocalPointValuesFaceVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -658,15 +658,15 @@ │ │ │ │ dstDestination buffer for the computed local point face-varying values │ │ │ │ channelface-varying channel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

For more flexibility computing local face-varying points, retrieval of the local point face-varying stencil table and use of its public methods is recommended or often required.

│ │ │ │ │ │ │ │ -

Definition at line 844 of file patchTable.h.

│ │ │ │ +

Definition at line 844 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ ComputeLocalPointValuesVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -708,15 +708,15 @@ │ │ │ │ srcBuffer with primvar data for the base and refined varying values │ │ │ │ dstDestination buffer for the computed local point varying values │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

For more flexibility computing local varying points, retrieval of the local point varying stencil table and use of its public methods is recommended or often required.

│ │ │ │ │ │ │ │ -

Definition at line 835 of file patchTable.h.

│ │ │ │ +

Definition at line 835 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasis() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -790,15 +790,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An overloaded version to assist template parameter resolution when explicitly declaring unused array arguments as 0.

│ │ │ │ │ │ │ │ -

Definition at line 865 of file patchTable.h.

│ │ │ │ +

Definition at line 865 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasis() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -872,15 +872,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An overloaded version to assist template parameter resolution when explicitly declaring unused array arguments as 0.

│ │ │ │ │ │ │ │ -

Definition at line 858 of file patchTable.h.

│ │ │ │ +

Definition at line 858 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasis() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1048,15 +1048,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An overloaded version to assist template parameter resolution when explicitly declaring unused array arguments as 0.

│ │ │ │ │ │ │ │ -

Definition at line 895 of file patchTable.h.

│ │ │ │ +

Definition at line 895 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasisFaceVarying() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1136,15 +1136,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An overloaded version to assist template parameter resolution when explicitly declaring unused array arguments as 0.

│ │ │ │ │ │ │ │ -

Definition at line 888 of file patchTable.h.

│ │ │ │ +

Definition at line 888 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasisFaceVarying() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1313,15 +1313,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An overloaded version to assist template parameter resolution when explicitly declaring unused array arguments as 0.

│ │ │ │ │ │ │ │ -

Definition at line 880 of file patchTable.h.

│ │ │ │ +

Definition at line 880 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasisVarying() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1395,15 +1395,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An overloaded version to assist template parameter resolution when explicitly declaring unused array arguments as 0.

│ │ │ │ │ │ │ │ -

Definition at line 873 of file patchTable.h.

│ │ │ │ +

Definition at line 873 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvaluateBasisVarying() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1654,15 +1654,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 812 of file patchTable.h.

│ │ │ │ +

Definition at line 812 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLocalPointFaceVaryingStencilTable() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1684,15 +1684,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the stencil table to compute local point face-varying values.

│ │ │ │ │ │ │ │ -

Definition at line 789 of file patchTable.h.

│ │ │ │ +

Definition at line 789 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLocalPointFaceVaryingStencilTable() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1735,15 +1735,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the stencil table to compute local point vertex values.

│ │ │ │ │ │ │ │ -

Definition at line 778 of file patchTable.h.

│ │ │ │ +

Definition at line 778 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLocalPointStencilTable() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1785,15 +1785,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 800 of file patchTable.h.

│ │ │ │ +

Definition at line 800 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLocalPointVaryingStencilTable() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1814,15 +1814,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the stencil table to compute local point varying values.

│ │ │ │ │ │ │ │ -

Definition at line 783 of file patchTable.h.

│ │ │ │ +

Definition at line 783 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLocalPointVaryingStencilTable() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1864,15 +1864,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 806 of file patchTable.h.

│ │ │ │ +

Definition at line 806 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetMaxValence()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1893,15 +1893,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns max vertex valence.

│ │ │ │ │ │ │ │ -

Definition at line 92 of file patchTable.h.

│ │ │ │ +

Definition at line 92 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumControlVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1942,15 +1942,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the total number of control vertex indices in the table.

│ │ │ │ │ │ │ │ -

Definition at line 84 of file patchTable.h.

│ │ │ │ +

Definition at line 84 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarChannels()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2106,15 +2106,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the total number of ptex faces in the mesh.

│ │ │ │ │ │ │ │ -

Definition at line 95 of file patchTable.h.

│ │ │ │ +

Definition at line 95 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetPatchArrayDescriptor()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2255,15 +2255,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Get the table of patch control vertices.

│ │ │ │ │ │ │ │ -

Definition at line 378 of file patchTable.h.

│ │ │ │ +

Definition at line 378 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetPatchDescriptor()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2568,15 +2568,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the PatchParamTable (PatchParams order matches patch array sorting)

│ │ │ │ │ │ │ │ -

Definition at line 381 of file patchTable.h.

│ │ │ │ +

Definition at line 381 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetPatchQuadOffsets()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2717,15 +2717,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the quad-offsets table.

│ │ │ │ │ │ │ │ -

Definition at line 392 of file patchTable.h.

│ │ │ │ +

Definition at line 392 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSharpnessIndexTable()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2746,15 +2746,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns a sharpness index table for each patch (if exists)

│ │ │ │ │ │ │ │ -

Definition at line 384 of file patchTable.h.

│ │ │ │ +

Definition at line 384 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getSharpnessIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2801,15 +2801,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns sharpness values table.

│ │ │ │ │ │ │ │ -

Definition at line 387 of file patchTable.h.

│ │ │ │ +

Definition at line 387 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getSharpnessValues()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2944,15 +2944,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the 'VertexValences' table (vertex neighborhoods table)

│ │ │ │ │ │ │ │ -

Definition at line 267 of file patchTable.h.

│ │ │ │ +

Definition at line 267 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsFeatureAdaptive()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3013,15 +3013,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 756 of file patchTable.h.

│ │ │ │ +

Definition at line 756 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ LocalPointFaceVaryingStencilPrecisionMatchesType() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3042,15 +3042,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 769 of file patchTable.h.

│ │ │ │ +

Definition at line 769 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ LocalPointStencilPrecisionMatchesType() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3092,15 +3092,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 748 of file patchTable.h.

│ │ │ │ +

Definition at line 748 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ LocalPointStencilPrecisionMatchesType() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3121,15 +3121,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 761 of file patchTable.h.

│ │ │ │ +

Definition at line 761 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ LocalPointVaryingStencilPrecisionMatchesType() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3171,15 +3171,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 752 of file patchTable.h.

│ │ │ │ +

Definition at line 752 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ LocalPointVaryingStencilPrecisionMatchesType() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3200,15 +3200,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 765 of file patchTable.h.

│ │ │ │ +

Definition at line 765 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ print()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3244,20 +3244,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 531 of file patchTable.h.

│ │ │ │ +

Definition at line 531 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Handle that can be used as unique patch identifier within PatchTable. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchTable.h>

│ │ │ │ +

#include <patchTable.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -119,15 +119,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Attributes

Index arrayIndex
 
Index patchIndex
 
 
class PatchMap
 
│ │ │ │

Detailed Description

│ │ │ │

Handle that can be used as unique patch identifier within PatchTable.

│ │ │ │ │ │ │ │ -

Definition at line 60 of file patchTable.h.

│ │ │ │ +

Definition at line 60 of file patchTable.h.

│ │ │ │

Friends And Related Symbol Documentation

│ │ │ │ │ │ │ │

◆ PatchMap

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -141,15 +141,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ friend
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 65 of file patchTable.h.

│ │ │ │ +

Definition at line 65 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ PatchTable

│ │ │ │ │ │ │ │
│ │ │ │ @@ -165,15 +165,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 64 of file patchTable.h.

│ │ │ │ +

Definition at line 64 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ arrayIndex

│ │ │ │ │ │ │ │ @@ -182,15 +182,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index arrayIndex
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 67 of file patchTable.h.

│ │ │ │ +

Definition at line 67 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ patchIndex

│ │ │ │ │ │ │ │
│ │ │ │ @@ -198,15 +198,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index patchIndex
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 68 of file patchTable.h.

│ │ │ │ +

Definition at line 68 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ vertIndex

│ │ │ │ │ │ │ │
│ │ │ │ @@ -214,20 +214,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index vertIndex
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 69 of file patchTable.h.

│ │ │ │ +

Definition at line 69 of file patchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Factory for constructing a PatchTable from a TopologyRefiner. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchTableFactory.h>

│ │ │ │ +

#include <patchTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -124,29 +124,29 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  Options
 Public options for the PatchTable factory. More...
 
struct  PatchFaceTag
static PatchTableCreate (TopologyRefiner const &refiner, Options options=Options(), ConstIndexArray selectedFaces=ConstIndexArray())
 Instantiates a PatchTable from a client-provided TopologyRefiner.
 
│ │ │ │

Detailed Description

│ │ │ │

Factory for constructing a PatchTable from a TopologyRefiner.

│ │ │ │ │ │ │ │ -

Definition at line 40 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 40 of file patchTableFactory.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ PatchTagVector

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef std::vector<PatchFaceTag> PatchTagVector
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 208 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 208 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ Create()

│ │ │ │ │ │ │ │ @@ -200,15 +200,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
Returns
A new instance of PatchTable
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Public options for the PatchTable factory. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchTableFactory.h>

│ │ │ │ +

#include <patchTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

enum  EndCapType {
│ │ │ │   ENDCAP_NONE = 0 │ │ │ │ ,
│ │ │ │   ENDCAP_BILINEAR_BASIS │ │ │ │ @@ -208,15 +208,15 @@ │ │ │ │
int const * fvarChannelIndices
 List containing the indices of the channels selected for the factory.
 
│ │ │ │

Detailed Description

│ │ │ │

Public options for the PatchTable factory.

│ │ │ │ │ │ │ │ -

Definition at line 45 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 45 of file patchTableFactory.h.

│ │ │ │

Member Enumeration Documentation

│ │ │ │ │ │ │ │

◆ EndCapType

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -237,15 +237,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
ENDCAP_GREGORY_BASIS 

use Gregory patches (highest quality, recommended default)

│ │ │ │
ENDCAP_LEGACY_GREGORY 

legacy option for 2.x style Gregory patches (Catmark only)

│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 55 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 55 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Options()

│ │ │ │ │ │ │ │ @@ -266,15 +266,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 63 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 63 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetEndCapType()

│ │ │ │ │ │ │ │ @@ -296,15 +296,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Get endcap basis type.

│ │ │ │ │ │ │ │ -

Definition at line 85 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 85 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetRefineAdaptiveOptions()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -325,15 +325,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Determine adaptive refinement options to match assigned patch options.

│ │ │ │ │ │ │ │ -

Definition at line 100 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 100 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetEndCapType()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -355,15 +355,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Set endcap basis type.

│ │ │ │ │ │ │ │ -

Definition at line 88 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 88 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetFVarPatchPrecision() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -403,15 +403,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 215 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 215 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetMaxIsolationLevel()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -433,15 +433,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Set maximum isolation level.

│ │ │ │ │ │ │ │ -

Definition at line 91 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 91 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetPatchPrecision() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -481,15 +481,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 212 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 212 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ endCapType

│ │ │ │ │ │ │ │ @@ -500,15 +500,15 @@ │ │ │ │ unsigned int endCapType │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

EndCapType.

│ │ │ │ │ │ │ │ -

Definition at line 120 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 120 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ fvarChannelIndices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -518,15 +518,15 @@ │ │ │ │ int const* fvarChannelIndices │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

List containing the indices of the channels selected for the factory.

│ │ │ │ │ │ │ │ -

Definition at line 140 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 140 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ fvarPatchPrecisionDouble

│ │ │ │ │ │ │ │
│ │ │ │ @@ -536,15 +536,15 @@ │ │ │ │ unsigned int fvarPatchPrecisionDouble │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate double-precision stencils for face-varying patches.

│ │ │ │ │ │ │ │ -

Definition at line 133 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 133 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateAllLevels

│ │ │ │ │ │ │ │
│ │ │ │ @@ -554,15 +554,15 @@ │ │ │ │ unsigned int generateAllLevels │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate levels from 'firstLevel' to 'maxLevel' (Uniform mode only)

│ │ │ │ │ │ │ │ -

Definition at line 110 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 110 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateFVarLegacyLinearPatches

│ │ │ │ │ │ │ │
│ │ │ │ @@ -572,15 +572,15 @@ │ │ │ │ unsigned int generateFVarLegacyLinearPatches │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate all linear face-varying patches (legacy)

│ │ │ │ │ │ │ │ -

Definition at line 136 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 136 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateFVarTables

│ │ │ │ │ │ │ │
│ │ │ │ @@ -590,15 +590,15 @@ │ │ │ │ unsigned int generateFVarTables │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate face-varying patch tables.

│ │ │ │ │ │ │ │ -

Definition at line 129 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 129 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateLegacySharpCornerPatches

│ │ │ │ │ │ │ │
│ │ │ │ @@ -608,15 +608,15 @@ │ │ │ │ unsigned int generateLegacySharpCornerPatches │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate sharp regular patches at smooth corners (legacy)

│ │ │ │ │ │ │ │ -

Definition at line 137 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 137 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateVaryingLocalPoints

│ │ │ │ │ │ │ │
│ │ │ │ @@ -626,15 +626,15 @@ │ │ │ │ unsigned int generateVaryingLocalPoints │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate local points with varying patches.

│ │ │ │ │ │ │ │ -

Definition at line 126 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 126 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateVaryingTables

│ │ │ │ │ │ │ │
│ │ │ │ @@ -644,15 +644,15 @@ │ │ │ │ unsigned int generateVaryingTables │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate varying patch tables.

│ │ │ │ │ │ │ │ -

Definition at line 125 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 125 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ includeBaseLevelIndices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -662,15 +662,15 @@ │ │ │ │ unsigned int includeBaseLevelIndices │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Include base level in patch point indices (Uniform mode only)

│ │ │ │ │ │ │ │ -

Definition at line 111 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 111 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ includeFVarBaseLevelIndices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -680,15 +680,15 @@ │ │ │ │ unsigned int includeFVarBaseLevelIndices │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Include base level in face-varying patch point indices (Uniform mode only)

│ │ │ │ │ │ │ │ -

Definition at line 112 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 112 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ maxIsolationLevel

│ │ │ │ │ │ │ │
│ │ │ │ @@ -698,15 +698,15 @@ │ │ │ │ unsigned int maxIsolationLevel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Cap adaptive feature isolation to the given level (max. 10)

│ │ │ │ │ │ │ │ -

Definition at line 117 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 117 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numFVarChannels

│ │ │ │ │ │ │ │
│ │ │ │ @@ -716,15 +716,15 @@ │ │ │ │ int numFVarChannels │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Number of channel indices and interpolation modes passed.

│ │ │ │ │ │ │ │ -

Definition at line 139 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 139 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ patchPrecisionDouble

│ │ │ │ │ │ │ │
│ │ │ │ @@ -734,15 +734,15 @@ │ │ │ │ unsigned int patchPrecisionDouble │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate double-precision stencils for vertex patches.

│ │ │ │ │ │ │ │ -

Definition at line 132 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 132 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ shareEndCapPatchPoints

│ │ │ │ │ │ │ │
│ │ │ │ @@ -751,15 +751,15 @@ │ │ │ │ │ │ │ │ unsigned int shareEndCapPatchPoints │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Share endcap patch points among adjacent endcap patches. currently only work with GregoryBasis.

│ │ │ │ │ │ │ │ -

Definition at line 121 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 121 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ triangulateQuads

│ │ │ │ │ │ │ │
│ │ │ │ @@ -769,15 +769,15 @@ │ │ │ │ unsigned int triangulateQuads │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Triangulate 'QUADS' primitives (Uniform mode only)

│ │ │ │ │ │ │ │ -

Definition at line 113 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 113 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ useInfSharpPatch

│ │ │ │ │ │ │ │
│ │ │ │ @@ -787,15 +787,15 @@ │ │ │ │ unsigned int useInfSharpPatch │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Use infinitely-sharp patch.

│ │ │ │ │ │ │ │ -

Definition at line 116 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 116 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ useSingleCreasePatch

│ │ │ │ │ │ │ │
│ │ │ │ @@ -805,20 +805,20 @@ │ │ │ │ unsigned int useSingleCreasePatch │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Use single crease patch.

│ │ │ │ │ │ │ │ -

Definition at line 115 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 115 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Obsolete internal struct not intended for public use – due to be deprecated. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <patchTableFactory.h>

│ │ │ │ +

#include <patchTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -133,15 +133,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

void clear ()
 
void assignBoundaryPropertiesFromEdgeMask (int boundaryEdgeMask)
 
 
unsigned int _isSingleCrease: 1
 
│ │ │ │

Detailed Description

│ │ │ │

Obsolete internal struct not intended for public use – due to be deprecated.

│ │ │ │ │ │ │ │ -

Definition at line 192 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 192 of file patchTableFactory.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ assignBoundaryPropertiesFromEdgeMask()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -219,15 +219,15 @@ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _boundaryCount
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 199 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 199 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ _boundaryIndex

│ │ │ │ │ │ │ │
│ │ │ │ @@ -235,15 +235,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _boundaryIndex
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 198 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 198 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ _boundaryMask

│ │ │ │ │ │ │ │
│ │ │ │ @@ -251,15 +251,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _boundaryMask
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 197 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 197 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _hasBoundaryEdge

│ │ │ │ │ │ │ │
│ │ │ │ @@ -267,15 +267,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _hasBoundaryEdge
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 200 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 200 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _hasPatch

│ │ │ │ │ │ │ │
│ │ │ │ @@ -283,15 +283,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _hasPatch
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 194 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 194 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _isRegular

│ │ │ │ │ │ │ │
│ │ │ │ @@ -299,15 +299,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _isRegular
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 195 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 195 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _isSingleCrease

│ │ │ │ │ │ │ │
│ │ │ │ @@ -315,15 +315,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _isSingleCrease
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 201 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 201 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _transitionMask

│ │ │ │ │ │ │ │
│ │ │ │ @@ -331,20 +331,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
unsigned int _transitionMask
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 196 of file patchTableFactory.h.

│ │ │ │ +

Definition at line 196 of file patchTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Applies refinement operations to generic primvar data. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <primvarRefiner.h>

│ │ │ │ +

#include <primvarRefiner.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -159,15 +159,15 @@ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 PrimvarRefinerReal (TopologyRefiner const &refiner)
 
 ~PrimvarRefinerReal ()
 
void LimitFaceVarying (T const &src, U &dst, int channel=0) const
 
│ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::PrimvarRefinerReal< REAL >

Applies refinement operations to generic primvar data.

│ │ │ │ │ │ │ │ -

Definition at line 56 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 56 of file primvarRefiner.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ PrimvarRefinerReal()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -187,15 +187,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 59 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 59 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ ~PrimvarRefinerReal()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -216,15 +216,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 60 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 60 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetTopologyRefiner()

│ │ │ │ │ │ │ │ @@ -246,15 +246,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 62 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 62 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Interpolate()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -305,15 +305,15 @@ │ │ │ │ levelThe refinement level │ │ │ │ srcSource primvar buffer (templating control vertex data) │ │ │ │ dstDestination primvar buffer (templating refined vertex data) │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 267 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 267 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ InterpolateFaceUniform()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -365,15 +365,15 @@ │ │ │ │ levelThe refinement level │ │ │ │ srcSource primvar buffer │ │ │ │ dstDestination primvar buffer │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 394 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 394 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ InterpolateFaceVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -423,15 +423,15 @@ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Apply face-varying interpolation weights to a primvar buffer associated with a particular face-varying channel.

│ │ │ │

Unlike vertex and varying primvar buffers, there is not a 1-to-1 correspondence between vertices and face-varying values – typically there are more face-varying values than vertices. Each face-varying channel is also independent in how its values relate to the vertices.

│ │ │ │

The destination buffer must allocate an array of data for all the refined values, i.e. at least refiner.GetLevel(level).GetNumFVarValues(channel).

│ │ │ │ │ │ │ │ -

Definition at line 293 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 293 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ InterpolateVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -483,15 +483,15 @@ │ │ │ │ levelThe refinement level │ │ │ │ srcSource primvar buffer (templating control vertex data) │ │ │ │ dstDestination primvar buffer (templating refined vertex data) │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 412 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 412 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Limit() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -535,15 +535,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
srcSource primvar buffer (refined data) for last level
dstPosDestination primvar buffer (data at the limit)
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 319 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 319 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Limit() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -589,15 +589,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 344 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 344 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ LimitFaceVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -637,20 +637,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 369 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 369 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <primvarRefiner.h>

│ │ │ │ +

#include <primvarRefiner.h>

│ │ │ │
│ │ │ │ Inheritance diagram for PrimvarRefiner:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ PrimvarRefinerReal< float > │ │ │ │ @@ -138,15 +138,15 @@ │ │ │ │ void Limit (T const &src, U &dstPos, U1 &dstTan1, U2 &dstTan2) const │ │ │ │   │ │ │ │ void LimitFaceVarying (T const &src, U &dst, int channel=0) const │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 1265 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 1265 of file primvarRefiner.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ PrimvarRefiner()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -164,20 +164,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 1267 of file primvarRefiner.h.

│ │ │ │ +

Definition at line 1267 of file primvarRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Object used to compute and query ptex face indices. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <ptexIndices.h>

│ │ │ │ +

#include <ptexIndices.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -121,15 +121,15 @@ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 PtexIndices (TopologyRefiner const &refiner)
 Constructor.
 
 ~PtexIndices ()
 Returns ptex face adjacency information for a given coarse face.
 
│ │ │ │

Detailed Description

│ │ │ │

Object used to compute and query ptex face indices.

│ │ │ │

Given a refiner, constructing a PtexIndices object builds the mapping from coarse faces to ptex ids. Once built, the object can be used to query the mapping.

│ │ │ │ │ │ │ │ -

Definition at line 46 of file ptexIndices.h.

│ │ │ │ +

Definition at line 46 of file ptexIndices.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ PtexIndices()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -262,15 +262,15 @@ │ │ │ │ │ │ │ │

Returns the number of ptex faces in the mesh.

│ │ │ │

Ptex

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

A specialized factory for StencilTable. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  Options
 
│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -140,15 +140,15 @@ │ │ │ │

 Utility function for stencil splicing for local point face-varying stencils.
 
│ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::StencilTableFactoryReal< REAL >

A specialized factory for StencilTable.

│ │ │ │ │ │ │ │ -

Definition at line 51 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 51 of file stencilTableFactory.h.

│ │ │ │

Member Enumeration Documentation

│ │ │ │ │ │ │ │

◆ Mode

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -164,15 +164,15 @@ │ │ │ │ │ │ │ │ INTERPOLATE_VARYING 

varying primvar stencils

│ │ │ │ │ │ │ │ INTERPOLATE_FACE_VARYING 

face-varying primvar stencils

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 55 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 55 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ AppendLocalPointStencilTable()

│ │ │ │ │ │ │ │ @@ -357,15 +357,15 @@ │ │ │ │ baseStencilTableInput StencilTable for refined vertices │ │ │ │ localPointStencilTableStencilTable for the change of basis patch points. │ │ │ │ factorizeIf factorize is set to true, endcap stencils will be factorized with supporting vertices from baseStencil table so that the endcap points can be computed directly from control vertices. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 148 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 148 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -458,16 +458,16 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following files: │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

A specialized factory for LimitStencilTable. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -135,15 +135,15 @@ │ │ │ │

│ │ │ │ Classes

struct  LocationArray
 Descriptor for limit surface locations. More...
 
struct  Options
│ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::LimitStencilTableFactoryReal< REAL >

A specialized factory for LimitStencilTable.

│ │ │ │

The LimitStencilTableFactory creates a table of limit stencils. Limit stencils can interpolate any arbitrary location on the limit surface. The stencils will be bilinear if the surface is refined uniformly, and bicubic if feature adaptive isolation is used instead.

│ │ │ │

Surface locations are expressed as a combination of ptex face index and normalized (s,t) patch coordinates. The factory exposes the LocationArray struct as a container for these location descriptors.

│ │ │ │ │ │ │ │ -

Definition at line 209 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 209 of file stencilTableFactory.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ LocationArrayVec

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -151,15 +151,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef std::vector<LocationArray> LocationArrayVec
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 244 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 244 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Enumeration Documentation

│ │ │ │ │ │ │ │

◆ Mode

│ │ │ │ │ │ │ │ @@ -178,15 +178,15 @@ │ │ │ │ │ │ │ │ INTERPOLATE_VARYING 

varying primvar stencils

│ │ │ │ │ │ │ │ INTERPOLATE_FACE_VARYING 

face-varying primvar stencils

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 213 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 213 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ Create()

│ │ │ │ │ │ │ │ @@ -252,16 +252,16 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
The documentation for this class was generated from the following files: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Vertex stencil descriptor. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for StencilReal< REAL >:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ LimitStencilReal< float > │ │ │ │ @@ -160,15 +160,15 @@ │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::StencilReal< REAL >

Vertex stencil descriptor.

│ │ │ │

Allows access and manipulation of a single stencil in a StencilTable.

│ │ │ │ │ │ │ │ -

Definition at line 53 of file stencilTable.h.

│ │ │ │ +

Definition at line 53 of file stencilTable.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ StencilReal() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -189,15 +189,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Default constructor.

│ │ │ │ │ │ │ │ -

Definition at line 57 of file stencilTable.h.

│ │ │ │ +

Definition at line 57 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ StencilReal() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -245,15 +245,15 @@ │ │ │ │ sizeTable pointer to the size of the stencil │ │ │ │ indicesTable pointer to the vertex indices of the stencil │ │ │ │ weightsTable pointer to the vertex weights of the stencil │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 67 of file stencilTable.h.

│ │ │ │ +

Definition at line 67 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ StencilReal() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -277,15 +277,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Copy constructor.

│ │ │ │ │ │ │ │ -

Definition at line 71 of file stencilTable.h.

│ │ │ │ +

Definition at line 71 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetSize()

│ │ │ │ │ │ │ │ @@ -309,15 +309,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the size of the stencil.

│ │ │ │ │ │ │ │ -

Definition at line 78 of file stencilTable.h.

│ │ │ │ +

Definition at line 78 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetSizePtr()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -340,15 +340,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the size of the stencil as a pointer.

│ │ │ │ │ │ │ │ -

Definition at line 83 of file stencilTable.h.

│ │ │ │ +

Definition at line 83 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -371,15 +371,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the control vertices' indices.

│ │ │ │ │ │ │ │ -

Definition at line 88 of file stencilTable.h.

│ │ │ │ +

Definition at line 88 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -402,15 +402,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 93 of file stencilTable.h.

│ │ │ │ +

Definition at line 93 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Next()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -433,15 +433,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Advance to the next stencil in the table.

│ │ │ │ │ │ │ │ -

Definition at line 98 of file stencilTable.h.

│ │ │ │ +

Definition at line 98 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Friends And Related Symbol Documentation

│ │ │ │ │ │ │ │

◆ LimitStencilTableFactoryReal< REAL >

│ │ │ │ │ │ │ │ @@ -460,15 +460,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 98 of file stencilTable.h.

│ │ │ │ +

Definition at line 98 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ StencilTableFactoryReal< REAL >

│ │ │ │ │ │ │ │
│ │ │ │ @@ -486,15 +486,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 98 of file stencilTable.h.

│ │ │ │ +

Definition at line 98 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ _indices

│ │ │ │ │ │ │ │ @@ -513,15 +513,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 110 of file stencilTable.h.

│ │ │ │ +

Definition at line 110 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _size

│ │ │ │ │ │ │ │
│ │ │ │ @@ -539,15 +539,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 109 of file stencilTable.h.

│ │ │ │ +

Definition at line 109 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _weights

│ │ │ │ │ │ │ │
│ │ │ │ @@ -565,20 +565,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 111 of file stencilTable.h.

│ │ │ │ +

Definition at line 111 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Vertex stencil class wrapping the template for compatibility. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for Stencil:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ StencilReal< float > │ │ │ │ @@ -161,15 +161,15 @@ │ │ │ │   │ │ │ │ float * _weights │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Vertex stencil class wrapping the template for compatibility.

│ │ │ │ │ │ │ │ -

Definition at line 116 of file stencilTable.h.

│ │ │ │ +

Definition at line 116 of file stencilTable.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ BaseStencil

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -183,15 +183,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ protected
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 118 of file stencilTable.h.

│ │ │ │ +

Definition at line 118 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Stencil() [1/3]

│ │ │ │ │ │ │ │ @@ -211,15 +211,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 121 of file stencilTable.h.

│ │ │ │ +

Definition at line 121 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Stencil() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -239,15 +239,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 122 of file stencilTable.h.

│ │ │ │ +

Definition at line 122 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Stencil() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -283,20 +283,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 123 of file stencilTable.h.

│ │ │ │ +

Definition at line 123 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Table of subdivision stencils. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for StencilTableReal< REAL >:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ LimitStencilTableReal< float > │ │ │ │ @@ -209,15 +209,15 @@ │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::StencilTableReal< REAL >

Table of subdivision stencils.

│ │ │ │

Stencils are the most direct method of evaluation of locations on the limit of a surface. Every point of a limit surface can be computed by linearly blending a collection of coarse control vertices.

│ │ │ │

A stencil assigns a series of control vertex indices with a blending weight that corresponds to a unique parametric location of the limit surface. When the control vertices move in space, the limit location can be very efficiently recomputed simply by applying the blending weights to the series of coarse control vertices.

│ │ │ │ │ │ │ │ -

Definition at line 141 of file stencilTable.h.

│ │ │ │ +

Definition at line 141 of file stencilTable.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ StencilTableReal() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -304,15 +304,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinevirtual │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 153 of file stencilTable.h.

│ │ │ │ +

Definition at line 153 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ StencilTableReal() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -333,15 +333,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 255 of file stencilTable.h.

│ │ │ │ +

Definition at line 255 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ StencilTableReal() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -363,15 +363,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 256 of file stencilTable.h.

│ │ │ │ +

Definition at line 256 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ Clear()

│ │ │ │ │ │ │ │ @@ -414,15 +414,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 714 of file stencilTable.h.

│ │ │ │ +

Definition at line 714 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ generateOffsets()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -443,15 +443,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 678 of file stencilTable.h.

│ │ │ │ +

Definition at line 678 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetControlIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -474,15 +474,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the indices of the control vertices.

│ │ │ │ │ │ │ │ -

Definition at line 179 of file stencilTable.h.

│ │ │ │ +

Definition at line 179 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumControlVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -505,15 +505,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of control vertices indexed in the table.

│ │ │ │ │ │ │ │ -

Definition at line 161 of file stencilTable.h.

│ │ │ │ +

Definition at line 161 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumStencils()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -536,15 +536,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of stencils in the table.

│ │ │ │ │ │ │ │ -

Definition at line 156 of file stencilTable.h.

│ │ │ │ +

Definition at line 156 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetOffsets()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -567,15 +567,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the offset to a given stencil (factory may leave empty)

│ │ │ │ │ │ │ │ -

Definition at line 174 of file stencilTable.h.

│ │ │ │ +

Definition at line 174 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSizes()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -598,15 +598,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of control vertices of each stencil in the table.

│ │ │ │ │ │ │ │ -

Definition at line 169 of file stencilTable.h.

│ │ │ │ +

Definition at line 169 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetStencil()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -630,15 +630,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns a Stencil at index i in the table.

│ │ │ │ │ │ │ │ -

Definition at line 722 of file stencilTable.h.

│ │ │ │ +

Definition at line 722 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -661,15 +661,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the stencil interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 184 of file stencilTable.h.

│ │ │ │ +

Definition at line 184 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator[]()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -693,15 +693,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the stencil at index i in the table.

│ │ │ │ │ │ │ │ -

Definition at line 734 of file stencilTable.h.

│ │ │ │ +

Definition at line 734 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ reserve()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -733,15 +733,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 698 of file stencilTable.h.

│ │ │ │ +

Definition at line 698 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ resize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -773,15 +773,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 690 of file stencilTable.h.

│ │ │ │ +

Definition at line 690 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ shrinkToFit()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -802,15 +802,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 706 of file stencilTable.h.

│ │ │ │ +

Definition at line 706 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ update() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -862,15 +862,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 650 of file stencilTable.h.

│ │ │ │ +

Definition at line 650 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ update() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -934,15 +934,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 618 of file stencilTable.h.

│ │ │ │ +

Definition at line 618 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateValues() [1/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1000,15 +1000,15 @@ │ │ │ │ dstValuesDestination buffer for the interpolated primvar data │ │ │ │ startIndex of first destination value to update │ │ │ │ endIndex of last destination value to update │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 205 of file stencilTable.h.

│ │ │ │ +

Definition at line 205 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateValues() [2/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1054,15 +1054,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 217 of file stencilTable.h.

│ │ │ │ +

Definition at line 217 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateValues() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1120,15 +1120,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 210 of file stencilTable.h.

│ │ │ │ +

Definition at line 210 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateValues() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1186,15 +1186,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 221 of file stencilTable.h.

│ │ │ │ +

Definition at line 221 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Friends And Related Symbol Documentation

│ │ │ │ │ │ │ │

◆ Far::PatchTableBuilder

│ │ │ │ │ │ │ │ @@ -1213,15 +1213,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 261 of file stencilTable.h.

│ │ │ │ +

Definition at line 261 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ StencilTableFactoryReal< REAL >

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1239,15 +1239,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 256 of file stencilTable.h.

│ │ │ │ +

Definition at line 256 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ _indices

│ │ │ │ │ │ │ │ @@ -1266,15 +1266,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 267 of file stencilTable.h.

│ │ │ │ +

Definition at line 267 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _numControlVertices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1292,15 +1292,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 263 of file stencilTable.h.

│ │ │ │ +

Definition at line 263 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _offsets

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1318,15 +1318,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 266 of file stencilTable.h.

│ │ │ │ +

Definition at line 266 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _sizes

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1344,15 +1344,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 265 of file stencilTable.h.

│ │ │ │ +

Definition at line 265 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _weights

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1370,20 +1370,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 268 of file stencilTable.h.

│ │ │ │ +

Definition at line 268 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Stencil table class wrapping the template for compatibility. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for StencilTable:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ StencilTableReal< float > │ │ │ │ @@ -208,15 +208,15 @@ │ │ │ │   │ │ │ │ std::vector< float > _weights │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Stencil table class wrapping the template for compatibility.

│ │ │ │ │ │ │ │ -

Definition at line 273 of file stencilTable.h.

│ │ │ │ +

Definition at line 273 of file stencilTable.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ BaseTable

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -230,15 +230,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ protected
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 275 of file stencilTable.h.

│ │ │ │ +

Definition at line 275 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ StencilTable() [1/3]

│ │ │ │ │ │ │ │ @@ -258,15 +258,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 286 of file stencilTable.h.

│ │ │ │ +

Definition at line 286 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ StencilTable() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -286,15 +286,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 287 of file stencilTable.h.

│ │ │ │ +

Definition at line 287 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ StencilTable() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -354,15 +354,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 288 of file stencilTable.h.

│ │ │ │ +

Definition at line 288 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetStencil()

│ │ │ │ │ │ │ │ @@ -383,15 +383,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 278 of file stencilTable.h.

│ │ │ │ +

Definition at line 278 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator[]()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -411,20 +411,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 281 of file stencilTable.h.

│ │ │ │ +

Definition at line 281 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Limit point stencil descriptor. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for LimitStencilReal< REAL >:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ StencilReal< REAL > │ │ │ │ @@ -179,15 +179,15 @@ │ │ │ │ REAL * _weights │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::LimitStencilReal< REAL >

Limit point stencil descriptor.

│ │ │ │ │ │ │ │ -

Definition at line 303 of file stencilTable.h.

│ │ │ │ +

Definition at line 303 of file stencilTable.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ LimitStencilReal()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -268,15 +268,15 @@ │ │ │ │ duuWeightsTable pointer to the 'uu' derivative weights │ │ │ │ duvWeightsTable pointer to the 'uv' derivative weights │ │ │ │ dvvWeightsTable pointer to the 'vv' derivative weights │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 324 of file stencilTable.h.

│ │ │ │ +

Definition at line 324 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetDuuWeights()

│ │ │ │ │ │ │ │ @@ -300,15 +300,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the uu derivative weights.

│ │ │ │ │ │ │ │ -

Definition at line 351 of file stencilTable.h.

│ │ │ │ +

Definition at line 351 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDuvWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -331,15 +331,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the uv derivative weights.

│ │ │ │ │ │ │ │ -

Definition at line 356 of file stencilTable.h.

│ │ │ │ +

Definition at line 356 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDuWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -362,15 +362,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the u derivative weights.

│ │ │ │ │ │ │ │ -

Definition at line 341 of file stencilTable.h.

│ │ │ │ +

Definition at line 341 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDvvWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -393,15 +393,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the vv derivative weights.

│ │ │ │ │ │ │ │ -

Definition at line 361 of file stencilTable.h.

│ │ │ │ +

Definition at line 361 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDvWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -424,15 +424,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the v derivative weights.

│ │ │ │ │ │ │ │ -

Definition at line 346 of file stencilTable.h.

│ │ │ │ +

Definition at line 346 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Next()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -455,15 +455,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Advance to the next stencil in the table.

│ │ │ │ │ │ │ │ -

Definition at line 366 of file stencilTable.h.

│ │ │ │ +

Definition at line 366 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Friends And Related Symbol Documentation

│ │ │ │ │ │ │ │

◆ LimitStencilTableFactoryReal< REAL >

│ │ │ │ │ │ │ │ @@ -482,15 +482,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 366 of file stencilTable.h.

│ │ │ │ +

Definition at line 366 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ StencilTableFactoryReal< REAL >

│ │ │ │ │ │ │ │
│ │ │ │ @@ -508,20 +508,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 366 of file stencilTable.h.

│ │ │ │ +

Definition at line 366 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Limit point stencil class wrapping the template for compatibility. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for LimitStencil:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ LimitStencilReal< float > │ │ │ │ @@ -182,15 +182,15 @@ │ │ │ │   │ │ │ │ REAL * _weights │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Limit point stencil class wrapping the template for compatibility.

│ │ │ │ │ │ │ │ -

Definition at line 392 of file stencilTable.h.

│ │ │ │ +

Definition at line 392 of file stencilTable.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ BaseStencil

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -204,15 +204,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ protected
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 394 of file stencilTable.h.

│ │ │ │ +

Definition at line 394 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ LimitStencil() [1/2]

│ │ │ │ │ │ │ │ @@ -233,15 +233,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 397 of file stencilTable.h.

│ │ │ │ +

Definition at line 397 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ LimitStencil() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -307,20 +307,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 398 of file stencilTable.h.

│ │ │ │ +

Definition at line 398 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Table of limit subdivision stencils. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for LimitStencilTableReal< REAL >:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ StencilTableReal< REAL > │ │ │ │ @@ -257,15 +257,15 @@ │ │ │ │ std::vector< REAL > _weights │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::LimitStencilTableReal< REAL >

Table of limit subdivision stencils.

│ │ │ │ │ │ │ │ -

Definition at line 409 of file stencilTable.h.

│ │ │ │ +

Definition at line 409 of file stencilTable.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ LimitStencilTableReal()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -406,15 +406,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the 'uu' derivative stencil interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 444 of file stencilTable.h.

│ │ │ │ +

Definition at line 444 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDuvWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -437,15 +437,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the 'uv' derivative stencil interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 449 of file stencilTable.h.

│ │ │ │ +

Definition at line 449 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDuWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -468,15 +468,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the 'u' derivative stencil interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 434 of file stencilTable.h.

│ │ │ │ +

Definition at line 434 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDvvWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -499,15 +499,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the 'vv' derivative stencil interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 454 of file stencilTable.h.

│ │ │ │ +

Definition at line 454 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDvWeights()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -530,15 +530,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the 'v' derivative stencil interpolation weights.

│ │ │ │ │ │ │ │ -

Definition at line 439 of file stencilTable.h.

│ │ │ │ +

Definition at line 439 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetLimitStencil()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -562,15 +562,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns a LimitStencil at index i in the table.

│ │ │ │ │ │ │ │ -

Definition at line 749 of file stencilTable.h.

│ │ │ │ +

Definition at line 749 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator[]()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -594,15 +594,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the limit stencil at index i in the table.

│ │ │ │ │ │ │ │ -

Definition at line 782 of file stencilTable.h.

│ │ │ │ +

Definition at line 782 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Update2ndDerivs() [1/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -674,15 +674,15 @@ │ │ │ │ vvderivsDestination buffer for the interpolated 'vv' derivative primvar data │ │ │ │ startIndex of first destination derivative to update │ │ │ │ endIndex of last destination derivative to update │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 528 of file stencilTable.h.

│ │ │ │ +

Definition at line 528 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Update2ndDerivs() [2/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -740,15 +740,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 548 of file stencilTable.h.

│ │ │ │ +

Definition at line 548 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Update2ndDerivs() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -818,15 +818,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 538 of file stencilTable.h.

│ │ │ │ +

Definition at line 538 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Update2ndDerivs() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -896,15 +896,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 556 of file stencilTable.h.

│ │ │ │ +

Definition at line 556 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateDerivs() [1/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -969,15 +969,15 @@ │ │ │ │ vderivsDestination buffer for the interpolated 'v' derivative primvar data │ │ │ │ startIndex of first destination derivative to update │ │ │ │ endIndex of last destination derivative to update │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 476 of file stencilTable.h.

│ │ │ │ +

Definition at line 476 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateDerivs() [2/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1029,15 +1029,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 493 of file stencilTable.h.

│ │ │ │ +

Definition at line 493 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateDerivs() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1101,15 +1101,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 484 of file stencilTable.h.

│ │ │ │ +

Definition at line 484 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateDerivs() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1173,15 +1173,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 500 of file stencilTable.h.

│ │ │ │ +

Definition at line 500 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Friends And Related Symbol Documentation

│ │ │ │ │ │ │ │

◆ LimitStencilTableFactoryReal< REAL >

│ │ │ │ │ │ │ │ @@ -1200,20 +1200,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 565 of file stencilTable.h.

│ │ │ │ +

Definition at line 565 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Limit stencil table class wrapping the template for compatibility. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTable.h>

│ │ │ │ +

#include <stencilTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for LimitStencilTable:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ LimitStencilTableReal< float > │ │ │ │ @@ -257,15 +257,15 @@ │ │ │ │   │ │ │ │ std::vector< REAL > _weights │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Limit stencil table class wrapping the template for compatibility.

│ │ │ │ │ │ │ │ -

Definition at line 583 of file stencilTable.h.

│ │ │ │ +

Definition at line 583 of file stencilTable.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ BaseTable

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -279,15 +279,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ protected
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 585 of file stencilTable.h.

│ │ │ │ +

Definition at line 585 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ LimitStencilTable()

│ │ │ │ │ │ │ │ @@ -378,15 +378,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 596 of file stencilTable.h.

│ │ │ │ +

Definition at line 596 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetLimitStencil()

│ │ │ │ │ │ │ │ @@ -407,15 +407,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 588 of file stencilTable.h.

│ │ │ │ +

Definition at line 588 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator[]()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -435,20 +435,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 591 of file stencilTable.h.

│ │ │ │ +

Definition at line 591 of file stencilTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
StencilTableFactoryReal< REAL >::Options Struct Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 Options ()
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -127,15 +127,15 @@ │ │ │ │

 
unsigned int fvarChannel
 
│ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ struct OpenSubdiv::OPENSUBDIV_VERSION::Far::StencilTableFactoryReal< REAL >::Options
│ │ │ │ -

Definition at line 61 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 61 of file stencilTableFactory.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Options()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -154,15 +154,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 63 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 63 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ factorizeIntermediateLevels

│ │ │ │ │ │ │ │ @@ -174,15 +174,15 @@ │ │ │ │ │ │ │ │ unsigned int factorizeIntermediateLevels │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

accumulate stencil weights from control vertices or from the stencils of the previous level

│ │ │ │ │ │ │ │ -

Definition at line 75 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 75 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ fvarChannel

│ │ │ │ │ │ │ │
│ │ │ │ @@ -193,15 +193,15 @@ │ │ │ │ │ │ │ │ unsigned int fvarChannel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

face-varying channel to use when generating face-varying stencils

│ │ │ │ │ │ │ │ -

Definition at line 79 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 79 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateControlVerts

│ │ │ │ │ │ │ │
│ │ │ │ @@ -213,15 +213,15 @@ │ │ │ │ unsigned int generateControlVerts │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

generate stencils for control-vertices

│ │ │ │ │ │ │ │ -

Definition at line 73 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 73 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateIntermediateLevels

│ │ │ │ │ │ │ │
│ │ │ │ @@ -233,15 +233,15 @@ │ │ │ │ unsigned int generateIntermediateLevels │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

vertices at all levels or highest only

│ │ │ │ │ │ │ │ -

Definition at line 74 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 74 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generateOffsets

│ │ │ │ │ │ │ │
│ │ │ │ @@ -253,15 +253,15 @@ │ │ │ │ unsigned int generateOffsets │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

populate optional "_offsets" field

│ │ │ │ │ │ │ │ -

Definition at line 72 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 72 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ interpolationMode

│ │ │ │ │ │ │ │
│ │ │ │ @@ -273,15 +273,15 @@ │ │ │ │ unsigned int interpolationMode │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

interpolation mode

│ │ │ │ │ │ │ │ -

Definition at line 71 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 71 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ maxLevel

│ │ │ │ │ │ │ │
│ │ │ │ @@ -293,20 +293,20 @@ │ │ │ │ unsigned int maxLevel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

generate stencils up to 'maxLevel'

│ │ │ │ │ │ │ │ -

Definition at line 78 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 78 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
LimitStencilTableFactoryReal< REAL >::Options Struct Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 Options ()
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -120,15 +120,15 @@ │ │ │ │

unsigned int fvarChannel
 face-varying channel to use
 
│ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ struct OpenSubdiv::OPENSUBDIV_VERSION::Far::LimitStencilTableFactoryReal< REAL >::Options
│ │ │ │ -

Definition at line 219 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 219 of file stencilTableFactory.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Options()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -147,15 +147,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 221 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 221 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ fvarChannel

│ │ │ │ │ │ │ │ @@ -168,15 +168,15 @@ │ │ │ │ unsigned int fvarChannel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

face-varying channel to use

│ │ │ │ │ │ │ │ -

Definition at line 229 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 229 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ generate1stDerivatives

│ │ │ │ │ │ │ │
│ │ │ │ @@ -188,15 +188,15 @@ │ │ │ │ unsigned int generate1stDerivatives │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate weights for 1st derivatives.

│ │ │ │ │ │ │ │ -

Definition at line 227 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 227 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ generate2ndDerivatives

│ │ │ │ │ │ │ │
│ │ │ │ @@ -208,15 +208,15 @@ │ │ │ │ unsigned int generate2ndDerivatives │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generate weights for 2nd derivatives.

│ │ │ │ │ │ │ │ -

Definition at line 228 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 228 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ interpolationMode

│ │ │ │ │ │ │ │
│ │ │ │ @@ -228,20 +228,20 @@ │ │ │ │ unsigned int interpolationMode │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

interpolation mode

│ │ │ │ │ │ │ │ -

Definition at line 226 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 226 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Descriptor for limit surface locations. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 LocationArray ()
 
│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -124,15 +124,15 @@ │ │ │ │

 array of v coordinates
 
│ │ │ │

Detailed Description

│ │ │ │
template<typename REAL>
│ │ │ │ struct OpenSubdiv::OPENSUBDIV_VERSION::Far::LimitStencilTableFactoryReal< REAL >::LocationArray

Descriptor for limit surface locations.

│ │ │ │ │ │ │ │ -

Definition at line 233 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 233 of file stencilTableFactory.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ LocationArray()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -151,15 +151,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 235 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 235 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ numLocations

│ │ │ │ │ │ │ │ @@ -172,15 +172,15 @@ │ │ │ │ int numLocations │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

number of (u,v) coordinates in the array

│ │ │ │ │ │ │ │ -

Definition at line 238 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 238 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ ptexIdx

│ │ │ │ │ │ │ │
│ │ │ │ @@ -192,15 +192,15 @@ │ │ │ │ int ptexIdx │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

ptex face index

│ │ │ │ │ │ │ │ -

Definition at line 237 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 237 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ s

│ │ │ │ │ │ │ │
│ │ │ │ @@ -212,15 +212,15 @@ │ │ │ │ REAL const* s │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

array of u coordinates

│ │ │ │ │ │ │ │ -

Definition at line 240 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 240 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ t

│ │ │ │ │ │ │ │
│ │ │ │ @@ -232,20 +232,20 @@ │ │ │ │ REAL const * t │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

array of v coordinates

│ │ │ │ │ │ │ │ -

Definition at line 241 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 241 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Stencil table factory class wrapping the template for compatibility. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │
│ │ │ │ Inheritance diagram for StencilTableFactory:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ StencilTableFactoryReal< float > │ │ │ │ @@ -146,15 +146,15 @@ │ │ │ │ - Public Types inherited from StencilTableFactoryReal< float > │ │ │ │ enum  Mode │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Stencil table factory class wrapping the template for compatibility.

│ │ │ │ │ │ │ │ -

Definition at line 287 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 287 of file stencilTableFactory.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ AppendLocalPointStencilTable()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -194,15 +194,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inlinestatic
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 308 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 308 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ AppendLocalPointStencilTableFaceVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -250,15 +250,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 334 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 334 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ AppendLocalPointStencilTableVarying()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -300,15 +300,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 321 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 321 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -338,15 +338,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 300 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 300 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -376,20 +376,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 293 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 293 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Stencil table factory class wrapping the template for compatibility. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <stencilTableFactory.h>

│ │ │ │ +

#include <stencilTableFactory.h>

│ │ │ │
│ │ │ │ Inheritance diagram for LimitStencilTableFactory:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ LimitStencilTableFactoryReal< float > │ │ │ │ @@ -128,15 +128,15 @@ │ │ │ │   │ │ │ │ typedef std::vector< LocationArray > LocationArrayVec │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Stencil table factory class wrapping the template for compatibility.

│ │ │ │ │ │ │ │ -

Definition at line 354 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 354 of file stencilTableFactory.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ Create()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -182,20 +182,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inlinestatic
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 360 of file stencilTableFactory.h.

│ │ │ │ +

Definition at line 360 of file stencilTableFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

A simple reference to raw topology data for use with TopologyRefinerFactory. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyDescriptor.h>

│ │ │ │ +

#include <topologyDescriptor.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  FVarChannel
 
│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -148,15 +148,15 @@ │ │ │ │

FVarChannel const * fvarChannels
 
│ │ │ │

Detailed Description

│ │ │ │

A simple reference to raw topology data for use with TopologyRefinerFactory.

│ │ │ │

TopologyDescriptor is a simple struct containing references to raw topology data used to construct a TopologyRefiner. It is not a requirement but a convenience for use with TopologyRefinerFactory when mesh topology is not available in an existing mesh data structure. It should be functionally complete and simple to use, but for more demanding situations, writing a custom Factory is usually warranted.

│ │ │ │ │ │ │ │ -

Definition at line 49 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 49 of file topologyDescriptor.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ TopologyDescriptor()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -180,15 +180,15 @@ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index const* cornerVertexIndices
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 62 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 62 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ cornerWeights

│ │ │ │ │ │ │ │
│ │ │ │ @@ -196,15 +196,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
float const* cornerWeights
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 63 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 63 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ creaseVertexIndexPairs

│ │ │ │ │ │ │ │
│ │ │ │ @@ -212,15 +212,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index const* creaseVertexIndexPairs
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 58 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 58 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ creaseWeights

│ │ │ │ │ │ │ │
│ │ │ │ @@ -228,15 +228,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
float const* creaseWeights
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 59 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 59 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ fvarChannels

│ │ │ │ │ │ │ │
│ │ │ │ @@ -244,15 +244,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
FVarChannel const* fvarChannels
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 82 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 82 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ holeIndices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -260,15 +260,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index const* holeIndices
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 66 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 66 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ isLeftHanded

│ │ │ │ │ │ │ │
│ │ │ │ @@ -276,15 +276,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
bool isLeftHanded
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 68 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 68 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numCorners

│ │ │ │ │ │ │ │
│ │ │ │ @@ -292,15 +292,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numCorners
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 61 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 61 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numCreases

│ │ │ │ │ │ │ │
│ │ │ │ @@ -308,15 +308,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numCreases
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 57 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 57 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numFaces

│ │ │ │ │ │ │ │
│ │ │ │ @@ -324,15 +324,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numFaces
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 52 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 52 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numFVarChannels

│ │ │ │ │ │ │ │
│ │ │ │ @@ -340,15 +340,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numFVarChannels
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 81 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 81 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numHoles

│ │ │ │ │ │ │ │
│ │ │ │ @@ -356,15 +356,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numHoles
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 65 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 65 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numVertices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -372,15 +372,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numVertices
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 51 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 51 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ numVertsPerFace

│ │ │ │ │ │ │ │
│ │ │ │ @@ -388,15 +388,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int const* numVertsPerFace
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 54 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 54 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ vertIndicesPerFace

│ │ │ │ │ │ │ │
│ │ │ │ @@ -404,20 +404,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index const* vertIndicesPerFace
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 55 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 55 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
TopologyDescriptor::FVarChannel Struct Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <topologyDescriptor.h>

│ │ │ │ +

#include <topologyDescriptor.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 FVarChannel ()
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -111,15 +111,15 @@ │ │ │ │

int numValues
 
Index const * valueIndices
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 73 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 73 of file topologyDescriptor.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ FVarChannel()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -136,15 +136,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 78 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 78 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ numValues

│ │ │ │ │ │ │ │ @@ -153,15 +153,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
int numValues
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 75 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 75 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ valueIndices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -169,20 +169,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Index const* valueIndices
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 76 of file topologyDescriptor.h.

│ │ │ │ +

Definition at line 76 of file topologyDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

An interface for accessing data in a specific level of a refined topology hierarchy. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyLevel.h>

│ │ │ │ +

#include <topologyLevel.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -258,15 +258,15 @@ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

Methods to inspect the overall inventory of components:

All three main component types are indexed locally within each level. For some topological relationships – notably face-vertices, which is often the only relationship of interest – the total number of entries is also made available.

│ │ │ │
int GetNumVertices () const
 ~TopologyLevel ()
 
│ │ │ │

Detailed Description

│ │ │ │

An interface for accessing data in a specific level of a refined topology hierarchy.

│ │ │ │

TopologyLevel provides an interface to data in a specific level of a topology hierarchy. Instances of TopologyLevel are created and owned by a TopologyRefiner, which will return const-references to them. Such references are only valid during the lifetime of the TopologyRefiner that created and returned them, and only for a given refinement, i.e. if the TopologyRefiner is re-refined, any references to TopoologyLevels are invalidated.

│ │ │ │ │ │ │ │ -

Definition at line 49 of file topologyLevel.h.

│ │ │ │ +

Definition at line 49 of file topologyLevel.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ TopologyLevel()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -283,15 +283,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 300 of file topologyLevel.h.

│ │ │ │ +

Definition at line 300 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ ~TopologyLevel()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -310,15 +310,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 301 of file topologyLevel.h.

│ │ │ │ +

Definition at line 301 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ DoesEdgeFVarTopologyMatch()

│ │ │ │ │ │ │ │ @@ -351,15 +351,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if face-varying topology across the edge only matches.

│ │ │ │ │ │ │ │ -

Definition at line 247 of file topologyLevel.h.

│ │ │ │ +

Definition at line 247 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ DoesFaceFVarTopologyMatch()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -391,15 +391,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if face-varying topology around a face matches.

│ │ │ │ │ │ │ │ -

Definition at line 252 of file topologyLevel.h.

│ │ │ │ +

Definition at line 252 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ DoesVertexFVarTopologyMatch()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -431,15 +431,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if face-varying topology around a vertex matches.

│ │ │ │ │ │ │ │ -

Definition at line 242 of file topologyLevel.h.

│ │ │ │ +

Definition at line 242 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ FindEdge()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -471,15 +471,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Identify the edge matching the given vertex pair.

│ │ │ │ │ │ │ │ -

Definition at line 120 of file topologyLevel.h.

│ │ │ │ +

Definition at line 120 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeChildEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -501,15 +501,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the child edges (in the next level) of a given edge.

│ │ │ │ │ │ │ │ -

Definition at line 268 of file topologyLevel.h.

│ │ │ │ +

Definition at line 268 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeChildVertex()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -531,15 +531,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the child vertex (in the next level) of a given edge.

│ │ │ │ │ │ │ │ -

Definition at line 274 of file topologyLevel.h.

│ │ │ │ +

Definition at line 274 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeFaceLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -561,15 +561,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the local indices of an edge with respect to its incident faces.

│ │ │ │ │ │ │ │ -

Definition at line 117 of file topologyLevel.h.

│ │ │ │ +

Definition at line 117 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -591,15 +591,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the faces incident a given edge.

│ │ │ │ │ │ │ │ -

Definition at line 102 of file topologyLevel.h.

│ │ │ │ +

Definition at line 102 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -621,15 +621,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the sharpness assigned a given edge.

│ │ │ │ │ │ │ │ -

Definition at line 173 of file topologyLevel.h.

│ │ │ │ +

Definition at line 173 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetEdgeVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -651,15 +651,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the vertices incident a given edge.

│ │ │ │ │ │ │ │ -

Definition at line 99 of file topologyLevel.h.

│ │ │ │ +

Definition at line 99 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceChildEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -681,15 +681,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the child edges (in the next level) of a given face.

│ │ │ │ │ │ │ │ -

Definition at line 265 of file topologyLevel.h.

│ │ │ │ +

Definition at line 265 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceChildFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -711,15 +711,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the child faces (in the next level) of a given face.

│ │ │ │ │ │ │ │ -

Definition at line 262 of file topologyLevel.h.

│ │ │ │ +

Definition at line 262 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceChildVertex()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -741,15 +741,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the child vertex (in the next level) of a given face.

│ │ │ │ │ │ │ │ -

Definition at line 271 of file topologyLevel.h.

│ │ │ │ +

Definition at line 271 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -771,15 +771,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the edges incident a given face.

│ │ │ │ │ │ │ │ -

Definition at line 96 of file topologyLevel.h.

│ │ │ │ +

Definition at line 96 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceFVarValues()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -811,15 +811,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the face-varying values associated with a particular face.

│ │ │ │ │ │ │ │ -

Definition at line 237 of file topologyLevel.h.

│ │ │ │ +

Definition at line 237 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceParentFace()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -841,15 +841,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the parent face (in the previous level) of a given face.

│ │ │ │ │ │ │ │ -

Definition at line 280 of file topologyLevel.h.

│ │ │ │ +

Definition at line 280 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFaceVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -871,15 +871,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the vertices incident a given face.

│ │ │ │ │ │ │ │ -

Definition at line 93 of file topologyLevel.h.

│ │ │ │ +

Definition at line 93 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -900,15 +900,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of edges in this level.

│ │ │ │ │ │ │ │ -

Definition at line 68 of file topologyLevel.h.

│ │ │ │ +

Definition at line 68 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -929,15 +929,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of faces in this level.

│ │ │ │ │ │ │ │ -

Definition at line 65 of file topologyLevel.h.

│ │ │ │ +

Definition at line 65 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFaceVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -958,15 +958,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the total number of face-vertices, i.e. the sum of all vertices for all faces.

│ │ │ │ │ │ │ │ -

Definition at line 71 of file topologyLevel.h.

│ │ │ │ +

Definition at line 71 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarChannels()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -987,15 +987,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of face-varying channels (should be same for all levels)

│ │ │ │ │ │ │ │ -

Definition at line 230 of file topologyLevel.h.

│ │ │ │ +

Definition at line 230 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarValues()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1017,15 +1017,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the total number of face-varying values in a particular channel (the upper bound of a face-varying value index)

│ │ │ │ │ │ │ │ -

Definition at line 234 of file topologyLevel.h.

│ │ │ │ +

Definition at line 234 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1046,15 +1046,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the number of vertices in this level.

│ │ │ │ │ │ │ │ -

Definition at line 62 of file topologyLevel.h.

│ │ │ │ +

Definition at line 62 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexChildVertex()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1076,15 +1076,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the child vertex (in the next level) of a given vertex.

│ │ │ │ │ │ │ │ -

Definition at line 277 of file topologyLevel.h.

│ │ │ │ +

Definition at line 277 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexEdgeLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1106,15 +1106,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the local indices of a vertex with respect to its incident edges.

│ │ │ │ │ │ │ │ -

Definition at line 114 of file topologyLevel.h.

│ │ │ │ +

Definition at line 114 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1136,15 +1136,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the edges incident a given vertex.

│ │ │ │ │ │ │ │ -

Definition at line 108 of file topologyLevel.h.

│ │ │ │ +

Definition at line 108 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexFaceLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1166,15 +1166,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the local indices of a vertex with respect to its incident faces.

│ │ │ │ │ │ │ │ -

Definition at line 111 of file topologyLevel.h.

│ │ │ │ +

Definition at line 111 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1196,15 +1196,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Access the faces incident a given vertex.

│ │ │ │ │ │ │ │ -

Definition at line 105 of file topologyLevel.h.

│ │ │ │ +

Definition at line 105 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexRule()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1226,15 +1226,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the subdivision rule assigned a given vertex specific to this level.

│ │ │ │ │ │ │ │ -

Definition at line 194 of file topologyLevel.h.

│ │ │ │ +

Definition at line 194 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1256,15 +1256,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return the sharpness assigned a given vertex.

│ │ │ │ │ │ │ │ -

Definition at line 176 of file topologyLevel.h.

│ │ │ │ +

Definition at line 176 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsEdgeBoundary()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1286,15 +1286,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the edge is a boundary (only one incident face)

│ │ │ │ │ │ │ │ -

Definition at line 134 of file topologyLevel.h.

│ │ │ │ +

Definition at line 134 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsEdgeInfSharp()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1316,15 +1316,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the edge is infinitely-sharp.

│ │ │ │ │ │ │ │ -

Definition at line 179 of file topologyLevel.h.

│ │ │ │ +

Definition at line 179 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsEdgeNonManifold()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1346,15 +1346,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the edge is non-manifold.

│ │ │ │ │ │ │ │ -

Definition at line 128 of file topologyLevel.h.

│ │ │ │ +

Definition at line 128 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsEdgeSemiSharp()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1376,15 +1376,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the edge is semi-sharp.

│ │ │ │ │ │ │ │ -

Definition at line 185 of file topologyLevel.h.

│ │ │ │ +

Definition at line 185 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsFaceHole()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1406,15 +1406,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if a given face has been tagged as a hole.

│ │ │ │ │ │ │ │ -

Definition at line 191 of file topologyLevel.h.

│ │ │ │ +

Definition at line 191 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsVertexBoundary()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1436,15 +1436,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the vertex is on a boundary (at least one incident boundary edge)

│ │ │ │ │ │ │ │ -

Definition at line 137 of file topologyLevel.h.

│ │ │ │ +

Definition at line 137 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsVertexCorner()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1466,15 +1466,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the vertex is a corner (only one incident face)

│ │ │ │ │ │ │ │ -

Definition at line 140 of file topologyLevel.h.

│ │ │ │ +

Definition at line 140 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsVertexInfSharp()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1496,15 +1496,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the vertex is infinitely-sharp.

│ │ │ │ │ │ │ │ -

Definition at line 182 of file topologyLevel.h.

│ │ │ │ +

Definition at line 182 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsVertexNonManifold()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1526,15 +1526,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the vertex is non-manifold.

│ │ │ │ │ │ │ │ -

Definition at line 131 of file topologyLevel.h.

│ │ │ │ +

Definition at line 131 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsVertexSemiSharp()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1556,15 +1556,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Return if the vertex is semi-sharp.

│ │ │ │ │ │ │ │ -

Definition at line 188 of file topologyLevel.h.

│ │ │ │ +

Definition at line 188 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsVertexValenceRegular()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1589,15 +1589,15 @@ │ │ │ │
│ │ │ │ │ │ │ │

Return if the valence of the vertex is regular (must be manifold)

│ │ │ │

Note that this test only determines if the valence of the vertex is regular with respect to the assigned subdivision scheme – not if the neighborhood around the vertex is regular. The latter depends on a number of factors including the incident faces of the vertex (they must all be regular) and the presence of sharpness at the vertex itself or its incident edges.

│ │ │ │

The regularity of the valence is a necessary but not a sufficient condition in determining the regularity of the neighborhood. For example, while the valence of an interior vertex may be regular, its neighborhood is not if the vertex was made infinitely sharp. Conversely, a corner vertex is considered regular by its valence but its neighborhood is not if the vertex was not made infinitely sharp.

│ │ │ │

Whether the valence of the vertex is regular is also a property that remains the same for the vertex in all subdivision levels. In contrast, the regularity of the region around the vertex may change as the presence of irregular faces or semi-sharp features is reduced by subdivision.

│ │ │ │ │ │ │ │ -

Definition at line 162 of file topologyLevel.h.

│ │ │ │ +

Definition at line 162 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PrintTopology()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1617,15 +1617,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 287 of file topologyLevel.h.

│ │ │ │ +

Definition at line 287 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ ValidateTopology()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1644,15 +1644,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 286 of file topologyLevel.h.

│ │ │ │ +

Definition at line 286 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Friends And Related Symbol Documentation

│ │ │ │ │ │ │ │

◆ TopologyRefiner

│ │ │ │ │ │ │ │ @@ -1669,20 +1669,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 292 of file topologyLevel.h.

│ │ │ │ +

Definition at line 292 of file topologyLevel.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Factory for constructing TopologyRefiners from specific mesh classes. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyRefinerFactory.h>

│ │ │ │ +

#include <topologyRefinerFactory.h>

│ │ │ │
│ │ │ │ Inheritance diagram for TopologyRefinerFactory< MESH >:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ TopologyRefinerFactoryBase │ │ │ │ @@ -277,15 +277,15 @@ │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │
template<class MESH>
│ │ │ │ class OpenSubdiv::OPENSUBDIV_VERSION::Far::TopologyRefinerFactory< MESH >

Factory for constructing TopologyRefiners from specific mesh classes.

│ │ │ │

TopologyRefinerFactory<MESH> is the factory class template to convert an instance of TopologyRefiner from an arbitrary mesh class. While a class template, the implementation is not (cannot) be complete, so specialization of a few methods is required (it is a stateless factory, so no instance and only static methods).

│ │ │ │

This template provides both the interface and high level assembly for the construction of the TopologyRefiner instance. The high level construction executes a specific set of operations to convert the client's MESH into TopologyRefiner. This set of operations combines methods independent of MESH from the base class with those specialized here for class MESH.

│ │ │ │ │ │ │ │ -

Definition at line 78 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 78 of file topologyRefinerFactory.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ TopologyError

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -301,15 +301,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 131 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 131 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ assignComponentTags()

│ │ │ │ │ │ │ │ @@ -344,15 +344,15 @@ │ │ │ │ staticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

(Optional) Specify edge or vertex sharpness or face holes

│ │ │ │ │ │ │ │ -

Definition at line 690 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 690 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ assignComponentTopology()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -386,15 +386,15 @@ │ │ │ │ staticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the relationships between vertices, faces, etc. ie the face-vertices, vertex-faces, edge-vertices, etc.

│ │ │ │ │ │ │ │ -

Definition at line 621 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 621 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ assignFaceVaryingTopology()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -428,15 +428,15 @@ │ │ │ │ staticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

(Optional) Specify face-varying data per face

│ │ │ │ │ │ │ │ -

Definition at line 674 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 674 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -479,15 +479,15 @@ │ │ │ │ meshClient's topological representation (or a converter) │ │ │ │ optionsOptions controlling the creation of the TopologyRefiner │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Returns
A new instance of TopologyRefiner or 0 for failure
│ │ │ │ │ │ │ │ -

Definition at line 346 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 346 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -519,15 +519,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
baseLevelAn existing TopologyRefiner to share base level.
│ │ │ │ │ │ │ │ │ │ │ │
Returns
A new instance of TopologyRefiner or 0 for failure
│ │ │ │ │ │ │ │ -

Definition at line 364 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 364 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ createBaseFVarChannel() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -561,15 +561,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Create a new face-varying channel with the given number of values.

│ │ │ │ │ │ │ │ -

Definition at line 561 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 561 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ createBaseFVarChannel() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -609,15 +609,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Create a new face-varying channel with the given number of values and independent interpolation options.

│ │ │ │ │ │ │ │ -

Definition at line 566 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 566 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ findBaseEdge()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -657,15 +657,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Identify an edge to be assigned a sharpness value given a vertex pair.

│ │ │ │ │ │ │ │ -

Definition at line 521 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 521 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseEdgeFaceLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -699,15 +699,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the local indices of an edge within each of its incident faces.

│ │ │ │ │ │ │ │ -

Definition at line 505 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 505 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseEdgeFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -741,15 +741,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the faces incident each edge.

│ │ │ │ │ │ │ │ -

Definition at line 489 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 489 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseEdgeVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -783,15 +783,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the vertices incident each edge.

│ │ │ │ │ │ │ │ -

Definition at line 484 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 484 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseFaceEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -825,15 +825,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the edges incident each face.

│ │ │ │ │ │ │ │ -

Definition at line 479 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 479 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseFaceFVarValues()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -873,15 +873,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the face-varying values for the corners of each face.

│ │ │ │ │ │ │ │ -

Definition at line 573 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 573 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseFaceVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -915,15 +915,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the vertices incident each face.

│ │ │ │ │ │ │ │ -

Definition at line 474 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 474 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseVertexEdgeLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -957,15 +957,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the local indices of a vertex within each of its incident edges.

│ │ │ │ │ │ │ │ -

Definition at line 515 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 515 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseVertexEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -999,15 +999,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the edges incident each vertex.

│ │ │ │ │ │ │ │ -

Definition at line 499 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 499 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseVertexFaceLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1041,15 +1041,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the local indices of a vertex within each of its incident faces.

│ │ │ │ │ │ │ │ -

Definition at line 510 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 510 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getBaseVertexFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1083,15 +1083,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign the faces incident each vertex.

│ │ │ │ │ │ │ │ -

Definition at line 494 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 494 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getNumBaseEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1113,15 +1113,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 441 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 441 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getNumBaseFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1143,15 +1143,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 436 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 436 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getNumBaseVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1173,15 +1173,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 446 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 446 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ populateBaseLevel()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1219,15 +1219,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ staticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 371 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 371 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ populateBaseLocalIndices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1251,15 +1251,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Determine all local indices by inspection (only for pure manifold meshes)

│ │ │ │ │ │ │ │ -

Definition at line 527 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 527 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ reportInvalidTopology()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1299,15 +1299,15 @@ │ │ │ │ staticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

(Optional) Control run-time topology validation and error reporting

│ │ │ │ │ │ │ │ -

Definition at line 707 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 707 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ resizeComponentTopology()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1341,15 +1341,15 @@ │ │ │ │ staticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of vertices, faces, face-vertices, etc.

│ │ │ │ │ │ │ │ -

Definition at line 580 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 580 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setBaseEdgeNonManifold()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1389,15 +1389,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Tag an edge as non-manifold.

│ │ │ │ │ │ │ │ -

Definition at line 533 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 533 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setBaseEdgeSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1437,15 +1437,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign a sharpness value to a given edge.

│ │ │ │ │ │ │ │ -

Definition at line 544 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 544 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setBaseFaceHole()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1485,15 +1485,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Tag a face as a hole.

│ │ │ │ │ │ │ │ -

Definition at line 554 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 554 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setBaseVertexNonManifold()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1533,15 +1533,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Tag a vertex as non-manifold.

│ │ │ │ │ │ │ │ -

Definition at line 538 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 538 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setBaseVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1581,15 +1581,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Assign a sharpness value to a given vertex.

│ │ │ │ │ │ │ │ -

Definition at line 549 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 549 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseEdgeFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1629,15 +1629,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of faces incident each edge.

│ │ │ │ │ │ │ │ -

Definition at line 458 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 458 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1671,15 +1671,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of edges to be accommodated.

│ │ │ │ │ │ │ │ -

Definition at line 425 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 425 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1713,15 +1713,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of faces to be accommodated.

│ │ │ │ │ │ │ │ -

Definition at line 420 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 420 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseFaceVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1761,15 +1761,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of vertices incident each face.

│ │ │ │ │ │ │ │ -

Definition at line 452 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 452 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseVertexEdges()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1809,15 +1809,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of edges incident each vertex.

│ │ │ │ │ │ │ │ -

Definition at line 468 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 468 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseVertexFaces()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1857,15 +1857,15 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of faces incident each vertex.

│ │ │ │ │ │ │ │ -

Definition at line 463 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 463 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ setNumBaseVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1899,21 +1899,21 @@ │ │ │ │ inlinestaticprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Specify the number of vertices to be accommodated.

│ │ │ │ │ │ │ │ -

Definition at line 430 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 430 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following files: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Stores topology data for a specified set of refinement options. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyRefiner.h>

│ │ │ │ +

#include <topologyRefiner.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -208,15 +208,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Classes

struct  AdaptiveOptions
 Adaptive refinement options. More...
 
struct  UniformOptions
 
 TopologyRefiner (TopologyRefiner const &source)
 
│ │ │ │

Detailed Description

│ │ │ │

Stores topology data for a specified set of refinement options.

│ │ │ │ │ │ │ │ -

Definition at line 51 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 51 of file topologyRefiner.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ TopologyRefiner() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -311,15 +311,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Returns the options specified on refinement.

│ │ │ │ │ │ │ │ -

Definition at line 196 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 196 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetFVarLinearInterpolation()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -341,15 +341,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the face-varying interpolation rule set for a given channel.

│ │ │ │ │ │ │ │ -

Definition at line 298 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 298 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ getLevel() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -369,15 +369,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 236 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 236 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getLevel() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -397,15 +397,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 237 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 237 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLevel()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -427,15 +427,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns a handle to access data specific to a particular level.

│ │ │ │ │ │ │ │ -

Definition at line 95 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 95 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetMaxLevel()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -456,15 +456,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the highest level of refinement.

│ │ │ │ │ │ │ │ -

Definition at line 74 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 74 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetMaxValence()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -485,15 +485,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the maximum vertex valence in all levels.

│ │ │ │ │ │ │ │ -

Definition at line 77 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 77 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumEdgesTotal()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -514,15 +514,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the total number of edges in all levels.

│ │ │ │ │ │ │ │ -

Definition at line 86 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 86 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFacesTotal()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -543,15 +543,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the total number of edges in all levels.

│ │ │ │ │ │ │ │ -

Definition at line 89 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 89 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFaceVerticesTotal()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -572,15 +572,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the total number of face vertices in all levels.

│ │ │ │ │ │ │ │ -

Definition at line 92 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 92 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarChannels()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -601,15 +601,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of face-varying channels in the tables.

│ │ │ │ │ │ │ │ -

Definition at line 293 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 293 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarValuesTotal()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -650,15 +650,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the number of refinement levels.

│ │ │ │ │ │ │ │ -

Definition at line 71 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 71 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumVerticesTotal()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -679,15 +679,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the total number of vertices in all levels.

│ │ │ │ │ │ │ │ -

Definition at line 83 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 83 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getRefinement() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -707,15 +707,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 239 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 239 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ getRefinement() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -735,15 +735,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 240 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 240 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSchemeOptions()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -764,15 +764,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the subdivision options.

│ │ │ │ │ │ │ │ -

Definition at line 65 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 65 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSchemeType()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -793,15 +793,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the subdivision scheme.

│ │ │ │ │ │ │ │ -

Definition at line 62 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 62 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetUniformOptions()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -822,15 +822,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the options specified on refinement.

│ │ │ │ │ │ │ │ -

Definition at line 149 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 149 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ HasHoles()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -851,15 +851,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns true if faces have been tagged as holes.

│ │ │ │ │ │ │ │ -

Definition at line 80 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 80 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsUniform()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -880,15 +880,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns true if uniform refinement has been applied.

│ │ │ │ │ │ │ │ -

Definition at line 68 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 68 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ RefineAdaptive()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -989,15 +989,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 226 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 226 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PatchTableBuilder

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1013,15 +1013,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 225 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 225 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PrimvarRefinerReal

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1039,15 +1039,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 229 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 229 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ PtexIndices

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1063,15 +1063,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 227 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 227 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ TopologyRefinerFactory

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1089,15 +1089,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 223 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 223 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ TopologyRefinerFactoryBase

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1113,20 +1113,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ friend │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 224 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 224 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Uniform refinement options. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyRefiner.h>

│ │ │ │ +

#include <topologyRefiner.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -123,15 +123,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 UniformOptions (int level)
 
void SetRefinementLevel (int level)
 Set uniform refinement level.
 
│ │ │ │

Detailed Description

│ │ │ │

Uniform refinement options.

│ │ │ │

Options for uniform refinement, including the number of levels, vertex ordering and generation of topology information.

│ │ │ │

Note the impact of the option to generate fullTopologyInLastLevel. Given subsequent levels of uniform refinement typically reguire 4x the data of the previous level, only the minimum amount of data is generated in the last level by default, i.e. a vertex and face-vertex list. If requiring topology traversal of the last level, e.g. inspecting edges or incident faces of vertices, the option to generate full topology in the last level should be enabled.

│ │ │ │ │ │ │ │ -

Definition at line 118 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 118 of file topologyRefiner.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ UniformOptions()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -149,15 +149,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 120 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 120 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ SetRefinementLevel()

│ │ │ │ │ │ │ │ @@ -180,15 +180,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Set uniform refinement level.

│ │ │ │ │ │ │ │ -

Definition at line 126 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 126 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ fullTopologyInLastLevel

│ │ │ │ │ │ │ │ @@ -198,15 +198,15 @@ │ │ │ │ │ │ │ │ unsigned int fullTopologyInLastLevel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Skip topological relationships in the last level of refinement that are not needed for interpolation (keep false if using limit).

│ │ │ │ │ │ │ │ -

Definition at line 131 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 131 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ orderVerticesFromFacesFirst

│ │ │ │ │ │ │ │
│ │ │ │ @@ -215,15 +215,15 @@ │ │ │ │ │ │ │ │ unsigned int orderVerticesFromFacesFirst │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Order child vertices from faces first instead of child vertices of vertices

│ │ │ │ │ │ │ │ -

Definition at line 129 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 129 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ refinementLevel

│ │ │ │ │ │ │ │
│ │ │ │ @@ -233,20 +233,20 @@ │ │ │ │ unsigned int refinementLevel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Number of refinement iterations.

│ │ │ │ │ │ │ │ -

Definition at line 128 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 128 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Adaptive refinement options. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyRefiner.h>

│ │ │ │ +

#include <topologyRefiner.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -129,15 +129,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 AdaptiveOptions (int level)
 
void SetIsolationLevel (int level)
 Set isolation level.
 
unsigned int orderVerticesFromFacesFirst:1
 
│ │ │ │

Detailed Description

│ │ │ │

Adaptive refinement options.

│ │ │ │ │ │ │ │ -

Definition at line 156 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 156 of file topologyRefiner.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ AdaptiveOptions()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -155,15 +155,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 158 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 158 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ SetIsolationLevel()

│ │ │ │ │ │ │ │ @@ -186,15 +186,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Set isolation level.

│ │ │ │ │ │ │ │ -

Definition at line 167 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 167 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SetSecondaryLevel()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -216,15 +216,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Set secondary isolation level.

│ │ │ │ │ │ │ │ -

Definition at line 170 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 170 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ considerFVarChannels

│ │ │ │ │ │ │ │ @@ -234,15 +234,15 @@ │ │ │ │ │ │ │ │ unsigned int considerFVarChannels │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Inspect face-varying channels and isolate when irregular features present

│ │ │ │ │ │ │ │ -

Definition at line 180 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 180 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ isolationLevel

│ │ │ │ │ │ │ │
│ │ │ │ @@ -251,15 +251,15 @@ │ │ │ │ │ │ │ │ unsigned int isolationLevel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Number of iterations applied to isolate extraordinary vertices and creases

│ │ │ │ │ │ │ │ -

Definition at line 172 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 172 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ orderVerticesFromFacesFirst

│ │ │ │ │ │ │ │
│ │ │ │ @@ -268,15 +268,15 @@ │ │ │ │ │ │ │ │ unsigned int orderVerticesFromFacesFirst │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Order child vertices from faces first instead of child vertices of vertices

│ │ │ │ │ │ │ │ -

Definition at line 182 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 182 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ secondaryLevel

│ │ │ │ │ │ │ │
│ │ │ │ @@ -285,15 +285,15 @@ │ │ │ │ │ │ │ │ unsigned int secondaryLevel │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Shallower level to stop isolation of smooth irregular features

│ │ │ │ │ │ │ │ -

Definition at line 174 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 174 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ useInfSharpPatch

│ │ │ │ │ │ │ │
│ │ │ │ @@ -302,15 +302,15 @@ │ │ │ │ │ │ │ │ unsigned int useInfSharpPatch │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Use infinitely sharp patches and stop isolation where applicable

│ │ │ │ │ │ │ │ -

Definition at line 178 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 178 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ useSingleCreasePatch

│ │ │ │ │ │ │ │
│ │ │ │ @@ -319,20 +319,20 @@ │ │ │ │ │ │ │ │ unsigned int useSingleCreasePatch │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Use 'single-crease' patch and stop isolation where applicable

│ │ │ │ │ │ │ │ -

Definition at line 176 of file topologyRefiner.h.

│ │ │ │ +

Definition at line 176 of file topologyRefiner.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Private base class of Factories for constructing TopologyRefiners. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyRefinerFactory.h>

│ │ │ │ +

#include <topologyRefinerFactory.h>

│ │ │ │
│ │ │ │ Inheritance diagram for TopologyRefinerFactoryBase:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ TopologyRefinerFactory< MESH > │ │ │ │ @@ -129,15 +129,15 @@ │ │ │ │ static bool prepareFaceVaryingChannels (TopologyRefiner &refiner) │ │ │ │   │ │ │ │ │ │ │ │

Detailed Description

│ │ │ │

Private base class of Factories for constructing TopologyRefiners.

│ │ │ │

TopologyRefinerFactoryBase is the base class for subclasses that are intended to construct TopologyRefiners directly from meshes in their native representations. The subclasses are parameterized by the mesh type <class MESH> and are expected to inherit the details related to assembly and validation provided here that are independent of the subclass' mesh type.

│ │ │ │ │ │ │ │ -

Definition at line 47 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 47 of file topologyRefinerFactory.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ TopologyCallback

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -151,15 +151,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ protected
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 54 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 54 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ prepareComponentTagsAndSharpness()

│ │ │ │ │ │ │ │ @@ -283,15 +283,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Options related to the construction of each TopologyRefiner. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <topologyRefinerFactory.h>

│ │ │ │ +

#include <topologyRefinerFactory.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 Options (Sdc::SchemeType sdcType=Sdc::SCHEME_CATMARK, Sdc::Options sdcOptions=Sdc::Options())
 
│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -119,15 +119,15 @@ │ │ │ │

unsigned int validateFullTopology: 1
 
│ │ │ │

Detailed Description

│ │ │ │
template<class MESH>
│ │ │ │ struct OpenSubdiv::OPENSUBDIV_VERSION::Far::TopologyRefinerFactory< MESH >::Options

Options related to the construction of each TopologyRefiner.

│ │ │ │ │ │ │ │ -

Definition at line 84 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 84 of file topologyRefinerFactory.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Options()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │ @@ -157,15 +157,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 86 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 86 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ schemeOptions

│ │ │ │ │ │ │ │ @@ -177,15 +177,15 @@ │ │ │ │ │ │ │ │ Sdc::Options schemeOptions │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

The full set of options for the scheme, e.g. boundary interpolation rules...

│ │ │ │ │ │ │ │ -

Definition at line 92 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 92 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ schemeType

│ │ │ │ │ │ │ │
│ │ │ │ @@ -197,15 +197,15 @@ │ │ │ │ Sdc::SchemeType schemeType │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

The subdivision scheme type identifier.

│ │ │ │ │ │ │ │ -

Definition at line 91 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 91 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ validateFullTopology

│ │ │ │ │ │ │ │
│ │ │ │ @@ -216,20 +216,20 @@ │ │ │ │ │ │ │ │ unsigned int validateFullTopology │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Apply more extensive validation of the constructed topology – intended for debugging.

│ │ │ │ │ │ │ │ -

Definition at line 94 of file topologyRefinerFactory.h.

│ │ │ │ +

Definition at line 94 of file topologyRefinerFactory.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

BufferDescriptor is a struct which describes buffer elements in interleaved data buffers. Almost all Osd Evaluator APIs take BufferDescriptors along with device-specific buffer objects. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <bufferDescriptor.h>

│ │ │ │ +

#include <bufferDescriptor.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -143,15 +143,15 @@ │ │ │ │

Detailed Description

│ │ │ │

BufferDescriptor is a struct which describes buffer elements in interleaved data buffers. Almost all Osd Evaluator APIs take BufferDescriptors along with device-specific buffer objects.

│ │ │ │

The offset of BufferDescriptor can also be used to express a batching offset if the data buffer is combined across multiple objects together.

│ │ │ │
    │ │ │ │
  • Note that each element has the same data type (float)
  • │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 61 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 61 of file bufferDescriptor.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ BufferDescriptor() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

│ │ │ │ Public Member Functions

 BufferDescriptor ()
 Default Constructor.
 
 BufferDescriptor (int o, int l, int s)
│ │ │ │ @@ -170,15 +170,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Default Constructor.

│ │ │ │ │ │ │ │ -

Definition at line 64 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 64 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ BufferDescriptor() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -216,15 +216,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Constructor.

│ │ │ │ │ │ │ │ -

Definition at line 67 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 67 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetLocalOffset()

│ │ │ │ │ │ │ │ @@ -246,15 +246,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Returns the relative offset within a stride.

│ │ │ │ │ │ │ │ -

Definition at line 70 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 70 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsValid()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -275,15 +275,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

True if the descriptor values are internally consistent.

│ │ │ │ │ │ │ │ -

Definition at line 75 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 75 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator!=()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -305,15 +305,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

True if the descriptors are not identical.

│ │ │ │ │ │ │ │ -

Definition at line 93 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 93 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ operator==()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -335,15 +335,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

True if the descriptors are identical.

│ │ │ │ │ │ │ │ -

Definition at line 86 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 86 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Reset()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -364,15 +364,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Resets the descriptor to default.

│ │ │ │ │ │ │ │ -

Definition at line 81 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 81 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ length

│ │ │ │ │ │ │ │ @@ -383,15 +383,15 @@ │ │ │ │ int length │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

number or length of the data

│ │ │ │ │ │ │ │ -

Definition at line 100 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 100 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ offset

│ │ │ │ │ │ │ │
│ │ │ │ @@ -401,15 +401,15 @@ │ │ │ │ int offset │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

offset to desired element data

│ │ │ │ │ │ │ │ -

Definition at line 98 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 98 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ stride

│ │ │ │ │ │ │ │
│ │ │ │ @@ -419,20 +419,20 @@ │ │ │ │ int stride │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

stride to the next element

│ │ │ │ │ │ │ │ -

Definition at line 102 of file bufferDescriptor.h.

│ │ │ │ +

Definition at line 102 of file bufferDescriptor.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this struct was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

OpenCL stencil table. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <clEvaluator.h>

│ │ │ │ +

#include <clEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -143,15 +143,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 CLStencilTable (Far::StencilTable const *stencilTable, cl_context clContext)
 
 CLStencilTable (Far::LimitStencilTable const *limitStencilTable, cl_context clContext)
 
 
│ │ │ │

Detailed Description

│ │ │ │

OpenCL stencil table.

│ │ │ │

This class is an OpenCL buffer representation of Far::StencilTable.

│ │ │ │

CLCompute consumes this table to apply stencils

│ │ │ │ │ │ │ │ -

Definition at line 52 of file clEvaluator.h.

│ │ │ │ +

Definition at line 52 of file clEvaluator.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ CLStencilTable() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -255,15 +255,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inlinestatic
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 61 of file clEvaluator.h.

│ │ │ │ +

Definition at line 61 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -295,15 +295,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 55 of file clEvaluator.h.

│ │ │ │ +

Definition at line 55 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDuuWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -322,15 +322,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 80 of file clEvaluator.h.

│ │ │ │ +

Definition at line 80 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDuvWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -349,15 +349,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 81 of file clEvaluator.h.

│ │ │ │ +

Definition at line 81 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDuWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -376,15 +376,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 78 of file clEvaluator.h.

│ │ │ │ +

Definition at line 78 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDvvWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -403,15 +403,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 82 of file clEvaluator.h.

│ │ │ │ +

Definition at line 82 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDvWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -430,15 +430,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 79 of file clEvaluator.h.

│ │ │ │ +

Definition at line 79 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetIndicesBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -457,15 +457,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 76 of file clEvaluator.h.

│ │ │ │ +

Definition at line 76 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumStencils()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -484,15 +484,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 83 of file clEvaluator.h.

│ │ │ │ +

Definition at line 83 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetOffsetsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -511,15 +511,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 75 of file clEvaluator.h.

│ │ │ │ +

Definition at line 75 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSizesBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -538,15 +538,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 74 of file clEvaluator.h.

│ │ │ │ +

Definition at line 74 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -565,20 +565,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 77 of file clEvaluator.h.

│ │ │ │ +

Definition at line 77 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
CLEvaluator Class Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <clEvaluator.h>

│ │ │ │ +

#include <clEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

typedef bool Instantiatable
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -245,29 +245,29 @@ │ │ │ │

 Wait the OpenCL kernels finish.
 
static void Synchronize (cl_command_queue queue)
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 100 of file clEvaluator.h.

│ │ │ │ +

Definition at line 100 of file clEvaluator.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ Instantiatable

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef bool Instantiatable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 102 of file clEvaluator.h.

│ │ │ │ +

Definition at line 102 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ CLEvaluator()

│ │ │ │ │ │ │ │ @@ -452,15 +452,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 145 of file clEvaluator.h.

│ │ │ │ +

Definition at line 145 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Create() [2/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -530,15 +530,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generic creator template.

│ │ │ │ │ │ │ │ -

Definition at line 131 of file clEvaluator.h.

│ │ │ │ +

Definition at line 131 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Create() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -592,15 +592,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 116 of file clEvaluator.h.

│ │ │ │ +

Definition at line 116 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Create() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -652,15 +652,15 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Generic creator template.

│ │ │ │ │ │ │ │ -

Definition at line 106 of file clEvaluator.h.

│ │ │ │ +

Definition at line 106 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [1/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1101,15 +1101,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1125 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1125 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [4/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1276,15 +1276,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1379 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1379 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [5/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1423,15 +1423,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1003 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1003 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [6/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1556,15 +1556,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1288 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1288 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [7/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1678,15 +1678,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 902 of file clEvaluator.h.

│ │ │ │ +

Definition at line 902 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [8/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1783,15 +1783,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1217 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1217 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [1/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1979,15 +1979,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2437 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2437 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [2/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2161,15 +2161,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2564 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2564 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [3/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2315,15 +2315,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2231 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2231 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [4/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2455,15 +2455,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2329 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2329 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [5/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2581,15 +2581,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2061 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2061 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [6/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2693,15 +2693,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2143 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2143 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [1/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2882,15 +2882,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1854 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1854 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [2/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3057,15 +3057,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1978 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1978 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [3/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3204,15 +3204,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1653 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1653 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [4/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3337,15 +3337,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1749 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1749 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [5/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3456,15 +3456,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1489 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1489 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [6/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3561,15 +3561,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1568 of file clEvaluator.h.

│ │ │ │ +

Definition at line 1568 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [1/9]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4206,15 +4206,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 421 of file clEvaluator.h.

│ │ │ │ +

Definition at line 421 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [5/9]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4367,15 +4367,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 646 of file clEvaluator.h.

│ │ │ │ +

Definition at line 646 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [6/9]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4500,15 +4500,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 309 of file clEvaluator.h.

│ │ │ │ +

Definition at line 309 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [7/9]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4619,15 +4619,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 561 of file clEvaluator.h.

│ │ │ │ +

Definition at line 561 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [8/9]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4727,15 +4727,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 219 of file clEvaluator.h.

│ │ │ │ +

Definition at line 219 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [9/9]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4818,15 +4818,15 @@ │ │ │ │ numStartEventsthe number of events in the array pointed to by startEvents. │ │ │ │ startEventspoints to an array of cl_event which will determine when it is safe for the OpenCL device to begin work or NULL if it can begin immediately. │ │ │ │ endEventpointer to a cl_event which will receive a copy of the cl_event which indicates when all work for this call has completed. This cl_event has an incremented reference count and should be released via clReleaseEvent(). NULL if not required. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 500 of file clEvaluator.h.

│ │ │ │ +

Definition at line 500 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Synchronize() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4876,20 +4876,20 @@ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Wait the OpenCL kernels finish.

│ │ │ │ │ │ │ │ -

Definition at line 2613 of file clEvaluator.h.

│ │ │ │ +

Definition at line 2613 of file clEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Concrete vertex buffer class for Cpu subdivision and DirectX drawing. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <cpuD3D11VertexBuffer.h>

│ │ │ │ +

#include <cpuD3D11VertexBuffer.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -143,15 +143,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

virtual ~CpuD3D11VertexBuffer ()
 Destructor.
 
void UpdateData (const float *src, int startVertex, int numVertices, void *deviceContext=NULL)
 
│ │ │ │

Detailed Description

│ │ │ │

Concrete vertex buffer class for Cpu subdivision and DirectX drawing.

│ │ │ │

CpuD3D11VertexBuffer implements CpuVertexBufferInterface and D3D11VertexBufferInterface.

│ │ │ │

An instance of this buffer class can be passed to CpuEvaluator.

│ │ │ │ │ │ │ │ -

Definition at line 48 of file cpuD3D11VertexBuffer.h.

│ │ │ │ +

Definition at line 48 of file cpuD3D11VertexBuffer.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ ~CpuD3D11VertexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -302,15 +302,15 @@ │ │ │ │ inline │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

Returns the D3D11 buffer object (for Osd::Mesh interface)

│ │ │ │ │ │ │ │ -

Definition at line 75 of file cpuD3D11VertexBuffer.h.

│ │ │ │ +

Definition at line 75 of file cpuD3D11VertexBuffer.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -430,15 +430,15 @@ │ │ │ │ │ │ │ │
│ │ │ │

This method is meant to be used in client code in order to provide coarse vertices data to Osd.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <cpuEvaluator.h>

│ │ │ │ +

#include <cpuEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -170,15 +170,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Static Public Member Functions

template<typename SRC_BUFFER , typename DST_BUFFER , typename STENCIL_TABLE >
static bool EvalStencils (SRC_BUFFER *srcBuffer, BufferDescriptor const &srcDesc, DST_BUFFER *dstBuffer, BufferDescriptor const &dstDesc, STENCIL_TABLE const *stencilTable, const CpuEvaluator *instance=NULL, void *deviceContext=NULL)
 Generic static eval stencils function. This function has a same signature as other device kernels have so that it can be called in the same way from OsdMesh template interface.
 
 
static void Synchronize (void *)
 synchronize all asynchronous computation invoked on this device.
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 39 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 39 of file cpuEvaluator.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ EvalPatches() [1/6]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -716,15 +716,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
patchTableCpuPatchTable or equivalent XXX: currently Far::PatchTable can't be used due to interface mismatch
instancenot used in the cpu evaluator
deviceContextnot used in the cpu evaluator
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 607 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 607 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ EvalPatches() [5/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -842,15 +842,15 @@ │ │ │ │ patchTableCpuPatchTable or equivalent XXX: currently Far::PatchTable can't be used due to interface mismatch │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 517 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 517 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ EvalPatches() [6/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -943,15 +943,15 @@ │ │ │ │ patchTableCpuPatchTable or equivalent XXX: currently Far::PatchTable can't be used due to interface mismatch │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 454 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 454 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1118,15 +1118,15 @@ │ │ │ │ fvarChannelface-varying channel │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1188 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 1188 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1251,15 +1251,15 @@ │ │ │ │ fvarChannelface-varying channel │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1100 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 1100 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1356,15 +1356,15 @@ │ │ │ │ fvarChannelface-varying channel │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1034 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 1034 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [1/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1524,15 +1524,15 @@ │ │ │ │ patchTableCpuPatchTable or equivalent XXX: currently Far::PatchTable can't be used due to interface mismatch │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 971 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 971 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1650,15 +1650,15 @@ │ │ │ │ patchTableCpuPatchTable or equivalent XXX: currently Far::PatchTable can't be used due to interface mismatch │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 886 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 886 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1748,15 +1748,15 @@ │ │ │ │ patchTableCpuPatchTable or equivalent XXX: currently Far::PatchTable can't be used due to interface mismatch │ │ │ │ instancenot used in the cpu evaluator │ │ │ │ deviceContextnot used in the cpu evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 823 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 823 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [1/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2352,15 +2352,15 @@ │ │ │ │ stencilTableFar::StencilTable or equivalent │ │ │ │ instancenot used in the cpu kernel (declared as a typed pointer to prevent undesirable template resolution) │ │ │ │ deviceContextnot used in the cpu kernel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 303 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 303 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [5/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2464,15 +2464,15 @@ │ │ │ │ stencilTableFar::StencilTable or equivalent │ │ │ │ instancenot used in the cpu kernel (declared as a typed pointer to prevent undesirable template resolution) │ │ │ │ deviceContextnot used in the cpu kernel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 168 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 168 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [6/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2551,15 +2551,15 @@ │ │ │ │ stencilTableFar::StencilTable or equivalent │ │ │ │ instancenot used in the cpu kernel (declared as a typed pointer to prevent undesirable template resolution) │ │ │ │ deviceContextnot used in the cpu kernel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 72 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 72 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Synchronize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2584,20 +2584,20 @@ │ │ │ │
│ │ │ │ │ │ │ │

synchronize all asynchronous computation invoked on this device.

│ │ │ │
│ │ │ │

Other methods

│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 1227 of file cpuEvaluator.h.

│ │ │ │ +

Definition at line 1227 of file cpuEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

D3D11 stencil table. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <d3d11ComputeEvaluator.h>

│ │ │ │ +

#include <d3d11ComputeEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -130,15 +130,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 D3D11StencilTable (Far::StencilTable const *stencilTable, ID3D11DeviceContext *deviceContext)
 
 ~D3D11StencilTable ()
 
 
│ │ │ │

Detailed Description

│ │ │ │

D3D11 stencil table.

│ │ │ │

This class is a D3D11 Shader Resource View representation of Far::StencilTable.

│ │ │ │

D3D11ComputeEvaluator consumes this table to apply stencils

│ │ │ │ │ │ │ │ -

Definition at line 56 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 56 of file d3d11ComputeEvaluator.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ D3D11StencilTable()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -214,15 +214,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inlinestatic
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 59 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 59 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -252,15 +252,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 64 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 64 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetIndicesSRV()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -279,15 +279,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 77 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 77 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumStencils()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -306,15 +306,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 79 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 79 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetOffsetsSRV()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -333,15 +333,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 76 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 76 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSizesSRV()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -360,15 +360,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 75 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 75 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetWeightsSRV()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -387,20 +387,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 78 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 78 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
D3D11ComputeEvaluator Class Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <d3d11ComputeEvaluator.h>

│ │ │ │ +

#include <d3d11ComputeEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

typedef bool Instantiatable
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -136,29 +136,29 @@ │ │ │ │

 
static void Synchronize (ID3D11DeviceContext *deviceContext)
 Wait the dispatched kernel finishes.
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 96 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 96 of file d3d11ComputeEvaluator.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ Instantiatable

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef bool Instantiatable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 98 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 98 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ D3D11ComputeEvaluator()

│ │ │ │ │ │ │ │ @@ -519,15 +519,15 @@ │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextID3D11DeviceContext. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 148 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 148 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -584,15 +584,15 @@ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Dispatch the DX compute kernel on GPU asynchronously. returns false if the kernel hasn't been compiled yet.

│ │ │ │ │ │ │ │ -

Definition at line 181 of file d3d11ComputeEvaluator.h.

│ │ │ │ +

Definition at line 181 of file d3d11ComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Synchronize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -617,15 +617,15 @@ │ │ │ │
│ │ │ │ │ │ │ │

Wait the dispatched kernel finishes.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

GL stencil table (Shader Storage buffer) │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <glComputeEvaluator.h>

│ │ │ │ +

#include <glComputeEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -141,15 +141,15 @@ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

 GLStencilTableSSBO (Far::StencilTable const *stencilTable)
 
 GLStencilTableSSBO (Far::LimitStencilTable const *limitStencilTable)
 
 
│ │ │ │

Detailed Description

│ │ │ │

GL stencil table (Shader Storage buffer)

│ │ │ │

This class is a GLSL SSBO representation of Far::StencilTable.

│ │ │ │

GLSLComputeKernel consumes this table to apply stencils

│ │ │ │ │ │ │ │ -

Definition at line 51 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 51 of file glComputeEvaluator.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ GLStencilTableSSBO() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -247,15 +247,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inlinestatic
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 58 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 58 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -285,15 +285,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 53 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 53 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetDuuWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -312,15 +312,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 76 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 76 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDuvWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -339,15 +339,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 77 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 77 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDuWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -366,15 +366,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 74 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 74 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDvvWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -393,15 +393,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 78 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 78 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetDvWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -420,15 +420,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 75 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 75 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetIndicesBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -447,15 +447,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 72 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 72 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumStencils()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -474,15 +474,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 79 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 79 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetOffsetsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -501,15 +501,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 71 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 71 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetSizesBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -528,15 +528,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 70 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 70 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetWeightsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -555,20 +555,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 73 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 73 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
GLComputeEvaluator Class Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <glComputeEvaluator.h>

│ │ │ │ +

#include <glComputeEvaluator.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

typedef bool Instantiatable
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ @@ -233,29 +233,29 @@ │ │ │ │

 
static void Synchronize (void *deviceContext)
 Wait the dispatched kernel finishes.
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 96 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 96 of file glComputeEvaluator.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ Instantiatable

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef bool Instantiatable
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 98 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 98 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ GLComputeEvaluator()

│ │ │ │ │ │ │ │ @@ -423,15 +423,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 111 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 111 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -479,15 +479,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 99 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 99 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [1/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -857,15 +857,15 @@ │ │ │ │ numPatchCoordsnumber of patchCoords. │ │ │ │ patchCoordsarray of locations to be evaluated. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1071 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1071 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [4/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1025,15 +1025,15 @@ │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 870 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 870 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [5/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1137,15 +1137,15 @@ │ │ │ │ numPatchCoordsnumber of patchCoords. │ │ │ │ patchCoordsarray of locations to be evaluated. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 997 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 997 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [6/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1263,15 +1263,15 @@ │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 769 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 769 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [7/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1347,15 +1347,15 @@ │ │ │ │ numPatchCoordsnumber of patchCoords. │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 943 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 943 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatches() [8/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1448,15 +1448,15 @@ │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 691 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 691 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [1/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1623,15 +1623,15 @@ │ │ │ │ fvarChannelface-varying channel │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1903 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1903 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [2/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1784,15 +1784,15 @@ │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ fvarChannelface-varying channel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 2011 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 2011 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [3/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1917,15 +1917,15 @@ │ │ │ │ fvarChannelface-varying channel │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1736 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1736 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [4/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2036,15 +2036,15 @@ │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ fvarChannelface-varying channel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1816 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1816 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [5/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2141,15 +2141,15 @@ │ │ │ │ fvarChannelface-varying channel │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1606 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1606 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesFaceVarying() [6/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2232,15 +2232,15 @@ │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ fvarChannelface-varying channel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1669 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1669 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [1/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2386,15 +2386,15 @@ │ │ │ │ numPatchCoordsnumber of patchCoords. │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1544 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1544 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [2/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2554,15 +2554,15 @@ │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1439 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1439 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [3/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2666,15 +2666,15 @@ │ │ │ │ numPatchCoordsnumber of patchCoords. │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1355 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1355 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [4/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2792,15 +2792,15 @@ │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1278 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1278 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [5/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2876,15 +2876,15 @@ │ │ │ │ numPatchCoordsnumber of patchCoords. │ │ │ │ patchCoordsarray of locations to be evaluated. must have BindVBO() method returning an array of PatchCoord struct in VBO. │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1214 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1214 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalPatchesVarying() [6/6]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2974,15 +2974,15 @@ │ │ │ │ patchTableGLPatchTable or equivalent │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLXFB evaluator │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 1154 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 1154 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [1/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3447,15 +3447,15 @@ │ │ │ │ dvvBufferOutput buffer 2nd derivative wrt v must have BindVBO() method returning a GL buffer object of destination data │ │ │ │ dvvDescvertex buffer descriptor for the dvvBuffer │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 502 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 502 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [4/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3601,15 +3601,15 @@ │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLSL kernel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 326 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 326 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [5/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3699,15 +3699,15 @@ │ │ │ │ dvBufferOutput buffer derivative wrt v must have BindVBO() method returning a GL buffer object of destination data │ │ │ │ dvDescvertex buffer descriptor for the dvBuffer │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 434 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 434 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [6/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3811,15 +3811,15 @@ │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLSL kernel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 236 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 236 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [7/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3881,15 +3881,15 @@ │ │ │ │ dstBufferOutput primvar buffer must have BindVBO() method returning a GL buffer object of destination data │ │ │ │ dstDescvertex buffer descriptor for the output buffer │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 386 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 386 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ EvalStencils() [8/8]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -3968,15 +3968,15 @@ │ │ │ │ stencilTablestencil table to be applied. The table must have SSBO interfaces. │ │ │ │ instancecached compiled instance. Clients are supposed to pre-compile an instance of this class and provide to this function. If it's null the kernel still compute by instantiating on-demand kernel although it may cause a performance problem. │ │ │ │ deviceContextnot used in the GLSL kernel │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -

Definition at line 168 of file glComputeEvaluator.h.

│ │ │ │ +

Definition at line 168 of file glComputeEvaluator.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Synchronize()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -4001,15 +4001,15 @@ │ │ │ │
│ │ │ │ │ │ │ │

Wait the dispatched kernel finishes.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Provides shader source which can be used by client code. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <hlslPatchShaderSource.h>

│ │ │ │ +

#include <hlslPatchShaderSource.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -122,15 +122,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Static Public Member Functions

static std::string GetPatchBasisShaderSource ()
 Returns shader source which can be used to evaluate position and first and second derivatives on piecewise parametric patches resulting from subdivision refinement.
 
static std::string GetPatchDrawingShaderSource ()
 
static std::string GetDomainShaderSource (Far::PatchDescriptor::Type type)
 
│ │ │ │

Detailed Description

│ │ │ │

Provides shader source which can be used by client code.

│ │ │ │ │ │ │ │ -

Definition at line 40 of file hlslPatchShaderSource.h.

│ │ │ │ +

Definition at line 40 of file hlslPatchShaderSource.h.

│ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ GetCommonShaderSource()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -282,15 +282,15 @@ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <mtlCommon.h>

│ │ │ │ +

#include <mtlCommon.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Attributes

id< MTLDevice > device = nullptr
 
id< MTLCommandQueue > commandQueue = nullptr
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 40 of file mtlCommon.h.

│ │ │ │ +

Definition at line 40 of file mtlCommon.h.

│ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ commandQueue

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
id<MTLCommandQueue> commandQueue = nullptr
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 43 of file mtlCommon.h.

│ │ │ │ +

Definition at line 43 of file mtlCommon.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ device

│ │ │ │ │ │ │ │
│ │ │ │ @@ -135,20 +135,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
id<MTLDevice> device = nullptr
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 42 of file mtlCommon.h.

│ │ │ │ +

Definition at line 42 of file mtlCommon.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
MTLLegacyGregoryPatchTable Class Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <mtlLegacyGregoryPatchTable.h>

│ │ │ │ +

#include <mtlLegacyGregoryPatchTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for MTLLegacyGregoryPatchTable:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ @@ -128,15 +128,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
static MTLLegacyGregoryPatchTableCreate (Far::PatchTable const *farPatchTable, DEVICE_CONTEXT context)
 
static MTLLegacyGregoryPatchTableCreate (Far::PatchTable const *farPatchTable, MTLContext *context)
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 41 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ +

Definition at line 41 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ ~MTLLegacyGregoryPatchTable()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -184,15 +184,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inlinestatic
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 48 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ +

Definition at line 48 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -248,15 +248,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 71 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ +

Definition at line 71 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetQuadOffsetsBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -275,15 +275,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 66 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ +

Definition at line 66 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -302,15 +302,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 56 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ +

Definition at line 56 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVertexValenceBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -329,15 +329,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 61 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ +

Definition at line 61 of file mtlLegacyGregoryPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateVertexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -374,15 +374,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
MTLPatchTable Class Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <mtlPatchTable.h>

│ │ │ │ +

#include <mtlPatchTable.h>

│ │ │ │
│ │ │ │ Inheritance diagram for MTLPatchTable:
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ @@ -170,29 +170,29 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
std::vector< id< MTLBuffer > > _fvarIndexBuffers
 
std::vector< id< MTLBuffer > > _fvarParamBuffers
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 46 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 46 of file mtlPatchTable.h.

│ │ │ │

Member Typedef Documentation

│ │ │ │ │ │ │ │

◆ VertexBufferBinding

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
typedef id<MTLBuffer> VertexBufferBinding
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 48 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 48 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ MTLPatchTable()

│ │ │ │ │ │ │ │ @@ -296,15 +296,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 54 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 54 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Create() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -360,15 +360,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 69 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 69 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFVarPatchIndexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -388,15 +388,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 70 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 70 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetFVarPatchParamBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -416,15 +416,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 71 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 71 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetNumFVarChannels()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -443,15 +443,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 68 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 68 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetPatchArrays()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -470,15 +470,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 61 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 61 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetPatchIndexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -497,15 +497,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 62 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 62 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetPatchParamBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -524,15 +524,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 63 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 63 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVaryingPatchArrays()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -551,15 +551,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 65 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 65 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetVaryingPatchIndexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -578,15 +578,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 66 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 66 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ _fvarIndexBuffers

│ │ │ │ │ │ │ │ @@ -603,15 +603,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 86 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 86 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _fvarParamBuffers

│ │ │ │ │ │ │ │
│ │ │ │ @@ -627,15 +627,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 87 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 87 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _fvarPatchArrays

│ │ │ │ │ │ │ │
│ │ │ │ @@ -651,15 +651,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 85 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 85 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _indexBuffer

│ │ │ │ │ │ │ │
│ │ │ │ @@ -675,15 +675,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 78 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 78 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _patchArrays

│ │ │ │ │ │ │ │
│ │ │ │ @@ -699,15 +699,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 76 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 76 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _patchParamBuffer

│ │ │ │ │ │ │ │
│ │ │ │ @@ -723,15 +723,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 79 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 79 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _varyingPatchArrays

│ │ │ │ │ │ │ │
│ │ │ │ @@ -747,15 +747,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 81 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 81 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ _varyingPatchIndexBuffer

│ │ │ │ │ │ │ │
│ │ │ │ @@ -771,20 +771,20 @@ │ │ │ │ │ │ │ │ │ │ │ │ protected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 83 of file mtlPatchTable.h.

│ │ │ │ +

Definition at line 83 of file mtlPatchTable.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
CPUMTLVertexBuffer Class Reference
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

#include <mtlVertexBuffer.h>

│ │ │ │ +

#include <mtlVertexBuffer.h>

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -127,15 +127,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Member Functions

void UpdateData (const float *src, int startVertex, int numVertices, MTLContext *context)
 
int GetNumElements () const
 
 CPUMTLVertexBuffer (int numElements, int numVertices)
 
bool allocate (MTLContext *context)
 
│ │ │ │

Detailed Description

│ │ │ │
│ │ │ │ -

Definition at line 39 of file mtlVertexBuffer.h.

│ │ │ │ +

Definition at line 39 of file mtlVertexBuffer.h.

│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ CPUMTLVertexBuffer()

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -251,15 +251,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ inline
│ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 58 of file mtlVertexBuffer.h.

│ │ │ │ +

Definition at line 58 of file mtlVertexBuffer.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ Create()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -320,15 +320,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 45 of file mtlVertexBuffer.h.

│ │ │ │ +

Definition at line 45 of file mtlVertexBuffer.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │

◆ GetNumVertices()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -347,15 +347,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 50 of file mtlVertexBuffer.h.

│ │ │ │ +

Definition at line 50 of file mtlVertexBuffer.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ UpdateData()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -392,15 +392,15 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file: │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Types, constants and utilities related to semi-sharp creasing – whose implementation is independent of the subdivision scheme. │ │ │ │ More...

│ │ │ │ │ │ │ │ -

#include <crease.h>

│ │ │ │ +

#include <crease.h>

│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Public Types

enum  Rule {
│ │ │ │   RULE_UNKNOWN = 0 │ │ │ │ ,
│ │ │ │   RULE_SMOOTH = (1 << 0) │ │ │ │ @@ -180,15 +180,15 @@ │ │ │ │
│ │ │ │

Detailed Description

│ │ │ │

Types, constants and utilities related to semi-sharp creasing – whose implementation is independent of the subdivision scheme.

│ │ │ │

Crease is intended to be a light-weight, trivially constructed class that computes crease-related properties – typically sharpness values and associated interpolation weights. An instance of Crease is defined with a set of options that include current and future variations that will impact computations involving sharpness values.

│ │ │ │

The Crease methods do not use topological neighborhoods as input. The methods here rely more on the sharpness values and less on the topology, so we choose to work directly with the sharpness values. We also follow the trend of using primitive arrays in the interface to encourage local gathering for re-use.

│ │ │ │

Note on the need for and use of sharpness values: In general, mask queries rely on the sharpness values. The common case of a smooth vertex, when known, avoids the need to inspect them, but unless the rules are well understood, users will be expected to provided them – particularly when they expect the mask queries to do all of the work (just determining if a vertex is smooth will require inspection of incident edge sharpness). Mask queries will occasionally require the subdivided sharpness values around the child vertex. So users will be expected to either provide them up front when known, or to be gathered on demand. Any implementation of subdivision with creasing cannot avoid subdividing the sharpness values first, so keeping them available for re-use is a worthwhile consideration.

│ │ │ │ │ │ │ │ -

Definition at line 62 of file crease.h.

│ │ │ │ +

Definition at line 62 of file crease.h.

│ │ │ │

Member Enumeration Documentation

│ │ │ │ │ │ │ │

◆ Rule

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ @@ -202,15 +202,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
Enumerator
RULE_UNKNOWN 
RULE_SMOOTH 
RULE_DART 
RULE_CREASE 
RULE_CORNER 
│ │ │ │ │ │ │ │ -

Definition at line 82 of file crease.h.

│ │ │ │ +

Definition at line 82 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │

Constructor & Destructor Documentation

│ │ │ │ │ │ │ │

◆ Crease() [1/2]

│ │ │ │ │ │ │ │ @@ -230,15 +230,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 91 of file crease.h.

│ │ │ │ +

Definition at line 91 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ Crease() [2/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -258,15 +258,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 92 of file crease.h.

│ │ │ │ +

Definition at line 92 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ ~Crease()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -285,15 +285,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 93 of file crease.h.

│ │ │ │ +

Definition at line 93 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Function Documentation

│ │ │ │ │ │ │ │

◆ ComputeFractionalWeightAtVertex()

│ │ │ │ │ │ │ │ @@ -362,15 +362,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 207 of file crease.h.

│ │ │ │ +

Definition at line 207 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ DetermineVertexVertexRule() [1/2]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -469,15 +469,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 228 of file crease.h.

│ │ │ │ +

Definition at line 228 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsInfinite()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -497,15 +497,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 72 of file crease.h.

│ │ │ │ +

Definition at line 72 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsSemiSharp()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -525,15 +525,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 73 of file crease.h.

│ │ │ │ +

Definition at line 73 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsSharp()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -553,15 +553,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 71 of file crease.h.

│ │ │ │ +

Definition at line 71 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsSmooth()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -581,15 +581,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlinestatic │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 70 of file crease.h.

│ │ │ │ +

Definition at line 70 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ IsUniform()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -608,15 +608,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 95 of file crease.h.

│ │ │ │ +

Definition at line 95 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SharpenBoundaryEdge()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -637,15 +637,15 @@ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Optional sharp features: Since options treat certain topological features as infinitely sharp – boundaries or (in future) non-manifold features – sharpness values should be adjusted before use. The following methods will adjust (by return) specific values according to the options applied.

│ │ │ │ │ │ │ │ -

Definition at line 189 of file crease.h.

│ │ │ │ +

Definition at line 189 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SharpenBoundaryVertex()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -665,15 +665,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 200 of file crease.h.

│ │ │ │ +

Definition at line 200 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SubdivideEdgeSharpnessAtVertex()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -766,15 +766,15 @@ │ │ │ │
│ │ │ │

Sharpness subdivision: The computation of a Uniform subdivided sharpness value is as follows:

    │ │ │ │
  • Smooth edges or verts stay Smooth
  • │ │ │ │
  • Sharp edges or verts stay Sharp
  • │ │ │ │
  • semi-sharp edges or verts are decremented by 1.0 but for Chaikin (and potentially future non-uniform schemes that improve upon it) the computation is more involved. In the case of edges in particular, the sharpness of a child edge is determined by the sharpness in the neighborhood of the end vertex corresponding to the child. For this reason, an alternative to subdividing sharpness that computes all child edges around a vertex is given.
  • │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 216 of file crease.h.

│ │ │ │ +

Definition at line 216 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SubdivideVertexSharpness()

│ │ │ │ │ │ │ │
│ │ │ │ @@ -794,15 +794,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 222 of file crease.h.

│ │ │ │ +

Definition at line 222 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │

Member Data Documentation

│ │ │ │ │ │ │ │

◆ SHARPNESS_INFINITE

│ │ │ │ │ │ │ │ @@ -819,15 +819,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ static │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 68 of file crease.h.

│ │ │ │ +

Definition at line 68 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ SHARPNESS_SMOOTH

│ │ │ │ │ │ │ │
│ │ │ │ @@ -844,20 +844,20 @@ │ │ │ │ │ │ │ │ static │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │

Constants and related queries of sharpness values:

│ │ │ │ │ │ │ │ -

Definition at line 67 of file crease.h.

│ │ │ │ +

Definition at line 67 of file crease.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
The documentation for this class was generated from the following file:
    │ │ │ │ -
  • opensubdiv/sdc/crease.h
  • │ │ │ │ +
  • opensubdiv/sdc/crease.h
  • │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 208 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 208 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignCornerLimitMask() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -619,15 +619,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 301 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 301 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignCornerLimitTangentMasks() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -833,15 +833,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 221 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 221 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignCreaseLimitMask() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1023,15 +1023,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 334 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 334 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignCreaseLimitTangentMasks() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1293,15 +1293,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 148 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 148 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignCreaseMaskForVertex() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1453,15 +1453,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 247 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 247 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignSmoothLimitMask() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1625,15 +1625,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 453 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 453 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignSmoothLimitTangentMasks() [4/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1707,15 +1707,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 71 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 71 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignSmoothMaskForEdge() [2/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -1863,15 +1863,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inlineprotected │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 173 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 173 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ assignSmoothMaskForVertex() [3/3]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2268,15 +2268,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 56 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 56 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetLocalNeighborhoodSize() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2405,15 +2405,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 50 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 50 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetRegularFaceSize() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2513,15 +2513,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 53 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 53 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetRegularVertexValence() [3/4]

│ │ │ │ │ │ │ │
│ │ │ │ @@ -2621,15 +2621,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ inline │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ -

Definition at line 47 of file catmarkScheme.h.

│ │ │ │ +

Definition at line 47 of file catmarkScheme.h.

│ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │

◆ GetTopologicalSplitType() [3/4]

│ │ │ │ │ │ │ │
│ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a01489.html │ │ │ │ @@ -95,15 +95,15 @@ │ │ │ │ Classes | │ │ │ │ Namespaces | │ │ │ │ Typedefs
│ │ │ │
types.h File Reference
│ │ │ │ │ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/patchTable.h"
│ │ │ │ +#include "../far/patchTable.h"
│ │ │ │ #include <algorithm>
│ │ │ │
│ │ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/a01489_source.html │ │ │ │ @@ -263,21 +263,21 @@ │ │ │ │
140} // end namespace OpenSubdiv
│ │ │ │
141
│ │ │ │
142
│ │ │ │
143#endif // OPENSUBDIV3_OSD_TYPES_H
│ │ │ │ │ │ │ │
std::vector< PatchParam > PatchParamVector
Definition types.h:133
│ │ │ │
std::vector< PatchArray > PatchArrayVector
Definition types.h:132
│ │ │ │ - │ │ │ │ -
Type GetType() const
Returns the type of the patch.
│ │ │ │ - │ │ │ │ -
Handle that can be used as unique patch identifier within PatchTable.
Definition patchTable.h:60
│ │ │ │ - │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ +
Type GetType() const
Returns the type of the patch.
│ │ │ │ + │ │ │ │ +
Handle that can be used as unique patch identifier within PatchTable.
Definition patchTable.h:60
│ │ │ │ + │ │ │ │ + │ │ │ │ + │ │ │ │
Coordinates set on a patch table.
Definition types.h:42
│ │ │ │
Far::PatchTable::PatchHandle handle
patch handle
Definition types.h:62
│ │ │ │ │ │ │ │ │ │ │ │
PatchCoord(Far::PatchTable::PatchHandle handleArg, float sArg, float tArg)
Constructor.
Definition types.h:53
│ │ │ │
float t
parametric location on patch
Definition types.h:63
│ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_2483050b711c1829a6434006d0beb10c.html │ │ │ │ @@ -93,79 +93,79 @@ │ │ │ │
│ │ │ │
osd Directory Reference
│ │ │ │
│ │ │ │
│ │ │ │

│ │ │ │ Classes

struct  PatchCoord
│ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_2483050b711c1829a6434006d0beb10c.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,41 +1,41 @@ │ │ │ │ │ var dir_2483050b711c1829a6434006d0beb10c = [ │ │ │ │ │ - ["bufferDescriptor.h", "a00899.html", "a00899"], │ │ │ │ │ - ["clEvaluator.h", "a00803.html", "a00803"], │ │ │ │ │ + ["bufferDescriptor.h", "a00896.html", "a00896"], │ │ │ │ │ + ["clEvaluator.h", "a00806.html", "a00806"], │ │ │ │ │ ["clPatchTable.h", "a00800.html", "a00800"], │ │ │ │ │ ["clVertexBuffer.h", "a00794.html", "a00794"], │ │ │ │ │ - ["cpuD3D11VertexBuffer.h", "a00845.html", "a00845"], │ │ │ │ │ - ["cpuEvaluator.h", "a00896.html", "a00896"], │ │ │ │ │ + ["cpuD3D11VertexBuffer.h", "a00842.html", "a00842"], │ │ │ │ │ + ["cpuEvaluator.h", "a00899.html", "a00899"], │ │ │ │ │ ["cpuGLVertexBuffer.h", "a00869.html", "a00869"], │ │ │ │ │ ["cpuPatchTable.h", "a00893.html", "a00893"], │ │ │ │ │ ["cpuVertexBuffer.h", "a00890.html", "a00890"], │ │ │ │ │ ["cudaEvaluator.h", "a00791.html", "a00791"], │ │ │ │ │ ["cudaPatchTable.h", "a00788.html", "a00788"], │ │ │ │ │ ["cudaVertexBuffer.h", "a00902.html", "a00902"], │ │ │ │ │ - ["d3d11ComputeEvaluator.h", "a00842.html", "a00842"], │ │ │ │ │ + ["d3d11ComputeEvaluator.h", "a00848.html", "a00848"], │ │ │ │ │ ["d3d11LegacyGregoryPatchTable.h", "a00839.html", "a00839"], │ │ │ │ │ - ["d3d11Mesh.h", "a00830.html", "a00830"], │ │ │ │ │ + ["d3d11Mesh.h", "a00827.html", "a00827"], │ │ │ │ │ ["d3d11PatchTable.h", "a00836.html", "a00836"], │ │ │ │ │ ["d3d11VertexBuffer.h", "a00833.html", "a00833"], │ │ │ │ │ - ["glComputeEvaluator.h", "a00848.html", "a00848"], │ │ │ │ │ + ["glComputeEvaluator.h", "a00845.html", "a00845"], │ │ │ │ │ ["glLegacyGregoryPatchTable.h", "a00866.html", "a00866"], │ │ │ │ │ ["glMesh.h", "a00857.html", "a00857"], │ │ │ │ │ ["glPatchTable.h", "a00863.html", "a00863"], │ │ │ │ │ ["glslPatchShaderSource.h", "a00854.html", "a00854"], │ │ │ │ │ ["glVertexBuffer.h", "a00860.html", "a00860"], │ │ │ │ │ ["glXFBEvaluator.h", "a00851.html", "a00851"], │ │ │ │ │ - ["hlslPatchShaderSource.h", "a00824.html", "a00824"], │ │ │ │ │ + ["hlslPatchShaderSource.h", "a00830.html", "a00830"], │ │ │ │ │ ["mesh.h", "a00887.html", "a00887"], │ │ │ │ │ - ["mtlCommon.h", "a00806.html", "a00806"], │ │ │ │ │ + ["mtlCommon.h", "a00803.html", "a00803"], │ │ │ │ │ ["mtlComputeEvaluator.h", "a00821.html", "a00821"], │ │ │ │ │ - ["mtlLegacyGregoryPatchTable.h", "a00815.html", "a00815"], │ │ │ │ │ + ["mtlLegacyGregoryPatchTable.h", "a00818.html", "a00818"], │ │ │ │ │ ["mtlMesh.h", "a00812.html", "a00812"], │ │ │ │ │ ["mtlPatchShaderSource.h", "a00809.html", "a00809"], │ │ │ │ │ - ["mtlPatchTable.h", "a00818.html", "a00818"], │ │ │ │ │ - ["mtlVertexBuffer.h", "a00827.html", "a00827"], │ │ │ │ │ + ["mtlPatchTable.h", "a00815.html", "a00815"], │ │ │ │ │ + ["mtlVertexBuffer.h", "a00824.html", "a00824"], │ │ │ │ │ ["ompEvaluator.h", "a00881.html", "a00881"], │ │ │ │ │ ["ompKernel.h", "a00878.html", "a00878"], │ │ │ │ │ ["opencl.h", "a00797.html", null], │ │ │ │ │ ["opengl.h", "a00884.html", null], │ │ │ │ │ ["tbbEvaluator.h", "a00875.html", "a00875"], │ │ │ │ │ ["tbbKernel.h", "a00872.html", "a00872"], │ │ │ │ │ ["types.h", "a01489.html", "a01489"] │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_7f420b72a822828cfa8b0561c695a5cc.html │ │ │ │ @@ -95,39 +95,39 @@ │ │ │ │ │ │ │ │
│ │ │ │

│ │ │ │ Files

 bufferDescriptor.h
 bufferDescriptor.h
 
 clEvaluator.h
 clEvaluator.h
 
 clPatchTable.h
 
 clVertexBuffer.h
 
 cpuD3D11VertexBuffer.h
 cpuD3D11VertexBuffer.h
 
 cpuEvaluator.h
 cpuEvaluator.h
 
 cpuGLVertexBuffer.h
 
 cpuPatchTable.h
 
 cpuVertexBuffer.h
 
 cudaEvaluator.h
 
 cudaPatchTable.h
 
 cudaVertexBuffer.h
 
 d3d11ComputeEvaluator.h
 d3d11ComputeEvaluator.h
 
 d3d11LegacyGregoryPatchTable.h
 
 d3d11Mesh.h
 d3d11Mesh.h
 
 d3d11PatchTable.h
 
 d3d11VertexBuffer.h
 
 glComputeEvaluator.h
 glComputeEvaluator.h
 
 glLegacyGregoryPatchTable.h
 
 glMesh.h
 
 glPatchTable.h
 
 glslPatchShaderSource.h
 
 glVertexBuffer.h
 
 glXFBEvaluator.h
 
 hlslPatchShaderSource.h
 hlslPatchShaderSource.h
 
 mesh.h
 
 mtlCommon.h
 mtlCommon.h
 
 mtlComputeEvaluator.h
 
 mtlLegacyGregoryPatchTable.h
 mtlLegacyGregoryPatchTable.h
 
 mtlMesh.h
 
 mtlPatchShaderSource.h
 
 mtlPatchTable.h
 mtlPatchTable.h
 
 mtlVertexBuffer.h
 mtlVertexBuffer.h
 
 ompEvaluator.h
 
 ompKernel.h
 
 opencl.h
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Files

 error.h
 
 patchDescriptor.h
 patchDescriptor.h
 
 patchMap.h
 patchMap.h
 
 patchParam.h
 patchParam.h
 
 patchTable.h
 patchTable.h
 
 patchTableFactory.h
 patchTableFactory.h
 
 primvarRefiner.h
 primvarRefiner.h
 
 ptexIndices.h
 ptexIndices.h
 
 stencilTable.h
 stencilTable.h
 
 stencilTableFactory.h
 stencilTableFactory.h
 
 topologyDescriptor.h
 topologyDescriptor.h
 
 topologyLevel.h
 topologyLevel.h
 
 topologyRefiner.h
 topologyRefiner.h
 
 topologyRefinerFactory.h
 topologyRefinerFactory.h
 
 types.h
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_7f420b72a822828cfa8b0561c695a5cc.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,17 +1,17 @@ │ │ │ │ │ var dir_7f420b72a822828cfa8b0561c695a5cc = [ │ │ │ │ │ ["error.h", "a00743.html", "a00743"], │ │ │ │ │ - ["patchDescriptor.h", "a00737.html", "a00737"], │ │ │ │ │ - ["patchMap.h", "a00734.html", "a00734"], │ │ │ │ │ - ["patchParam.h", "a00740.html", "a00740"], │ │ │ │ │ - ["patchTable.h", "a00731.html", "a00731"], │ │ │ │ │ - ["patchTableFactory.h", "a00725.html", "a00725"], │ │ │ │ │ - ["primvarRefiner.h", "a00728.html", "a00728"], │ │ │ │ │ - ["ptexIndices.h", "a00722.html", "a00722"], │ │ │ │ │ - ["stencilTable.h", "a00719.html", "a00719"], │ │ │ │ │ - ["stencilTableFactory.h", "a00716.html", "a00716"], │ │ │ │ │ - ["topologyDescriptor.h", "a00713.html", "a00713"], │ │ │ │ │ - ["topologyLevel.h", "a00710.html", "a00710"], │ │ │ │ │ - ["topologyRefiner.h", "a00707.html", "a00707"], │ │ │ │ │ - ["topologyRefinerFactory.h", "a00701.html", "a00701"], │ │ │ │ │ + ["patchDescriptor.h", "a00740.html", "a00740"], │ │ │ │ │ + ["patchMap.h", "a00731.html", "a00731"], │ │ │ │ │ + ["patchParam.h", "a00737.html", "a00737"], │ │ │ │ │ + ["patchTable.h", "a00734.html", "a00734"], │ │ │ │ │ + ["patchTableFactory.h", "a00728.html", "a00728"], │ │ │ │ │ + ["primvarRefiner.h", "a00722.html", "a00722"], │ │ │ │ │ + ["ptexIndices.h", "a00725.html", "a00725"], │ │ │ │ │ + ["stencilTable.h", "a00713.html", "a00713"], │ │ │ │ │ + ["stencilTableFactory.h", "a00719.html", "a00719"], │ │ │ │ │ + ["topologyDescriptor.h", "a00716.html", "a00716"], │ │ │ │ │ + ["topologyLevel.h", "a00707.html", "a00707"], │ │ │ │ │ + ["topologyRefiner.h", "a00704.html", "a00704"], │ │ │ │ │ + ["topologyRefinerFactory.h", "a00710.html", "a00710"], │ │ │ │ │ ["types.h", "a01486.html", "a01486"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_f61368944c63c2c1f8c69bc232e59c39.html │ │ │ │ @@ -95,17 +95,17 @@ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_f61368944c63c2c1f8c69bc232e59c39.js │ │ │ │ ├── js-beautify {} │ │ │ │ │ @@ -1,9 +1,9 @@ │ │ │ │ │ var dir_f61368944c63c2c1f8c69bc232e59c39 = [ │ │ │ │ │ ["bilinearScheme.h", "a00785.html", null], │ │ │ │ │ - ["catmarkScheme.h", "a00779.html", null], │ │ │ │ │ - ["crease.h", "a00782.html", "a00782"], │ │ │ │ │ + ["catmarkScheme.h", "a00782.html", null], │ │ │ │ │ + ["crease.h", "a00779.html", "a00779"], │ │ │ │ │ ["loopScheme.h", "a00776.html", null], │ │ │ │ │ ["options.h", "a00773.html", "a00773"], │ │ │ │ │ ["scheme.h", "a00770.html", "a00770"], │ │ │ │ │ ["types.h", "a01492.html", "a01492"] │ │ │ │ │ ]; │ │ │ ├── ./usr/share/doc/opensubdiv/doxy_html/dir_fa5edef2a780a73fbfb6a11f1af88ceb.html │ │ │ │ @@ -107,17 +107,17 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Files

 bilinearScheme.h
 
 catmarkScheme.h
 catmarkScheme.h
 
 crease.h
 crease.h
 
 loopScheme.h
 
 options.h
 
 scheme.h
 
 
 surfaceFactory.h
 
 surfaceFactoryCache.h
 
 surfaceFactoryMeshAdapter.h
 
 tessellation.h
 tessellation.h
 
 vertexDescriptor.h
 vertexDescriptor.h
 
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │
│ │ │ │
│ │ │ │ Classes | │ │ │ │ Namespaces
│ │ │ │ -
topologyRefinerFactory.h File Reference
│ │ │ │ +
topologyRefiner.h File Reference
│ │ │ │
│ │ │ │
│ │ │ │
#include "../version.h"
│ │ │ │ -#include "../far/topologyRefiner.h"
│ │ │ │ -#include "../far/error.h"
│ │ │ │ -#include <cassert>
│ │ │ │ +#include "../sdc/types.h"
│ │ │ │ +#include "../sdc/options.h"
│ │ │ │ +#include "../far/types.h"
│ │ │ │ +#include "../far/topologyLevel.h"
│ │ │ │ +#include <vector>
│ │ │ │
│ │ │ │ -

Go to the source code of this file.

│ │ │ │ +

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ - │ │ │ │ - │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │

│ │ │ │ Classes

class  TopologyRefinerFactoryBase
 Private base class of Factories for constructing TopologyRefiners. More...
class  TopologyRefiner
 Stores topology data for a specified set of refinement options. More...
 
class  TopologyRefinerFactory< MESH >
 Factory for constructing TopologyRefiners from specific mesh classes. More...
struct  TopologyRefiner::UniformOptions
 Uniform refinement options. More...
 
struct  TopologyRefinerFactory< MESH >::Options
 Options related to the construction of each TopologyRefiner. More...
struct  TopologyRefiner::AdaptiveOptions
 Adaptive refinement options. More...
 
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ + │ │ │ │ + │ │ │ │ │ │ │ │ │ │ │ │

│ │ │ │ Namespaces

namespace  OpenSubdiv
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Vtr
 
namespace  OpenSubdiv::OPENSUBDIV_VERSION::Far
 
│ │ │ │
│ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ │ @@ -1,34 +1,37 @@ │ │ │ │ │ [Logo] OpenSubdiv │ │ │ │ │ Loading... │ │ │ │ │ Searching... │ │ │ │ │ No Matches │ │ │ │ │ _C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ │ -topologyRefinerFactory.h File Reference │ │ │ │ │ +topologyRefiner.h File Reference │ │ │ │ │ #include "../version.h" │ │ │ │ │ -#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h" │ │ │ │ │ -#include "_._._/_f_a_r_/_e_r_r_o_r_._h" │ │ │ │ │ -#include │ │ │ │ │ +#include "_._._/_s_d_c_/_t_y_p_e_s_._h" │ │ │ │ │ +#include "_._._/_s_d_c_/_o_p_t_i_o_n_s_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_y_p_e_s_._h" │ │ │ │ │ +#include "_._._/_f_a_r_/_t_o_p_o_l_o_g_y_L_e_v_e_l_._h" │ │ │ │ │ +#include │ │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ │ CCllaasssseess │ │ │ │ │ - class   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_B_a_s_e │ │ │ │ │ -  Private base class of Factories for constructing TopologyRefiners. │ │ │ │ │ + class   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r │ │ │ │ │ +  Stores topology data for a specified set of refinement options. │ │ │ │ │ _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ - class   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_ _M_E_S_H_ _> │ │ │ │ │ -  Factory for constructing TopologyRefiners from specific mesh classes. │ │ │ │ │ - _M_o_r_e_._._. │ │ │ │ │ +struct   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_U_n_i_f_o_r_m_O_p_t_i_o_n_s │ │ │ │ │ +  Uniform refinement options. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ -struct   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_<_ _M_E_S_H_ _>_:_:_O_p_t_i_o_n_s │ │ │ │ │ -  _O_p_t_i_o_n_s related to the construction of each _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r. _M_o_r_e_._._. │ │ │ │ │ +struct   _T_o_p_o_l_o_g_y_R_e_f_i_n_e_r_:_:_A_d_a_p_t_i_v_e_O_p_t_i_o_n_s │ │ │ │ │ +  Adaptive refinement options. _M_o_r_e_._._. │ │ │ │ │   │ │ │ │ │ NNaammeessppaacceess │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v │ │ │ │ │   │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N │ │ │ │ │   │ │ │ │ │ +namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_V_t_r │ │ │ │ │ +  │ │ │ │ │ namespace   _O_p_e_n_S_u_b_d_i_v_:_:_O_P_E_N_S_U_B_D_I_V___V_E_R_S_I_O_N_:_:_F_a_r │ │ │ │ │   │ │ │ │ │ * _o_p_e_n_s_u_b_d_i_v │ │ │ │ │ * _f_a_r │ │ │ │ │ - * _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_F_a_c_t_o_r_y_._h │ │ │ │ │ + * _t_o_p_o_l_o_g_y_R_e_f_i_n_e_r_._h │ │ │ │ │ * Generated on Sat Jan 6 2024 14:18:14 for OpenSubdiv by _[_d_o_x_y_g_e_n_]1.9.8