[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15249] trunk/blender: Merge of apricot branch game engine changes into trunk, excluding GLSL.
Revision: 15249 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15249 Author: blendix Date: 2008-06-17 12:27:34 +0200 (Tue, 17 Jun 2008) Log Message: --- Merge of apricot branch game engine changes into trunk, excluding GLSL. GLEW Added the GLEW opengl extension library into extern/, always compiled into Blender now. This is much nicer than doing this kind of extension management manually, and will be used in the game engine, for GLSL, and other opengl extensions. * According to the GLEW website it works on Windows, Linux, Mac OS X, FreeBSD, Irix, and Solaris. There might still be platform specific issues due to this commit, so let me know and I'll look into it. * This means also that all extensions will now always be compiled in, regardless of the glext.h on the platform where compilation happens. Game Engine === Refactoring of the use of opengl extensions and other drawing code in the game engine, and cleaning up some hacks related to GLSL integration. These changes will be merged into trunk too after this. The game engine graphics demos apricot level survived my tests, but this could use some good testing of course. For users: please test with the options Generate Display Lists and Vertex Arrays enabled, these should be the fastest and are supposed to be unreliable, but if that's the case that's probably due to bugs that can be fixed. * The game engine now also uses GLEW for extensions, replacing the custom opengl extensions code that was there. Removes a lot of #ifdef's, but the runtime checks stay of course. * Removed the WITHOUT_GLEXT environment variable. This was added to work around a specific bug and only disabled multitexturing anyway. It might also have caused a slowdown since it was retrieving the environment variable for every vertex in immediate mode (bug #13680). * Refactored the code to allow drawing skinned meshes with vertex arrays too, removing some specific immediate mode drawing functions for this that only did extra normal calculation. Now it always splits vertices of flat faces instead. * Refactored normal recalculation with some minor optimizations, required for the above change. * Removed some outdated code behind the __NLA_OLDDEFORM #ifdef. * Fixed various bugs in setting of multitexture coordinates and vertex attributes for vertex arrays. These were not being enabled/disabled correct according to the opengl spec, leading to crashes. Also tangent attributes used an immediate mode call for vertex arrays, which can't work. * Fixed use of uninitialized variable in RAS_TexVert. * Exporting skinned meshes was doing O(n^2) lookups for vertices and deform weights, now uses same trick as regular meshes. Modified Paths: -- trunk/blender/blenderplayer/CMakeLists.txt trunk/blender/extern/CMakeLists.txt trunk/blender/extern/Makefile trunk/blender/extern/SConscript trunk/blender/source/Makefile trunk/blender/source/blender/src/CMakeLists.txt trunk/blender/source/blender/src/Makefile trunk/blender/source/blender/src/SConscript trunk/blender/source/blender/src/usiblender.c trunk/blender/source/creator/CMakeLists.txt trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp trunk/blender/source/gameengine/BlenderRoutines/CMakeLists.txt trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderCanvas.h trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp trunk/blender/source/gameengine/BlenderRoutines/Makefile trunk/blender/source/gameengine/BlenderRoutines/SConscript trunk/blender/source/gameengine/Converter/BL_ArmatureObject.cpp trunk/blender/source/gameengine/Converter/BL_BlenderDataConversion.cpp trunk/blender/source/gameengine/Converter/BL_MeshDeformer.cpp trunk/blender/source/gameengine/Converter/BL_MeshDeformer.h trunk/blender/source/gameengine/Converter/BL_SkinDeformer.cpp trunk/blender/source/gameengine/Converter/BL_SkinDeformer.h trunk/blender/source/gameengine/Converter/BL_SkinMeshObject.cpp trunk/blender/source/gameengine/Converter/BL_SkinMeshObject.h trunk/blender/source/gameengine/Converter/KX_BlenderSceneConverter.cpp trunk/blender/source/gameengine/Converter/KX_BlenderSceneConverter.h trunk/blender/source/gameengine/GamePlayer/common/CMakeLists.txt trunk/blender/source/gameengine/GamePlayer/common/GPC_Canvas.h trunk/blender/source/gameengine/GamePlayer/common/GPC_PolygonMaterial.cpp trunk/blender/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp trunk/blender/source/gameengine/GamePlayer/common/GPC_RenderTools.h trunk/blender/source/gameengine/GamePlayer/common/Makefile trunk/blender/source/gameengine/GamePlayer/common/SConscript trunk/blender/source/gameengine/GamePlayer/ghost/CMakeLists.txt
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15250] branches/apricot/source/blender: Apricot Branch: GLSL
Revision: 15250 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15250 Author: blendix Date: 2008-06-17 16:21:33 +0200 (Tue, 17 Jun 2008) Log Message: --- Apricot Branch: GLSL * Added support for the ColorRamp node. * Added less than / greather than in the Math node. * Added support for all blend modes of the Mix node and all blend modes in the texture stack. * Added more Map To support, now available: Col, Nor, Csp, Ref, Spec, Amb, Hard, Alpha, Emit. * Possible fix for a GLEW / opengl include conflict on Mac OS X in playanim.c Modified Paths: -- branches/apricot/source/blender/blenkernel/BKE_texture.h branches/apricot/source/blender/blenkernel/intern/texture.c branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/material_shaders.glsl branches/apricot/source/blender/gpu/intern/material_shaders.glsl.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_math.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c branches/apricot/source/blender/src/playanim.c Modified: branches/apricot/source/blender/blenkernel/BKE_texture.h === --- branches/apricot/source/blender/blenkernel/BKE_texture.h2008-06-17 10:27:34 UTC (rev 15249) +++ branches/apricot/source/blender/blenkernel/BKE_texture.h2008-06-17 14:21:33 UTC (rev 15250) @@ -53,6 +53,7 @@ void init_colorband(struct ColorBand *coba, int rangetype); struct ColorBand *add_colorband(int rangetype); int do_colorband(struct ColorBand *coba, float in, float out[4]); +void colorband_table_RGBA(struct ColorBand *coba, float **array, int *size); void default_tex(struct Tex *tex); struct Tex *add_texture(char *name); Modified: branches/apricot/source/blender/blenkernel/intern/texture.c === --- branches/apricot/source/blender/blenkernel/intern/texture.c 2008-06-17 10:27:34 UTC (rev 15249) +++ branches/apricot/source/blender/blenkernel/intern/texture.c 2008-06-17 14:21:33 UTC (rev 15250) @@ -53,6 +53,7 @@ #include DNA_world_types.h #include DNA_brush_types.h #include DNA_node_types.h +#include DNA_color_types.h #include IMB_imbuf_types.h #include IMB_imbuf.h @@ -389,6 +390,17 @@ return 1; /* OK */ } +void colorband_table_RGBA(ColorBand *coba, float **array, int *size) +{ + int a; + + *size = CM_TABLE+1; + *array = MEM_callocN(sizeof(float)*(*size)*4, ColorBand); + + for(a=0; a*size; a++) + do_colorband(coba, (float)a/(float)CM_TABLE, (*array)[a*4]); +} + /* *** TEX */ void free_texture(Tex *tex) Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-06-17 10:27:34 UTC (rev 15249) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-06-17 14:21:33 UTC (rev 15250) @@ -146,6 +146,7 @@ struct GPUPass *next, *prev; ListBase nodes; + int firstbind; struct GPUOutput *output; struct GPUShader *shader; }; @@ -677,21 +678,28 @@ if (input-tex) { if (input-bindtex) { + if(pass-firstbind); GPU_texture_bind(input-tex, input-texid); GPU_shader_uniform_texture(shader, name, input-tex); } } - else if (input-arraysize) - GPU_shader_uniform_vector(shader, name, input-type, - input-arraysize, - (input-dynamicvec)? input-dynamicvec: input-vec); - else - GPU_shader_uniform_vector(shader, name, input-type, 1, - (input-dynamicvec)? input-dynamicvec: input-vec); + else if (input-arraysize) { + if(pass-firstbind || input-dynamicvec) + GPU_shader_uniform_vector(shader, name, input-type, + input-arraysize, + (input-dynamicvec)? input-dynamicvec: input-vec); + } + else { + if(pass-firstbind || input-dynamicvec) + GPU_shader_uniform_vector(shader, name, input-type, 1, + (input-dynamicvec)?
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15251] branches/apricot/source/blender: Apricot Branch: GLSL
Revision: 15251 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15251 Author: blendix Date: 2008-06-17 19:32:12 +0200 (Tue, 17 Jun 2008) Log Message: --- Apricot Branch: GLSL * Added support for Ramps, diffuse + specular, all inputs and blending methods are supported. Modified Paths: -- branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/material_shaders.glsl branches/apricot/source/blender/gpu/intern/material_shaders.glsl.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_rgb.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_value.c Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-06-17 14:21:33 UTC (rev 15250) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-06-17 17:32:12 UTC (rev 15251) @@ -80,6 +80,7 @@ struct GPUNode *next, *prev; char *name; + int tag; ListBase inputs; ListBase outputs; @@ -574,7 +575,7 @@ code = BLI_dynstr_get_cstring(ds); BLI_dynstr_free(ds); - //if(G.f G_DEBUG) printf(%s\n, code); + if(G.f G_DEBUG) printf(%s\n, code); return code; } @@ -624,7 +625,7 @@ BLI_dynstr_free(ds); - //if(G.f G_DEBUG) printf(%s\n, code); + if(G.f G_DEBUG) printf(%s\n, code); return code; } @@ -725,48 +726,6 @@ GPU_shader_unbind(shader); } -/* Pass create/free */ - -GPUPass *GPU_generate_pass(ListBase *nodes, struct GPUNodeLink *outlink, int vertexshader, int profile) -{ - GPUShader *shader; - GPUPass *pass; - char *vertexcode, *fragmentcode; - - /* generate code and compile with opengl */ - fragmentcode = code_generate_fragment(nodes, outlink-source); - vertexcode = (vertexshader)? code_generate_vertex(nodes, profile): NULL; - shader = GPU_shader_create(vertexcode, fragmentcode); - MEM_freeN(fragmentcode); - MEM_freeN(vertexcode); - - /* failed? */ - if (!shader) { - GPU_nodes_free(nodes); - return NULL; - } - - /* create pass */ - pass = MEM_callocN(sizeof(GPUPass), GPUPass); - - pass-nodes = *nodes; - pass-output = outlink-source; - pass-shader = shader; - pass-firstbind = 1; - - /* take ownership over nodes */ - memset(nodes, 0, sizeof(*nodes)); - - return pass; -} - -void GPU_pass_free(GPUPass *pass) -{ - GPU_shader_free(pass-shader); - GPU_nodes_free(pass-nodes); - MEM_freeN(pass); -} - /* Node Link Functions */ GPUNodeLink *GPU_node_link_create(int type) @@ -1164,3 +1123,85 @@ return node; } +/* Pass create/free */ + +void gpu_nodes_tag(GPUNodeLink *link) +{ + GPUNode *node; + GPUInput *input; + + if(!link-source) + return; + + node = link-source-node; + if(node-tag) + return; + + node-tag= 1; + for(input=node-inputs.first; input; input=input-next) + if(input-link) + gpu_nodes_tag(input-link); +} + +void gpu_nodes_prune(ListBase *nodes, GPUNodeLink *outlink) +{ + GPUNode *node, *next; + + for(node=nodes-first; node; node=node-next) + node-tag= 0; + + gpu_nodes_tag(outlink); + + for(node=nodes-first; node; node=next) { + next = node-next; + + if(!node-tag) { + BLI_remlink(nodes, node); + GPU_node_free(node); + } + } +} + +GPUPass *GPU_generate_pass(ListBase *nodes, GPUNodeLink *outlink, int vertexshader, int profile) +{ + GPUShader *shader; + GPUPass *pass; + char *vertexcode, *fragmentcode; + + /* prune unused nodes */ + gpu_nodes_prune(nodes, outlink); + + /* generate code and compile with opengl */ + fragmentcode = code_generate_fragment(nodes, outlink-source); + vertexcode = (vertexshader)? code_generate_vertex(nodes, profile): NULL; + shader = GPU_shader_create(vertexcode, fragmentcode); + MEM_freeN(fragmentcode); + MEM_freeN(vertexcode); + + /* failed? */ + if (!shader) { + GPU_nodes_free(nodes); + return NULL; + } + + /* create pass */ + pass = MEM_callocN(sizeof(GPUPass), GPUPass); + + pass-nodes = *nodes; + pass-output = outlink-source; + pass-shader = shader; + pass-firstbind = 1; + + /* take ownership over nodes */ + memset(nodes, 0, sizeof(*nodes)); + + return pass; +} + +void GPU_pass_free(GPUPass *pass) +{ +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15257] branches/apricot/source/blender: Apricot Branch: GLSL
Revision: 15257 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15257 Author: blendix Date: 2008-06-17 23:23:51 +0200 (Tue, 17 Jun 2008) Log Message: --- Apricot Branch: GLSL * Added support for the Material and Extended Material nodes. * Added support for node groups. * All nodes except Dynamic are now supported. Modified Paths: -- branches/apricot/source/blender/blenkernel/BKE_node.h branches/apricot/source/blender/blenkernel/intern/node.c branches/apricot/source/blender/gpu/GPU_material.h branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/material_shaders.glsl branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_camera.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_curves.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_geom.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_hueSatVal.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_invert.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_mapping.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_material.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_math.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_mixRgb.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_normal.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_output.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_rgb.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_sepcombRGB.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_squeeze.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_texture.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_value.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_vectMath.c Modified: branches/apricot/source/blender/blenkernel/BKE_node.h === --- branches/apricot/source/blender/blenkernel/BKE_node.h 2008-06-17 21:17:11 UTC (rev 15256) +++ branches/apricot/source/blender/blenkernel/BKE_node.h 2008-06-17 21:23:51 UTC (rev 15257) @@ -95,7 +95,7 @@ void *pydict; /* holds pointer to python script dictionary (scope)*/ /* gpu */ - struct GPUNode *(*gpufunc)(struct GPUMaterial *mat, struct bNode *node, struct GPUNodeStack *in, struct GPUNodeStack *out); + int (*gpufunc)(struct GPUMaterial *mat, struct bNode *node, struct GPUNodeStack *in, struct GPUNodeStack *out); } bNodeType; Modified: branches/apricot/source/blender/blenkernel/intern/node.c === --- branches/apricot/source/blender/blenkernel/intern/node.c2008-06-17 21:17:11 UTC (rev 15256) +++ branches/apricot/source/blender/blenkernel/intern/node.c2008-06-17 21:23:51 UTC (rev 15257) @@ -2379,6 +2379,8 @@ gs[i].name = ; gs[i].hasinput= ns[i]-hasinput; + gs[i].hasoutput= ns[i]-hasinput; + gs[i].sockettype= ns[i]-sockettype; } gs[i].type= GPU_NONE; @@ -2389,10 +2391,52 @@ bNodeSocket *sock; int i; - for (sock=sockets-first, i=0; sock; sock=sock-next, i++) + for (sock=sockets-first, i=0; sock; sock=sock-next, i++) { ns[i]-data= gs[i].link; + ns[i]-hasinput= gs[i].hasinput; + ns[i]-hasoutput= gs[i].hasoutput; + ns[i]-sockettype= gs[i].sockettype; + } } +static void gpu_node_group_execute(bNodeStack *stack, GPUMaterial *mat, bNode *gnode, bNodeStack **in, bNodeStack **out) +{ + bNode *node; + bNodeTree *ntree= (bNodeTree *)gnode-id; + bNodeStack *nsin[MAX_SOCKET]; /* arbitrary... watch this */ + bNodeStack *nsout[MAX_SOCKET]; /* arbitrary... watch this */ + GPUNodeStack gpuin[MAX_SOCKET+1], gpuout[MAX_SOCKET+1]; + int doit = 0; + + if(ntree==NULL) return; + + stack+= gnode-stack_index; + + for(node= ntree-nodes.first; node; node= node-next) { + if(node-typeinfo-gpufunc) { + group_node_get_stack(node, stack, nsin, nsout, in, out); + + doit = 0; + + /* for groups, only execute outputs for edited group */ + if(node-typeinfo-nclass==NODE_CLASS_OUTPUT) { + if(gnode-flag NODE_GROUP_EDIT) + if(node-flag NODE_DO_OUTPUT) + doit = 1; + } + else +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15258] branches/apricot/source/gameengine : Apricot Branch: GLSL
Revision: 15258 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15258 Author: blendix Date: 2008-06-18 00:03:17 +0200 (Wed, 18 Jun 2008) Log Message: --- Apricot Branch: GLSL * GLSL in the game engine now uses the second uv layer too. Modified Paths: -- branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.h branches/apricot/source/gameengine/Ketsji/BL_Material.cpp branches/apricot/source/gameengine/Ketsji/BL_Material.h branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp Modified: branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp === --- branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp 2008-06-17 21:23:51 UTC (rev 15257) +++ branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp 2008-06-17 22:03:17 UTC (rev 15258) @@ -310,6 +310,7 @@ Mesh* mesh, Material *mat, MTFace* tface, + const char *tfaceName, MFace* mface, MCol* mmcol, int lightlayer, @@ -588,6 +589,7 @@ } MT_Point2 uv[4]; MT_Point2 uv2[4]; + const char *uvName = , *uv2Name = ; uv[0]= uv[1]= uv[2]= uv[3]= MT_Point2(0.0f, 0.0f); uv2[0]= uv2[1]= uv2[2]= uv2[3]= MT_Point2(0.0f, 0.0f); @@ -614,6 +616,8 @@ if (mface-v4) uv[3] = MT_Point2(tface-uv[3]); + + uvName = tfaceName; } else { // nothing at all @@ -639,40 +643,39 @@ isFirstSet = false; else { - MT_Point2 uvSet[4]; for (int lay=0; layMAX_MTFACE; lay++) { MTF_localLayer layer = layers[lay]; if (layer.face == 0) break; - - bool processed = false; if (strcmp(map.uvCoName.ReadPtr(), layer.name)==0) { + MT_Point2 uvSet[4]; + uvSet[0]= MT_Point2(layer.face-uv[0]); uvSet[1]= MT_Point2(layer.face-uv[1]); uvSet[2]= MT_Point2(layer.face-uv[2]); if (mface-v4) uvSet[3]= MT_Point2(layer.face-uv[3]); + else + uvSet[3]= MT_Point2(0.0f, 0.0f); - processed = true; + if (isFirstSet) + { + uv[0] = uvSet[0]; uv[1] = uvSet[1]; + uv[2] = uvSet[2]; uv[3] = uvSet[3]; + isFirstSet = false; + uvName = layer.name; + } + else + { + uv2[0] = uvSet[0]; uv2[1] = uvSet[1]; + uv2[2] = uvSet[2]; uv2[3] = uvSet[3]; + map.mapping |= USECUSTOMUV; + uv2Name = layer.name; + } } - - if (!processed) continue; - - if (isFirstSet) - { - uv[0] = uvSet[0]; uv[1] = uvSet[1]; - uv[2] = uvSet[2]; uv[3] = uvSet[3]; - isFirstSet = false; - } - else - { - uv2[0] = uvSet[0]; uv2[1] = uvSet[1]; - uv2[2] = uvSet[2]; uv2[3] = uvSet[3]; - map.mapping |=
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15264] trunk/blender/source:
Revision: 15264 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15264 Author: blendix Date: 2008-06-18 12:30:14 +0200 (Wed, 18 Jun 2008) Log Message: --- * Fix for a crash in game engine vertex array drawing with texfaces. * For 2D filters, don't require opengl 2.0 but just the extensions, so it works on computers without full 2.0 support too. * In debug mode, don't print memory statistics for preview render. Modified Paths: -- trunk/blender/source/blender/render/intern/source/convertblender.c trunk/blender/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp Modified: trunk/blender/source/blender/render/intern/source/convertblender.c === --- trunk/blender/source/blender/render/intern/source/convertblender.c 2008-06-18 09:52:31 UTC (rev 15263) +++ trunk/blender/source/blender/render/intern/source/convertblender.c 2008-06-18 10:30:14 UTC (rev 15264) @@ -4434,7 +4434,7 @@ LampRen *lar; /* statistics for debugging render memory usage */ - if(G.f G_DEBUG) { + if((G.f G_DEBUG) (G.rendering)) { if((re-r.scemode R_PREVIEWBUTS)==0) { BKE_image_print_memlist(); MEM_printmemlist_stats(); Modified: trunk/blender/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp === --- trunk/blender/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp 2008-06-18 09:52:31 UTC (rev 15263) +++ trunk/blender/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp 2008-06-18 10:30:14 UTC (rev 15264) @@ -54,11 +54,13 @@ RAS_2DFilterManager::RAS_2DFilterManager(): -texturewidth(-1), textureheight(-1), +texname(-1), texturewidth(-1), textureheight(-1), canvaswidth(-1), canvasheight(-1), -numberoffilters(0),texname(-1) +numberoffilters(0) { - isshadersupported = GLEW_VERSION_2_0; + isshadersupported = GLEW_ARB_shader_objects + GLEW_ARB_fragment_shader GLEW_ARB_multitexture; + if(!isshadersupported) { std::coutshaders not supported! std::endl; @@ -81,7 +83,6 @@ unsigned int RAS_2DFilterManager::CreateShaderProgram(char* shadersource) { GLuint program = 0; -#if defined(GL_ARB_shader_objects) defined(WITH_GLEXT) GLuint fShader = glCreateShaderObjectARB(GL_FRAGMENT_SHADER); GLint success; @@ -117,7 +118,7 @@ std::cout 2dFilters - Shader program validation error std::endl; return 0; } -#endif + return program; } @@ -151,7 +152,6 @@ void RAS_2DFilterManager::StartShaderProgram(unsigned int shaderprogram) { -#if defined(GL_ARB_shader_objects) defined(WITH_GLEXT) GLint uniformLoc; glUseProgramObjectARB(shaderprogram); uniformLoc = glGetUniformLocationARB(shaderprogram, bgl_RenderedTexture); @@ -178,14 +178,11 @@ { glUniform1fARB(uniformLoc,textureheight); } -#endif } void RAS_2DFilterManager::EndShaderProgram() { -#if defined(GL_ARB_shader_objects) defined(WITH_GLEXT) glUseProgramObjectARB(0); -#endif } void RAS_2DFilterManager::SetupTexture() @@ -295,7 +292,6 @@ { if(!isshadersupported) return; -#if defined(GL_ARB_shader_objects) defined(WITH_GLEXT) if(pass0 || pass=MAX_RENDER_PASS) return; @@ -336,5 +332,4 @@ m_filters[pass] = CreateShaderProgram(mode); m_enabled[pass] = 1; } -#endif } Modified: trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp === --- trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp 2008-06-18 09:52:31 UTC (rev 15263) +++ trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp 2008-06-18 10:30:14 UTC (rev 15264) @@ -142,6 +142,9 @@ glColor3d(0,0,0); } + EnableTextures(false); + glEnableClientState(GL_TEXTURE_COORD_ARRAY); + // use glDrawElements to draw each vertexarray for (vt=0;vtvertexarrays.size();vt++) { @@ -168,6 +171,8 @@ } + + glDisableClientState(GL_TEXTURE_COORD_ARRAY); } void RAS_VAOpenGLRasterizer::IndexPrimitivesMulti( const vecVertexArray vertexarrays, @@ -281,6 +286,8 @@ break; } } + + glClientActiveTextureARB(GL_TEXTURE0_ARB); } if(GLEW_ARB_vertex_program) { @@ -359,10 +366,14 @@ break; }
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15265] branches/apricot: Apricot Branch: svn merge -r 15249:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/ blender/
Revision: 15265 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15265 Author: blendix Date: 2008-06-18 13:04:30 +0200 (Wed, 18 Jun 2008) Log Message: --- Apricot Branch: svn merge -r 15249:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender/ (game engine shape keys!) Modified Paths: -- branches/apricot/extern/make/msvc_7_0/extern.sln branches/apricot/projectfiles_vc7/blender/blender.vcproj branches/apricot/projectfiles_vc7/gameengine/blenderhook/KX_blenderhook.vcproj branches/apricot/projectfiles_vc7/gameengine/converter/KX_converter.vcproj branches/apricot/projectfiles_vc7/gameengine/gameplayer/common/GP_common.vcproj branches/apricot/projectfiles_vc7/gameengine/gameplayer/ghost/GP_ghost.vcproj branches/apricot/projectfiles_vc7/gameengine/ketsji/KX_ketsji.vcproj branches/apricot/projectfiles_vc7/gameengine/rasterizer/RAS_rasterizer.vcproj branches/apricot/projectfiles_vc7/gameengine/rasterizer/openglrasterizer/RAS_openglrasterizer.vcproj branches/apricot/source/blender/blenkernel/BKE_action.h branches/apricot/source/blender/blenkernel/BKE_key.h branches/apricot/source/blender/blenkernel/intern/action.c branches/apricot/source/blender/blenkernel/intern/key.c branches/apricot/source/blender/blenkernel/intern/sca.c branches/apricot/source/blender/blenloader/intern/readfile.c branches/apricot/source/blender/blenloader/intern/writefile.c branches/apricot/source/blender/makesdna/DNA_actuator_types.h branches/apricot/source/blender/render/intern/source/convertblender.c branches/apricot/source/blender/src/buttons_logic.c branches/apricot/source/blender/src/transform_constraints.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Converter/BL_DeformableGameObject.cpp branches/apricot/source/gameengine/Converter/BL_DeformableGameObject.h branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp branches/apricot/source/gameengine/Converter/BL_MeshDeformer.h branches/apricot/source/gameengine/Converter/BL_SkinDeformer.cpp branches/apricot/source/gameengine/Converter/BL_SkinDeformer.h branches/apricot/source/gameengine/Converter/BL_SkinMeshObject.cpp branches/apricot/source/gameengine/Converter/BL_SkinMeshObject.h branches/apricot/source/gameengine/Converter/KX_ConvertActuators.cpp branches/apricot/source/gameengine/GameLogic/SCA_IObject.h branches/apricot/source/gameengine/Ketsji/KX_GameObject.cpp branches/apricot/source/gameengine/Ketsji/KX_GameObject.h branches/apricot/source/gameengine/Ketsji/KX_RayCast.cpp branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/Rasterizer/RAS_2DFilterManager.cpp branches/apricot/source/gameengine/Rasterizer/RAS_Deformer.h branches/apricot/source/gameengine/Rasterizer/RAS_MeshObject.cpp branches/apricot/source/gameengine/Rasterizer/RAS_MeshObject.h branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp Added Paths: --- branches/apricot/extern/glew/make/ branches/apricot/extern/glew/make/msvc_7_0/ branches/apricot/extern/glew/make/msvc_7_0/glew_vc7.vcproj Removed Paths: - branches/apricot/extern/glew/make/msvc_7_0/ branches/apricot/extern/glew/make/msvc_7_0/glew_vc7.vcproj Copied: branches/apricot/extern/glew/make (from rev 15264, trunk/blender/extern/glew/make) Copied: branches/apricot/extern/glew/make/msvc_7_0 (from rev 15264, trunk/blender/extern/glew/make/msvc_7_0) Deleted: branches/apricot/extern/glew/make/msvc_7_0/glew_vc7.vcproj === --- trunk/blender/extern/glew/make/msvc_7_0/glew_vc7.vcproj 2008-06-18 10:30:14 UTC (rev 15264) +++ branches/apricot/extern/glew/make/msvc_7_0/glew_vc7.vcproj 2008-06-18 11:04:30 UTC (rev 15265) @@ -1,146 +0,0 @@ -?xml version=1.0 encoding=Windows-1252? -VisualStudioProject - ProjectType=Visual C++ - Version=7.10 - Name=glew - ProjectGUID={BAC615B0-F1AF-418B-8D23-A10FD8870D6A} - Keyword=Win32Proj - Platforms - Platform - Name=Win32/ - /Platforms - Configurations - Configuration - Name=Blender Debug|Win32 - OutputDirectory=..\..\..\..\..\build\msvc_7\extern\glew\debug - IntermediateDirectory=..\..\..\..\..\build\msvc_7\extern\glew\debug - ConfigurationType=4 - CharacterSet=2 - Tool - Name=VCCLCompilerTool - Optimization=0 - AdditionalIncludeDirectories=..\..\include -
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15266] branches/apricot/source/gameengine /Converter: Apricot Branch: missed some files in last commit.
Revision: 15266 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15266 Author: blendix Date: 2008-06-18 13:16:40 +0200 (Wed, 18 Jun 2008) Log Message: --- Apricot Branch: missed some files in last commit. Added Paths: --- branches/apricot/source/gameengine/Converter/BL_ShapeActionActuator.cpp branches/apricot/source/gameengine/Converter/BL_ShapeActionActuator.h branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.cpp branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.h Added: branches/apricot/source/gameengine/Converter/BL_ShapeActionActuator.cpp === --- branches/apricot/source/gameengine/Converter/BL_ShapeActionActuator.cpp (rev 0) +++ branches/apricot/source/gameengine/Converter/BL_ShapeActionActuator.cpp 2008-06-18 11:16:40 UTC (rev 15266) @@ -0,0 +1,797 @@ +/** +* $Id: BL_ShapeActionActuator.cpp 15261 2008-06-18 07:03:47Z ben2610 $ +* + * * BEGIN GPL LICENSE BLOCK * + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV. + * All rights reserved. + * + * The Original Code is: all of this file. + * + * Contributor(s): none yet. + * + * * END GPL LICENSE BLOCK * +*/ + +#if defined (__sgi) +#include math.h +#else +#include cmath +#endif + +#include SCA_LogicManager.h +#include BL_ShapeActionActuator.h +#include BL_ActionActuator.h +#include BL_ShapeDeformer.h +#include KX_GameObject.h +#include STR_HashedString.h +#include DNA_action_types.h +#include DNA_nla_types.h +#include DNA_actuator_types.h +#include BKE_action.h +#include DNA_armature_types.h +#include MEM_guardedalloc.h +#include BLI_blenlib.h +#include BLI_arithb.h +#include MT_Matrix4x4.h +#include BKE_utildefines.h + +#ifdef HAVE_CONFIG_H +#include config.h +#endif + +BL_ShapeActionActuator::~BL_ShapeActionActuator() +{ +} + +void BL_ShapeActionActuator::ProcessReplica() +{ + m_localtime=m_startframe; + m_lastUpdate=-1; +} + +void BL_ShapeActionActuator::SetBlendTime (float newtime) +{ + m_blendframe = newtime; +} + +CValue* BL_ShapeActionActuator::GetReplica() +{ + BL_ShapeActionActuator* replica = new BL_ShapeActionActuator(*this);//m_float,GetName()); + replica-ProcessReplica(); + + // this will copy properties and so on... + CValue::AddDataToReplica(replica); + return replica; +} + +bool BL_ShapeActionActuator::ClampLocalTime() +{ + if (m_startframe m_endframe) { + if (m_localtime m_startframe) + { + m_localtime = m_startframe; + return true; + } + else if (m_localtime m_endframe) + { + m_localtime = m_endframe; + return true; + } + } else { + if (m_localtime m_startframe) + { + m_localtime = m_startframe; + return true; + } + else if (m_localtime m_endframe) + { + m_localtime = m_endframe; + return true; + } + } + return false; +} + +void BL_ShapeActionActuator::SetStartTime(float curtime) +{ + float direction = m_startframe m_endframe ? 1.0 : -1.0; + + if (!(m_flag ACT_FLAG_REVERSE)) + m_starttime = curtime - direction*(m_localtime - m_startframe)/KX_KetsjiEngine::GetAnimFrameRate(); + else + m_starttime = curtime - direction*(m_endframe - m_localtime)/KX_KetsjiEngine::GetAnimFrameRate(); +} + +void BL_ShapeActionActuator::SetLocalTime(float curtime) +{ + float delta_time = (curtime - m_starttime)*KX_KetsjiEngine::GetAnimFrameRate(); + + if (m_endframe m_startframe) + delta_time = -delta_time; + + if (!(m_flag ACT_FLAG_REVERSE)) + m_localtime = m_startframe + delta_time; + else + m_localtime = m_endframe - delta_time; +} + +void BL_ShapeActionActuator::BlendShape(Key* key, float srcweight) +{ + vectorfloat::const_iterator
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15294] branches/apricot/source: Apricot Branch: GLSL
Revision: 15294 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15294 Author: blendix Date: 2008-06-21 12:33:12 +0200 (Sat, 21 Jun 2008) Log Message: --- Apricot Branch: GLSL * Added initial support for shadow buffers, works in the 3d view and the game engine, but has known issues still: * Shadow buffers are made again for each 3d viewport unnecessarily. * No filtering. * There was a bug with some shaders going black, but can't reproduce it anymore? * Added support for layer lamps, though they're still always computed in the shader, this needs to be optimized. * Added support for animating lamp position/rotation in the game engine. * Fix issue with lamps giving negative light on the backside. * Fix issue with specular + orthographic camera. * Fix square spotlights. * Potential workaround for a bug in the nvidia drivers with shader linking. Modified Paths: -- branches/apricot/source/blender/blenkernel/intern/object.c branches/apricot/source/blender/blenloader/intern/readfile.c branches/apricot/source/blender/gpu/GPU_extensions.h branches/apricot/source/blender/gpu/GPU_material.h branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_codegen.h branches/apricot/source/blender/gpu/intern/gpu_extensions.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/material_shaders.glsl branches/apricot/source/blender/gpu/intern/material_shaders.glsl.c branches/apricot/source/blender/gpu/intern/material_vertex_shader.glsl branches/apricot/source/blender/gpu/intern/material_vertex_shader.glsl.c branches/apricot/source/blender/include/BDR_drawobject.h branches/apricot/source/blender/include/BSE_drawview.h branches/apricot/source/blender/makesdna/DNA_object_types.h branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_camera.c branches/apricot/source/blender/nodes/intern/SHD_nodes/SHD_geom.c branches/apricot/source/blender/src/buttons_shading.c branches/apricot/source/blender/src/drawobject.c branches/apricot/source/blender/src/drawview.c branches/apricot/source/blender/src/previewrender.c branches/apricot/source/blender/src/renderwin.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.h branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.cpp branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.h branches/apricot/source/gameengine/Ketsji/KX_Light.cpp branches/apricot/source/gameengine/Ketsji/KX_Light.h branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/Ketsji/KX_Scene.h Modified: branches/apricot/source/blender/blenkernel/intern/object.c === --- branches/apricot/source/blender/blenkernel/intern/object.c 2008-06-20 21:36:15 UTC (rev 15293) +++ branches/apricot/source/blender/blenkernel/intern/object.c 2008-06-21 10:33:12 UTC (rev 15294) @@ -112,6 +112,8 @@ #include BPY_extern.h +#include GPU_material.h + #include blendef.h /* Local function protos */ @@ -268,6 +270,7 @@ } if(ob-soft) sbFree(ob-soft); if(ob-fluidsimSettings) fluidsimSettingsFree(ob-fluidsimSettings); + if(ob-gpulamp) GPU_lamp_free(ob-gpulamp); } static void unlink_object__unlinkModifierLinks(void *userData, Object *ob, Object **obpoin) @@ -1215,6 +1218,7 @@ obn-vnode = NULL; #endif + obn-gpulamp = NULL; return obn; } Modified: branches/apricot/source/blender/blenloader/intern/readfile.c === --- branches/apricot/source/blender/blenloader/intern/readfile.c 2008-06-20 21:36:15 UTC (rev 15293) +++ branches/apricot/source/blender/blenloader/intern/readfile.c 2008-06-21 10:33:12 UTC (rev 15294) @@ -3368,6 +3368,7 @@ ob-bb= NULL; ob-derivedDeform= NULL; ob-derivedFinal= NULL; + ob-gpulamp= NULL; } /* READ SCENE * */ Modified: branches/apricot/source/blender/gpu/GPU_extensions.h === --- branches/apricot/source/blender/gpu/GPU_extensions.h2008-06-20 21:36:15 UTC (rev 15293) +++ branches/apricot/source/blender/gpu/GPU_extensions.h2008-06-21 10:33:12 UTC (rev 15294) @@ -72,6 +72,7 @@ GPUTexture *GPU_texture_create_1D(int w, float *pixels, int halffloat); GPUTexture *GPU_texture_create_2D(int w, int h, float *pixels, int halffloat); +GPUTexture *GPU_texture_create_depth(int w, int h);
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15385] trunk/blender/intern:
Revision: 15385 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15385 Author: blendix Date: 2008-06-29 22:53:17 +0200 (Sun, 29 Jun 2008) Log Message: --- Fix for bug #8680: GameLogic.getRandomFloat() returns very small values on 64 bit, instead of range 0..1. Also a warning fix. Modified Paths: -- trunk/blender/intern/iksolver/intern/IK_QTask.h trunk/blender/intern/moto/include/MT_random.h trunk/blender/intern/moto/intern/MT_random.cpp Modified: trunk/blender/intern/iksolver/intern/IK_QTask.h === --- trunk/blender/intern/iksolver/intern/IK_QTask.h 2008-06-29 15:11:35 UTC (rev 15384) +++ trunk/blender/intern/iksolver/intern/IK_QTask.h 2008-06-29 20:53:17 UTC (rev 15385) @@ -74,7 +74,7 @@ virtual bool PositionTask() const { return false; } - virtual void Scale(float scale) {} + virtual void Scale(float) {} protected: int m_id; Modified: trunk/blender/intern/moto/include/MT_random.h === --- trunk/blender/intern/moto/include/MT_random.h 2008-06-29 15:11:35 UTC (rev 15384) +++ trunk/blender/intern/moto/include/MT_random.h 2008-06-29 20:53:17 UTC (rev 15385) @@ -31,10 +31,10 @@ #include limits.h -#define MT_RAND_MAX ULONG_MAX +#define MT_RAND_MAX UINT_MAX -extern void MT_srand(unsigned long); -extern unsigned long MT_rand(); +extern void MT_srand(unsigned int); +extern unsigned int MT_rand(); #endif Modified: trunk/blender/intern/moto/intern/MT_random.cpp === --- trunk/blender/intern/moto/intern/MT_random.cpp 2008-06-29 15:11:35 UTC (rev 15384) +++ trunk/blender/intern/moto/intern/MT_random.cpp 2008-06-29 20:53:17 UTC (rev 15385) @@ -76,11 +76,11 @@ #define TEMPERING_SHIFT_T(y) (y 15) #define TEMPERING_SHIFT_L(y) (y 18) -static unsigned long mt[N]; /* the array for the state vector */ +static unsigned int mt[N]; /* the array for the state vector */ static int mti = N+1; /* mti==N+1 means mt[N] is not initialized */ /* initializing the array with a NONZERO seed */ -void MT_srand(unsigned long seed) +void MT_srand(unsigned int seed) { /* setting initial seeds to mt[N] using */ /* the generator Line 25 of Table 1 in */ @@ -91,12 +91,12 @@ mt[mti] = (69069 * mt[mti-1]) 0x; } -unsigned long MT_rand() +unsigned int MT_rand() { -static unsigned long mag01[2] = { 0x0, MATRIX_A }; +static unsigned int mag01[2] = { 0x0, MATRIX_A }; /* mag01[x] = x * MATRIX_A for x=0,1 */ -unsigned long y; +unsigned int y; if (mti = N) { /* generate N words at one time */ int kk; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15387] trunk/blender/source:
Revision: 15387 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15387 Author: blendix Date: 2008-06-29 23:51:27 +0200 (Sun, 29 Jun 2008) Log Message: --- Fix for bug #7753: after game engine drawing with vertex arrays, nurbs/curves/text dissappears. This also removes the vertex arrays option and enables it always for OpenGL version = 1.1 - there's no need to have an option to make things render faster disabled by default, also it should work stable now. Modified Paths: -- trunk/blender/source/blender/makesdna/DNA_userdef_types.h trunk/blender/source/blender/src/drawview.c trunk/blender/source/blender/src/space.c trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp trunk/blender/source/gameengine/GamePlayer/ghost/GPG_Application.cpp trunk/blender/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp Modified: trunk/blender/source/blender/makesdna/DNA_userdef_types.h === --- trunk/blender/source/blender/makesdna/DNA_userdef_types.h 2008-06-29 21:06:18 UTC (rev 15386) +++ trunk/blender/source/blender/makesdna/DNA_userdef_types.h 2008-06-29 21:51:27 UTC (rev 15387) @@ -310,7 +310,7 @@ #defineUSER_DUP_ACT(1 10) /* gameflags */ -#define USER_VERTEX_ARRAYS 1 +#define USER_DEPRECATED_FLAG 1 #define USER_DISABLE_SOUND 2 #define USER_DISABLE_MIPMAP4 Modified: trunk/blender/source/blender/src/drawview.c === --- trunk/blender/source/blender/src/drawview.c 2008-06-29 21:06:18 UTC (rev 15386) +++ trunk/blender/source/blender/src/drawview.c 2008-06-29 21:51:27 UTC (rev 15387) @@ -246,7 +246,8 @@ glDisable(GL_COLOR_MATERIAL); } -/* also called when render 'ogl' */ +/* also called when render 'ogl' + keep synced with Myinit_gl_stuff in the game engine! */ void init_gl_stuff(void) { float mat_ambient[] = { 0.0, 0.0, 0.0, 0.0 }; Modified: trunk/blender/source/blender/src/space.c === --- trunk/blender/source/blender/src/space.c2008-06-29 21:06:18 UTC (rev 15386) +++ trunk/blender/source/blender/src/space.c2008-06-29 21:51:27 UTC (rev 15387) @@ -378,9 +378,6 @@ if ( (syshandle = SYS_GetSystem()) ) { /* User defined settings */ - a= (U.gameflags USER_VERTEX_ARRAYS); - SYS_WriteCommandLineInt(syshandle, vertexarrays, a); - a= (U.gameflags USER_DISABLE_SOUND); SYS_WriteCommandLineInt(syshandle, noaudio, a); @@ -4255,15 +4252,11 @@ uiDefButS(block, MENU, B_GLRESLIMITCHANGED, GL Texture Clamp Off%x0|%l|GL Texture Clamp 8192%x8192|GL Texture Clamp 4096%x4096|GL Texture Clamp 2048%x2048|GL Texture Clamp 1024%x1024|GL Texture Clamp 512%x512|GL Texture Clamp 256%x256|GL Texture Clamp 128%x128, (xpos+edgsp+(5*mpref)+(5*midsp)),y4,mpref,buth, (U.glreslimit), 0, 0, 0, 0, Limit the texture size to save graphics memory); - uiDefButBitI(block, TOG, USER_VERTEX_ARRAYS, 0, Vertex Arrays, - (xpos+edgsp+(5*mpref)+(5*midsp)),y3,mpref,buth, - (U.gameflags), 0, 0, 0, 0, Toggles between vertex arrays on (less reliable) and off (more reliable)); - uiDefButI(block, NUM, 0, Time Out , - (xpos+edgsp+(5*mpref)+(5*midsp)), y2, mpref, buth, + (xpos+edgsp+(5*mpref)+(5*midsp)), y3, mpref, buth, U.textimeout, 0.0, 3600.0, 30, 2, Time since last access of a GL texture in seconds after which it is freed. (Set to 0 to keep textures allocated)); uiDefButI(block, NUM, 0, Collect Rate , - (xpos+edgsp+(5*mpref)+(5*midsp)), y1, mpref, buth, + (xpos+edgsp+(5*mpref)+(5*midsp)), y2, mpref, buth, U.texcollectrate, 1.0, 3600.0, 30, 2, Number of seconds between each run of the GL texture garbage collector.); /* *** */ Modified: trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp === --- trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp 2008-06-29 21:06:18 UTC (rev 15386) +++ trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp 2008-06-29 21:51:27 UTC (rev 15387) @@ -165,20 +165,14 @@ RAS_IRenderTools* rendertools = new
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15467] branches/apricot/source/blender: Apricot Branch: GLSL
Revision: 15467 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15467 Author: blendix Date: 2008-07-07 12:52:09 +0200 (Mon, 07 Jul 2008) Log Message: --- Apricot Branch: GLSL * Added a separate Layer option for lamp shadows, that only restricts which objects cast shadow, instead of receive light and shadow. * Added exp/log compatibility for GLSL versions 1.10. * Check for depth texture extension before using it. Modified Paths: -- branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_extensions.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/makesdna/DNA_lamp_types.h branches/apricot/source/blender/python/api2_2x/Lamp.c branches/apricot/source/blender/render/intern/include/render_types.h branches/apricot/source/blender/render/intern/source/rayshade.c branches/apricot/source/blender/render/intern/source/shadbuf.c branches/apricot/source/blender/render/intern/source/zbuf.c branches/apricot/source/blender/src/buttons_shading.c branches/apricot/source/blender/src/drawview.c Added Paths: --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_vertex.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_vertex.glsl.c Removed Paths: - branches/apricot/source/blender/gpu/intern/material_shaders.glsl branches/apricot/source/blender/gpu/intern/material_vertex_shader.glsl branches/apricot/source/blender/gpu/intern/material_vertex_shader.glsl.c Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-07 09:23:12 UTC (rev 15466) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-07 10:52:09 UTC (rev 15467) @@ -51,8 +51,6 @@ #include GPU_extensions.h #include gpu_codegen.h -#include material_vertex_shader.glsl.c -#include material_shaders.glsl.c #include string.h #include stdarg.h @@ -66,6 +64,9 @@ #endif #endif +extern char datatoc_gpu_shader_material_glsl[]; +extern char datatoc_gpu_shader_vertex_glsl[]; + /* structs and defines */ typedef enum GPUDataSource { @@ -344,9 +345,9 @@ { if(!FUNCTION_HASH) { FUNCTION_HASH = BLI_ghash_new(BLI_ghashutil_strhash, BLI_ghashutil_strcmp); - gpu_parse_functions_string(FUNCTION_HASH, datatoc_material_shaders_glsl); + gpu_parse_functions_string(FUNCTION_HASH, datatoc_gpu_shader_material_glsl); FUNCTION_PROTOTYPES = gpu_generate_function_prototyps(FUNCTION_HASH); - FUNCTION_LIB = GPU_shader_create_lib(datatoc_material_shaders_glsl); + FUNCTION_LIB = GPU_shader_create_lib(datatoc_gpu_shader_material_glsl); } return (GPUFunction*)BLI_ghash_lookup(FUNCTION_HASH, name); @@ -698,7 +699,7 @@ } BLI_dynstr_append(ds, \n); - BLI_dynstr_append(ds, datatoc_material_vertex_shader_glsl); + BLI_dynstr_append(ds, datatoc_gpu_shader_vertex_glsl); for (node=nodes-first; node; node=node-next) for (input=node-inputs.first; input; input=input-next) Modified: branches/apricot/source/blender/gpu/intern/gpu_extensions.c === --- branches/apricot/source/blender/gpu/intern/gpu_extensions.c 2008-07-07 09:23:12 UTC (rev 15466) +++ branches/apricot/source/blender/gpu/intern/gpu_extensions.c 2008-07-07 10:52:09 UTC (rev 15467) @@ -260,6 +260,9 @@ GLenum type, format; void *pixels = NULL; + if(depth !GLEW_ARB_depth_texture) + return NULL; + tex = MEM_callocN(sizeof(GPUTexture), GPUTexture); tex-w = tex-realw = w; tex-h = tex-realh = h; @@ -285,10 +288,10 @@ tex-number = 0; glBindTexture(tex-target, tex-bindcode); - if(depth) { /* TODO extensions */ + if(depth) { type = GL_UNSIGNED_BYTE; format = GL_DEPTH_COMPONENT; - tex-internalformat = GL_DEPTH_COMPONENT16; + tex-internalformat = GL_DEPTH_COMPONENT; } else if (halffloat (GLEW_ARB_texture_float || GLEW_ATI_texture_float)) { type = GL_FLOAT; Modified: branches/apricot/source/blender/gpu/intern/gpu_material.c === --- branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-07-07 09:23:12 UTC (rev 15466) +++ branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-07-07 10:52:09 UTC (rev 15467) @@ -1184,9 +1184,9 @@ int GPU_lamp_shadow_layer(GPULamp *lamp) { - if(lamp-fb lamp-tex (lamp-mode LA_LAYER)) +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15468] branches/apricot/source: Apricot Branch: GLSL
Revision: 15468 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15468 Author: blendix Date: 2008-07-07 13:58:09 +0200 (Mon, 07 Jul 2008) Log Message: --- Apricot Branch: GLSL * Forgot to add/remove file in list commit. * Game engine shadow optimization, don't use shaders for drawing into shadow buffer. Modified Paths: -- branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.cpp branches/apricot/source/gameengine/Rasterizer/RAS_IRasterizer.h branches/apricot/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp Added Paths: --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c Removed Paths: - branches/apricot/source/blender/gpu/intern/material_shaders.glsl.c Added: branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c === --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c (rev 0) +++ branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c 2008-07-07 11:58:09 UTC (rev 15468) @@ -0,0 +1,1055 @@ +/* DataToC output of file gpu_shader_material_glsl */ + +int datatoc_gpu_shader_material_glsl_size= 33564; +char datatoc_gpu_shader_material_glsl[]= { + 10, 35,105,102, 32, 95, 95, 86, 69, 82, 83, 73, 79, 78, 95, 95, 32, 60, 32, 49, 49, 48, 10, 10,102,108,111, 97, +116, 32,101,120,112, 40,102,108,111, 97,116, 32,102, 41, 10,123, 10, 9,114,101,116,117,114,110, 32,112,111,119, 40, 50, 46, 55, + 49, 56, 50, 56, 49, 56, 50, 56, 52, 54, 44, 32,102, 41, 59, 10,125, 10, 10,102,108,111, 97,116, 32,108,111,103, 40,102,108,111, + 97,116, 32,102, 41, 10,123, 10, 9,114,101,116,117,114,110, 32,108,111,103, 50, 40,102, 41, 47,108,111,103, 50, 40, 50, 46, 55, + 49, 56, 50, 56, 49, 56, 50, 56, 52, 54, 41, 59, 10,125, 10, 10, 35,101,110,100,105,102, 10, 10,118,111,105,100, 32,114,103, 98, + 95,116,111, 95,104,115,118, 40,118,101, 99, 52, 32,114,103, 98, 44, 32,111,117,116, 32,118,101, 99, 52, 32,111,117,116, 99,111, +108, 41, 10,123, 10, 9,102,108,111, 97,116, 32, 99,109, 97,120, 44, 32, 99,109,105,110, 44, 32,104, 44, 32,115, 44, 32,118, 44, + 32, 99,100,101,108,116, 97, 59, 10, 9,118,101, 99, 51, 32, 99, 59, 10, 10, 9, 99,109, 97,120, 32, 61, 32,109, 97,120, 40,114, +103, 98, 91, 48, 93, 44, 32,109, 97,120, 40,114,103, 98, 91, 49, 93, 44, 32,114,103, 98, 91, 50, 93, 41, 41, 59, 10, 9, 99,109, +105,110, 32, 61, 32,109,105,110, 40,114,103, 98, 91, 48, 93, 44, 32,109,105,110, 40,114,103, 98, 91, 49, 93, 44, 32,114,103, 98, + 91, 50, 93, 41, 41, 59, 10, 9, 99,100,101,108,116, 97, 32, 61, 32, 99,109, 97,120, 45, 99,109,105,110, 59, 10, 10, 9,118, 32, + 61, 32, 99,109, 97,120, 59, 10, 9,105,102, 32, 40, 99,109, 97,120, 33, 61, 48, 46, 48, 41, 10, 9, 9,115, 32, 61, 32, 99,100, +101,108,116, 97, 47, 99,109, 97,120, 59, 10, 9,101,108,115,101, 32,123, 10, 9, 9,115, 32, 61, 32, 48, 46, 48, 59, 10, 9, 9, +104, 32, 61, 32, 48, 46, 48, 59, 10, 9,125, 10, 10, 9,105,102, 32, 40,115, 32, 61, 61, 32, 48, 46, 48, 41, 32,123, 10, 9, 9, +104, 32, 61, 32, 48, 46, 48, 59, 10, 9,125, 10, 9,101,108,115,101, 32,123, 10, 9, 9, 99, 32, 61, 32, 40,118,101, 99, 51, 40, + 99,109, 97,120, 44, 32, 99,109, 97,120, 44, 32, 99,109, 97,120, 41, 32, 45, 32,114,103, 98, 46,120,121,122, 41, 47, 99,100,101, +108,116, 97, 59, 10, 10, 9, 9,105,102, 32, 40,114,103, 98, 46,120, 61, 61, 99,109, 97,120, 41, 32,104, 32, 61, 32, 99, 91, 50, + 93, 32, 45, 32, 99, 91, 49, 93, 59, 10, 9, 9,101,108,115,101, 32,105,102, 32, 40,114,103, 98, 46,121, 61, 61, 99,109, 97,120, + 41, 32,104, 32, 61, 32, 50, 46, 48, 32, 43, 32, 99, 91, 48, 93, 32, 45, 32, 32, 99, 91, 50, 93, 59, 10, 9, 9,101,108,115,101, + 32,104, 32, 61, 32, 52, 46, 48, 32, 43, 32, 99, 91, 49, 93, 32, 45, 32, 99, 91, 48, 93, 59, 10, 10, 9, 9,104, 32, 47, 61, 32, + 54, 46, 48, 59, 10, 10, 9, 9,105,102, 32, 40,104, 60, 48, 46, 48, 41, 10, 9, 9, 9,104, 32, 43, 61, 32, 49, 46, 48, 59, 10, + 9,125, 10, 10, 9,111,117,116, 99,111,108, 32, 61, 32,118,101, 99, 52, 40,104, 44, 32,115, 44, 32,118, 44, 32,114,103, 98, 46, +119, 41, 59, 10,125, 10, 10,118,111,105,100, 32,104,115,118, 95,116,111, 95,114,103, 98, 40,118,101, 99, 52, 32,104,115,118, 44, + 32,111,117,116, 32,118,101, 99, 52, 32,111,117,116, 99,111,108, 41, 10,123, 10, 9,102,108,111, 97,116, 32,105, 44, 32,102, 44, + 32,112, 44, 32,113, 44, 32,116, 44, 32,104, 44, 32,115, 44, 32,118, 59, 10, 9,118,101, 99, 51, 32,114,103, 98, 59, 10, 10, 9, +104, 32, 61, 32,104,115,118, 91, 48, 93, 59, 10, 9,115, 32, 61, 32,104,115,118, 91, 49, 93, 59, 10, 9,118, 32, 61, 32,104,115, +118, 91, 50, 93, 59, 10, 10,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15469] branches/apricot/source: Apricot Branch
Revision: 15469 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15469 Author: blendix Date: 2008-07-07 15:57:29 +0200 (Mon, 07 Jul 2008) Log Message: --- Apricot Branch == Some optimizations: * Only Apply mesh deformer if the mesh is actually modified, once per frame, this was done too often before. * GLSL shader binding is now faster, only goes over dynamics inputs instead of all of them, and frees more memory after compiling too. Modified Paths: -- branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp branches/apricot/source/gameengine/Converter/BL_MeshDeformer.h branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.h branches/apricot/source/gameengine/Converter/BL_SkinDeformer.cpp branches/apricot/source/gameengine/Converter/BL_SkinDeformer.h branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-07 11:58:09 UTC (rev 15468) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-07 13:57:29 UTC (rev 15469) @@ -152,13 +152,14 @@ char attribname[32];/* attribute name */ int attribfirst;/* this is the first one that is bound */ GPUBuiltin builtin; /* builtin uniform */ + + char shadername[32];/* name in shader */ } GPUInput; struct GPUPass { struct GPUPass *next, *prev; - ListBase nodes; - int firstbind; + ListBase inputs; struct GPUOutput *output; struct GPUShader *shader; }; @@ -730,92 +731,121 @@ return pass-shader; } -void GPU_pass_bind(GPUPass *pass) +void GPU_nodes_extract_dynamic_inputs(GPUPass *pass, ListBase *nodes) { + GPUShader *shader = pass-shader; GPUNode *node; - GPUInput *input; - GPUShader *shader = pass-shader; - ListBase *nodes = pass-nodes; - DynStr *ds; - char *name; + GPUInput *next, *input; + ListBase *inputs = pass-inputs; + int extract; - if (!shader) + memset(inputs, 0, sizeof(*inputs)); + + if(!shader) return; - /* create textures first, otherwise messes up multitexture state for -* following textures*/ - for (node=nodes-first; node; node=node-next) - for (input=node-inputs.first; input; input=input-next) - if (input-ima) - input-tex = GPU_texture_from_blender(input-ima, input-iuser); - GPU_shader_bind(shader); for (node=nodes-first; node; node=node-next) { - for (input=node-inputs.first; input; input=input-next) { + for (input=node-inputs.first; input; input=next) { + next = input-next; + /* attributes don't need to be bound, they already have * an id that the drawing functions will use */ if(input-source == GPU_SOURCE_ATTRIB || input-source == GPU_SOURCE_BUILTIN) continue; - /* pass samplers and uniforms to opengl */ - if (input-link) - input-tex = NULL; /* input-link-tex; */ - - ds = BLI_dynstr_new(); - if (input-tex) - BLI_dynstr_printf(ds, samp%d, input-texid); + if (input-ima || input-tex) + snprintf(input-shadername, sizeof(input-shadername), samp%d, input-texid); else - BLI_dynstr_printf(ds, unf%d, input-id); - name = BLI_dynstr_get_cstring(ds); - BLI_dynstr_free(ds); + snprintf(input-shadername, sizeof(input-shadername), unf%d, input-id); - if (input-tex) { - if (input-bindtex) { - if(pass-firstbind); - GPU_texture_bind(input-tex, input-texid); - GPU_shader_uniform_texture(shader, name, input-tex); - } + /* pass non-dynamic uniforms to opengl */ + extract = 0; + + if(input-ima || input-tex) { + if (input-bindtex) + extract = 1; } else if (input-arraysize) { -
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15499] trunk/blender/source/blender/nodes /intern/CMP_nodes/CMP_gamma.c:
Revision: 15499 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15499 Author: blendix Date: 2008-07-09 12:13:09 +0200 (Wed, 09 Jul 2008) Log Message: --- Fix for bugfix #12075: gamma node check for nan was always checking red channel. Modified Paths: -- trunk/blender/source/blender/nodes/intern/CMP_nodes/CMP_gamma.c Modified: trunk/blender/source/blender/nodes/intern/CMP_nodes/CMP_gamma.c === --- trunk/blender/source/blender/nodes/intern/CMP_nodes/CMP_gamma.c 2008-07-09 09:21:52 UTC (rev 15498) +++ trunk/blender/source/blender/nodes/intern/CMP_nodes/CMP_gamma.c 2008-07-09 10:13:09 UTC (rev 15499) @@ -47,7 +47,7 @@ int i=0; for(i=0; i3; i++) { /* check for negative to avoid nan's */ - out[i] = (in[0] 0.0f)? pow(in[i],fac[0]): in[0]; + out[i] = (in[i] 0.0f)? pow(in[i],fac[0]): in[i]; } out[3] = in[3]; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15517] trunk/blender: Sync with Apricot Game Engine
Revision: 15517 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15517 Author: blendix Date: 2008-07-10 14:47:20 +0200 (Thu, 10 Jul 2008) Log Message: --- Sync with Apricot Game Engine = * Clean up and optimizations in skinned/deformed mesh code. * Compatibility fixes and clean up in the rasterizer. * Changes related to GLSL shadow buffers which should have no effect, to keep the code in sync with apricot. Modified Paths: -- trunk/blender/intern/moto/include/GEN_Map.h trunk/blender/source/blender/src/usiblender.c trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp trunk/blender/source/gameengine/Converter/BL_BlenderDataConversion.cpp trunk/blender/source/gameengine/Converter/BL_MeshDeformer.cpp trunk/blender/source/gameengine/Converter/BL_MeshDeformer.h trunk/blender/source/gameengine/Converter/BL_ShapeDeformer.h trunk/blender/source/gameengine/Converter/BL_SkinDeformer.cpp trunk/blender/source/gameengine/Converter/BL_SkinDeformer.h trunk/blender/source/gameengine/Converter/BL_SkinMeshObject.cpp trunk/blender/source/gameengine/Converter/BL_SkinMeshObject.h trunk/blender/source/gameengine/Ketsji/BL_BlenderShader.cpp trunk/blender/source/gameengine/Ketsji/BL_BlenderShader.h trunk/blender/source/gameengine/Ketsji/BL_Material.cpp trunk/blender/source/gameengine/Ketsji/BL_Material.h trunk/blender/source/gameengine/Ketsji/KX_BlenderMaterial.cpp trunk/blender/source/gameengine/Ketsji/KX_BlenderMaterial.h trunk/blender/source/gameengine/Ketsji/KX_GameObject.cpp trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.cpp trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.h trunk/blender/source/gameengine/Ketsji/KX_Light.cpp trunk/blender/source/gameengine/Ketsji/KX_Light.h trunk/blender/source/gameengine/Ketsji/KX_Scene.cpp trunk/blender/source/gameengine/Ketsji/KX_Scene.h trunk/blender/source/gameengine/Rasterizer/RAS_BucketManager.cpp trunk/blender/source/gameengine/Rasterizer/RAS_IPolygonMaterial.cpp trunk/blender/source/gameengine/Rasterizer/RAS_IPolygonMaterial.h trunk/blender/source/gameengine/Rasterizer/RAS_IRasterizer.h trunk/blender/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp trunk/blender/source/gameengine/Rasterizer/RAS_MaterialBucket.h trunk/blender/source/gameengine/Rasterizer/RAS_MeshObject.cpp trunk/blender/source/gameengine/Rasterizer/RAS_MeshObject.h trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_ListRasterizer.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_ListRasterizer.h trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.h trunk/blender/source/gameengine/Rasterizer/RAS_TexVert.cpp trunk/blender/source/gameengine/Rasterizer/RAS_TexVert.h trunk/blender/source/kernel/gen_system/GEN_HashedPtr.h trunk/blender/source/kernel/gen_system/GEN_Map.h Modified: trunk/blender/intern/moto/include/GEN_Map.h === --- trunk/blender/intern/moto/include/GEN_Map.h 2008-07-10 01:47:51 UTC (rev 15516) +++ trunk/blender/intern/moto/include/GEN_Map.h 2008-07-10 12:47:20 UTC (rev 15517) @@ -82,6 +82,24 @@ } return 0; } + +Key* getKey(int index) { +int count=0; +for (int i=0;im_num_buckets;i++) +{ +Entry* bucket = m_buckets[i]; +while(bucket) +{ +if (count==index) +{ +return bucket-m_key; +} +bucket = bucket-m_next; +count++; +} +} +return 0; +} void clear() { for (int i = 0; i m_num_buckets; ++i) { Modified: trunk/blender/source/blender/src/usiblender.c === --- trunk/blender/source/blender/src/usiblender.c 2008-07-10 01:47:51 UTC (rev 15516) +++ trunk/blender/source/blender/src/usiblender.c 2008-07-10 12:47:20 UTC (rev 15517) @@ -34,6 +34,8 @@ #include stdio.h #include string.h +#include GL/glew.h + #ifdef WIN32 #include windows.h /* need to include windows.h so _WIN32_IE is defined */ #ifndef _WIN32_IE Modified: trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp === --- trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp 2008-07-10 01:47:51 UTC (rev 15516) +++
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15521] trunk/blender/source/blender/src/ vpaint.c:
Revision: 15521 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15521 Author: blendix Date: 2008-07-10 17:30:35 +0200 (Thu, 10 Jul 2008) Log Message: --- Fix for bug #17292: vertex paint blur darkens the colors as you paint, due to old optimization to use 8, but this is equivalent to /256, and it should be /255. Modified Paths: -- trunk/blender/source/blender/src/vpaint.c Modified: trunk/blender/source/blender/src/vpaint.c === --- trunk/blender/source/blender/src/vpaint.c 2008-07-10 15:15:47 UTC (rev 15520) +++ trunk/blender/source/blender/src/vpaint.c 2008-07-10 15:30:35 UTC (rev 15521) @@ -566,9 +566,9 @@ cp= (char *)col; cp[0]= 255; - cp[1]= (mfac*cp1[1]+fac*cp2[1])8; - cp[2]= (mfac*cp1[2]+fac*cp2[2])8; - cp[3]= (mfac*cp1[3]+fac*cp2[3])8; + cp[1]= (mfac*cp1[1]+fac*cp2[1])/255; + cp[2]= (mfac*cp1[2]+fac*cp2[2])/255; + cp[3]= (mfac*cp1[3]+fac*cp2[3])/255; return col; } @@ -586,11 +586,11 @@ cp= (char *)col; cp[0]= 255; - temp= cp1[1] + ((fac*cp2[1])8); + temp= cp1[1] + ((fac*cp2[1])/255); if(temp254) cp[1]= 255; else cp[1]= temp; - temp= cp1[2] + ((fac*cp2[2])8); + temp= cp1[2] + ((fac*cp2[2])/255); if(temp254) cp[2]= 255; else cp[2]= temp; - temp= cp1[3] + ((fac*cp2[3])8); + temp= cp1[3] + ((fac*cp2[3])/255); if(temp254) cp[3]= 255; else cp[3]= temp; return col; @@ -609,11 +609,11 @@ cp= (char *)col; cp[0]= 255; - temp= cp1[1] - ((fac*cp2[1])8); + temp= cp1[1] - ((fac*cp2[1])/255); if(temp0) cp[1]= 0; else cp[1]= temp; - temp= cp1[2] - ((fac*cp2[2])8); + temp= cp1[2] - ((fac*cp2[2])/255); if(temp0) cp[2]= 0; else cp[2]= temp; - temp= cp1[3] - ((fac*cp2[3])8); + temp= cp1[3] - ((fac*cp2[3])/255); if(temp0) cp[3]= 0; else cp[3]= temp; return col; @@ -635,9 +635,9 @@ /* first mul, then blend the fac */ cp[0]= 255; - cp[1]= (mfac*cp1[1] + fac*((cp2[1]*cp1[1])8) )8; - cp[2]= (mfac*cp1[2] + fac*((cp2[2]*cp1[2])8) )8; - cp[3]= (mfac*cp1[3] + fac*((cp2[3]*cp1[3])8) )8; + cp[1]= (mfac*cp1[1] + fac*((cp2[1]*cp1[1])/255) )/255; + cp[2]= (mfac*cp1[2] + fac*((cp2[2]*cp1[2])/255) )/255; + cp[3]= (mfac*cp1[3] + fac*((cp2[3]*cp1[3])/255) )/255; return col; @@ -664,9 +664,9 @@ return col1; cp[0]= 255; - cp[1]= (mfac*cp1[1]+fac*cp2[1])8; - cp[2]= (mfac*cp1[2]+fac*cp2[2])8; - cp[3]= (mfac*cp1[3]+fac*cp2[3])8; + cp[1]= (mfac*cp1[1]+fac*cp2[1])/255; + cp[2]= (mfac*cp1[2]+fac*cp2[2])/255; + cp[3]= (mfac*cp1[3]+fac*cp2[3])/255; return col; } @@ -692,9 +692,9 @@ return col1; cp[0]= 255; - cp[1]= (mfac*cp1[1]+fac*cp2[1])8; - cp[2]= (mfac*cp1[2]+fac*cp2[2])8; - cp[3]= (mfac*cp1[3]+fac*cp2[3])8; + cp[1]= (mfac*cp1[1]+fac*cp2[1])/255; + cp[2]= (mfac*cp1[2]+fac*cp2[2])/255; + cp[3]= (mfac*cp1[3]+fac*cp2[3])/255; return col; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15576] branches/apricot/source: Apricot: GLSL
Revision: 15576 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15576 Author: blendix Date: 2008-07-15 01:26:38 +0200 (Tue, 15 Jul 2008) Log Message: --- Apricot: GLSL = * Added options to disable lights, shaders, shadows, ramps, nodes and textures other than col/alpha for GLSL, in the Game menu. * These have python access too to switch them in game, but it doesn't work correct yet with display lists enabled. * Fix issue with light lagging behind, debug stats drawing in wrong color, and a number of other small fixes. Modified Paths: -- branches/apricot/source/blender/blenkernel/BKE_global.h branches/apricot/source/blender/gpu/GPU_material.h branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_codegen.h branches/apricot/source/blender/gpu/intern/gpu_extensions.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c branches/apricot/source/blender/python/SConscript branches/apricot/source/blender/python/api2_2x/Blender.c branches/apricot/source/blender/src/drawobject.c branches/apricot/source/blender/src/header_info.c branches/apricot/source/blender/src/space.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/GamePlayer/ghost/GPG_Application.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.h branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.h branches/apricot/source/gameengine/Ketsji/KX_Light.cpp branches/apricot/source/gameengine/Ketsji/KX_Light.h branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_ListRasterizer.cpp Modified: branches/apricot/source/blender/blenkernel/BKE_global.h === --- branches/apricot/source/blender/blenkernel/BKE_global.h 2008-07-14 22:23:39 UTC (rev 15575) +++ branches/apricot/source/blender/blenkernel/BKE_global.h 2008-07-14 23:26:38 UTC (rev 15576) @@ -218,9 +218,15 @@ #define G_FILE_NO_UI(1 10) #define G_FILE_GAME_TO_IPO (1 11) #define G_FILE_GAME_MAT (1 12) -#define G_FILE_DIAPLAY_LISTS(1 13) +#define G_FILE_DISPLAY_LISTS(1 13) #define G_FILE_SHOW_PHYSICS (1 14) #define G_FILE_GAME_MAT_GLSL(1 15) +#define G_FILE_GLSL_NO_LIGHTS (1 16) +#define G_FILE_GLSL_NO_SHADERS (1 17) +#define G_FILE_GLSL_NO_SHADOWS (1 18) +#define G_FILE_GLSL_NO_RAMPS(1 19) +#define G_FILE_GLSL_NO_NODES(1 20) +#define G_FILE_GLSL_NO_EXTRA_TEX (1 21) /* G.windowstate */ #define G_WINDOWSTATE_USERDEF 0 Modified: branches/apricot/source/blender/gpu/GPU_material.h === --- branches/apricot/source/blender/gpu/GPU_material.h 2008-07-14 22:23:39 UTC (rev 15575) +++ branches/apricot/source/blender/gpu/GPU_material.h 2008-07-14 23:26:38 UTC (rev 15576) @@ -44,6 +44,7 @@ struct Lamp; struct bNode; struct LinkNode; +struct Scene; struct GPUVertexAttribs; struct GPUNode; struct GPUNodeLink; @@ -108,9 +109,11 @@ /* High level functions to create and use GPU materials */ -int GPU_material_from_blender(struct Material *ma); +int GPU_material_from_blender(struct Scene *scene, struct Material *ma); void GPU_material_free(GPUMaterial *material); +void GPU_materials_free(); + void GPU_material_bind(GPUMaterial *material, int lay); void GPU_material_bind_uniforms(GPUMaterial *material, float obmat[][4], float viewmat[][4], float viewinv[][4]); void GPU_material_unbind(GPUMaterial *material); Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-14 22:23:39 UTC (rev 15575) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-14 23:26:38 UTC (rev 15576) @@ -803,22 +803,34 @@ if (!shader) return; - /* create textures first, otherwise messes up multitexture state for -* following textures*/ - for (input=inputs-first; input; input=input-next) + GPU_shader_bind(shader); + + /* now bind the textures */ + for (input=inputs-first; input; input=input-next) { if (input-ima) input-tex = GPU_texture_from_blender(input-ima, input-iuser); - GPU_shader_bind(shader); - - /* pass dynamic inputs to opengl, others were
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15595] branches/apricot: Apricot Branch
Revision: 15595 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15595 Author: blendix Date: 2008-07-15 23:59:46 +0200 (Tue, 15 Jul 2008) Log Message: --- Apricot Branch == * Made in game switching of GLSL options work. There is still a one frame flicker that needs to be fixed. * Added access to the estimated average framerate in the game engine: GameLogic.getAverageFrameRate(). * Added acces to the blender build info from python: Blender.Get(buildinfo) * Various GLSL optimizations to allow more constant folding in the glsl compiler, use glsl shadow functions to do shadow, instead of own code, and fix an issue with opengl texture color range. Modified Paths: -- branches/apricot/release/scripts/sysinfo.py branches/apricot/source/blender/gpu/GPU_material.h branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_extensions.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c branches/apricot/source/blender/python/CMakeLists.txt branches/apricot/source/blender/python/SConscript branches/apricot/source/blender/python/api2_2x/Blender.c branches/apricot/source/blender/python/api2_2x/Makefile branches/apricot/source/blender/src/drawobject.c branches/apricot/source/blender/src/drawview.c branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.h branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.cpp branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.h branches/apricot/source/gameengine/Ketsji/KX_PythonInit.cpp branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/PyDoc/GameLogic.py branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.h Modified: branches/apricot/release/scripts/sysinfo.py === --- branches/apricot/release/scripts/sysinfo.py 2008-07-15 21:08:39 UTC (rev 15594) +++ branches/apricot/release/scripts/sysinfo.py 2008-07-15 21:59:46 UTC (rev 15595) @@ -94,6 +94,8 @@ output.write(header + \n\n) +output.write(%s\n\n % Blender.Get('buildinfo')) + output.write(Platform: %s\n\n\n % sys.platform) output.write(Python:\n==\n\n) Modified: branches/apricot/source/blender/gpu/GPU_material.h === --- branches/apricot/source/blender/gpu/GPU_material.h 2008-07-15 21:08:39 UTC (rev 15594) +++ branches/apricot/source/blender/gpu/GPU_material.h 2008-07-15 21:59:46 UTC (rev 15595) @@ -70,6 +70,7 @@ GPU_MAT4 = 16, GPU_TEX1D = 1001, GPU_TEX2D = 1002, + GPU_SHADOW2D = 1003, GPU_ATTRIB = 3001 } GPUType; Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-15 21:08:39 UTC (rev 15594) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-15 21:59:46 UTC (rev 15595) @@ -71,7 +71,6 @@ typedef enum GPUDataSource { GPU_SOURCE_VEC_UNIFORM, - GPU_SOURCE_ARRAY_UNIFORM, GPU_SOURCE_BUILTIN, GPU_SOURCE_TEX_PIXEL, GPU_SOURCE_TEX, @@ -131,7 +130,6 @@ GPUNode *node; int type; /* datatype */ - int arraysize; /* number of elements in an array */ int source; /* data source */ int id; /* unique id as created by code generator */ @@ -140,6 +138,7 @@ int bindtex;/* input is responsible for binding the texture? */ int definetex; /* input is responsible for defining the pixel? */ int textarget; /* GL_TEXTURE_* */ + int textype;/* datatype */ struct Image *ima; /* image */ struct ImageUser *iuser;/* image user */ @@ -267,6 +266,8 @@ } } + if(!type gpu_str_prefix(code, sampler2DShadow)) + type= GPU_SHADOW2D; if(!type gpu_str_prefix(code, sampler1D)) type= GPU_TEX1D; if(!type gpu_str_prefix(code, sampler2D)) @@ -323,6 +324,8 @@ BLI_dynstr_append(ds, sampler1D); else if(function-paramtype[a] == GPU_TEX2D)
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15602] trunk/blender/source/blender/ blenlib/intern/arithb.c:
Revision: 15602 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15602 Author: blendix Date: 2008-07-16 15:47:03 +0200 (Wed, 16 Jul 2008) Log Message: --- Bugfix: particles with deflection based on size could pass through objects due to a broken SweepingSphereIntersectsTriangleUV. This merges the code from the shrinkwrap branch by Andr?\195?\169 Pinto, thanks! Modified Paths: -- trunk/blender/source/blender/blenlib/intern/arithb.c Modified: trunk/blender/source/blender/blenlib/intern/arithb.c === --- trunk/blender/source/blender/blenlib/intern/arithb.c2008-07-16 12:56:23 UTC (rev 15601) +++ trunk/blender/source/blender/blenlib/intern/arithb.c2008-07-16 13:47:03 UTC (rev 15602) @@ -60,6 +60,7 @@ #define SMALL_NUMBER 1.e-8 #define ABS(x) ((x) 0 ? -(x) : (x)) #define SWAP(type, a, b) { type sw_ap; sw_ap=(a); (a)=(b); (b)=sw_ap; } +#define CLAMP(a, b, c) if((a)(b)) (a)=(b); else if((a)(c)) (a)=(c) #if defined(WIN32) || defined(__APPLE__) @@ -3800,12 +3801,50 @@ /* Adapted from the paper by Kasper Fauerby */ /* Improved Collision detection and Response */ +static int getLowestRoot(float a, float b, float c, float maxR, float* root) +{ + // Check if a solution exists + float determinant = b*b - 4.0f*a*c; + + // If determinant is negative it means no solutions. + if (determinant = 0.0f) + { + // calculate the two roots: (if determinant == 0 then + // x1==x2 but let’s disregard that slight optimization) + float sqrtD = sqrt(determinant); + float r1 = (-b - sqrtD) / (2.0f*a); + float r2 = (-b + sqrtD) / (2.0f*a); + + // Sort so x1 = x2 + if (r1 r2) + SWAP( float, r1, r2); + + // Get lowest root: + if (r1 0.0f r1 maxR) + { + *root = r1; + return 1; + } + + // It is possible that we want x2 - this can happen + // if x1 0 + if (r2 0.0f r2 maxR) + { + *root = r2; + return 1; + } + } + // No (valid) solutions + return 0; +} + int SweepingSphereIntersectsTriangleUV(float p1[3], float p2[3], float radius, float v0[3], float v1[3], float v2[3], float *lambda, float *ipoint) { float e1[3], e2[3], e3[3], point[3], vel[3], /*dist[3],*/ nor[3], temp[3], bv[3]; - float a, b, c, d, e, x, y, z, t, t0, t1, radius2=radius*radius; + float a, b, c, d, e, x, y, z, radius2=radius*radius; float elen2,edotv,edotbv,nordotv,vel2; - int embedded_in_plane=0, found_by_sweep=0; + float newLambda; + int found_by_sweep=0; VecSubf(e1,v1,v0); VecSubf(e2,v2,v0); @@ -3814,45 +3853,42 @@ /*---test plane of tri---*/ Crossf(nor,e1,e2); Normalize(nor); + /* flip normal */ if(Inpf(nor,vel)0.0f) VecMulf(nor,-1.0f); a=Inpf(p1,nor)-Inpf(v0,nor); - nordotv=Inpf(nor,vel); - if ((nordotv -0.01) (nordotv 0.01)) { - if(fabs(a)=1.0f) + if (fabs(nordotv) 0.01) + { + if(fabs(a)=radius) + { return 0; - else{ - embedded_in_plane=1; - t0=0.0f; - t1=1.0f; } } - else{ - t0=(radius-a)/nordotv; - t1=(-radius-a)/nordotv; - /* make t0t1 */ - if(t0t1){b=t1; t1=t0; t0=b;} + else + { + float t0=(-a+radius)/nordotv; + float t1=(-a-radius)/nordotv; + if(t0t1) + SWAP(float, t0, t1); + if(t01.0f || t10.0f) return 0; /* clamp to [0,1] */ - t0=(t00.0f)?0.0f:((t01.0f)?1.0:t0); - t1=(t10.0f)?0.0f:((t11.0f)?1.0:t1); - } + CLAMP(t0, 0.0f, 1.0f); + CLAMP(t1, 0.0f, 1.0f); -/*---test inside of tri---*/ - if(embedded_in_plane==0){ + /*---test inside of tri---*/ /* plane intersection point */ - VecCopyf(point,vel); - VecMulf(point,t0); - VecAddf(point,point,p1); - VecCopyf(temp,nor); - VecMulf(temp,radius); - VecSubf(point,point,temp); + point[0] = p1[0] + vel[0]*t0 - nor[0]*radius; + point[1] = p1[1] + vel[1]*t0 - nor[1]*radius; + point[2] = p1[2] + vel[2]*t0 - nor[2]*radius; + + /* is the point in the tri? */ a=Inpf(e1,e1);
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15603] branches/apricot/source: Apricot Branch
Revision: 15603 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15603 Author: blendix Date: 2008-07-16 15:53:39 +0200 (Wed, 16 Jul 2008) Log Message: --- Apricot Branch == Fix for bug #17326: normal and tangents in the game engine were computed different than other parts of Blender, this makes the game engine use the same code as Blender. Fix for part of bug #17307: normal maps not working correct in editmode in some cases. Fix for bug #17339: a crash on ATI cards in glTexSubImage1D due to a mistake in the code. A patch to fix this was provided by Yong Ch, thanks! Modified Paths: -- branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_extensions.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp Modified: branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h === --- branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h 2008-07-16 13:47:03 UTC (rev 15602) +++ branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h 2008-07-16 13:53:39 UTC (rev 15603) @@ -483,5 +483,7 @@ void DM_vertex_attributes_from_gpu(DerivedMesh *dm, struct GPUVertexAttribs *gattribs, DMVertexAttribs *attribs); +void DM_add_tangent_layer(DerivedMesh *dm); + #endif Modified: branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c === --- branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c 2008-07-16 13:47:03 UTC (rev 15602) +++ branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c 2008-07-16 13:53:39 UTC (rev 15603) @@ -1252,6 +1252,43 @@ } } +static void *emDM_getFaceDataArray(DerivedMesh *dm, int type) +{ + EditMeshDerivedMesh *emdm= (EditMeshDerivedMesh*) dm; + EditMesh *em= emdm-em; + EditFace *efa; + char *data, *emdata; + void *datalayer; + int index, offset, size; + + datalayer = DM_get_face_data_layer(dm, type); + if(datalayer) + return datalayer; + + /* layers are store per face for editmesh, we convert to a temporary +* data layer array in the derivedmesh when these are requested */ + if(type == CD_MTFACE || type == CD_MCOL) { + index = CustomData_get_layer_index(em-fdata, type); + + if(index != -1) { + offset = em-fdata.layers[index].offset; + size = CustomData_sizeof(type); + + DM_add_face_layer(dm, type, CD_CALLOC, NULL); + index = CustomData_get_layer_index(dm-faceData, type); + dm-faceData.layers[index].flag |= CD_FLAG_TEMPORARY; + + data = datalayer = DM_get_face_data_layer(dm, type); + for(efa=em-faces.first; efa; efa=efa-next, data+=size) { + emdata = CustomData_em_get(em-fdata, efa-data, type); + memcpy(data, emdata, size); + } + } + } + + return datalayer; +} + static void emDM_release(DerivedMesh *dm) { EditMeshDerivedMesh *emdm= (EditMeshDerivedMesh*) dm; @@ -1287,6 +1324,7 @@ emdm-dm.copyVertArray = emDM_copyVertArray; emdm-dm.copyEdgeArray = emDM_copyEdgeArray; emdm-dm.copyFaceArray = emDM_copyFaceArray; + emdm-dm.getFaceDataArray = emDM_getFaceDataArray; emdm-dm.foreachMappedVert = emDM_foreachMappedVert; emdm-dm.foreachMappedEdge = emDM_foreachMappedEdge; @@ -3079,7 +3117,7 @@ /* *** GLSL */ -static void DM_add_tangent_layer(DerivedMesh *dm) +void DM_add_tangent_layer(DerivedMesh *dm) { /* mesh vars */ MTFace *mtface, *tf; Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-16 13:47:03 UTC (rev 15602) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-07-16 13:53:39 UTC (rev 15603) @@ -965,11 +965,11 @@ input-textype = type; if (type == GPU_TEX1D) { - input-tex = GPU_texture_create_1D(link-texturesize, link-ptr1, 1); + input-tex = GPU_texture_create_1D(link-texturesize, link-ptr1, 0); input-textarget = GL_TEXTURE_1D; } else { - input-tex = GPU_texture_create_2D(link-texturesize, link-texturesize, link-ptr2, 1); + input-tex =
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15671] branches/apricot/source: Apricot Branch
Revision: 15671 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15671 Author: blendix Date: 2008-07-21 17:35:11 +0200 (Mon, 21 Jul 2008) Log Message: --- Apricot Branch == * Refactoring in the texture and material drawing code, moving code into the gpu module, removing the duplicated versions in the game engine. * Made game engine text drawing work with GLSL. It works based on filling in the default uv layer, so it requires a texture with the text image and mapped as uv's to work. Modified Paths: -- branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h branches/apricot/source/blender/blenkernel/BKE_bad_level_calls.h branches/apricot/source/blender/blenkernel/BKE_mesh.h branches/apricot/source/blender/blenkernel/bad_level_call_stubs/stubs.c branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c branches/apricot/source/blender/blenkernel/intern/cdderivedmesh.c branches/apricot/source/blender/blenkernel/intern/image.c branches/apricot/source/blender/blenkernel/intern/mesh.c branches/apricot/source/blender/blenkernel/intern/subsurf_ccg.c branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/include/BDR_drawmesh.h branches/apricot/source/blender/include/BDR_drawobject.h branches/apricot/source/blender/python/CMakeLists.txt branches/apricot/source/blender/python/SConscript branches/apricot/source/blender/python/api2_2x/Blender.c branches/apricot/source/blender/python/api2_2x/Image.c branches/apricot/source/blender/python/api2_2x/Makefile branches/apricot/source/blender/src/drawmesh.c branches/apricot/source/blender/src/drawobject.c branches/apricot/source/blender/src/drawview.c branches/apricot/source/blender/src/editface.c branches/apricot/source/blender/src/editsima.c branches/apricot/source/blender/src/headerbuttons.c branches/apricot/source/blender/src/imagepaint.c branches/apricot/source/blender/src/meshtools.c branches/apricot/source/blender/src/sculptmode.c branches/apricot/source/blender/src/space.c branches/apricot/source/blender/src/verse_image.c branches/apricot/source/creator/Makefile branches/apricot/source/creator/SConscript branches/apricot/source/creator/creator.c branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderGL.h branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h branches/apricot/source/gameengine/GamePlayer/common/CMakeLists.txt branches/apricot/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp branches/apricot/source/gameengine/GamePlayer/common/GPC_RenderTools.h branches/apricot/source/gameengine/GamePlayer/common/SConscript branches/apricot/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_PolygonMaterial.cpp branches/apricot/source/gameengine/Rasterizer/RAS_IRenderTools.h branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp Added Paths: --- branches/apricot/source/blender/gpu/GPU_draw.h branches/apricot/source/blender/gpu/intern/gpu_draw.c Removed Paths: - branches/apricot/source/gameengine/GamePlayer/common/GPC_PolygonMaterial.cpp branches/apricot/source/gameengine/GamePlayer/common/GPC_PolygonMaterial.h Modified: branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h === --- branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h 2008-07-21 13:47:42 UTC (rev 15670) +++ branches/apricot/source/blender/blenkernel/BKE_DerivedMesh.h 2008-07-21 15:35:11 UTC (rev 15671) @@ -199,7 +199,8 @@ * * Also called for *final* editmode DerivedMeshes */ - void (*drawFacesSolid)(DerivedMesh *dm, int (*setMaterial)(int)); + void (*drawFacesSolid)(DerivedMesh *dm, + int (*setMaterial)(int, void *attribs)); /* Draw all faces * o If useTwoSided, draw front and back using col arrays @@ -221,7 +222,7 @@ * o Only if setMaterial returns true */ void (*drawFacesGLSL)(DerivedMesh *dm, - int (*setMaterial)(int, struct GPUVertexAttribs *attribs)); + int (*setMaterial)(int, void *attribs)); /* Draw mapped faces (no color, or texture) * o Only if !setDrawOptions or @@ -255,7 +256,7 @@ * o Only if setMaterial and setDrawOptions return true */ void (*drawMappedFacesGLSL)(DerivedMesh *dm, - int (*setMaterial)(int, struct GPUVertexAttribs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15690] branches/apricot/source: Apricot Branch: GLSL
Revision: 15690 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15690 Author: blendix Date: 2008-07-22 16:33:10 +0200 (Tue, 22 Jul 2008) Log Message: --- Apricot Branch: GLSL Added support for some world settings, updated docs. * Ambient color * Exposure/Range * Mist (implementation should be optimized) http://www.blender.org/development/current-projects/changes-since-246/realtime-glsl-materials/ Modified Paths: -- branches/apricot/source/blender/gpu/GPU_draw.h branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp Modified: branches/apricot/source/blender/gpu/GPU_draw.h === --- branches/apricot/source/blender/gpu/GPU_draw.h 2008-07-22 12:02:57 UTC (rev 15689) +++ branches/apricot/source/blender/gpu/GPU_draw.h 2008-07-22 14:33:10 UTC (rev 15690) @@ -46,7 +46,11 @@ * shared with the game engine, where there were previously * duplicates of some of these functions. */ -/* Initialize */ +/* Initialize + * - sets the default Blender opengl state, if in doubt, check + * the contents of this function + * - this is called when starting Blender, for opengl rendering, + * and for switching back from the game engine for example. */ void GPU_state_init(void); @@ -94,7 +98,8 @@ void GPU_set_linear_mipmap(int linear); void GPU_paint_set_mipmap(int mipmap); -/* Image opengl free and update */ +/* Image updates and free + * - these deal with images bound as opengl textures */ void GPU_paint_update_image(struct Image *ima, int x, int y, int w, int h); void GPU_update_images_framechange(void); Modified: branches/apricot/source/blender/gpu/intern/gpu_material.c === --- branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-07-22 12:02:57 UTC (rev 15689) +++ branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-07-22 14:33:10 UTC (rev 15690) @@ -42,6 +42,7 @@ #include DNA_scene_types.h #include DNA_texture_types.h #include DNA_view3d_types.h +#include DNA_world_types.h #include BKE_colortools.h #include BKE_DerivedMesh.h @@ -1000,9 +1001,11 @@ void GPU_shaderesult_set(GPUShadeInput *shi, GPUShadeResult *shr) { + GPUMaterial *mat= shi-gpumat; + GPUNodeLink *emit, *ulinfac, *ulogfac, *mistfac; Material *ma= shi-mat; - GPUMaterial *mat= shi-gpumat; - GPUNodeLink *emit; + World *world= mat-scene-world; + float linfac, logfac, misttype; memset(shr, 0, sizeof(*shr)); @@ -1037,6 +1040,29 @@ shr-combined = shr-diff; shr-alpha = shi-alpha; + if(world) { + /* exposure correction */ + if(world-exp!=0.0f || world-range!=1.0f) { + linfac= 1.0 + pow((2.0*world-exp + 0.5), -10); + logfac= log((linfac-1.0)/linfac)/world-range; + + GPU_link(mat, set_value, GPU_uniform(linfac), ulinfac); + GPU_link(mat, set_value, GPU_uniform(logfac), ulogfac); + + GPU_link(mat, shade_exposure_correct, shr-combined, + ulinfac, ulogfac, shr-combined); + GPU_link(mat, shade_exposure_correct, shr-spec, + ulinfac, ulogfac, shr-spec); + } + + /* ambient color */ + if(world-ambr!=0.0f || world-ambg!=0.0f || world-ambb!=0.0f) { + if(GPU_link_changed(shi-amb) || ma-amb != 0.0f) + GPU_link(mat, shade_maddf, shr-combined, GPU_uniform(ma-amb), + GPU_uniform(world-ambr), shr-combined); + } + } + if(ma-mode MA_RAMP_COL) ramp_diffuse_result(shi, shr-combined); if(ma-mode MA_RAMP_SPEC) ramp_spec_result(shi, shr-spec); @@ -1044,6 +1070,17 @@ GPU_link(mat, shade_add, shr-combined, shr-spec, shr-combined); } + if(world (world-mode WO_MIST) !(ma-mode MA_NOMIST)) { + misttype = world-mistype; + + GPU_link(mat, shade_mist_factor, GPU_builtin(GPU_VIEW_POSITION), + GPU_uniform(world-miststa), GPU_uniform(world-mistdist), + GPU_uniform(misttype), GPU_uniform(world-misi), mistfac); + + GPU_link(mat, mix_blend, mistfac, GPU_uniform(world-horr), + shr-combined,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15724] branches/apricot/source/blender/ blenkernel/intern/DerivedMesh.c: Apricot Branch: fix for typo, no idea how this compiled with gcc..
Revision: 15724 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15724 Author: blendix Date: 2008-07-24 00:23:28 +0200 (Thu, 24 Jul 2008) Log Message: --- Apricot Branch: fix for typo, no idea how this compiled with gcc.. Modified Paths: -- branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c Modified: branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c === --- branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c 2008-07-23 21:37:37 UTC (rev 15723) +++ branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c 2008-07-23 22:23:28 UTC (rev 15724) @@ -1898,7 +1898,7 @@ void *userData) { /* not supported yet */ - vDM_drawFacesText(dm, NULL); + vDM_drawFacesTex(dm, NULL); } /**/ ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15844] branches/apricot: svn merge -r15780:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/ blender
Revision: 15844 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15844 Author: blendix Date: 2008-07-28 16:35:56 +0200 (Mon, 28 Jul 2008) Log Message: --- svn merge -r15780:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender Modified Paths: -- branches/apricot/release/scripts/rvk1_torvk2.py branches/apricot/source/blender/include/BIF_editarmature.h branches/apricot/source/blender/makesdna/DNA_armature_types.h branches/apricot/source/blender/makesdna/DNA_constraint_types.h branches/apricot/source/blender/makesdna/DNA_object_types.h branches/apricot/source/blender/python/api2_2x/Armature.c branches/apricot/source/blender/python/api2_2x/Bone.c branches/apricot/source/blender/python/api2_2x/doc/Armature.py branches/apricot/source/blender/python/api2_2x/sceneRender.c branches/apricot/source/blender/src/buttons_editing.c branches/apricot/source/blender/src/buttons_object.c branches/apricot/source/blender/src/drawgpencil.c branches/apricot/source/blender/src/drawview.c branches/apricot/source/blender/src/editarmature.c branches/apricot/source/blender/src/editobject.c branches/apricot/source/blender/src/gpencil.c branches/apricot/source/blender/src/interface.c branches/apricot/source/blender/src/outliner.c branches/apricot/source/blender/src/poseobject.c branches/apricot/source/blender/src/transform_conversions.c branches/apricot/source/blender/src/transform_manipulator.c branches/apricot/source/creator/creator.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp Modified: branches/apricot/release/scripts/rvk1_torvk2.py === --- branches/apricot/release/scripts/rvk1_torvk2.py 2008-07-28 14:28:19 UTC (rev 15843) +++ branches/apricot/release/scripts/rvk1_torvk2.py 2008-07-28 14:35:56 UTC (rev 15844) @@ -14,7 +14,7 @@ __version__ = 2007/04/27 __bpydoc__ = \ -DEFORM to RVK2 copies deform data (except EDGESPLIT,DECIMATE,SUBSURF,BOOLEAN, +DEFORM to RVK2 copies deform data (except EDGESPLIT,DECIMATE,SUBSURF,BOOLEAN, BUILD,MIRROR,ARRAY) of the active object to the RVK (relative vertex key) of the other selected object. @@ -25,7 +25,7 @@ The new version of this scrit (Blender 2.43) manages the modifier changes. There are a lot of modifiers but only the ones which just deforms the shape can be used : LATTICE, CURVE, WAVE, ARMATURE. You can unset these modifiers -from the script. +from the script. Usage: @@ -35,7 +35,7 @@ level, the script will ask if it should change that. Before copying data to the rvk it will also ask whether it should replace or add a new vertex group. - + #-- @@ -70,7 +70,7 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA # Copy the rvk (1, or armature, lattice, or # any mesh deformation except surface @@ -83,7 +83,7 @@ # download the script : # http://jmsoler.free.fr/util/blenderfile/py/rvk1_torvk2.py # Communicate upon problems or errors: -# http://www.zoo-logique.org/3D.Blender/newsportal/thread.php?group=3D.Blender +# http://www.zoo-logique.org/3D.Blender/newsportal/thread.php?group=3D.Blender #-- # Page officielle : # http://jmsoler.free.fr/util/blenderfile/py/rvk1_torvk2.py @@ -101,22 +101,22 @@ exec t=Modifier.Types.%s%t return t -def deform2rvk(): +def deform2rvk(): POSSMOD_list=['EDGESPLIT', 'DECIMATE', - 'SUBSURF', - 'BOOLEAN', + 'SUBSURF', + 'BOOLEAN', 'BUILD', - 'MIRROR', + 'MIRROR', 'ARRAY'] AUTHMOD_list=['LATTICE', - 'CURVE', + 'CURVE', 'WAVE', 'ARMATURE'] MODIFIERS=0 - + BMOD=[['Possible Modifiers'], ['Allowed Modifiers']] @@ -129,8 +129,8 @@ # = # must be 2 meshes #
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15867] trunk/blender/source: Game Engine: alpha blending and sorting
Revision: 15867 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15867 Author: blendix Date: 2008-07-29 17:48:31 +0200 (Tue, 29 Jul 2008) Log Message: --- Game Engine: alpha blending and sorting === Alpha blending + sorting was revised, to fix bugs and get it to work more predictable. * A new per texture face Sort setting defines if the face is alpha sorted or not, instead of abusing the ZTransp setting as it did before. * Existing files are converted to hopefully match the old behavior as much as possible with a version patch. * On new meshes the Sort flag is disabled by the default, to avoid unexpected and hard to find slowdowns. * Alpha sorting for faces was incredibly slow. Sorting faces in a mesh with 600 faces lowered the framerate from 200 to 70 fps in my test.. the sorting there case goes about 15x faster now, but it is still advised to use Clip Alpha if possible instead of regular Alpha. * There still various limitations in the alpha sorting code, I've added some comments to the code about this. Some docs at the bottom of the page: http://www.blender.org/development/current-projects/changes-since-246/realtime-glsl-materials/ Merged some fixes from the apricot branch, most important change is that tangents are now exactly the same as the rest of Blender, instead of being computed in the game engine with a different algorithm. Also, the subversion was bumped to 1. Modified Paths: -- trunk/blender/source/blender/blenkernel/BKE_DerivedMesh.h trunk/blender/source/blender/blenkernel/BKE_blender.h trunk/blender/source/blender/blenkernel/intern/DerivedMesh.c trunk/blender/source/blender/blenkernel/intern/customdata.c trunk/blender/source/blender/blenloader/intern/readfile.c trunk/blender/source/blender/makesdna/DNA_customdata_types.h trunk/blender/source/blender/makesdna/DNA_meshdata_types.h trunk/blender/source/blender/src/buttons_editing.c trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderGL.cpp trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp trunk/blender/source/gameengine/Converter/BL_BlenderDataConversion.cpp trunk/blender/source/gameengine/Ketsji/BL_BlenderShader.cpp trunk/blender/source/gameengine/Ketsji/BL_BlenderShader.h trunk/blender/source/gameengine/Ketsji/BL_Material.h trunk/blender/source/gameengine/Ketsji/BL_Texture.cpp trunk/blender/source/gameengine/Ketsji/KX_BlenderMaterial.cpp trunk/blender/source/gameengine/Ketsji/KX_BlenderMaterial.h trunk/blender/source/gameengine/Ketsji/KX_GameObject.cpp trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.cpp trunk/blender/source/gameengine/Ketsji/KX_PolygonMaterial.cpp trunk/blender/source/gameengine/Ketsji/KX_PolygonMaterial.h trunk/blender/source/gameengine/Ketsji/KX_Scene.cpp trunk/blender/source/gameengine/Rasterizer/RAS_BucketManager.cpp trunk/blender/source/gameengine/Rasterizer/RAS_BucketManager.h trunk/blender/source/gameengine/Rasterizer/RAS_IPolygonMaterial.cpp trunk/blender/source/gameengine/Rasterizer/RAS_IPolygonMaterial.h trunk/blender/source/gameengine/Rasterizer/RAS_IRasterizer.h trunk/blender/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp trunk/blender/source/gameengine/Rasterizer/RAS_MaterialBucket.h trunk/blender/source/gameengine/Rasterizer/RAS_MeshObject.cpp trunk/blender/source/gameengine/Rasterizer/RAS_MeshObject.h trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp trunk/blender/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h trunk/blender/source/gameengine/Rasterizer/RAS_Polygon.cpp Removed Paths: - trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderPolyMaterial.cpp trunk/blender/source/gameengine/BlenderRoutines/KX_BlenderPolyMaterial.h Modified: trunk/blender/source/blender/blenkernel/BKE_DerivedMesh.h === --- trunk/blender/source/blender/blenkernel/BKE_DerivedMesh.h 2008-07-29 15:27:03 UTC (rev 15866) +++ trunk/blender/source/blender/blenkernel/BKE_DerivedMesh.h 2008-07-29 15:48:31 UTC (rev 15867) @@ -437,5 +437,7 @@ /* determines required DerivedMesh data according to view and edit modes */ CustomDataMask get_viewedit_datamask(); +void DM_add_tangent_layer(DerivedMesh *dm); + #endif Modified: trunk/blender/source/blender/blenkernel/BKE_blender.h === --- trunk/blender/source/blender/blenkernel/BKE_blender.h 2008-07-29 15:27:03 UTC (rev 15866) +++ trunk/blender/source/blender/blenkernel/BKE_blender.h 2008-07-29 15:48:31 UTC (rev 15867) @@ -41,7 +41,7 @@ struct MemFile; #define BLENDER_VERSION246 -#define BLENDER_SUBVERSION 0
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15868] branches/apricot/source: Apricot Branch
Revision: 15868 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15868 Author: blendix Date: 2008-07-29 18:25:20 +0200 (Tue, 29 Jul 2008) Log Message: --- Apricot Branch == svn merge -r15866:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender Alpha blending and sorting changes, but also include some initial support for GLSL lamps in dupligroups (only one duplicate works at the moment). Modified Paths: -- branches/apricot/source/blender/blenkernel/BKE_blender.h branches/apricot/source/blender/blenloader/intern/readfile.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c branches/apricot/source/blender/makesdna/DNA_meshdata_types.h branches/apricot/source/blender/src/buttons_editing.c branches/apricot/source/blender/src/drawview.c branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.cpp branches/apricot/source/gameengine/Ketsji/BL_Material.h branches/apricot/source/gameengine/Ketsji/BL_Texture.cpp branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.h branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.cpp branches/apricot/source/gameengine/Ketsji/KX_PolygonMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_PolygonMaterial.h branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp branches/apricot/source/gameengine/Rasterizer/RAS_IPolygonMaterial.cpp branches/apricot/source/gameengine/Rasterizer/RAS_IPolygonMaterial.h branches/apricot/source/gameengine/Rasterizer/RAS_IRasterizer.h branches/apricot/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp branches/apricot/source/gameengine/Rasterizer/RAS_MaterialBucket.h branches/apricot/source/gameengine/Rasterizer/RAS_MeshObject.cpp branches/apricot/source/gameengine/Rasterizer/RAS_MeshObject.h branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h branches/apricot/source/gameengine/Rasterizer/RAS_Polygon.cpp Removed Paths: - branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderPolyMaterial.cpp branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderPolyMaterial.h Modified: branches/apricot/source/blender/blenkernel/BKE_blender.h === --- branches/apricot/source/blender/blenkernel/BKE_blender.h2008-07-29 15:48:31 UTC (rev 15867) +++ branches/apricot/source/blender/blenkernel/BKE_blender.h2008-07-29 16:25:20 UTC (rev 15868) @@ -41,7 +41,7 @@ struct MemFile; #define BLENDER_VERSION246 -#define BLENDER_SUBVERSION 0 +#define BLENDER_SUBVERSION 1 #define BLENDER_MINVERSION 245 #define BLENDER_MINSUBVERSION 15 Modified: branches/apricot/source/blender/blenloader/intern/readfile.c === --- branches/apricot/source/blender/blenloader/intern/readfile.c 2008-07-29 15:48:31 UTC (rev 15867) +++ branches/apricot/source/blender/blenloader/intern/readfile.c 2008-07-29 16:25:20 UTC (rev 15868) @@ -4899,6 +4899,49 @@ } } +void alphasort_version_246(FileData *fd, Library *lib, Mesh *me) +{ + Material *ma; + MFace *mf; + MTFace *tf; + int a, b, texalpha; + + /* verify we have a tface layer */ + for(b=0; bme-fdata.totlayer; b++) + if(me-fdata.layers[b].type == CD_MTFACE) + break; + + if(b == me-fdata.totlayer) + return; + + /* if we do, set alpha sort if the game engine did it before */ + for(a=0, mf=me-mface; ame-totface; a++, mf++) { + if(mf-mat_nr me-totcol) { + ma= newlibadr(fd, lib, me-mat[mf-mat_nr]); + texalpha = 0; + + for(b=0; ma bMAX_MTEX; b++) + if(ma-mtex ma-mtex[b] ma-mtex[b]-mapto MAP_ALPHA) + texalpha = 1; + } + else { + ma= NULL; + texalpha = 0; + } + + for(b=0; bme-fdata.totlayer; b++) { + if(me-fdata.layers[b].type == CD_MTFACE) { + tf = ((MTFace*)me-fdata.layers[b].data) + a; + +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15906] branches/blender-2.47: branches/ blender-2.47
Revision: 15906 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15906 Author: blendix Date: 2008-08-01 21:49:11 +0200 (Fri, 01 Aug 2008) Log Message: --- branches/blender-2.47 Merge over the game engine changes from trunk into 2.47. The most user visible changes are in logic with new sensors, controllers and actuators, the state system, shape key drivers, dupligroups, and more. There are also new python fynctions and the alpha sorting setting. The rest consists of refactoring, fixes and optimizations. MSVC projectfiles might no be merged over correct, I didn't have a way to check this. Merge from trunk: Revision: 14949 Revision: 14952 Revision: 14960 Revision: 15087 Revision: 15172 Revision: 15182 Revision: 15213 Revision: 15221 Revision: 15227 Revision: 15231 Revision: 15249 Revision: 15260 Revision: 15261 Revision: 15263 Revision: 15264 Revision: 15276 Revision: 15280 Revision: 15291 Revision: 15306 Revision: 15327 Revision: 15333 Revision: 15335 Revision: 15336 Revision: 15345 Revision: 15346 Revision: 15347 Revision: 15348 Revision: 15352 Revision: 15354 Revision: 15359 Revision: 15367 Revision: 15376 Revision: 15377 Revision: 15382 Revision: 15387 Revision: 15388 Revision: 15388 Revision: 15394 Revision: 15395 Revision: 15397 Revision: 15413 Revision: 15420 Revision: 15421 Revision: 15425 Revision: 15431 Revision: 15451 Revision: 15477 Revision: 15486 Revision: 15498 Revision: 15504 Revision: 15517 Revision: 15519 Revision: 15546 Revision: 15547 Revision: 15592 Revision: 15607 Revision: 15611 Revision: 15628 Revision: 15638 Revision: 15639 Revision: 15642 Revision: 15656 Revision: 15660 Revision: 15662 Revision: 15663 Revision: 15668 Revision: 15693 Revision: 15695 Revision: 15702 Revision: 15714 Revision: 15723 Revision: 15760 Revision: 15778 Revision: 15843 Revision: 15855 Revision: 15867 Revision: 15872 Revision: 15873 Revision: 15874 Revision: 15875 Revision: 15882 Revision: 15883 Revision: 15884 Revision: 15886 Modified Paths: -- branches/blender-2.47/blenderplayer/CMakeLists.txt branches/blender-2.47/extern/CMakeLists.txt branches/blender-2.47/extern/Makefile branches/blender-2.47/extern/SConscript branches/blender-2.47/extern/make/msvc_7_0/extern.sln branches/blender-2.47/intern/moto/include/GEN_Map.h branches/blender-2.47/projectfiles_vc7/blender/blender.vcproj branches/blender-2.47/projectfiles_vc7/blender/src/BL_src.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/blenderhook/KX_blenderhook.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/converter/KX_converter.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/gamelogic/SCA_GameLogic.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/gameplayer/common/GP_common.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/gameplayer/ghost/GP_ghost.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/ketsji/KX_ketsji.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/rasterizer/RAS_rasterizer.vcproj branches/blender-2.47/projectfiles_vc7/gameengine/rasterizer/openglrasterizer/RAS_openglrasterizer.vcproj branches/blender-2.47/source/Makefile branches/blender-2.47/source/blender/blenkernel/BKE_DerivedMesh.h branches/blender-2.47/source/blender/blenkernel/BKE_action.h branches/blender-2.47/source/blender/blenkernel/BKE_blender.h branches/blender-2.47/source/blender/blenkernel/BKE_ipo.h branches/blender-2.47/source/blender/blenkernel/BKE_key.h branches/blender-2.47/source/blender/blenkernel/BKE_scene.h branches/blender-2.47/source/blender/blenkernel/intern/DerivedMesh.c branches/blender-2.47/source/blender/blenkernel/intern/action.c branches/blender-2.47/source/blender/blenkernel/intern/customdata.c branches/blender-2.47/source/blender/blenkernel/intern/key.c branches/blender-2.47/source/blender/blenkernel/intern/sca.c branches/blender-2.47/source/blender/blenloader/intern/readfile.c branches/blender-2.47/source/blender/blenloader/intern/writefile.c branches/blender-2.47/source/blender/include/BIF_butspace.h branches/blender-2.47/source/blender/include/BIF_interface.h branches/blender-2.47/source/blender/include/butspace.h
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15932] branches/apricot: apricot branch: svn merge -r15868:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/ blender
Revision: 15932 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15932 Author: blendix Date: 2008-08-03 16:46:34 +0200 (Sun, 03 Aug 2008) Log Message: --- apricot branch: svn merge -r15868:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender Modified Paths: -- branches/apricot/bin/.blender/.Blanguages branches/apricot/intern/boolop/SConscript branches/apricot/intern/boolop/intern/BOP_Edge.cpp branches/apricot/intern/boolop/intern/BOP_Edge.h branches/apricot/intern/boolop/intern/BOP_Face.cpp branches/apricot/intern/boolop/intern/BOP_Face.h branches/apricot/intern/boolop/intern/BOP_Interface.cpp branches/apricot/intern/boolop/intern/BOP_Merge.cpp branches/apricot/intern/boolop/intern/BOP_Merge.h branches/apricot/intern/boolop/intern/BOP_Mesh.cpp branches/apricot/intern/boolop/intern/BOP_Mesh.h branches/apricot/intern/boolop/intern/BOP_Tag.h branches/apricot/intern/boolop/intern/BOP_Vertex.cpp branches/apricot/intern/boolop/intern/BOP_Vertex.h branches/apricot/intern/bsp/SConscript branches/apricot/projectfiles_vc7/gameengine/blenderhook/KX_blenderhook.vcproj branches/apricot/projectfiles_vc7/gameengine/ketsji/KX_ketsji.vcproj branches/apricot/projectfiles_vc7/gameengine/physics/PHY_Physics/PHY_Sumo/PHY_Sumo.vcproj branches/apricot/release/scripts/bpymodules/colladaImEx/collada.py branches/apricot/release/scripts/bpymodules/colladaImEx/translator.py branches/apricot/release/scripts/bpymodules/colladaImEx/xmlUtils.py branches/apricot/source/blender/blenkernel/BKE_texture.h branches/apricot/source/blender/blenkernel/intern/collision.c branches/apricot/source/blender/blenkernel/intern/texture.c branches/apricot/source/blender/blenlib/intern/BLI_kdopbvh.c branches/apricot/source/blender/blenlib/intern/boxpack2d.c branches/apricot/source/blender/blenloader/intern/writefile.c branches/apricot/source/blender/include/BDR_gpencil.h branches/apricot/source/blender/include/BIF_editview.h branches/apricot/source/blender/makesdna/DNA_gpencil_types.h branches/apricot/source/blender/src/buttons_logic.c branches/apricot/source/blender/src/drawgpencil.c branches/apricot/source/blender/src/editimasel.c branches/apricot/source/blender/src/editipo.c branches/apricot/source/blender/src/editobject.c branches/apricot/source/blender/src/editview.c branches/apricot/source/blender/src/gpencil.c branches/apricot/source/blender/src/header_info.c branches/apricot/source/blender/src/header_ipo.c branches/apricot/source/blender/src/header_view3d.c branches/apricot/source/blender/src/meshlaplacian.c branches/apricot/source/blender/src/space.c branches/apricot/source/blender/src/toolbox.c branches/apricot/source/gameengine/Converter/BL_ActionActuator.cpp branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Converter/KX_ConvertSensors.cpp branches/apricot/source/gameengine/GameLogic/SCA_ActuatorEventManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_ActuatorEventManager.h branches/apricot/source/gameengine/GameLogic/SCA_AlwaysEventManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_AlwaysEventManager.h branches/apricot/source/gameengine/GameLogic/SCA_EventManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_EventManager.h branches/apricot/source/gameengine/GameLogic/SCA_IObject.cpp branches/apricot/source/gameengine/GameLogic/SCA_ISensor.cpp branches/apricot/source/gameengine/GameLogic/SCA_ISensor.h branches/apricot/source/gameengine/GameLogic/SCA_JoystickManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_JoystickManager.h branches/apricot/source/gameengine/GameLogic/SCA_KeyboardManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_KeyboardManager.h branches/apricot/source/gameengine/GameLogic/SCA_LogicManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_MouseManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_MouseManager.h branches/apricot/source/gameengine/GameLogic/SCA_PropertyEventManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_PropertyEventManager.h branches/apricot/source/gameengine/GameLogic/SCA_RandomEventManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_RandomEventManager.h branches/apricot/source/gameengine/GameLogic/SCA_TimeEventManager.cpp branches/apricot/source/gameengine/GameLogic/SCA_TimeEventManager.h branches/apricot/source/gameengine/GamePlayer/common/windows/GPW_Canvas.h branches/apricot/source/gameengine/Ketsji/KXNetwork/KX_NetworkEventManager.cpp branches/apricot/source/gameengine/Ketsji/KXNetwork/KX_NetworkEventManager.h
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15938] branches/apricot/source/gameengine /Converter/BL_BlenderDataConversion.cpp: apricot branch: fix a bug with the export of the second uv layer
Revision: 15938 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=15938 Author: blendix Date: 2008-08-03 18:02:56 +0200 (Sun, 03 Aug 2008) Log Message: --- apricot branch: fix a bug with the export of the second uv layer to the game engine for GLSL. Modified Paths: -- branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp Modified: branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp === --- branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp 2008-08-03 15:57:09 UTC (rev 15937) +++ branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp 2008-08-03 16:02:56 UTC (rev 15938) @@ -644,6 +644,7 @@ for (int vind = 0; vindmaterial-num_enabled; vind++) { BL_Mapping map = material-mapping[vind]; + if (map.uvCoName.IsEmpty()) isFirstSet = false; else @@ -673,7 +674,7 @@ isFirstSet = false; uvName = layer.name; } - else + else if(strcmp(layer.name, uvName) != 0) { uv2[0] = uvSet[0]; uv2[1] = uvSet[1]; uv2[2] = uvSet[2]; uv2[3] = uvSet[3]; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16080] branches/apricot: Apricot Branch
Revision: 16080 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16080 Author: blendix Date: 2008-08-13 19:37:37 +0200 (Wed, 13 Aug 2008) Log Message: --- Apricot Branch == Various cleanups and optimizations in the game engine: * Remove some duplication in the RAS_RenderTools, and sync the blender and game player versions. Also avoid some opengl state changes. * Don't make separate materials for triangles and quads, this distinction was moved to the mesh level. Also don't take some other irrelevant tface settings into account to avoid making more materials. * Refactoring of mesh storage, should fix wrong normals on meshes that are reused. It also allows for joining together nearby meshes for speed, though that's disabled still because it doesn't work together correct yet with ome features. * Added a distinction for game objects to be either culled or set invisible, previously there was only one flag, which couldn't work correct. * For parenting to bones, where_is_pose was executed multiple times per frame, now should be once per armature. * Fix uninitialized intertia value in the physics system. * Various warning fixes. * Removed some conditionals in GLSL and other minor optimizations in the code. Also cache opengl uniform locations, and fix an invalid memory read. * Avoid doing some math for GLSL lamps if it is not required. Modified Paths: -- branches/apricot/intern/moto/include/GEN_Map.h branches/apricot/intern/moto/include/MT_Matrix4x4.h branches/apricot/intern/moto/include/MT_Matrix4x4.inl branches/apricot/source/blender/blenkernel/intern/armature.c branches/apricot/source/blender/gpu/GPU_extensions.h branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_codegen.h branches/apricot/source/blender/gpu/intern/gpu_extensions.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c branches/apricot/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.cpp branches/apricot/source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp branches/apricot/source/gameengine/Converter/BL_ArmatureObject.h branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp branches/apricot/source/gameengine/Converter/BL_ShapeActionActuator.cpp branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.cpp branches/apricot/source/gameengine/Converter/BL_SkinDeformer.cpp branches/apricot/source/gameengine/Converter/BL_SkinDeformer.h branches/apricot/source/gameengine/Converter/BL_SkinMeshObject.cpp branches/apricot/source/gameengine/Converter/BL_SkinMeshObject.h branches/apricot/source/gameengine/Converter/KX_BlenderSceneConverter.cpp branches/apricot/source/gameengine/Converter/KX_ConvertActuators.cpp branches/apricot/source/gameengine/GamePlayer/common/GPC_RenderTools.cpp branches/apricot/source/gameengine/GamePlayer/common/GPC_RenderTools.h branches/apricot/source/gameengine/GamePlayer/common/unix/GPU_PolygonMaterial.h branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.cpp branches/apricot/source/gameengine/Ketsji/BL_BlenderShader.h branches/apricot/source/gameengine/Ketsji/BL_Material.h branches/apricot/source/gameengine/Ketsji/BL_Shader.cpp branches/apricot/source/gameengine/Ketsji/BL_Shader.h branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_BlenderMaterial.h branches/apricot/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp branches/apricot/source/gameengine/Ketsji/KX_GameObject.cpp branches/apricot/source/gameengine/Ketsji/KX_GameObject.h branches/apricot/source/gameengine/Ketsji/KX_MeshProxy.cpp branches/apricot/source/gameengine/Ketsji/KX_PolygonMaterial.cpp branches/apricot/source/gameengine/Ketsji/KX_PolygonMaterial.h branches/apricot/source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.cpp branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/Ketsji/KX_VertexProxy.cpp branches/apricot/source/gameengine/Ketsji/KX_VisibilityActuator.cpp branches/apricot/source/gameengine/Physics/Bullet/CcdPhysicsController.h branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.h branches/apricot/source/gameengine/Rasterizer/RAS_IPolygonMaterial.cpp branches/apricot/source/gameengine/Rasterizer/RAS_IPolygonMaterial.h
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16082] branches/apricot/source: Apricot Branch
Revision: 16082 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16082 Author: blendix Date: 2008-08-13 19:42:58 +0200 (Wed, 13 Aug 2008) Log Message: --- Apricot Branch == svn merge -r16064:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender Modified Paths: -- branches/apricot/source/blender/blenkernel/intern/bvhutils.c branches/apricot/source/blender/src/header_view3d.c branches/apricot/source/gameengine/GameLogic/SCA_PythonController.cpp Modified: branches/apricot/source/blender/blenkernel/intern/bvhutils.c === --- branches/apricot/source/blender/blenkernel/intern/bvhutils.c 2008-08-13 17:38:38 UTC (rev 16081) +++ branches/apricot/source/blender/blenkernel/intern/bvhutils.c 2008-08-13 17:42:58 UTC (rev 16082) @@ -48,9 +48,6 @@ /* Math stuff for ray casting on mesh faces and for nearest surface */ -static float nearest_point_in_tri_surface(const float *point, const float *v0, const float *v1, const float *v2, float *nearest); - -#define ISECT_EPSILON 1e-6 static float ray_tri_intersection(const BVHTreeRay *ray, const float m_dist, const float *v0, const float *v1, const float *v2) { float dist; @@ -79,170 +76,324 @@ return FLT_MAX; } + /* - * This calculates the distance from point to the plane - * Distance is negative if point is on the back side of plane + * Function adapted from David Eberly's distance tools (LGPL) + * http://www.geometrictools.com/LibFoundation/Distance/Distance.html */ -static float point_plane_distance(const float *point, const float *plane_point, const float *plane_normal) +static float nearest_point_in_tri_surface(const float *v0,const float *v1,const float *v2,const float *p, int *v, int *e, float *d, float *nearest ) { - float pp[3]; - VECSUB(pp, point, plane_point); - return INPR(pp, plane_normal); -} -static float choose_nearest(const float v0[2], const float v1[2], const float point[2], float closest[2]) -{ - float d[2][2], sdist[2]; - VECSUB2D(d[0], v0, point); - VECSUB2D(d[1], v1, point); + float diff[3]; + float e0[3]; + float e1[3]; + float A00; + float A01; + float A11; + float B0; + float B1; + float C; + float Det; + float S; + float T; + float sqrDist; + int lv = -1, le = -1; + + VECSUB(diff, v0, p); + VECSUB(e0, v1, v0); + VECSUB(e1, v2, v0); + + A00 = INPR ( e0, e0 ); + A01 = INPR( e0, e1 ); + A11 = INPR ( e1, e1 ); + B0 = INPR( diff, e0 ); + B1 = INPR( diff, e1 ); + C = INPR( diff, diff ); + Det = fabs( A00 * A11 - A01 * A01 ); + S = A01 * B1 - A11 * B0; + T = A01 * B0 - A00 * B1; - sdist[0] = d[0][0]*d[0][0] + d[0][1]*d[0][1]; - sdist[1] = d[1][0]*d[1][0] + d[1][1]*d[1][1]; - - if(sdist[0] sdist[1]) + if ( S + T = Det ) { - if(closest) - VECCOPY2D(closest, v0); - return sdist[0]; + if ( S 0.0f ) + { + if ( T 0.0f ) // Region 4 + { + if ( B0 0.0f ) + { + T = 0.0f; + if ( -B0 = A00 ) + { + S = (float)1.0; + sqrDist = A00 + 2.0f * B0 + C; + lv = 1; + } + else + { + if(fabs(A00) FLT_EPSILON) + S = -B0/A00; + else + S = 0.0f; + sqrDist = B0 * S + C; + le = 0; + } + } + else + { + S = 0.0f; + if ( B1 = 0.0f ) + { + T = 0.0f; + sqrDist = C; + lv = 0; + } + else if ( -B1 = A11 ) + { + T = 1.0f; + sqrDist =
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16114] branches/apricot/source/gameengine /Rasterizer/RAS_BucketManager.cpp: Apricot branch: a fix for flickering alpha, with multi-material
Revision: 16114 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16114 Author: blendix Date: 2008-08-14 19:12:40 +0200 (Thu, 14 Aug 2008) Log Message: --- Apricot branch: a fix for flickering alpha, with multi-material objects. Note that sorting is only between polygons with the same material, so which material draws first is still arbitrary, but consistent. Modified Paths: -- branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp Modified: branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp === --- branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp 2008-08-14 17:09:39 UTC (rev 16113) +++ branches/apricot/source/gameengine/Rasterizer/RAS_BucketManager.cpp 2008-08-14 17:12:40 UTC (rev 16114) @@ -69,7 +69,7 @@ { bool operator()(const sortedmeshslot a, const sortedmeshslot b) { - return a.m_z b.m_z; + return (a.m_z b.m_z) || (a.m_z == b.m_z a.m_ms b.m_ms); } }; @@ -77,7 +77,7 @@ { bool operator()(const sortedmeshslot a, const sortedmeshslot b) { - return a.m_z b.m_z; + return (a.m_z b.m_z) || (a.m_z == b.m_z a.m_ms b.m_ms); } }; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16165] branches/apricot/source/gameengine /Converter: Apricot Branch: bugfix, some meshes were not deforming anymore
Revision: 16165 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16165 Author: blendix Date: 2008-08-18 12:27:48 +0200 (Mon, 18 Aug 2008) Log Message: --- Apricot Branch: bugfix, some meshes were not deforming anymore after a recent commit. Modified Paths: -- branches/apricot/source/gameengine/Converter/BL_DeformableGameObject.cpp branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp branches/apricot/source/gameengine/Converter/BL_MeshDeformer.h branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.h branches/apricot/source/gameengine/Converter/BL_SkinDeformer.cpp branches/apricot/source/gameengine/Converter/BL_SkinDeformer.h Modified: branches/apricot/source/gameengine/Converter/BL_DeformableGameObject.cpp === --- branches/apricot/source/gameengine/Converter/BL_DeformableGameObject.cpp 2008-08-18 10:24:56 UTC (rev 16164) +++ branches/apricot/source/gameengine/Converter/BL_DeformableGameObject.cpp 2008-08-18 10:27:48 UTC (rev 16165) @@ -41,12 +41,14 @@ delete m_pDeformer; // __NLA : Temporary until we decide where to put this } -void BL_DeformableGameObject::ProcessReplica(KX_GameObject* replica) +void BL_DeformableGameObject::ProcessReplica(KX_GameObject* replica) { + BL_MeshDeformer *deformer; KX_GameObject::ProcessReplica(replica); - if (m_pDeformer){ - ((BL_DeformableGameObject*)replica)-m_pDeformer = m_pDeformer-GetReplica(); + if (m_pDeformer) { + deformer = (BL_MeshDeformer*)m_pDeformer-GetReplica(); + ((BL_DeformableGameObject*)replica)-m_pDeformer = deformer; } } Modified: branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp === --- branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp 2008-08-18 10:24:56 UTC (rev 16164) +++ branches/apricot/source/gameengine/Converter/BL_MeshDeformer.cpp 2008-08-18 10:27:48 UTC (rev 16165) @@ -90,8 +90,18 @@ delete [] m_transverts; if (m_transnors) delete [] m_transnors; -}; +} + +void BL_MeshDeformer::Relink(GEN_Mapclass GEN_HashedPtr, void**map) +{ + void **h_obj = (*map)[m_gameobj]; + if (h_obj) + m_gameobj = (BL_DeformableGameObject*)(*h_obj); + else + m_gameobj = NULL; +} + /** * @warning This function is expensive! */ @@ -218,4 +228,4 @@ m_tvtot = m_bmesh-totvert; } } - + Modified: branches/apricot/source/gameengine/Converter/BL_MeshDeformer.h === --- branches/apricot/source/gameengine/Converter/BL_MeshDeformer.h 2008-08-18 10:24:56 UTC (rev 16164) +++ branches/apricot/source/gameengine/Converter/BL_MeshDeformer.h 2008-08-18 10:27:48 UTC (rev 16165) @@ -47,7 +47,7 @@ public: void VerifyStorage(); void RecalcNormals(); - virtual void Relink(GEN_Mapclass GEN_HashedPtr, void**map){}; + virtual void Relink(GEN_Mapclass GEN_HashedPtr, void**map); BL_MeshDeformer(BL_DeformableGameObject *gameobj, struct Object* obj, class BL_SkinMeshObject *meshobj ): @@ -67,6 +67,7 @@ virtual RAS_Deformer* GetReplica(){return NULL;}; struct Mesh* GetMesh() { return m_bmesh; }; // virtual void InitDeform(double time){}; + protected: class BL_SkinMeshObject*m_pMeshObject; struct Mesh*m_bmesh; Modified: branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.h === --- branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.h 2008-08-18 10:24:56 UTC (rev 16164) +++ branches/apricot/source/gameengine/Converter/BL_ShapeDeformer.h 2008-08-18 10:27:48 UTC (rev 16165) @@ -43,17 +43,6 @@ class BL_ShapeDeformer : public BL_SkinDeformer { public: - virtual void Relink(GEN_Mapclass GEN_HashedPtr, void**map) - { - void **h_obj = (*map)[m_gameobj]; - if (h_obj){ - m_gameobj = (BL_DeformableGameObject*)(*h_obj); - } - else - m_gameobj=NULL; - // relink the underlying skin deformer - BL_SkinDeformer::Relink(map); - }; BL_ShapeDeformer(BL_DeformableGameObject *gameobj, Object *bmeshobj, BL_SkinMeshObject *mesh) Modified: branches/apricot/source/gameengine/Converter/BL_SkinDeformer.cpp === ---
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16170] branches/apricot: Apricot Branch
Revision: 16170 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16170 Author: blendix Date: 2008-08-18 14:09:33 +0200 (Mon, 18 Aug 2008) Log Message: --- Apricot Branch == svn merge -r16142:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender Modified Paths: -- branches/apricot/intern/guardedalloc/MEM_guardedalloc.h branches/apricot/intern/guardedalloc/intern/mallocn.c branches/apricot/intern/guardedalloc/intern/mmap_win.c branches/apricot/intern/guardedalloc/make/msvc_7_0/guardedalloc.vcproj branches/apricot/intern/guardedalloc/mmap_win.h branches/apricot/intern/opennl/make/msvc_7_0/opennl.vcproj branches/apricot/intern/opennl/superlu/smemory.c branches/apricot/projectfiles_vc7/kernel/system/SYS_system.vcproj branches/apricot/release/datafiles/datatoc.c branches/apricot/source/blender/blenkernel/BKE_customdata.h branches/apricot/source/blender/blenkernel/BKE_effect.h branches/apricot/source/blender/blenkernel/BKE_endian.h branches/apricot/source/blender/blenkernel/BKE_utildefines.h branches/apricot/source/blender/blenkernel/intern/CCGSubSurf.c branches/apricot/source/blender/blenkernel/intern/DerivedMesh.c branches/apricot/source/blender/blenkernel/intern/cloth.c branches/apricot/source/blender/blenkernel/intern/displist.c branches/apricot/source/blender/blenkernel/intern/effect.c branches/apricot/source/blender/blenkernel/intern/icons.c branches/apricot/source/blender/blenkernel/intern/image.c branches/apricot/source/blender/blenkernel/intern/implicit.c branches/apricot/source/blender/blenkernel/intern/particle_system.c branches/apricot/source/blender/blenlib/BLI_editVert.h branches/apricot/source/blender/blenlib/BLI_rand.h branches/apricot/source/blender/blenlib/intern/BLI_ghash.c branches/apricot/source/blender/blenlib/intern/BLI_kdopbvh.c branches/apricot/source/blender/blenlib/intern/fileops.c branches/apricot/source/blender/blenlib/intern/psfont.c branches/apricot/source/blender/blenlib/intern/rand.c branches/apricot/source/blender/blenlib/intern/util.c branches/apricot/source/blender/blenloader/BLO_sys_types.h branches/apricot/source/blender/blenloader/intern/genfile.c branches/apricot/source/blender/blenloader/intern/readblenentry.c branches/apricot/source/blender/blenloader/intern/readfile.c branches/apricot/source/blender/blenpluginapi/intern/pluginapi.c branches/apricot/source/blender/imbuf/intern/cineon/cineonlib.c branches/apricot/source/blender/imbuf/intern/cineon/dpxlib.c branches/apricot/source/blender/imbuf/intern/cineon/logImageCore.h branches/apricot/source/blender/imbuf/intern/cineon/logmemfile.c branches/apricot/source/blender/imbuf/intern/cineon/logmemfile.h branches/apricot/source/blender/imbuf/intern/scaling.c branches/apricot/source/blender/include/BIF_meshtools.h branches/apricot/source/blender/makesdna/DNA_object_force.h branches/apricot/source/blender/makesdna/intern/makesdna.c branches/apricot/source/blender/python/api2_2x/Draw.c branches/apricot/source/blender/python/api2_2x/doc/Mathutils.py branches/apricot/source/blender/python/api2_2x/vector.c branches/apricot/source/blender/python/api2_2x/vector.h branches/apricot/source/blender/radiosity/CMakeLists.txt branches/apricot/source/blender/radiosity/SConscript branches/apricot/source/blender/radiosity/intern/source/Makefile branches/apricot/source/blender/radiosity/intern/source/radnode.c branches/apricot/source/blender/radiosity/intern/source/radpreprocess.c branches/apricot/source/blender/render/CMakeLists.txt branches/apricot/source/blender/render/SConscript branches/apricot/source/blender/render/intern/include/render_types.h branches/apricot/source/blender/render/intern/source/occlusion.c branches/apricot/source/blender/render/intern/source/pipeline.c branches/apricot/source/blender/render/intern/source/rendercore.c branches/apricot/source/blender/render/intern/source/shadbuf.c branches/apricot/source/blender/render/intern/source/strand.c branches/apricot/source/blender/render/intern/source/zbuf.c branches/apricot/source/blender/src/buttons_editing.c branches/apricot/source/blender/src/buttons_logic.c branches/apricot/source/blender/src/buttons_object.c branches/apricot/source/blender/src/buttons_scene.c branches/apricot/source/blender/src/drawmesh.c branches/apricot/source/blender/src/drawobject.c branches/apricot/source/blender/src/editkey.c branches/apricot/source/blender/src/editmesh_mods.c branches/apricot/source/blender/src/editmesh_tools.c branches/apricot/source/blender/src/header_info.c branches/apricot/source/blender/src/header_script.c branches/apricot/source/blender/src/interface.c
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16173] branches/apricot/source/blender/ src/previewrender.c: Apricot Branch: fix some missing updates for GLSL materials
Revision: 16173 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16173 Author: blendix Date: 2008-08-18 15:25:27 +0200 (Mon, 18 Aug 2008) Log Message: --- Apricot Branch: fix some missing updates for GLSL materials when changing world settings. Thanks Pablo for the patch, though I implemented it a bit differently. Modified Paths: -- branches/apricot/source/blender/src/previewrender.c Modified: branches/apricot/source/blender/src/previewrender.c === --- branches/apricot/source/blender/src/previewrender.c 2008-08-18 13:06:33 UTC (rev 16172) +++ branches/apricot/source/blender/src/previewrender.c 2008-08-18 13:25:27 UTC (rev 16173) @@ -224,11 +224,20 @@ } } - if(ELEM3(id_code, ID_MA, ID_TE, ID_LA)) { + if(ELEM4(id_code, ID_MA, ID_TE, ID_LA, ID_WO)) { Object *ob; Material *ma; - if(id_code == ID_LA) { + if(id_code == ID_WO) { + for(ma=G.main-mat.first; ma; ma=ma-id.next) { + if(ma-gpumaterial) { + GPU_material_free(ma-gpumaterial); + ma-gpumaterial= NULL; + allqueue(REDRAWVIEW3D, 0); + } + } + } + else if(id_code == ID_LA) { for(ob=G.main-object.first; ob; ob=ob-id.next) { if(ob-gpulamp) { GPU_lamp_free(ob-gpulamp); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16195] branches/apricot/source: Apricot Branch
Revision: 16195 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16195 Author: blendix Date: 2008-08-20 18:29:55 +0200 (Wed, 20 Aug 2008) Log Message: --- Apricot Branch == * Make lights and shadows work better with dupligroups, also in the game engine. Previously only one dupli would be created, and shadows didn't work well at all. * Make normal maps + stencil work. * Some glsl refresh and default material fixes. Modified Paths: -- branches/apricot/source/blender/blenkernel/intern/material.c branches/apricot/source/blender/blenkernel/intern/object.c branches/apricot/source/blender/blenloader/intern/readfile.c branches/apricot/source/blender/gpu/GPU_material.h branches/apricot/source/blender/gpu/intern/gpu_codegen.c branches/apricot/source/blender/gpu/intern/gpu_draw.c branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/makesdna/DNA_object_types.h branches/apricot/source/blender/src/drawscene.c branches/apricot/source/blender/src/drawview.c branches/apricot/source/blender/src/previewrender.c branches/apricot/source/gameengine/Converter/BL_BlenderDataConversion.cpp branches/apricot/source/gameengine/Ketsji/KX_GameObject.cpp branches/apricot/source/gameengine/Ketsji/KX_GameObject.h branches/apricot/source/gameengine/Ketsji/KX_KetsjiEngine.cpp branches/apricot/source/gameengine/Ketsji/KX_Light.cpp branches/apricot/source/gameengine/Ketsji/KX_Light.h branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp Modified: branches/apricot/source/blender/blenkernel/intern/material.c === --- branches/apricot/source/blender/blenkernel/intern/material.c 2008-08-20 06:11:11 UTC (rev 16194) +++ branches/apricot/source/blender/blenkernel/intern/material.c 2008-08-20 16:29:55 UTC (rev 16195) @@ -100,7 +100,7 @@ } if(ma-gpumaterial) - GPU_material_free(ma-gpumaterial); + GPU_material_free(ma); } void init_material(Material *ma) Modified: branches/apricot/source/blender/blenkernel/intern/object.c === --- branches/apricot/source/blender/blenkernel/intern/object.c 2008-08-20 06:11:11 UTC (rev 16194) +++ branches/apricot/source/blender/blenkernel/intern/object.c 2008-08-20 16:29:55 UTC (rev 16195) @@ -270,7 +270,7 @@ } if(ob-soft) sbFree(ob-soft); if(ob-fluidsimSettings) fluidsimSettingsFree(ob-fluidsimSettings); - if(ob-gpulamp) GPU_lamp_free(ob-gpulamp); + if(ob-gpulamp.first) GPU_lamp_free(ob); } static void unlink_object__unlinkModifierLinks(void *userData, Object *ob, Object **obpoin) @@ -1229,7 +1229,7 @@ obn-vnode = NULL; #endif - obn-gpulamp = NULL; + obn-gpulamp.first = obn-gpulamp.last = NULL; return obn; } Modified: branches/apricot/source/blender/blenloader/intern/readfile.c === --- branches/apricot/source/blender/blenloader/intern/readfile.c 2008-08-20 06:11:11 UTC (rev 16194) +++ branches/apricot/source/blender/blenloader/intern/readfile.c 2008-08-20 16:29:55 UTC (rev 16195) @@ -3400,7 +3400,7 @@ ob-bb= NULL; ob-derivedDeform= NULL; ob-derivedFinal= NULL; - ob-gpulamp= NULL; + ob-gpulamp.first= ob-gpulamp.last= NULL; } /* READ SCENE * */ Modified: branches/apricot/source/blender/gpu/GPU_material.h === --- branches/apricot/source/blender/gpu/GPU_material.h 2008-08-20 06:11:11 UTC (rev 16194) +++ branches/apricot/source/blender/gpu/GPU_material.h 2008-08-20 16:29:55 UTC (rev 16195) @@ -120,7 +120,7 @@ /* High level functions to create and use GPU materials */ int GPU_material_from_blender(struct Scene *scene, struct Material *ma); -void GPU_material_free(GPUMaterial *material); +void GPU_material_free(struct Material *ma); void GPU_materials_free(); @@ -151,8 +151,8 @@ /* Lamps */ -int GPU_lamp_from_blender(struct Object *ob, struct Lamp *la); -void GPU_lamp_free(GPULamp *lamp); +GPULamp *GPU_lamp_from_blender(struct Object *ob, struct Object *par); +void GPU_lamp_free(struct Object *ob); int GPU_lamp_has_shadow_buffer(GPULamp *lamp); void GPU_lamp_shadow_buffer_bind(GPULamp *lamp, float viewmat[][4], int *winsize, float winmat[][4]); Modified: branches/apricot/source/blender/gpu/intern/gpu_codegen.c === --- branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-08-20 06:11:11 UTC (rev 16194) +++ branches/apricot/source/blender/gpu/intern/gpu_codegen.c2008-08-20 16:29:55 UTC (rev 16195) @@ -362,10 +362,8 @@ { extern Material
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16202] branches/apricot/source/gameengine :
Revision: 16202 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16202 Author: blendix Date: 2008-08-21 15:40:40 +0200 (Thu, 21 Aug 2008) Log Message: --- Apricot Branch: fix for bug #17435, only first 3 texture slots were being used for finding second uv coordinate layer. Modified Paths: -- branches/apricot/source/gameengine/Ketsji/BL_Material.h branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h branches/apricot/source/gameengine/Rasterizer/RAS_TexVert.h Modified: branches/apricot/source/gameengine/Ketsji/BL_Material.h === --- branches/apricot/source/gameengine/Ketsji/BL_Material.h 2008-08-21 07:59:18 UTC (rev 16201) +++ branches/apricot/source/gameengine/Ketsji/BL_Material.h 2008-08-21 13:40:40 UTC (rev 16202) @@ -18,9 +18,9 @@ this will default to users available units to build with more available, just increment this value although the more you add the slower the search time will be. - we will go for three, which should be enough + we will go for eight, which should be enough */ -#define MAXTEX 3 //match in RAS_TexVert RAS_OpenGLRasterizer +#define MAXTEX 8 //match in RAS_TexVert RAS_OpenGLRasterizer // different mapping modes class BL_Mapping Modified: branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h === --- branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h 2008-08-21 07:59:18 UTC (rev 16201) +++ branches/apricot/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h 2008-08-21 13:40:40 UTC (rev 16202) @@ -41,7 +41,7 @@ #include RAS_MaterialBucket.h #include RAS_ICanvas.h -#define RAS_MAX_TEXCO 3 // match in BL_Material +#define RAS_MAX_TEXCO 8 // match in BL_Material #define RAS_MAX_ATTRIB 16 // match in BL_BlenderShader struct OglDebugLine Modified: branches/apricot/source/gameengine/Rasterizer/RAS_TexVert.h === --- branches/apricot/source/gameengine/Rasterizer/RAS_TexVert.h 2008-08-21 07:59:18 UTC (rev 16201) +++ branches/apricot/source/gameengine/Rasterizer/RAS_TexVert.h 2008-08-21 13:40:40 UTC (rev 16202) @@ -57,7 +57,7 @@ enum { FLAT = 1, SECOND_UV = 2, - MAX_UNIT = 3 + MAX_UNIT = 8 }; short getFlag() const; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16227] branches/apricot: Apricot Branch: svn merge -r 16194:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/ blender
Revision: 16227 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16227 Author: blendix Date: 2008-08-22 13:51:56 +0200 (Fri, 22 Aug 2008) Log Message: --- Apricot Branch: svn merge -r 16194:HEAD https://svn.blender.org/svnroot/bf-blender/trunk/blender Modified Paths: -- branches/apricot/extern/bullet2/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorld.cpp branches/apricot/projectfiles_vc7/gameengine/physics/PHY_Physics/PHY_Bullet/PHY_Bullet.vcproj branches/apricot/release/scripts/flt_properties.py branches/apricot/source/blender/blenkernel/BKE_deform.h branches/apricot/source/blender/blenkernel/BKE_effect.h branches/apricot/source/blender/blenkernel/intern/bvhutils.c branches/apricot/source/blender/blenkernel/intern/deform.c branches/apricot/source/blender/blenkernel/intern/effect.c branches/apricot/source/blender/blenkernel/intern/ipo.c branches/apricot/source/blender/blenkernel/intern/modifier.c branches/apricot/source/blender/blenkernel/intern/particle.c branches/apricot/source/blender/blenkernel/intern/particle_system.c branches/apricot/source/blender/blenlib/intern/BLI_kdopbvh.c branches/apricot/source/blender/blenloader/intern/readfile.c branches/apricot/source/blender/blenloader/intern/writefile.c branches/apricot/source/blender/include/BDR_gpencil.h branches/apricot/source/blender/include/BIF_drawgpencil.h branches/apricot/source/blender/makesdna/DNA_gpencil_types.h branches/apricot/source/blender/makesdna/DNA_ipo_types.h branches/apricot/source/blender/makesdna/DNA_modifier_types.h branches/apricot/source/blender/makesdna/DNA_object_force.h branches/apricot/source/blender/makesdna/DNA_particle_types.h branches/apricot/source/blender/makesdna/DNA_space_types.h branches/apricot/source/blender/python/api2_2x/Mesh.c branches/apricot/source/blender/python/api2_2x/Object.c branches/apricot/source/blender/python/api2_2x/doc/Object.py branches/apricot/source/blender/src/buttons_editing.c branches/apricot/source/blender/src/buttons_object.c branches/apricot/source/blender/src/drawgpencil.c branches/apricot/source/blender/src/editipo.c branches/apricot/source/blender/src/editipo_lib.c branches/apricot/source/blender/src/gpencil.c branches/apricot/source/gameengine/Converter/KX_ConvertActuators.cpp branches/apricot/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp branches/apricot/source/gameengine/Ketsji/KX_PythonInit.cpp branches/apricot/source/gameengine/Ketsji/KX_Scene.cpp branches/apricot/source/gameengine/Ketsji/KX_Scene.h branches/apricot/source/gameengine/Physics/Bullet/CMakeLists.txt branches/apricot/source/gameengine/Physics/Bullet/CcdPhysicsController.cpp branches/apricot/source/gameengine/Physics/Bullet/CcdPhysicsController.h branches/apricot/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp branches/apricot/source/gameengine/Physics/Bullet/SConscript branches/apricot/source/gameengine/Physics/common/PHY_DynamicTypes.h branches/apricot/source/gameengine/PyDoc/GameLogic.py Added Paths: --- branches/apricot/release/scripts/flt_dofedit.py branches/apricot/release/scripts/flt_lodedit.py branches/apricot/source/blender/blenkernel/BKE_shrinkwrap.h branches/apricot/source/blender/blenkernel/intern/shrinkwrap.c Modified: branches/apricot/extern/bullet2/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorld.cpp === --- branches/apricot/extern/bullet2/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorld.cpp 2008-08-22 11:46:59 UTC (rev 16226) +++ branches/apricot/extern/bullet2/src/BulletDynamics/Dynamics/btDiscreteDynamicsWorld.cpp 2008-08-22 11:51:56 UTC (rev 16227) @@ -856,10 +856,26 @@ btScalar radius = coneShape-getRadius();//+coneShape-getMargin(); btScalar height = coneShape-getHeight();//+coneShape-getMargin(); btVector3 start = worldTransform.getOrigin(); - getDebugDrawer()-drawLine(start+worldTransform.getBasis() * btVector3(btScalar(0.),btScalar(0.),btScalar(0.5)*height),start+worldTransform.getBasis() * btVector3(radius,btScalar(0.),btScalar(-0.5)*height),color); - getDebugDrawer()-drawLine(start+worldTransform.getBasis() * btVector3(btScalar(0.),btScalar(0.),btScalar(0.5)*height),start+worldTransform.getBasis() * btVector3(-radius,btScalar(0.),btScalar(-0.5)*height),color); - getDebugDrawer()-drawLine(start+worldTransform.getBasis() * btVector3(btScalar(0.),btScalar(0.),btScalar(0.5)*height),start+worldTransform.getBasis() * btVector3(btScalar(0.),radius,btScalar(-0.5)*height),color); -
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16258] branches/apricot/source/gameengine /Ketsji/KX_Light.cpp: Apricot Branch: bugfix, crash in lights switching blender files,
Revision: 16258 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16258 Author: blendix Date: 2008-08-26 14:38:05 +0200 (Tue, 26 Aug 2008) Log Message: --- Apricot Branch: bugfix, crash in lights switching blender files, accidentally removed a line of code that should have been kept. Modified Paths: -- branches/apricot/source/gameengine/Ketsji/KX_Light.cpp Modified: branches/apricot/source/gameengine/Ketsji/KX_Light.cpp === --- branches/apricot/source/gameengine/Ketsji/KX_Light.cpp 2008-08-26 04:28:18 UTC (rev 16257) +++ branches/apricot/source/gameengine/Ketsji/KX_Light.cpp 2008-08-26 12:38:05 UTC (rev 16258) @@ -64,6 +64,7 @@ KX_LightObject::~KX_LightObject() { + m_rendertools-RemoveLight(m_lightobj); } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16262] branches/apricot/source: Apricot Branch: fix for a change I made to avoid doing where_is_pose
Revision: 16262 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16262 Author: blendix Date: 2008-08-26 19:38:39 +0200 (Tue, 26 Aug 2008) Log Message: --- Apricot Branch: fix for a change I made to avoid doing where_is_pose too often, didn't work correct for multiple objects sharing the same armature. Modified Paths: -- branches/apricot/source/blender/blenkernel/intern/action.c branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp branches/apricot/source/gameengine/Converter/BL_ArmatureObject.h branches/apricot/source/gameengine/Converter/BL_SkinDeformer.cpp branches/apricot/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp Modified: branches/apricot/source/blender/blenkernel/intern/action.c === --- branches/apricot/source/blender/blenkernel/intern/action.c 2008-08-26 17:09:17 UTC (rev 16261) +++ branches/apricot/source/blender/blenkernel/intern/action.c 2008-08-26 17:38:39 UTC (rev 16262) @@ -347,6 +347,7 @@ VECCOPY(pchan-loc, chan-loc); VECCOPY(pchan-size, chan-size); QUATCOPY(pchan-quat, chan-quat); + Mat4CpyMat4(pchan-chan_mat, (float(*)[4])chan-chan_mat); pchan-flag= chan-flag; con= chan-constraints.first; Modified: branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp === --- branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp 2008-08-26 17:09:17 UTC (rev 16261) +++ branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp 2008-08-26 17:38:39 UTC (rev 16262) @@ -53,18 +53,19 @@ : KX_GameObject(sgReplicationInfo,callbacks), m_objArma(armature), - m_mrdPose(NULL), m_lastframe(0.0), m_activeAct(NULL), m_activePriority(999), - m_lastapplyframe(0.0), - m_lastapplypose(NULL) + m_lastapplyframe(0.0) { m_armature = get_armature(m_objArma); - m_pose = m_objArma-pose; + + /* we make a copy of blender object's pose, and then always swap it with +* the original pose before calling into blender functions, to deal with +* replica's or other objects using the same blender object */ + copy_pose(m_pose, m_objArma-pose, 1 /* copy_constraint_channels_hack */); } - CValue* BL_ArmatureObject::GetReplica() { BL_ArmatureObject* replica = new BL_ArmatureObject(*this); @@ -80,42 +81,39 @@ { KX_GameObject::ProcessReplica(replica); + replica-m_pose = NULL; + copy_pose(replica-m_pose, m_pose, 1 /* copy_constraint_channels_hack */); } BL_ArmatureObject::~BL_ArmatureObject() { - if (m_mrdPose) - free_pose(m_mrdPose); + if (m_pose) + free_pose(m_pose); } -/* note, you can only call this for exisiting Armature objects, and not mix it with other Armatures */ -/* there is only 1 unique Pose per Armature */ -void BL_ArmatureObject::ApplyPose() +bool BL_ArmatureObject::VerifyPose() { - if(m_lastapplyframe == m_lastframe m_lastapplypose == m_pose) - return; - - if (m_pose) { - // copy to armature object - if (m_objArma-pose != m_pose)/* This should never happen but it does - Campbell */ - extract_pose_from_pose(m_objArma-pose, m_pose); - - // is this needed anymore? - //if (!m_mrdPose) - // copy_pose (m_mrdPose, m_pose, 0); - //else - // extract_pose_from_pose(m_mrdPose, m_pose); - + if(m_lastapplyframe != m_lastframe) { + extract_pose_from_pose(m_objArma-pose, m_pose); where_is_pose(m_objArma); - m_lastapplyframe = m_lastframe; - m_lastapplypose = m_pose; + extract_pose_from_pose(m_pose, m_objArma-pose); + return false; } + else + return true; } +void BL_ArmatureObject::ApplyPose() +{ + if(VerifyPose()) + extract_pose_from_pose(m_objArma-pose, m_pose); +} + void BL_ArmatureObject::SetPose(bPose *pose) { - m_pose = pose; + extract_pose_from_pose(m_pose, pose); + m_lastapplyframe = -1.0; } bool BL_ArmatureObject::SetActiveAction(BL_ActionActuator *act, short priority, double curtime) @@ -176,20 +174,16 @@ /* If the caller supplies a null pose, create a new one. */ /* Otherwise, copy the armature's pose channels into the caller-supplied pose */ - // is this needed anymore? - //if (!m_mrdPose){ - // copy_pose (m_mrdPose, m_pose, 0); - //} - if (!*pose) { // must duplicate the constraints too otherwise we have corruption in free_pose_channels() // because it will free the blender
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16263] branches/apricot/source/blender/ gpu/intern/gpu_material.c: Apricot Branch: apply glsl object color before mist, makes more sense.
Revision: 16263 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16263 Author: blendix Date: 2008-08-26 19:53:04 +0200 (Tue, 26 Aug 2008) Log Message: --- Apricot Branch: apply glsl object color before mist, makes more sense. Modified Paths: -- branches/apricot/source/blender/gpu/intern/gpu_material.c Modified: branches/apricot/source/blender/gpu/intern/gpu_material.c === --- branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-08-26 17:38:39 UTC (rev 16262) +++ branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-08-26 17:53:04 UTC (rev 16263) @@ -1161,6 +1161,11 @@ GPU_link(mat, shade_add, shr-combined, shr-spec, shr-combined); } + if(ma-shade_flag MA_OBCOLOR) { + mat-obcolalpha = 1; + GPU_link(mat, shade_obcolor, shr-combined, GPU_builtin(GPU_OBCOLOR), shr-combined); + } + if(world (world-mode WO_MIST) !(ma-mode MA_NOMIST)) { misttype = world-mistype; @@ -1181,11 +1186,6 @@ } GPU_link(mat, mtex_alpha_to_col, shr-combined, shr-alpha, shr-combined); - - if(ma-shade_flag MA_OBCOLOR) { - mat-obcolalpha = 1; - GPU_link(mat, shade_obcolor, shr-combined, GPU_builtin(GPU_OBCOLOR), shr-combined); - } } GPUNodeLink *GPU_blender_material(GPUMaterial *mat, Material *ma) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16269] branches/apricot/source/blender/ gpu/intern: Apricot Branch: still didn't get the glsl obcolor mixing right,
Revision: 16269 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16269 Author: blendix Date: 2008-08-27 13:56:11 +0200 (Wed, 27 Aug 2008) Log Message: --- Apricot Branch: still didn't get the glsl obcolor mixing right, forgot why I did it the other way around before (because of alpha), should work correct now. Also, noticed I committed a bugfix before without knowing related to creating material buckets with 65k faces. The fix was provided by Samuel Anjam, thanks! Modified Paths: -- branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c Modified: branches/apricot/source/blender/gpu/intern/gpu_material.c === --- branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-08-27 07:12:07 UTC (rev 16268) +++ branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-08-27 11:56:11 UTC (rev 16269) @@ -1096,7 +1096,7 @@ GPUNodeLink *emit, *ulinfac, *ulogfac, *mistfac; Material *ma= shi-mat; World *world= mat-scene-world; - float linfac, logfac, misttype, one = 1.0f; + float linfac, logfac, misttype; memset(shr, 0, sizeof(*shr)); @@ -1161,10 +1161,10 @@ GPU_link(mat, shade_add, shr-combined, shr-spec, shr-combined); } - if(ma-shade_flag MA_OBCOLOR) { - mat-obcolalpha = 1; + GPU_link(mat, mtex_alpha_to_col, shr-combined, shr-alpha, shr-combined); + + if(ma-shade_flag MA_OBCOLOR) GPU_link(mat, shade_obcolor, shr-combined, GPU_builtin(GPU_OBCOLOR), shr-combined); - } if(world (world-mode WO_MIST) !(ma-mode MA_NOMIST)) { misttype = world-mistype; @@ -1179,13 +1179,16 @@ if(!(ma-mode MA_ZTRA)) { if(world (GPU_link_changed(shr-alpha) || ma-alpha != 1.0f)) - GPU_link(mat, shade_world_mix, shr-alpha, GPU_uniform(world-horr), + GPU_link(mat, shade_world_mix, GPU_uniform(world-horr), shr-combined, shr-combined); - GPU_link(mat, set_value, GPU_uniform(one), shr-alpha); + GPU_link(mat, shade_alpha_opaque, shr-combined, shr-combined); } - GPU_link(mat, mtex_alpha_to_col, shr-combined, shr-alpha, shr-combined); + if(ma-shade_flag MA_OBCOLOR) { + mat-obcolalpha = 1; + GPU_link(mat, shade_alpha_obcolor, shr-combined, GPU_builtin(GPU_OBCOLOR), shr-combined); + } } GPUNodeLink *GPU_blender_material(GPUMaterial *mat, Material *ma) Modified: branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl === --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl 2008-08-27 07:12:07 UTC (rev 16268) +++ branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl 2008-08-27 11:56:11 UTC (rev 16269) @@ -1475,7 +1475,7 @@ void shade_obcolor(vec4 col, vec4 obcol, out vec4 outcol) { - outcol = col*obcol; + outcol = vec4(col.rgb*obcol.rgb, col.a); } void ramp_rgbtobw(vec3 color, out float outval) @@ -1525,9 +1525,19 @@ outfac = (1.0-fac)*(1.0-misi); } -void shade_world_mix(float fac, vec3 hor, vec4 col, out vec4 outcol) +void shade_world_mix(vec3 hor, vec4 col, out vec4 outcol) { - fac = clamp(fac, 0.0, 1.0); + float fac = clamp(col.a, 0.0, 1.0); outcol = vec4(mix(hor, col.rgb, fac), col.a); } +void shade_alpha_opaque(vec4 col, out vec4 outcol) +{ + outcol = vec4(col.rgb, 1.0); +} + +void shade_alpha_obcolor(vec4 col, vec4 obcol, out vec4 outcol) +{ + outcol = vec4(col.rgb, col.a*obcol.a); +} + Modified: branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c === --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c 2008-08-27 07:12:07 UTC (rev 16268) +++ branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c 2008-08-27 11:56:11 UTC (rev 16269) @@ -1,979 +1,979 @@ /* DataToC output of file gpu_shader_material_glsl */ -int datatoc_gpu_shader_material_glsl_size= 32419; +int datatoc_gpu_shader_material_glsl_size= 32632; char datatoc_gpu_shader_material_glsl[]= { - 10,102,108, -111, 97,116, 32,101,120,112, 95, 98,108,101,110,100,101,114, 40,102,108,111, 97,116, 32,102, 41, 10,123, 10, 9,114,101,116,117, -114,110, 32,112,111,119, 40, 50, 46, 55, 49, 56, 50, 56, 49, 56, 50, 56, 52, 54, 44, 32,102, 41, 59, 10,125, 10, 10,118,111,105, -100, 32,114,103, 98, 95,116,111, 95,104,115,118, 40,118,101, 99, 52, 32,114,103, 98, 44, 32,111,117,116, 32,118,101, 99, 52, 32, -111,117,116,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16271] branches/apricot/source/gameengine /Converter/BL_ArmatureObject.cpp: Apricot Branch: bugfix, broke bone parenting with yesterday's commit.
Revision: 16271 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16271 Author: blendix Date: 2008-08-27 15:10:16 +0200 (Wed, 27 Aug 2008) Log Message: --- Apricot Branch: bugfix, broke bone parenting with yesterday's commit. Modified Paths: -- branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp Modified: branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp === --- branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp 2008-08-27 13:02:44 UTC (rev 16270) +++ branches/apricot/source/gameengine/Converter/BL_ArmatureObject.cpp 2008-08-27 13:10:16 UTC (rev 16271) @@ -201,8 +201,8 @@ { bPoseChannel *pchan; - VerifyPose(); - pchan = get_pose_channel(m_pose, bone-name); + ApplyPose(); + pchan = get_pose_channel(m_objArma-pose, bone-name); if(pchan) { matrix.setValue(pchan-pose_mat[0][0]); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [16272] branches/apricot/source/blender/ gpu/intern: Apricot Branch: another fix for obcolor alpha - i can't seem
Revision: 16272 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=16272 Author: blendix Date: 2008-08-27 16:18:52 +0200 (Wed, 27 Aug 2008) Log Message: --- Apricot Branch: another fix for obcolor alpha - i can't seem to get this right :). Modified Paths: -- branches/apricot/source/blender/gpu/intern/gpu_material.c branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c Modified: branches/apricot/source/blender/gpu/intern/gpu_material.c === --- branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-08-27 13:10:16 UTC (rev 16271) +++ branches/apricot/source/blender/gpu/intern/gpu_material.c 2008-08-27 14:18:52 UTC (rev 16272) @@ -1173,8 +1173,8 @@ GPU_uniform(world-miststa), GPU_uniform(world-mistdist), GPU_uniform(misttype), GPU_uniform(world-misi), mistfac); - GPU_link(mat, mix_blend, mistfac, GPU_uniform(world-horr), - shr-combined, shr-combined); + GPU_link(mat, mix_blend, mistfac, shr-combined, + GPU_uniform(world-horr), shr-combined); } if(!(ma-mode MA_ZTRA)) { Modified: branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl === --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl 2008-08-27 13:10:16 UTC (rev 16271) +++ branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl 2008-08-27 14:18:52 UTC (rev 16272) @@ -1522,7 +1522,7 @@ else if(misttype == 1.0); else fac = sqrt(fac); - outfac = (1.0-fac)*(1.0-misi); + outfac = 1.0 - (1.0-fac)*(1.0-misi); } void shade_world_mix(vec3 hor, vec4 col, out vec4 outcol) Modified: branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c === --- branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c 2008-08-27 13:10:16 UTC (rev 16271) +++ branches/apricot/source/blender/gpu/intern/gpu_shader_material.glsl.c 2008-08-27 14:18:52 UTC (rev 16272) @@ -1,1016 +1,1016 @@ /* DataToC output of file gpu_shader_material_glsl */ -int datatoc_gpu_shader_material_glsl_size= 32632; +int datatoc_gpu_shader_material_glsl_size= 32638; char datatoc_gpu_shader_material_glsl[]= { - 10,102,108,111, 97,116, 32,101,120,112, 95, 98,108,101,110,100,101,114, 40,102,108,111, 97,116, - 32,102, 41, 10,123, 10, 9,114,101,116,117,114,110, 32,112,111,119, 40, 50, 46, 55, 49, 56, 50, 56, 49, 56, 50, 56, 52, 54, 44, - 32,102, 41, 59, 10,125, 10, 10,118,111,105,100, 32,114,103, 98, 95,116,111, 95,104,115,118, 40,118,101, 99, 52, 32,114,103, 98, - 44, 32,111,117,116, 32,118,101, 99, 52, 32,111,117,116, 99,111,108, 41, 10,123, 10, 9,102,108,111, 97,116, 32, 99,109, 97,120, - 44, 32, 99,109,105,110, 44, 32,104, 44, 32,115, 44, 32,118, 44, 32, 99,100,101,108,116, 97, 59, 10, 9,118,101, 99, 51, 32, 99, - 59, 10, 10, 9, 99,109, 97,120, 32, 61, 32,109, 97,120, 40,114,103, 98, 91, 48, 93, 44, 32,109, 97,120, 40,114,103, 98, 91, 49, - 93, 44, 32,114,103, 98, 91, 50, 93, 41, 41, 59, 10, 9, 99,109,105,110, 32, 61, 32,109,105,110, 40,114,103, 98, 91, 48, 93, 44, - 32,109,105,110, 40,114,103, 98, 91, 49, 93, 44, 32,114,103, 98, 91, 50, 93, 41, 41, 59, 10, 9, 99,100,101,108,116, 97, 32, 61, - 32, 99,109, 97,120, 45, 99,109,105,110, 59, 10, 10, 9,118, 32, 61, 32, 99,109, 97,120, 59, 10, 9,105,102, 32, 40, 99,109, 97, -120, 33, 61, 48, 46, 48, 41, 10, 9, 9,115, 32, 61, 32, 99,100,101,108,116, 97, 47, 99,109, 97,120, 59, 10, 9,101,108,115,101, - 32,123, 10, 9, 9,115, 32, 61, 32, 48, 46, 48, 59, 10, 9, 9,104, 32, 61, 32, 48, 46, 48, 59, 10, 9,125, 10, 10, 9,105,102, - 32, 40,115, 32, 61, 61, 32, 48, 46, 48, 41, 32,123, 10, 9, 9,104, 32, 61, 32, 48, 46, 48, 59, 10, 9,125, 10, 9,101,108,115, -101, 32,123, 10, 9, 9, 99, 32, 61, 32, 40,118,101, 99, 51, 40, 99,109, 97,120, 44, 32, 99,109, 97,120, 44, 32, 99,109, 97,120, - 41, 32, 45, 32,114,103, 98, 46,120,121,122, 41, 47, 99,100,101,108,116, 97, 59, 10, 10, 9, 9,105,102, 32, 40,114,103, 98, 46, -120, 61, 61, 99,109, 97,120, 41, 32,104, 32, 61, 32, 99, 91, 50, 93, 32, 45, 32, 99, 91, 49, 93, 59, 10, 9, 9,101,108,115,101, - 32,105,102, 32, 40,114,103, 98, 46,121, 61, 61, 99,109, 97,120, 41, 32,104, 32, 61, 32, 50, 46, 48, 32, 43, 32, 99, 91, 48, 93, - 32, 45, 32, 32, 99, 91, 50, 93, 59, 10, 9, 9,101,108,115,101, 32,104, 32, 61, 32, 52, 46, 48, 32, 43, 32, 99, 91, 49, 93, 32, - 45, 32, 99, 91, 48, 93, 59, 10, 10, 9, 9,104, 32, 47, 61, 32, 54, 46, 48, 59, 10, 10, 9, 9,105,102, 32, 40,104, 60, 48, 46, - 48, 41, 10, 9, 9, 9,104, 32, 43, 61, 32, 49, 46, 48, 59, 10, 9,125, 10, 10,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18295] branches/blender2.5/blender/source /blender: 2.5: fix repeat last, and display of operator properties
Revision: 18295 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18295 Author: blendix Date: 2009-01-03 21:03:39 +0100 (Sat, 03 Jan 2009) Log Message: --- 2.5: fix repeat last, and display of operator properties in rna outliner. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_modifier.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c Modified: branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c === --- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-01-03 19:39:39 UTC (rev 18294) +++ branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-01-03 20:03:39 UTC (rev 18295) @@ -4184,6 +4184,7 @@ if(nameprop) { text= RNA_property_string_get_alloc(pptr, nameprop, textbuf, sizeof(textbuf)); + descr= (char*)RNA_property_ui_description(pptr, prop); but= uiDefIconTextBut(block, LABEL, 0, icon, text, x1, y1, x2, y2, NULL, 0, 0, 0, 0, descr); if(text != textbuf) MEM_freeN(text); Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_modifier.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/rna_modifier.c 2009-01-03 19:39:39 UTC (rev 18294) +++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_modifier.c 2009-01-03 20:03:39 UTC (rev 18295) @@ -875,7 +875,6 @@ srna= RNA_def_struct(brna, CastModifier, Modifier); RNA_def_struct_ui_text(srna, Cast Modifier, Cast Modifier.); RNA_def_struct_sdna(srna, CastModifierData); - RNA_def_property_update(prop, NC_OBJECT|ND_MODIFIER, rna_Modifier_update); prop= RNA_def_property(srna, cast_type, PROP_ENUM, PROP_NONE); RNA_def_property_enum_sdna(prop, NULL, type); Modified: branches/blender2.5/blender/source/blender/windowmanager/intern/wm.c === --- branches/blender2.5/blender/source/blender/windowmanager/intern/wm.c 2009-01-03 19:39:39 UTC (rev 18294) +++ branches/blender2.5/blender/source/blender/windowmanager/intern/wm.c 2009-01-03 20:03:39 UTC (rev 18295) @@ -80,12 +80,6 @@ { int tot; - if(op-ptr) { - op-properties= op-ptr-data; - MEM_freeN(op-ptr); - op-ptr= NULL; - } - BLI_addtail(wm-operators, op); tot= BLI_countlist(wm-operators); Modified: branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c === --- branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c 2009-01-03 19:39:39 UTC (rev 18294) +++ branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c 2009-01-03 20:03:39 UTC (rev 18295) @@ -367,11 +367,18 @@ op-type= ot; BLI_strncpy(op-idname, ot-idname, OP_MAX_TYPENAME); + /* initialize properties, either copy or create */ op-ptr= MEM_callocN(sizeof(PointerRNA), wmOperatorPtrRNA); - if(properties properties-data) - op-ptr-data= IDP_CopyProperty(properties-data); - RNA_pointer_create(RNA_WindowManager, wm-id, ot-srna, op-ptr-data, op-ptr); + if(properties properties-data) { + op-properties= IDP_CopyProperty(properties-data); + } + else { + IDPropertyTemplate val = {0}; + op-properties= IDP_New(IDP_GROUP, val, wmOperatorProperties); + } + RNA_pointer_create(RNA_WindowManager, wm-id, ot-srna, op-properties, op-ptr); + /* initialize error reports */ if (reports) { op-reports= reports; /* must be initialized alredy */ } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18411] branches/blender2.5/blender/source /blender: RNA
Revision: 18411 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18411 Author: blendix Date: 2009-01-07 22:05:51 +0100 (Wed, 07 Jan 2009) Log Message: --- RNA * DNA_userdef_types.h, done. Patch by Nathaniel Garbutt, thanks! Modified Paths: -- branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h branches/blender2.5/blender/source/blender/makesrna/RNA_access.h branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_constraint.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_text.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_userdef.c Modified: branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h === --- branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h 2009-01-07 20:40:27 UTC (rev 18410) +++ branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h 2009-01-07 21:05:51 UTC (rev 18411) @@ -331,5 +331,11 @@ #define GP_PAINT_DOSMOOTH (10) #define GP_PAINT_DOSIMPLIFY(11) +/* theme drawtypes */ +#define TH_MINIMAL 0 +#define TH_ROUNDSHADED 1 +#define TH_ROUNDED 2 +#define TH_OLDSKOOL3 +#define TH_SHADED 4 #endif Modified: branches/blender2.5/blender/source/blender/makesrna/RNA_access.h === --- branches/blender2.5/blender/source/blender/makesrna/RNA_access.h 2009-01-07 20:40:27 UTC (rev 18410) +++ branches/blender2.5/blender/source/blender/makesrna/RNA_access.h 2009-01-07 21:05:51 UTC (rev 18411) @@ -36,6 +36,8 @@ extern BlenderRNA BLENDER_RNA; extern StructRNA RNA_Action; +extern StructRNA RNA_ActionChannel; +extern StructRNA RNA_ActionGroup; extern StructRNA RNA_Actuator; extern StructRNA RNA_ActuatorSensor; extern StructRNA RNA_AlwaysSensor; @@ -55,8 +57,8 @@ extern StructRNA RNA_Camera; extern StructRNA RNA_CastModifier; extern StructRNA RNA_CharInfo; +extern StructRNA RNA_ClothCollisionSettings; extern StructRNA RNA_ClothModifier; -extern StructRNA RNA_ClothCollisionSettings; extern StructRNA RNA_ClothSettings; extern StructRNA RNA_CollectionProperty; extern StructRNA RNA_CollisionModifier; @@ -118,7 +120,6 @@ extern StructRNA RNA_LatticeModifier; extern StructRNA RNA_LatticePoint; extern StructRNA RNA_Library; -extern StructRNA RNA_MappingTexture; extern StructRNA RNA_MCol; extern StructRNA RNA_MColLayer; extern StructRNA RNA_MFloatProperty; @@ -223,11 +224,30 @@ extern StructRNA RNA_TextLine; extern StructRNA RNA_TextMarker; extern StructRNA RNA_Texture; +extern StructRNA RNA_TextureSlot; +extern StructRNA RNA_Theme; +extern StructRNA RNA_ThemeActionEditor; +extern StructRNA RNA_ThemeAudioWindow; +extern StructRNA RNA_ThemeBoneColorSet; +extern StructRNA RNA_ThemeButtonsWindow; +extern StructRNA RNA_ThemeFileBrowser; +extern StructRNA RNA_ThemeImageEditor; +extern StructRNA RNA_ThemeIpoEditor; +extern StructRNA RNA_ThemeNLAEditor; +extern StructRNA RNA_ThemeNodeEditor; +extern StructRNA RNA_ThemeOutliner; +extern StructRNA RNA_ThemeSequenceEditor; +extern StructRNA RNA_ThemeTextEditor; +extern StructRNA RNA_ThemeTimeline; +extern StructRNA RNA_ThemeUserInterface; +extern StructRNA RNA_ThemeUserPreferences; +extern StructRNA RNA_ThemeView3D; extern StructRNA RNA_TouchSensor; extern StructRNA RNA_TransformSequence; extern StructRNA RNA_UVProjectModifier; extern StructRNA RNA_UnknownType; extern StructRNA RNA_UserPreferences; +extern StructRNA RNA_UserSolidLight; extern StructRNA RNA_VectorFont; extern StructRNA RNA_VertexGroup; extern StructRNA RNA_WaveModifier; Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-01-07 20:40:27 UTC (rev 18410) +++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-01-07 21:05:51 UTC (rev 18411) @@ -167,6 +167,15 @@ return mask; } +static int rna_color_quantize(PropertyRNA *prop, PropertyDefRNA *dp) +{ + if(prop-type == PROP_FLOAT prop-subtype == PROP_COLOR) + if(strcmp(dp-dnatype, float) != 0 strcmp(dp-dnatype, double) != 0) + return 1; + + return 0; +} + static char *rna_def_property_get_func(FILE *f, StructRNA *srna, PropertyRNA *prop, PropertyDefRNA *dp) { char *func; @@ -212,6 +221,8 @@ else { if(prop-type == PROP_BOOLEAN dp-booleanbit) fprintf(f, return (%s(data-%s[index] %d) != 0);\n, (dp-booleannegative)? !: , dp-dnaname, dp-booleanbit); +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18416] branches/blender2.5/blender: 2.5: make and cmake fixes for recent changes.
Revision: 18416 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18416 Author: blendix Date: 2009-01-08 14:54:39 +0100 (Thu, 08 Jan 2009) Log Message: --- 2.5: make and cmake fixes for recent changes. Modified Paths: -- branches/blender2.5/blender/intern/ghost/Makefile branches/blender2.5/blender/source/Makefile branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt Modified: branches/blender2.5/blender/intern/ghost/Makefile === --- branches/blender2.5/blender/intern/ghost/Makefile 2009-01-08 11:14:58 UTC (rev 18415) +++ branches/blender2.5/blender/intern/ghost/Makefile 2009-01-08 13:54:39 UTC (rev 18416) @@ -38,7 +38,7 @@ include nan_subdirs.mk -install: all +install: all debug @[ -d $(NAN_GHOST) ] || mkdir $(NAN_GHOST) @[ -d $(NAN_GHOST)/include ] || mkdir $(NAN_GHOST)/include @[ -d $(NAN_GHOST)/lib ] || mkdir $(NAN_GHOST)/lib Modified: branches/blender2.5/blender/source/Makefile === --- branches/blender2.5/blender/source/Makefile 2009-01-08 11:14:58 UTC (rev 18415) +++ branches/blender2.5/blender/source/Makefile 2009-01-08 13:54:39 UTC (rev 18416) @@ -237,8 +237,8 @@ PULIB += $(OCGDIR)/blender/ed_view3d/libed_view3d.a PULIB += $(OCGDIR)/blender/ed_interface/libed_interface.a PULIB += $(OCGDIR)/blender/ed_object/libed_object.a +PULIB += $(OCGDIR)/blender/ed_armature/libed_armature.a PULIB += $(OCGDIR)/blender/ed_mesh/libed_mesh.a -PULIB += $(OCGDIR)/blender/ed_armature/libed_armature.a PULIB += $(OCGDIR)/blender/ed_animation/libed_animation.a PULIB += $(OCGDIR)/blender/ed_transform/libed_transform.a PULIB += $(OCGDIR)/blender/ed_util/libed_util.a Modified: branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt === --- branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt 2009-01-08 11:14:58 UTC (rev 18415) +++ branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt 2009-01-08 13:54:39 UTC (rev 18416) @@ -33,6 +33,7 @@ ../../../intern/iksolver/extern ../blenloader ../quicktime ../../../intern/bmfont ../../../extern/bullet2/src ../nodes ../../../extern/glew/include ../gpu ../makesrna + ../../../intern/bsp/extern ${SDL_INC} ${ZLIB_INC} ) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18417] branches/blender2.5/blender/source /blender/makesrna: RNA
Revision: 18417 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18417 Author: blendix Date: 2009-01-08 14:57:29 +0100 (Thu, 08 Jan 2009) Log Message: --- RNA * The generated code is now split into multiple files instead of a single big one. Scons, make and cmake are updated to deal with this. Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/RNA_types.h branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt branches/blender2.5/blender/source/blender/makesrna/intern/Makefile branches/blender2.5/blender/source/blender/makesrna/intern/SConscript branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_ID.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_lattice.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_meta.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_modifier.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_object.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_rna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_text.c Modified: branches/blender2.5/blender/source/blender/makesrna/RNA_types.h === --- branches/blender2.5/blender/source/blender/makesrna/RNA_types.h 2009-01-08 13:54:39 UTC (rev 18416) +++ branches/blender2.5/blender/source/blender/makesrna/RNA_types.h 2009-01-08 13:57:29 UTC (rev 18417) @@ -132,7 +132,8 @@ STRUCT_ID = 1, /* internal flags */ - STRUCT_RUNTIME = 2 + STRUCT_RUNTIME = 2, + STRUCT_GENERATED = 4 } StructFlag; typedef struct StructRNA StructRNA; Modified: branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt === --- branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt 2009-01-08 13:54:39 UTC (rev 18416) +++ branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt 2009-01-08 13:57:29 UTC (rev 18417) @@ -24,8 +24,7 @@ # # * END GPL LICENSE BLOCK * -SET(SRC - makesrna.c +SET(DEFSRC rna_action.c rna_actuator.c rna_armature.c @@ -36,7 +35,6 @@ rna_constraint.c rna_controller.c rna_curve.c - rna_define.c rna_fluidsim.c rna_group.c rna_ID.c @@ -70,7 +68,58 @@ rna_userdef.c rna_vfont.c rna_wm.c - rna_world.c + rna_world.c) + +SET(GENSRC + rna_action_gen.c + rna_actuator_gen.c + rna_armature_gen.c + rna_brush_gen.c + rna_camera_gen.c + rna_cloth_gen.c + rna_color_gen.c + rna_constraint_gen.c + rna_controller_gen.c + rna_curve_gen.c + rna_fluidsim_gen.c + rna_group_gen.c + rna_ID_gen.c + rna_image_gen.c + rna_ipo_gen.c + rna_key_gen.c + rna_lamp_gen.c + rna_lattice_gen.c + rna_main_gen.c + rna_material_gen.c + rna_mesh_gen.c + rna_meta_gen.c + rna_modifier_gen.c + rna_nodetree_gen.c + rna_object_gen.c + rna_object_force_gen.c + rna_packedfile_gen.c + rna_particle_gen.c + rna_pose_gen.c + rna_property_gen.c + rna_radio_gen.c + rna_rna_gen.c + rna_scene_gen.c + rna_screen_gen.c + rna_scriptlink_gen.c + rna_sensor_gen.c + rna_sequence_gen.c + rna_sound_gen.c + rna_text_gen.c + rna_texture_gen.c + rna_userdef_gen.c + rna_vfont_gen.c + rna_wm_gen.c + rna_world_gen.c) + +SET(SRC + makesrna.c + rna_define.c + ${DEFSRC} ../../../../intern/guardedalloc/intern/mallocn.c ../../../../intern/guardedalloc/intern/mmap_win.c) @@ -81,15 +130,16 @@ ADD_EXECUTABLE(makesrna ${SRC} ${INC_FILES}) TARGET_LINK_LIBRARIES(makesrna bf_dna) -# Output rna.c +# Output rna_*_gen.c ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/rna.c - COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesrna ${CMAKE_CURRENT_BINARY_DIR}/rna.c ${CMAKE_SOURCE_DIR}/source/blender/makesrna/ + OUTPUT ${GENSRC} + COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesrna ${CMAKE_CURRENT_BINARY_DIR}/ ${CMAKE_SOURCE_DIR}/source/blender/makesrna/ DEPENDS makesrna ) # Build bf_rna -SET(SRC rna_access.c rna_dependency.c rna.c) +SET(SRC rna_access.c rna_dependency.c ${GENSRC}) BLENDERLIB(bf_rna ${SRC} ${INC}) MESSAGE(STATUS Configuring makesrna) + Modified: branches/blender2.5/blender/source/blender/makesrna/intern/Makefile === --- branches/blender2.5/blender/source/blender/makesrna/intern/Makefile 2009-01-08 13:54:39
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18419] branches/blender2.5/blender/source /blender: RNA: don't pass RNA type in RNA_id_pointer_create, can be found automatically.
Revision: 18419 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18419 Author: blendix Date: 2009-01-08 16:33:34 +0100 (Thu, 08 Jan 2009) Log Message: --- RNA: don't pass RNA type in RNA_id_pointer_create, can be found automatically. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c branches/blender2.5/blender/source/blender/makesrna/RNA_access.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c Modified: branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c === --- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-01-08 15:29:09 UTC (rev 18418) +++ branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-01-08 15:33:34 UTC (rev 18419) @@ -1357,7 +1357,7 @@ else if(soops-outlinevis==SO_USERDEF) { PointerRNA userdefptr; - RNA_pointer_create(NULL, NULL, RNA_UserPreferences, U, userdefptr); + RNA_pointer_create(NULL, RNA_UserPreferences, U, userdefptr); ten= outliner_add_element(soops, soops-tree, (void*)userdefptr, NULL, TSE_RNA_STRUCT, -1); Modified: branches/blender2.5/blender/source/blender/makesrna/RNA_access.h === --- branches/blender2.5/blender/source/blender/makesrna/RNA_access.h 2009-01-08 15:29:09 UTC (rev 18418) +++ branches/blender2.5/blender/source/blender/makesrna/RNA_access.h 2009-01-08 15:33:34 UTC (rev 18419) @@ -270,8 +270,8 @@ */ void RNA_main_pointer_create(struct Main *main, PointerRNA *r_ptr); -void RNA_id_pointer_create(StructRNA *idtype, struct ID *id, PointerRNA *r_ptr); -void RNA_pointer_create(StructRNA *idtype, struct ID *id, StructRNA *type, void *data, PointerRNA *r_ptr); +void RNA_id_pointer_create(struct ID *id, PointerRNA *r_ptr); +void RNA_pointer_create(struct ID *id, StructRNA *type, void *data, PointerRNA *r_ptr); void RNA_blender_rna_pointer_create(PointerRNA *r_ptr); Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c 2009-01-08 15:29:09 UTC (rev 18418) +++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c 2009-01-08 15:33:34 UTC (rev 18419) @@ -61,16 +61,34 @@ r_ptr-data= main; } -void RNA_id_pointer_create(StructRNA *idtype, ID *id, PointerRNA *r_ptr) +void RNA_id_pointer_create(ID *id, PointerRNA *r_ptr) { + PointerRNA tmp; + StructRNA *idtype= NULL; + + if(id) { + memset(tmp, 0, sizeof(tmp)); + tmp.data= id; + idtype= rna_ID_refine(tmp); + } + r_ptr-id.type= idtype; r_ptr-id.data= id; r_ptr-type= idtype; r_ptr-data= id; } -void RNA_pointer_create(StructRNA *idtype, ID *id, StructRNA *type, void *data, PointerRNA *r_ptr) +void RNA_pointer_create(ID *id, StructRNA *type, void *data, PointerRNA *r_ptr) { + PointerRNA tmp; + StructRNA *idtype= NULL; + + if(id) { + memset(tmp, 0, sizeof(tmp)); + tmp.data= id; + idtype= rna_ID_refine(tmp); + } + r_ptr-id.type= idtype; r_ptr-id.data= id; r_ptr-type= type; Modified: branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c === --- branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c 2009-01-08 15:29:09 UTC (rev 18418) +++ branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c 2009-01-08 15:33:34 UTC (rev 18419) @@ -392,7 +392,7 @@ IDPropertyTemplate val = {0}; op-properties= IDP_New(IDP_GROUP, val, wmOperatorProperties); } - RNA_pointer_create(RNA_WindowManager, wm-id, ot-srna, op-properties, op-ptr); + RNA_pointer_create(wm-id, ot-srna, op-properties, op-ptr); /* initialize error reports */ if (reports) { Modified: branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c === --- branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c 2009-01-08 15:29:09 UTC (rev 18418) +++ branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c 2009-01-08 15:33:34 UTC
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18448] branches/blender2.5/blender/source /blender: RNA
Revision: 18448 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18448 Author: blendix Date: 2009-01-10 23:57:33 +0100 (Sat, 10 Jan 2009) Log Message: --- RNA * Finished DNA_lamp_types.h, DNA_world_types.h and DNA_sound_types.h. * Renamed parent struct property to nested, and also remaining from usage to base. * Added a NEVER_NULL subtype for pointers and use it for all properties that apply. * Make sure all structs have a description, and fix any other DOC_BROKEN descriptions, also many other naming consistency improvements. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c branches/blender2.5/blender/source/blender/makesrna/RNA_access.h branches/blender2.5/blender/source/blender/makesrna/RNA_define.h branches/blender2.5/blender/source/blender/makesrna/RNA_types.h branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_ID.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_action.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_actuator.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_armature.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_brush.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_camera.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_cloth.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_color.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_constraint.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_controller.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_curve.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_fluidsim.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_group.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_image.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal_types.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_ipo.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_key.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_lamp.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_lattice.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_main.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_material.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_mesh.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_meta.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_modifier.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_nodetree.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_object.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_object_force.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_packedfile.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_particle.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_pose.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_property.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_radio.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_rna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_screen.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_scriptlink.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_sensor.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_sequence.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_sound.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_text.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_texture.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_userdef.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_vfont.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_wm.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_world.c branches/blender2.5/blender/source/blender/python/epy_doc_gen.py Modified: branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c === --- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-01-10 19:45:48 UTC
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18515] branches/blender2.5/blender/source /blender: UI: various changes
Revision: 18515 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18515 Author: blendix Date: 2009-01-15 05:13:38 +0100 (Thu, 15 Jan 2009) Log Message: --- UI: various changes * View2D to region now returns ints instead of shorts. * Use Numpad instead of Pad in automatic keymap menu info. * Menus can now use buttons other than BUTM and SEPR, in particular TOG and ROW are now supported instead of flipping bits manually. * Added a simpler uiDefMenu* api for making menus now, and it only supports Operator and RNA buttons at the moment, will be used in next commit. Not sure how this will evolve .. makes menu code look cleaner anyways. * Ensure that interface code doesn't crash when getting unknown Operators and RNA properties, and display their buttons grayed out in that case. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/gpencil/gpencil.c branches/blender2.5/blender/source/blender/editors/include/UI_interface.h branches/blender2.5/blender/source/blender/editors/include/UI_resources.h branches/blender2.5/blender/source/blender/editors/include/UI_view2d.h branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/interface/interface_draw.c branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/interface/view2d.c branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_draw.c branches/blender2.5/blender/source/blender/editors/space_time/time_header.c branches/blender2.5/blender/source/blender/editors/transform/transform.c branches/blender2.5/blender/source/blender/windowmanager/WM_api.h branches/blender2.5/blender/source/blender/windowmanager/intern/wm_keymap.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c Modified: branches/blender2.5/blender/source/blender/editors/gpencil/gpencil.c === --- branches/blender2.5/blender/source/blender/editors/gpencil/gpencil.c 2009-01-15 03:12:21 UTC (rev 18514) +++ branches/blender2.5/blender/source/blender/editors/gpencil/gpencil.c 2009-01-15 04:13:38 UTC (rev 18515) @@ -770,7 +770,8 @@ VecCopyf(p3d, pt-x); } else { - short mval[2], mx, my; + short mval[2]; + int mx, my; float *fp= give_cursor(NULL, NULL); // XXX should be scene, v3d float dvec[3]; @@ -778,15 +779,13 @@ if (gps-flag GP_STROKE_2DSPACE) { // XXX // View2D *v2d= spacelink_get_view2d(curarea-spacedata.first); - // UI_view2d_view_to_region(v2d, pt-x, pt-y, mval, mval+1); + // UI_view2d_view_to_region(v2d, pt-x, pt-y, mx, my); } else { // XXX - // mval[0]= (short)(pt-x / 1000 * curarea-winx); - // mval[1]= (short)(pt-y / 1000 * curarea-winy); + // mx= (short)(pt-x / 1000 * curarea-winx); + // my= (short)(pt-y / 1000 * curarea-winy); } - mx= mval[0]; - my= mval[1]; /* convert screen coordinate to 3d coordinates * - method taken from editview.c - mouse_cursor() @@ -1551,7 +1550,7 @@ { bGPDspoint *pt1, *pt2; View3D *v3d= NULL; - short x0=0, y0=0, x1=0, y1=0; + int x0=0, y0=0, x1=0, y1=0; short xyval[2]; int i; Modified: branches/blender2.5/blender/source/blender/editors/include/UI_interface.h === --- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-01-15 03:12:21 UTC (rev 18514) +++ branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-01-15 04:13:38 UTC (rev 18515) @@ -268,7 +268,7 @@ uiBut *uiDefButC(uiBlock *block, int type, int retval, char *str, short x1, short y1, short x2, short y2, char *poin, float min, float max, float a1, float a2, char *tip); uiBut *uiDefButBitC(uiBlock *block, int type, int bit, int retval, char *str, short x1, short y1, short x2, short y2, char *poin, float min, float max, float a1, float a2, char *tip); uiBut *uiDefButR(uiBlock *block, int type, int retval, char *str, short x1, short y1, short x2, short y2, struct PointerRNA *ptr, const char *propname, int index, float min, float max, float a1, float a2, char *tip); -uiBut *uiDefButO(struct bContext *C, uiBlock *block, int type, char *opname, int opcontext, char *str, short x1, short y1, short x2, short y2, char *tip); +uiBut
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18516] branches/blender2.5/blender/source /blender: RNA
Revision: 18516 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18516 Author: blendix Date: 2009-01-15 05:22:23 +0100 (Thu, 15 Jan 2009) Log Message: --- RNA * Work around bScreen/Screen DNA name patching, so bScreen does not require manual callbacks to be written for properties. * Added SpaceLink and SpaceImage RNA. * Fix issue initializing ID property arrays with default values. DNA * Some DNA changes for space image. * And a fix for corrupt clone image pointer in reading brushes. Modified Paths: -- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c branches/blender2.5/blender/source/blender/makesdna/DNA_scene_types.h branches/blender2.5/blender/source/blender/makesdna/DNA_space_types.h branches/blender2.5/blender/source/blender/makesrna/RNA_access.h branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_internal.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_material.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_screen.c Added Paths: --- branches/blender2.5/blender/source/blender/makesrna/intern/rna_space.c Modified: branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c === --- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-15 04:13:38 UTC (rev 18515) +++ branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-15 04:22:23 UTC (rev 18516) @@ -1490,6 +1490,8 @@ if(mtex) mtex-tex= newlibadr_us(fd, brush-id.lib, mtex-tex); } + + brush-clone.image= newlibadr_us(fd, brush-id.lib, brush-clone.image); } } } @@ -5237,6 +5239,7 @@ break; } } + /* main region */ ar= MEM_callocN(sizeof(ARegion), area region from do_versions); Modified: branches/blender2.5/blender/source/blender/makesdna/DNA_scene_types.h === --- branches/blender2.5/blender/source/blender/makesdna/DNA_scene_types.h 2009-01-15 04:13:38 UTC (rev 18515) +++ branches/blender2.5/blender/source/blender/makesdna/DNA_scene_types.h 2009-01-15 04:22:23 UTC (rev 18516) @@ -431,6 +431,8 @@ short uvcalc_mapdir; short uvcalc_mapalign; short uvcalc_flag; + short uv_flag, uv_selectmode; + short uv_pad[2]; /* Auto-IK */ short autoik_chainlen; @@ -838,6 +840,16 @@ #define UVCALC_NO_ASPECT_CORRECT 2 /* would call this UVCALC_ASPECT_CORRECT, except it should be default with old file */ #define UVCALC_TRANSFORM_CORRECT 4 /* adjust UV's while transforming to avoid distortion */ +/* toolsettings-uv_flag */ +#define UV_SYNC_SELECTION 1 +#define UV_SHOW_SAME_IMAGE 2 + +/* toolsettings-uv_selectmode */ +#define UV_SELECT_VERTEX 0 +#define UV_SELECT_EDGE 1 /* not implemented */ +#define UV_SELECT_FACE 2 +#define UV_SELECT_ISLAND 3 + /* toolsettings-edge_mode */ #define EDGE_MODE_SELECT 0 #define EDGE_MODE_TAG_SEAM 1 Modified: branches/blender2.5/blender/source/blender/makesdna/DNA_space_types.h === --- branches/blender2.5/blender/source/blender/makesdna/DNA_space_types.h 2009-01-15 04:13:38 UTC (rev 18515) +++ branches/blender2.5/blender/source/blender/makesdna/DNA_space_types.h 2009-01-15 04:22:23 UTC (rev 18516) @@ -222,30 +222,26 @@ SpaceLink *next, *prev; ListBase regionbase;/* storage of regions for inactive spaces */ int spacetype; - float blockscale; + float blockscale; short blockhandler[8]; - - View2D v2d; /* depricated, copied to region */ struct Image *image; struct ImageUser iuser; struct CurveMapping *cumap; - short mode, menunr; - short imanr; + short menunr, imanr, pad2; short curtile; /* the currently active tile of the image when tile is enabled, is kept in sync with the active faces tile */ int flag; - short selectmode; short imtypenr, lock; - short pin; - float zoom; + short pin, pad3; char dt_uv; /* UV draw type */ char sticky; /* sticky selection type */ char dt_uvstretch; -
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18517] branches/blender2.5/blender/source /blender: 2.5: Space Image ported back
Revision: 18517 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18517 Author: blendix Date: 2009-01-15 05:38:18 +0100 (Thu, 15 Jan 2009) Log Message: --- 2.5: Space Image ported back Organized as follows: uvedit/ uv editing related code uvedit_draw.c: drawing code uvedit_ops.c: operators, just a few done uvedit_unwrap_ops.c: will be operators for unwrapping uvedit_paramatrizer.c: lscm/abf/stretch/pack space_image/ space_image.c: registration and common getter/setters image_draw.c: drawing code, mostly functional image_panels.c: panels, all commented out image_render.c: render callbacks, non functional image_ops.c: operators, only view navigation done image_header.c: header, menus mostly done but missing buttons Notes: * Header menus consist only of Operator and RNA buttons, if they are not implemented they're displayed grayed out. Ideally the full header could work like this, but std_libbuttons looks problematic. * Started using view2d code more than the old code, but for now it still does own view2d management due to some very specific requirements that the image window has. The drawing code however is more clear hopefully, it only uses view2d, and there is no switching between 'p' and 'f' view2d's anymore, it is always 'f'. * In order to make uvedit operators more independent I move some image space settings to scene toolsettings, and the current image and its buffer is in the context. Especially sync selection and select mode belonged there anyway as this cannot work correct with different spaces having different settings anyway. * Image paint is not back yet, did not want to put that together with uvedit because there's really no code sharing.. perhaps vertex paint, image paint and sculpt would be good to have in one module to share brush code, partial redraw, etc better. Modified Paths: -- branches/blender2.5/blender/source/blender/blenkernel/BKE_context.h branches/blender2.5/blender/source/blender/blenkernel/intern/context.c branches/blender2.5/blender/source/blender/editors/Makefile branches/blender2.5/blender/source/blender/editors/SConscript branches/blender2.5/blender/source/blender/editors/include/ED_armature.h branches/blender2.5/blender/source/blender/editors/include/ED_mesh.h branches/blender2.5/blender/source/blender/editors/include/ED_object.h branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/mesh/editface.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_lib.c branches/blender2.5/blender/source/blender/editors/mesh/mesh_intern.h branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/space_api/spacetypes.c branches/blender2.5/blender/source/blender/editors/space_image/Makefile branches/blender2.5/blender/source/blender/editors/space_image/SConscript branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h branches/blender2.5/blender/source/blender/editors/space_image/space_image.c Added Paths: --- branches/blender2.5/blender/source/blender/editors/include/ED_uvedit.h branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c branches/blender2.5/blender/source/blender/editors/space_image/image_panels.c branches/blender2.5/blender/source/blender/editors/space_image/image_render.c branches/blender2.5/blender/source/blender/editors/uvedit/ branches/blender2.5/blender/source/blender/editors/uvedit/Makefile branches/blender2.5/blender/source/blender/editors/uvedit/SConscript branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_draw.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_intern.h branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_parametrizer.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_parametrizer.h branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_unwrap_ops.c Removed Paths: - branches/blender2.5/blender/source/blender/editors/space_image/image_header.c Modified: branches/blender2.5/blender/source/blender/blenkernel/BKE_context.h === --- branches/blender2.5/blender/source/blender/blenkernel/BKE_context.h 2009-01-15 04:22:23 UTC (rev 18516) +++ branches/blender2.5/blender/source/blender/blenkernel/BKE_context.h 2009-01-15 04:38:18 UTC (rev 18517) @@ -47,6 +47,8 @@ struct
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18520] branches/blender2.5/blender/source /blender/editors/space_image/SConscript: Tweak scons linking order priority to fix compile on windows.
Revision: 18520 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18520 Author: blendix Date: 2009-01-15 06:51:00 +0100 (Thu, 15 Jan 2009) Log Message: --- Tweak scons linking order priority to fix compile on windows. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_image/SConscript Modified: branches/blender2.5/blender/source/blender/editors/space_image/SConscript === --- branches/blender2.5/blender/source/blender/editors/space_image/SConscript 2009-01-15 05:41:25 UTC (rev 18519) +++ branches/blender2.5/blender/source/blender/editors/space_image/SConscript 2009-01-15 05:51:00 UTC (rev 18520) @@ -7,4 +7,4 @@ incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' incs += ' ../../render/extern/include ../../makesrna' -env.BlenderLib ( 'bf_editors_space_image', sources, Split(incs), [], libtype=['core'], priority=[45] ) +env.BlenderLib ( 'bf_editors_space_image', sources, Split(incs), [], libtype=['core'], priority=[40] ) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18525] branches/blender2.5/blender/source /blender/makesrna/intern: RNA
Revision: 18525 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18525 Author: blendix Date: 2009-01-15 17:18:32 +0100 (Thu, 15 Jan 2009) Log Message: --- RNA * Attempt to fix CMake build on some systems were it could not find the rna_*_gen.c files, now it specifies full path. Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c Modified: branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt === --- branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt 2009-01-15 16:07:39 UTC (rev 18524) +++ branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt 2009-01-15 16:18:32 UTC (rev 18525) @@ -71,52 +71,7 @@ rna_wm.c rna_world.c) -SET(GENSRC - rna_action_gen.c - rna_actuator_gen.c - rna_armature_gen.c - rna_brush_gen.c - rna_camera_gen.c - rna_cloth_gen.c - rna_color_gen.c - rna_constraint_gen.c - rna_controller_gen.c - rna_curve_gen.c - rna_fluidsim_gen.c - rna_group_gen.c - rna_ID_gen.c - rna_image_gen.c - rna_ipo_gen.c - rna_key_gen.c - rna_lamp_gen.c - rna_lattice_gen.c - rna_main_gen.c - rna_material_gen.c - rna_mesh_gen.c - rna_meta_gen.c - rna_modifier_gen.c - rna_nodetree_gen.c - rna_object_gen.c - rna_object_force_gen.c - rna_packedfile_gen.c - rna_particle_gen.c - rna_pose_gen.c - rna_property_gen.c - rna_radio_gen.c - rna_rna_gen.c - rna_scene_gen.c - rna_screen_gen.c - rna_scriptlink_gen.c - rna_sensor_gen.c - rna_sequence_gen.c - rna_sound_gen.c - rna_space_gen.c - rna_text_gen.c - rna_texture_gen.c - rna_userdef_gen.c - rna_vfont_gen.c - rna_wm_gen.c - rna_world_gen.c) +STRING(REGEX REPLACE rna_([a-zA-Z0-9_-]*).c ${CMAKE_CURRENT_BINARY_DIR}/rna_\\1_gen.c GENSRC ${DEFSRC}) SET(SRC makesrna.c @@ -135,7 +90,7 @@ # Output rna_*_gen.c ADD_CUSTOM_COMMAND( OUTPUT ${GENSRC} - COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesrna ${CMAKE_CURRENT_BINARY_DIR}/ ${CMAKE_SOURCE_DIR}/source/blender/makesrna/ + COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesrna ${CMAKE_CURRENT_BINARY_DIR}/ DEPENDS makesrna ) Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-01-15 16:07:39 UTC (rev 18524) +++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-01-15 16:18:32 UTC (rev 18525) @@ -962,7 +962,7 @@ {rna_world.c, RNA_def_world}, {NULL, NULL}}; -static void rna_generate(BlenderRNA *brna, char *basedirectory, FILE *f, char *filename) +static void rna_generate(BlenderRNA *brna, FILE *f, char *filename) { StructDefRNA *ds; PropertyDefRNA *dp; @@ -1014,7 +1014,7 @@ fclose(fp); } -static int rna_preprocess(char *basedirectory, char *outfile) +static int rna_preprocess(char *outfile) { BlenderRNA *brna; StructDefRNA *ds; @@ -1059,7 +1059,7 @@ status = 1; } else { - rna_generate(brna, basedirectory, file, PROCESS_ITEMS[i].filename); + rna_generate(brna, file, PROCESS_ITEMS[i].filename); fclose(file); status= (DefRNA.error != 0); @@ -1073,29 +1073,17 @@ return status; } -#ifndef BASE_HEADER -#define BASE_HEADER ../ -#endif - int main(int argc, char **argv) { int totblock, return_status = 0; - if (argc!=2 argc!=3) { - printf(Usage: %s outdirectory/ [base directory]\n, argv[0]); + if (argc2) { + printf(Usage: %s outdirectory/\n, argv[0]); return_status = 1; } else { - char baseDirectory[256]; - printf(Running makesrna, program versions %s\n, RNA_VERSION_DATE); - - if (argc==3) - strcpy(baseDirectory, argv[2]); - else - strcpy(baseDirectory, BASE_HEADER); - - return_status= rna_preprocess(baseDirectory, argv[1]); + return_status= rna_preprocess(argv[1]); } totblock= MEM_get_memory_blocks_in_use(); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18542] branches/blender2.5/blender/source /blender: RNA
Revision: 18542 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18542 Author: blendix Date: 2009-01-17 00:53:11 +0100 (Sat, 17 Jan 2009) Log Message: --- RNA * Added more compact property definitions, with a single function. Only used by operators at the moment, would need to tweak regular expressions a bit more to use it also for other RNA definitions. * The operator properties defined now were completed a bit more but still have many issues that need to be adressed, specifically; * Some properties that should be booleans or enums are defined as ints, note that ints are only for numeric values, not bitflags or multiple choice. * Soft/hard limits and default values of many properties are not well defined still, * Inconsistent naming, especially for example mouse locations or bounds are named differently in different places. Also mouse locations and other vector like properties should become a single vector property instead of multiple X/Y properties. * Almost no properties have descriptions, these would be good to have for docs and tooltips. So, please verify that the properties of the operators you wrote are well defined. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c branches/blender2.5/blender/source/blender/editors/animation/anim_draw.c branches/blender2.5/blender/source/blender/editors/animation/anim_filter.c branches/blender2.5/blender/source/blender/editors/animation/anim_ipo_utils.c branches/blender2.5/blender/source/blender/editors/animation/anim_markers.c branches/blender2.5/blender/source/blender/editors/animation/anim_ops.c branches/blender2.5/blender/source/blender/editors/animation/keyframes_draw.c branches/blender2.5/blender/source/blender/editors/animation/keyframes_edit.c branches/blender2.5/blender/source/blender/editors/animation/keyframes_general.c branches/blender2.5/blender/source/blender/editors/animation/keyframing.c branches/blender2.5/blender/source/blender/editors/interface/view2d_ops.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_add.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_tools.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/sculpt/sculpt.c branches/blender2.5/blender/source/blender/editors/space_action/action_draw.c branches/blender2.5/blender/source/blender/editors/space_action/action_edit.c branches/blender2.5/blender/source/blender/editors/space_action/action_ops.c branches/blender2.5/blender/source/blender/editors/space_action/action_select.c branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c branches/blender2.5/blender/source/blender/editors/space_ipo/ipo_draw.c branches/blender2.5/blender/source/blender/editors/space_node/node_select.c branches/blender2.5/blender/source/blender/editors/space_node/node_state.c branches/blender2.5/blender/source/blender/editors/space_script/script_edit.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_edit.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_select.c branches/blender2.5/blender/source/blender/editors/transform/transform_ops.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/makesrna/RNA_define.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c Modified: branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c === --- branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c 2009-01-16 20:24:31 UTC (rev 18541) +++ branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c 2009-01-16 23:53:11 UTC (rev 18542) @@ -1,1542 +1,1511 @@ -/** - * $Id: editaction.c 17746 2008-12-08 11:19:44Z aligorith $ - * - * * BEGIN GPL LICENSE BLOCK * - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18543] branches/blender2.5/blender/source /blender: RNA: forgot to rename some values in the keymaps in last commit.
Revision: 18543 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18543 Author: blendix Date: 2009-01-17 00:58:10 +0100 (Sat, 17 Jan 2009) Log Message: --- RNA: forgot to rename some values in the keymaps in last commit. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c branches/blender2.5/blender/source/blender/editors/mesh/mesh_ops.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_ops.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c Modified: branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c === --- branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c 2009-01-16 23:53:11 UTC (rev 18542) +++ branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c 2009-01-16 23:58:10 UTC (rev 18543) @@ -2956,7 +2956,7 @@ ot-flag= OPTYPE_REGISTER/*|OPTYPE_UNDO*/; /* props XXX figure out? */ - RNA_def_float(ot-srna, sharpness, 0.01f, 0.0f, FLT_MAX, sharpness, , 0.0f, FLT_MAX); + RNA_def_float(ot-srna, sharpness, 0.01f, 0.0f, FLT_MAX, sharpness, , 0.0f, 180.0f); } @@ -3128,7 +3128,7 @@ ot-flag= OPTYPE_REGISTER/*|OPTYPE_UNDO*/; /* props */ - RNA_def_float(ot-srna, sharpness, 0.0f, 0.0f, FLT_MAX, sharpness, , 0.0f, FLT_MAX); + RNA_def_float(ot-srna, sharpness, 0.0f, 0.0f, FLT_MAX, sharpness, , 0.0f, 180.0f); } void select_non_manifold(EditMesh *em) Modified: branches/blender2.5/blender/source/blender/editors/mesh/mesh_ops.c === --- branches/blender2.5/blender/source/blender/editors/mesh/mesh_ops.c 2009-01-16 23:53:11 UTC (rev 18542) +++ branches/blender2.5/blender/source/blender/editors/mesh/mesh_ops.c 2009-01-16 23:58:10 UTC (rev 18543) @@ -106,8 +106,8 @@ WM_keymap_add_item(keymap, MESH_OT_select_non_manifold, MKEY, KM_PRESS, (KM_CTRL|KM_SHIFT|KM_ALT), 0); WM_keymap_add_item(keymap, MESH_OT_selectconnected_mesh_all, LKEY, KM_PRESS, KM_CTRL, 0); WM_keymap_add_item(keymap, MESH_OT_selectconnected_mesh, LKEY, KM_PRESS, 0, 0); - RNA_float_set(WM_keymap_add_item(keymap, MESH_OT_select_linked_flat_faces, FKEY, KM_PRESS, (KM_CTRL|KM_SHIFT|KM_ALT), 0)-ptr,fsharpness,135.0); - RNA_float_set(WM_keymap_add_item(keymap, MESH_OT_select_sharp_edges, SKEY, KM_PRESS, (KM_CTRL|KM_SHIFT|KM_ALT), 0)-ptr,fsharpness,135.0); + RNA_float_set(WM_keymap_add_item(keymap, MESH_OT_select_linked_flat_faces, FKEY, KM_PRESS, (KM_CTRL|KM_SHIFT|KM_ALT), 0)-ptr,sharpness,135.0); + RNA_float_set(WM_keymap_add_item(keymap, MESH_OT_select_sharp_edges, SKEY, KM_PRESS, (KM_CTRL|KM_SHIFT|KM_ALT), 0)-ptr,sharpness,135.0); /* hide */ WM_keymap_add_item(keymap, MESH_OT_hide_mesh, HKEY, KM_PRESS, 0, 0); Modified: branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_ops.c === --- branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_ops.c 2009-01-16 23:53:11 UTC (rev 18542) +++ branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_ops.c 2009-01-16 23:58:10 UTC (rev 18543) @@ -117,35 +117,35 @@ RNA_boolean_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewhome, CKEY, KM_PRESS, KM_SHIFT, 0)-ptr, center, 1); /* numpad view hotkeys*/ - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD0, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_CAMERA); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD1, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_FRONT); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD2, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_STEPDOWN); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD3, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_RIGHT); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD4, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_STEPLEFT); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD5, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_PERSPORTHO); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD6, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_STEPRIGHT); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD7, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_TOP); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD8, KM_PRESS, 0, 0)-ptr, viewnum, V3D_VIEW_STEPUP); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD1, KM_PRESS, KM_CTRL, 0)-ptr, viewnum, V3D_VIEW_BACK); - RNA_enum_set(WM_keymap_add_item(keymap, VIEW3D_OT_viewnumpad, PAD3, KM_PRESS,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18545] branches/blender2.5/blender: 2.5: various warning fixes.
Revision: 18545 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18545 Author: blendix Date: 2009-01-17 01:51:42 +0100 (Sat, 17 Jan 2009) Log Message: --- 2.5: various warning fixes. Modified Paths: -- branches/blender2.5/blender/intern/SoundSystem/SND_Utils.h branches/blender2.5/blender/intern/SoundSystem/intern/SND_Utils.cpp branches/blender2.5/blender/intern/decimation/intern/LOD_ExternNormalEditor.cpp branches/blender2.5/blender/intern/decimation/intern/LOD_ManMesh2.cpp branches/blender2.5/blender/intern/decimation/intern/LOD_QSDecimator.cpp branches/blender2.5/blender/intern/elbeem/intern/solver_init.cpp branches/blender2.5/blender/intern/ghost/intern/GHOST_WindowX11.cpp branches/blender2.5/blender/intern/iksolver/intern/IK_Solver.cpp branches/blender2.5/blender/intern/opennl/superlu/util.c branches/blender2.5/blender/source/blender/blenkernel/BKE_context.h branches/blender2.5/blender/source/blender/blenkernel/intern/DerivedMesh.c branches/blender2.5/blender/source/blender/blenkernel/intern/context.c branches/blender2.5/blender/source/blender/blenkernel/intern/exotic.c branches/blender2.5/blender/source/blender/blenkernel/intern/modifier.c branches/blender2.5/blender/source/blender/blenkernel/intern/report.c branches/blender2.5/blender/source/blender/blenlib/intern/BLI_ghash.c branches/blender2.5/blender/source/blender/blenlib/intern/BLI_kdopbvh.c branches/blender2.5/blender/source/blender/blenlib/intern/arithb.c branches/blender2.5/blender/source/blender/blenlib/intern/fnmatch.c branches/blender2.5/blender/source/blender/blenlib/intern/graph.c branches/blender2.5/blender/source/blender/blenlib/intern/listbase.c branches/blender2.5/blender/source/blender/blenlib/intern/winstuff.c branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c branches/blender2.5/blender/source/blender/editors/animation/keyframing.c branches/blender2.5/blender/source/blender/editors/armature/editarmature.c branches/blender2.5/blender/source/blender/editors/transform/transform_conversions.c branches/blender2.5/blender/source/blender/imbuf/intern/cineon/cineonlib.c branches/blender2.5/blender/source/blender/imbuf/intern/cineon/dpxlib.c Modified: branches/blender2.5/blender/intern/SoundSystem/SND_Utils.h === --- branches/blender2.5/blender/intern/SoundSystem/SND_Utils.h 2009-01-17 00:26:46 UTC (rev 18544) +++ branches/blender2.5/blender/intern/SoundSystem/SND_Utils.h 2009-01-17 00:51:42 UTC (rev 18545) @@ -97,8 +97,8 @@ extern unsigned int SND_GetNumberOfChannels(void* sample); extern unsigned int SND_GetSampleRate(void* sample); extern unsigned int SND_GetBitRate(void* sample); -extern unsigned int SND_GetNumberOfSamples(void* sample, int sample_length); -extern unsigned int SND_GetHeaderSize(void* sample, int sample_length); +extern unsigned int SND_GetNumberOfSamples(void* sample, unsigned int sample_length); +extern unsigned int SND_GetHeaderSize(void* sample, unsigned int sample_length); extern unsigned int SND_GetExtraChunk(void* sample); extern void SND_GetSampleInfo(signed char* sample, SND_WaveSlot* waveslot); Modified: branches/blender2.5/blender/intern/SoundSystem/intern/SND_Utils.cpp === --- branches/blender2.5/blender/intern/SoundSystem/intern/SND_Utils.cpp 2009-01-17 00:26:46 UTC (rev 18544) +++ branches/blender2.5/blender/intern/SoundSystem/intern/SND_Utils.cpp 2009-01-17 00:51:42 UTC (rev 18545) @@ -290,7 +290,7 @@ /* gets the length of the actual sample data (without the header) */ -unsigned int SND_GetNumberOfSamples(void* sample, int sample_length) +unsigned int SND_GetNumberOfSamples(void* sample, unsigned int sample_length) { unsigned int chunklength, length = 0, offset; unsigned short block_align; @@ -330,7 +330,7 @@ /* gets the size of the entire header (file - sampledata) */ -unsigned int SND_GetHeaderSize(void* sample, int sample_length) +unsigned int SND_GetHeaderSize(void* sample, unsigned int sample_length) { unsigned int chunklength, headersize = 0, offset = 16; unsigned short block_align; Modified: branches/blender2.5/blender/intern/decimation/intern/LOD_ExternNormalEditor.cpp === --- branches/blender2.5/blender/intern/decimation/intern/LOD_ExternNormalEditor.cpp 2009-01-17 00:26:46 UTC (rev 18544) +++ branches/blender2.5/blender/intern/decimation/intern/LOD_ExternNormalEditor.cpp 2009-01-17 00:51:42 UTC (rev 18545) @@ -41,8 +41,8 @@ LOD_Decimation_InfoPtr extern_info, LOD_ManMesh2 mesh ) : - m_extern_info (extern_info), - m_mesh(mesh) + m_mesh(mesh), + m_extern_info (extern_info) { }
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18550] branches/blender2.5/blender/source /blender/makesrna: RNA: made naming of animateable flags for properties more clear.
Revision: 18550 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18550 Author: blendix Date: 2009-01-17 14:54:56 +0100 (Sat, 17 Jan 2009) Log Message: --- RNA: made naming of animateable flags for properties more clear. Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/RNA_access.h branches/blender2.5/blender/source/blender/makesrna/RNA_types.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_scene.c Modified: branches/blender2.5/blender/source/blender/makesrna/RNA_access.h === --- branches/blender2.5/blender/source/blender/makesrna/RNA_access.h 2009-01-17 05:36:58 UTC (rev 18549) +++ branches/blender2.5/blender/source/blender/makesrna/RNA_access.h 2009-01-17 13:54:56 UTC (rev 18550) @@ -327,12 +327,12 @@ int RNA_property_enum_value(PointerRNA *ptr, PropertyRNA *prop, const char *identifier, int *value); int RNA_property_enum_identifier(PointerRNA *ptr, PropertyRNA *prop, const int value, const char **identifier); - const char *RNA_property_ui_name(PointerRNA *ptr, PropertyRNA *prop); const char *RNA_property_ui_description(PointerRNA *ptr, PropertyRNA *prop); int RNA_property_editable(PointerRNA *ptr, PropertyRNA *prop); -int RNA_property_evaluated(PointerRNA *ptr, PropertyRNA *prop); +int RNA_property_animateable(PointerRNA *ptr, PropertyRNA *prop); +int RNA_property_animated(PointerRNA *ptr, PropertyRNA *prop); void RNA_property_update(struct bContext *C, PointerRNA *ptr, PropertyRNA *prop); Modified: branches/blender2.5/blender/source/blender/makesrna/RNA_types.h === --- branches/blender2.5/blender/source/blender/makesrna/RNA_types.h 2009-01-17 05:36:58 UTC (rev 18549) +++ branches/blender2.5/blender/source/blender/makesrna/RNA_types.h 2009-01-17 13:54:56 UTC (rev 18550) @@ -72,18 +72,15 @@ typedef enum PropertyFlag { /* editable means the property is editable in the user -* interface, evaluated means that the property is set -* as part of an evaluation. these can change at runtime -* the property flag contains the default. editable is -* enabled by default except for collections. */ +* interface, properties are editable by default except +* for pointers and collections. */ PROP_NOT_EDITABLE = 1, - PROP_EVALUATED = 2, - /* driveable means the property can be driven by some + /* animateable means the property can be driven by some * other input, be it animation curves, expressions, .. -* in other words making the property evaluated. -* enable by default except for pointers and collections. */ - PROP_NOT_DRIVEABLE = 4, +* properties are animateable by default except for pointers +* and collections */ + PROP_NOT_ANIMATEABLE = 2, #if 0 /* for pointers and collections, means that the struct Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c 2009-01-17 05:36:58 UTC (rev 18549) +++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_access.c 2009-01-17 13:54:56 UTC (rev 18550) @@ -511,20 +511,30 @@ return !(flag PROP_NOT_EDITABLE); } -int RNA_property_evaluated(PointerRNA *ptr, PropertyRNA *prop) +int RNA_property_animateable(PointerRNA *ptr, PropertyRNA *prop) { int flag; rna_idproperty_check(prop, ptr); + if(prop-flag PROP_NOT_ANIMATEABLE) + return 0; + if(prop-editable) flag= prop-editable(ptr); else flag= prop-flag; - return (flag PROP_EVALUATED); + return !(flag PROP_NOT_EDITABLE); } +int RNA_property_animated(PointerRNA *ptr, PropertyRNA *prop) +{ + /* would need to ask animation system */ + + return 0; +} + void RNA_property_update(struct bContext *C, PointerRNA *ptr, PropertyRNA *prop) { rna_idproperty_check(prop, ptr); Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c 2009-01-17 05:36:58 UTC (rev 18549) +++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c 2009-01-17 13:54:56 UTC (rev 18550) @@ -668,7 +668,7 @@ prop-description= ; if(type == PROP_COLLECTION || type == PROP_POINTER) - prop-flag= PROP_NOT_EDITABLE|PROP_NOT_DRIVEABLE; +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18552] branches/blender2.5/blender/source /blender/makesrna/intern/makesrna.c: RNA: warning fix for mac gcc.
Revision: 18552 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18552 Author: blendix Date: 2009-01-17 16:28:34 +0100 (Sat, 17 Jan 2009) Log Message: --- RNA: warning fix for mac gcc. Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-01-17 14:56:12 UTC (rev 18551) +++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-01-17 15:28:34 UTC (rev 18552) @@ -176,6 +176,26 @@ return 0; } +static const char *rna_function_string(void *func) +{ + return (func)? (const char*)func: NULL; +} + +static void rna_float_print(FILE *f, float num) +{ + if(num == -FLT_MAX) fprintf(f, -FLT_MAX); + else if(num == FLT_MAX) fprintf(f, FLT_MAX); + else if((int)num == num) fprintf(f, %.1ff, num); + else fprintf(f, %.10ff, num); +} + +static void rna_int_print(FILE *f, int num) +{ + if(num == INT_MIN) fprintf(f, INT_MIN); + else if(num == INT_MAX) fprintf(f, INT_MAX); + else fprintf(f, %d, num); +} + static char *rna_def_property_get_func(FILE *f, StructRNA *srna, PropertyRNA *prop, PropertyDefRNA *dp) { char *func; @@ -219,8 +239,11 @@ fprintf(f, return (%s)%s((data-%s)[index]);\n, rna_type_type(prop), (dp-booleannegative)? !: , dp-dnaname); } else { - if(prop-type == PROP_BOOLEAN dp-booleanbit) - fprintf(f, return (%s(data-%s[index] %d) != 0);\n, (dp-booleannegative)? !: , dp-dnaname, dp-booleanbit); + if(prop-type == PROP_BOOLEAN dp-booleanbit) { + fprintf(f, return (%s(data-%s[index] , (dp-booleannegative)? !: , dp-dnaname); + rna_int_print(f, dp-booleanbit); + fprintf(f, ) != 0);\n); + } else if(rna_color_quantize(prop, dp)) fprintf(f, return (%s)(data-%s[index]/255.0f);\n, rna_type_type(prop), dp-dnaname); else @@ -232,10 +255,16 @@ fprintf(f, static %s %s(PointerRNA *ptr)\n, rna_type_type(prop), func); fprintf(f, {\n); rna_print_data_get(f, dp); - if(prop-type == PROP_BOOLEAN dp-booleanbit) - fprintf(f, return (%s((data-%s) %d) != 0);\n, (dp-booleannegative)? !: , dp-dnaname, dp-booleanbit); - else if(prop-type == PROP_ENUM dp-enumbitflags) - fprintf(f, return ((data-%s) %d);\n, dp-dnaname, rna_enum_bitmask(prop)); + if(prop-type == PROP_BOOLEAN dp-booleanbit) { + fprintf(f, return (%s((data-%s) , (dp-booleannegative)? !: , dp-dnaname); + rna_int_print(f, dp-booleanbit); + fprintf(f, ) != 0);\n); + } + else if(prop-type == PROP_ENUM dp-enumbitflags) { + fprintf(f, return ((data-%s) , dp-dnaname); + rna_int_print(f, rna_enum_bitmask(prop)); + fprintf(f, );\n); + } else if(prop-type == PROP_POINTER dp-dnapointerlevel == 0) fprintf(f, return (%s)(data-%s);\n, rna_type_type(prop), dp-dnaname); else @@ -248,26 +277,6 @@ return func; } -static const char *rna_function_string(void *func) -{ - return (func)? (const char*)func: NULL; -} - -static void rna_float_print(FILE *f, float num) -{ - if(num == -FLT_MAX) fprintf(f, -FLT_MAX); - else if(num == FLT_MAX) fprintf(f, FLT_MAX); - else if((int)num == num) fprintf(f, %.1ff, num); - else fprintf(f, %.10ff, num); -} - -static void rna_int_print(FILE *f, int num) -{ - if(num == INT_MIN) fprintf(f, INT_MIN); - else if(num == INT_MAX) fprintf(f, INT_MAX); - else fprintf(f, %d, num); -} - static void rna_clamp_value(FILE *f, PropertyRNA *prop) { if(prop-type == PROP_INT) { @@ -334,8 +343,12 @@
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18556] branches/blender2.5/blender/source /blender: 2.5: uv editor
Revision: 18556 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18556 Author: blendix Date: 2009-01-17 23:14:08 +0100 (Sat, 17 Jan 2009) Log Message: --- 2.5: uv editor - mouse select, loop select, select linked, unlink selection operators. - added edge selection mode. - fix 2.45 bug with unitialized theme colors, which caused the active face and face centers to be not drawn. Modified Paths: -- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c branches/blender2.5/blender/source/blender/editors/interface/resources.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_draw.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_intern.h branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/makesdna/DNA_scene_types.h branches/blender2.5/blender/source/blender/windowmanager/intern/wm_files.c Modified: branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c === --- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-17 18:35:33 UTC (rev 18555) +++ branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-17 22:14:08 UTC (rev 18556) @@ -8492,8 +8492,12 @@ do_versions_windowmanager_2_50(screen); /* struct audio data moved to renderdata */ - for(scene= main-scene.first; scene; scene= scene-id.next) + for(scene= main-scene.first; scene; scene= scene-id.next) { scene-r.audio = scene-audio; + + if(!scene-toolsettings-uv_selectmode) + scene-toolsettings-uv_selectmode= UV_SELECT_VERTEX; + } /* shader, composit and texture node trees have id.name empty, put something in * to have them show in RNA viewer and accessible otherwise. @@ -8501,7 +8505,8 @@ for(ma= main-mat.first; ma; ma= ma-id.next) { if(ma-nodetree strlen(ma-nodetree-id.name)==0) strcpy(ma-nodetree-id.name, NTShader Nodetree); - } + } + /* and composit trees */ for(sce= main-scene.first; sce; sce= sce-id.next) { if(sce-nodetree strlen(sce-nodetree-id.name)==0) Modified: branches/blender2.5/blender/source/blender/editors/interface/resources.c === --- branches/blender2.5/blender/source/blender/editors/interface/resources.c 2009-01-17 18:35:33 UTC (rev 18555) +++ branches/blender2.5/blender/source/blender/editors/interface/resources.c 2009-01-17 22:14:08 UTC (rev 18556) @@ -511,8 +511,10 @@ SETCOL(btheme-tima.vertex, 0xff, 0x70, 0xff, 255); SETCOL(btheme-tima.vertex_select, 0xff, 0xff, 0x70, 255); btheme-tima.vertex_size= 2; + btheme-tima.facedot_size= 2; SETCOL(btheme-tima.face, 0, 50, 150, 40); SETCOL(btheme-tima.face_select, 200, 100, 200, 80); + SETCOL(btheme-tima.editmesh_active, 255, 255, 255, 128); /* space imageselect */ btheme-timasel= btheme-tv3d; Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_header.c === --- branches/blender2.5/blender/source/blender/editors/space_image/image_header.c 2009-01-17 18:35:33 UTC (rev 18555) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_header.c 2009-01-17 22:14:08 UTC (rev 18556) @@ -223,12 +223,6 @@ case 8: /* Border Select Pinned */ borderselect_sima(UV_SELECT_PINNED); break; - case 2: /* Unlink Selection */ - unlink_selection(); - break; - case 3: /* Linked UVs */ - select_linked_tface_uv(2); - break; case 7: /* Pinned UVs */ select_pinned_tface_uv(); break; @@ -1207,9 +1201,11 @@ uiBlockBeginAlign(block); uiDefIconButBitS(block, TOG, SCE_SELECT_VERTEX, B_REDR, ICON_VERTEXSEL, - xco,yco,XIC,YIC, scene-selectmode, 1.0, 0.0, 0, 0, Vertex select mode (Ctrl Tab 1)); + xco,yco,XIC,YIC, scene-selectmode, 1.0, 0.0, 0, 0, Vertex select mode); + uiDefIconButBitS(block, TOG, SCE_SELECT_EDGE, B_REDR, ICON_EDGESEL, +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18597] branches/blender2.5/blender/source /blender: 2.5: WIP commit for WM compositing.
Revision: 18597 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18597 Author: blendix Date: 2009-01-20 22:55:48 +0100 (Tue, 20 Jan 2009) Log Message: --- 2.5: WIP commit for WM compositing. * Drawing code from wm_event_system.c split into separate wm_draw.c file. Now there's 3 different draw methods implemented, not sure what survives or will be added but is useful for debugging. * Draw All: redraws everything each time, for reference. * Draw Overlap All: what the code did before this commit, only draw regions marked for redraw, and anything that overlaps them. * Triple Buffer: copies/retores all area regions into a texture, and blits that before drawing. Menus, brushes, gestures, etc are redrawn always on top of that. Currently Draw Overlap All is set hardcoded to be used still. Triple Buffer code is not complete, it doesn't handle window resize yet. Cards that don't support non power of two textures can need quite large textures as well, this could be split into multiple smaller ones. Modified Paths: -- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/screen/area.c branches/blender2.5/blender/source/blender/editors/screen/screen_edit.c branches/blender2.5/blender/source/blender/gpu/GPU_extensions.h branches/blender2.5/blender/source/blender/makesdna/DNA_windowmanager_types.h branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c Added Paths: --- branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c Modified: branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c === --- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-20 20:44:36 UTC (rev 18596) +++ branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-20 21:55:48 UTC (rev 18597) @@ -3999,6 +3999,9 @@ win-queue.first= win-queue.last= NULL; win-handlers.first= win-handlers.last= NULL; win-subwindows.first= win-subwindows.last= NULL; + + win-drawtex= 0; + win-drawmethod= 0; } wm-operators.first= wm-operators.last= NULL; @@ -4448,6 +4451,7 @@ ar-headerstr= NULL; ar-swinid= 0; ar-type= NULL; + ar-swap= 0; } /* for the saved 2.50 files without regiondata */ Modified: branches/blender2.5/blender/source/blender/editors/include/ED_screen.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_screen.h 2009-01-20 20:44:36 UTC (rev 18596) +++ branches/blender2.5/blender/source/blender/editors/include/ED_screen.h 2009-01-20 21:55:48 UTC (rev 18597) @@ -55,7 +55,7 @@ void ED_spacetypes_keymap(struct wmWindowManager *wm); intED_area_header_standardbuttons(const struct bContext *C, struct uiBlock *block, int yco); void ED_area_overdraw(struct bContext *C); -void ED_area_overdraw_flush(struct bContext *C); +void ED_area_overdraw_flush(struct bContext *C, struct ScrArea *sa, struct ARegion *ar); /* areas */ Modified: branches/blender2.5/blender/source/blender/editors/screen/area.c === --- branches/blender2.5/blender/source/blender/editors/screen/area.c 2009-01-20 20:44:36 UTC (rev 18596) +++ branches/blender2.5/blender/source/blender/editors/screen/area.c 2009-01-20 21:55:48 UTC (rev 18597) @@ -143,28 +143,18 @@ /* based on screen region draw tags, set draw tags in azones, and future region tabs etc */ /* only exported for WM */ -void ED_area_overdraw_flush(bContext *C) +void ED_area_overdraw_flush(bContext *C, ScrArea *sa, ARegion *ar) { - ScrArea *sa; + AZone *az; - for(sa= CTX_wm_screen(C)-areabase.first; sa; sa= sa-next) { - ARegion *ar; - - for(ar= sa-regionbase.first; ar; ar= ar-next) { - if(ar-do_draw) { - AZone *az; - - for(az= sa-actionzones.first; az; az= az-next) { - int xs= (az-x1+az-x2)/2, ys= (az-y1+az-y2)/2; - - /* test if inside */ - if(BLI_in_rcti(ar-winrct, xs, ys)) { - az-do_draw= 1; - } - } - } + for(az= sa-actionzones.first; az; az= az-next) { + int xs= (az-x1+az-x2)/2, ys= (az-y1+az-y2)/2; +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18632] branches/blender2.5/blender/source /blender: 2.5: WM Compositing
Revision: 18632 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18632 Author: blendix Date: 2009-01-23 04:52:52 +0100 (Fri, 23 Jan 2009) Log Message: --- 2.5: WM Compositing * Triple Buffer is now more complete: - Proper handling of window resize, duplicate, etc. - It now uses 3x3 textures (or less) if the power of two sizes do not match well. That still has a worst case wast of 23.4%, but better than 300%. - It can also use the ARB/NV/EXT_texture_rectangle extension now, which may be supported on hardware that does not support ARB_texture_non_power_of_two. - Gesture, menu and brushe redraws now require no redraws at all from the area regions. So even on a high poly scene just moving the paint cursor or opening a menu should be fast. * Testing can be done by setting the Window Draw Method in the User Preferences in the outliner. Overlap is still default, since Triple Buffer has not been tested on computers other than mine, would like to avoid crashing Blender on startup in case there is a common bug, but it's ready for testing now. - For reference Full draws the full window each time. - Triple Buffer should work for both swap copy and swap exchange systems, the latter still need the -E command line option for Overlap. - Resizing and going fullscreen still gives flicker here but no more than Full drawing. * Partial Redraw was added. ED_region_tag_redraw_partial takes a rect in window coordinates to define a subarea of the region. On region draw it will then set glScissor to a smaller area, and ar-drawrct will always be set to either the partial or full window rect. The latter can then be used for clipping in the 3D view or clipping interface drawing. Neither is implemented yet. Modified Paths: -- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/screen/area.c branches/blender2.5/blender/source/blender/makesdna/DNA_screen_types.h branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h branches/blender2.5/blender/source/blender/makesdna/DNA_windowmanager_types.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_userdef.c branches/blender2.5/blender/source/blender/windowmanager/WM_api.h branches/blender2.5/blender/source/blender/windowmanager/intern/wm.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_event_system.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_gesture.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_subwindow.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_window.c branches/blender2.5/blender/source/blender/windowmanager/wm_event_system.h Added Paths: --- branches/blender2.5/blender/source/blender/windowmanager/wm_draw.h Modified: branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c === --- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-23 03:41:05 UTC (rev 18631) +++ branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2009-01-23 03:52:52 UTC (rev 18632) @@ -4007,8 +4007,9 @@ win-handlers.first= win-handlers.last= NULL; win-subwindows.first= win-subwindows.last= NULL; - win-drawtex= 0; - win-drawmethod= 0; + win-drawdata= NULL; + win-drawmethod= -1; + win-drawfail= 0; } wm-operators.first= wm-operators.last= NULL; @@ -4459,6 +4460,8 @@ ar-swinid= 0; ar-type= NULL; ar-swap= 0; + ar-do_draw= 0; + memset(ar-drawrct, 0, sizeof(ar-drawrct)); } /* for the saved 2.50 files without regiondata */ @@ -4497,6 +4500,7 @@ sc-context= NULL; sc-mainwin= sc-subwinactive= 0; /* indices */ + sc-swap= 0; /* hacky patch... but people have been saving files with the verse-blender, causing the handler to keep running for ever, with no means to disable it */ Modified: branches/blender2.5/blender/source/blender/editors/include/ED_screen.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_screen.h 2009-01-23 03:41:05 UTC (rev 18631) +++ branches/blender2.5/blender/source/blender/editors/include/ED_screen.h 2009-01-23 03:52:52 UTC (rev 18632)
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18637] branches/blender2.5/blender/source /blender: 2.5: multiple small fixes
Revision: 18637 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18637 Author: blendix Date: 2009-01-23 21:36:47 +0100 (Fri, 23 Jan 2009) Log Message: --- 2.5: multiple small fixes - wm draw method is now initialized correct when reading older files, but the SDNA bug causing the problem is still unsolved. is due to // char pad[8]; not being recognized as commented. - triple buffer proxy texture test follows spec better now, was disabling triple buffer unnecessarily on some drivers. - some cmake compile fixes related to sequencer pthread usage and removed bad level calls lib for player. - show outliner header buttons in oops mode as well until that can be switched in the UI. - fix region data free issue for tooltips - warning fixes Modified Paths: -- branches/blender2.5/blender/source/blender/blenkernel/BKE_mesh.h branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt branches/blender2.5/blender/source/blender/blenkernel/intern/exotic.c branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c branches/blender2.5/blender/source/blender/blenkernel/intern/multires.c branches/blender2.5/blender/source/blender/blenkernel/intern/screen.c branches/blender2.5/blender/source/blender/blenlib/intern/arithb.c branches/blender2.5/blender/source/blender/blenlib/intern/graph.c branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/space_outliner/outliner_header.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/gpu/GPU_draw.h branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h branches/blender2.5/blender/source/blender/makesrna/intern/rna_constraint.c branches/blender2.5/blender/source/blender/python/intern/bpy_rna.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_files.c Modified: branches/blender2.5/blender/source/blender/blenkernel/BKE_mesh.h === --- branches/blender2.5/blender/source/blender/blenkernel/BKE_mesh.h 2009-01-23 17:42:36 UTC (rev 18636) +++ branches/blender2.5/blender/source/blender/blenkernel/BKE_mesh.h 2009-01-23 20:36:47 UTC (rev 18637) @@ -39,6 +39,7 @@ struct MDeformVert; struct Mesh; struct MFace; +struct MEdge; struct MVert; struct MCol; struct Object; Modified: branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt === --- branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt 2009-01-23 17:42:36 UTC (rev 18636) +++ branches/blender2.5/blender/source/blender/blenkernel/CMakeLists.txt 2009-01-23 20:36:47 UTC (rev 18637) @@ -56,18 +56,12 @@ ADD_DEFINITIONS(-DWITH_FFMPEG) ENDIF(WITH_FFMPEG) -IF(WITH_PLAYER) - SUBDIRS(bad_level_call_stubs) -ENDIF(WITH_PLAYER) - IF(WITH_PYTHON) SET(INC ${INC} ../python ${PYTHON_INC}) ELSE(WITH_PYTHON) ADD_DEFINITIONS(-DDISABLE_PYTHON) ENDIF(WITH_PYTHON) -BLENDERLIB(bf_blenkernel ${SRC} ${INC}) - IF(WITH_INTERNATIONAL) ADD_DEFINITIONS(-DWITH_FREETYPE2) ENDIF(WITH_INTERNATIONAL) @@ -75,3 +69,10 @@ IF(NOT WITH_ELBEEM) ADD_DEFINITIONS(-DDISABLE_ELBEEM) ENDIF(NOT WITH_ELBEEM) + +IF(WIN32) + SET(INC ${INC} ${PTHREADS_INC}) +ENDIF(WIN32) + +BLENDERLIB(bf_blenkernel ${SRC} ${INC}) + Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/exotic.c === --- branches/blender2.5/blender/source/blender/blenkernel/intern/exotic.c 2009-01-23 17:42:36 UTC (rev 18636) +++ branches/blender2.5/blender/source/blender/blenkernel/intern/exotic.c 2009-01-23 20:36:47 UTC (rev 18637) @@ -2387,7 +2387,7 @@ static void write_videoscape_mesh(Scene *scene, Object *ob, char *str) { - Mesh *me; + Mesh *me= ob-data; EditMesh *em = me-edit_mesh; Material *ma; MFace *mface; Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c === --- branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c 2009-01-23 17:42:36 UTC (rev 18636) +++ branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c 2009-01-23 20:36:47 UTC (rev 18637) @@ -215,7 +215,7 @@ /*first check if the array buffer size has room*/ /*if newlen is 200 chars less then totallen, reallocate anyway*/ if (newlen = prop-totallen prop-totallen - newlen 200) { - idp_resize_group_array(prop, newlen, newarr); + idp_resize_group_array(prop, newlen, prop-data.pointer); prop-len =
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18701] trunk/blender/source/blender/src/ editface.c: Fix for bug #18066: made UV Unwrap Reset same as the default UV
Revision: 18701 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18701 Author: blendix Date: 2009-01-27 20:59:12 +0100 (Tue, 27 Jan 2009) Log Message: --- Fix for bug #18066: made UV Unwrap Reset same as the default UV coordinates when creating a new layer. Modified Paths: -- trunk/blender/source/blender/src/editface.c Modified: trunk/blender/source/blender/src/editface.c === --- trunk/blender/source/blender/src/editface.c 2009-01-27 19:32:44 UTC (rev 18700) +++ trunk/blender/source/blender/src/editface.c 2009-01-27 19:59:12 UTC (rev 18701) @@ -631,15 +631,15 @@ dy= 1.0-size; uv[0][0]= 0; - uv[0][1]= size+dy; + uv[0][1]= dy; - uv[1][0]= 0; + uv[1][0]= size; uv[1][1]= dy; uv[2][0]= size; - uv[2][1]= dy; - - uv[3][0]= size; + uv[2][1]= size+dy; + + uv[3][0]= 0; uv[3][1]= size+dy; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18702] trunk/blender/source/blender/src/ header_buttonswin.c: Fix for bug #17961: crash with material copy/ past and GLSL.
Revision: 18702 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18702 Author: blendix Date: 2009-01-27 21:17:32 +0100 (Tue, 27 Jan 2009) Log Message: --- Fix for bug #17961: crash with material copy/past and GLSL. Modified Paths: -- trunk/blender/source/blender/src/header_buttonswin.c Modified: trunk/blender/source/blender/src/header_buttonswin.c === --- trunk/blender/source/blender/src/header_buttonswin.c2009-01-27 19:59:12 UTC (rev 18701) +++ trunk/blender/source/blender/src/header_buttonswin.c2009-01-27 20:17:32 UTC (rev 18702) @@ -77,6 +77,8 @@ #include MEM_guardedalloc.h #include BLI_blenlib.h +#include GPU_material.h + #include blendef.h #include mydevice.h #include butspace.h @@ -168,6 +170,7 @@ } matcopybuf.nodetree= ntreeCopyTree(ma-nodetree, 0); matcopybuf.preview= NULL; + matcopybuf.gpumaterial.first= matcopybuf.gpumaterial.last= NULL; matcopied= 1; } break; @@ -188,6 +191,8 @@ ntreeFreeTree(ma-nodetree); MEM_freeN(ma-nodetree); } + + GPU_materials_free(ma); id= (ma-id); memcpy(ma, matcopybuf, sizeof(Material)); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18703] trunk/blender/source/blender/ python/api2_2x/Constraint.c: Fix for bug #18183: crash when using Bake Constraints script.
Revision: 18703 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18703 Author: blendix Date: 2009-01-27 22:19:19 +0100 (Tue, 27 Jan 2009) Log Message: --- Fix for bug #18183: crash when using Bake Constraints script. The constraint remove function was not working correct, this code uses a pretty bad hack, did not clean it up, but at least it should work now. Modified Paths: -- trunk/blender/source/blender/python/api2_2x/Constraint.c Modified: trunk/blender/source/blender/python/api2_2x/Constraint.c === --- trunk/blender/source/blender/python/api2_2x/Constraint.c2009-01-27 20:17:32 UTC (rev 18702) +++ trunk/blender/source/blender/python/api2_2x/Constraint.c2009-01-27 21:19:19 UTC (rev 18703) @@ -2291,6 +2291,7 @@ { bConstraint *con = locate_constr(self, value); bPoseChannel *active= NULL; + int tmpflag= 0; /* if we can't locate the constraint, return (exception already set) */ if (!con) @@ -2304,6 +2305,11 @@ if (active) active-bone-flag = ~BONE_ACTIVE; self-pchan-bone-flag |= BONE_ACTIVE; } + + if(!(self-obj-flag OB_POSEMODE)) { + self-obj-flag |= OB_POSEMODE; + tmpflag= 1; + } } /* del_constr_func() frees constraint + its data */ @@ -2314,6 +2320,8 @@ if (active) active-bone-flag |= BONE_ACTIVE; self-pchan-bone-flag = ~BONE_ACTIVE; } + if(tmpflag) + self-obj-flag = ~OB_POSEMODE; /* erase the link to the constraint */ value-con = NULL; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18704] trunk/blender/source/blender/ python/api2_2x/Constraint.c: Fix for bug #18167: setting Constraint. Settings.SCRIPT checked for type
Revision: 18704 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18704 Author: blendix Date: 2009-01-27 22:26:31 +0100 (Tue, 27 Jan 2009) Log Message: --- Fix for bug #18167: setting Constraint.Settings.SCRIPT checked for type Object rather than Text so did not work when assigning a text to it. Modified Paths: -- trunk/blender/source/blender/python/api2_2x/Constraint.c Modified: trunk/blender/source/blender/python/api2_2x/Constraint.c === --- trunk/blender/source/blender/python/api2_2x/Constraint.c2009-01-27 21:19:19 UTC (rev 18703) +++ trunk/blender/source/blender/python/api2_2x/Constraint.c2009-01-27 21:26:31 UTC (rev 18704) @@ -1560,7 +1560,7 @@ break; case EXPP_CONSTR_SCRIPT: { Text *text = (( BPy_Text * )value)-text; - if( !BPy_Object_Check( value ) ) + if( !BPy_Text_Check( value ) ) return EXPP_ReturnIntError( PyExc_TypeError, expected BPy text argument ); con-text = text; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18705] trunk/blender/source/blender/src/ buttons_editing.c: Fix for bug #18087: Editing of object name and modifiers did not
Revision: 18705 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18705 Author: blendix Date: 2009-01-27 23:09:23 +0100 (Tue, 27 Jan 2009) Log Message: --- Fix for bug #18087: Editing of object name and modifiers did not work in editing buttons if the object data was linked. Modified Paths: -- trunk/blender/source/blender/src/buttons_editing.c Modified: trunk/blender/source/blender/src/buttons_editing.c === --- trunk/blender/source/blender/src/buttons_editing.c 2009-01-27 21:26:31 UTC (rev 18704) +++ trunk/blender/source/blender/src/buttons_editing.c 2009-01-27 22:09:23 UTC (rev 18705) @@ -1944,13 +1944,14 @@ uiButSetFunc(but, modifiers_applyModifier, ob, md); } + uiClearButLock(); + uiSetButLock(ob ob-id.lib, ERROR_LIBDATA_MESSAGE); + if (md-type!=eModifierType_Fluidsim md-type!=eModifierType_Softbody md-type!=eModifierType_ParticleSystem (md-type!=eModifierType_Cloth)) { but = uiDefBut(block, BUT, B_MODIFIER_RECALC, Copy, lx,(cy-=19),60,19, 0, 0, 0, 0, 0, Duplicate the current modifier at the same position in the stack); uiButSetFunc(but, modifiers_copyModifier, ob, md); } uiBlockEndAlign(block); - - uiSetButLock(ob ob-id.lib, ERROR_LIBDATA_MESSAGE); } lx = x + 10; @@ -5525,7 +5526,6 @@ uiBlockSetCol(block, TH_AUTO); } if(ob) { - uiSetButLock(object_data_is_libdata(ob), ERROR_LIBDATA_MESSAGE); but = uiDefBut(block, TEX, B_IDNAME, OB:, xco, 180, 454-xco, YIC, ob-id.name+2, 0.0, 21.0, 0, 0, Active Object name.); #ifdef WITH_VERSE if(ob-vnode) uiButSetFunc(but, test_and_send_idbutton_cb, ob, ob-id.name); @@ -5534,6 +5534,7 @@ uiButSetFunc(but, test_idbutton_cb, ob-id.name, NULL); #endif + uiSetButLock(object_data_is_libdata(ob), ERROR_LIBDATA_MESSAGE); } /* empty display handling, note it returns! */ ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18721] branches/blender2.5/blender/source /blender: 2.5:
Revision: 18721 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18721 Author: blendix Date: 2009-01-28 20:42:49 +0100 (Wed, 28 Jan 2009) Log Message: --- 2.5: * Fix using enter key for selecting item in a submenu. * Fix some non working buttons in nodes. * Fix memory leak when using glsl. * Change triple buffer proxy test a bit, hopefully this succeeds on more cards now. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_init_exit.c Modified: branches/blender2.5/blender/source/blender/editors/interface/interface.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface.c 2009-01-28 18:36:55 UTC (rev 18720) +++ branches/blender2.5/blender/source/blender/editors/interface/interface.c 2009-01-28 19:42:49 UTC (rev 18721) @@ -433,8 +433,8 @@ if(but-rnaprop != oldbut-rnaprop) if(but-rnaindex != oldbut-rnaindex) return 0; if(but-func != oldbut-func) return 0; - if(but-func_arg1 != oldbut-func_arg1) return 0; - if(but-func_arg2 != oldbut-func_arg2) return 0; + if(oldbut-func_arg1 != oldbut but-func_arg1 != oldbut-func_arg1) return 0; + if(oldbut-func_arg2 != oldbut but-func_arg2 != oldbut-func_arg2) return 0; return 1; } Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c 2009-01-28 18:36:55 UTC (rev 18720) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c 2009-01-28 19:42:49 UTC (rev 18721) @@ -157,7 +157,52 @@ static int ui_handler_region_menu(bContext *C, wmEvent *event, void *userdata); static int ui_handler_popup(bContext *C, wmEvent *event, void *userdata); static void ui_handler_remove_popup(bContext *C, void *userdata); +static void ui_handle_button_activate(bContext *C, ARegion *ar, uiBut *but, uiButtonActivateType type); +/* menu navigation helpers ** */ + +static uiBut *ui_but_prev(uiBut *but) +{ + while(but-prev) { + but= but-prev; + if(but-type!=LABEL but-type!=SEPR but-type!=ROUNDBOX) return but; + } + return NULL; +} + +static uiBut *ui_but_next(uiBut *but) +{ + while(but-next) { + but= but-next; + if(but-type!=LABEL but-type!=SEPR but-type!=ROUNDBOX) return but; + } + return NULL; +} + +static uiBut *ui_but_first(uiBlock *block) +{ + uiBut *but; + + but= block-buttons.first; + while(but) { + if(but-type!=LABEL but-type!=SEPR but-type!=ROUNDBOX) return but; + but= but-next; + } + return NULL; +} + +static uiBut *ui_but_last(uiBlock *block) +{ + uiBut *but; + + but= block-buttons.last; + while(but) { + if(but-type!=LABEL but-type!=SEPR but-type!=ROUNDBOX) return but; + but= but-prev; + } + return NULL; +} + /* ** button apply/revert / static ListBase UIAfterFuncs = {NULL, NULL}; @@ -2892,8 +2937,23 @@ button_activate_state(C, but, BUTTON_STATE_HIGHLIGHT); - if(type == BUTTON_ACTIVATE_OPEN) + if(type == BUTTON_ACTIVATE_OPEN) { button_activate_state(C, but, BUTTON_STATE_MENU_OPEN); + + /* activate first button in submenu */ + if(data-menu data-menu-region) { + ARegion *subar= data-menu-region; + uiBlock *subblock= subar-uiblocks.first; + uiBut *subbut; + + if(subblock) { + subbut= ui_but_first(subblock); + + if(subbut) + ui_handle_button_activate(C, subar, subbut, BUTTON_ACTIVATE); + } + } + } else if(type == BUTTON_ACTIVATE_TEXT_EDITING) button_activate_state(C, but, BUTTON_STATE_TEXT_EDITING); else if(type == BUTTON_ACTIVATE_APPLY) @@ -3155,50 +3215,6 @@ } } -/* menu navigation helpers ** */ - -static uiBut *ui_but_prev(uiBut *but) -{ - while(but-prev) { - but= but-prev; - if(but-type!=LABEL but-type!=SEPR but-type!=ROUNDBOX) return but; - } - return NULL; -} - -static uiBut *ui_but_next(uiBut *but)
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18722] branches/blender2.5/blender/source /blender: 2.5:
Revision: 18722 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18722 Author: blendix Date: 2009-01-28 22:43:43 +0100 (Wed, 28 Jan 2009) Log Message: --- 2.5: * UV Editor Transform, translate, rotate, scale, live unwrap, snap, gesture, etc work. * Also for selection operators, used OPERATOR_FINISHED|OPERATOR_PASS_THROUGH instead of just OPERATOR_PASS_THROUGH to make gestures work, seems more correct to me. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/include/ED_uvedit.h branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/space_ipo/ipo_select.c branches/blender2.5/blender/source/blender/editors/space_node/node_select.c branches/blender2.5/blender/source/blender/editors/transform/transform.c branches/blender2.5/blender/source/blender/editors/transform/transform_conversions.c branches/blender2.5/blender/source/blender/editors/transform/transform_generics.c branches/blender2.5/blender/source/blender/editors/transform/transform_ops.c branches/blender2.5/blender/source/blender/editors/transform/transform_snap.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_intern.h branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_unwrap_ops.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_space.c Added Paths: --- branches/blender2.5/blender/source/blender/editors/include/ED_image.h Added: branches/blender2.5/blender/source/blender/editors/include/ED_image.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_image.h (rev 0) +++ branches/blender2.5/blender/source/blender/editors/include/ED_image.h 2009-01-28 21:43:43 UTC (rev 18722) @@ -0,0 +1,39 @@ +/** + * $Id: + * + * * BEGIN GPL LICENSE BLOCK * + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * The Original Code is Copyright (C) 2008 Blender Foundation. + * All rights reserved. + * + * Contributor(s): Blender Foundation + * + * * END GPL LICENSE BLOCK * + */ + +#ifndef ED_IMAGE_H +#define ED_IMAGE_H + +struct SpaceImage; + +/* space_image.c, exported for transform */ +struct Image *ED_space_image(struct SpaceImage *sima); +void ED_space_image_size(struct SpaceImage *sima, int *width, int *height); +void ED_space_image_uv_aspect(struct SpaceImage *sima, float *aspx, float *aspy); + +#endif /* ED_IMAGE_H */ + Modified: branches/blender2.5/blender/source/blender/editors/include/ED_uvedit.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_uvedit.h 2009-01-28 19:42:49 UTC (rev 18721) +++ branches/blender2.5/blender/source/blender/editors/include/ED_uvedit.h 2009-01-28 21:43:43 UTC (rev 18722) @@ -30,6 +30,8 @@ struct Scene; struct Object; +struct MTFace; +struct EditFace; struct Image; struct wmWindowManager; @@ -41,5 +43,20 @@ void ED_uvedit_set_tile(struct Scene *scene, struct Object *obedit, struct Image *ima, int curtile, int dotile); int ED_uvedit_minmax(struct Scene *scene, struct Image *ima, struct Object *obedit, float *min, float *max); +int ED_uvedit_test_silent(struct Object *obedit); +int ED_uvedit_test(struct Object *obedit); + +int uvedit_face_visible(struct Scene *scene, struct Image *ima, struct EditFace *efa, struct MTFace *tf); +int uvedit_face_selected(struct Scene *scene, struct EditFace *efa, struct MTFace *tf); +int uvedit_edge_selected(struct Scene *scene, struct EditFace *efa, struct MTFace *tf, int i); +int uvedit_uv_selected(struct Scene *scene, struct EditFace *efa, struct MTFace *tf, int i); + +int ED_uvedit_nearest_uv(struct Scene *scene, struct Object *obedit, struct Image *ima, float co[2], float uv[2]); + +/* uvedit_unwrap.c */ +void ED_uvedit_live_unwrap_begin(struct Scene *scene, struct
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18725] branches/blender2.5/blender/source /blender: 2.5:
Revision: 18725 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18725 Author: blendix Date: 2009-01-29 00:29:27 +0100 (Thu, 29 Jan 2009) Log Message: --- 2.5: * Automatic shortcut keys in menus now compare operator properties as well. Implemented IDP_EqualsProperties for this. * I imagine all these compares may be a bit slow, for this case it's not so bad though because it only happens for one menu when it is opened. Modified Paths: -- branches/blender2.5/blender/source/blender/blenkernel/BKE_idprop.h branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/windowmanager/WM_api.h branches/blender2.5/blender/source/blender/windowmanager/intern/wm_keymap.c Modified: branches/blender2.5/blender/source/blender/blenkernel/BKE_idprop.h === --- branches/blender2.5/blender/source/blender/blenkernel/BKE_idprop.h 2009-01-28 22:51:42 UTC (rev 18724) +++ branches/blender2.5/blender/source/blender/blenkernel/BKE_idprop.h 2009-01-28 23:29:27 UTC (rev 18725) @@ -142,6 +142,8 @@ struct IDProperty *IDP_GetProperties(struct ID *id, int create_if_needed); struct IDProperty *IDP_CopyProperty(struct IDProperty *prop); +int IDP_EqualsProperties(struct IDProperty *prop1, struct IDProperty *prop2); + /* Allocate a new ID. Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c === --- branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c 2009-01-28 22:51:42 UTC (rev 18724) +++ branches/blender2.5/blender/source/blender/blenkernel/intern/idprop.c 2009-01-28 23:29:27 UTC (rev 18725) @@ -527,6 +527,60 @@ } } +int IDP_EqualsProperties(IDProperty *prop1, IDProperty *prop2) +{ + if(prop1 == NULL prop2 == NULL) + return 1; + else if(prop1 == NULL || prop2 == NULL) + return 0; + else if(prop1-type != prop2-type) + return 0; + + if(prop1-type == IDP_INT) + return (IDP_Int(prop1) == IDP_Int(prop2)); + else if(prop1-type == IDP_FLOAT) + return (IDP_Float(prop1) == IDP_Float(prop2)); + else if(prop1-type == IDP_DOUBLE) + return (IDP_Double(prop1) == IDP_Double(prop2)); + else if(prop1-type == IDP_STRING) + return BSTR_EQ(IDP_String(prop1), IDP_String(prop2)); + else if(prop1-type == IDP_ARRAY) { + if(prop1-len == prop2-len prop1-subtype == prop2-subtype) + return memcmp(IDP_Array(prop1), IDP_Array(prop2), idp_size_table[prop1-subtype]*prop1-len); + else + return 0; + } + else if(prop1-type == IDP_GROUP) { + IDProperty *link1, *link2; + + if(BLI_countlist(prop1-data.group) != BLI_countlist(prop2-data.group)) + return 0; + + for(link1=prop1-data.group.first; link1; link1=link1-next) { + link2= IDP_GetPropertyFromGroup(prop2, link1-name); + + if(!IDP_EqualsProperties(link1, link2)) + return 0; + } + + return 1; + } + else if(prop1-type == IDP_IDPARRAY) { + IDProperty *array1= IDP_IDPArray(prop1); + IDProperty *array2= IDP_IDPArray(prop2); + int i; + + if(prop1-len != prop2-len) + return 0; + + for(i=0; iprop1-len; i++) + if(!IDP_EqualsProperties(array1[i], array2[i])) + return 0; + } + + return 1; +} + IDProperty *IDP_New(int type, IDPropertyTemplate val, const char *name) { IDProperty *prop=NULL; Modified: branches/blender2.5/blender/source/blender/editors/interface/interface.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface.c 2009-01-28 22:51:42 UTC (rev 18724) +++ branches/blender2.5/blender/source/blender/editors/interface/interface.c 2009-01-28 23:29:27 UTC (rev 18725) @@ -482,13 +482,15 @@ static void ui_menu_block_set_keymaps(const bContext *C, uiBlock *block) { uiBut *but; + IDProperty *prop; char buf[512], *butstr; + int bounds= 0;; - /* XXX bounds? */ for(but=block-buttons.first; but; but=but-next) { - /* only hotkey for menus without properties */ - if(but-opname but-opptr==NULL) { - if(WM_key_event_operator_string(C, but-opname,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18726] branches/blender2.5/blender/source /blender/editors/interface: 2.5: fix for issue in last commit, menu bounds were no always
Revision: 18726 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18726 Author: blendix Date: 2009-01-29 00:56:21 +0100 (Thu, 29 Jan 2009) Log Message: --- 2.5: fix for issue in last commit, menu bounds were no always computed correct. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/interface/interface_intern.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c Modified: branches/blender2.5/blender/source/blender/editors/interface/interface.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface.c 2009-01-28 23:29:27 UTC (rev 18725) +++ branches/blender2.5/blender/source/blender/editors/interface/interface.c 2009-01-28 23:56:21 UTC (rev 18726) @@ -207,11 +207,17 @@ /* *** block calc * */ -/* only for pulldowns */ void uiTextBoundsBlock(uiBlock *block, int addval) { + block-textbounds= addval; + block-dotextbounds= 1; +} + +/* only for pulldowns */ +static void ui_text_bounds_block(uiBlock *block) +{ uiBut *bt; - int i = 0, j, x1addval= 0, nextcol; + int i = 0, j, x1addval= 0, nextcol, addval= block-textbounds; bt= block-buttons.first; while(bt) { @@ -505,10 +511,6 @@ } } } - - // XXX not nice .. - if(bounds) - uiTextBoundsBlock(block, 50); } void uiEndBlock(const bContext *C, uiBlock *block) @@ -533,9 +535,12 @@ /* handle pending stuff */ if(block-flag UI_BLOCK_LOOP) ui_menu_block_set_keymaps(C, block); + if(block-dotextbounds) ui_text_bounds_block(block); /* after keymaps! */ if(block-autofill) ui_autofill(block); if(block-minx==0.0 block-maxx==0.0) uiBoundsBlock(block, 0); if(block-flag UI_BUT_ALIGN) uiBlockEndAlign(block); + + block-endblock= 1; } /* ** BLOCK DRAWING FUNCTION * */ @@ -544,6 +549,9 @@ { uiBut *but; + if(!block-endblock) + uiEndBlock(C, block); + /* we set this only once */ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_intern.h === --- branches/blender2.5/blender/source/blender/editors/interface/interface_intern.h 2009-01-28 23:29:27 UTC (rev 18725) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_intern.h 2009-01-28 23:56:21 UTC (rev 18726) @@ -214,7 +214,9 @@ int lock; char *lockstr; - float xofs, yofs; // offset to parent button + float xofs, yofs; // offset to parent button + int textbounds, dotextbounds; // for doing delayed + int endblock; // uiEndBlock done? rctf safety;// pulldowns, to detect outside, can differ per case how it is created ListBase saferct; // uiSafetyRct list Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c 2009-01-28 23:29:27 UTC (rev 18725) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c 2009-01-28 23:56:21 UTC (rev 18726) @@ -651,6 +651,9 @@ block= block_func(C, handle, arg); block-handle= handle; + if(!block-endblock) + uiEndBlock(C, block); + /* if this is being created from a button */ if(but) { if(ELEM(but-type, BLOCK, PULLDOWN)) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18748] branches/blender2.5/blender/source /blender/editors/interface/interface_handlers.c: 2.5: fix mistake in last commit, was crashing menus.
Revision: 18748 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18748 Author: blendix Date: 2009-01-30 13:49:01 +0100 (Fri, 30 Jan 2009) Log Message: --- 2.5: fix mistake in last commit, was crashing menus. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c 2009-01-30 12:18:08 UTC (rev 18747) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c 2009-01-30 12:49:01 UTC (rev 18748) @@ -1431,6 +1431,7 @@ static void ui_blockopen_begin(bContext *C, uiBut *but, uiHandleButtonData *data) { uiBlockCreateFunc func= NULL; + uiBlockHandleCreateFunc handlefunc= NULL; uiMenuCreateFunc menufunc= NULL; void *arg= NULL; @@ -1449,15 +1450,15 @@ data-value= data-origvalue; but-editval= data-value; - func= ui_block_func_MENU; + handlefunc= ui_block_func_MENU; arg= but; break; case ICONROW: - func= ui_block_func_ICONROW; + handlefunc= ui_block_func_ICONROW; arg= but; break; case ICONTEXTROW: - func= ui_block_func_ICONTEXTROW; + handlefunc= ui_block_func_ICONTEXTROW; arg= but; break; case COL: @@ -1465,13 +1466,13 @@ VECCOPY(data-vec, data-origvec); but-editvec= data-vec; - func= ui_block_func_COL; + handlefunc= ui_block_func_COL; arg= but; break; } - if(func) { - data-menu= ui_popup_block_create(C, data-region, but, func, NULL, arg); + if(func || handlefunc) { + data-menu= ui_popup_block_create(C, data-region, but, func, handlefunc, arg); if(but-block-handle) data-menu-popup= but-block-handle-popup; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18749] branches/blender2.5/blender/source /blender/editors/space_image: 2.5: Added simple toolbox menu in image window as a test,
Revision: 18749 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18749 Author: blendix Date: 2009-01-30 13:58:00 +0100 (Fri, 30 Jan 2009) Log Message: --- 2.5: Added simple toolbox menu in image window as a test, can uses same menus as header now since code doesn't depend on being in the header anymore. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_header.c === --- branches/blender2.5/blender/source/blender/editors/space_image/image_header.c 2009-01-30 12:49:01 UTC (rev 18748) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_header.c 2009-01-30 12:58:00 UTC (rev 18749) @@ -1117,3 +1117,38 @@ uiDrawBlock(C, block); } +/** toolbox operator */ + +static int toolbox_invoke(bContext *C, wmOperator *op, wmEvent *event) +{ + SpaceImage *sima= (SpaceImage*)CTX_wm_space_data(C); + Object *obedit= CTX_data_edit_object(C); + uiMenuItem *head; + int show_uvedit; + + show_uvedit= get_space_image_show_uvedit(sima, obedit); + + head= uiPupMenuBegin(Toolbox); + + uiMenuLevel(head, View, image_viewmenu); + if(show_uvedit) uiMenuLevel(head, Select, image_selectmenu); + uiMenuLevel(head, Image, image_imagemenu); + if(show_uvedit) uiMenuLevel(head, UVs, image_uvsmenu); + + uiPupMenuEnd(C, head); + + return OPERATOR_CANCELLED; +} + +void IMAGE_OT_toolbox(wmOperatorType *ot) +{ + /* identifiers */ + ot-name= Toolbox; + ot-idname= IMAGE_OT_toolbox; + + /* api callbacks */ + ot-invoke= toolbox_invoke; + ot-poll= space_image_main_area_poll; +} + + Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h === --- branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h 2009-01-30 12:49:01 UTC (rev 18748) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h 2009-01-30 12:58:00 UTC (rev 18749) @@ -57,10 +57,14 @@ /* image_header.c */ void image_header_buttons(const struct bContext *C, struct ARegion *ar); +void IMAGE_OT_toolbox(struct wmOperatorType *ot); + /* image_draw.c */ void draw_image_main(struct SpaceImage *sima, struct ARegion *ar, struct Scene *scene); /* image_ops.c */ +int space_image_main_area_poll(struct bContext *C); + void IMAGE_OT_view_all(struct wmOperatorType *ot); void IMAGE_OT_view_pan(struct wmOperatorType *ot); void IMAGE_OT_view_selected(struct wmOperatorType *ot); Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c === --- branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c 2009-01-30 12:49:01 UTC (rev 18748) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c 2009-01-30 12:58:00 UTC (rev 18749) @@ -144,7 +144,7 @@ sima_zoom_set(sima, ar, sima-zoom*zoomfac); } -static int space_image_main_area_poll(bContext *C) +int space_image_main_area_poll(bContext *C) { SpaceLink *slink= CTX_wm_space_data(C); ARegion *ar= CTX_wm_region(C); Modified: branches/blender2.5/blender/source/blender/editors/space_image/space_image.c === --- branches/blender2.5/blender/source/blender/editors/space_image/space_image.c 2009-01-30 12:49:01 UTC (rev 18748) +++ branches/blender2.5/blender/source/blender/editors/space_image/space_image.c 2009-01-30 12:58:00 UTC (rev 18749) @@ -146,6 +146,8 @@ WM_operatortype_append(IMAGE_OT_view_zoom_in); WM_operatortype_append(IMAGE_OT_view_zoom_out); WM_operatortype_append(IMAGE_OT_view_zoom_ratio); + + WM_operatortype_append(IMAGE_OT_toolbox); } void image_keymap(struct wmWindowManager *wm) @@ -169,6 +171,8 @@ RNA_float_set(WM_keymap_add_item(keymap, IMAGE_OT_view_zoom_ratio, PAD2, KM_PRESS, 0, 0)-ptr, ratio, 0.5f); RNA_float_set(WM_keymap_add_item(keymap, IMAGE_OT_view_zoom_ratio, PAD4, KM_PRESS, 0, 0)-ptr, ratio, 0.25f); RNA_float_set(WM_keymap_add_item(keymap, IMAGE_OT_view_zoom_ratio, PAD8, KM_PRESS, 0, 0)-ptr, ratio, 0.125f); + + WM_keymap_add_item(keymap, IMAGE_OT_toolbox, SPACEKEY, KM_PRESS, 0, 0); } static void image_refresh(const bContext *C, ScrArea *sa)
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18795] branches/blender2.5/blender/source /blender/editors/mesh/mesh_intern.h: Fix for select multi loop commit, probably missed this file.
Revision: 18795 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18795 Author: blendix Date: 2009-02-02 20:59:22 +0100 (Mon, 02 Feb 2009) Log Message: --- Fix for select multi loop commit, probably missed this file. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/mesh/mesh_intern.h Modified: branches/blender2.5/blender/source/blender/editors/mesh/mesh_intern.h === --- branches/blender2.5/blender/source/blender/editors/mesh/mesh_intern.h 2009-02-02 19:57:57 UTC (rev 18794) +++ branches/blender2.5/blender/source/blender/editors/mesh/mesh_intern.h 2009-02-02 19:59:22 UTC (rev 18795) @@ -192,6 +192,7 @@ void MESH_OT_select_random(struct wmOperatorType *ot); void MESH_OT_vertices_to_sphere(struct wmOperatorType *ot); void MESH_OT_selection_type(struct wmOperatorType *ot); +void MESH_OT_select_multi_loop(struct wmOperatorType *ot); extern EditEdge *findnearestedge(ViewContext *vc, int *dist); extern void EM_automerge(int update); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18809] branches/blender2.5/blender/source /blender: UI
Revision: 18809 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18809 Author: blendix Date: 2009-02-04 12:52:16 +0100 (Wed, 04 Feb 2009) Log Message: --- UI * Changed uiPupMenuOperator usage to uiPupMenuBegin/End (simpler, no need to build a string). Also made transform orientation and subdiv type enums instead of ints for this. * Added an icon argument to many of the uiMenu calls, and added a uiMenuItemIntO. * Move auto rna button creation out of outliner code, now is uiDefAutoButR for individual buttons and uiDefAutoButsRNA for a whole block. * Implemented uiPupBlock(O). Pressing F6 gives a menu with the properties of the last operator to test. I tried to make a redo last operator out of this but couldn't get the context correct for the operator to repeat in. Further the popup block also has some issues getting closed while editing buttons. * Fix uiAfterFunc memory leak on Ctrl+Q quit. * Fix handling of RNA number button dragging and sliding for RNA buttons with range -inf/inf. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/include/BIF_transform.h branches/blender2.5/blender/source/blender/editors/include/ED_util.h branches/blender2.5/blender/source/blender/editors/include/UI_interface.h branches/blender2.5/blender/source/blender/editors/include/UI_resources.h branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c branches/blender2.5/blender/source/blender/editors/interface/interface_intern.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_tools.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c branches/blender2.5/blender/source/blender/editors/transform/transform_ops.c branches/blender2.5/blender/source/blender/editors/transform/transform_orientations.c branches/blender2.5/blender/source/blender/editors/util/undo.c branches/blender2.5/blender/source/blender/windowmanager/intern/wm_operators.c Added Paths: --- branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c Modified: branches/blender2.5/blender/source/blender/editors/include/BIF_transform.h === --- branches/blender2.5/blender/source/blender/editors/include/BIF_transform.h 2009-02-04 11:47:05 UTC (rev 18808) +++ branches/blender2.5/blender/source/blender/editors/include/BIF_transform.h 2009-02-04 11:52:16 UTC (rev 18809) @@ -37,6 +37,7 @@ struct wmEvent; struct bContext; struct Object; +struct uiMenuItem; void transform_keymap_for_space(struct wmWindowManager *wm, struct ListBase *keymap, int spaceid); void transform_operatortypes(void); @@ -113,6 +114,7 @@ void BIF_selectTransformOrientation(struct bContext *C, struct TransformOrientation *ts); void BIF_selectTransformOrientationValue(struct bContext *C, int orientation); +void BIF_menuTransformOrientation(struct bContext *C, struct uiMenuItem *head, void *arg); char * BIF_menustringTransformOrientation(const struct bContext *C, char *title); /* the returned value was allocated and needs to be freed after use */ int BIF_countTransformOrientation(const struct bContext *C); Modified: branches/blender2.5/blender/source/blender/editors/include/ED_util.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_util.h 2009-02-04 11:47:05 UTC (rev 18808) +++ branches/blender2.5/blender/source/blender/editors/include/ED_util.h 2009-02-04 11:52:16 UTC (rev 18809) @@ -44,6 +44,7 @@ /* undo.c */ void ED_undo_push(struct bContext *C, char *str); void ED_undo_push_op (struct bContext *C, struct wmOperator *op); +void ED_undo_pop (struct bContext *C); void ED_OT_undo (struct wmOperatorType *ot); void ED_OT_redo (struct wmOperatorType *ot); Modified: branches/blender2.5/blender/source/blender/editors/include/UI_interface.h === --- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-04 11:47:05 UTC (rev 18808) +++ branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-04 11:52:16 UTC (rev 18809) @@ -210,11 +210,12 @@
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18835] branches/blender2.5/blender/source /blender/editors: 2.5: ID datablock button back, previously known as std_libbuttons.
Revision: 18835 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18835 Author: blendix Date: 2009-02-06 17:40:14 +0100 (Fri, 06 Feb 2009) Log Message: --- 2.5: ID datablock button back, previously known as std_libbuttons. The way this worked in 2.4x wasn't really clean, with events going all over the place and using dubious variables such as G.but-lockpoin or G.sima-menunr. It works as follows now, for example: xco= uiDefIDPoinButs(block, CTX_data_main(C), NULL, (ID**)sima-image, ID_IM, sima-pin, xco, yco, sima_idpoin_handle, UI_ID_BROWSE|UI_ID_RENAME|UI_ID_ADD_NEW|UI_ID_OPEN|UI_ID_DELETE|UI_ID_ALONE|UI_ID_PIN); The last two parameters are a callback function, and a list of events or functionalities that are supported. The callback function will then get the ID pointer + event to handle. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/interface/interface_handlers.c branches/blender2.5/blender/source/blender/editors/interface/interface_intern.h branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/transform/transform_orientations.c Modified: branches/blender2.5/blender/source/blender/editors/include/UI_interface.h === --- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-06 16:38:53 UTC (rev 18834) +++ branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-06 16:40:14 UTC (rev 18835) @@ -33,6 +33,7 @@ /* Struct Declarations */ struct ID; +struct Main; struct ListBase; struct ARegion; struct wmWindow; @@ -395,10 +396,25 @@ * - PickerButtons: buttons like the color picker (for code sharing). * - AutoButR: RNA property button with type automatically defined. */ -typedef void (*uiIDPoinFuncFP)(struct bContext *C, char *str, struct ID **idpp); +#define UI_ID_RENAME 1 +#define UI_ID_BROWSE 2 +#define UI_ID_ADD_NEW 4 +#define UI_ID_OPEN 8 +#define UI_ID_ALONE16 +#define UI_ID_DELETE 32 +#define UI_ID_LOCAL64 +#define UI_ID_AUTO_NAME128 +#define UI_ID_FAKE_USER256 +#define UI_ID_PIN 512 +#define UI_ID_BROWSE_RENDER1024 +#define UI_ID_FULL (UI_ID_RENAME|UI_ID_BROWSE|UI_ID_ADD_NEW|UI_ID_OPEN|UI_ID_ALONE|UI_ID_DELETE|UI_ID_LOCAL) -uiBut *uiDefIDPoinBut(struct uiBlock *block, uiIDPoinFuncFP func, short blocktype, int retval, char *str, +typedef void (*uiIDPoinFuncFP)(struct bContext *C, char *str, struct ID **idpp); +typedef void (*uiIDPoinFunc)(struct bContext *C, struct ID *id, int event); + +uiBut *uiDefIDPoinBut(uiBlock *block, uiIDPoinFuncFP func, short blocktype, int retval, char *str, short x1, short y1, short x2, short y2, void *idpp, char *tip); +int uiDefIDPoinButs(uiBlock *block, struct Main *main, struct ID *parid, struct ID **id_p, int id_code, short *pin_p, int x, int y, uiIDPoinFunc func, int events); uiBut *uiDefPulldownBut(uiBlock *block, uiBlockCreateFunc func, void *arg, char *str, short x1, short y1, short x2, short y2, char *tip); uiBut *uiDefMenuBut(uiBlock *block, uiMenuCreateFunc func, void *arg, char *str, short x1, short y1, short x2, short y2, char *tip); @@ -434,9 +450,12 @@ * uiButSetCompleteFunc is for tab completion. * * uiBlockSetFunc and uiButSetFunc are callbacks run when a button is used, - * in case events, operators or RNA are not sufficient to handle the button. */ + * in case events, operators or RNA are not sufficient to handle the button. + * + * uiButSetNFunc will free the argument with MEM_freeN. */ typedef void (*uiButHandleFunc)(struct bContext *C, void *arg1, void *arg2); +typedef void (*uiButHandleNFunc)(struct bContext *C, void *argN, void *arg2); typedef void (*uiButCompleteFunc)(struct bContext *C, char *str, void *arg); typedef void (*uiBlockHandleFunc)(struct bContext *C, void *arg, int event); @@ -445,6 +464,7 @@ void uiBlockSetFunc (uiBlock *block,uiButHandleFunc func, void *arg1, void *arg2); void uiButSetFunc(uiBut *but,uiButHandleFunc func, void *arg1, void *arg2); +void uiButSetNFunc (uiBut *but,uiButHandleNFunc func, void *argN, void *arg2); void uiButSetCompleteFunc(uiBut *but,uiButCompleteFunc func, void *arg); Modified:
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18836] branches/blender2.5/blender/source /blender: 2.5: Enable triple buffer drawing by default (if it doesn't work
Revision: 18836 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18836 Author: blendix Date: 2009-02-06 17:51:09 +0100 (Fri, 06 Feb 2009) Log Message: --- 2.5: Enable triple buffer drawing by default (if it doesn't work or flickers, kick me). Also removed proxy texture test since it does not seem to be implemented well by all drivers. Modified Paths: -- branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c Modified: branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h === --- branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h 2009-02-06 16:40:14 UTC (rev 18835) +++ branches/blender2.5/blender/source/blender/makesdna/DNA_userdef_types.h 2009-02-06 16:51:09 UTC (rev 18836) @@ -327,8 +327,8 @@ #define USER_VRML_TWOSIDED 4 /* wm draw method */ -#define USER_DRAW_OVERLAP 0 -#define USER_DRAW_TRIPLE 1 +#define USER_DRAW_TRIPLE 0 +#define USER_DRAW_OVERLAP 1 #define USER_DRAW_FULL 2 /* tw_flag (transform widget) */ Modified: branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c === --- branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c 2009-02-06 16:40:14 UTC (rev 18835) +++ branches/blender2.5/blender/source/blender/windowmanager/intern/wm_draw.c 2009-02-06 16:51:09 UTC (rev 18836) @@ -365,7 +365,7 @@ static int wm_triple_gen_textures(wmWindow *win, wmDrawTriple *triple) { - GLint width; + GLint maxsize; int x, y; /* compute texture sizes */ @@ -402,16 +402,13 @@ for(y=0; ytriple-ny; y++) { for(x=0; xtriple-nx; x++) { - /* disabled, does not seems to work well everywhere */ /* proxy texture is only guaranteed to test for the cases that * there is only one texture in use, which may not be the case */ - glBindTexture(triple-target, triple-bind[x + y*triple-nx]); - glTexImage2D(GL_PROXY_TEXTURE_2D, 0, GL_RGB8, triple-x[x], triple-y[y], 0, GL_RGB, GL_UNSIGNED_BYTE, NULL); - glGetTexLevelParameteriv(GL_PROXY_TEXTURE_2D, 0, GL_TEXTURE_WIDTH, width); + glGetIntegerv(GL_MAX_TEXTURE_SIZE, maxsize); - if(width == 0) { + if(triple-x[x] maxsize || triple-y[y] maxsize) { glBindTexture(triple-target, 0); - printf(WM: failed to allocate texture for triple buffer drawing (GL_PROXY_TEXTURE_2D).\n); + printf(WM: failed to allocate texture for triple buffer drawing (texture too large for graphics card).\n); return 0; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18843] branches/blender2.5/blender/source /blender: 2.5: UV Editor, more operators.
Revision: 18843 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18843 Author: blendix Date: 2009-02-07 02:27:46 +0100 (Sat, 07 Feb 2009) Log Message: --- 2.5: UV Editor, more operators. Border Select Circle Select Pin Select Pinned Unwrap Minimize Stretch Pack Islands Average Islands Scale Snap Cursor Snap Selection Modified Paths: -- branches/blender2.5/blender/source/blender/editors/include/ED_mesh.h branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/include/UI_interface.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/space_view3d/space_view3d.c branches/blender2.5/blender/source/blender/editors/transform/transform.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_intern.h branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_unwrap_ops.c branches/blender2.5/blender/source/blender/windowmanager/WM_types.h Modified: branches/blender2.5/blender/source/blender/editors/include/ED_mesh.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_mesh.h 2009-02-06 21:18:36 UTC (rev 18842) +++ branches/blender2.5/blender/source/blender/editors/include/ED_mesh.h 2009-02-07 01:27:46 UTC (rev 18843) @@ -112,6 +112,8 @@ void EM_select_edge(struct EditEdge *eed, int sel); void EM_select_face(struct EditFace *efa, int sel); void EM_select_face_fgon(struct EditMesh *em, struct EditFace *efa, int val); +void EM_select_swap(struct EditMesh *em); +void EM_toggle_select_all(struct EditMesh *em); void EM_selectmode_flush(struct EditMesh *em); void EM_deselect_flush(struct EditMesh *em); void EM_selectmode_set(struct EditMesh *em); Modified: branches/blender2.5/blender/source/blender/editors/include/ED_screen.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_screen.h 2009-02-06 21:18:36 UTC (rev 18842) +++ branches/blender2.5/blender/source/blender/editors/include/ED_screen.h 2009-02-07 01:27:46 UTC (rev 18843) @@ -114,6 +114,7 @@ intED_operator_editarmature(struct bContext *C); intED_operator_editcurve(struct bContext *C); intED_operator_uvedit(struct bContext *C); +intED_operator_uvmap(struct bContext *C); intED_operator_posemode(struct bContext *C); Modified: branches/blender2.5/blender/source/blender/editors/include/UI_interface.h === --- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-06 21:18:36 UTC (rev 18842) +++ branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-07 01:27:46 UTC (rev 18843) @@ -212,7 +212,7 @@ void uiMenuItemVal(uiMenuItem *head, const char *name, int icon, int argval); void uiMenuItemEnumO(uiMenuItem *head, int icon, char *opname, char *propname, int value); -void uiMenuItemBooleanO(uiMenuItem *head, int icon, char *opname, char *propname, int value); +void uiMenuItemBooleanO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, int value); void uiMenuItemsEnumO(uiMenuItem *head, char *opname, char *propname); void uiMenuItemIntO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, int value); void uiMenuItemFloatO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, float value); Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c 2009-02-06 21:18:36 UTC (rev 18842) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c 2009-02-07 01:27:46 UTC (rev 18843) @@ -2035,9 +2035,9 @@ } /* single operator item with property */ -void uiMenuItemBooleanO(uiMenuItem *head, int icon, char *opname, char *propname, int value) +void uiMenuItemBooleanO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, int value) { - uiMenuItem *item= ui_menu_add_item(head, , icon, 0); + uiMenuItem *item=
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18867] branches/blender2.5/blender/source /blender/makesrna/intern/makesrna.c: 2.5: RNA auto pointer type detection didn't find right types.
Revision: 18867 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18867 Author: blendix Date: 2009-02-08 15:56:43 +0100 (Sun, 08 Feb 2009) Log Message: --- 2.5: RNA auto pointer type detection didn't find right types. If two RNA structs have the same DNA structs it should use the first defined one, could be smarter but for now this makes it work again. Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c Modified: branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-02-08 14:25:04 UTC (rev 18866) +++ branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c 2009-02-08 14:56:43 UTC (rev 18867) @@ -1411,8 +1411,8 @@ } } + rna_auto_types(); rna_sort(brna); - rna_auto_types(); status= (DefRNA.error != 0); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18918] branches/blender2.5/blender/source /blender: 2.5: Image window operators, quite a few of these still have
Revision: 18918 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18918 Author: blendix Date: 2009-02-11 00:17:58 +0100 (Wed, 11 Feb 2009) Log Message: --- 2.5: Image window operators, quite a few of these still have missing parts and are work in progress. Set 3D Cursor Set Tile Sample Color New Open Replace Reload Save (As) Save Sequence Pack Unpack Record Composite The file select operators have context issues still. They need to get the image space in the context on exec() but it's not there currently, not sure how to solve that yet. Also added name parameter to uiMenuItemEnumO, and fixed mute argument in ED_update_for_newframe calls in fluidsim bake. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/armature/editarmature.c branches/blender2.5/blender/source/blender/editors/include/ED_image.h branches/blender2.5/blender/source/blender/editors/include/UI_interface.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/physics/ed_fluidsim.c branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c branches/blender2.5/blender/source/blender/editors/transform/transform_orientations.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_space.c Modified: branches/blender2.5/blender/source/blender/editors/armature/editarmature.c === --- branches/blender2.5/blender/source/blender/editors/armature/editarmature.c 2009-02-10 23:08:53 UTC (rev 18917) +++ branches/blender2.5/blender/source/blender/editors/armature/editarmature.c 2009-02-10 23:17:58 UTC (rev 18918) @@ -3429,11 +3429,11 @@ } CTX_DATA_END; - uiMenuItemEnumO(head, 0, ARMATURE_OT_set_parent, type, ARM_PAR_CONNECT); + uiMenuItemEnumO(head, , 0, ARMATURE_OT_set_parent, type, ARM_PAR_CONNECT); /* ob becomes parent, make the associated menus */ if (allchildbones) - uiMenuItemEnumO(head, 0, ARMATURE_OT_set_parent, type, ARM_PAR_OFFSET); + uiMenuItemEnumO(head, , 0, ARMATURE_OT_set_parent, type, ARM_PAR_OFFSET); uiPupMenuEnd(C, head); Modified: branches/blender2.5/blender/source/blender/editors/include/ED_image.h === --- branches/blender2.5/blender/source/blender/editors/include/ED_image.h 2009-02-10 23:08:53 UTC (rev 18917) +++ branches/blender2.5/blender/source/blender/editors/include/ED_image.h 2009-02-10 23:17:58 UTC (rev 18918) @@ -33,7 +33,7 @@ /* space_image.c, exported for transform */ struct Image *ED_space_image(struct SpaceImage *sima); -void ED_space_image_set(struct SpaceImage *sima, struct Scene *scene, struct Object *obedit, struct Image *ima); +void ED_space_image_set(struct bContext *C, struct SpaceImage *sima, struct Scene *scene, struct Object *obedit, struct Image *ima); struct ImBuf *ED_space_image_buffer(struct SpaceImage *sima); void ED_space_image_size(struct SpaceImage *sima, int *width, int *height); Modified: branches/blender2.5/blender/source/blender/editors/include/UI_interface.h === --- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-10 23:08:53 UTC (rev 18917) +++ branches/blender2.5/blender/source/blender/editors/include/UI_interface.h 2009-02-10 23:17:58 UTC (rev 18918) @@ -212,7 +212,7 @@ void uiMenuItemVal(uiMenuItem *head, const char *name, int icon, int argval); -void uiMenuItemEnumO(uiMenuItem *head, int icon, char *opname, char *propname, int value); +void uiMenuItemEnumO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, int value); void uiMenuItemBooleanO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, int value); void uiMenuItemsEnumO(uiMenuItem *head, char *opname, char *propname); void uiMenuItemIntO(uiMenuItem *head, const char *name, int icon, char *opname, char *propname, int value); Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c === ---
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18926] branches/blender2.5/blender/source /blender/editors/space_outliner/outliner.c: 2.5: fix crash due to keyingset commit, ot-idname should alway
Revision: 18926 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18926 Author: blendix Date: 2009-02-11 15:56:35 +0100 (Wed, 11 Feb 2009) Log Message: --- 2.5: fix crash due to keyingset commit, ot-idname should always be set. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c Modified: branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c === --- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-02-11 12:32:29 UTC (rev 18925) +++ branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-02-11 14:56:35 UTC (rev 18926) @@ -3116,7 +3116,8 @@ void OUTLINER_OT_keyingset_add_selected(wmOperatorType *ot) { - + ot-idname= OUTLINER_OT_keyingset_add_selected; + ot-name= Keyingset Add Selected; } @@ -3124,7 +3125,8 @@ void OUTLINER_OT_keyingset_remove_selected(wmOperatorType *ot) { - + ot-idname= OUTLINER_OT_keyingset_remove_selected; + ot-name= Keyingset Remove Selected; } /* * DRAW *** */ ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18930] branches/blender2.5/blender/source /blender: 2.5: Image window, some small changes:
Revision: 18930 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18930 Author: blendix Date: 2009-02-11 20:16:14 +0100 (Wed, 11 Feb 2009) Log Message: --- 2.5: Image window, some small changes: * Added notifier for edited images. * Fix main region emboss drawing when showing render. * Don't go fullscreen with fileselect for now to work around context getting lost, so open/replace works. * Save operators are more complete now, but still lack confirmation and choosing image type. * Pack operators work correctly now (but not unpack). * Setting white/black point for curves. * Time cursor for record composite. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/windowmanager/WM_types.h Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c === --- branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c 2009-02-11 17:46:10 UTC (rev 18929) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c 2009-02-11 19:16:14 UTC (rev 18930) @@ -125,7 +125,7 @@ } } -static void sima_draw_render_info(SpaceImage *sima, ARegion *ar) +static void draw_render_info(SpaceImage *sima, ARegion *ar) { rcti rect; float colf[3]; @@ -136,23 +136,24 @@ return; rect= ar-winrct; - rect.ymin= rect.ymax - HEADER_HEIGHT; + rect.xmin= 0; + rect.ymin= ar-winrct.ymax - ar-winrct.ymin - HEADER_HEIGHT; + rect.xmax= ar-winrct.xmax - ar-winrct.xmin; + rect.ymax= ar-winrct.ymax - ar-winrct.ymin; - glaDefine2DArea(rect); - /* clear header rect */ UI_GetThemeColor3fv(TH_BACK, colf); - glClearColor(colf[0]+0.1f, colf[1]+0.1f, colf[2]+0.1f, 1.0); - glClear(GL_COLOR_BUFFER_BIT); + glColor3f(colf[0]+0.1f, colf[1]+0.1f, colf[2]+0.1f); + glRecti(rect.xmin, rect.ymin, rect.xmax, rect.ymax); UI_ThemeColor(TH_TEXT_HI); - glRasterPos2i(12, 5); - UI_RasterPos(12, 5); + glRasterPos2i(12, rect.ymin + 5); + UI_RasterPos(12, rect.ymin + 5); if(showspare) { UI_DrawString(G.fonts, (Previous), 0); - glRasterPos2i(72, 5); - UI_RasterPos(72, 5); + glRasterPos2i(72, rect.ymin + 5); + UI_RasterPos(72, rect.ymin + 5); } UI_DrawString(G.fonts, str, 0); @@ -668,7 +669,7 @@ /* render info */ if(ibuf show_render) - sima_draw_render_info(sima, ar); + draw_render_info(sima, ar); /* XXX integrate this code */ #if 0 Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_header.c === --- branches/blender2.5/blender/source/blender/editors/space_image/image_header.c 2009-02-11 17:46:10 UTC (rev 18929) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_header.c 2009-02-11 19:16:14 UTC (rev 18930) @@ -186,37 +186,6 @@ #ifndef DISABLE_PYTHON if (event = 20) BPY_menu_do_python(PYMENU_IMAGE, event - 20); #endif - switch(event) - { - case 0: - open_image_sima((G.qual==LR_CTRLKEY)); - break; - case 1: - replace_image_sima((G.qual==LR_CTRLKEY)); - break; - case 2: - pack_image_sima(); - break; - case 5: - save_as_image_sima(); - break; - case 6: - reload_image_sima(); - break; - case 7: - new_image_sima(); - break; - case 8: - save_image_sima(); - break; - case 9: - save_image_sequence_sima(); - break; - case 10: - BKE_image_memorypack(sima-image); - allqueue(REDRAWIMAGE, 0); - break; - } } #endif @@ -242,12 +211,14 @@ uiMenuItemO(head, 0, IMAGE_OT_open); // Open... if(ima) { - uiMenuItemO(head, 0, IMAGE_OT_replace); // Replace... - uiMenuItemO(head, 0, IMAGE_OT_reload); // Reload... + if(!show_render) { + uiMenuItemO(head, 0, IMAGE_OT_replace); // Replace... + uiMenuItemO(head, 0, IMAGE_OT_reload); // Reload... + }
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18931] branches/blender2.5/blender/source /blender/editors: 2.5: Curve edit mode.
Revision: 18931 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18931 Author: blendix Date: 2009-02-12 00:02:21 +0100 (Thu, 12 Feb 2009) Log Message: --- 2.5: Curve edit mode. Transform works again, and editcurve.c is partly operatorized though nothing hooked up yet. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c branches/blender2.5/blender/source/blender/editors/curve/editcurve.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_tools.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/transform/transform_conversions.c branches/blender2.5/blender/source/blender/editors/transform/transform_generics.c Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h === --- branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-11 19:16:14 UTC (rev 18930) +++ branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-11 23:02:21 UTC (rev 18931) @@ -38,5 +38,38 @@ /* editfont.c */ void FONT_OT_textedit(struct wmOperatorType *ot); +/* editcurve.c */ +void CURVE_OT_separate(struct wmOperatorType *ot); +void CURVE_OT_switch_direction(struct wmOperatorType *ot); +void CURVE_OT_set_weight(struct wmOperatorType *ot); +void CURVE_OT_set_radius(struct wmOperatorType *ot); +void CURVE_OT_smooth(struct wmOperatorType *ot); +void CURVE_OT_smooth_curve_radius(struct wmOperatorType *ot); +void CURVE_OT_de_select_first(struct wmOperatorType *ot); +void CURVE_OT_de_select_last(struct wmOperatorType *ot); +void CURVE_OT_de_select_all(struct wmOperatorType *ot); +void CURVE_OT_hide(struct wmOperatorType *ot); +void CURVE_OT_reveal(struct wmOperatorType *ot); +void CURVE_OT_select_invert(struct wmOperatorType *ot); +void CURVE_OT_subdivide(struct wmOperatorType *ot); +void CURVE_OT_set_spline_type(struct wmOperatorType *ot); +void CURVE_OT_make_segment(struct wmOperatorType *ot); +void CURVE_OT_spin(struct wmOperatorType *ot); +void CURVE_OT_add_vertex(struct wmOperatorType *ot); +void CURVE_OT_extrude(struct wmOperatorType *ot); +void CURVE_OT_make_cyclic(struct wmOperatorType *ot); +void CURVE_OT_select_linked(struct wmOperatorType *ot); +void CURVE_OT_select_row(struct wmOperatorType *ot); +void CURVE_OT_select_next(struct wmOperatorType *ot); +void CURVE_OT_select_previous(struct wmOperatorType *ot); +void CURVE_OT_select_more(struct wmOperatorType *ot); +void CURVE_OT_select_less(struct wmOperatorType *ot); +void CURVE_OT_select_random(struct wmOperatorType *ot); +void CURVE_OT_select_every_nth(struct wmOperatorType *ot); +void CURVE_OT_add_duplicate(struct wmOperatorType *ot); +void CURVE_OT_delete(struct wmOperatorType *ot); +void CURVE_OT_set_smooth(struct wmOperatorType *ot); +void CURVE_OT_clear_tilt(struct wmOperatorType *ot); + #endif /* ED_UTIL_INTERN_H */ Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c === --- branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c 2009-02-11 19:16:14 UTC (rev 18930) +++ branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c 2009-02-11 23:02:21 UTC (rev 18931) @@ -64,6 +64,38 @@ void ED_operatortypes_curve(void) { WM_operatortype_append(FONT_OT_textedit); + + WM_operatortype_append(CURVE_OT_separate); + WM_operatortype_append(CURVE_OT_switch_direction); + WM_operatortype_append(CURVE_OT_set_weight); + WM_operatortype_append(CURVE_OT_set_radius); + WM_operatortype_append(CURVE_OT_smooth); + WM_operatortype_append(CURVE_OT_smooth_curve_radius); + WM_operatortype_append(CURVE_OT_de_select_first); + WM_operatortype_append(CURVE_OT_de_select_last); + WM_operatortype_append(CURVE_OT_de_select_all); + WM_operatortype_append(CURVE_OT_hide); + WM_operatortype_append(CURVE_OT_reveal); + WM_operatortype_append(CURVE_OT_select_invert); + WM_operatortype_append(CURVE_OT_subdivide); + WM_operatortype_append(CURVE_OT_set_spline_type); + WM_operatortype_append(CURVE_OT_make_segment); + WM_operatortype_append(CURVE_OT_spin); + WM_operatortype_append(CURVE_OT_add_vertex); + WM_operatortype_append(CURVE_OT_extrude); + WM_operatortype_append(CURVE_OT_make_cyclic); + WM_operatortype_append(CURVE_OT_select_linked); + WM_operatortype_append(CURVE_OT_select_row); + WM_operatortype_append(CURVE_OT_select_next); + WM_operatortype_append(CURVE_OT_select_previous); +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18946] branches/blender2.5/blender/source /blender: 2.5: Most curve/surface editmode operators back:
Revision: 18946 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18946 Author: blendix Date: 2009-02-12 23:12:21 +0100 (Thu, 12 Feb 2009) Log Message: --- 2.5: Most curve/surface editmode operators back: * Hide, Reveal * Separate, Duplicate, Delete * Set Weight, Set Radius, Set Spline Type, Set Handle Type, Set Smooth * Tilt, Clear Tilt * Smooth, Smooth Radius * De(select) First, De(select) Last, De(select) All, Select Inverse, Select Linked, Select Control Point Row, Select Next, Select Previous, Select More, Select Less, Select Random, Select Every Nth * Switch Direction, Subdivide, Make Segment, Spin, Extrude, Toggle Cyclic * Specials Menu Not working correct yet: * Add Vertex (ctrl click) * Add Menu Modified Paths: -- branches/blender2.5/blender/source/blender/blenkernel/intern/curve.c branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c branches/blender2.5/blender/source/blender/editors/curve/editcurve.c branches/blender2.5/blender/source/blender/editors/include/ED_curve.h branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/interface/interface.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_unwrap_ops.c Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/curve.c === --- branches/blender2.5/blender/source/blender/blenkernel/intern/curve.c 2009-02-12 18:05:34 UTC (rev 18945) +++ branches/blender2.5/blender/source/blender/blenkernel/intern/curve.c 2009-02-12 22:12:21 UTC (rev 18946) @@ -191,6 +191,8 @@ cun-bev.first= cun-bev.last= 0; cun-path= 0; + cun-editnurb= NULL; + #if 0 // XXX old animation system /* single user ipo too */ if(cun-ipo) cun-ipo= copy_ipo(cun-ipo); Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h === --- branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-12 18:05:34 UTC (rev 18945) +++ branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-12 22:12:21 UTC (rev 18946) @@ -44,20 +44,21 @@ void CURVE_OT_set_weight(struct wmOperatorType *ot); void CURVE_OT_set_radius(struct wmOperatorType *ot); void CURVE_OT_smooth(struct wmOperatorType *ot); -void CURVE_OT_smooth_curve_radius(struct wmOperatorType *ot); +void CURVE_OT_smooth_radius(struct wmOperatorType *ot); void CURVE_OT_de_select_first(struct wmOperatorType *ot); void CURVE_OT_de_select_last(struct wmOperatorType *ot); void CURVE_OT_de_select_all(struct wmOperatorType *ot); void CURVE_OT_hide(struct wmOperatorType *ot); void CURVE_OT_reveal(struct wmOperatorType *ot); -void CURVE_OT_select_invert(struct wmOperatorType *ot); +void CURVE_OT_select_inverse(struct wmOperatorType *ot); void CURVE_OT_subdivide(struct wmOperatorType *ot); void CURVE_OT_set_spline_type(struct wmOperatorType *ot); +void CURVE_OT_set_handle_type(struct wmOperatorType *ot); void CURVE_OT_make_segment(struct wmOperatorType *ot); void CURVE_OT_spin(struct wmOperatorType *ot); void CURVE_OT_add_vertex(struct wmOperatorType *ot); void CURVE_OT_extrude(struct wmOperatorType *ot); -void CURVE_OT_make_cyclic(struct wmOperatorType *ot); +void CURVE_OT_toggle_cyclic(struct wmOperatorType *ot); void CURVE_OT_select_linked(struct wmOperatorType *ot); void CURVE_OT_select_row(struct wmOperatorType *ot); void CURVE_OT_select_next(struct wmOperatorType *ot); @@ -66,10 +67,16 @@ void CURVE_OT_select_less(struct wmOperatorType *ot); void CURVE_OT_select_random(struct wmOperatorType *ot); void CURVE_OT_select_every_nth(struct wmOperatorType *ot); -void CURVE_OT_add_duplicate(struct wmOperatorType *ot); +void CURVE_OT_duplicate(struct wmOperatorType *ot); void CURVE_OT_delete(struct wmOperatorType *ot); void CURVE_OT_set_smooth(struct wmOperatorType *ot); void CURVE_OT_clear_tilt(struct wmOperatorType *ot); +void CURVE_OT_add_surface_primitive(struct wmOperatorType *ot); +void CURVE_OT_add_curve_primitive(struct wmOperatorType *ot); +void CURVE_OT_specials_menu(struct wmOperatorType *ot); +void CURVE_OT_add_menu(struct wmOperatorType *ot); + + #endif /* ED_UTIL_INTERN_H */ Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c === --- branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c 2009-02-12 18:05:34 UTC (rev 18945)
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18959] branches/blender2.5/blender/source /blender/editors: 2.5: Keyingsets now can construct rna paths including pointers
Revision: 18959 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18959 Author: blendix Date: 2009-02-13 15:48:38 +0100 (Fri, 13 Feb 2009) Log Message: --- 2.5: Keyingsets now can construct rna paths including pointers and collections, which means keying for example object game settings or constraint properties should work. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/animation/keyframing.c branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c Modified: branches/blender2.5/blender/source/blender/editors/animation/keyframing.c === --- branches/blender2.5/blender/source/blender/editors/animation/keyframing.c 2009-02-13 14:16:56 UTC (rev 18958) +++ branches/blender2.5/blender/source/blender/editors/animation/keyframing.c 2009-02-13 14:48:38 UTC (rev 18959) @@ -718,8 +718,8 @@ /* validate pointer first - exit if failure*/ RNA_id_pointer_create(id, id_ptr); - if (RNA_path_resolve(id_ptr, rna_path, ptr, prop) == 0) { - printf(Insert Key: Could not insert keyframe, as RNA Path is invalid for the given ID \n); + if (RNA_path_resolve(id_ptr, rna_path, ptr, prop) == 0 || prop == NULL) { + printf(Insert Key: Could not insert keyframe, as RNA Path is invalid for the given ID (%s)\n, rna_path); return 0; } @@ -2050,7 +2050,7 @@ PropertyRNA *prop; RNA_id_pointer_create(ksp-id, id_ptr); - if (RNA_path_resolve(id_ptr, ksp-rna_path, ptr, prop)) + if (RNA_path_resolve(id_ptr, ksp-rna_path, ptr, prop) prop) arraylen= RNA_property_array_length(ptr, prop); } Modified: branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c === --- branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-02-13 14:16:56 UTC (rev 18958) +++ branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c 2009-02-13 14:48:38 UTC (rev 18959) @@ -3144,10 +3144,10 @@ { ListBase hierarchy = {NULL, NULL}; LinkData *ld; - TreeElement *tem; - TreeStoreElem *tse; - PointerRNA *ptr; - PropertyRNA *prop; + TreeElement *tem, *temnext, *temsub; + TreeStoreElem *tse, *tsenext; + PointerRNA *ptr, *nextptr; + PropertyRNA *prop, *nameprop; ID *id = NULL; char *path=NULL, *newpath=NULL; int array_index= 0; @@ -3189,9 +3189,9 @@ /* check if we're looking for first ID, or appending to path */ if (id) { - if (tse-type == TSE_RNA_STRUCT) + if(tse-type == TSE_RNA_STRUCT) printf(\t tem = RNA Struct '%s' \n, tem-name); - else if (tse-type == TSE_RNA_ARRAY_ELEM) + else if(tse-type == TSE_RNA_ARRAY_ELEM) printf(\t tem = RNA Array Elem '%s' \n, tem-name); else if (tse-type == TSE_RNA_PROPERTY) printf(\t tem = RNA Property '%s' \n, tem-name); @@ -3201,22 +3201,67 @@ /* just 'append' property to path * - to prevent memory leaks, we must write to newpath not path, then free old path + swap them */ - // TODO: how should this be done? - //newpath= RNA_path_append(path, ptr, prop, tem-index, /*RNA_property_identifier(ptr, prop)*/0); - if (path) MEM_freeN(path); - path= newpath; + if(tse-type == TSE_RNA_PROPERTY) { + if(RNA_property_type(ptr, prop) == PROP_POINTER) { + /* for pointer we just append property name */ + newpath= RNA_path_append(path, ptr, prop, 0, NULL); + } + else if(RNA_property_type(ptr, prop) == PROP_COLLECTION) { + temnext= (TreeElement*)(ld-next-data); + tsenext= TREESTORE(temnext); + + nextptr= temnext-rnaptr; + nameprop= RNA_struct_name_property(nextptr); + + if(nameprop) { + /* if possible, use name as a key in the
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18960] branches/blender2.5/blender/source /blender/makesrna/intern/CMakeLists.txt: 2.5: update cmake for rna_animation.c.
Revision: 18960 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18960 Author: blendix Date: 2009-02-13 17:05:42 +0100 (Fri, 13 Feb 2009) Log Message: --- 2.5: update cmake for rna_animation.c. Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt Modified: branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt === --- branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt 2009-02-13 14:48:38 UTC (rev 18959) +++ branches/blender2.5/blender/source/blender/makesrna/intern/CMakeLists.txt 2009-02-13 16:05:42 UTC (rev 18960) @@ -27,6 +27,7 @@ SET(DEFSRC rna_action.c rna_actuator.c + rna_animation.c rna_armature.c rna_brush.c rna_camera.c ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18961] branches/blender2.5/blender/source /blender/editors: 2.5: Curve edit mode add vertex and add menus now work.
Revision: 18961 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=18961 Author: blendix Date: 2009-02-13 18:37:01 +0100 (Fri, 13 Feb 2009) Log Message: --- 2.5: Curve edit mode add vertex and add menus now work. Also fixed an issue where sublevel menus did not get right operator context. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c branches/blender2.5/blender/source/blender/editors/curve/editcurve.c branches/blender2.5/blender/source/blender/editors/include/ED_view3d.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_add.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/object/object_intern.h branches/blender2.5/blender/source/blender/editors/object/object_ops.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_select.c Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h === --- branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-13 16:05:42 UTC (rev 18960) +++ branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-13 17:37:01 UTC (rev 18961) @@ -71,12 +71,8 @@ void CURVE_OT_delete(struct wmOperatorType *ot); void CURVE_OT_set_smooth(struct wmOperatorType *ot); void CURVE_OT_clear_tilt(struct wmOperatorType *ot); -void CURVE_OT_add_surface_primitive(struct wmOperatorType *ot); -void CURVE_OT_add_curve_primitive(struct wmOperatorType *ot); void CURVE_OT_specials_menu(struct wmOperatorType *ot); -void CURVE_OT_add_menu(struct wmOperatorType *ot); - #endif /* ED_UTIL_INTERN_H */ Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c === --- branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c 2009-02-13 16:05:42 UTC (rev 18960) +++ branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c 2009-02-13 17:37:01 UTC (rev 18961) @@ -91,32 +91,6 @@ ot-poll= ED_operator_editsurfcurve; } -static int add_menu_invoke(bContext *C, wmOperator *op, wmEvent *event) -{ - Object *obedit= CTX_data_edit_object(C); - uiMenuItem *head; - - head= uiPupMenuBegin(Add, 0); - if(obedit-type == OB_CURVE) - uiMenuItemsEnumO(head, CURVE_OT_add_curve_primitive, type); - else - uiMenuItemsEnumO(head, CURVE_OT_add_surface_primitive, type); - uiPupMenuEnd(C, head); - - return OPERATOR_CANCELLED; -} - -void CURVE_OT_add_menu(wmOperatorType *ot) -{ - /* identifiers */ - ot-name= Add Menu; - ot-idname= CURVE_OT_add_menu; - - /* api clastbacks */ - ot-invoke= add_menu_invoke; - ot-poll= ED_operator_editsurfcurve; -} - /* registration / void ED_operatortypes_curve(void) @@ -161,11 +135,7 @@ WM_operatortype_append(CURVE_OT_extrude); WM_operatortype_append(CURVE_OT_toggle_cyclic); - WM_operatortype_append(CURVE_OT_add_menu); WM_operatortype_append(CURVE_OT_specials_menu); - - WM_operatortype_append(CURVE_OT_add_surface_primitive); - WM_operatortype_append(CURVE_OT_add_curve_primitive); } void ED_keymap_curve(wmWindowManager *wm) Modified: branches/blender2.5/blender/source/blender/editors/curve/editcurve.c === --- branches/blender2.5/blender/source/blender/editors/curve/editcurve.c 2009-02-13 16:05:42 UTC (rev 18960) +++ branches/blender2.5/blender/source/blender/editors/curve/editcurve.c 2009-02-13 17:37:01 UTC (rev 18961) @@ -3258,16 +3258,15 @@ /* add vertex operator **/ -static int addvert_Nurb(bContext *C, short mode) +static int addvert_Nurb(bContext *C, short mode, float location[3]) { Scene *scene= CTX_data_scene(C); Object *obedit= CTX_data_edit_object(C); ListBase *editnurb= curve_get_editcurve(obedit); - View3D *v3d= CTX_wm_view3d(C); Nurb *nu; BezTriple *bezt, *newbezt = NULL; BPoint *bp, *newbp = NULL; - float *curs, mat[3][3],imat[3][3], temp[3]; + float mat[3][3],imat[3][3], temp[3]; Mat3CpyMat4(mat, obedit-obmat); Mat3Inv(imat,mat); @@ -3315,16 +3314,7 @@ VECCOPY(newbezt-vec[2], bezt-vec[2]); } else { - if(v3d) { - curs= give_cursor(scene,
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19013] branches/blender2.5/blender/source /blender/blenfont/SConscript: 2.5: fix to make blenfont module compile with scons.
Revision: 19013 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19013 Author: blendix Date: 2009-02-17 20:37:47 +0100 (Tue, 17 Feb 2009) Log Message: --- 2.5: fix to make blenfont module compile with scons. Modified Paths: -- branches/blender2.5/blender/source/blender/blenfont/SConscript Modified: branches/blender2.5/blender/source/blender/blenfont/SConscript === --- branches/blender2.5/blender/source/blender/blenfont/SConscript 2009-02-17 19:09:14 UTC (rev 19012) +++ branches/blender2.5/blender/source/blender/blenfont/SConscript 2009-02-17 19:37:47 UTC (rev 19013) @@ -4,7 +4,10 @@ sources = env.Glob('intern/*.c') -incs = '. intern #/intern/guardedalloc ../blenkernel ../blenlib ../makesdna ../ftfont ../../editors/include' +incs = '. intern #/intern/guardedalloc ../blenkernel ../blenlib ../makesdna ../ftfont ../editors/include' +incs += ' ' + env['BF_FTGL_INC'] +incs += ' ' + env['BF_FREETYPE_INC'] +incs += ' ' + env['BF_GETTEXT_INC'] defs = '' ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19014] branches/blender2.5/blender/source /blender: 2.5: Text edit mode operators back.
Revision: 19014 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19014 Author: blendix Date: 2009-02-17 20:55:20 +0100 (Tue, 17 Feb 2009) Log Message: --- 2.5: Text edit mode operators back. Took me a while getting them nicely repeatable, and splitting up the big edit_text operator into individual operator so it's all nicely scriptable, documented, configurable, etc.. * Insert Text, Line Break, Insert Lorem * Toggle Case, Set Case, Toggle Style, Set Style, Set Material * Copy Text, Cut Text, Paste Text, Paste File, Paste Buffer * Move, Move Select, Delete * Change Spacing, Change Character Notes * Text (datablock) to Object doesn't work yet, will need to implement text editor context for that. * Some shortcut keys don't work because screen/wm overrides them, ctrl+x, ctrl+left/right. That override goes top down which works well for some cases, but here we need to override in the other direction. * There's no unicode support in RNA, or the user interface code for that matter, but text strings can contain these characters. At the moment it stores a UTF-8 string in char arrays, which is supposed to be nicely compatible with ascii. Seems reasonable to add support for UTF-8 in the interface code, python bindings, .. eventually? Modified Paths: -- branches/blender2.5/blender/source/blender/blenkernel/intern/font.c branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c branches/blender2.5/blender/source/blender/editors/curve/editcurve.c branches/blender2.5/blender/source/blender/editors/curve/editfont.c branches/blender2.5/blender/source/blender/editors/include/ED_curve.h branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/include/UI_interface.h branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/object/object_intern.h branches/blender2.5/blender/source/blender/editors/object/object_ops.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/font.c === --- branches/blender2.5/blender/source/blender/blenkernel/intern/font.c 2009-02-17 19:37:47 UTC (rev 19013) +++ branches/blender2.5/blender/source/blender/blenkernel/intern/font.c 2009-02-17 19:55:20 UTC (rev 19014) @@ -658,7 +658,7 @@ VChar *che; struct chartrans *chartransdata=NULL, *ct; float *f, xof, yof, xtrax, linedist, *linedata, *linedata2, *linedata3, *linedata4; - float twidth; + float twidth, maxlen= 0; int i, slen, j; int curbox; int selstart, selend; @@ -826,8 +826,6 @@ } } if(ascii== '\n' || ascii== '\r' || ascii==0 || ct-dobreak) { - float maxlen; - ct-xof= xof; ct-yof= yof; ct-linenr= lnr; Modified: branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h === --- branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-17 19:37:47 UTC (rev 19013) +++ branches/blender2.5/blender/source/blender/editors/curve/curve_intern.h 2009-02-17 19:55:20 UTC (rev 19014) @@ -36,29 +36,57 @@ char *ED_lorem; /* editfont.c */ -void FONT_OT_textedit(struct wmOperatorType *ot); +enum { DEL_ALL, DEL_NEXT_CHAR, DEL_PREV_CHAR, DEL_SELECTION, DEL_NEXT_SEL, DEL_PREV_SEL }; +enum { CASE_LOWER, CASE_UPPER }; +enum { LINE_BEGIN, LINE_END, PREV_CHAR, NEXT_CHAR, PREV_WORD, NEXT_WORD, + PREV_LINE, NEXT_LINE, PREV_PAGE, NEXT_PAGE }; +void FONT_OT_insert_text(struct wmOperatorType *ot); +void FONT_OT_line_break(struct wmOperatorType *ot); +void FONT_OT_insert_lorem(struct wmOperatorType *ot); +void FONT_OT_text_to_object(struct wmOperatorType *ot); + +void FONT_OT_toggle_case(struct wmOperatorType *ot); +void FONT_OT_set_case(struct wmOperatorType *ot); +void FONT_OT_toggle_style(struct wmOperatorType *ot); +void FONT_OT_set_style(struct wmOperatorType *ot); +void FONT_OT_set_material(struct wmOperatorType *ot); + +void FONT_OT_copy_text(struct wmOperatorType *ot); +void FONT_OT_cut_text(struct wmOperatorType *ot); +void FONT_OT_paste_text(struct wmOperatorType *ot); +void FONT_OT_paste_file(struct wmOperatorType *ot); +void FONT_OT_paste_buffer(struct wmOperatorType *ot); + +void FONT_OT_move(struct wmOperatorType *ot); +void
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19016] branches/blender2.5/blender/source /blender/blenfont: 2.5: CMake update for blenfont module, also some flags for scons
Revision: 19016 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19016 Author: blendix Date: 2009-02-17 21:16:09 +0100 (Tue, 17 Feb 2009) Log Message: --- 2.5: CMake update for blenfont module, also some flags for scons to make it compatible with makefiles and ftfont module. Modified Paths: -- branches/blender2.5/blender/source/blender/blenfont/CMakeLists.txt branches/blender2.5/blender/source/blender/blenfont/SConscript Modified: branches/blender2.5/blender/source/blender/blenfont/CMakeLists.txt === --- branches/blender2.5/blender/source/blender/blenfont/CMakeLists.txt 2009-02-17 19:57:05 UTC (rev 19015) +++ branches/blender2.5/blender/source/blender/blenfont/CMakeLists.txt 2009-02-17 20:16:09 UTC (rev 19016) @@ -24,15 +24,23 @@ FILE(GLOB SRC intern/*.c) -#SET(INC . intern ../../../intern/guardedalloc ../blenlib ../blenkernel ../makedna - SET(INC - ../../../intern/guardedalloc ../blenlib ../makesdna - ../blenkernel ../ftfont + ../../../intern/guardedalloc ../blenlib ../makesdna ../editors/include + ../blenkernel ../ftfont ../../../extern/glew/include + ${FTGL_INC} + ${FREETYPE_INC} + ${GETTEXT_INC} ) +ADD_DEFINITIONS(-DFTGL_LIBRARY_STATIC) + IF(WITH_INTERNATIONAL) ADD_DEFINITIONS(-DWITH_FREETYPE2) ENDIF(WITH_INTERNATIONAL) -BLENDERLIB(bf_blenfont ${SRC} ${INC}) \ No newline at end of file +IF(WIN32) + ADD_DEFINITIONS(-D_WIN32 -DUSE_GETTEXT_DLL) +ENDIF(WIN32) + +BLENDERLIB(bf_blenfont ${SRC} ${INC}) + Modified: branches/blender2.5/blender/source/blender/blenfont/SConscript === --- branches/blender2.5/blender/source/blender/blenfont/SConscript 2009-02-17 19:57:05 UTC (rev 19015) +++ branches/blender2.5/blender/source/blender/blenfont/SConscript 2009-02-17 20:16:09 UTC (rev 19016) @@ -15,4 +15,8 @@ if env['WITH_BF_INTERNATIONAL']: defs += ' WITH_FREETYPE2' +defs = 'FTGL_STATIC_LIBRARY' +if sys.platform == 'win32': + defs += ' _WIN32 USE_GETTEXT_DLL' + env.BlenderLib ( 'bf_blenfont', sources, Split(incs), Split(defs), libtype=['core'], priority=[210] ) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19017] branches/blender2.5/blender/source /blender/editors: 2.5: Image space, two fixes:
Revision: 19017 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19017 Author: blendix Date: 2009-02-17 21:37:23 +0100 (Tue, 17 Feb 2009) Log Message: --- 2.5: Image space, two fixes: * With one item in ID databrowse list, you couldn't activate it. * Render result without render image now displays grid at size according to render settings again. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c 2009-02-17 20:16:09 UTC (rev 19016) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c 2009-02-17 20:37:23 UTC (rev 19017) @@ -440,7 +440,7 @@ for(idtest=lb-first, nr=1; idtest; idtest=idtest-next, nr++) { if(nr==params-browsenr) { - if(id == idtest) + if(*id_p == idtest) return; *id_p= idtest; @@ -1128,7 +1128,5 @@ uiDefBut(block, BUT_CURVE, event, , rect-xmin, rect-ymin, rect-xmax-rect-xmin, fy-rect-ymin, cumap, 0.0f, 1.0f, 0, 0, ); - } - Modified: branches/blender2.5/blender/source/blender/editors/space_image/space_image.c === --- branches/blender2.5/blender/source/blender/editors/space_image/space_image.c 2009-02-17 20:16:09 UTC (rev 19016) +++ branches/blender2.5/blender/source/blender/editors/space_image/space_image.c 2009-02-17 20:37:23 UTC (rev 19017) @@ -276,33 +276,33 @@ /** main region ***/ /* sets up the fields of the View2D from zoom and offset */ -static void image_main_area_set_view2d(SpaceImage *sima, ARegion *ar) +static void image_main_area_set_view2d(SpaceImage *sima, ARegion *ar, Scene *scene) { Image *ima= ED_space_image(sima); float x1, y1, w, h; int width, height, winx, winy; + ED_space_image_size(sima, width, height); + #if 0 - if(image_preview_active(curarea, xim, yim)); - else if(sima-image) { + if(image_preview_active(curarea, width, height)); +#endif + if(sima-image) { ImBuf *ibuf= ED_space_image_buffer(sima); float xuser_asp, yuser_asp; ED_image_aspect(sima-image, xuser_asp, yuser_asp); if(ibuf) { - xim= ibuf-x * xuser_asp; - yim= ibuf-y * yuser_asp; + width= ibuf-x * xuser_asp; + width= ibuf-y * yuser_asp; } else if( sima-image-type==IMA_TYPE_R_RESULT ) { /* not very important, just nice */ - xim= (G.scene-r.xsch*G.scene-r.size)/100; - yim= (G.scene-r.ysch*G.scene-r.size)/100; + width= (scene-r.xsch*scene-r.size)/100; + height= (scene-r.ysch*scene-r.size)/100; } } -#endif - ED_space_image_size(sima, width, height); - w= width; h= height; @@ -373,7 +373,7 @@ glClear(GL_COLOR_BUFFER_BIT); /* we set view2d from own zoom and offset each time */ - image_main_area_set_view2d(sima, ar); + image_main_area_set_view2d(sima, ar, scene); /* we draw image in pixelspace */ draw_image_main(sima, ar, scene); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19018] branches/blender2.5/blender/source /blender: RNA:
Revision: 19018 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19018 Author: blendix Date: 2009-02-17 22:07:01 +0100 (Tue, 17 Feb 2009) Log Message: --- RNA: * Added Particle wrapping patch by Roelf de Kock. It's not complete yet and I haven't reviewed it, but committing anyway, will get to it later. * Added Percentage subtype for floats. Doesn't really do much besides making auto rna buttons into sliders rather than numeric inputs, but can later display in % rather than 0.0-1.0. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/curve/editcurve.c branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_unwrap_ops.c branches/blender2.5/blender/source/blender/makesrna/RNA_define.h branches/blender2.5/blender/source/blender/makesrna/RNA_types.h branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_ID.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_define.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_main.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_particle.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_rna.c Modified: branches/blender2.5/blender/source/blender/editors/curve/editcurve.c === --- branches/blender2.5/blender/source/blender/editors/curve/editcurve.c 2009-02-17 20:37:23 UTC (rev 19017) +++ branches/blender2.5/blender/source/blender/editors/curve/editcurve.c 2009-02-17 21:07:01 UTC (rev 19018) @@ -1077,7 +1077,7 @@ ot-flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float(ot-srna, weight, 1.0f, 0.0f, 1.0f, Weight, , 0.0f, 1.0f); + RNA_def_float_percentage(ot-srna, weight, 1.0f, 0.0f, 1.0f, Weight, , 0.0f, 1.0f); } /*** set radius operator **/ @@ -4195,7 +4195,7 @@ ot-flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* properties */ - RNA_def_float(ot-srna, percent, 0.5f, 0.0f, 1.0f, Percent, Percentage of vertices to select randomly., 0.0001f, 1.0f); + RNA_def_float_percentage(ot-srna, percent, 0.5f, 0.0f, 1.0f, Percent, Percentage of vertices to select randomly., 0.0001f, 1.0f); } /** select every nth */ Modified: branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c === --- branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c 2009-02-17 20:37:23 UTC (rev 19017) +++ branches/blender2.5/blender/source/blender/editors/interface/interface_utils.c 2009-02-17 21:07:01 UTC (rev 19018) @@ -249,6 +249,8 @@ if(RNA_property_subtype(ptr, prop) == PROP_COLOR) but= uiDefButR(block, COL, 0, name, x1, y1, x2, y2, ptr, propname, 0, 0, 0, -1, -1, NULL); } + else if(RNA_property_subtype(ptr, prop) == PROP_PERCENTAGE) + but= uiDefButR(block, NUMSLI, 0, name, x1, y1, x2, y2, ptr, propname, index, 0, 0, -1, -1, NULL); else but= uiDefButR(block, NUM, 0, name, x1, y1, x2, y2, ptr, propname, index, 0, 0, -1, -1, NULL); break; Modified: branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c === --- branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c 2009-02-17 20:37:23 UTC (rev 19017) +++ branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c 2009-02-17 21:07:01 UTC (rev 19018) @@ -3448,10 +3448,10 @@ ot-poll= ED_operator_editmesh; /* flags */ - ot-flag= OPTYPE_REGISTER/*|OPTYPE_UNDO*/; + ot-flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_float(ot-srna, percent, 0.5f, 0.0f, 1.0f, Percent, Percentage of vertices to select randomly., 0.0001f, 1.0f); + RNA_def_float_percentage(ot-srna, percent, 0.5f, 0.0f, 1.0f, Percent, Percentage of vertices to select randomly., 0.0001f, 1.0f); } void editmesh_select_by_material(EditMesh *em, int index) Modified: branches/blender2.5/blender/source/blender/editors/object/object_edit.c === ---
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19035] branches/blender2.5/blender/source /blender/makesrna/intern/rna_particle.c: RNA: fix for bug in particle code, hopefully this solves the crash
Revision: 19035 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19035 Author: blendix Date: 2009-02-18 22:28:04 +0100 (Wed, 18 Feb 2009) Log Message: --- RNA: fix for bug in particle code, hopefully this solves the crash? Modified Paths: -- branches/blender2.5/blender/source/blender/makesrna/intern/rna_particle.c Modified: branches/blender2.5/blender/source/blender/makesrna/intern/rna_particle.c === --- branches/blender2.5/blender/source/blender/makesrna/intern/rna_particle.c 2009-02-18 18:08:33 UTC (rev 19034) +++ branches/blender2.5/blender/source/blender/makesrna/intern/rna_particle.c 2009-02-18 21:28:04 UTC (rev 19035) @@ -34,6 +34,7 @@ #include DNA_particle_types.h #ifdef RNA_RUNTIME + static void rna_PartSettings_start_set(struct PointerRNA *ptr, float value) { ParticleSettings *settings = (ParticleSettings*)ptr-data; @@ -176,7 +177,8 @@ {PARS_DEAD, DEAD, Dead, }, {PARS_UNBORN, UNBORN, Unborn, }, {PARS_ALIVE, ALIVE, Alive, }, - {PARS_DYING, DYING, Dying, } + {PARS_DYING, DYING, Dying, }, + {0, NULL, NULL, NULL} }; srna = RNA_def_struct(brna, Particle, NULL); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19047] branches/blender2.5/blender/source /blender: 2.5:
Revision: 19047 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19047 Author: blendix Date: 2009-02-20 00:53:40 +0100 (Fri, 20 Feb 2009) Log Message: --- 2.5: * Image painting back. 2d paint, 3d paint and projection, undo, pressure, repeating paint operations, etc should all work. Drawing cursor needs a bit of work, only gets shown when enabling texture paint mode now. * Move sculpt, image paint, and vertex/weight paint into a single sculpt_paint module. Doesn't make much difference now, but nice to have it together for better integration and consistency in the future. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/Makefile branches/blender2.5/blender/source/blender/editors/SConscript branches/blender2.5/blender/source/blender/editors/include/ED_screen.h branches/blender2.5/blender/source/blender/editors/include/ED_sculpt.h branches/blender2.5/blender/source/blender/editors/include/ED_view3d.h branches/blender2.5/blender/source/blender/editors/mesh/editface.c branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c branches/blender2.5/blender/source/blender/editors/sculpt_paint/Makefile branches/blender2.5/blender/source/blender/editors/sculpt_paint/SConscript branches/blender2.5/blender/source/blender/editors/space_api/spacetypes.c branches/blender2.5/blender/source/blender/editors/space_image/space_image.c branches/blender2.5/blender/source/blender/editors/space_view3d/drawmesh.c branches/blender2.5/blender/source/blender/editors/space_view3d/drawobject.c branches/blender2.5/blender/source/blender/editors/space_view3d/space_view3d.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_draw.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_intern.h branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_ops.c branches/blender2.5/blender/source/blender/editors/util/ed_util.c branches/blender2.5/blender/source/blender/editors/util/undo.c branches/blender2.5/blender/source/blender/editors/uvedit/Makefile branches/blender2.5/blender/source/blender/editors/uvedit/SConscript branches/blender2.5/blender/source/blender/makesdna/DNA_brush_types.h branches/blender2.5/blender/source/blender/makesdna/DNA_scene_types.h branches/blender2.5/blender/source/blender/makesrna/intern/makesrna.c branches/blender2.5/blender/source/blender/makesrna/intern/rna_brush.c branches/blender2.5/blender/source/blender/windowmanager/WM_types.h branches/blender2.5/blender/source/blender/windowmanager/wm_event_types.h Added Paths: --- branches/blender2.5/blender/source/blender/editors/sculpt_paint/ branches/blender2.5/blender/source/blender/editors/sculpt_paint/paint_image.c branches/blender2.5/blender/source/blender/editors/sculpt_paint/paint_intern.h branches/blender2.5/blender/source/blender/editors/sculpt_paint/paint_ops.c branches/blender2.5/blender/source/blender/editors/sculpt_paint/paint_utils.c branches/blender2.5/blender/source/blender/editors/sculpt_paint/paint_vertex.c branches/blender2.5/blender/source/blender/editors/sculpt_paint/sculpt_stroke.c Removed Paths: - branches/blender2.5/blender/source/blender/editors/sculpt/ branches/blender2.5/blender/source/blender/editors/sculpt_paint/stroke.c branches/blender2.5/blender/source/blender/editors/space_view3d/vpaint.c Modified: branches/blender2.5/blender/source/blender/editors/Makefile === --- branches/blender2.5/blender/source/blender/editors/Makefile 2009-02-19 23:15:27 UTC (rev 19046) +++ branches/blender2.5/blender/source/blender/editors/Makefile 2009-02-19 23:53:40 UTC (rev 19047) @@ -29,6 +29,6 @@ # Bounces make to subdirectories. SOURCEDIR = source/blender/editors -DIRS = armature mesh animation object sculpt datafiles transform screen curve gpencil physics preview uvedit space_outliner space_time space_view3d interface util space_api space_graph space_image space_node space_buttons space_info space_file space_sound space_action space_nla space_script space_text space_sequencer +DIRS = armature mesh animation object sculpt_paint datafiles transform screen curve gpencil physics preview uvedit space_outliner space_time space_view3d interface util space_api space_graph space_image space_node space_buttons space_info space_file space_sound space_action space_nla space_script space_text space_sequencer include nan_subdirs.mk Modified: branches/blender2.5/blender/source/blender/editors/SConscript === --- branches/blender2.5/blender/source/blender/editors/SConscript 2009-02-19 23:15:27
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19062] branches/blender2.5/blender/source /blender: 2.5: Particle Edit, work in progress commit.
Revision: 19062 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19062 Author: blendix Date: 2009-02-20 21:39:27 +0100 (Fri, 20 Feb 2009) Log Message: --- 2.5: Particle Edit, work in progress commit. * Still incomplete and some operators don't work, refresh issues, etc. * Made Hide/Reveal operators consistent for various modes. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c branches/blender2.5/blender/source/blender/editors/armature/editarmature.c branches/blender2.5/blender/source/blender/editors/armature/poseobject.c branches/blender2.5/blender/source/blender/editors/curve/curve_ops.c branches/blender2.5/blender/source/blender/editors/curve/editcurve.c branches/blender2.5/blender/source/blender/editors/include/ED_view3d.h branches/blender2.5/blender/source/blender/editors/mesh/editmesh_mods.c branches/blender2.5/blender/source/blender/editors/mesh/mesh_ops.c branches/blender2.5/blender/source/blender/editors/object/object_edit.c branches/blender2.5/blender/source/blender/editors/physics/editparticle.c branches/blender2.5/blender/source/blender/editors/sculpt_paint/sculpt.c branches/blender2.5/blender/source/blender/editors/space_api/spacetypes.c branches/blender2.5/blender/source/blender/editors/space_image/image_header.c branches/blender2.5/blender/source/blender/editors/space_view3d/drawobject.c branches/blender2.5/blender/source/blender/editors/space_view3d/space_view3d.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_buttons.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_edit.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_select.c branches/blender2.5/blender/source/blender/editors/transform/transform_conversions.c branches/blender2.5/blender/source/blender/editors/util/undo.c branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c branches/blender2.5/blender/source/blender/windowmanager/WM_types.h Added Paths: --- branches/blender2.5/blender/source/blender/editors/include/ED_particle.h Removed Paths: - branches/blender2.5/blender/source/blender/editors/include/ED_editparticle.h Modified: branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c === --- branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c 2009-02-20 19:11:35 UTC (rev 19061) +++ branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c 2009-02-20 20:39:27 UTC (rev 19062) @@ -192,7 +192,7 @@ WM_keymap_add_item(keymap, POSE_OT_hide, HKEY, KM_PRESS, 0, 0); kmi= WM_keymap_add_item(keymap, POSE_OT_hide, HKEY, KM_PRESS, KM_SHIFT, 0); - RNA_boolean_set(kmi-ptr, invert, 1); + RNA_boolean_set(kmi-ptr, unselected, 1); WM_keymap_add_item(keymap, POSE_OT_reveal, HKEY, KM_PRESS, KM_ALT, 0); /*clear pose*/ WM_keymap_add_item(keymap, POSE_OT_rot_clear, RKEY, KM_PRESS, KM_ALT, 0); Modified: branches/blender2.5/blender/source/blender/editors/armature/editarmature.c === --- branches/blender2.5/blender/source/blender/editors/armature/editarmature.c 2009-02-20 19:11:35 UTC (rev 19061) +++ branches/blender2.5/blender/source/blender/editors/armature/editarmature.c 2009-02-20 20:39:27 UTC (rev 19062) @@ -4703,7 +4703,7 @@ Object *ob= CTX_data_active_object(C); bArmature *arm= ob-data; - if(RNA_boolean_get(op-ptr, invert)) + if(RNA_boolean_get(op-ptr, unselected)) bone_looper(ob, arm-bonebase.first, NULL, hide_unselected_pose_bone); else @@ -4719,7 +4719,7 @@ void POSE_OT_hide(wmOperatorType *ot) { /* identifiers */ - ot-name= Hide Selection; + ot-name= Hide Selected; ot-idname= POSE_OT_hide; /* api callbacks */ @@ -4730,7 +4730,7 @@ ot-flag= OPTYPE_REGISTER|OPTYPE_UNDO; /* props */ - RNA_def_boolean(ot-srna, invert, 0, Invert, ); + RNA_def_boolean(ot-srna, unselected, 0, Unselected, ); } static int show_pose_bone(Object *ob, Bone *bone, void *ptr) @@ -4764,7 +4764,7 @@ void POSE_OT_reveal(wmOperatorType *ot) { /* identifiers */ - ot-name= Reveil Selection; + ot-name= Reveal Selected; ot-idname= POSE_OT_reveal; /* api callbacks */ @@ -4773,9 +4773,6 @@ /* flags */ ot-flag= OPTYPE_REGISTER|OPTYPE_UNDO; - - /* props */ - RNA_def_boolean(ot-srna, invert, 0, Invert, ); } /* * RENAMING DISASTERS */
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19063] branches/blender2.5/blender/source /blender/editors/space_graph: 2.5: Fix build temporarily, seems there was a file missing
Revision: 19063 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19063 Author: blendix Date: 2009-02-20 21:43:22 +0100 (Fri, 20 Feb 2009) Log Message: --- 2.5: Fix build temporarily, seems there was a file missing in the graph properties panel commit. Ton, please check. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c branches/blender2.5/blender/source/blender/editors/space_graph/space_graph.c Modified: branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c === --- branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c 2009-02-20 20:39:27 UTC (rev 19062) +++ branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c 2009-02-20 20:43:22 UTC (rev 19063) @@ -99,7 +99,7 @@ WM_operatortype_append(GRAPHEDIT_OT_view_togglehandles); WM_operatortype_append(GRAPHEDIT_OT_set_previewrange); WM_operatortype_append(GRAPHEDIT_OT_view_all); - WM_operatortype_append(GRAPHEDIT_OT_properties); + // XXX file is not in svn: WM_operatortype_append(GRAPHEDIT_OT_properties); /* keyframes */ /* selection */ @@ -202,7 +202,7 @@ /* keymap for all regions */ keymap= WM_keymap_listbase(wm, GraphEdit Generic, SPACE_IPO, 0); - WM_keymap_add_item(keymap, GRAPHEDIT_OT_properties, NKEY, KM_PRESS, 0, 0); + // XXX file is not in svn: WM_keymap_add_item(keymap, GRAPHEDIT_OT_properties, NKEY, KM_PRESS, 0, 0); /* channels */ /* Channels are not directly handled by the Graph Editor module, but are inherited from the Animation module. Modified: branches/blender2.5/blender/source/blender/editors/space_graph/space_graph.c === --- branches/blender2.5/blender/source/blender/editors/space_graph/space_graph.c 2009-02-20 20:39:27 UTC (rev 19062) +++ branches/blender2.5/blender/source/blender/editors/space_graph/space_graph.c 2009-02-20 20:43:22 UTC (rev 19063) @@ -354,7 +354,7 @@ /* set view2d view matrix for scrolling (without scrollers) */ UI_view2d_view_ortho(C, ar-v2d); - graph_region_buttons(C, ar); + // XXX file is not in svn: graph_region_buttons(C, ar); /* restore view matrix? */ UI_view2d_view_restore(C); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [19075] branches/blender2.5/blender/source /blender/editors/space_image/image_panels.c: 2.5: fix for last commit, for case sensitive OSes.
Revision: 19075 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=revroot=bf-blenderrevision=19075 Author: blendix Date: 2009-02-21 19:43:28 +0100 (Sat, 21 Feb 2009) Log Message: --- 2.5: fix for last commit, for case sensitive OSes. Modified Paths: -- branches/blender2.5/blender/source/blender/editors/space_image/image_panels.c Modified: branches/blender2.5/blender/source/blender/editors/space_image/image_panels.c === --- branches/blender2.5/blender/source/blender/editors/space_image/image_panels.c 2009-02-21 18:33:09 UTC (rev 19074) +++ branches/blender2.5/blender/source/blender/editors/space_image/image_panels.c 2009-02-21 18:43:28 UTC (rev 19075) @@ -56,7 +56,7 @@ #include BKE_library.h #include BKE_main.h #include BKE_node.h -#include BKE_packedfile.h +#include BKE_packedFile.h #include BKE_screen.h #include BKE_utildefines.h ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs