- Timestamp:
- Sep 8, 2009 11:13:06 AM (15 years ago)
- Location:
- trunk/src/VBox/GuestHost/OpenGL/state_tracker
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/GuestHost/OpenGL/state_tracker/state_bufferobject.c
r21308 r22831 55 55 CRBufferObject *pObj = (CRBufferObject *)data; 56 56 if (pObj->data) crFree(pObj->data); 57 58 if (diff_api.AlphaFunc) 59 { 60 diff_api.DeleteBuffersARB(1, &pObj->name); 61 } 62 57 63 crFree(pObj); 58 64 } -
trunk/src/VBox/GuestHost/OpenGL/state_tracker/state_framebuffer.c
r22363 r22831 44 44 } 45 45 46 static void crStateFreeFBO(void *data) 47 { 48 CRFramebufferObject *pObj = (CRFramebufferObject *)data; 49 50 if (diff_api.AlphaFunc) 51 { 52 diff_api.DeleteFramebuffersEXT(1, &pObj->id); 53 } 54 55 crFree(pObj); 56 } 57 58 static void crStateFreeRBO(void *data) 59 { 60 CRRenderbufferObject *pObj = (CRRenderbufferObject *)data; 61 62 if (diff_api.AlphaFunc) 63 { 64 diff_api.DeleteRenderbuffersEXT(1, &pObj->id); 65 } 66 67 crFree(pObj); 68 } 69 46 70 DECLEXPORT(void) STATE_APIENTRY 47 71 crStateFramebufferObjectDestroy(CRContext *ctx) … … 52 76 fbo->renderbuffer = NULL; 53 77 54 crFreeHashtable(fbo->framebuffers, cr Free);55 crFreeHashtable(fbo->renderbuffers, cr Free);78 crFreeHashtable(fbo->framebuffers, crStateFreeFBO); 79 crFreeHashtable(fbo->renderbuffers, crStateFreeRBO); 56 80 } 57 81 … … 246 270 { 247 271 fbo->framebuffer = (CRFramebufferObject*) crCalloc(sizeof(CRFramebufferObject)); 248 CRSTATE_FBO_CHECKERR(!fbo-> renderbuffer, GL_OUT_OF_MEMORY, "glBindFramebufferEXT");272 CRSTATE_FBO_CHECKERR(!fbo->framebuffer, GL_OUT_OF_MEMORY, "glBindFramebufferEXT"); 249 273 fbo->framebuffer->id = framebuffer; 250 274 crStateInitFrameBuffer(fbo->framebuffer);
Note:
See TracChangeset
for help on using the changeset viewer.