PyAPI: remove deprecated 2D_/3D_ prefix for built-in shader names

Names passed to gpu.shader.from_builtin()
no longer skip the 2D_/3D_ prefix.
This commit is contained in:
Campbell Barton
2023-05-23 15:51:54 +10:00
parent fd68f977e0
commit 9a8fd2f1dd
6 changed files with 7 additions and 25 deletions

View File

@@ -12,7 +12,7 @@ IMAGE_NAME = "Untitled"
image = bpy.data.images[IMAGE_NAME]
texture = gpu.texture.from_image(image)
shader = gpu.shader.from_builtin('2D_IMAGE')
shader = gpu.shader.from_builtin('IMAGE')
batch = batch_for_shader(
shader, 'TRI_FAN',
{
@@ -45,7 +45,7 @@ IMAGE_NAME = "Untitled"
image = bpy.data.images[IMAGE_NAME]
texture = gpu.texture.from_image(image)
shader = gpu.shader.from_builtin('3D_IMAGE')
shader = gpu.shader.from_builtin('IMAGE')
batch = batch_for_shader(
shader, 'TRIS',
{