Changeset 21127 in vbox for trunk/src/VBox/Additions/common/crOpenGL
- Timestamp:
- Jul 1, 2009 2:25:14 PM (16 years ago)
- Location:
- trunk/src/VBox/Additions/common/crOpenGL/pack
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/crOpenGL/pack/packspu_context.c
r15758 r21127 82 82 packspu_CreateContext( const char *dpyName, GLint visual, GLint shareCtx ) 83 83 { 84 GET_THREAD(thread); 84 85 int writeback = 1; 85 86 GLint serverCtx = (GLint) -1; … … 89 90 crLockMutex(&_PackMutex); 90 91 #endif 92 93 if (!thread) { 94 thread = packspuNewThread(crThreadID()); 95 } 96 CRASSERT(thread); 97 CRASSERT(thread->packer); 91 98 92 99 if (shareCtx > 0) { … … 98 105 } 99 106 100 crPackSetContext( pack_spu.thread[0].packer );107 crPackSetContext( thread->packer ); 101 108 102 109 /* Pack the command */ … … 107 114 108 115 /* Flush buffer and get return value */ 109 packspuFlush( &(pack_spu.thread[0]));110 if (!( pack_spu.thread[0].netServer.conn->actual_network))116 packspuFlush(thread); 117 if (!(thread->netServer.conn->actual_network)) 111 118 { 112 119 /* HUMUNGOUS HACK TO MATCH SERVER NUMBERING -
trunk/src/VBox/Additions/common/crOpenGL/pack/packspu_misc.c
r20148 r21127 112 112 GLint PACKSPU_APIENTRY packspu_WindowCreate( const char *dpyName, GLint visBits ) 113 113 { 114 GET_THREAD(thread); 114 115 static int num_calls = 0; 115 116 int writeback = pack_spu.thread[0].netServer.conn->actual_network; 116 117 GLint return_val = (GLint) 0; 117 118 118 /* WindowCreate is special - just like CreateContext.119 * GET_THREAD(thread) doesn't work as the thread won't have called120 * MakeCurrent yet, so we've got to use the first thread's packer121 * buffer.122 */123 124 crPackSetContext( pack_spu.thread[0].packer);119 if (!thread) { 120 thread = packspuNewThread( crThreadID() ); 121 } 122 CRASSERT(thread); 123 CRASSERT(thread->packer); 124 125 crPackSetContext(thread->packer); 125 126 126 127 if (pack_spu.swap) … … 132 133 crPackWindowCreate( dpyName, visBits, &return_val, &writeback ); 133 134 } 134 packspuFlush( &pack_spu.thread[0]);135 if (!( pack_spu.thread[0].netServer.conn->actual_network))135 packspuFlush(thread); 136 if (!(thread->netServer.conn->actual_network)) 136 137 { 137 138 return num_calls++;
Note:
See TracChangeset
for help on using the changeset viewer.