[Bf-blender-cvs] [171433e8413] master: PyDoc: Improve description of texture.evaluate
Aaron Carlisle
noreply at git.blender.org
Thu Aug 5 01:26:11 CEST 2021
Commit: 171433e841379e7efad069bbda9880fb271e2fc4
Author: Aaron Carlisle
Date: Wed Aug 4 19:26:01 2021 -0400
Branches: master
https://developer.blender.org/rB171433e841379e7efad069bbda9880fb271e2fc4
PyDoc: Improve description of texture.evaluate
Inspired by the old 2.49 docs: https://docs.blender.org/api/249PythonDoc/Texture.Texture-class.html#evaluate
===================================================================
M source/blender/makesrna/intern/rna_texture_api.c
===================================================================
diff --git a/source/blender/makesrna/intern/rna_texture_api.c b/source/blender/makesrna/intern/rna_texture_api.c
index 42b3e4420c1..c46b9acf986 100644
--- a/source/blender/makesrna/intern/rna_texture_api.c
+++ b/source/blender/makesrna/intern/rna_texture_api.c
@@ -61,12 +61,30 @@ void RNA_api_texture(StructRNA *srna)
func = RNA_def_function(srna, "evaluate", "texture_evaluate");
RNA_def_function_ui_description(func, "Evaluate the texture at the coordinates given");
- parm = RNA_def_float_vector(func, "value", 3, NULL, -FLT_MAX, FLT_MAX, "", "", -1e4, 1e4);
+ parm = RNA_def_float_vector(func,
+ "value",
+ 3,
+ NULL,
+ -FLT_MAX,
+ FLT_MAX,
+ "The object coordinates (x,y,z) used to generate/map the texture",
+ "",
+ -1e4,
+ 1e4);
RNA_def_parameter_flags(parm, 0, PARM_REQUIRED);
-
/* return location and normal */
parm = RNA_def_float_vector(
- func, "result", 4, NULL, -FLT_MAX, FLT_MAX, "Result", NULL, -1e4, 1e4);
+ func,
+ "result",
+ 4,
+ NULL,
+ -FLT_MAX,
+ FLT_MAX,
+ "The result of the texture where (x,y,z,w) are (red, green, blue, intensity). For greyscale "
+ "textures, often intensity only will be used",
+ NULL,
+ -1e4,
+ 1e4);
RNA_def_parameter_flags(parm, PROP_THICK_WRAP, 0);
RNA_def_function_output(func, parm);
}
More information about the Bf-blender-cvs
mailing list