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
media / base / wait_and_replace_sync_token_client.h [blame]
// Copyright 2020 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef MEDIA_BASE_WAIT_AND_REPLACE_SYNC_TOKEN_CLIENT_H_
#define MEDIA_BASE_WAIT_AND_REPLACE_SYNC_TOKEN_CLIENT_H_
#include "base/memory/raw_ptr.h"
#include "gpu/command_buffer/common/sync_token.h"
#include "media/base/media_export.h"
#include "media/base/video_frame.h"
namespace gpu {
class InterfaceBase;
}
namespace media {
class MEDIA_EXPORT WaitAndReplaceSyncTokenClient
: public VideoFrame::SyncTokenClient {
public:
explicit WaitAndReplaceSyncTokenClient(gpu::InterfaceBase* ib);
WaitAndReplaceSyncTokenClient(const WaitAndReplaceSyncTokenClient&) = delete;
WaitAndReplaceSyncTokenClient& operator=(
const WaitAndReplaceSyncTokenClient&) = delete;
void GenerateSyncToken(gpu::SyncToken* sync_token) final;
void WaitSyncToken(const gpu::SyncToken& sync_token) final;
private:
raw_ptr<gpu::InterfaceBase> ib_;
};
} // namespace media
#endif // MEDIA_BASE_WAIT_AND_REPLACE_SYNC_TOKEN_CLIENT_H_