[Bf-python] Some questions on 2.28 documents

Tatsuya Nakamura BlenderM at n.email.ne.jp
Wed Sep 3 06:21:38 CEST 2003


Hi, Stephen and Jacques!
Thank you so much for your accurate :) and detailed answers to my questions.
They are really helpful for my Japanese documentation on the new Blender 
Python.

I have another question related to Effect module.
In this module, two sets of methods "getFlag()/setFlag()" and 
"getType()/setType()"
work similar way.:
 - getFlag() Retreives the flag of an effect object
             Returns: the flag of an effect object :
             0 = build effect; 1 = wave effect;2 = particle effect; 
(type=int)
   (*above description is from the new Python document.)
 - getType() Returns the type of the effect :
             0 : Build effect; 1 : Particle effect; 2 : Wave effect
   (*above description is from the last Jacques' mail.)

However, the return value of getFlag looks different from what the 
document says
when its type is "Wave". I have attached a sample Blender file. After 
open the file,
you can change the type of effects on the Buttons window and execute the 
Python
on the Text window to see the results.
The return values of getFlag are various when its type is "Wave". 
(Please be aware
that "Build" effect has no method related to either flag or type. If you 
set a effect type
to "Build", you will see an error message on your console.)
It seems that the return value changes depends on its order in the 
effect list on the script.

I guess this might be a bug on the implementation of getFlag method.
Any suggestion is welcome!

Again, thanks a lot for all of your help.
Tatsuya.

Jacques Guignot wrote:

> Hi, Tatsuya!
> Here are some answers to the (accurate) questions you asked.
>
> Tatsuya Nakamura wrote:
>
>> 1-a) About "getControlPoint" method.
>
>
> Stephen already answered this one.
>
>
>
>> 1-b) About "getType" method. The document says "The mode of the curve
>> is a combination of 4 parameters. Bits 0,1,2 : "Back", "Front" and "3D".
>> Bit 3 : "CurvePath" is set. Bit 4 : "CurveFollow" is set."
>> I can see the three options ("Back", "Front" and "3D") for Bit 0,1,2 
>> on the
>> Blender's Buttons window.
>> What do the rest of Bits ("CurvePath" and "CurveFollow") mean?
>
>
> These 2 bits are only used if you use the curve to duplicate objects 
> along the curve. They have corresponding buttons u can see when 
> hitting F7 (animation windows)
>
>
>>
>> 2) Effect class
>>
>> 2-a) What is the "minfac" of the wave effect? I cannot find this 
>> value on the
>> Buttons window.
>
>
> Sorry. My fault. The minfac is not useful. It -was- a parameter for 
> wave effects, but is now obsolete.
>
>> 2-b) There is no "type" variable in this class, however, there are 
>> two methods
>> "getType" and "setType". What are these methods for?
>
>
> Returns the type of the effect : 0 : Build effect
>                                                 1 : Particle effect
>                                                 2 : Wave effect
> The settype function is not really useful (transforming a build effect 
> in a wave effect...hmmm...). But I wrote it because some other effects 
> may be written later, and this function *could* be useful.
>
>
>>
>> 3) World class
>>
>> There is no explanation about the variable "mode". Is it not 
>> implemented on 2.28?
>
>
>
> mode is a combination of 2 bits
>
> bit 1 (last one) indicates the world has mist
> bit 2 indicates the world has stars.
>
>>
>> 4) Metaball class
>>
>> What are those five parametors "expx", "expy", "expz", "rad", and 
>> "rad2" represents?
>> I cannot see the correspondent parametors with them on the Buttons 
>> window.
>
>
>
> Sorry again. These parameters are used for internal computations in 
> the mballs.
> They should be removed, and it is usually a bad thing to change them.
> They can (should) be discarded.
>
>
> Thanks for your interest. I really like so accurate questions!
>
>
>
> _______________________________________________
> Bf-python mailing list
> Bf-python at blender.org
> http://www.blender.org/mailman/listinfo/bf-python
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sampleEffect01.zip
Type: application/x-zip-compressed
Size: 13970 bytes
Desc: not available
URL: <http://lists.blender.org/pipermail/bf-python/attachments/20030903/51c6f529/attachment.bin>


More information about the Bf-python mailing list