Merge pull request #5083 from J08nY/classref

Added classref for Image, ImageTexture, LargeTexture
This commit is contained in:
Rémi Verschelde 2016-06-07 12:23:12 +02:00
commit bf98095f46
2 changed files with 258 additions and 3 deletions

View file

@ -1663,6 +1663,9 @@ _VariantCall::addfunc(Variant::m_vtype,Variant::m_ret,_SCS(#m_method),VCALL(m_cl
_VariantCall::constant_data[Variant::IMAGE].value["FORMAT_ATC_ALPHA_INTERPOLATED"]=Image::FORMAT_ATC_ALPHA_INTERPOLATED;
_VariantCall::constant_data[Variant::IMAGE].value["FORMAT_CUSTOM"]=Image::FORMAT_CUSTOM;
_VariantCall::constant_data[Variant::IMAGE].value["INTERPOLATE_NEAREST"]=Image::INTERPOLATE_NEAREST;
_VariantCall::constant_data[Variant::IMAGE].value["INTERPOLATE_BILINEAR"]=Image::INTERPOLATE_BILINEAR;
_VariantCall::constant_data[Variant::IMAGE].value["INTERPOLATE_CUBIC"]=Image::INTERPOLATE_CUBIC;
}
void unregister_variant_methods() {

View file

@ -1809,9 +1809,33 @@
</constant>
<constant name="PROPERTY_USAGE_NETWORK" value="4">
</constant>
<constant name="PROPERTY_USAGE_EDITOR_HELPER" value="8">
</constant>
<constant name="PROPERTY_USAGE_CHECKABLE" value="16">
</constant>
<constant name="PROPERTY_USAGE_CHECKED" value="32">
</constant>
<constant name="PROPERTY_USAGE_INTERNATIONALIZED" value="64">
</constant>
<constant name="PROPERTY_USAGE_BUNDLE" value="128">
</constant>
<constant name="PROPERTY_USAGE_CATEGORY" value="256">
</constant>
<constant name="PROPERTY_USAGE_STORE_IF_NONZERO" value="512">
</constant>
<constant name="PROPERTY_USAGE_STORE_IF_NONONE" value="1024">
</constant>
<constant name="PROPERTY_USAGE_NO_INSTANCE_STATE" value="2048">
</constant>
<constant name="PROPERTY_USAGE_RESTART_IF_CHANGED" value="4096">
</constant>
<constant name="PROPERTY_USAGE_DEFAULT" value="7">
Default usage (storage and editor).
</constant>
<constant name="PROPERTY_USAGE_DEFAULT_INTL" value="71">
</constant>
<constant name="PROPERTY_USAGE_NOEDITOR" value="5">
</constant>
<constant name="METHOD_FLAG_NORMAL" value="1">
</constant>
<constant name="METHOD_FLAG_EDITOR" value="2">
@ -9404,6 +9428,96 @@
<description>
</description>
</method>
<method name="has_icon_override" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<description>
</description>
</method>
<method name="has_stylebox_override" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<description>
</description>
</method>
<method name="has_font_override" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<description>
</description>
</method>
<method name="has_color_override" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<description>
</description>
</method>
<method name="has_constant_override" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<description>
</description>
</method>
<method name="has_icon" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<argument index="1" name="type" type="String" default="&quot;&quot;">
</argument>
<description>
</description>
</method>
<method name="has_stylebox" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<argument index="1" name="type" type="String" default="&quot;&quot;">
</argument>
<description>
</description>
</method>
<method name="has_font" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<argument index="1" name="type" type="String" default="&quot;&quot;">
</argument>
<description>
</description>
</method>
<method name="has_color" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<argument index="1" name="type" type="String" default="&quot;&quot;">
</argument>
<description>
</description>
</method>
<method name="has_constant" qualifiers="const">
<return type="bool">
</return>
<argument index="0" name="name" type="String">
</argument>
<argument index="1" name="type" type="String" default="&quot;&quot;">
</argument>
<description>
</description>
</method>
<method name="get_parent_control" qualifiers="const">
<return type="Control">
</return>
@ -9523,6 +9637,10 @@
<description>
</description>
</method>
<method name="minimum_size_changed">
<description>
</description>
</method>
</methods>
<signals>
<signal name="focus_enter">
@ -15119,6 +15237,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="2" name="dest" type="Vector2" default="0">
</argument>
<description>
Copy a "src_rect" [Rect2] from "src" [Image] to this [Image] on coordinates "dest".
</description>
</method>
<method name="brush_transfer">
@ -15129,6 +15248,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="2" name="pos" type="Vector2" default="0">
</argument>
<description>
Transfer data from "src" to this [Image] using a "brush" as a mask/brush on coordinates "pos".
</description>
</method>
<method name="brushed">
@ -15141,6 +15261,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="2" name="pos" type="Vector2" default="0">
</argument>
<description>
Return a new [Image] from this [Image] that is created by brushhing see [method brush_transfer].
</description>
</method>
<method name="compressed">
@ -15149,6 +15270,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="format" type="int" default="0">
</argument>
<description>
Return a new compressed [Image] from this [Image] using one of [Image].COMPRESS_*.
</description>
</method>
<method name="converted">
@ -15157,18 +15279,21 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="format" type="int" default="0">
</argument>
<description>
Return a new [Image] from this [Image] with a different format.
</description>
</method>
<method name="decompressed">
<return type="Image">
</return>
<description>
Return a new decompressed [Image].
</description>
</method>
<method name="empty">
<return type="bool">
</return>
<description>
Return whether this [Image] is empty(no data).
</description>
</method>
<method name="fix_alpha_edges">
@ -15179,18 +15304,21 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<return type="RawArray">
</return>
<description>
Return the raw data of the [Image].
</description>
</method>
<method name="get_format">
<return type="int">
</return>
<description>
Return the format of the [Image], one of [Image].FORMAT_*.
</description>
</method>
<method name="get_height">
<return type="int">
</return>
<description>
Return the height of the [Image].
</description>
</method>
<method name="get_pixel">
@ -15203,6 +15331,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="2" name="mipmap_level" type="int" default="0">
</argument>
<description>
Return the color of the pixel in the [Image] on coordinates "x,y" on mipmap level "mipmap_level".
</description>
</method>
<method name="get_rect">
@ -15211,18 +15340,21 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="area" type="Rect2" default="0">
</argument>
<description>
Return a new [Image] that is a copy of "area" in this [Image].
</description>
</method>
<method name="get_used_rect">
<return type="Rect2">
</return>
<description>
Return the area of this [Image] that is used/visibly colored/opaque.
</description>
</method>
<method name="get_width">
<return type="int">
</return>
<description>
Return the width of the [Image].
</description>
</method>
<method name="load">
@ -15231,6 +15363,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="path" type="String" default="0">
</argument>
<description>
Load an [Image].
</description>
</method>
<method name="put_pixel">
@ -15243,6 +15376,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="3" name="mipmap_level" type="int" default="0">
</argument>
<description>
Put a pixel of "color" on coordinates "x,y" on mipmap level "mipmap_level".
</description>
</method>
<method name="resized">
@ -15255,6 +15389,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="2" name="interpolation" type="int" default="1">
</argument>
<description>
Return a new [Image] from this [Image] that is resized to size "x,y" using [Image].INTERPOLATE_*.
</description>
</method>
<method name="save_png">
@ -15263,6 +15398,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="path" type="String" default="0">
</argument>
<description>
Save this [Image] as a png.
</description>
</method>
<method name="Image">
@ -15336,12 +15472,20 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
</constant>
<constant name="FORMAT_CUSTOM" value="22">
</constant>
<constant name="INTERPOLATE_NEAREST" value="0">
</constant>
<constant name="INTERPOLATE_BILINEAR" value="1">
</constant>
<constant name="INTERPOLATE_CUBIC" value="2">
</constant>
</constants>
</class>
<class name="ImageTexture" inherits="Texture" category="Core">
<brief_description>
A [Texture] based on an [Image].
</brief_description>
<description>
A [Texture] based on an [Image]. Can be created from an [Image].
</description>
<methods>
<method name="create">
@ -15354,6 +15498,9 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="3" name="flags" type="int" default="7">
</argument>
<description>
Create a new [ImageTexture] with "width" and "height".
"format" one of [Image].FORMAT_*.
"flags" one or more of [Texture].FLAG_*.
</description>
</method>
<method name="create_from_image">
@ -15362,54 +15509,63 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="1" name="flags" type="int" default="7">
</argument>
<description>
Create a new [ImageTexture] from an [Image] with "flags" from [Texture].FLAG_*.
</description>
</method>
<method name="get_format" qualifiers="const">
<return type="int">
</return>
<description>
Return the format of the [ImageTexture], one of [Image].FORMAT_*.
</description>
</method>
<method name="load">
<argument index="0" name="path" type="String">
</argument>
<description>
Load an [ImageTexure].
</description>
</method>
<method name="set_data">
<argument index="0" name="image" type="Image">
</argument>
<description>
Set the [Image] of this [ImageTexture].
</description>
</method>
<method name="get_data" qualifiers="const">
<return type="Image">
</return>
<description>
Return the [Image] of this [ImageTexture].
</description>
</method>
<method name="set_storage">
<argument index="0" name="mode" type="int">
</argument>
<description>
Set the storage type. One of [ImageTexture].STORAGE_*.
</description>
</method>
<method name="get_storage" qualifiers="const">
<return type="int">
</return>
<description>
Return the storage type. One of [ImageTexture].STORAGE_*.
</description>
</method>
<method name="set_lossy_storage_quality">
<argument index="0" name="quality" type="float">
</argument>
<description>
Set the storage quality in case of [ImageTexture].STORAGE_COMPRESS_LOSSY.
</description>
</method>
<method name="get_lossy_storage_quality" qualifiers="const">
<return type="float">
</return>
<description>
Return the storage quality for [ImageTexture].STORAGE_COMPRESS_LOSSY.
</description>
</method>
<method name="fix_alpha_edges">
@ -15437,10 +15593,13 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
</methods>
<constants>
<constant name="STORAGE_RAW" value="0">
[Image] data is stored raw and unaltered.
</constant>
<constant name="STORAGE_COMPRESS_LOSSY" value="1">
[Image] data is compressed with a lossy algorithm. You can set the storage quality with [method set_lossy_storage_quality].
</constant>
<constant name="STORAGE_COMPRESS_LOSSLESS" value="2">
[Image] data is compressed with a lossless algorithm.
</constant>
</constants>
</class>
@ -17861,8 +18020,11 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
</class>
<class name="LargeTexture" inherits="Texture" category="Core">
<brief_description>
A Texture capable of storing many smaller Textures with offsets.
</brief_description>
<description>
A Texture capable of storing many smaller Textures with offsets.
You can dynamically add pieces(Textures) to this fLargeTexture] using different offsets.
</description>
<methods>
<method name="add_piece">
@ -17873,6 +18035,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="1" name="texture" type="Texture">
</argument>
<description>
Add another [Texture] to this [LargeTexture], starting on offset "ofs".
</description>
</method>
<method name="set_piece_offset">
@ -17881,6 +18044,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="1" name="ofs" type="Vector2">
</argument>
<description>
Set the offset of the piece with index "idx" to "ofs".
</description>
</method>
<method name="set_piece_texture">
@ -17889,22 +18053,26 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="1" name="texture" type="Texture">
</argument>
<description>
Set the [Texture] of the piece with index "idx" to "ofs".
</description>
</method>
<method name="set_size">
<argument index="0" name="size" type="Vector2">
</argument>
<description>
Set the size of this [LargeTexture].
</description>
</method>
<method name="clear">
<description>
Clear the [LargeTexture].
</description>
</method>
<method name="get_piece_count" qualifiers="const">
<return type="int">
</return>
<description>
Return the number of pieces currently in this [LargeTexture].
</description>
</method>
<method name="get_piece_offset" qualifiers="const">
@ -17913,6 +18081,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="idx" type="int">
</argument>
<description>
Return the offset of the piece with index "idx".
</description>
</method>
<method name="get_piece_texture" qualifiers="const">
@ -17921,6 +18090,7 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<argument index="0" name="idx" type="int">
</argument>
<description>
Return the [Texture] of the piece with index "idx".
</description>
</method>
</methods>
@ -18672,6 +18842,36 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
</theme_item>
</theme_items>
</class>
<class name="Listener" inherits="Spatial" category="Core">
<brief_description>
</brief_description>
<description>
</description>
<methods>
<method name="make_current">
<description>
</description>
</method>
<method name="clear_current">
<description>
</description>
</method>
<method name="is_current" qualifiers="const">
<return type="bool">
</return>
<description>
</description>
</method>
<method name="get_listener_transform" qualifiers="const">
<return type="Transform">
</return>
<description>
</description>
</method>
</methods>
<constants>
</constants>
</class>
<class name="MainLoop" inherits="Object" category="Core">
<brief_description>
Main loop is the abstract main loop base class.
@ -22296,6 +22496,18 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<description>
</description>
</method>
<method name="set_use_vsync">
<argument index="0" name="enable" type="bool">
</argument>
<description>
</description>
</method>
<method name="is_vsnc_enabled" qualifiers="const">
<return type="bool">
</return>
<description>
</description>
</method>
</methods>
<constants>
<constant name="DAY_SUNDAY" value="0">
@ -24239,6 +24451,18 @@ Example: (content-length:12), (Content-Type:application/json; charset=UTF-8)
<description>
</description>
</method>
<method name="set_region_rect">
<argument index="0" name="rect" type="Rect2">
</argument>
<description>
</description>
</method>
<method name="get_region_rect" qualifiers="const">
<return type="Rect2">
</return>
<description>
</description>
</method>
<method name="set_draw_center">
<argument index="0" name="draw_center" type="bool">
</argument>
@ -36652,6 +36876,14 @@ This method controls whether the position between two cached points is interpola
<description>
</description>
</method>
<method name="erase">
<argument index="0" name="pos" type="int">
</argument>
<argument index="1" name="chars" type="int">
</argument>
<description>
</description>
</method>
<method name="extension">
<return type="String">
</return>
@ -37373,6 +37605,18 @@ This method controls whether the position between two cached points is interpola
<description>
</description>
</method>
<method name="set_region_rect">
<argument index="0" name="region" type="Rect2">
</argument>
<description>
</description>
</method>
<method name="get_region_rect" qualifiers="const">
<return type="Rect2">
</return>
<description>
</description>
</method>
<method name="set_draw_center">
<argument index="0" name="enable" type="bool">
</argument>
@ -41705,6 +41949,12 @@ This method controls whether the position between two cached points is interpola
2-element structure that can be used to represent positions in 2d-space, or any other pair of numeric values.
</description>
<methods>
<method name="abs">
<return type="Vector2">
</return>
<description>
</description>
</method>
<method name="angle">
<return type="float">
</return>
@ -44551,11 +44801,13 @@ This method controls whether the position between two cached points is interpola
</argument>
<argument index="1" name="arg1" type="Rect2">
</argument>
<argument index="2" name="arg2" type="RID">
<argument index="2" name="arg2" type="Rect2">
</argument>
<argument index="3" name="arg3" type="RealArray">
<argument index="3" name="arg3" type="RID">
</argument>
<argument index="4" name="arg4" type="Color" default="Color(1,1,1,1)">
<argument index="4" name="arg4" type="RealArray">
</argument>
<argument index="5" name="arg5" type="Color" default="Color(1,1,1,1)">
</argument>
<description>
</description>