• Jeremy Reizenstein's avatar
    Deduplicate texture maps when joining · e12a0813
    Jeremy Reizenstein authored
    Summary:
    If you join several meshes which have TexturesUV textures using join_meshes_as_scene then we amalgamate all the texture images in to a single one. This now checks if some of the images are equal (i.e. the tensors are the same tensor, in the `is` sense; they have the same `id` in Python) and only uses one copy if they are.
    
    I have an example of a massive scene made of several textured meshes with some shared, where this makes the difference between fitting the data on the GPU and not.
    
    Reviewed By: theschnitz
    
    Differential Revision: D25982364
    
    fbshipit-source-id: a8228805f38475c796302e27328a340d9b56c8ef
    e12a0813
test_texturing.py 38.8 KB