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 NET_CALL_BASE_H 17 #define NET_CALL_BASE_H 18 19 #include <cstdio> 20 #include <cstdlib> 21 #include <stdint.h> 22 23 #include "refbase.h" 24 #include "call_manager_inner_type.h" 25 #include "surface.h" 26 27 namespace OHOS { 28 namespace Telephony { 29 class NetCallBase : public virtual RefBase { 30 public: 31 NetCallBase(); 32 virtual ~NetCallBase() = default; 33 34 int32_t StartConference(); 35 int32_t JoinConference(); 36 int32_t KickOutConference(); 37 int32_t LeaveConference(); 38 39 int32_t GetNetCallType(); 40 int32_t ChangeNetCallType(); 41 virtual int32_t InitVideoCall() = 0; 42 virtual int32_t UpdateImsCallMode(ImsCallMode mode) = 0; 43 virtual int32_t ReportImsCallModeInfo(CallMediaModeInfo &imsCallModeInfo) = 0; 44 virtual int32_t SendUpdateCallMediaModeRequest(ImsCallMode mode) = 0; 45 // receive call media mode modify request from peer 46 virtual int32_t RecieveUpdateCallMediaModeRequest(CallModeReportInfo &response) = 0; 47 // send call media mode modify response to peer 48 virtual int32_t SendUpdateCallMediaModeResponse(ImsCallMode mode) = 0; 49 // receive call media mode modify response to peer 50 virtual int32_t ReceiveUpdateCallMediaModeResponse(CallModeReportInfo &response) = 0; 51 virtual int32_t ControlCamera(std::string &cameraId, int32_t callingUid, int32_t callingPid) = 0; 52 virtual int32_t SetPreviewWindow(std::string &surfaceId, sptr<Surface> surface) = 0; 53 virtual int32_t SetDisplayWindow(std::string &surfaceId, sptr<Surface> surface) = 0; 54 virtual int32_t SetPausePicture(std::string &path) = 0; 55 virtual int32_t SetDeviceDirection(int32_t rotation) = 0; 56 virtual int32_t CancelCallUpgrade() = 0; 57 virtual int32_t RequestCameraCapabilities() = 0; 58 }; 59 } // namespace Telephony 60 } // namespace OHOS 61 62 #endif // NET_CALL_BASE_H 63