OSDN Git Service

[AU] Update volume setting and Audio Device API 3.0
authorHochi Huang <hochi.huang@mediatek.com>
Sun, 21 Sep 2014 01:40:30 +0000 (09:40 +0800)
committerleozwang <leozwang@google.com>
Wed, 24 Sep 2014 19:20:26 +0000 (12:20 -0700)
Change-Id: I772584ae05e6a8d2fdc8c4a52e44ad80c3c1a4a7
Signed-off-by: Hochi Huang <hochi.huang@mediatek.com>
include/hardware_legacy/AudioHardwareInterface.h

index 6b524a8..7d34aaa 100644 (file)
@@ -117,6 +117,11 @@ public:
      */
     virtual status_t    getNextWriteTimestamp(int64_t *timestamp);
 
+    /**
+     * Return a recent count of the number of audio frames presented to an external observer.
+     */
+    virtual status_t    getPresentationPosition(uint64_t *frames, struct timespec *timestamp);
+
 };
 
 /**
@@ -276,6 +281,18 @@ public:
 
     static AudioHardwareInterface* create();
 
+    virtual int createAudioPatch(unsigned int num_sources,
+                               const struct audio_port_config *sources,
+                               unsigned int num_sinks,
+                               const struct audio_port_config *sinks,
+                               audio_patch_handle_t *handle) = 0;
+
+    virtual int releaseAudioPatch(audio_patch_handle_t handle) = 0;
+
+    virtual int getAudioPort(struct audio_port *port) = 0;
+
+    virtual int setAudioPortConfig(const struct audio_port_config *config) = 0;
+
 protected:
 
     virtual status_t dump(int fd, const Vector<String16>& args) = 0;