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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
|
---@class cc.RenderTexture :cc.Node
local RenderTexture={ }
cc.RenderTexture=RenderTexture
---* Used for grab part of screen to a texture. <br>
---* param rtBegin The position of renderTexture on the fullRect.<br>
---* param fullRect The total size of screen.<br>
---* param fullViewport The total viewportSize.
---@param rtBegin vec2_table
---@param fullRect rect_table
---@param fullViewport rect_table
---@return self
function RenderTexture:setVirtualViewport (rtBegin,fullRect,fullViewport) end
---* Clears the texture with a specified stencil value.<br>
---* param stencilValue A specified stencil value.
---@param stencilValue int
---@return self
function RenderTexture:clearStencil (stencilValue) end
---* Value for clearDepth. Valid only when "autoDraw" is true. <br>
---* return Value for clearDepth.
---@return float
function RenderTexture:getClearDepth () end
---* Value for clear Stencil. Valid only when "autoDraw" is true.<br>
---* return Value for clear Stencil.
---@return int
function RenderTexture:getClearStencil () end
---* Set Value for clear Stencil.<br>
---* param clearStencil Value for clear Stencil.
---@param clearStencil int
---@return self
function RenderTexture:setClearStencil (clearStencil) end
---* Sets the Sprite being used. <br>
---* param sprite A Sprite.
---@param sprite cc.Sprite
---@return self
function RenderTexture:setSprite (sprite) end
---* Gets the Sprite being used. <br>
---* return A Sprite.
---@return cc.Sprite
function RenderTexture:getSprite () end
---* When enabled, it will render its children into the texture automatically. Disabled by default for compatibility reasons.<br>
---* Will be enabled in the future.<br>
---* return Return the autoDraw value.
---@return boolean
function RenderTexture:isAutoDraw () end
---@overload fun(string:string,int:int,boolean:boolean,function:function):self
---@overload fun(string:string,int1:boolean,boolean2:function):self
---@param fileName string
---@param format int
---@param isRGBA boolean
---@param callback function
---@return boolean
function RenderTexture:saveToFileAsNonPMA (fileName,format,isRGBA,callback) end
---* Flag: Use stack matrix computed from scene hierarchy or generate new modelView and projection matrix.<br>
---* param keepMatrix Whether or not use stack matrix computed from scene hierarchy or generate new modelView and projection matrix.<br>
---* js NA
---@param keepMatrix boolean
---@return self
function RenderTexture:setKeepMatrix (keepMatrix) end
---* Set flags.<br>
---* param clearFlags set clear flags.
---@param clearFlags int
---@return self
function RenderTexture:setClearFlags (clearFlags) end
---* Starts grabbing.
---@return self
function RenderTexture:begin () end
---@overload fun(string:string,int:int,boolean:boolean,function:function):self
---@overload fun(string:string,int1:boolean,boolean2:function):self
---@param filename string
---@param format int
---@param isRGBA boolean
---@param callback function
---@return boolean
function RenderTexture:saveToFile (filename,format,isRGBA,callback) end
---* Set a valve to control whether or not render its children into the texture automatically. <br>
---* param isAutoDraw Whether or not render its children into the texture automatically.
---@param isAutoDraw boolean
---@return self
function RenderTexture:setAutoDraw (isAutoDraw) end
---* Set color value. <br>
---* param clearColor Color value.
---@param clearColor color4f_table
---@return self
function RenderTexture:setClearColor (clearColor) end
---* Ends grabbing.<br>
---* lua endToLua
---@return self
function RenderTexture:endToLua () end
---@overload fun(float:float,float:float,float:float,float:float,float:float):self
---@overload fun(float:float,float:float,float:float,float:float):self
---@overload fun(float:float,float:float,float:float,float:float,float:float,int:int):self
---@param r float
---@param g float
---@param b float
---@param a float
---@param depthValue float
---@param stencilValue int
---@return self
function RenderTexture:beginWithClear (r,g,b,a,depthValue,stencilValue) end
---* Clears the texture with a specified depth value. <br>
---* param depthValue A specified depth value.
---@param depthValue float
---@return self
function RenderTexture:clearDepth (depthValue) end
---* Clear color value. Valid only when "autoDraw" is true. <br>
---* return Color value.
---@return color4f_table
function RenderTexture:getClearColor () end
---* Clears the texture with a color. <br>
---* param r Red.<br>
---* param g Green.<br>
---* param b Blue.<br>
---* param a Alpha.
---@param r float
---@param g float
---@param b float
---@param a float
---@return self
function RenderTexture:clear (r,g,b,a) end
---* Valid when "autoDraw" is true.<br>
---* return Clear flags.
---@return int
function RenderTexture:getClearFlags () end
---* Set Value for clearDepth.<br>
---* param clearDepth Value for clearDepth.
---@param clearDepth float
---@return self
function RenderTexture:setClearDepth (clearDepth) end
---@overload fun(int:int,int:int,int:int,int:int):self
---@overload fun(int:int,int:int,int:int):self
---@param w int
---@param h int
---@param format int
---@param depthStencilFormat int
---@return boolean
function RenderTexture:initWithWidthAndHeight (w,h,format,depthStencilFormat) end
---@overload fun(int:int,int:int,int:int):self
---@overload fun(int:int,int:int,int:int,int:int):self
---@overload fun(int:int,int:int):self
---@param w int
---@param h int
---@param format int
---@param depthStencilFormat int
---@return self
function RenderTexture:create (w,h,format,depthStencilFormat) end
---*
---@param renderer cc.Renderer
---@param transform mat4_table
---@param flags unsigned_int
---@return self
function RenderTexture:draw (renderer,transform,flags) end
---*
---@param renderer cc.Renderer
---@param parentTransform mat4_table
---@param parentFlags unsigned_int
---@return self
function RenderTexture:visit (renderer,parentTransform,parentFlags) end
---* FIXME: should be protected.<br>
---* but due to a bug in PowerVR + Android,<br>
---* the constructor is public again.<br>
---* js ctor
---@return self
function RenderTexture:RenderTexture () end
|