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

bge.types.KX_BlenderMaterial.rst « bge_types « rst « python_api « doc - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 0dfc7a10d1360b1fd1100856c3dd832726278104 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
KX_BlenderMaterial(PyObjectPlus)
================================

.. module:: bge.types

base class --- :class:`PyObjectPlus`

.. class:: KX_BlenderMaterial(PyObjectPlus)

   KX_BlenderMaterial

   .. attribute:: shader

      The materials shader.

      :type: :class:`BL_Shader`

   .. attribute:: blending

      Ints used for pixel blending, (src, dst), matching the setBlending method.

      :type: (integer, integer)

   .. attribute:: material_index

      The material's index.

      :type: integer

   .. method:: getShader()

      Returns the material's shader.

      :return: the material's shader
      :rtype: :class:`BL_Shader`

   .. method:: setBlending(src, dest)

      Set the pixel color arithmetic functions.

      :arg src: Specifies how the red, green, blue, and alpha source blending factors are computed.
      :type src: Value in...

         * GL_ZERO,
         * GL_ONE, 
         * GL_SRC_COLOR, 
         * GL_ONE_MINUS_SRC_COLOR, 
         * GL_DST_COLOR, 
         * GL_ONE_MINUS_DST_COLOR, 
         * GL_SRC_ALPHA, 
         * GL_ONE_MINUS_SRC_ALPHA, 
         * GL_DST_ALPHA, 
         * GL_ONE_MINUS_DST_ALPHA, 
         * GL_SRC_ALPHA_SATURATE

      :arg dest: Specifies how the red, green, blue, and alpha destination blending factors are computed.
      :type dest: Value in...

         * GL_ZERO
         * GL_ONE
         * GL_SRC_COLOR
         * GL_ONE_MINUS_SRC_COLOR
         * GL_DST_COLOR
         * GL_ONE_MINUS_DST_COLOR
         * GL_SRC_ALPHA
         * GL_ONE_MINUS_SRC_ALPHA
         * GL_DST_ALPHA
         * GL_ONE_MINUS_DST_ALPHA
         * GL_SRC_ALPHA_SATURATE

   .. method:: getMaterialIndex()

      Returns the material's index.

      :return: the material's index
      :rtype: integer