Commit Graph
3463 Commits
Author SHA1 Message Date
Benjamin Doherty 62b50eb8ba Update RELEASE_NOTES for 1.9.12 2021-02-16 10:42:41 -08:00
Ben Doherty b4932e384a matc: Use consistent params for semantic code analysis (#3524)
When running semantic analysis on a material, we were arbitrarily choosing the first code gen permutation to analyze. So, running matc with arguments --api metal versus --api all would run analysis on slightly different shader code. This causes bugs when flags passed to glslang differ during semantic analysis. This change updates all semantic analysis to always use the same shader code.
2021-02-08 14:06:47 -08:00
Benjamin Doherty 5e68dc5f8d Bump version to 1.9.12 2021-02-08 09:58:15 -08:00
Ben Doherty 22e4a54782 Update RELEASE_NOTES for 1.9.11 2021-02-08 09:50:23 -08:00
Benjamin Doherty 1289922c5f Release Filament 1.9.11 2021-02-08 09:48:50 -08:00
Ben Doherty 00f50c5f5a Draft: fix TSAN issue by using lock in ColorGrading constructor (#3510)
This is a second attempt to fix Google3 TSAN failures seen inside of the ColorGrading constructor.

Related first attempt: #3462
2021-02-05 14:05:21 -08:00
Philip Rideout 23c90a624d RenderTarget demo should create depth attachment.
This "fixes" #3501, which was not really a bug.  (doh)
2021-02-05 11:21:06 -08:00
Philip Rideout 0e27f0c162 RenderTarget demo now disables post-processing in offscreen view.
The color now match up perfectly.  Woops.

(#3402)
2021-02-05 11:21:06 -08:00
Philip Rideout 297f3d9808 Fix logcat spam with ubershaders.
Since the ubershader does not have variants for clear coat, the dummy
texture there should be unconditional.
2021-02-05 09:07:58 -08:00
Philip Rideout b4f6400d2e Do not exclude Vulkan from continuous Android CI. 2021-02-05 09:07:27 -08:00
Philip Rideout 4d905eb4bb Repair Vulkan-enabled Android builds.
We should probably change our continuous CI so that it does not
exclude Vulkan, but keep our release CI as is (for small binaries).

Fixes #3505
2021-02-05 08:41:39 -08:00
Philip Rideout 83a58033d1 Re-enable optimal bloom on Intel GPUs. 2021-02-05 08:38:29 -08:00
Philip Rideout edc8162ebb PostProcessManager Bloom: fix call to setMinMaxLevels.
This was being called on the wrong texture.
2021-02-05 08:38:29 -08:00
Romain Guy da2c9b8092 Fix doc typo 2021-02-04 14:47:22 -08:00
Romain Guy 2cf3fb569a Update Kotlin to 1.4.30 2021-02-04 14:42:50 -08:00
Benjamin Doherty 0c6de2cb58 Update RELEASE_NOTES 2021-02-04 12:47:53 -08:00
Ben Doherty 07ddd52dcf Add getVertexIndex API for vertex shaders (#3493) 2021-02-04 12:40:21 -08:00
Philip Rideout f6425fdcfb VulkanBlitter progress. 2021-02-03 17:59:59 -08:00
Philip Rideout 521c7fc713 Restore "magic resolve" as per code review. 2021-02-03 17:56:01 -08:00
Philip Rideout 3175711323 Fix MSAA for OpenGL ES 3.0 core.
This fixes `GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE` caused by the
following spec clause being violated:

```
The value of RENDERBUFFER_SAMPLES [must be] the same for all
attached renderbuffers and, if the attached images are a mix of
renderbuffers and textures, the value of RENDERBUFFER_SAMPLES
is zero.
```

Tested on Chrome with Triangle and Helmet demos (after enabling MSAA).
Also tried running the automation suite in a debug build on macOS.

Fixes #3128.
2021-02-03 17:56:01 -08:00
Philip Rideout d669b1b26f Add null terminator to fix Windows build. 2021-02-03 14:56:34 -08:00
Philip Rideout c2b4b6347e matc: add --raw argument for internal use.
This feature can generate SPIRV blobs and will be used by VulkanBlitter.

(#3485)
2021-02-03 14:56:34 -08:00
Philip Rideout 8d13b7634c Upgrade MoltenVK. 2021-02-03 09:54:19 -08:00
Philip Rideout 89bf201b6c Refactoring: Add VulkanBlitter, inspired by MetalBlitter.
This is a prep step to fix #3485.
2021-02-03 08:13:21 -08:00
Philip Rideout 9f68daeb8f Remove unused sampler params. 2021-02-02 10:51:16 -08:00
Philip Rideout c62b88013b Add setMinMaxLevels to DriverAPI.
This adds setMinMaxLevels to the DriverAPI and calls it from
PostProcessManager and the new unit test. The allows us to be compliant
to the OpenGL specification. The new unit test now looks much better on
Intel GPUs. Chrome still gives an INVALID_OPERATION.

Unfortunately the actual bloom effect still has issues on my Intel GPU,
even though the test passes. So, we need to keep the ping-pong
implementation both for Chrome and for Intel.
2021-02-02 10:51:16 -08:00
Philip Rideout 2e8df10e6e Quaternion slerp: ensure "short path" when falling back to lerp.
I noticed that our slerp function sometimes produces a jolt in
animation, but only when the time delta is very small, and only when the
two operands have completely opposing signs.

For example, let's say you are slerping from <0.76, 0.39, 0.51, 0.19>
to <-0.72, -0.45, -0.49, -0.17>.

These quats are actually quite near to each other because the total
negation of the second quat is similar to the first quat.

We were already doing the short path check in the proper slerp path, but
not when falling back to lerp due to a small angle.
2021-02-01 14:35:05 -08:00
Romain Guy 2f9c310127 Update RELEASE_NOTES.md 2021-02-01 14:24:02 -08:00
Benjamin Doherty 6eec2cde81 Release Filament 1.9.10 2021-02-01 11:44:33 -08:00
Philip Rideout 98ae61ffe5 gltfio: Fix "_maskThreshold not found" error.
MaterialGenerator selects a custom blend mode for transmissive models,
therefore the AssetLoader should look at the material's blend mode when
it sets up properties, not the one requested by the glTF file.

Fixes #3444.
2021-02-01 09:52:06 -08:00
Romain Guy adb489c77a Compile Android libraries with fPIC (#3473)
* Compile Android libraries with fPIC

* Rmove warning
2021-01-29 15:23:34 -08:00
Philip Rideout eeccfed8e4 Rewrite and enhance test_FeedbackLoops.
Previously this test was actually finding a ReadPixels failure on Intel
GPU's, rather than a failure of feedback loop behavior. This was due to
the fact that it was calling ReadPixels on a non-zero miplevel, which
seems to be unsupported on Intel GPU's.

The test now follows the downsample phase with an upsample phase, just
like the real bloom effect. This allows us to issue ReadPixels on the
base level, thus making the test more targetted to rendering feedback
loops.
2021-01-29 15:06:57 -08:00
Philip Rideout 893ed861e9 gltfio on Java: free material cache in AssetLoader#destroy
Fixes #3469
2021-01-29 14:42:54 -08:00
Romain Guy 411ae23512 Update Kotlin, Gradle and NDK dependencies (#3470)
* Update Kotlin, Gradle and NDK dependencies

* Update CI build
2021-01-29 12:09:08 -08:00
Romain Guy 8f05984551 Update release notes 2021-01-29 09:31:36 -08:00
Romain GuyandPhilip Rideout 4567b01c1d Multi-thread shaders generation when compiling materials (#3464)
* Stop using members as globals between methods

* Multi-thread shaders generation with JobSystem

* Pass JobSystem to MaterialBuilder::build()

* Fix MeshAssimp to use the new API

* Allow the Java API to pass a job system via Engine

* Update docs

* Apply suggestions from code review

Co-authored-by: Philip Rideout <philiprideout@gmail.com>
2021-01-29 09:30:37 -08:00
Philip Rideout 29315f9a1b gltfio: fix crash during async texture decode.
Recall that we now use shared_ptr to simplify lifetime management of
cgltf source data (#3413).

Before this commit, we were only using shared_ptr to retain the source
data during buffer uploads. After this commit, we are using it to retain
source data during texture decoding.

Fixes #3428.
2021-01-29 09:06:32 -08:00
Ben Doherty d4a2d30a1c Fix sporatic data race warning seen in Google3 (#3462) 2021-01-27 16:38:38 -08:00
Philip Rideout cec5f3e988 gltfio: disable shader optimizations by default
Note that ubershaders (which are always used on Android and WebGL) are
still optimized by default.
2021-01-27 11:40:51 -08:00
Romain Guy 02501c6e60 Modulate emissive by alpha on blended objects (#3459)
This prevents light from being emitted from completely
transparent pixels.
2021-01-26 16:35:49 -08:00
Ben Doherty 4d8da14c1f Update universal library option in build.sh for Apple silicon (#3458) 2021-01-26 16:34:46 -08:00
Philip Rideout 4fae917fb5 Introduce optional ping-ping bloom implementation.
Second attempt after abandoning #3451.

Feedback loops do not work with Chrome or Intel GPU's, so we now have an
optional ping-pong implementation of Bloom.

Issue #2338.
2021-01-26 15:08:39 -08:00
Philip Rideout c84036c8c4 Update JavaScript bindings and demo to prep for Bloom workaround. 2021-01-26 13:18:03 -08:00
Philip Rideout 34429f5490 Add unit test for feedback loops.
This test passes on my Radeon GPU MacBook but fails with an Intel GPU.
2021-01-26 13:12:46 -08:00
Philip Rideout 59c2d5bef3 Plumbing for disabling feedback loops on Intel.
This is a follow-on to #3451, which adds optional ping-pong support to
the bloom generator.
2021-01-26 13:12:24 -08:00
Ben Doherty a3412c4f45 Remove shadow cascade visualization from unlit variants (#3455) 2021-01-26 11:20:54 -08:00
Philip Rideout 564d846be5 Repair backend unit tests on macOS.
This fixes "illegal hardware instruction" seen on my MacBook, which
is the same as #1839, but triggered only in a test environment where
the main thread is the same as the driver thread, and filament is built
with HAS_THREADING enabled.
2021-01-26 08:57:16 -08:00
Romain Guy 41186340c9 Change visibility of a few color grading options 2021-01-25 08:49:25 -08:00
Ben Doherty 96bba71739 Update combine-static-libs.sh script to work with universal binaries (#3447) 2021-01-22 15:57:43 -08:00
Adrian PerezandMathias Agopian 5ab7a9e3ab Add swap() methods to Allocator.h (#3445)
* Add swap() methods to Allocator.h

This allows StructureOfArraysBase's move constructor to compile.
Removed an apparent workaround in SingleInstanceComponentManager.

* swap can be noexcept

* Add swap() methods to Allocator.h

This allows StructureOfArraysBase's move constructor to compile.

Co-authored-by: Mathias Agopian <pixelflinger@gmail.com>
2021-01-22 15:45:20 -08:00