Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_image_api.c
| Show First 20 Lines • Show All 216 Lines • ▼ Show 20 Lines | |||||
| } | } | ||||
| static int rna_Image_gl_load(Image *image, ReportList *reports, int frame) | static int rna_Image_gl_load(Image *image, ReportList *reports, int frame) | ||||
| { | { | ||||
| ImageUser iuser; | ImageUser iuser; | ||||
| BKE_imageuser_default(&iuser); | BKE_imageuser_default(&iuser); | ||||
| iuser.framenr = frame; | iuser.framenr = frame; | ||||
| GPUTexture *tex = GPU_texture_from_blender(image, &iuser, GL_TEXTURE_2D); | GPUTexture *tex = GPU_texture_from_blender(image, &iuser, NULL, GL_TEXTURE_2D); | ||||
| if (tex == NULL) { | if (tex == NULL) { | ||||
| BKE_reportf(reports, RPT_ERROR, "Failed to load image texture '%s'", image->id.name + 2); | BKE_reportf(reports, RPT_ERROR, "Failed to load image texture '%s'", image->id.name + 2); | ||||
| return (int)GL_INVALID_OPERATION; | return (int)GL_INVALID_OPERATION; | ||||
| } | } | ||||
| return GL_NO_ERROR; | return GL_NO_ERROR; | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 148 Lines • Show Last 20 Lines | |||||