Commit Graph

1146 Commits

Author SHA1 Message Date
Powei Feng
aa4f1910b8 android: add static annotation for Utils.init() (#9435)
This allows for static call from java, e.g.:

```
static {
    Utils.init();
}
```
2025-11-13 22:01:49 +00:00
Powei Feng
080f958da3 android: remove checked in asset (#9426)
For sample-gltf-viewer, an asset was checked into the source tree.
But other assets are generated or copied from asset directories.

We remove the checked in gltf and copy the asset over during
build (as with other existing files).
2025-11-13 06:29:45 +00:00
Mathias Agopian
3a503976c8 add View::getLastDynamicResolutionScale() (#9419)
* add View::getLastDynamicResolutionScale()

This method return the last dynamic resolution scaling factor used
by the view.

FIXES=[457753622]
2025-11-10 14:49:23 -08:00
Rafael Marinho de Araújo
d47a69a529 add overload of loadTexture that loads bitmap from ByteArray (#9416)
Co-authored-by: rma6 <rafaelmarinhoa@gmail.com>
2025-11-07 10:11:23 -08:00
Benjamin Doherty
b84c6ace8d Release Filament 1.67.0 2025-11-05 10:33:15 -08:00
Doris Wu
84fdf36ed9 buffer update opt: New android sample for material instance stress test (#9396) 2025-11-05 03:24:56 +00:00
Powei Feng
faa565c3ff vk: remove unused shaders (#9394)
The BlitDepth shaders were no longer referenced in the blit code
and hence are removed.
2025-11-04 17:45:57 +00:00
Powei Feng
21c7fa6253 Release Filament 1.66.2 2025-10-29 11:09:30 -07:00
rafadevai
326bc4c311 Fix comments for TextureSampler::setAnisotropy (#9357)
The default value for no anisotropy must be 1
instead of 0.
2025-10-23 11:14:33 -07:00
Doris Wu
8d6e8b8b3c buffer update opt: Add engine config for default shared Ubo size (#9340) 2025-10-22 03:48:18 +00:00
rafadevai
9da29e3ab7 Add new public API to query a sampler transform name field. (#9320)
* Add new public API to query a sampler transform name field.

This new API will let filament users query a Material object
the value of the `transformName` field of a specified sampler
parameter.

The transformName is an optional field, so if its not defined
by the user, it will return a nullptr value.

- A new test was added to test_filamat to validate the serialization.
- A new parameter was added to the test sandboxLit material to
validate the parsing a material with the new field.

* Addressing review comments

- Add java and js bindings for the new API
- Tests for querying the getParameterTransformName

* Use utils::ImmutableCString for transformName

* Updating release notes

* Review comments

* Addressing more review comments

- Fix comments
- For the java binding return an empty string when the
transform is not present.
2025-10-21 23:55:25 +00:00
Sungun Park
d3f4e91be2 Release Filament 1.66.1 2025-10-21 12:56:30 -07:00
Doris Wu
9561137d53 buffer update opt: Change to use feature flag instead of engine flag (#9327)
* Revert "buffer update opt: Add a flag to guard the feature (#9322)"

This reverts commit 49c4a5d62c.

* Update feature flags

* feedback

* Update naming
2025-10-16 07:13:30 +08:00
Doris Wu
49c4a5d62c buffer update opt: Add a flag to guard the feature (#9322) 2025-10-15 23:14:53 +08:00
Benjamin Doherty
b7dea28cc5 Release Filament 1.66.0 2025-10-14 14:25:20 -07:00
Mathias Agopian
f8e8c27c04 Add a Renderer API to force skipping frames (#9313)
* Add a Renderer API to force skipping frames

Renderer::skipNextFrames(size_t) can be used to force filament to
pretend the next N frames must be skipped. This is mostly useful for
debugging.

* Add DebugOptions to Settings

We still need to move the "Debug" features of gltf_viewer to this,
but this give us a framework to do it. 
Currently there is one debug option that allows to set a number of
frames to skip.

ViewerGui propose a button to skip 10 frames using this framework

* Update libs/viewer/src/Settings.cpp

Co-authored-by: Powei Feng <powei@google.com>

* Update libs/viewer/src/Settings.cpp

Co-authored-by: Powei Feng <powei@google.com>

---------

Co-authored-by: Powei Feng <powei@google.com>
2025-10-13 12:52:17 -07:00
Powei Feng
caf886df6b Release Filament 1.65.4 2025-10-07 15:54:13 -07:00
Mathias Agopian
31d66002a9 optional per-channel depth clear (#9287)
- increase the number of channels from 4 to 8
- new api on View to enable per-channel depth clear
FIXES=[447648764]
2025-10-03 14:25:02 -07:00
Sungun Park
f07a44eb15 Release Filament 1.65.3 2025-09-30 18:50:39 +00:00
Powei Feng
7663ca8dfe Release Filament 1.65.2 2025-09-24 11:53:16 -07:00
Powei Feng
edb17200d0 android: fix hello-cam sample appID
Make the application id and namespace consistent.
2025-09-23 16:10:39 -07:00
Ben Doherty
bf2459540e Add Java bindings for setFrameScheduledCallback (#9182) 2025-09-22 18:40:42 -07:00
Sungun Park
24a6bd30f9 Release Filament 1.65.1 2025-09-19 15:42:25 +00:00
Ben Doherty
59f19aee0e Add documentation and script to publish to Maven Central (#9216) 2025-09-16 13:41:06 -04:00
Sungun Park
57d1a6a165 Add MSAA swapchain support (#9196)
Users can now create a swapchain with MSAA support, which enables direct
rendering to a multi-sampled swapchain image and automatic resolution.

This is only supported by EGL(Android). Other GL platforms (GLX, WGL,
etc) don't support it because the swapchain MSAA settings must be
configured before window creation.

Support for other backends will follow.

BUGS=[433327615]
2025-09-11 21:29:06 +00:00
Benjamin Doherty
da315ef9fe Release Filament 1.65.0 2025-09-09 17:15:42 -07:00
Mathias Agopian
88e4ddeec7 View::setCamera() should accept nullptr
FIXES=[441757817]
2025-09-08 07:56:47 -07:00
Mathias Agopian
26ceaebac6 add RenderManager::getInstanceCount()
FIXES=[442916683]
2025-09-05 09:51:06 -07:00
Mathias Agopian
76e36cd87b try to cleanup android libraries cmake build
- make as many library deps private as possible
- try to keep the same structure between the CMakeList.txt files
- for gltfio use libgltfio_core.a
2025-09-04 11:28:28 -07:00
Powei Feng
9fad497fa0 Enable c++20 for Android and iOS (#9150)
- Fix Android cmake files
- Change iOS samples to use c++20
2025-09-03 00:28:14 +00:00
Powei Feng
f875dc2c08 Release Filament 1.64.1 2025-09-02 11:17:37 -07:00
Juan Caldas
74ba3eb00c webgpu: Support skinning on WebGPU (#9137)
BUGS = [436886048]
2025-08-29 00:24:14 +00:00
Doris Wu
ff394f7c1b feat: Add Visibility Bitmask method for GTAO (#9101)
* Quick test

* Fix incorrect logic and add some comments

* Set thickness parameter

* refactoring

* Update

* Generated files

* Some comments

* Update

* Update generated files

* Update

* Update

* Add comments
2025-08-26 23:27:02 +00:00
Sungun Park
95db13a544 Release Filament 1.64.0 2025-08-19 21:50:50 +00:00
Mathias Agopian
45f68909d7 Fix dynamic resolution with TRANSLUCENT views
A few bugs in that area were introduced by #8391. Upscaling is 
supposed to perform the final blending if needed, but it didn't.
Transparency/blending is only supported by the bilinear upscaler, which
is automatically selected in that case.

The upscaling pass itself may include a final `RCAS` pass for
sharpening, in that case, blending must be performed then. So we added
the logic for that.


Fixes #9061
2025-08-13 16:53:16 -07:00
Benjamin Doherty
a9f2253d93 Release Filament 1.63.1 2025-08-13 11:47:16 -04:00
Powei Feng
c21f211a13 Update java for Texture::Usage (#9055)
Also update samples and utils to use proper usage when
generating mipmaps.
2025-08-11 19:47:26 +00:00
Mathias Agopian
db14efc151 compress the DFG LUT with zstd
- use resgen to package the DFG LUT into filament, instead of using
  a large include of a C array.

- add a zstd compression step, which reduces the size from ~100KB to
  ~75KB.

The overhead of zstd is about 90KB uncompressed, however it will pay
for itself tenfold when we use it to compress material packages.
2025-08-07 14:58:18 -07:00
Mathias Agopian
71d0723026 add zstd to the build 2025-08-07 14:58:18 -07:00
Mathias Agopian
b92af357f7 add a material option to use linear fog calculations (#9030)
The new `linearFog` material property, when set to `true` enables a
simplified fog calculation. The fog equation becomes linear which is
unrealistic, but more efficient to compute. In some situations with
a shallow fog range, it doesn't make a huge difference visually.

In this mode, height falloff and in-scattering are ignored.

The linear equation slope is calculated from the regular parameters to
match the slope of the real equation at a camera height. If 
`heightFalloff` is disabled, set to 0, the `density` parameter 
exactly corresponds to the slope of the equation in [1/m] units.
2025-08-07 01:33:36 -07:00
Mathias Agopian
7f18c7fd43 fix -d (matdbg) build option
There was two problems:
- tint was needed regardless of webgpu support
- libfilamat wasn't built on the android side
  (I don't know how it ever worked)
2025-08-06 17:29:51 -07:00
Eliza
5924633085 gl: amortize shader compilation over N frames (#8964)
* gl: amortize shader compilation over N frames

On platforms which don't support parallel shader compilation (e.g. Firefox), we
can sort of emulate it by queueing up any requests to `Material::compile()` and
compiling each shader over multiple frames.

Compiling over consecutive frames slows things quite noticeably. Instead, space
each compilation over a number of ticks (16 chosen arbitrarily).

If we need a program NOW, we can bump a program queued for much later to the
front. We also avoid compiling any queued programs on this same frame to limit
stuttering.

* gl: add flag to disable amortized shader compile

If this flag is on, the new amortized compile code should theoretically never be
executed.

* gl: add CompilerPriorityQueue docs, Java API

* gl: amortize shaders, z3moon feedback

* gl: update CompilerThreadPool
2025-08-06 21:09:27 +00:00
Powei Feng
ac076e872e Release Filament 1.63.0 2025-08-05 22:59:34 -07:00
Benjamin Doherty
bbced6d59d Release Filament 1.62.2 2025-07-31 10:27:23 -07:00
Mathias Agopian
70d41664b5 Add Renderer::shouldRenderFrame() API
FIXES=[410463814]
2025-07-30 15:32:23 -07:00
Sungun Park
36f7911917 Release Filament 1.62.1 2025-07-14 23:11:18 +00:00
Mathias Agopian
29ed42fa98 dynamic resolution can be always be enable if minScale==maxScale
normally dynamic resolution is turned off when timerQueries are no
available, but we should still allow it if minScale==maxScale.

FIXES=[428767320]
2025-07-14 10:32:48 -07:00
Mathias Agopian
f6f7082b55 Make libfilament.java use libfilament-generatePrefilterMipmap 2025-07-07 14:16:16 -07:00
Powei Feng
74445904f2 Release Filament 1.62.0 2025-06-30 16:39:15 -07:00
Powei Feng
3d0653604f android: add static, default model for gltf-viewer (#8898)
The default gltf for android's gltf-viewer is the buster drone,
which uses skinning.

We add an additional model (damaged helmet) as an alternative
default. This will be useful for debugging WebGPU, where skinnning is
not yet supported. This alternate path can only be invoke by starting
the app through adb:

  `adb shell am start -n com.google.android.filament.gltf/.MainActivity --ez "use-static-model" true`
2025-06-26 19:15:54 +00:00