Commit Graph

1324 Commits

Author SHA1 Message Date
David G Yu
141cd19673
Merge branch 'dev' into dev-no-framework-option 2022-09-02 18:10:23 -07:00
David G Yu
4a75c5577a
Merge pull request #1254 from barfowl/gcc_warnings_bitfields
Suppression of GCC warnings from -Wconversion with bitfields
2022-09-02 15:51:11 -07:00
Barry Fowler
887ee04572 Added more methods to Far::TopologyLevel:
- test if a vertex is a corner (one incident face)
    - test if valence of a vertex is regular
    - tests if a vertex is semi- or inf-sharp
    - tests if an edge is semi- or inf-sharp
2022-09-02 12:56:29 -07:00
David G Yu
4f5b15ca26
Merge pull request #1244 from diekev/dev-ogl-program-cache
OpenGL Compute Evaluator: cache active program
2022-08-30 14:40:18 -07:00
Barry Fowler
8b863a0009 Fix GCC warnings with -Wconversion and bitfields:
- apply bitmask in member initialization to suppress warning
    - add public Set...() with bitmask for assignment by users
    - replace any assignments with new public Set...() methods
2022-08-30 14:34:17 -07:00
Barry Fowler
57847e625c Fix GCC warnings with -Wshadow and -Wconversion:
- suppressed -Wshadow in libraries, tutorials and regressions
    - suppressed -Wconversion when casts to simple POD type required
2022-08-30 12:56:59 -07:00
Barry Fowler
810d7f671b Fix GCC warnings with current default flags:
- default flags include warnings enabled by -Wall and -Wextra
    - suppressed newer warnings in public headers and internal files
      (-Wclass-memaccess, -Wcast-function-type, -Wdeprecated-copy)
    - suppressed -Wunused-function from internal source files
2022-08-30 12:13:44 -07:00
Barry Fowler
647309a7d7 Improved mixed partial at Gregory patch corners:
- normalized the rational weights for pairs of interior points
    - fixed sign swap error in mixed partial of bilinear patches
    - applied changes to both far/patchBasis and osd/patchBasisCommon
2022-08-25 18:40:33 -07:00
David G Yu
7b8728a3f4
Merge branch 'dev' into dev-mac-subproject 2022-08-07 17:12:10 -07:00
Barry Fowler
a1c7be7c8e Addition of Bfr interface (1 of 4): opensubdiv/bfr
This set of commits includes the addition of a new evaluation interface
that treats a subdivision mesh more like a piecewise parametric surface
primitive.  The new interface was placed in namespace "Bfr" for "Base
Face Representation" as all concepts and classes relate to a single face
of the base mesh.
2022-08-02 20:38:17 -07:00
Kévin Dietrich
38fe09c701 OpenGL Compute Evaluator: cache active program
Client applications may keep track of the active shader program so as to
not unnecessarily bind and unbind the same shader consecutively as
switching shaders is costly.

The current behavior of the OpenGL compute evaluator is to set the
active shader to 0 (zero) after running its program(s) which might
interfere with the aforemoentioned client applications' behavior,
leading to bugs.

Instead of unsetting any previously set shader program, cache the
current program before using the evaluator program, and reset the active
program to the previous one when done.

In Blender, this lead to some rendering artifacts. See https://
developer.blender.org/D15064 for more details on it.
2022-06-26 18:08:38 +02:00
David G Yu
a91707bae8 Fixed subobject initialization warnings
Fixed a few code sites where subobject initializers were missing braces.
2021-10-20 14:55:59 -07:00
Thomas Thomassen
beb095d7e3 Add option to not generate frameworks under macOS. Ref #1236 2021-10-20 20:35:40 +02:00
Thomas Thomassen
3fdcb02cd3 Use PROJECT_SOURCE_DIR instead of CMAKE_SOURCE_DIR. 2021-10-06 23:21:22 +02:00
Caroline Lachanski
ff76e0f2dc Release 3.4.4 2021-02-05 17:24:39 -08:00
David G Yu
bb0b366cb7 Fixed macOS static framework
Assigned the postfix "_static" to the static framework
and also fixed header installation. This makes the static
framework usable and also fixes build errors when using
recent versions of CMake. Also fixes build errors that
can occur when building with multiple threads.
2021-02-03 10:08:08 -08:00
David G Yu
62ddd17bcb
Merge pull request #1208 from barfowl/far_unrefine_maxlevel_bug
Fixed Far::TopologyRefiner::GetMaxLevel() after call to Unrefine()
2021-01-26 14:41:40 -08:00
David G Yu
0d117082fd
Merge pull request #1207 from barfowl/far_stencil_precision_bug
Fixed bug in double precision template for Far::StencilTableFactory
2021-01-26 14:32:57 -08:00
Barry Fowler
03c19c7194 Fixed Far::TopologyRefiner::GetMaxLevel() after call to Unrefine():
- reset _maxLevel member to 0 in Unrefine()
2020-10-24 17:21:18 -07:00
Barry Fowler
75e31d88d6 Fixed bug in double precision template for Far::StencilTableFactory:
- added missing template parameter with use of Far::PrimvarRefiner
2020-10-24 17:20:38 -07:00
Barry Fowler
c1dd0bdfca Fixed bug in sparse refinement where face-varying topology differs:
- do not select face if incomplete, i.e. not descended from specified face
2020-10-24 17:19:08 -07:00
David G Yu
82ab1b9f54 Release 3.4.3 2020-04-01 23:04:53 -07:00
David G Yu
e7dfecc3bf Additional fixes for dynamic and static linking
Updated to link the GL loader objects directly
along with the osd GPU objects for both static
and dynamic libraries.
2020-04-01 21:54:21 -07:00
David G Yu
0ca74b2e8e Release 3.4.2 2020-04-01 17:21:33 -07:00
David G Yu
b93725be26 Fixed static library linking on Windows
Changed the glLoader library to an object library
instead of a static library to improve generating
opensubdiv static libraries.
2020-04-01 12:13:36 -07:00
David G Yu
e6963dac5a Release 3.4.1 RC1 2020-03-23 18:23:51 -07:00
David G Yu
cb596ffb8a Added option to control building shared libraries
This adds support for the standard global option
  BUILD_SHARED_LIBS
to select whether to build shared libraries.

Note that building shared DLL libraries is still
not yet supported on Windows.
2020-03-09 17:50:49 -07:00
David G Yu
82988d04ad Updated EXT to ARB for GL direct_state_access
The ARB_direct_state_access API is more consistent with
the 4.5 and 4.6 core API and is also more widely supported.
2020-03-06 11:37:55 -08:00
David G Yu
f3f28995a5 Enabled internal GL API loader as GLEW alternative
At build time, the preprocessor symbols: OSD_USES_GLEW or
OSD_USES_INTERNAL_GLAPILOADER determine the GL API loader
that will be used by the OSD library.
2020-03-06 11:37:55 -08:00
Pol
e7ef20dacd
Merge pull request #1183 from davidgyu/dev_internal_glloader_prep
Prepare to replace GLEW with internal GL API Loader
2020-03-03 20:50:05 -05:00
David G Yu
28f2574bc5 Moved GLEW dependencies to glLoader wrapper
This introduces an internal glLoader library which allows
most of the implementation to be agnostic about the
implementation of the GL loading library.  Specifically,
this removes references to the GLEW headers and libraries
from the rest of the source code and build system.
2020-03-03 17:10:30 -08:00
David G Yu
6dde62d48f Fixed strict-aliasing warnings
Minor update to the implementation of a few internal tagging
methods in Vtr to avoid violating strict-aliasing rules.
Specifically, switched to using std::memcpy instead of
reinterpret_cast to implement type punning.
2020-02-28 16:28:33 -08:00
George ElKoura
69af58f7aa
Merge pull request #1174 from davidgyu/dev_ptex_dependency_fix
Fixed Ptex link dependencies
2020-01-15 18:10:12 -08:00
David G Yu
552ebf1376 Fixed Ptex link dependencies
Removed the link dependency from libosd to
the Ptex library since Ptex is used only by the
examples. Updated examples/common to separate
the common Ptex sources from the other common
sources so that they are used only by the Ptex
examples.
2020-01-15 14:47:18 -08:00
barry
8b065abb90 Formatted the modified source file to adhere to 80-column standard 2020-01-13 18:07:23 -08:00
barry
eed095ae15 Updated documentation related to boundary interpolation case "none":
- updated user documentation describing the enum
    - updated the Doxygen comments in sdc/options.h
2020-01-10 14:26:51 -08:00
barry
5a0e16e65d Revised tagging of boundary faces as holes if explicitly sharpened:
- tag faces containing vertices with an unsharpened incident boundary edge
2020-01-10 14:14:22 -08:00
George ElKoura
92341f7c1e Prefix OpenSubdiv CMake macros
This fixes issue #1157 by adding "osd" as a prefix to public macros.
2019-08-17 16:44:30 -07:00
David G Yu
1b556809c3 Merge remote-tracking branch 'origin/dev' into rc/v3_4_0 2019-06-24 20:19:28 -07:00
David G Yu
5c8cdf9121 Fixed regression in MTLComputeEvaluator
Fixed the initialization of patchArray and patchParam
in the implementation of the MTLComputeEvaluator::EvalPatches()
compute kernel.
2019-06-24 16:47:56 -07:00
barry
5e1a4b44be Minor improvements to Doxygen comments for Far header files:
- minor changes to Doxygen comments based on feedback
    - new description for PatchTableFactory::Options::EndCapType
    - fixed warnings related to Doxygen use of <REAL> in patchTable.h
2019-06-20 13:56:54 -07:00
barry
6d3e1b02af Added condition to compensate for incorrect FVar corner tags:
- re-assess corner tags for irregular patches on FVar boundaries
2019-06-18 11:24:23 -07:00
barry
69ab4d6170 Fixed Loop patch creation bug with val-3 interior vertex at third corner:
- adjusted point-sharing logic in PatchBuilder::SourcePatch to correct
2019-06-14 11:28:22 -07:00
David G Yu
001029f352 Release 3.4.0 RC1 2019-06-10 17:48:17 -07:00
David G Yu
f881c49a5b Minor revisions to some Osd deprecation notes
Several of the methods in osd/patchBasisCommon.h were
never intended as public API, and several have been
deprecated in favor of the newer OsdEvaluatePatchBasis()
and OsdEvaluatePatchBasisNormalized() methods. These
obsolete methods have now all be marked as deprecated.

Also, fixed a minor spelling typo in glslPatchBasisCommon.glsl
2019-06-10 15:29:03 -07:00
David G Yu
943f1a8886
Merge pull request #1117 from barfowl/far_api_revisions
Minor revisions to a few precision related methods of Far classes
2019-06-07 20:56:57 -07:00
barry
b2d610fd56 Minor revisions to some precision related methods of Far classes:
- renamed PatchTable methods to query the precision of its StencilTables
    - removed the "set" prefix from precision-related PatchTableFactory::Options
2019-06-07 18:40:53 -07:00
barry
cb79eab120 Improved Loop regular patch approximations of irregular features:
- updated LoopPatchBuilder with new Gregory to Box-spline conversion matrix
2019-06-07 17:55:31 -07:00
David G Yu
67cc2a3810 Irregular patch shader transition edges
Updated the Gregory patch tessellation shaders to account for
transition edges.

Changed the implementation of OsdGetTessParameterizationTriangle()
to take the input parametric location as a 3-component value. This
allows the edge parameterization to be more numerically robust and
consistent.

Also, corrected some minor discrepancies between the various
tessellation shader configurations.
2019-06-03 15:34:40 -07:00
David G Yu
17bc75b488 Compute transition mask for irregular patches
The irregular patches around extraordinary vertices
might have transitions edges depending on the secondary
refinement level specified during topological refinement.

We used to skip the computation of the transition mask
for irregular patches, but this is now necessary
since the introduction of the secondary level option.
2019-05-30 12:12:53 -07:00