Changeset 278
- Timestamp:
- 06/26/08 06:40:59 (4 months ago)
- Files:
-
- GtkRadiant/trunk/plugins/entity/light.cpp (modified) (3 diffs)
- GtkRadiant/trunk/plugins/imagem8/m32.cpp (modified) (2 diffs)
- GtkRadiant/trunk/plugins/imagem8/m8.cpp (modified) (3 diffs)
- GtkRadiant/trunk/plugins/imagewal/wal.cpp (modified) (2 diffs)
- GtkRadiant/trunk/plugins/map/parse.cpp (modified) (1 diff)
- GtkRadiant/trunk/plugins/map/write.cpp (modified) (2 diffs)
- GtkRadiant/trunk/plugins/shaders/plugin.cpp (modified) (5 diffs)
- GtkRadiant/trunk/plugins/surface/surfacedialog.cpp (modified) (5 diffs)
- GtkRadiant/trunk/plugins/surface_heretic2/surfacedialog.cpp (modified) (1 diff)
- GtkRadiant/trunk/plugins/surface_quake2/surfacedialog.cpp (modified) (5 diffs)
- GtkRadiant/trunk/plugins/surface_ufoai/surfacedialog.cpp (modified) (1 diff)
- GtkRadiant/trunk/radiant/texwindow.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
GtkRadiant/trunk/plugins/entity/light.cpp
r185 r278 244 244 bool bIsSpotLight = !!target[0]; 245 245 //!\todo Write an API for modules to register preference settings, and make this preference module-specific. 246 int nPasses = pref == 1 ? 3 : 2;246 // int nPasses = pref == 1 ? 3 : 2; 247 247 248 248 g_QglTable.m_pfn_qglPushAttrib(GL_DEPTH_BUFFER_BIT | GL_COLOR_BUFFER_BIT); … … 288 288 void DrawLight(entity_t* e, int nGLState, int pref, int nViewType) 289 289 { 290 int i;290 // int i; 291 291 // top, bottom, tleft, tright, bright, bleft 292 292 vec3_t points[6]; … … 480 480 g_QglTable.m_pfn_qglEnable(GL_LINE_STIPPLE); 481 481 482 float* envelope = (pref == 1) ? e->fLightEnvelope1 : e->fLightEnvelope2; 482 float* envelope = (pref == 1) ? e->fLightEnvelope1 : e->fLightEnvelope2; 483 483 for (int iPass = 0; iPass < nPasses; iPass++) 484 484 { GtkRadiant/trunk/plugins/imagem8/m32.cpp
r195 r278 27 27 void LoadM32(const char *name, unsigned char **pic, int *width, int *height) 28 28 { 29 FILE *f;29 // FILE *f; 30 30 m32_header_t *m32_header; 31 31 //rgb_t *palette; 32 32 int i, num_pixels, size; 33 char text_buf[255];33 // char text_buf[255]; 34 34 unsigned int length; 35 35 unsigned char *palette_ent, *buf_temp; … … 37 37 38 38 // open file 39 if ( length = vfsLoadFile ((char *) name, (void **) &m32_file_buffer, 0) == (unsigned int) -1)39 if ( (length = vfsLoadFile ((char *) name, (void **) &m32_file_buffer, 0)) == (unsigned int) -1) 40 40 { 41 41 Sys_Printf("Unable to open file %s\n",name); GtkRadiant/trunk/plugins/imagem8/m8.cpp
r195 r278 27 27 void LoadM8(const char *name, unsigned char **pic, int *width, int *height) 28 28 { 29 FILE *f;29 // FILE *f; 30 30 m8_header_t *m8_header; 31 31 rgb_t *palette; … … 45 45 46 46 // open file 47 if ( length = vfsLoadFile ((char *) text_buf, (void **) &m8_file_buffer, 0) == (unsigned int) -1)47 if ( (length = vfsLoadFile ((char *) text_buf, (void **) &m8_file_buffer, 0)) == (unsigned int) -1) 48 48 { 49 49 strcpy(text_buf, name); … … 63 63 } 64 64 } 65 65 66 66 m8_header = (m8_header_t *)m8_file_buffer; 67 67 GtkRadiant/trunk/plugins/imagewal/wal.cpp
r195 r278 31 31 void LoadWAL(const char *name, unsigned char **pic, int *width, int *height) 32 32 { 33 FILE *f;33 // FILE *f; 34 34 miptex_t *wal_header; 35 rgb_t *palette;35 // rgb_t *palette; 36 36 int i, num_pixels, size; 37 char text_buf[255];37 // char text_buf[255]; 38 38 unsigned int length; 39 39 unsigned char *palette_ent, *buf_temp; … … 41 41 42 42 // open file 43 if ( length = vfsLoadFile ((char *) name, (void **) &wal_file_buffer, 0) == (unsigned int) -1)43 if ( (length = vfsLoadFile ((char *) name, (void **) &wal_file_buffer, 0)) == (unsigned int) -1) 44 44 { 45 45 Sys_Printf("Unable to open file %s\n",name); GtkRadiant/trunk/plugins/map/parse.cpp
r185 r278 570 570 { 571 571 brush_t *pBrush; 572 CPtrArray *brushes = NULL;572 // CPtrArray *brushes = NULL; 573 573 char temptoken[1024]; 574 574 GtkRadiant/trunk/plugins/map/write.cpp
r185 r278 53 53 out->printf("patchDef2\n{\n%s\n( %i %i 0 0 0 )\n", 54 54 str, pPatch->width, pPatch->height); 55 55 56 56 // write matrix 57 57 out->printf("(\n"); … … 118 118 { 119 119 char *pos; 120 while ( pos = (char*)strchr( str, '/' )) {120 while ( (pos = (char*)strchr( str, '/' )) != NULL ) { 121 121 str = pos+1; // to speed optimize, change the "while" to an "if" 122 122 } GtkRadiant/trunk/plugins/shaders/plugin.cpp
r185 r278 3 3 All rights reserved. 4 4 5 Redistribution and use in source and binary forms, with or without modification, 5 Redistribution and use in source and binary forms, with or without modification, 6 6 are permitted provided that the following conditions are met: 7 7 8 Redistributions of source code must retain the above copyright notice, this list 8 Redistributions of source code must retain the above copyright notice, this list 9 9 of conditions and the following disclaimer. 10 10 … … 13 13 other materials provided with the distribution. 14 14 15 Neither the name of Loki software nor the names of its contributors may be used 16 to endorse or promote products derived from this software without specific prior 17 written permission. 15 Neither the name of Loki software nor the names of its contributors may be used 16 to endorse or promote products derived from this software without specific prior 17 written permission. 18 18 19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' 20 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 21 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 22 DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY 23 DIRECT,INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 24 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 25 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON 26 ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 28 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' 20 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 21 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 22 DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY 23 DIRECT,INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 24 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 25 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON 26 ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 28 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 29 */ 30 30 … … 47 47 _QERBrushTable g_BrushTable; 48 48 49 static bool g_bInterfaceInitDone = false;49 // static bool g_bInterfaceInitDone = false; 50 50 51 51 // ============================================================================= … … 55 55 CSynapseClientShaders g_SynapseClient; 56 56 57 static const XMLConfigEntry_t entries[] = 58 { 57 static const XMLConfigEntry_t entries[] = 58 { 59 59 { SHADERS_MAJOR, SYN_PROVIDE, sizeof(_QERShadersTable), NULL }, 60 60 { VFS_MAJOR, SYN_REQUIRE, sizeof(g_VFSTable), &g_VFSTable }, … … 76 76 g_pSynapseServer->IncRef(); 77 77 Set_Syn_Printf(g_pSynapseServer->Get_Syn_Printf()); 78 78 79 79 if ( !g_SynapseClient.ConfigXML( pServer, NULL, entries ) ) { 80 80 return NULL; 81 81 } 82 82 83 83 g_SynapseClient.AddAPI(RADIANT_MAJOR, NULL, sizeof(_QERFuncTable_1), SYN_REQUIRE, &g_FuncTable); 84 84 g_SynapseClient.AddAPI(DATA_MAJOR, NULL, sizeof(_QERAppDataTable), SYN_REQUIRE, &g_DataTable); GtkRadiant/trunk/plugins/surface/surfacedialog.cpp
r264 r278 220 220 texdef_t* tmp_texdef; 221 221 texdef_to_face_t* temp_texdef_face_list; 222 char buf[12];222 // char buf[12]; 223 223 char texture_name[128]; 224 224 … … 258 258 temp_texdef_face_list = get_texdef_face_list()->next; 259 259 260 for ( temp_texdef_face_list; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next)260 for (; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next) 261 261 { 262 262 tmp_texdef = &temp_texdef_face_list->texdef; … … 316 316 char blank[1]; 317 317 GList *items = NULL; 318 GList *tmp_item;318 // GList *tmp_item; 319 319 int num_of_list_items = 0; 320 320 … … 382 382 if (!texdef_face_list_empty()) 383 383 { 384 texdef_to_face_t* p = get_texdef_face_list();384 // texdef_to_face_t* p = get_texdef_face_list(); 385 385 GetSelFacesTexdef( get_texdef_face_list() ); 386 386 } … … 1863 1863 { 1864 1864 texdef_t* tmp_texdef; 1865 texdef_t* tmp_orig_texdef;1865 // texdef_t* tmp_orig_texdef; 1866 1866 texdef_to_face_t* temp_texdef_face_list; 1867 1867 GtkRadiant/trunk/plugins/surface_heretic2/surfacedialog.cpp
r264 r278 263 263 temp_texdef_face_list = get_texdef_face_list()->next; 264 264 265 for ( temp_texdef_face_list; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next)265 for (; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next) 266 266 { 267 267 tmp_texdef = &temp_texdef_face_list->texdef; GtkRadiant/trunk/plugins/surface_quake2/surfacedialog.cpp
r264 r278 225 225 texdef_t* tmp_texdef; 226 226 texdef_to_face_t* temp_texdef_face_list; 227 char buf[12];227 // char buf[12]; 228 228 char texture_name[128]; 229 229 … … 263 263 temp_texdef_face_list = get_texdef_face_list()->next; 264 264 265 for ( temp_texdef_face_list; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next)265 for (; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next) 266 266 { 267 267 tmp_texdef = &temp_texdef_face_list->texdef; … … 321 321 char blank[1]; 322 322 GList *items = NULL; 323 GList *tmp_item;323 // GList *tmp_item; 324 324 int num_of_list_items = 0; 325 325 … … 387 387 if (!texdef_face_list_empty()) 388 388 { 389 texdef_to_face_t* p = get_texdef_face_list();389 // texdef_to_face_t* p = get_texdef_face_list(); 390 390 GetSelFacesTexdef( get_texdef_face_list() ); 391 391 } … … 1876 1876 { 1877 1877 texdef_t* tmp_texdef; 1878 texdef_t* tmp_orig_texdef;1878 // texdef_t* tmp_orig_texdef; 1879 1879 texdef_to_face_t* temp_texdef_face_list; 1880 1880 GtkRadiant/trunk/plugins/surface_ufoai/surfacedialog.cpp
r264 r278 263 263 temp_texdef_face_list = get_texdef_face_list()->next; 264 264 265 for ( temp_texdef_face_list; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next)265 for (; temp_texdef_face_list; temp_texdef_face_list = temp_texdef_face_list->next) 266 266 { 267 267 tmp_texdef = &temp_texdef_face_list->texdef; GtkRadiant/trunk/radiant/texwindow.cpp
r264 r278 265 265 texturing = false; 266 266 break; 267 default: 268 return; 267 269 } 268 270
