1/*
2Copyright 2018 Google Inc. All Rights Reserved.
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS-IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15*/
16
17#ifndef RESONANCE_AUDIO_NODE_PUBLISHER_NODE_H_
18#define RESONANCE_AUDIO_NODE_PUBLISHER_NODE_H_
19
20#include <memory>
21
22#include "base/logging.h"
23#include "node/node.h"
24
25namespace vraudio {
26
27// Interface for publisher nodes that declares helper methods required to
28// connect to a publisher node. All publishing nodes need to implement this
29// interface.
30//
31// @tparam OutputType Type of the output container being streamed.
32// @interface
33template <typename OutputType>
34class PublisherNode {
35 public:
36 virtual ~PublisherNode() {}
37
38 // Creates a shared pointer of the Node instance.
39 //
40 // @return Returns a shared pointer the of Node instance.
41 virtual std::shared_ptr<Node> GetSharedNodePtr() = 0;
42
43 // Get internal Node::Output instance.
44 //
45 // @return Returns a pointer to the internal Node::Output instance.
46 virtual Node::Output<OutputType>* GetOutput() = 0;
47};
48
49} // namespace vraudio
50
51#endif // RESONANCE_AUDIO_NODE_PUBLISHER_NODE_H_
52

source code of qtmultimedia/src/3rdparty/resonance-audio/resonance_audio/node/publisher_node.h