From dd373e2d5cb4796b7b2253e7d6d95da51db1ed08 Mon Sep 17 00:00:00 2001 From: gaoqiang_strong Date: Tue, 8 Nov 2022 20:12:26 +0800 Subject: [PATCH] bug Signed-off-by: gaoqiang_strong --- common/include/dscreen_constants.h | 8 ++++++++ .../native_cpp/screen_sink/include/dscreen_sink_proxy.h | 5 +---- .../native_cpp/screen_sink/include/idscreen_sink.h | 2 +- .../native_cpp/screen_sink/src/dscreen_sink_proxy.cpp | 1 + .../include/callback/dscreen_source_callback.h | 2 +- .../include/callback/dscreen_source_callback_stub.h | 4 +--- .../include/callback/idscreen_source_callback.h | 2 +- .../screen_source/include/dscreen_source_proxy.h | 4 +--- .../native_cpp/screen_source/include/idscreen_source.h | 2 +- .../src/callback/dscreen_source_callback_stub.cpp | 1 + .../native_cpp/screen_source/src/dscreen_source_proxy.cpp | 1 + .../dscreenservice/include/dscreen_sink_service.h | 2 +- .../dscreenservice/include/dscreen_sink_stub.h | 5 +---- .../sourceservice/dscreenmgr/include/dscreen.h | 2 +- .../include/callback/dscreen_source_callback_proxy.h | 4 +--- .../dscreenservice/include/dscreen_source_stub.h | 5 +---- .../src/callback/dscreen_source_callback_proxy.cpp | 1 + .../screendatachannel/include/screen_data_channel_impl.h | 2 +- .../decoder/include/image_decoder_callback.h | 2 +- .../decoder/include/image_sink_decoder.h | 2 -- .../screensinkprocessor/include/image_sink_processor.h | 2 +- .../screensinktrans/include/screen_sink_trans.h | 2 +- .../encoder/include/image_encoder_callback.h | 2 +- .../encoder/include/image_source_encoder.h | 1 - .../include/image_source_processor.h | 2 +- .../screensourcetrans/include/screen_source_trans.h | 5 +---- .../screensourcetrans/src/screen_source_trans.cpp | 1 + 27 files changed, 32 insertions(+), 40 deletions(-) diff --git a/common/include/dscreen_constants.h b/common/include/dscreen_constants.h index e3f55a66..671a9ccc 100644 --- a/common/include/dscreen_constants.h +++ b/common/include/dscreen_constants.h @@ -140,6 +140,14 @@ constexpr int32_t DISTRIBUTED_HARDWARE_SCREEN_SINK_SA_ID = 4808; constexpr uint64_t SCREEN_ID_INVALID = -1ULL; constexpr uint64_t SCREEN_ID_DEFAULT = 0; constexpr int32_t SCREEN_LOADSA_TIMEOUT_MS = 10000; +constexpr size_t DID_MAX_SIZE = 256; +constexpr size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; +constexpr uint8_t SESSION_WAIT_SECONDS = 5; +constexpr uint8_t DATA_WAIT_SECONDS = 1; +constexpr size_t DATA_QUEUE_MAX_SIZE = 1000; +constexpr uint32_t DECODE_WAIT_MILLISECONDS = 5000; +constexpr size_t DATA_BUFFER_MAX_SIZE = 10 * 1024 * 1024; +constexpr uint8_t TASK_WAIT_SECONDS = 1; } // namespace DistributedHardware } // namespace OHOS #endif \ No newline at end of file diff --git a/interfaces/innerkits/native_cpp/screen_sink/include/dscreen_sink_proxy.h b/interfaces/innerkits/native_cpp/screen_sink/include/dscreen_sink_proxy.h index 853f7a50..a3e34227 100644 --- a/interfaces/innerkits/native_cpp/screen_sink/include/dscreen_sink_proxy.h +++ b/interfaces/innerkits/native_cpp/screen_sink/include/dscreen_sink_proxy.h @@ -34,7 +34,7 @@ public: { } - ~DScreenSinkProxy() {} + ~DScreenSinkProxy() override {} int32_t InitSink(const std::string ¶ms) override; int32_t ReleaseSink() override; int32_t SubscribeLocalHardware(const std::string &dhId, const std::string ¶m) override; @@ -43,9 +43,6 @@ public: private: static inline BrokerDelegator delegator_; - - const size_t DID_MAX_SIZE = 256; - const size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; }; } // namespace DistributedHardware } // namespace OHOS diff --git a/interfaces/innerkits/native_cpp/screen_sink/include/idscreen_sink.h b/interfaces/innerkits/native_cpp/screen_sink/include/idscreen_sink.h index 96be07e5..67f398b5 100644 --- a/interfaces/innerkits/native_cpp/screen_sink/include/idscreen_sink.h +++ b/interfaces/innerkits/native_cpp/screen_sink/include/idscreen_sink.h @@ -32,7 +32,7 @@ public: }; IDScreenSink() = default; - virtual ~IDScreenSink() = default; + ~IDScreenSink() override = default; virtual int32_t InitSink(const std::string ¶ms) = 0; virtual int32_t ReleaseSink() = 0; virtual int32_t SubscribeLocalHardware(const std::string &dhId, const std::string ¶m) = 0; diff --git a/interfaces/innerkits/native_cpp/screen_sink/src/dscreen_sink_proxy.cpp b/interfaces/innerkits/native_cpp/screen_sink/src/dscreen_sink_proxy.cpp index 69198236..c9e8e580 100644 --- a/interfaces/innerkits/native_cpp/screen_sink/src/dscreen_sink_proxy.cpp +++ b/interfaces/innerkits/native_cpp/screen_sink/src/dscreen_sink_proxy.cpp @@ -19,6 +19,7 @@ #include "message_option.h" #include "message_parcel.h" +#include "dscreen_constants.h" #include "dscreen_errcode.h" #include "dscreen_log.h" #include "dscreen_util.h" diff --git a/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback.h b/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback.h index 403c0a9f..1a463157 100644 --- a/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback.h +++ b/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback.h @@ -29,7 +29,7 @@ namespace DistributedHardware { class DScreenSourceCallback : public DScreenSourceCallbackStub { public: DScreenSourceCallback() = default; - ~DScreenSourceCallback() = default; + ~DScreenSourceCallback() override = default; int32_t OnNotifyRegResult(const std::string &devId, const std::string &dhId, const std::string &reqId, int32_t status, const std::string &data) override; diff --git a/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback_stub.h b/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback_stub.h index c4ddd5e9..434ad916 100644 --- a/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback_stub.h +++ b/interfaces/innerkits/native_cpp/screen_source/include/callback/dscreen_source_callback_stub.h @@ -31,15 +31,13 @@ namespace DistributedHardware { class DScreenSourceCallbackStub : public IRemoteStub { public: DScreenSourceCallbackStub(); - ~DScreenSourceCallbackStub() = default; + ~DScreenSourceCallbackStub() override = default; int32_t OnRemoteRequest(uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) override; private: using DScreenFunc = int32_t (DScreenSourceCallbackStub::*)(MessageParcel &data, MessageParcel &reply, MessageOption &option); std::map memberFuncMap_; - const size_t DID_MAX_SIZE = 256; - const size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; int32_t OnNotifyRegResultInner(MessageParcel &data, MessageParcel &reply, MessageOption &option); diff --git a/interfaces/innerkits/native_cpp/screen_source/include/callback/idscreen_source_callback.h b/interfaces/innerkits/native_cpp/screen_source/include/callback/idscreen_source_callback.h index 5f880c37..bebc4b0c 100644 --- a/interfaces/innerkits/native_cpp/screen_source/include/callback/idscreen_source_callback.h +++ b/interfaces/innerkits/native_cpp/screen_source/include/callback/idscreen_source_callback.h @@ -28,7 +28,7 @@ public: NOTIFY_UNREG_RESULT, }; - virtual ~IDScreenSourceCallback() {} + ~IDScreenSourceCallback() override {} virtual int32_t OnNotifyRegResult(const std::string &devId, const std::string &dhId, const std::string &reqId, int32_t status, const std::string &data) = 0; virtual int32_t OnNotifyUnregResult(const std::string &devId, const std::string &dhId, diff --git a/interfaces/innerkits/native_cpp/screen_source/include/dscreen_source_proxy.h b/interfaces/innerkits/native_cpp/screen_source/include/dscreen_source_proxy.h index bf638d59..da188082 100644 --- a/interfaces/innerkits/native_cpp/screen_source/include/dscreen_source_proxy.h +++ b/interfaces/innerkits/native_cpp/screen_source/include/dscreen_source_proxy.h @@ -34,7 +34,7 @@ public: { } - ~DScreenSourceProxy() {} + ~DScreenSourceProxy() override {} int32_t InitSource(const std::string ¶ms, const sptr &callback) override; int32_t ReleaseSource() override; int32_t RegisterDistributedHardware(const std::string &devId, const std::string &dhId, @@ -52,8 +52,6 @@ private: bool CheckUnregParams(const std::string &devId, const std::string &dhId, const std::string &reqId) const; bool CheckConfigParams(const std::string &devId, const std::string &dhId, const std::string &key, const std::string &value) const; - const size_t DID_MAX_SIZE = 256; - const size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; }; } } diff --git a/interfaces/innerkits/native_cpp/screen_source/include/idscreen_source.h b/interfaces/innerkits/native_cpp/screen_source/include/idscreen_source.h index 6c1a69ed..d5c5b117 100644 --- a/interfaces/innerkits/native_cpp/screen_source/include/idscreen_source.h +++ b/interfaces/innerkits/native_cpp/screen_source/include/idscreen_source.h @@ -34,7 +34,7 @@ public: DSCREEN_NOTIFY, }; - virtual ~IDScreenSource() {} + ~IDScreenSource() override {} virtual int32_t InitSource(const std::string ¶ms, const sptr &callback) = 0; virtual int32_t ReleaseSource() = 0; virtual int32_t RegisterDistributedHardware(const std::string &devId, const std::string &dhId, diff --git a/interfaces/innerkits/native_cpp/screen_source/src/callback/dscreen_source_callback_stub.cpp b/interfaces/innerkits/native_cpp/screen_source/src/callback/dscreen_source_callback_stub.cpp index dce62441..01f2cff0 100644 --- a/interfaces/innerkits/native_cpp/screen_source/src/callback/dscreen_source_callback_stub.cpp +++ b/interfaces/innerkits/native_cpp/screen_source/src/callback/dscreen_source_callback_stub.cpp @@ -21,6 +21,7 @@ #include "ipc_types.h" #include "message_parcel.h" +#include "dscreen_constants.h" #include "dscreen_errcode.h" #include "dscreen_log.h" diff --git a/interfaces/innerkits/native_cpp/screen_source/src/dscreen_source_proxy.cpp b/interfaces/innerkits/native_cpp/screen_source/src/dscreen_source_proxy.cpp index fb8cfd89..26c8e97b 100644 --- a/interfaces/innerkits/native_cpp/screen_source/src/dscreen_source_proxy.cpp +++ b/interfaces/innerkits/native_cpp/screen_source/src/dscreen_source_proxy.cpp @@ -20,6 +20,7 @@ #include "message_option.h" #include "message_parcel.h" +#include "dscreen_constants.h" #include "dscreen_errcode.h" #include "dscreen_log.h" #include "dscreen_util.h" diff --git a/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_service.h b/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_service.h index 68b08da5..720c0e88 100644 --- a/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_service.h +++ b/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_service.h @@ -29,7 +29,7 @@ class DScreenSinkService : public SystemAbility, public DScreenSinkStub, DECLARE_SYSTEM_ABILITY(DScreenSinkService); public: DScreenSinkService(int32_t saId, bool runOnCreate); - ~DScreenSinkService() = default; + ~DScreenSinkService() override = default; int32_t InitSink(const std::string ¶ms) override; int32_t ReleaseSink() override; int32_t SubscribeLocalHardware(const std::string &dhId, const std::string ¶m) override; diff --git a/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_stub.h b/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_stub.h index d11f1174..7648328f 100644 --- a/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_stub.h +++ b/services/screenservice/sinkservice/dscreenservice/include/dscreen_sink_stub.h @@ -27,7 +27,7 @@ namespace DistributedHardware { class DScreenSinkStub : public IRemoteStub { public: DScreenSinkStub(); - ~DScreenSinkStub() = default; + ~DScreenSinkStub() override = default; int32_t OnRemoteRequest(uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) override; private: @@ -45,9 +45,6 @@ private: MessageOption &option); int32_t DScreenNotifyInner(MessageParcel &data, MessageParcel &reply, MessageOption &option); - - const size_t DID_MAX_SIZE = 256; - const size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; }; } // namespace DistributedHardware } // namespace OHOS diff --git a/services/screenservice/sourceservice/dscreenmgr/include/dscreen.h b/services/screenservice/sourceservice/dscreenmgr/include/dscreen.h index e68b3957..612f2428 100644 --- a/services/screenservice/sourceservice/dscreenmgr/include/dscreen.h +++ b/services/screenservice/sourceservice/dscreenmgr/include/dscreen.h @@ -77,7 +77,7 @@ private: class DScreen : public ScreenSourceTransCallback, public std::enable_shared_from_this { public: - ~DScreen(); + ~DScreen() override; DScreen(const std::string &devId, const std::string &dhId, std::shared_ptr dscreenCallback); void OnTransError(int32_t err, const std::string &content) override; diff --git a/services/screenservice/sourceservice/dscreenservice/include/callback/dscreen_source_callback_proxy.h b/services/screenservice/sourceservice/dscreenservice/include/callback/dscreen_source_callback_proxy.h index e809de15..aedee50c 100644 --- a/services/screenservice/sourceservice/dscreenservice/include/callback/dscreen_source_callback_proxy.h +++ b/services/screenservice/sourceservice/dscreenservice/include/callback/dscreen_source_callback_proxy.h @@ -29,7 +29,7 @@ public: { } - ~DScreenSourceCallbackProxy() {} + ~DScreenSourceCallbackProxy() override {} int32_t OnNotifyRegResult(const std::string &devId, const std::string &dhId, const std::string &reqId, int32_t status, const std::string &resultData) override; int32_t OnNotifyUnregResult(const std::string &devId, const std::string &dhId, const std::string &reqId, @@ -39,8 +39,6 @@ private: static inline BrokerDelegator delegator_; bool CheckParams(const std::string &devId, const std::string &dhId, const std::string &reqId, const std::string &resultData) const; - const size_t DID_MAX_SIZE = 256; - const size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; }; } // namespace DistributedHardware } // namespace OHOS diff --git a/services/screenservice/sourceservice/dscreenservice/include/dscreen_source_stub.h b/services/screenservice/sourceservice/dscreenservice/include/dscreen_source_stub.h index ad7dc6e0..541290a0 100644 --- a/services/screenservice/sourceservice/dscreenservice/include/dscreen_source_stub.h +++ b/services/screenservice/sourceservice/dscreenservice/include/dscreen_source_stub.h @@ -25,7 +25,7 @@ namespace DistributedHardware { class DScreenSourceStub : public IRemoteStub { public: DScreenSourceStub(); - virtual ~DScreenSourceStub() = default; + ~DScreenSourceStub() override = default; int32_t OnRemoteRequest(uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option) override; @@ -50,9 +50,6 @@ private: using DScreenSourceFunc = int32_t (DScreenSourceStub::*)(MessageParcel &data, MessageParcel &reply, MessageOption &option); std::map memberFuncMap_; - - const size_t DID_MAX_SIZE = 256; - const size_t PARAM_MAX_SIZE = 50 * 1024 * 1024; }; } // namespace DistributedHardware } // namespace OHOS diff --git a/services/screenservice/sourceservice/dscreenservice/src/callback/dscreen_source_callback_proxy.cpp b/services/screenservice/sourceservice/dscreenservice/src/callback/dscreen_source_callback_proxy.cpp index 9ed713fa..729d0819 100644 --- a/services/screenservice/sourceservice/dscreenservice/src/callback/dscreen_source_callback_proxy.cpp +++ b/services/screenservice/sourceservice/dscreenservice/src/callback/dscreen_source_callback_proxy.cpp @@ -17,6 +17,7 @@ #include "parcel.h" +#include "dscreen_constants.h" #include "dscreen_errcode.h" #include "dscreen_log.h" #include "dscreen_util.h" diff --git a/services/screentransport/screendatachannel/include/screen_data_channel_impl.h b/services/screentransport/screendatachannel/include/screen_data_channel_impl.h index 1eff6b3c..7fa6a9ad 100644 --- a/services/screentransport/screendatachannel/include/screen_data_channel_impl.h +++ b/services/screentransport/screendatachannel/include/screen_data_channel_impl.h @@ -30,7 +30,7 @@ class ScreenDataChannelImpl : public IScreenChannel, public std::enable_shared_from_this { public: explicit ScreenDataChannelImpl(std::string peerDevId) : peerDevId_(peerDevId) {}; - ~ScreenDataChannelImpl() = default; + ~ScreenDataChannelImpl() override = default; int32_t CreateSession(const std::shared_ptr &listener) override; int32_t ReleaseSession() override; diff --git a/services/screentransport/screensinkprocessor/decoder/include/image_decoder_callback.h b/services/screentransport/screensinkprocessor/decoder/include/image_decoder_callback.h index 939205ab..2b29050e 100644 --- a/services/screentransport/screensinkprocessor/decoder/include/image_decoder_callback.h +++ b/services/screentransport/screensinkprocessor/decoder/include/image_decoder_callback.h @@ -29,7 +29,7 @@ class ImageDecoderCallback : public Media::AVCodecCallback { public: explicit ImageDecoderCallback(const std::shared_ptr &decoder) : videoDecoder_(decoder) {}; - ~ImageDecoderCallback() = default; + ~ImageDecoderCallback() override = default; void OnError(Media::AVCodecErrorType errorType, int32_t errorCode) override; void OnOutputBufferAvailable(uint32_t index, Media::AVCodecBufferInfo info, Media::AVCodecBufferFlag flag) override; diff --git a/services/screentransport/screensinkprocessor/decoder/include/image_sink_decoder.h b/services/screentransport/screensinkprocessor/decoder/include/image_sink_decoder.h index 44a3270f..1e4b1cbe 100644 --- a/services/screentransport/screensinkprocessor/decoder/include/image_sink_decoder.h +++ b/services/screentransport/screensinkprocessor/decoder/include/image_sink_decoder.h @@ -64,8 +64,6 @@ private: private: static const constexpr char *LOG_TAG = "ImageSinkDecoder"; - static constexpr uint32_t DECODE_WAIT_MILLISECONDS = 5000; - static constexpr size_t DATA_QUEUE_MAX_SIZE = 1000; std::mutex dataMutex_; std::mutex decodeMutex_; diff --git a/services/screentransport/screensinkprocessor/include/image_sink_processor.h b/services/screentransport/screensinkprocessor/include/image_sink_processor.h index 8929a74b..20ab7d27 100644 --- a/services/screentransport/screensinkprocessor/include/image_sink_processor.h +++ b/services/screentransport/screensinkprocessor/include/image_sink_processor.h @@ -26,7 +26,7 @@ namespace DistributedHardware { class ImageSinkProcessor : public IImageSinkProcessor { public: ImageSinkProcessor() = default; - ~ImageSinkProcessor() = default; + ~ImageSinkProcessor() override = default; int32_t ConfigureImageProcessor(const VideoParam &localParam, const VideoParam &remoteParam, const std::shared_ptr &imageListener) override; diff --git a/services/screentransport/screensinktrans/include/screen_sink_trans.h b/services/screentransport/screensinktrans/include/screen_sink_trans.h index f7b417c5..807eb932 100644 --- a/services/screentransport/screensinktrans/include/screen_sink_trans.h +++ b/services/screentransport/screensinktrans/include/screen_sink_trans.h @@ -32,7 +32,7 @@ class ScreenSinkTrans : public IScreenSinkTrans, public std::enable_shared_from_this { public: ScreenSinkTrans() = default; - ~ScreenSinkTrans() = default; + ~ScreenSinkTrans() override = default; int32_t SetUp(const VideoParam &localParam, const VideoParam &remoteParam, const std::string &peerDevId) override; int32_t Release() override; diff --git a/services/screentransport/screensourceprocessor/encoder/include/image_encoder_callback.h b/services/screentransport/screensourceprocessor/encoder/include/image_encoder_callback.h index b3410caf..a100ce46 100644 --- a/services/screentransport/screensourceprocessor/encoder/include/image_encoder_callback.h +++ b/services/screentransport/screensourceprocessor/encoder/include/image_encoder_callback.h @@ -29,7 +29,7 @@ class ImageEncoderCallback : public Media::AVCodecCallback { public: explicit ImageEncoderCallback(const std::shared_ptr &encoder) : videoEncoder_(encoder) {}; - ~ImageEncoderCallback() = default; + ~ImageEncoderCallback() override = default; void OnError(Media::AVCodecErrorType errorType, int32_t errorCode) override; void OnOutputBufferAvailable(uint32_t index, Media::AVCodecBufferInfo info, Media::AVCodecBufferFlag flag) override; diff --git a/services/screentransport/screensourceprocessor/encoder/include/image_source_encoder.h b/services/screentransport/screensourceprocessor/encoder/include/image_source_encoder.h index 0a15e52a..d5a6dfe2 100644 --- a/services/screentransport/screensourceprocessor/encoder/include/image_source_encoder.h +++ b/services/screentransport/screensourceprocessor/encoder/include/image_source_encoder.h @@ -66,7 +66,6 @@ private: std::shared_ptr videoSharedMemory_; std::shared_ptr encodeVideoCallback_; std::weak_ptr imageProcessorListener_; - const size_t DATA_BUFFER_MAX_SIZE = 10 * 1024 * 1024; }; } // namespace DistributedHardware } // namespace OHOS diff --git a/services/screentransport/screensourceprocessor/include/image_source_processor.h b/services/screentransport/screensourceprocessor/include/image_source_processor.h index b95f9c14..d42fbd96 100644 --- a/services/screentransport/screensourceprocessor/include/image_source_processor.h +++ b/services/screentransport/screensourceprocessor/include/image_source_processor.h @@ -26,7 +26,7 @@ namespace DistributedHardware { class ImageSourceProcessor : public IImageSourceProcessor { public: ImageSourceProcessor() = default; - ~ImageSourceProcessor() = default; + ~ImageSourceProcessor() override = default; int32_t ConfigureImageProcessor(const VideoParam &localParam, const VideoParam &remoteParam, const std::shared_ptr &listener) override; diff --git a/services/screentransport/screensourcetrans/include/screen_source_trans.h b/services/screentransport/screensourcetrans/include/screen_source_trans.h index 3f40712a..2d63fa10 100644 --- a/services/screentransport/screensourcetrans/include/screen_source_trans.h +++ b/services/screentransport/screensourcetrans/include/screen_source_trans.h @@ -36,7 +36,7 @@ class ScreenSourceTrans : public IScreenSourceTrans, public std::enable_shared_from_this { public: ScreenSourceTrans() = default; - ~ScreenSourceTrans() = default; + ~ScreenSourceTrans() override = default; int32_t SetUp(const VideoParam &localParam, const VideoParam &remoteParam, const std::string &peerDevId) override; int32_t Release() override; @@ -61,9 +61,6 @@ private: private: static const constexpr char *LOG_TAG = "ScreenSourceTrans"; - static constexpr uint8_t SESSION_WAIT_SECONDS = 5; - static constexpr uint8_t DATA_WAIT_SECONDS = 1; - static constexpr size_t DATA_QUEUE_MAX_SIZE = 1000; std::mutex sessionMtx_; std::mutex dataMtx_; diff --git a/services/screentransport/screensourcetrans/src/screen_source_trans.cpp b/services/screentransport/screensourcetrans/src/screen_source_trans.cpp index 63141660..5491cb3e 100644 --- a/services/screentransport/screensourcetrans/src/screen_source_trans.cpp +++ b/services/screentransport/screensourcetrans/src/screen_source_trans.cpp @@ -17,6 +17,7 @@ #include +#include "dscreen_constants.h" #include "dscreen_errcode.h" #include "dscreen_hisysevent.h" #include "dscreen_hitrace.h" -- Gitee