22 Jan
2024
22 Jan
'24
2:37 p.m.
This check was introduced in 4640be8dc834. At that point the only way for that condition to be false was for a cube map texture.
It reads to me like it's specifically checking for a 2D texture instead of "not a cube texture", but the distinction may be somewhat moot: WINED3D_CKEY_SRC_BLT implies ddraw, and that means we either have a cube texture or a 2D texture. Note that constructs like ```c if (a) { if (b) { if (c) { [...] } } } ``` can often be rewritten as ```c if (a && b && c) { [...] } ``` without readability being reduced. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/4888#note_58397