summaryrefslogtreecommitdiff
path: root/indra/llprimitive/llgltfmaterial.h
AgeCommit message (Collapse)Author
2023-12-06Fix LLGLTFMaterial hashingHenri Beauchamp
This PR fixes the non-working material hashing for LLGLTFMaterial instances. There are several issues in the current code, stemming to the fact that the hashing is performed on the block of the member variables: 1.- There are padding bytes between member variables, even after rearranging them to avoid most of the padding; in particular, the std::array's size is not a multiple of 4 bytes (64 bits), and most compilers will pad them to the next 4-byte aligment as a result. Note that C++ standards do not impose the zeroing of padding bytes on construction of a class instance, with only a couple exceptions (such as explicit zero-initialization). Those bytes MUST therefore be zeroed by us on construction. 2.- The TextureTransform strutcure getPacked() method did not touch some of the packed bytes, and as a result could *potentially* cause an issue for hashing when applied to a transform of another material instance. 3.- With the recent addition of the local textures tracking map, the said map cannot be hashed as a block of memory (map pairs will typically be allocated on the heap or on the stack, not in the memory block used by member variables). This PR solves all these issues and offers proper hashing of LLGLTFMaterial instances.
2023-11-06SL-20523 Local textures not updating on PBR Materials #5Andrey Kleshchev
2023-11-06SL-20523 Local textures not updating on PBR Materials #4Andrey Kleshchev
2023-11-06SL-20523 Local textures not updating on PBR Materials #3Andrey Kleshchev
2023-11-06SL-20523 Local textures not updating on PBR Materials #2Andrey Kleshchev
2023-11-06SL-20523 Local textures not updating on PBR Materials #1Andrey Kleshchev
Update editor in which texture changed to local
2023-10-25Fix DRTVWR-559 std::array usage in llrender and llprimitive after mergeBrad Linden
2023-10-09SL-20225: LLGLTFMaterial code syncCosmic Linden
2023-08-29SL-20229 Add GenericStreamingMessage and use it to receive GLTF material ↵RunitaiLinden
overrides
2023-05-03Improved fix for SL-19675 crash. How about just don't refer to data when ↵Brad Linden
you don't need it
2023-04-21SL-19606: Fix missing GLTF texture transforms in PBR alpha mask/alpha blend ↵Cosmic Linden
shadows
2023-03-23SL-19169 Local material updates aren't applied with non-default transformsAndrey Kleshchev
2023-03-22DRTVWR-559 Fix for bad hashing of materials breaking render batches and who ↵Dave Parks
knows what else.
2023-03-02SL-19281 Unify handling of haze and gamma between fullbright and not and ↵Dave Parks
move haze back to sRGB color space to stay consistent with sky colors. Also fix broken "roughness" stuck at 0.2.
2023-02-27SL-19279: LLGLSLShader::bindXXX is not free. Pack the uniformsCosmic Linden
2023-02-15SL-19121: Address review comments from SL-19080 phase 2Cosmic Linden
2023-02-14Merge pull request #73 from secondlife/SL-19080cosmic-linden
SL-19080: GLTF Material asset consistency: Part 2: Update viewer GLTF Material asset upload to v1.1
2023-02-09SL-19080: Address clang-provided errorsCosmic Linden
2023-02-09SL-19080: Update GLTF Material asset upload to v1.1, with stricter GLTF ↵Cosmic Linden
compliance and removal of unsupported features
2023-02-02SL-18908 Make media texture override base color and emissive texture on PBR ↵Dave Parks
materials when present.
2023-01-10SL-18820: Fix applying material clearing transform overrides. Loosen some ↵Cosmic Linden
asserts to allow non-default transform overrides.
2023-01-09SL-18820: Update LLGLTFMaterial: Add setBaseMaterial() and equality comparisonCosmic Linden
2022-11-14SL-18634: Fix GLTF material texture transform not serializing when texture ↵Cosmic Linden
ID is null
2022-11-09Revert "SL-18523: When editing an object's material override, use the ↵Sabrina Shanman
object's material override as a base, rather than its render material (pull request #1190)"
2022-11-08SL-18523: When editing an object's material override, use the object's ↵Cosmic Linden
material override as a base, rather than its render material
2022-11-02SL-18485: Render GLTF materials with extension KHR_texture_transform with ↵Cosmic Linden
approprate texture transforms
2022-11-02SL-18520 Use GLTF material.extras to pass flags for enabling overriding ↵Dave Parks
alpha mode and double sided to default
2022-11-01SL-18520 WIP - Use off-by-epsilon and special UUID identifier hacks to allow ↵Dave Parks
overriding to default values.
2022-10-31SL-18442 Port of Caladbolg's fix for emissive overrides not taking. Remove ↵Dave Parks
unused function.
2022-10-27SL-18411: GLTF material transform serialization, plus fix improper indexing ↵Cosmic Linden
not matching GLTF spec
2022-10-20SL-18411: Copy over LLGLTFMaterial changes (most notably various ↵Cosmic Linden
getters/setters and texture transform stub)
2022-10-19SL-18105 Hook up TE override material to render pipe by way of render material.Dave Parks
2022-10-19SL-18105 Hook up render pipe directly to LLTextureEntry::mGLTFMaterial and ↵Dave Parks
add LLViewerFetchedTextures to LLFetchedGLTFMaterial. Lower reflection probe resolution to 128x128 per side.
2022-10-17WIP for SL-17697 live editing now computes diffs of changed material ↵Brad Kittenbrink
properties in tinygltf schema json
2022-10-14SL-18105 Add to/from json capability to LLGLTFMaterialDave Parks
2022-09-23SL-18134 Rename Albedo to Base Color to be more consistent with GLTF specDave Parks
2022-08-08SL-17937 Fix for broken PBR material batching.Dave Parks
2022-06-29SL-17685 Drag and drop material supportDave Parks
2022-06-28SL-17379 More complete integration of material asset typeDave Parks
2022-06-23SL-17653 Last commit was accidentally partialDave Parks