Commit graph

722 commits

Author SHA1 Message Date
Ziqing Hui ff0cd457b4 winegstreamer: Set AvgTimePerFrame in GetOutputType() for WMV decoder.
Krkr2 game engine need AvgTimePerFrame to calculate video frame time.
2024-03-06 19:01:38 +01:00
Ziqing Hui 732ed62819 mf/tests: Test AvgTimePerFrame for WMV decoder DMO. 2024-03-06 19:01:38 +01:00
Rémi Bernon ba3799527c mf/topology_loader: Only propagate some media type attributes. 2024-03-01 23:14:22 +01:00
Yuxuan Shui 97d4c7fe3f mf: Only preroll when starting from stopped state.
Stream sink such as evr can't be prerolled a second time, and when we are
restarting from a paused state, those stream sink will already be prerolled
so don't preroll them again. Otherwise we will be waiting for Prerolled
events that will never come.
2024-02-08 23:31:25 +01:00
Zhiyi Zhang 6b853a9354 mf/tests: Test IMFMediaSession::Start().
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
2024-02-06 22:56:50 +01:00
Zhiyi Zhang 9c82ce962b mf: Support seeking while a session is started. 2024-02-06 22:56:50 +01:00
Zhiyi Zhang c1223d0be0 mf/tests: Add a create_test_topology() helper.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
2024-02-06 22:56:50 +01:00
Zhiyi Zhang 8173d3b0ab mf: Add a session_flush_nodes() helper.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
2024-02-06 22:56:50 +01:00
Zhiyi Zhang a00b30bfbf mf: Make session_get_node_object() more robust.
It's possible that a state object pointer not in the topology node collection gets passed to
session_get_node_object(). Instead of returning the last node when the object is not found, we
should return a NULL so that the state of the last node is not changed by mistake.

Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
2024-02-06 22:56:48 +01:00
Rémi Bernon 604bc7ccf9 mf/tests: Add some tests with video processor aperture handling. 2024-02-06 16:36:19 +01:00
Rémi Bernon 5a12be3a9a mf/tests: Report more transform current type mismatches. 2024-02-06 16:36:19 +01:00
Jacek Caban b4fa0147e3 mf: Avoid implicit enum to int pointer casts. 2024-01-31 12:04:32 +01:00
Rémi Bernon 6aca31f1a1 winegstreamer: Implement H264 decoder GetInputCurrentType. 2024-01-30 11:06:00 +01:00
Rémi Bernon 2d88c57716 mf/topology_loader: Try to connect transform nodes with their current types first.
And only if that fails try again by enumerating types.
2024-01-30 11:05:58 +01:00
Rémi Bernon d95d113230 mf/topology_loader: Initialize transform output type before adding converter.
Otherwise the next topology_branch_connect call will fail when it will
try to lookup the upstream element media type.
2024-01-30 11:05:57 +01:00
Rémi Bernon 2a185126ca mf/topology_loader: Ignore SetOutputType errors when doing indirect connect.
It only succeeds with converters, or if a decoder can directly output
the downstream media type.

If it fails we may have to add a converter after the decoder, and we
will call topology_branch_connect on the downstream branch for that.
2024-01-30 11:05:56 +01:00
Rémi Bernon 0dab1ffdf9 mf/topology_loader: Use a local variable for the indirect connection method.
Instead of modifying the method_mask parameter, in case we need to retry
with another transform.
2024-01-30 11:05:54 +01:00
Rémi Bernon 56b1f80210 mf/tests: Check inserted topology loader transforms explicitly. 2024-01-30 11:05:54 +01:00
Nikolay Sivov 21bbd34d35 mf/tests: Fully cleanup when skipping tests. 2024-01-19 18:01:34 +01:00
Nikolay Sivov 8e82b56a7e mf/tests: Skip tests if video renderer can't be created. 2024-01-17 10:56:47 +01:00
Nikolay Sivov 7e30b44367 mf/tests: Skip tests if D3D9 is unusable.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2024-01-08 20:52:27 +01:00
Rémi Bernon d748440ea2 mf/tests: Workaround broken Win7 test_h264_decoder_concat_streams result.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55638
2023-12-12 23:15:03 +01:00
Alfred Agrell 9c78628f14 mf/tests: Test IMediaObject_GetOutputSizeInfo. 2023-11-23 16:17:27 +01:00
Alfred Agrell 33d9310a9f winegstreamer: Implement DMO interface for WMA decoder. 2023-11-23 16:17:27 +01:00
Alfred Agrell f04aeeef9f winegstreamer: Switch WMA decoder to use wg_format internally. 2023-11-23 16:17:27 +01:00
Alexandre Julliard 7ccb5df0fc makefiles: Always use the global SOURCES variable for .rc files. 2023-11-01 22:43:56 +01:00
Alexandre Julliard c432eac726 makefiles: Always use the global SOURCES variable for .idl files. 2023-11-01 22:43:50 +01:00
Santino Mazza 0170cd3a4c mf: Handle errors with source event generator in session. 2023-10-31 22:17:01 +01:00
Nikolay Sivov 729ed419ae mf/samplegrabber: Use OnSetPresentationClock() on shutdown as well.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-10-31 18:52:08 +01:00
Nikolay Sivov 09d949494b mf/samplegrabber: Reset the clock before OnShutdown().
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-10-31 18:52:08 +01:00
Nikolay Sivov 882d822900 mf/samplegrabber: Check shutdown state when setting the clock.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
2023-10-31 18:52:08 +01:00
Nikolay Sivov c45ae2c680 mf/samplegrabber: Release current media type on shutdown. 2023-10-31 18:52:08 +01:00
Rémi Bernon d0400e5637 mf/tests: Avoid crashing if MF_BYTESTREAM_EFFECTIVE_URL is missing.
Wine-Bug: https://bugs.winehq.org//show_bug.cgi?id=55588
2023-10-27 10:19:40 -05:00
Paul Gofman deff1303fb winegstreamer: Add AVDecVideoAcceleration_H264 attribute for h264 decoder MFT. 2023-10-17 21:48:20 +02:00
Fabian Maurer df01ef80a0 mf/tests: Increase buffer to prevent stack corruption.
init_dmo_media_type_video uses head + extra bytes memory,
and with MEDIASUBTYPE_RGB8 the extra bytes are already 1024.
This leads to stack corruption.
2023-10-17 18:18:03 +02:00
Zhiyi Zhang e4cdcb1ec9 mf: Avoid a double free of presentation clock timers.
In clock_change_state() when a clock is running, a timer is removed from clock->timers. The same
timer is then used to create an async result, which will eventually calls present_clock_timer_callback_Invoke()
and release the same timer. Check if the timer is still in clock->timers before releasing it.
2023-10-09 20:51:22 +02:00
Paul Gofman 416a273241 winegstreamer: Also return output with 2 channels for multichannel inputs from AAC decoder. 2023-09-27 22:23:12 +02:00
Paul Gofman bb95f8c2f6 winegstreamer: Validate maximum channel count in _SetInputType in AAC decoder. 2023-09-27 22:23:12 +02:00
Paul Gofman 902133b008 winegstreamer: Correct output available types attrs in AAC decoder for channel count > 2. 2023-09-27 22:23:12 +02:00
Paul Gofman 5b0172e161 winegstreamer: Handle missing or zero channel count in _GetOutputAvailableType in AAC decoder. 2023-09-27 22:23:12 +02:00
Paul Gofman 3432ef30c3 mf/tests: Add tests for AAC decoder with different input number of channels. 2023-09-27 22:23:12 +02:00
Ziqing Hui b3edb269ec winegstreamer: Add MFMPEG4SinkClassFactory. 2023-09-05 15:20:38 +02:00
Ziqing Hui f98f36123a mf/tests: Use h264 and aac in mp4 media sink tests. 2023-09-05 15:20:38 +02:00
Ziqing Hui b4be3b1b25 mf/tests: Add tests for h264 encoder. 2023-09-05 15:20:38 +02:00
Ziqing Hui c22b9defe7 mf/tests: Call check_attributes in check_mft_get_output_current_type_. 2023-09-05 15:20:38 +02:00
Rémi Bernon 57bd5b10a1 mf/session: Increase the request count when requests are already queued. 2023-08-29 16:02:05 +02:00
Rémi Bernon 4d30ce831e mf/session: Request more samples from upstream when necessary. 2023-08-29 16:02:04 +02:00
Rémi Bernon 986d82d147 mf/session: Push transform input samples directly to ProcessInput. 2023-08-29 16:02:03 +02:00
Rémi Bernon 5d51349276 mf/session: Use helpers to push and pop samples for transform streams. 2023-08-29 16:02:01 +02:00
Rémi Bernon b60db1693e mf/session: Drain remaining requests in transform_node_deliver_samples. 2023-08-29 16:02:00 +02:00