Commit Graph

33 Commits

Author SHA1 Message Date
barfowl
04de3a37d9 Missed a few corrections in the previous commit. 2015-05-21 20:14:46 -07:00
barfowl
6d5b29c2dc Replacing use of old Far::TopologyRefiner methods with Far::TopologyLevel 2015-05-21 19:52:25 -07:00
barfowl
40832a0f0d Amendment to previous commit deprecating PatchTables::Evaluate methods:
- replaced Evaluate() with EvaluateBasis() in far/tutorial_6
    - commented out use of EvaluateFaceVarying() in examples/farViewer
        - face-varying patches are work in progress
2015-05-20 16:40:32 -07:00
Takahito Tejima
74b78b3d17 Refactor again FarPatchTableFactory.
- rename "Regular end cap" to "BSplineBasis end cap"
- revert templating and add EndCapType into PatchTablesFactory::Options.
- make EndCapFactories internal in PatchTablesFactory.
- move end cap stencils into PatchTables, keep them relative to the max level.
- add a utility StencilTablesFactory::AppendEndCapStencilTables to splice and factorize endcap stencil tables.
2015-04-23 16:58:56 -07:00
Jeremy Cowles
9f88363d07 Merge pull request #436 from takahito-tejima/dev
Fixes far_tutorial_6 crash
2015-04-22 20:30:47 -07:00
George ElKoura
0371a3aa5f Renamed methods on Far::PtexIndices.
GetNumPtexFaces() became GetNumFaces()
GetPtexIndex() became GetFaceId()
GetPtexAdjacency() became GetAdjacency()
2015-04-21 22:23:22 -07:00
George ElKoura
420473b45b Experiment separating out Ptex from TopologyRefiner.
Remove the ptex-specific code from the Far::TopologyRefiner and instead provide it in a separate class Far::PtexIndices.  Clients who need to use the Ptex API need to first build a Far::PtexIndices object by providing it with a refiner.

This has the advantage of keeping the API on the TopologyRefiner a little cleaner.  The ptex methods were const but were mutating state with const_casts.  The new mechanism still achieves the same lazy initialization behavior by forcing clients to instantiate them exactly when needed.

A disadvantage of this approach is that the PatchTablesFactory creates its own PtexIndices and throws it out after the patch tables are created.  This is great if you're never going to need the ptex indices again, but not so great if you will need them again.
2015-04-21 17:34:02 -07:00
takahito-tejima
c4acb578f2 Fixes far_tutorial_6 crash 2015-04-21 15:38:51 -07:00
Takahito Tejima
6e6e8040b7 CMakeLists: add enable_testing/add_test 2015-04-16 10:52:08 -07:00
jcowles
cc5a9e891c Fixed more array indexing issues in examples/tutorials 2015-03-12 12:32:30 -07:00
jcowles
aba0ef9692 Fix array index typos in tutorials 2015-03-12 11:14:23 -07:00
manuelk
d0a624f373 Add "smooth UVs" to Far
- extend Far::PatchTables data structures & interfaces to store requisite
  information for channels of face-varying bi-cubic patches
- implement gather function in Far::PatchTablesFactory to populate face-varying
  channels with adaptive patches
- extend accessor interface in Vtr::Level
- propagate code fall-out throughout OpenSubdiv code base, examples & tutorials
- extend vtrViewer code to visualize tessellated bi-cubic face-varying patches
2015-02-26 13:57:47 -08:00
barfowl
1de732e6fa Updated far/tutorial_1 for recent changes to Far::TopologyRefinerFactory<MESH> 2015-01-07 21:39:22 -08:00
barfowl
9bb98a94fd Renaming of a few Sdc types and constants:
- renamed Sdc::Type to SchemeType and TypeTraits to SchemeTypeTraits
    - renamed TYPE_ prefix to SCHEME_
    - updated all usage within core library
    - updated all usage in examples, tutorials, etc.
2015-01-06 17:40:11 -08:00
barfowl
865fe5591f Modified Far::TopologyRefinerFactory<>::Create() take new Options as argument
- update examples, tutorials, regressions, etc. accordingly
2015-01-06 00:03:21 -08:00
barfowl
127152a511 Cleaned up protected access to TopologyRefiner from its Factories:
- fixed naming consistency of protected methods used by Factory
    - removed other unused and/or redundant protected methods
    - update Far Factories to reflect changes to Refiner methods
    - updated usage in tutorials and regression
2015-01-04 16:33:18 -08:00
manuelk
bfbd868fe2 Modify Far::TopologyRefiner refinement options
- move level of refinement / isolation into the Options structs
- fix splash damage in rest of the code

note 1: this is less than ideal, because most compilers accept the previous
        call to these functions with an incorrect parameter list (ie. passing
        the level instead of the struct issues no warnings and compiles...)
        caveat emptor...

note 2: the level parameter names may not be final for adaptive modes
        as we will likely want independent controls over crease vs.
        extraordinary vertex isolation.
2014-12-30 14:07:24 -08:00
manuelk
5944ada0f9 Add Options structs to Far::TopologyRefiner refinement methods
- fix all splash damage to tutorials / examples...
2014-12-23 10:07:24 -08:00
manuelk
88bbdee64f Fix build warning in far_tutorial_1 2014-12-20 14:32:00 -08:00
manuelk
4b6db70539 Fix Windows build 2014-12-15 11:24:45 -08:00
manuelk
48cf4b6528 Refactor Vtr::Array for better "const" safety
Const' declared instances of Vtr::Array do not protect the pointer held
privately by the class properly. In order to force the compiler to
protect this pointer, we removed all non-const accessors from Vtr::Array
(now renamed Vtr::ConstArray) and moved them to a child class (Vtr::Array),
which requires const_cast<> operators internally to allow access.

The change & renaming is then propagated to all internal dependencies.
2014-12-15 10:23:13 -08:00
manuelk
9a3a88546d Rename some members of Far::TopologyRefinerFactory::TopologyDescriptor for consistency
- propagate changes to tutorials / examples
2014-12-12 11:19:24 -08:00
manuelk
ce55f56d50 Rename Sdc::Options vertex boundary interpolation rule enums
- VVarBoundaryInterpolation is now VtxBoundaryInterpolation
- enum prefix change from VVAR to VTX
- generel cleanup / doxyfication
- update of beta / release notes
2014-12-12 11:10:17 -08:00
manuelk
cbb02fd3ce Fix tutorial include paths
- now prettier with <opensubdiv> prefix
2014-12-11 10:14:46 -08:00
manuelk
c10e18a035 Add cascading stencils Far tutorial 2014-11-18 16:52:32 -08:00
manuelk
f145f70fd2 Refactor Far::StencilTablesFactory
- re-implement the pool allocator
    - use templates to remove code redundancy between regular & limit stencils
    - leverage [] operator overloading to simplify stencil factorization
    - add the ability to treat subdivision levels independently (see below)

- refactor Far::TopologyRefiner::Interpolate<>() methods to pass buffers by reference
  (allows overloading of [] operator)

- rename some of the stencil factory options
- propagate changes to Osd / examples / tutorials...
2014-10-21 16:36:26 -07:00
manuelk
8fea836eb1 Fix far_tutorial_2 : remove redundant Vertex copy constructor
fixes #359
2014-10-16 12:01:14 -07:00
manuelk
c30087cb52 Fix face-varying code in examples / tutorials to reflect changes in commit 4d84dfd7be 2014-10-10 11:57:43 -07:00
manuelk
f7b21b941c Add far_tutorial_6 showing how to interpolate primvar data on the surface
limit at arbitrary locations.
2014-09-22 13:51:59 -07:00
Nathan Litke
1d0378774a Fixed a bug in far_tutorial_3 which had set the number of face-varying values to the number of per-face vertices, not the number of uvs. 2014-09-17 13:34:02 -07:00
Manuel Kraemer
20438e0253 Fix MSVC build for far_tutorial_1 (linker error)
- typo in previous fix disabled the code instead of enabling...
2014-09-07 15:21:57 -07:00
Manuel Kraemer
f060f3a877 Fix MSVC build for far_tutorial_1 2014-09-06 17:53:09 -07:00
manuelk
c399655dcc Landing 3.0.0.alpha
Sync'ing the 'dev' branch with the 'feature_3.0dev' branch at commit 68c6d11fc36761ae1a5e6cdc3457be16f2e9704a

The branch 'feature_3.0dev' is now locked and preserved for historical purposes.
2014-09-05 15:07:46 -07:00