- move python build section into the python directory (cleaning up)
- fix some broken dependencies
- remove the public_headers targets if doxygen was not found
TODO :
- fix MSVC targets for public headers (wbn if MSVC didn't require the pro version
in order to support solution folders)
- fix osd_regression to not build if -DNO_LIB is present (ie. fix the broken dependency)
- 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
- Added OSD_ prefix to preprocessor symbols
- Adjusted transition sub-patch parameterization to be
consistent with non-transition patches
- Unified BSpline shader code
- Removed duplicate Boundary, Corner, and Transition shader source
- Fixed a few discrepancies in the remaining duplicate code paths
- Replaced EvalData and EvalVertexData classes with a simpler DataStream class that only
accesses a single data stream, binds and unbinds it
- DataStream has both an input and an output version which avoids much of the const-ness
const-related ambiguity of the previous design pattern
- Vertex, varying and face-varying data now all have a dedicate struct (VertexData, VaryingData, FaceVaryingData)
as a way of gathering the various data-streams required to perform sampling
- renamd some "Buffers" into "Tables" for better naming consistency with Far
- remove PatchMap from FarPatchTables
- add a new FarPatchMap quad-tree class (constructed from FarPatchTables)
- refactor the EvalLimitController to use the quad-tree search instead of a
serial loop access
fixes#174
- defined a fallback value for ROTATE
- made GetPatchLevel() a macro to avoid
referencing gl_PrimitiveID from vertex shaders
- fixed float array initializers
- minor refactoring of the LimitEvalContext to accomodate all the data buffers
- pushing some minor sub-patch functionality back to FarPatchParams
- extend example code with randomly generated varying vertex colors
adding an arbitrary break if vertex valence is > 256
- add a Warning function to Osd error reporting
- minor cleanup /refactor / document of OsdError
fixes#167
and adding the requisite accessors
Note : all our example code goes through the same boiler-plate texture
binding code - we might want to move it as a member function of the DrawContext.
- added boundary / corner kernel code
- bug fixes for Gregory patch kernel
- wired the new kernels in the controller class
Note 1 : corner / gregory kernels are not working yet
Note 2 : the vertex mirroring solution used for boundary / corner kernels could be incorrect...
- FarKernelBatch becomes a class w/ accessors
- split the FarKernelBatchFactory to its own header file
- add doxy doc
- propagate fallout to the rest of the code base
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
- replace ptex indexing with the FarPtexCoord structure as a way to pass per-patch
ptex data to the shaders.
We are replacing a vector<int> arranged as :
int[0] : ptex face index
int[1] : (u,v) as 16 bits encoding the log2 coordinate of the top left corner
Instead we are now using a struct arranged as :
int[0] : ptex face index
int[1] : is a bit-field containing u,v, rotation, depth and non-quad
The u,v coordinates have been reduced to 10 bits instead of 16, which still
gives us a lot of margin.
- Replace OsdVertexBufferDescriptor with something more adequate for general
primvar representation (this name will probably eventually change...)
- Improve OsdPatchDescriptor
- add a "loop" boolean (true if the patch is of loop type)
- add a GetPatchSize() accessor
- OsdPatchArray :
- remove some redundant elements (still more to do there)
- Fix all shader / examples / regressions & stuff to make this all work.
fixes#143
2 client APIs are changed.
- VertexBuffer::UpdateData() takes start vertex offset
- ComputeController::Refine() takes FarKernelBatchVector
Also, ComputeContext no longer holds farmesh.
Client can free farmesh after OsdComputeContext is created.
(but still need FarKernelBatchVector to apply subdivision kernels)
Now a ComputeController is passed as an
argument to OsdMesh::Create(). This is
a better match to the underlying object
model and can be much more efficient for
compute controllers that have expensive
resources, e.g. compiled shader kernels.
Fixes#103
- add bool OsdGLDrawContext::SupportsAdaptiveTessellation() method
- modify glViewer to use that instead of #ifdefs
Note : this is not the final word on this as OSD really needs a more comprehensive
system to provide run-time information about available features to the client code.
fixes#111
Model the GL VB after D3D11 one, where there are no data read backs, however this means
an extra memory copy of the buffer. 4th level uniform subdiv on Car, glGetBufferSubData
was taking 50% of CPU time before (actual subdiv 22%), now that is gone. Full CPU Draw
62ms -> 54ms, looks like most of overhead now is just waiting on GL queries).
In example code, GLUT has been replaced with GLFW so that glViewer/ptexViewer can run on OSX (10.7 or later).
OSX note: still have some problem with clang, may need to explicitly specify gcc on cmake cmdline
-DCMAKE_CXX_COMPILE=/usr/bin/g++
fixes#98
- remove the GL error check in cudaGLVertexBuffer :
* unrelated GL errors left on the stack were triggering erroneous
vertexBuffer allocation errors
* we should not be checking for GL errors here anyway (as most other
buffer allocations aren't checked either)
- add some pointer checking in the GL / D3D drawContexts in case the
vertexBuffer pointers passed are NULL
- add some additional typedefs in OsdError to report some of the new
CUDA / GL related errors
This avoids adaptive tessellation artifacts near silhouette edges
by using the projected diameter of an edge's bounding sphere
rather than the length of the projected edge itself.
There is a nice writeup of this by Bryan Dudash of NVIDIA at:
https://developer.nvidia.com/content/dynamic-hardware-tessellation-basics
- [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...
- All data representation classes are now single-templated for a vertex class 'U'
- All constructors / instancing code has been moved into "Factory" functions that are dual-templated
for two vertex classes <class T, class U=T>. This allows hbr specialization with a placeholder
vertex flass 'T' for faster analysis without paying interpolation costs, while far can still specialize
a fully implemented vertex class 'U' with full subdivision functionality.
- Some preliminary clean-up work on FarVertexEditTables with the addition of a FarVertexEdit class
as a replacement for the former HbrVertedEdit which was introducing back dependencies on hbr. The
implementation is very lightweight. Some slight renaming / cleanup of the code, with some more to
be done.
- there are no more dependencies on hbr (not even #include) from far's data structure !
Notes :
- the FarDispatcher mechanism has become somewhat awkward and should be re-evaluated when refactoring osd.
- the "Factory" pattern survives this round of refactoring until we can find something better.
Closes#34
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
where it can cause havoc downstream, and move vertexBuffers into the cpp
file to avoid gl.h inclusion and to fix dynamic cast issues. These were
found during Presto integration.
- modify shape_utils to return a vector of coarse vertices when creating an hbr mesh
- minor cleanup of osd mesh and the addition of a vector parameter in the creator to
save the remapping between the hbr mesh progenitor and the current serialized osd mesh.
- minor fallout modifications to the glutViewer & far regression code
Notes :
- the dual template of far is causing a lot of complications
-> suggest finding a way to isolate the T template to the factory code.
-> far needs a concept of a vector of vertex & varying data (to abstract the vertex buffer
away from osd)
-> the dispatched mechanism is awkward and needs refactoring
-> suggest moving the default CPU kernels away from the subdivision tables
-> suggest finding a way to completely untemplate the tables (we might need a templated
factory function though)
-> osd should be able to call delete on the far mesh to get rid of all the CPU-bound data
once the GPU data has been laid-out.
Closes#18.
kernel, call OsdKernelDispatcher::Factory::Register() and keep the integer
result value as kernel handle.
Attempted to elimiate registering function from client code, but currently
disabled (in kernelDispatcher.cpp) because of Maya plugin doesn't work with cuda
kernel.
glutViewer creates kernel menu dynamically according to linked kernels.
Fix a bug of maya plugin crashes.
Closes#14
- use find_package(OpenMP) to test that the compiler supports OMP
(looks like the "express" versions of MSVC do not)
- if not available, make sure that osd does not register those
compute kernels (but does register the CPU standalone ones)
- similar refinements on other dependencies (Maya, CUDA) where
the build "opts in" depending on which libs are found.
some CMakeLists still need more cleanup...
Closes#9
specification (how many elements exists in the buffer).
client will create OsdVertexBuffer and provide it as an argument of
OsdMesh::Subdivide() function. It would be more flexible and hopefully matches
various use cases.
Since each dispatcher has to accept arbitrary vertex buffer, introduced a simple
shader registry into glslDispatcher. It will configure shaders for given vertex
elements on demand (for now, just works only for varying buffer).
Fixed cuda kernel's GL resource leakage. Since cuda GL interop seems one-way,
OsdCudaVertexBuffer manages vertex updating instead of just using
OsdGpuVertexBuffer.
Cleaned up some kernel codes and renamed ambiguous names.