-
-
Notifications
You must be signed in to change notification settings - Fork 22.8k
Fix miscellaneous oddities around the class reference (part 6) #107536
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Fix miscellaneous oddities around the class reference (part 6) #107536
Conversation
765a896
to
5735913
Compare
@@ -31,7 +31,7 @@ | |||
</methods> | |||
<members> | |||
<member name="cast_shadow" type="int" setter="set_cast_shadows_setting" getter="get_cast_shadows_setting" enum="GeometryInstance3D.ShadowCastingSetting" default="1"> | |||
The selected shadow casting flag. | |||
The mode used to cast shadows from this instance. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alternative which I am genuinely not sure.
The mode used to cast shadows from this instance. | |
The way in which this instance casts shadows. |
<param index="0" name="file" type="String" /> | ||
<description> | ||
Returns file size in bytes, or [code]-1[/code] on error. | ||
Returns the size of the file at the given path, in bytes, or [code]-1[/code] on error. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, file
is actually a file path. Put a pin on this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it should be changed to path
, renaming argument is not breaking change.
@@ -3745,7 +3745,7 @@ | |||
<param index="7" name="layered_type" type="int" enum="RenderingServer.TextureLayeredType" default="0" /> | |||
<description> | |||
Creates a texture based on a native handle that was created outside of Godot's renderer. | |||
[b]Note:[/b] If using only the rendering device renderer, it's recommend to use [method RenderingDevice.texture_create_from_extension] together with [method RenderingServer.texture_rd_create], rather than this method. It will give you much more control over the texture's format and usage. | |||
[b]Note:[/b] If using only the rendering device renderer, it's recommend to use [method RenderingDevice.texture_create_from_extension] together with [method RenderingServer.texture_rd_create], rather than this method. This way, the texture's format and usage can be controlled more effectively. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reason this was done is because the previous sentence is indirect (no "you"). But, alternatively:
[b]Note:[/b] If using only the rendering device renderer, it's recommend to use [method RenderingDevice.texture_create_from_extension] together with [method RenderingServer.texture_rd_create], rather than this method. This way, the texture's format and usage can be controlled more effectively. | |
[b]Note:[/b] If using only the rendering device renderer, it's recommend to use [method RenderingDevice.texture_create_from_extension] together with [method RenderingServer.texture_rd_create], rather than this method. You will be able to control the texture's format and usage more effectively. |
@@ -3410,7 +3410,7 @@ | |||
The ratio of [WorkerThreadPool]'s threads that will be reserved for low-priority tasks. For example, if 10 threads are available and this value is set to [code]0.3[/code], 3 of the worker threads will be reserved for low-priority tasks. The actual value won't exceed the number of CPU cores minus one, and if possible, at least one worker thread will be dedicated to low-priority tasks. | |||
</member> | |||
<member name="threading/worker_pool/max_threads" type="int" setter="" getter="" default="-1"> | |||
Maximum number of threads to be used by [WorkerThreadPool]. Value of [code]-1[/code] means [code]1[/code] on Web, or a number of [i]logical[/i] CPU cores available on other platforms (see [method OS.get_processor_count]). | |||
Maximum number of threads to be used by [WorkerThreadPool]. On Web, a value of [code]-1[/code] means [code]1[/code]. On other platforms, it means all [i]logical[/i] CPU cores available (see [method OS.get_processor_count]). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Something about this still bothers me.
@@ -3356,7 +3356,7 @@ | |||
If [code]true[/code], the texture importer will import lossless textures using the PNG format. Otherwise, it will default to using WebP. | |||
</member> | |||
<member name="rendering/textures/vram_compression/cache_gpu_compressor" type="bool" setter="" getter="" default="true"> | |||
If [code]true[/code], the GPU texture compressor will cache the local RenderingDevice and its resources (shaders and pipelines), allowing for faster subsequent imports at a memory cost. | |||
If [code]true[/code], the GPU texture compressor will cache the local RenderingDevice and its resources (shaders and pipelines), making subsequent imports faster at the cost of increased memory usage. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe this was fine before? It was very succinct, maybe too much.
@@ -522,7 +522,7 @@ | |||
A signal can only be connected once to the same [Callable]. If the signal is already connected, this method returns [constant ERR_INVALID_PARAMETER] and generates an error, unless the signal is connected with [constant CONNECT_REFERENCE_COUNTED]. To prevent this, use [method is_connected] first to check for existing connections. | |||
[b]Note:[/b] If the [param callable]'s object is freed, the connection will be lost. | |||
[b]Note:[/b] In GDScript, it is generally recommended to connect signals with [method Signal.connect] instead. | |||
[b]Note:[/b] This operation (and all other signal related operations) is thread-safe. | |||
[b]Note:[/b] This method, and all other signal-related methods, are thread-safe. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I genuinely don't think this note needs to exist, especially specifically only in Object.connect
, but I digress.
c82c970
to
216435e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GUI/TextServer related changes look good.
<param index="0" name="file" type="String" /> | ||
<description> | ||
Returns file size in bytes, or [code]-1[/code] on error. | ||
Returns the size of the file at the given path, in bytes, or [code]-1[/code] on error. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it should be changed to path
, renaming argument is not breaking change.
216435e
to
6df0ff0
Compare
Continuation of #107143
This PR addressed yet yet another huge chunk of class reference oddities I remembered to note down for later while localizing the class reference. Some of these are clear typos, some are inconsistencies, some are just awkward.
Of particular note:
language
everywherea
lpha channel" punnetwork/connection/network_mode
to be somewhat less awkwardmove_to_center
is_pixel_opaque
get_data
andget_double
tab_close_pressed
keep_compressed_buffer
size
description aroundoversampling
propertiescast_shadow
to be more meaningfulxr/openxr/foveation_level
get_script_signal_list
add_user_signal
[code]
tags to TextServer'sstring_to_upper
& similarget
methodsscreen_get_pixel
claiming it returns a whole screenshot and literally the entire [Color] typehorizontal_alignment
properties, leading to duplicate translation stringsFor some of the descriptions affected, additional tweaks have been made to justify a whole translation string change.