Merge pull request #46520 from lawnjelly/soft_skin_aa
Disallow antialiasing for software skinned 2d polys
This commit is contained in:
commit
6b4abc6e17
2 changed files with 12 additions and 2 deletions
|
@ -1143,6 +1143,7 @@
|
|||
<member name="rendering/quality/2d/use_software_skinning" type="bool" setter="" getter="" default="true">
|
||||
If [code]true[/code], performs 2D skinning on the CPU rather than the GPU. This provides greater compatibility with a wide range of hardware, and also may be faster in some circumstances.
|
||||
Currently only available when [member rendering/batching/options/use_batching] is active.
|
||||
[b]Note:[/b] Antialiased software skinned polys are not supported, and will be rendered without antialiasing.
|
||||
</member>
|
||||
<member name="rendering/quality/2d/use_transform_snap" type="bool" setter="" getter="" default="false">
|
||||
If [code]true[/code], forces snapping of 2D object transforms to the nearest whole coordinate.
|
||||
|
|
|
@ -2282,7 +2282,16 @@ PREAMBLE(bool)::prefill_joined_item(FillState &r_fill_state, int &r_command_star
|
|||
#ifdef GLES_OVER_GL
|
||||
// anti aliasing not accelerated .. it is problematic because it requires a 2nd line drawn around the outside of each
|
||||
// poly, which would require either a second list of indices or a second list of vertices for this step
|
||||
bool use_legacy_path = false;
|
||||
|
||||
if (polygon->antialiased) {
|
||||
// anti aliasing is also not supported for software skinned meshes.
|
||||
// we can't easily revert, so we force software skinned meshes to run through
|
||||
// batching path with no AA.
|
||||
use_legacy_path = !bdata.settings_use_software_skinning || p_item->skeleton == RID();
|
||||
}
|
||||
|
||||
if (use_legacy_path) {
|
||||
// not accelerated
|
||||
_prefill_default_batch(r_fill_state, command_num, *p_item);
|
||||
} else {
|
||||
|
@ -2298,9 +2307,9 @@ PREAMBLE(bool)::prefill_joined_item(FillState &r_fill_state, int &r_command_star
|
|||
bool buffer_full = false;
|
||||
|
||||
if (send_light_angles) {
|
||||
// NYI
|
||||
// polygon with light angles is not yet implemented
|
||||
// for batching .. this means software skinned with light angles won't work
|
||||
_prefill_default_batch(r_fill_state, command_num, *p_item);
|
||||
//buffer_full = prefill_polygon<true>(polygon, r_fill_state, r_command_start, command_num, command_count, p_item, multiply_final_modulate);
|
||||
} else
|
||||
buffer_full = _prefill_polygon<false>(polygon, r_fill_state, r_command_start, command_num, command_count, p_item, multiply_final_modulate);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue