aboutsummaryrefslogtreecommitdiffstats
path: root/pages/develop/api/efl/gfx/map/method/lightning_3d.txt
blob: 982220b6cb2d5b0712ac967bde0bee3ca3ed22e5 (plain) (blame)
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
~~Title: Efl.Gfx.Map.lightning_3d~~
===== Signature =====

<code>
lightning_3d {
    params {
        @in pivot: free(const(Efl.Gfx), efl_del);
        @in lx: double;
        @in ly: double;
        @in lz: double;
        @in lr: int;
        @in lg: int;
        @in lb: int;
        @in ar: int;
        @in ag: int;
        @in ab: int;
    }
}
</code>

===== C signature =====

<code c>
void efl_gfx_map_lightning_3d(Eo *obj, const Efl_Gfx *pivot, double lx, double ly, double lz, int lr, int lg, int lb, int ar, int ag, int ab);
</code>

===== Parameters =====

  * **pivot** //(in)// - %%A pivot object for the light point, can be %%''null''%%.%%
  * **lx** //(in)// - %%X relative coordinate in space of light point.%%
  * **ly** //(in)// - %%Y relative coordinate in space of light point.%%
  * **lz** //(in)// - %%Z absolute coordinate in space of light point.%%
  * **lr** //(in)// - %%Light red value (0 - 255).%%
  * **lg** //(in)// - %%Light green value (0 - 255).%%
  * **lb** //(in)// - %%Light blue value (0 - 255).%%
  * **ar** //(in)// - %%Ambient color red value (0 - 255).%%
  * **ag** //(in)// - %%Ambient color green value (0 - 255).%%
  * **ab** //(in)// - %%Ambient color blue value (0 - 255).%%

===== Description =====

%%Apply a lightning effect on the object.%%

%%This is used to apply lighting calculations (from a single light source) to a given mapped object. The R, G and B values of each vertex will be modified to reflect the lighting based on the light point coordinates, the light color and the ambient color, and at what angle the map is facing the light source. A surface should have its points be declared in a clockwise fashion if the face is "facing" towards you (as opposed to away from you) as faces have a "logical" side for lighting.%%

%%The coordinates are set relative to the given %%''pivot''%% object. If its geometry changes, then the absolute position of the rotation center will change accordingly. The Z position is absolute. If the %%''pivot''%% is %%''null''%% then this object will be its own pivot.%%

//Since 1.20//
{{page>:develop:api-include:efl:gfx:map:method:lightning_3d:description&nouser&nolink&nodate}}

===== Implemented by =====

  * **Efl.Gfx.Map.lightning_3d**