Commit Graph

32 Commits

Author SHA1 Message Date
manuelk
13e9136b63 Remove Hbr from doxygen docs 2014-12-22 11:50:41 -08:00
manuelk
5ff9edf4f9 Decrease compiler warning thresholds and fix outstanding warnings.
Note: this round fixes clang / gcc -Wetra warnings. More fixing remains for icc -w3 errors.
2014-05-15 13:34:32 -07:00
mkraemer
05a7db5e14 Make CMake path variables more robust
Add quotes around variables containing paths - this might require a second pass...

fixes #258
2014-04-09 16:43:38 -04:00
manuelk
c3cb17fa99 Modify Far remapping of singular vertices to point to their source vertex.
- Add a vector of index pairs to HbrMesh to track the index of a split
  vertex and its origin vertex
- Correct the Far remap tables in FarSubdivisionTablesFactory to point split
  vertices to their origin instead of themselves
- Fix regression/common/shape_utils.h to use the new HbrMesh::GetSplitVertices()
  method.
- Fix the osdPolySmooth example to use the new HbrMesh::GetSplitVertices()
  method.
- Add a paragraph to the documentation

fixes #241
2013-11-21 16:05:31 -08:00
manuelk
2dc8520938 Fix Chaikin rule
The Chaikin crease interpolation mode seems to be broken:
	   - Catmark / Loop / Bilinear are passing the wrong halfedge vertex to the
	     SubdivideCreaseWeight function which results in sub-edge crease weights
	     being swapped
	   - the loop that iterates over adjacent edges needs to check against both
	     the original edge and its opposite, otherwise it may be incorrectly
	     accumulated into summation of these adjacent edges (with a 0.25 weight)

	   The proposed fix:
	   - Swaps the Dest/Org vertex passed to the SubdivideCreaseWeight (and
	     we probably want Julian to confirm that this the correct fix)
	   - Checks against both the original edge and its opposite in the iteration
	     over adjacent edges
	   - Replaces the std::vector based query with an HbrHalfedgeOperator for
	     better performance (hopefully)

	   The similar fix to OpenSubdiv been reviewed by Tony DeRose.

    Also in the fix:
        - fix "obj" tag parsing of the smooth triangle tag that was incorrectly
          associated with the crease method (and reporting the wrong errors)
        - add regression shapes for both Loop & Catmark schemes to hbr_regression
        - add same shapes to the glViewer
        - improve hbr_regression output to be more readable
        - add command-line argument parsing to hbr_regression
        - add functionality to dump an obj file when regression fails for comparison

fixes #235
2013-11-07 17:06:55 -08:00
manuelk
404ec9649d Fix edge-only face-varying interpolation.
For face-varying interpolation, sharpness should be interpreted as an
infintely sharp boundary. Hbr implements this correctly for vertex
sharpness, but inconsistently for edge sharpness: both the fvarbits
cache and methods that gather face-varying sharpness need to be corrected.

fixes #231
2013-10-22 09:43:50 -07:00
manuelk
3ae50d1c50 Amending Apache license language & file headers.
New text:

     Copyright 2013 Pixar

     Licensed under the Apache License, Version 2.0 (the "Apache License")
     with the following modification; you may not use this file except in
     compliance with the Apache License and the following modification to it:
     Section 6. Trademarks. is deleted and replaced with:

     6. Trademarks. This License does not grant permission to use the trade
        names, trademarks, service marks, or product names of the Licensor
        and its affiliates, except as required to comply with Section 4(c) of
        the License and to reproduce the content of the NOTICE file.

     You may obtain a copy of the Apache License at

         http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the Apache License with the above modification is
     distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     KIND, either express or implied. See the Apache License for the specific
     language governing permissions and limitations under the Apache License.
2013-09-26 12:04:57 -07:00
manuelk
7d4999c46e Adding support for subdivision stencils.
- Adding FarStencilTables and FarStencilTablesFactory classes
- Adding Osd EvalStencil context & controllers for CPU, OMP and TBB backends
- Adding the code example glStencilViewer
- Adding reST documentation
- Changing version to 2.2.0_dev
- Fix HbrMesh::Unrefine function
- Fix "CanEval" function in OsdVertexBufferDescriptor

Note 0: there is no stencil support for hierarchical edits

Note 1: there is no support for face-varying data stencils yet

Note 2: the current stencil factory is lazy but the caching system is not re-entrant
2013-09-11 16:05:14 -07:00
Takahito Tejima
51a45b598d Updating EULA 2013-07-18 14:19:50 -07:00
manuelk
845a036693 make copy constructors private for HbrHalfedge and HbrFVarData
fixes #194
2013-07-18 09:07:28 -07:00
manuelk
9712b44239 Documentation build modifications:
- add macro "_add_doxy_headers" in order to track all header files elligible for
  doxygen documenation. This captures public header files that would otherwise be
  excluded from installation because they are not supported by the OS. Private
  header files remain excluded though.

- add custom targets and commands so that documentation build produces functioning
  RST and Doxygen documentation both in the build and install stages

- switched to Doxygen 1.8 (because markdown will make in-lined documentation easier)

- added build switches to disable examples, regression and python-SWIG targets

- fixed doxygen link in the nav bar

- modified python html processing tool to match Cmake changes
2013-07-05 15:36:54 -07:00
manuelk
ad3bacbbbb remove topology data from FarMesh and refactor uniform / adaptive
code paths using FarPatchTables for all serialized topological data.
2013-05-15 17:53:40 -07:00
manuelk
b815aff333 First pass at fixing the installation part of the Cmake build : now CMAKE_INSTALL_PREFIX can
be used as intended to specify an installation directory, which can be located anywhere on the
file system.

Also improved the doxygen target and made the doxy build "quiet".

fixes #154
2013-04-22 19:35:41 -07:00
manuelk
d73d74f70b "const" the vertex index pointer in HbrMesh::NewFace (request from sbrew) 2013-03-06 14:31:15 -08:00
manuelk
ea1a87441f Add support for hierarchical hole edits.
- add tag parsing for h-hole in shape_utils
- re-create Renderman's test shape from the documentation (catmark_square_hedit.h)
- fix Hbr to correctly pass the hole tag from parent to child face
- fix FarSubdivisionTables to handle disconnected face-vertices without crashing

fixes #75
2013-03-01 18:27:19 -08:00
manuelk
25f79e7ff2 - change adaptive refinement in FarMeshFactory to not refine inside holes,
while retaining a necessary 1-ring on the inside of a hole edge

- add IsInsideHole() function to HbrHalfEdge

- add HasChild() function to HbrVertex and HbrHalfedge

- add a regression shape with adjacent holes and creases (tests dart, crease & boundaries)

Note : this does not address hierarchical edits inside holes or hole tags in hierarchical edits

fixes #78
2013-02-20 14:12:09 -08:00
manuelk
a52c70ab8b First pass implementation of holes :
- make sure HBR passes down the hole tag to children when subdividing faces
- minor API modification : allow to unset the hole flag on a face
- modify uniform / adaptive FarMeshFactory to be aware of the flag
- make the FarSubdivisionTableFactory assert when finding unconnected HBR vertices (as it should)

* Uniform subdivision :
    The refinement scheme only creates faces & vertices necessary
    to maintain the one-ring around the edges of a hole, so this solution
    is quite efficient.

* Adaptive subdivision :
    At the moment we are still performing full topological analysis on holes and
    only skipping patches associated to holes. This is sub-optimal in 2 ways :
        1. the topological analysis can potentially be cranking on a lot of unnecessary
           geometry
        2. even though we may not be drawing the patches, the compute stage is still
           applying kernels on all the control vertices of these patches.
    We will have to revisit feature adaptive subdivision & holes, so keep the issue active.

fixes #78
2013-02-13 14:34:33 -08:00
Andrew Wong
329a9a7b40 hbr: fix a few more warnings 2013-02-09 23:35:01 -05:00
Andrew Wong
08ca7af0c9 hbr: fix warnings in the Hbr*Edit constructors
warning C4242: 'initializing' : conversion from 'int' to 'const unsigned char', possible loss of data
2013-02-09 23:34:59 -05:00
manuelk
9ed6ac7da8 - clean up all unused variables / constructors...
- add a -Wall flag, but leave it commented out for now until the same is done for other compilers

fixes #96
2013-01-22 14:47:46 -08:00
opensubdiv
96520b4845 Fixed a few VS2010 build warnings 2013-01-10 13:33:04 -08:00
manuelk
f9dd284be0 Some notes :
- still need to change these changes with other compilers (MSVC / clang...)

- had to add a -Wno-invalid-offsetof for GCC (still need to test w/ other compilers) : apparently gcc 4.4 is somewhat incorrect in tagging our templated class as POD.

- had to change fvarData.h to initialize bitfields to 0 as gcc generates truncated int warnings when trying to initialize 31 bits to -1

- in mesh.h replaced original tbb::concurrent_vector with std::vector until a better solution can be found

Fixes #93
2013-01-10 10:47:50 -08:00
manuelk
10c687ecd5 Release Candidate 1.0 :
- [Feature Adaptive GPU Rendering of Catmull-Clark Surfaces](http://research.microsoft.com/en-us/um/people/cloop/tog2012.pdf).

- New API architecture : we are planning to lock on to this new framework as the basis for backward compatibility, which we will enforce from Release 1.0 onward. Subsequent releases of OpenSubdiv should not break client code.

- DirectX 11 support

- and much more...
2012-12-10 17:15:13 -08:00
manuelk
9d37554969 Making CMakeLists more consistent 2012-09-12 15:01:32 -07:00
Julian Fong
0866814fb3 HbrFace::Unrefine() needs to work with new face allocation strategy. 2012-08-20 13:29:05 -07:00
Julian Fong
59edf56416 Change container get methods (HbrMesh::GetVertices, etc) to take
output iterators instead of std::vector - eases prman integration
for cases where std::list makes more sense.

Block allocate face children array in common case (<= 4 children).

Other, minor consistency edits.
2012-08-20 13:21:12 -07:00
manuelk
3c16c2c18f Good catch - in practice this should be pretty hard to get into... but
better safe than sorry.

Closes #46
2012-08-10 15:24:04 -07:00
manuelk
e2217e182c From now on, hbr assumes that its clients will provide the defition of a
mutex class with Lock / Unlock public functions.

- remove Mutex implementation from Hbr (and revert to original PRman code)
- provide a Mutex class stub in osd
- add some forward declarations in OsdMesh to limit some of the mutex spills
- #include <osd/mutex.h> where needed (little hackish until we can refactor
some of far better)
- remove ILM_BASE from some CMakeLists

Closes #48
2012-08-10 15:14:02 -07:00
Takahito Tejima
e3d939ee61 fix for win64 build 2012-08-03 20:15:24 -07:00
manuelk
a1552cfe82 Siggrpah 2012 - rolling over all of prepro work into beta 1.1 2012-08-03 19:51:27 -07:00
manuelk
7a6fd95f6b Move Hbr behind the OpenSubdiv namespace
Fix all regressions / plugins.

Closes #3.
2012-06-14 18:47:57 -07:00
Manuel Kraemer
dcb6572ae9 Base check-in of Hbr / Far 2012-06-08 11:18:20 -07:00