summaryrefslogtreecommitdiff
path: root/audio/tests/PinResourceHelpers/TestResourceHelper.h
blob: 08fafa23d251aa8b82ad91588f1826cfdbb30902 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
// ------------------------------------------------------------------------------
//
// Copyright (C) Microsoft. All rights reserved.
//
// Module Name:
//
//  TestResourceHelpers.h
//
// Abstract:
//
//  Header for BuildResourceList helpers.
//
// -------------------------------------------------------------------------------
#pragma once

#include <HalfApp.h>

// ----------------------------------------------------------------------
HRESULT GetProcessingModesForConnector
(
    IMMDevice*              pDevice,
    UINT                    uConnectorId,
    EndpointConnectorType   eConnectorType,
    ULONG*                  pCount,
    AUDIO_SIGNALPROCESSINGMODE** ppModes
);

// ----------------------------------------------------------------------
HRESULT GetDefaultFormatForConnector
(
    IMMDevice*              pDevice,
    EndpointConnectorType   eConnectorType,
    WAVEFORMATEX**          ppDefaultFormat
);

// ----------------------------------------------------------------------
HRESULT GetPreferredFormatForConnector
(
    IMMDevice*                  pDevice,
    UINT                        uConnectorId,
    EndpointConnectorType       eConnectorType,
    AUDIO_SIGNALPROCESSINGMODE  mode,
    WAVEFORMATEX**              ppPreferredFormat
);

// ----------------------------------------------------------------------
HRESULT GetPreferredFormatPeriodicityCharacteristicsForConnector
(
    IMMDevice*                  pDevice,
    EndpointConnectorType       eConnectorType,
    AUDIO_SIGNALPROCESSINGMODE  mode,
    STACKWISE_DATAFLOW          dataFlow,
    WAVEFORMATEX*               pPreferredFormat,
    ULONG                       cFormatRecords,
    PFORMAT_RECORD              pFormatRecords,
    UINT32*                     pDefaultPeriodicityInFrames,
    UINT32*                     pFundamentalPeriodicityInFrames,
    UINT32*                     pMinPeriodicityInFrames,
    UINT32*                     pMaxPeriodicityInFrames,
    UINT32*                     pMaxPeriodicityInFramesExtended
);

// ----------------------------------------------------------------------
HRESULT GetSupportedFormatRecordsForConnector
(
    IMMDevice*              pDevice,
    UINT                    uConnectorId,
    EndpointConnectorType   eConnectorType,
    AUDIO_SIGNALPROCESSINGMODE mode,
    STACKWISE_DATAFLOW      dataFlow,
    ULONG*                  pCount,
    FORMAT_RECORD**         ppFormatRecords
);