Commit Graph

290 Commits

Author SHA1 Message Date
gelder
ecd726742f Added evaluator, first .obj file reading and subdividing. 2013-11-05 21:50:11 -08:00
gelder
7dbf3d4198 Updates to simple cpu wrapper classes being written for Presto deformers. 2013-11-05 20:23:37 -08:00
manuelk
83d9315e64 Fix Chaikin tag parsing
Also:
- add 2 shape examples with Chaikin rule tag
- add shapes to the glViewer
- add a stub in the documentation

Note: the Chaikin rule currently applied by Hbr appears to be somewhat off...

fixes #236
2013-11-01 11:38:20 -07:00
David G. Yu
9d60586400 Fixed VS2010 build errors. 2013-10-28 17:36:04 -07:00
manuelk
c8d490e292 Fix some warnings that are failing VC++ builds 2013-10-28 15:48:51 -07:00
manuelk
9e9fd5c021 Fix Far to handle disconnected vertices in an Hbr mesh.
Also:
    - change our shape parser to skip non-manifold faces (print a warning)
    - add a 'fan' non-manifold test shape to the glViewer

fixes #233
2013-10-28 10:40:24 -07:00
Dirk Van Gelder
38399a382c This change adds simple HbrMesh and FarMesh wrapper classes to osdutil
and a projectTest example binary to test.  Currently projectTest crashes,
Manuel has been looking into the crash- thanks!
2013-10-25 23:24:23 -07:00
Takahito Tejima
dd8cc1a3b7 improve ptex guttering. 2013-10-15 17:47:58 -07:00
Takahito Tejima
b41d55eda3 dxPtexViwer : more parity to ptexViewer 2013-10-07 19:07:26 -07:00
Takahito Tejima
3e28bbe7d6 ptexViewer : show ptex memory usage 2013-10-07 19:06:40 -07:00
Takahito Tejima
d702eecfcb Add DX11 ptex viewer (unfinished) 2013-10-04 18:28:00 -07:00
Takahito Tejima
28356dae40 Optimize a bit of ptex mipmap lookup. 2013-10-04 18:23:20 -07:00
David G Yu
c8fb9bb7d3 Fixed ptex cache resource release sequence. 2013-09-28 18:23:55 +01: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
Takahito Tejima
8807904cbd ptexViewer : add surface normal mode, use ptex cache for faster mipmap generation 2013-09-26 09:31:54 -07:00
manuelk
47ce9fe1b4 Fix ptexViewer build with GLFW 2.x 2013-09-24 09:04:20 -07:00
Takahito Tejima
d44724c5b7 Fix a bug of bad fvar splicing for loop surface. 2013-09-23 14:18:43 -07:00
Takahito Tejima
541a4c81ae fix msvc warnings 2013-09-23 13:20:58 -07:00
Takahito Tejima
d2192f0d16 Fix face varying rendering on loop surface 2013-09-23 12:56:46 -07:00
Takahito Tejima
f38d0ac3af New example : uvViewer, to see how face varying interpolation rule works 2013-09-23 12:53:41 -07:00
Takahito Tejima
f6b9d90697 Analytical displacement mapping,
from 'Analytic Displacement Mapping using Hardware Tessellation; Niessner and Loop [TOG 2013])

and ptexViewer code cleanup
2013-09-20 18:29:00 -07:00
Takahito Tejima
c7d8368fff Add a slider component and cleanup hud code. 2013-09-20 18:19:34 -07:00
David G Yu
945bd59c7e Fixed glBatchViewer build for GLFW 2.x 2013-09-19 12:08:12 -07:00
Kenneth Russell
81d3955280 Set GLFW_OPENGL_FORWARD_COMPAT on Mac OS to make samples work on that platform.
Fixed "Quit" menu option in glBatchViewer.
2013-09-17 10:18:32 -07:00
manuelk
924d994fdd Fix CMake executable macro
- Added a macro for non-cuda / non-glfw executables to add proper dependencies for ICC
- Switched various examples & regressions
2013-09-16 18:16:28 -07:00
Manuel Kraemer
0172d47a59 Squash build warning 2013-09-13 09:18:13 -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
d41b4e9df0 Fixes facevarying rendering in glBatchViewer 2013-08-28 17:15:42 -07:00
Takahito Tejima
b3948bb336 Fixes overlapped hud menu 2013-08-28 16:36:06 -07:00
David G Yu
fb2a519d52 Added cmdline obj loading to the DX11 viewer 2013-08-17 13:33:52 -07:00
manuelk
ac72015310 Adding TBB Compute back-end to glViewer 2013-08-16 10:51:51 -07:00
manuelk
b81d159b91 Enabling Intel's C++ Studio XE icc compiler in Linux
- Add a ICC_LOCATION option to CMake configuration
- Fix icc dependencies
- Add documentation
2013-08-15 15:21:00 -07:00
takahito-tejima
8cf9c834df Fix overlapping HUD menu 2013-07-18 19:49:16 -07:00
takahito-tejima
dd91b2de8c Fix some portability issues on OSX. (GLEW will be used if exists) 2013-07-18 19:49:00 -07:00
Takahito Tejima
8796be66e9 Add 'freeze' button to ptexViewer + cleanup 2013-07-18 15:08:17 -07:00
Takahito Tejima
51a45b598d Updating EULA 2013-07-18 14:19:50 -07:00
Takahito Tejima
a13c0565e4 Renamed texture buffers and uniforms
g_VertexBuffer -> OsdVertexBuffer
g_ValenceBuffer -> OsdValenceBuffer
g_QuadOffsetBuffer -> OsdQuadOffsetBuffer
g_ptexIndicesBuffer -> OsdPatchParamBuffer
g_uvFVarBuffer -> OsdFVarDataBuffer
LevelBase -> PrimitiveIdBase
2013-07-18 12:57:26 -07:00
David G Yu
d19bedb51c Fixed macro redefinition errors
Reported by AMD and Apple GLSL compilers
2013-07-16 17:02:22 +01:00
Takahito Tejima
de3e706379 Potential fix for the shader compilation problem.
Replace face varying computation functions with equivalent macros
to avoid gl_PrimitiveID undefined error.
2013-07-08 16:16:28 -07:00
Manuel Kraemer
7a71def44a Adding more documentation
- new RST pages for our excample code
- fix doxygen documentation link from the nav tab
- fix cmake build rules (still not quite working as intended)
- adding API RST documentation all around
2013-07-04 19:17:34 -07:00
Takahito Tejima
2b4dd1cb0a Add convenient functions to compute face varying attributes.
closes #171
2013-07-03 12:08:10 -07:00
Takahito Tejima
33e0d6e42d Add varying buffer interface to OsdUtilMeshBatch.
Update glBatchViewer for varying/facevarying color display
2013-07-02 11:18:06 -07:00
Takahito Tejima
37b2b8150e Add FaceVarying color display mode into glViewer 2013-07-02 11:16:27 -07:00
David G Yu
c6eff9860a Fixed dxviewer clear color to be in sRGB space 2013-07-02 10:09:45 -07:00
Takahito Tejima
a1d9e028bc Fix a bug in ptexViewer: the ptex level computation of non-quad face was wrong 2013-07-01 14:23:00 -07:00
David G Yu
b9c14e4abe Fixed hotkey display for fractional tess 2013-07-01 11:41:49 -07:00
David G Yu
288b27dc28 Finished varying color shader updates for glViewer 2013-06-28 18:34:34 -07:00
David G Yu
c94c928fe9 Fixed file execute permissions 2013-06-28 17:02:16 -07:00
Takahito Tejima
b9086b4686 Fix OsdGLSLTransformFeedbackComputeContext to bind vertex/varying buffer correctly.
Closes #186
2013-06-28 16:09:04 -07:00
David G Yu
d2abf61c56 Added adaptive tess of user varying values
This isn't necessarily a final design, but
it gets enough of the pieces in place to move
forward.
2013-06-28 14:05:47 -07:00
takahito-tejima
bd42d42be5 Fix varying color display on glViewer/mac 2013-06-27 14:05:24 -07:00
Takahito Tejima
184e90f9a1 Add fractional spacing mode for patch rendering. 2013-06-27 13:34:25 -07:00
Takahito Tejima
e030157f73 Add varying buffer handling to OsdMesh.
Fix a bug that breaks varying interpolation on cuda kernel
Clean up glViewer with some new functions : varying color, screen space lod, patch culling
2013-06-27 12:57:21 -07:00
David G Yu
7d16bffccb Continued cleanup of OpenGL dependencies 2013-06-26 00:52:57 -07:00
manuelk
876cf3bc86 fix GLFW problems with ptexViewer and paintTest
GLFW 3.0.1 made the reshape callback explicit. Since we are using it to setup some framebuffers,
we need to call this function ourselves before starting the main-loop.

fixes #181
2013-06-20 13:51:07 -07:00
manuelk
30ec963112 fix example code to work with GLFW 3.0
- fix FindGLFW.cmake to match the new locations

- fix all viewer & examples to build with 3.0, 3.0.1 and 3.0.2

Note : ptxViewer and paintTest do not work with 3.0.1 and 3.0.2 (yet)
2013-06-20 11:53:33 -07:00
manuelk
edfc9b4bb6 limitEval example : add the ability to read regular obj files as a command line argument (usefuly for debugging...) 2013-06-18 16:52:21 -07:00
manuelk
bbe4435b19 minor API refactor of for EvalLimit :
- 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
2013-06-17 18:13:13 -07:00
David G Yu
077f95b8f0 Fixed a couple bugs/typos in simple_math.h 2013-06-14 09:55:55 -07:00
manuelk
54bef92aab switch cpuEvalLimitController to use a quad-tree based patch access map :
- 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
2013-06-13 14:01:23 -07:00
David G Yu
38c951a06c Fixed patch color override for uniform subdivision 2013-06-10 23:33:34 -07:00
David G Yu
06701a8855 Removed examples/evalTest from examples/CMakeLists 2013-06-10 17:26:58 -07:00
David G Yu
6c487c5bac Deleted examples/evalTest 2013-06-10 17:24:34 -07:00
David G Yu
29afdfc8b3 Fixed GLSL transform feedback initialization. 2013-06-10 16:56:32 -07:00
David G Yu
967fc4db72 Fixed glsl shader portability edgeDistance
Moved all edgeDistance declarations to client shader code.
2013-06-10 16:32:45 -07:00
David G Yu
1461deb308 Fixed glsl shader portability (input,output) 2013-06-10 16:31:30 -07:00
David G Yu
c185968809 Updated glsl code texelFetchBuffer -> texelFetch
This allows us to remove unnecessary directives
to require GL_EXT_gpu_shader4
2013-06-10 16:21:47 -07:00
manuelk
419b6b9716 - add a message to limitEval when trying to display face-varying UVs on shapes
that do not have that type of data

- fix some regression shapes that had "empty" uv values
  (including some minor topo surgery that luckily appears to not break
  regression baselines)
2013-06-07 17:53:23 -07:00
manuelk
cf1b2f1334 - fix a face-varying bug in shape_utils : now face-varying UVs are indexed correctly
coming out of our shape format

- set blue component of point-cloud to 0 in face-varying mode (save a few micro-secs)
2013-06-07 14:47:41 -07:00
manuelk
f5a7ad4cdb evalLimit example : make sure to reset the output buffer on creation - some of the prims may not
set all the point colors (if face-varying data is missing on the test shape for instance)
and we don't want random values creeping from unset memory allocations.
2013-06-07 10:38:10 -07:00
manuelk
c18cf5bff2 first pass at face-varying interpolation for CpuEvalLimit - still
a couple of kinks to be worked out...
2013-06-06 18:07:46 -07:00
manuelk
043369485c - adding varying data interpolation to the EvalLimit module
- 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
2013-06-05 11:44:30 -07:00
Takahito Tejima
b0e8533ef4 Fix cmakefile and #ifdefs for opencl configuration. 2013-06-05 10:44:21 -07:00
Takahito Tejima
a6bf169344 Fix fvardata interpolation on adaptive patches. 2013-06-04 11:02:27 -07:00
manuelk
21b9fbbb95 Moving some member variables of OsdGlDrawContext from public to protected
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.
2013-05-31 17:11:16 -07:00
manuelk
f2b3419a4d bug fix in limitEval example : calculation for the required number of samples was incorrect
on geometry with non-quad faces. This should be fixed now.
2013-05-31 14:14:42 -07:00
manuelk
393362b589 Cleaning up the feature adaptive patch colors : all example code now shares the same function to provide the patch colors
Note : this function will probably eventually move down to osdutil or some similar canonical place
2013-05-22 16:26:02 -07:00
David G Yu
5632721a4b Assign locations for attribs and frag data 2013-05-22 12:36:21 -07:00
Takahito Tejima
87114f7428 Rename osd_util to osdutil.
Cleanup the batching classes so that DrawCollection() no longer caches
current batch and effect. Any kind of binding optimization will be
handled in client's delegate class.
Also remove InitializeVertexBuffer method and add some arguments to
constructor instead.
2013-05-21 17:20:22 -07:00
David G Yu
0f0d4d56ff Fixed ptexViewer xform feedback initialization 2013-05-20 12:21:13 -07:00
David G Yu
9aa83d9538 Fixed simpleCpu draw context construction. 2013-05-20 12:21:13 -07:00
David G Yu
784b6e4475 Fixed OS X build issues. 2013-05-17 15:53:36 -07:00
Takahito Tejima
a6dbb0adc4 example/paintTest can be built with GL 4.3 or later. 2013-05-17 13:59:06 -07:00
Takahito Tejima
e75d94e2ac Fix paintTest to follow API change 2013-05-17 13:40:39 -07:00
Takahito Tejima
aa76d9c645 Add constructor to FarPatchTables. Add enums to FarPatchTables::Type. 2013-05-17 12:49:57 -07:00
manuelk
c2cec239cd removing osd/patch.h (and cleaning up attending dependencies) 2013-05-17 09:06:40 -07:00
manuelk
19073abec8 fix glslTransformFeedback constructor for glBatchViewer 2013-05-16 17:48:06 -07:00
Takahito Tejima
6140f1ae81 DrawContext->IsAdaptive() is no longer needed in client code. 2013-05-16 17:10:17 -07:00
Takahito Tejima
da4fc9c653 Fix multiMeshFactory to splice uniform patches correctly.
(IP) refactor osdbatch
2013-05-16 16:55:53 -07:00
manuelk
6256010296 re-factoring the EvalLimit portion of the code (and other minor comment / typo fixes) 2013-05-16 14:21:11 -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
Takahito Tejima
b16272d6a5 more msvc fixes. make dxViewer working. 2013-05-14 10:48:48 -07:00
Takahito Tejima
1a2b71d929 Refactor OsdGLDrawContext to be constructed from FarPatchTables, instead of FarMesh.
Removed reference to FarMesh from OsdUtilMeshBatch.
Added const qualifier to ComputeContext constructor.
2013-05-10 19:35:25 -07:00
Takahito Tejima
b7814266c9 Add OpenCL specialized batching class 2013-05-10 09:20:45 -07:00
Takahito Tejima
6ea485de47 fix compile error 2013-05-09 21:27:00 -07:00
Takahito Tejima
5e5fc97b0c fix glBatchViewer 2013-05-09 19:18:32 -07:00
Takahito Tejima
7b6630cf40 fix simpleCpu and ptexViewer to be compilable with new patch tables. 2013-05-09 13:48:00 -07:00
Takahito Tejima
3eaf0362bd split patch descriptor into two parts, far intrinsic properties and osd's.
more OsdGLDrawContext clean up.
2013-05-09 13:14:02 -07:00
Takahito Tejima
f592e90067 fix OsdGLDrawContext to follow far patchtables refactoring. 2013-05-09 09:23:01 -07:00
David G Yu
2a12b21ab2 Removed mutex implementation.
We added this to support earlier versions
of hbr, but it is no longer needed.
2013-05-07 11:27:14 -07:00