fix [#29063] reprojetion painting : failed to create opengl offscreen buffer
error report was not passed into the UI and only printed into the terminal, now shows an error popup.
This commit is contained in:
@@ -145,7 +145,11 @@ class ProjectEdit(Operator):
|
|||||||
for image in bpy.data.images:
|
for image in bpy.data.images:
|
||||||
image.tag = True
|
image.tag = True
|
||||||
|
|
||||||
if 'FINISHED' not in bpy.ops.paint.image_from_view():
|
# opengl buffer may fail, we can't help this, but best report it.
|
||||||
|
try:
|
||||||
|
ret = bpy.ops.paint.image_from_view()
|
||||||
|
except RuntimeError as err:
|
||||||
|
self.report({'ERROR'}, str(err))
|
||||||
return {'CANCELLED'}
|
return {'CANCELLED'}
|
||||||
|
|
||||||
image_new = None
|
image_new = None
|
||||||
|
Reference in New Issue
Block a user