Commit Graph

14 Commits

Author SHA1 Message Date
Ben Doherty
b759074c8f Deprecate set method on MaterialBuilder (#545)
* Remove the defines entry in material definitions

* Deprecate set function

* Remove some getter methods from MaterilaBuilder

* Fix tests, add to CI
2018-11-28 15:35:19 -08:00
Ben Doherty
a1ed3b81a3 Move static code analysis into filamat (#534)
* Handle static code analysis automatically

* Fix matc test cases

* Only call InitializeProcess once per process
2018-11-27 14:11:27 -08:00
Ben Doherty
6d158bbc80 Remove codeGenTargetApi (#511) 2018-11-26 10:51:34 -08:00
Ben Doherty
b5fa822e86 Move GLSLPostProcessor and dependencies into filamat (#500)
* Move GLSLPostProcessor into filamat
2018-11-20 12:30:26 -08:00
Philip Rideout
55eaad9450 Add smol-v to third_party.
Since we use this for decoding, this adds a dependency to the core
filament renderer which in practice is only used for Vulkan. However
this is a tiny library, so it's simplest just to always include it.

The next PR will add the actual compression / decompression code to
filaflat and filamat. Here are the preliminary results.

   102K =>  29K  aiDefaultMat.filamat
   102K =>  29K  aiDefaultTrans.filamat
    21K => 5.0K  bakedColor.filamat
    22K => 5.2K  bakedTexture.filamat
    21K => 5.0K  depthVisualizer.filamat
    40K =>  10K  groundShadow.filamat
   102K =>  29K  sandboxCloth.filamat
   125K =>  36K  sandboxLit.filamat
   126K =>  36K  sandboxLitFade.filamat
   126K =>  36K  sandboxLitTransparent.filamat
   109K =>  31K  sandboxSubsurface.filamat
    21K => 4.9K  sandboxUnlit.filamat
    21K => 4.9K  transparentColor.filamat

Both the "before" and "after" numbers are excluding non-Vulkan targets,
and I also changed our CMakeLists to build filamat instead of inc.
2018-11-15 16:55:40 -08:00
Romain Guy
f1c2c39a3d Cleanup matc a little bit (#488) 2018-11-14 11:58:06 -08:00
Mathias Agopian
912b301790 Try to bring some sanity to our UBO structures
- move UBO declarations in UibGenerator, i.e. next
  to their Uniform Interface Block definition.
  This should help forgetting to update one but
  not the other.

- move UniformInterfaceBlock.h and SamplerInferfaceBlock.h under
  private/filament/.

- do the same things for samplers
2018-10-24 15:11:54 -07:00
Ben Doherty
13cb47eead Fix incorrect SPIR-V instructions (#297)
* Add shaders to a program and link

* Remove glslang scope

* Add call to link for preprocessor-only optimization

* Add comment
2018-09-24 16:34:50 -07:00
Romain Guy
91279fa818 Exclude comments from brace parsing in vertex/fragment blocks (#200)
* Exclude comments from brace parsing in vertex/fragment blocks

If a comment contained an opening brace { but not the matching
closing one, matc would not count braces properly and not find
the proper end of a vertex/fragment block.

* Add test
2018-09-04 12:03:16 -07:00
Romain Guy
4585b8f896 Add clearCoatNormal property (#131)
* Add clear coat normal map support

This change allows to set a separate normal map for the clear coat layer of a material.

* Document the new clearCoatNormal property

* Fix typo
2018-08-24 08:56:44 -07:00
Romain Guy
9f2592ed9d Update SPIRV libraries (#99)
* Update SPIRV libraries

- Update `spirv-cross`
- Update `spirv-tools`
- Update `glslang`

`spirv-tools` contains a fix for an issue we reported (unnecessary promotions to highp in certain expressions).

* Add SPIRV-Tools dependency to matinfo
2018-08-15 12:59:17 -07:00
Romain Guy
bb75923b79 Fix post-process shader when not in Vulkan (#41)
* Fix post-process shader when not in Vulkan

The post-process shader must not flip the source texture when we compile for OpenGL. This happens because we use SPIR-V/Vulkan as an intermediate format.

* Fix the Android build

We need to output a location when targeting SPIR-V for mobile.
2018-08-07 18:46:30 -07:00
Tact Yoshida
ad49986245 Remove execute permissions 2018-08-06 10:36:54 -07:00
Romain Guy
b3d758f3b3 Initial commit 2018-08-03 10:38:22 -07:00