Add support for generating noise images with an offset.
This commit is contained in:
parent
1450a72bfa
commit
97c8d9f348
6 changed files with 31 additions and 6 deletions
|
|
@ -31,6 +31,9 @@
|
|||
<member name="noise" type="OpenSimplexNoise" setter="set_noise" getter="get_noise">
|
||||
The [OpenSimplexNoise] instance used to generate the noise.
|
||||
</member>
|
||||
<member name="noise_offset" type="Vector2" setter="set_noise_offset" getter="get_noise_offset" default="Vector2( 0, 0 )">
|
||||
An offset used to specify the noise space coordinate of the top left corner of the generated noise. This value is ignored if [member seamless] is enabled.
|
||||
</member>
|
||||
<member name="seamless" type="bool" setter="set_seamless" getter="get_seamless" default="false">
|
||||
Whether the texture can be tiled without visible seams or not. Seamless textures take longer to generate.
|
||||
[b]Note:[/b] Seamless noise has a lower contrast compared to non-seamless noise. This is due to the way noise uses higher dimensions for generating seamless noise.
|
||||
|
|
|
|||
|
|
@ -31,8 +31,10 @@
|
|||
</argument>
|
||||
<argument index="1" name="height" type="int">
|
||||
</argument>
|
||||
<argument index="2" name="noise_offset" type="Vector2" default="Vector2( 0, 0 )">
|
||||
</argument>
|
||||
<description>
|
||||
Generate a noise image in [constant Image.FORMAT_L8] format with the requested [code]width[/code] and [code]height[/code], based on the current noise parameters.
|
||||
Generate a noise image in [constant Image.FORMAT_L8] format with the requested [code]width[/code] and [code]height[/code], based on the current noise parameters. If [code]noise_offset[/code] is specified, then the offset value is used as the coordinates of the top-left corner of the generated noise.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_1d" qualifiers="const">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue