Commit Graph

1405 Commits

Author SHA1 Message Date
Philip Rideout
bfaa2bdd4e gltf_baker: allow 3D visualization of mesh normals. 2019-06-03 13:03:14 -07:00
Philip Rideout
ce4a3edf7b gltf_baker: visualizers now use fp32 textures.
This allows us to skip the CPU-side vector-to-color conversion that
occured at the end, and makes the real-time visualization consistent
with the final visualization.
2019-06-03 13:03:14 -07:00
Philip Rideout
6c153b046f gltf_baker: allow visualization of mesh normals. 2019-06-03 13:03:14 -07:00
Philip Rideout
7a732eb9c4 gltf_baker: show the bounds of the asset
Parameterization can run into problems for very large, very small, or
off-center assets. Showingthe min/max helps users diagnose these issues.
2019-06-03 13:03:14 -07:00
Philip Rideout
fdfb8862eb gltf_baker: allow tmin adjustment. 2019-06-03 13:03:14 -07:00
Philip Rideout
8df3253955 Resurrect the denoiser.
This follows the convention of providing our own CMake files in the tnt
folder(s) and successfully builds with the -i option (install).
2019-06-03 10:39:56 -07:00
Philip Rideout
78ec315b69 Overhaul the gltf_baker UI.
As per the design doc, this makes the app somewhat usable by eliminating
hardcoded filenames, the hidden state machine, etc.
2019-06-03 08:32:48 -07:00
Philip Rideout
13fc64470a Add shader_ball in glTF 2.0 format. 2019-05-31 15:02:35 -07:00
Philip Rideout
97b5d43bd5 AssetPipeline: renormalize after baking transforms. 2019-05-30 16:03:13 -07:00
Philip Rideout
c2fcb39336 resgen: remove unused flag. 2019-05-30 16:02:55 -07:00
Mathias Agopian
4e718f592c fix typo in ashmem fallback code
There was typo that prevented the ashmem fallback code to work.
This became briefly a problem on Android Q before we fixed our
use of private APIs.
2019-05-30 13:39:09 -07:00
Romain Guy
d780e8b2a0 Add link_library(libc++.a) (#1245)
* Add link_library(libc++.a)

* Always link statically against libc++ and libc++abi on Linux
2019-05-30 11:49:03 -07:00
Romain Guy
e1b773958f Add screen and multiply blending modes (#1241)
* Add screen and multiply blending modes

This change also fixes a sorting issue: different sorting modes
were sorted in different buckets which is incorrect. We want
to sort only by distance.

* Update release notes and Java API

* Fix build error
2019-05-30 10:17:16 -07:00
Ben Doherty
326a67acdb Fix iOS README formatting 2019-05-30 10:01:56 -07:00
Ben Doherty
2c36d0aaae Add gLTF iOS sample (#1236) 2019-05-30 10:00:21 -07:00
Jack Diver
1b45f253eb Removed unnecessary nullptr guard from MeshReader::MaterialRegistry destructor. 2019-05-30 09:54:37 -07:00
nitronoid
7a2b5125ed Moved back to [] syntax, works for exisitng string keys now. 2019-05-30 09:54:37 -07:00
nitronoid
da39dbcb57 Fixed move constructors for MeshReader::MaterialRegistry 2019-05-30 09:54:37 -07:00
Philip Rideout
fab70e878a Repair redball tutorial.
Our GitHub Pages site is currently using an older version of the
filament wasm file so we should avoid using the new API here.
2019-05-30 09:34:08 -07:00
Jack Diver
0d2fe62d68 Fixed enum scoping in DriverEnums.h to allow compilation with gcc (#1244) 2019-05-30 09:05:18 -07:00
Philip Rideout
bafa62cdec Repair the install target, disable denoise.
This rolls back denoise functionality to repair install builds.
Will investigate a proper fix by authoring a tnt/CMakeLists.
2019-05-29 15:41:34 -07:00
Ben Doherty
fd318826c5 Update spirv-cross (#1238) 2019-05-29 15:16:02 -07:00
Mathias Agopian
5403a19076 compute the projection scale properly.
It used to be hard-coded, which meant the size SAO radius changed with
the screen resolution.
2019-05-29 13:08:41 -07:00
Ben Doherty
89c4647c3c Expose gltfio library so it can be used by third_parties (#1230) 2019-05-28 14:50:38 -07:00
Mathias Agopian
9befaeb3ae SAO now uses a hierarchical depth to improve performance
- we generate LODs for the depth map using the framegraph
- these LODs are used in the SAO shader to improve data access locality
2019-05-28 13:09:11 -07:00
Philip Rideout
122eb8c82e gltf_baker: add UV visualization option 2019-05-28 11:44:04 -07:00
Philip Rideout
81b3f1b244 Build OpenImageDenoise only if TBB is available. 2019-05-28 11:43:50 -07:00
Philip Rideout
cc89b6ad1e PathTracer now applies OpenImageDenoise. 2019-05-28 11:43:50 -07:00
Philip Rideout
0f7aa70f2d Add OpenImageDenoise. 2019-05-28 11:43:50 -07:00
François Guthmann
b7304084d9 Corrected minor LaTeX typo (#1234)
The Jacobian formula display was broken in the cloth IBL section.
2019-05-25 13:14:35 -07:00
Romain Guy
a99d3b613f Remove unnecessary variants 2019-05-24 18:27:39 -07:00
Romain Guy
e896ed9d87 Add support for Parallax Occlusion Mapping in the PBR demo 2019-05-24 17:45:26 -07:00
Romain Guy
975395ce98 Simplify duplicate code 2019-05-24 17:01:57 -07:00
Philip Rideout
761b407159 AssetPipeline now has replaceOcclusion function.
This preserve original materials and substitutes the occlusion texture
with the generated AO.
2019-05-24 14:59:10 -07:00
Philip Rideout
5bdbf63ff6 gltf_baker now has an export modal. 2019-05-24 14:59:10 -07:00
Mathias Agopian
d3753ca463 fix framegraph test 2019-05-24 11:10:18 -07:00
Mathias Agopian
ca20ae3851 handle levels of textures in the framegraph
- it's now possible to use a level of a texture as an attachment of
  a rendertarget in the framegraph, by simply setting the desired level
  when specifying an attachment.

- for now, removed the (never used) feature where the framegraph could
  resize a resource under-the-hood.

- when requesting the physical renderder target by calling
  getRenderTarget(), we now must specify the same level that was used
  when the rendertarget was created. This is not ideal, and we hope
  to fix that in the future, but it'll require some serious internal
  changes (and maybe API changes)
2019-05-24 10:22:23 -07:00
Mathias Agopian
ea6d8dd212 Simplify useRenderTarget() helper and update accesses
- useRenderTarget() has a helper for simple cases, make it even more
easy to use. It assumes a single color attachment w/ WRITE access,
which is a common case.

- update all useRenderTarget() access flags
2019-05-24 10:22:23 -07:00
Mathias Agopian
92dfeb63dc Fix wrong assert in createRenderTarget()
- we were not taking the attachment's level into account.
2019-05-24 10:22:23 -07:00
Ben Doherty
68d6b5718e Unbind textures / sampler groups in Metal backend when destroyed, add SSAO workaround (#1222) 2019-05-24 09:14:25 -07:00
Philip Rideout
8f1d4ffa4d gltf_baker now parameterizes in a background thread. 2019-05-23 22:06:43 -07:00
Philip Rideout
3b2d75e129 gltf_baker now has adjustable resolution. 2019-05-23 22:06:43 -07:00
Mathias Agopian
2d2be0a214 update min/max LOD when using a texture as attachment
This fixes a problem where the min lod of a texture would be set
incorrectly when first drawing into the base level (common case) and
then creating a mipmap chain from it using blits.
Because drawing into the texture doesn't set the base level, after the
blit, the min level would be set to 1 instead of 0.

In fact, there was no way to set the level of a texture by drawing into
it, the only ways were by blitting or uploading data.


This change updates the min/max LOD when a texture level is attached to 
a rendertarget, regardless of whether we read or write -- assuming that
we will write to it. The problem is that at that stage we don't know
if we will read or write. That said, if the user attaches an uninitialized
level to read from it, who cares what really happens
2019-05-23 21:47:05 -07:00
Mathias Agopian
1716f9e7cd fix our ostream << hex << char
Even when hex modifier is used, 'char' should be printed as characters,
this is particularly relevant with 0.
e.g. out << (char)0, should write a nul terminator, not "0".
2019-05-23 21:46:28 -07:00
Mathias Agopian
da0d94caf2 promote uint8_t (i.e. uchar) to printable ints
An easy way to do this is to prepend a "+" to the variable.
2019-05-23 21:46:03 -07:00
Pixelflinger
1b41ef78cd Use depth culling when computing SSAO
Since we have a depth buffer, we might as well use it for depth-culling,
this automatically discards the skybox's fragments -- which we can
assume won't participate in SSAO.
2019-05-23 16:35:16 -07:00
Mathias Agopian
83c523256d fix debug builds 2019-05-23 13:09:11 -07:00
Pixelflinger
507aeb1e34 ssao is now done in quarter resolution
- this means that we cannot share the depth pass between ssao and color
passes, so all this code is removed, which simplify things a lot.

- the depth pass code is moved into the ssao codepath since they're now
intimately linked.

- and finals ssao shader can't rely on frameUniform which is set up with
the main buffer's size (instead of 1/4 res).
2019-05-23 12:59:22 -07:00
Romain Guy
43115e1f3b Update release notes 2019-05-23 12:56:56 -07:00
Romain Guy
0a5c068cb6 Switch specular AA to Tokuyoshi and Kaplanyan (#1218)
This replaces the previous "curvature to roughness" method. Both are related
and rely on the screen space variance of geometric normals but this new
solution offers more control (the screen space variance and the clamping
threshold can be controlled).
2019-05-23 12:56:26 -07:00