## Context
This is a problem discovered when running "Max: The Curse of Brotherhood" under proton. This game writes 4MB a piece into `wg_transform`, which contains about 4 seconds of compressed video. `wg_transform` calls `gst_pad_push` in `transform_ProcessOutput`, which takes \~300ms (i.e. 20 frames @ 60fps) to decode this buffer of video. So the end result is the game hitches every 4 seconds while playing cut scene videos.
Proton currently has a special case for this particular game, for which it breaks up the buffer into small chunks to avoid long blocks. This MR adopts that and applies it generally.
One concern raised by @redmcg is:
> The only issue I can think of is if there are any decoders which don't have a parser; then they might not know how to deal with an arbitrary 4096 byte buffer (the parser is generally responsible for taking arbitrary buffers and producing something the decoder can work with, for example: a full frame).
So this MR only enables this strategy when there is a parser element.
--
v7: winegstreamer: Avoid large buffer pushes in wg_transform.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7288
## Context
This is a problem discovered when running "Max: The Curse of Brotherhood" under proton. This game writes 4MB a piece into `wg_transform`, which contains about 4 seconds of compressed video. `wg_transform` calls `gst_pad_push` in `transform_ProcessOutput`, which takes \~300ms (i.e. 20 frames @ 60fps) to decode this buffer of video. So the end result is the game hitches every 4 seconds while playing cut scene videos.
Proton currently has a special case for this particular game, for which it breaks up the buffer into small chunks to avoid long blocks. This MR adopts that and applies it generally.
One concern raised by @redmcg is:
> The only issue I can think of is if there are any decoders which don't have a parser; then they might not know how to deal with an arbitrary 4096 byte buffer (the parser is generally responsible for taking arbitrary buffers and producing something the decoder can work with, for example: a full frame).
So this MR only enables this strategy when there is a parser element.
--
v6: winegstreamer: Avoid large buffer pushes in wg_transform.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7288
## Context
This is a problem discovered when running "Max: The Curse of Brotherhood" under proton. This game writes 4MB a piece into `wg_transform`, which contains about 4 seconds of compressed video. `wg_transform` calls `gst_pad_push` in `transform_ProcessOutput`, which takes \~300ms (i.e. 20 frames @ 60fps) to decode this buffer of video. So the end result is the game hitches every 4 seconds while playing cut scene videos.
Proton currently has a special case for this particular game, for which it breaks up the buffer into small chunks to avoid long blocks. This MR adopts that and applies it generally.
One concern raised by @redmcg is:
> The only issue I can think of is if there are any decoders which don't have a parser; then they might not know how to deal with an arbitrary 4096 byte buffer (the parser is generally responsible for taking arbitrary buffers and producing something the decoder can work with, for example: a full frame).
So this MR only enables this strategy when there is a parser element.
--
v5: winegstreamer: Avoid large buffer pushes in wg_transform.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7288
This patch series adds quite a few new tests for saving to image file formats that aren't DDS, and adds partial support for saving surfaces to targa files.
--
v2: d3dx9: Add basic support for saving surfaces to targa files.
d3dx9: Add TGA prefix to targa specific defines.
d3dx9/tests: Add tests for saving surfaces to non-DDS files.
d3dx9/tests: Add a test for saving a surface as D3DXIFF_DIB.
d3dx9/tests: Add some more tests for saving surfaces as targa files.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7386
There is no ([not yet?](https://gitlab.freedesktop.org/wayland/wayland-protocols/-/merge_requ…) dedicated protocol for requesting pointer warps, but it's possible to request one with `zwp_locked_pointer_v1.set_cursor_position_hint` which may be performed when the pointer is unlocked. The idea is to quickly lock/set position/unlock. This is used by SDL (in some cases: [SDL_MOUSE_EMULATE_WARP_WITH_RELATIVE](https://wiki.libsdl.org/SDL3/SDL_HINT…) and Xwayland. The limitation is/will be that the compositor will ignore requests to warp the pointer outside of surface bounds.
What I'd like to have working is the auto cursor placement feature of some applications, where they just want to call SetCursorPos towards specific UI elements inside their single window, and usually they'll be unclipped and have a visible cursor while doing this.
This patch also happens to allow mouselook to work in applications which use SetCursorPos for mouselook and aren't getting covered by the heuristics that turn on Wayland relative motion (for some reason the driver thinks the cursor is visible). Seems to affect Half-Life (GoldSrc) on my system. Though force enabling relative motion with an environment variable in a custom build or somehow improving the heuristics will also fix that.
A suface/pointer can only have one lock or confinement, and this implementation depends on the pointer lock. So if needed, I temporarily unlock/unconfine in order to do the warp then relock/reconfine. I modified `wayland_pointer_update_constraint` so I don't have to temporarily disable relative motion during this in case it's enabled. I think it's safe/a no-op to attempt pointer warps while using relative motion, as according to the protocol the warp will not generate a relative motion event, and while there will be a wl_pointer motion event, they're ignored while relative motion is being used.
--
v4: winewayland: Implement SetCursorPos via pointer lock.
winewayland: Update locked pointer position hint.
https://gitlab.winehq.org/wine/wine/-/merge_requests/7353
On Wed Feb 26 12:04:41 2025 +0000, Yongjie Yao wrote:
> In fact, some HTTP server will send "Expires: -1" in HTTP response header.
> You are right, HTTP spec is that invalid value, include "0".
> I add a test to test_http_connection() that would send "Expires: -1" in
> response header, I get the error log:
> ```
> 0024:err:wininet:HTTP_ParseDateAsAsctime unexpected weekday L"-1"
> 0024:err:wininet:HTTP_ParseDate unexpected date format L"-1"
> ```
> Maybe we should just treat "Expires: -1" as an invalid date format and
> ignore it.
I mean you should test it on actual Windows
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/7323#note_95992
In fact, some HTTP server will send "Expires: -1" in HTTP response header.
You are right, HTTP spec is that invalid value, include "0".
I add a test to test_http_connection() that would send "Expires: -1" in response header, I get the error log:
```
0024:err:wininet:HTTP_ParseDateAsAsctime unexpected weekday L"-1"
0024:err:wininet:HTTP_ParseDate unexpected date format L"-1"
```
Maybe we should just treat "Expires: -1" as an invalid date format and ignore it.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/7323#note_95990
Needed for Indiana Jones and the Great Circle.
---
The naming of the shellfolders one is not a mistake; they seemed to have named it differently than all the other shell API sets.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/6977