| // Copyright 2019 The Fuchsia Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| library fuchsia.hardware.mediacodec; |
| |
| using fuchsia.io; |
| using zx; |
| |
| closed protocol Device { |
| /// This method connects the caller with a fuchsia.mediacodec.CodecFactory. |
| strict GetCodecFactory(resource struct { |
| request zx.Handle:CHANNEL; |
| }); |
| |
| /// This method hands a service directory to the codec. Currently the only service available |
| /// via this service directory is fuchsia.metrics.MetricEventLoggerFactory. Any services |
| /// available via this service directory are services we'd prefer to get via the DDK. A device |
| /// can simply close this channel if the device doesn't need to use any services available via |
| /// this service directory. |
| strict SetAuxServiceDirectory(resource struct { |
| service_directory client_end:fuchsia.io.Directory; |
| }); |
| }; |