Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWillian Padovani Germano <wpgermano@gmail.com>2003-07-31 01:15:41 +0400
committerWillian Padovani Germano <wpgermano@gmail.com>2003-07-31 01:15:41 +0400
commitfe07b232b7e7e80569733de2b42e391874de6477 (patch)
tree5c6d95e7869855163aea95d38fff9b485d5d6d12 /source/blender/src/editkey.c
parent35c4c3222caea20d603e51191b3e85790cd76202 (diff)
* got rid of a warning in editipo.c:
changed "get_ipo(key, ..." to "get_ipo((ID *)key, ..." in line 107. * changed insert_meshkey(Mesh *me) to insert_meshkey(Mesh *me, short offline): To call this function from a script, so that it doesn't pop the "relative / absolute" dialog window when the "offline" arg is non-zero. Exppython: * NMesh module: - Added method NMesh.addMaterial(mat) to the NMesh module: alternative safer (aka slower) way to add materials. - Added optional arg to NMesh_update(): if given and equal to 1, the mesh normals are recalculated. - Fixed NMesh.getVertexInfluences: it was segfaulting when a NULL bone was linked to the vertex. Thanks to Jiba on the bf-python mailing list for bug report and sample .blend file. Also made this method give an IndexError when the vertex index is out of range. * Material module: Added specR, specG, specB vars for compatibility with the 2.25 API. Pointed by Manuel Bastioni. * Image module: Exposed image width, height and depth parameters. From a suggestion by jms. * BPython Ref Doc: - Small updates to reflect the above additions. - Added info for the Bone type in the Armature doc.
Diffstat (limited to 'source/blender/src/editkey.c')
-rw-r--r--source/blender/src/editkey.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/source/blender/src/editkey.c b/source/blender/src/editkey.c
index 5d9492d9af7..0edc47ad9c8 100644
--- a/source/blender/src/editkey.c
+++ b/source/blender/src/editkey.c
@@ -104,7 +104,7 @@ static IpoCurve *get_key_icu(Key *key, int keynum) {
*/
IpoCurve *icu;
if (!(key->ipo)) {
- key->ipo = get_ipo(key, ID_KE, 1);
+ key->ipo = get_ipo((ID *)key, ID_KE, 1);
return NULL;
}
@@ -356,7 +356,7 @@ void key_to_mesh(KeyBlock *kb, Mesh *me)
-void insert_meshkey(Mesh *me)
+void insert_meshkey(Mesh *me, short offline)
{
Key *key;
KeyBlock *kb, *kkb;
@@ -365,7 +365,13 @@ void insert_meshkey(Mesh *me)
if(me->key==0) {
me->key= add_key( (ID *)me);
- rel = pupmenu("Insert Vertex Keys %t|Relative keys %x1|Absolute keys %x2");
+
+ if (!offline) /* interactive */
+ rel = pupmenu("Insert Vertex Keys %t|"
+ "Relative keys %x1|Absolute keys %x2");
+ else /* we were called from a script */
+ rel = offline;
+
switch (rel) {
case 1:
me->key->type = KEY_RELATIVE;