Skip to content
  • Chris Forbes's avatar
    mesa: fix texture view use of _mesa_get_tex_image() · 8bb666ce
    Chris Forbes authored
    
    
    The target parameter to _mesa_get_tex_image() is a target enum, not an index.
    When we're setting up faces for a cubemap, it should be
    CUBE_MAP_POSITIVE_X .. CUBE_MAP_NEGATIVE_Z; for all other targets it
    should be the same as the texobj's target.
    
    Fixes broken cubemaps [had only +X face but claimed to have all] produced by
    glTextureView, which then caused various crashes in the driver when we
    tried to use them.
    
    Signed-off-by: default avatarChris Forbes <chrisf@ijw.co.nz>
    Reviewed-by: default avatarBrian Paul <brianp@vmware.com>
    8bb666ce