1 /* 2 * Copyright (C) 2021 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef I_STANDARD_MEDIA_SERVICE_H 17 #define I_STANDARD_MEDIA_SERVICE_H 18 19 #include "ipc_types.h" 20 #include "iremote_broker.h" 21 #include "iremote_proxy.h" 22 #include "iremote_stub.h" 23 24 namespace OHOS { 25 namespace Media { 26 class IStandardMediaService : public IRemoteBroker { 27 public: 28 /** 29 * sub system ability ID 30 */ 31 enum MediaSystemAbility : int32_t { 32 MEDIA_PLAYER = 0, 33 MEDIA_RECORDER = 1, 34 MEDIA_CODEC = 2, 35 MEDIA_AVMETADATAHELPER = 3, 36 MEDIA_CODECLIST = 4, 37 MEDIA_AVCODEC = 5, 38 RECORDER_PROFILES = 6, 39 MEDIA_MONITOR = 7, 40 MEDIA_SCREEN_CAPTURE = 8, 41 MEDIA_SCREEN_CAPTURE_CONTROLLER = 9, 42 MEDIA_TRANSCODER = 10, 43 MEDIA_SCREEN_CAPTURE_MONITOR = 11 44 }; 45 46 /** 47 * Create Player/Recorder/AVCodec/Codeclist/Split/AVmetadata Service Ability 48 * 49 * @return Returns remote object sptr, nullptr on failure. 50 */ 51 virtual sptr<IRemoteObject> GetSubSystemAbility(IStandardMediaService::MediaSystemAbility subSystemId, 52 const sptr<IRemoteObject> &listener) = 0; 53 54 /** 55 * IPC code ID 56 */ 57 enum MediaServiceMsg : int32_t { 58 GET_SUBSYSTEM = 0, 59 }; 60 61 DECLARE_INTERFACE_DESCRIPTOR(u"IStandardMediaService"); 62 }; 63 } // namespace Media 64 } // namespace OHOS 65 #endif // I_STANDARD_MEDIA_SERVICE_H 66