From 145ab8c49efe0de188a55f4c682dd5fcf916f105 Mon Sep 17 00:00:00 2001 From: Porteries Tristan Date: Fri, 3 Jul 2015 11:47:48 +0200 Subject: =?UTF-8?q?BGE:=20Extend=20Python=20API=20for=20KX=5FBlenderMateri?= =?UTF-8?q?al=20(specular,=20diffuse=E2=80=A6)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add support for material diffuse, specular… in KX_BlenderMaterial python proxy. And use mathutils in KX_BlenderMaterial for the specular and diffuse color in KX_BlenderMaterial. Reviewers: sybren, brita_, kupoman, agoose77, dfelinto, moguri, campbellbarton, hg1 Reviewed By: moguri, campbellbarton, hg1 Subscribers: dfelinto Projects: #game_engine Differential Revision: https://developer.blender.org/D1298 --- .../rst/bge_types/bge.types.KX_BlenderMaterial.rst | 42 ++++++++++++++++++++++ 1 file changed, 42 insertions(+) (limited to 'doc/python_api/rst/bge_types') diff --git a/doc/python_api/rst/bge_types/bge.types.KX_BlenderMaterial.rst b/doc/python_api/rst/bge_types/bge.types.KX_BlenderMaterial.rst index 80450526c9a..17f54031ec3 100644 --- a/doc/python_api/rst/bge_types/bge.types.KX_BlenderMaterial.rst +++ b/doc/python_api/rst/bge_types/bge.types.KX_BlenderMaterial.rst @@ -89,6 +89,48 @@ base class --- :class:`PyObjectPlus` :return: the material's shader :rtype: :class:`BL_Shader` + .. attribute:: alpha + + The material's alpha transparency. + + :type: float between 0.0 and 1.0 inclusive + + .. attribute:: hardness + + How hard (sharp) the material's specular reflection is. + + :type: integer between 1 and 511 inclusive + + .. attribute:: emit + + Amount of light to emit. + + :type: float between 0.0 and 2.0 inclusive + + .. attribute:: specularIntensity + + How intense (bright) the material's specular reflection is. + + :type: float between 0.0 and 1.0 inclusive + + .. attribute:: diffuseIntensity + + The material's amount of diffuse reflection. + + :type: float between 0.0 and 1.0 inclusive + + .. attribute:: specularColor + + The material's specular color. + + :type: :class:`mathutils.Color` + + .. attribute:: diffuseColor + + The material's diffuse color. + + :type: :class:`mathutils.Color` + .. method:: setBlending(src, dest) Set the pixel color arithmetic functions. -- cgit v1.2.3