A video push stream quick establishment method and device of a portable surveillance ball and a storage medium

CN122802656APending Publication Date: 2026-09-22SHENZHEN WEIYUNTONG TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611155542.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-31
Publication Date
2026-09-22

AI Technical Summary

Technical Problem

该类方式能够实现视频回传,但在临时布控场景下,由于设备部署位置不固定、无线网络状态存在波动、平台接入参数可能不同,容易导致从设备进入布控状态到目标设备显示首个现场画面的时间较长

Benefits of technology

1、本申请中提供的便携式布控球的视频推流快速建立方法,在便携式布控球由非布控状态切换至布控状态后,根据状态信息和接入信息生成多个候选媒体传输上下文,使后续的视频推流建立过程能够与当前布控状态以及目标设备相适配;

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122802656A_ABST
    Figure CN122802656A_ABST
Patent Text Reader

Abstract

The application discloses a portable control ball video push stream quick establishment method and device and a storage medium. The method comprises the following steps: acquiring a deployment trigger instruction; generating a plurality of candidate media transmission contexts according to state information and access information; generating a first media frame through the portable control ball; generating a promotable media probe payload according to the first media frame; sending a first message carrying the promotable media probe payload to a candidate push stream channel; determining a target push stream channel and a corresponding target promotable media probe payload according to channel response information returned by the candidate push stream channel; converting the target promotable media probe payload from a probe state to a flow state according to the target promotable media probe payload; generating a second media frame, making the time stamp of the second media frame continuous to the target promotable media probe payload, and sending the second media frame through the target push stream channel.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image processing technology, and in particular to a method, apparatus and storage medium for rapid video streaming establishment using a portable PTZ camera. Background Technology

[0002] Portable surveillance cameras are temporarily deployed video acquisition devices, typically used in scenarios such as road maintenance, temporary construction, emergency response, and patrol of key areas. Compared to fixed monitoring equipment, the deployment location, network environment, and access platform of portable surveillance cameras may vary depending on the usage scenario. Therefore, they usually need to establish a media transmission connection with the target device via a wireless communication network after arriving on site in order to push the on-site video footage to the command platform, video access server, or mobile terminal.

[0003] Existing portable surveillance cameras typically require several steps to establish a video stream before they can display the live feed. These steps include network access, platform authentication, media session establishment, and video stream transmission. The target device can only display the live feed after receiving media data that meets the decoding requirements. While this method enables video transmission, in temporary deployment scenarios, the unpredictable device locations, fluctuating wireless network conditions, and varying platform access parameters can lead to a prolonged time between the device entering deployment mode and the target device displaying the first live feed.

[0004] Therefore, it is necessary to provide a method for quickly establishing video streaming suitable for portable surveillance cameras to improve the problem of slow initial scene setup speed of portable surveillance cameras in temporary deployment scenarios. Summary of the Invention

[0005] To address the aforementioned technical issues, this application provides a method, apparatus, and storage medium for rapidly establishing video streaming using a portable PTZ camera.

[0006] The technical solution provided in this application is described below:

[0007] The first aspect of this application provides a method for rapid video streaming establishment using a portable surveillance sphere, applicable to a portable surveillance sphere, the method comprising: Obtain a deployment trigger indication, which is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state; In response to the deployment trigger indication, status information and access information are obtained; Multiple candidate media transmission contexts are generated based on the status information and the access information; A first media frame is generated by a portable surveillance ball. The first media frame is a media frame that can be independently decoded by the target device, and the data size of the first media frame is smaller than the data size of the media frame generated by the portable surveillance ball. Generate an upgradable media detection payload based on the first media frame; Based on the multiple candidate media transmission contexts, a first message carrying the upgradable media detection payload is sent to the candidate streaming channel; The target propulsion channel and the corresponding target upgradable media detection payload are determined based on the channel response information returned by the candidate propulsion channels. The target media session is switched from the probe state to the streaming state according to the target upgradable media detection payload, so that the first media frame is the first displayable media frame of the target media session; A second media frame is generated, with its timestamp continuing from that of the target upgradable media detection payload, and then transmitted through the target streaming channel.

[0008] Optionally, determining the target push channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate push channel includes: Receive the second message returned by the candidate push stream channel; Parse the candidate channel identifier and candidate media session identifier from the second message; Based on the candidate channel identifier and / or the candidate media session identifier, the second message is matched with the corresponding first message; The target propulsion channel and the corresponding target upgradable media detection payload are determined based on the matching results.

[0009] Optionally, in response to the deployment trigger indication, generating multiple candidate media transmission contexts based on status information and access information includes: In response to the deployment trigger indication, first status information and first access information are obtained; Multiple candidate media transmission contexts are generated based on the first status information and the first access information; Obtain the second state information; Update at least one candidate media transmission context based on the second state information.

[0010] Optionally, after sending a first message carrying the upgradable media detection payload to the candidate streaming channel, and before determining the target streaming channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate streaming channel, the method further includes: Obtain second status information, which includes network measurement information obtained after sending the first message. Based on the network measurement information, determine whether the candidate push channel meets the conditions for continued detection; If the conditions for continued probing are met, the corresponding candidate media transmission context remains in the probing waiting state. If the conditions for continued detection are not met, the candidate media transmission context is regenerated based on the updated second state information; The first message carrying the upgradable media detection payload is retransmitted based on the regenerated candidate media transmission context.

[0011] Optionally, the step of generating a first media frame via a portable surveillance sphere, wherein the first media frame is a media frame that can be independently decoded by the target device, and the data size of the first media frame is smaller than the data size of the media frame generated by the portable surveillance sphere, includes: The first encoding parameter is determined based on the state information; Based on the first encoding parameters, the current image frame or cached image frame acquired by the portable surveillance ball is encoded to generate the first media frame.

[0012] Optionally, generating multiple candidate media transmission contexts based on the status information and the access information includes: The communication bearer set is determined based on the status information, and the platform access set is determined based on the access information; Based on the mapping relationship between the communication bearer set and the platform access set, multiple candidate push channels are generated; Configure candidate channel identifiers and candidate media session identifiers for the multiple candidate push channels respectively; Construct candidate media transmission contexts based on the candidate channel identifier and candidate media session identifier corresponding to the same candidate push channel.

[0013] Optionally, the candidate media transmission context includes at least one of the following: candidate channel identifier, candidate media session identifier, transmission endpoint parameters, protocol stack parameters, authentication parameters, media encapsulation parameters, and communication bearer identifier.

[0014] Optionally, the portable surveillance PTZ includes a housing, a folding support structure, and a camera PTZ. The housing has a receiving cavity and an opening communicating with the receiving cavity. The folding support structure includes a fixed base, a telescopic rod assembly and a PTZ camera mounting base. The fixed base is disposed in the receiving cavity. One end of the telescopic rod assembly is connected to the fixed base and the other end is connected to the PTZ camera mounting base. The PTZ camera is mounted on the PTZ camera mounting base. The telescopic rod assembly has a retracted state where it is housed within the accommodating cavity and an extended state where it extends out of the accommodating cavity.

[0015] A second aspect of this application provides a portable PTZ camera for rapid video streaming setup, used to control the portable PTZ camera, the device comprising: The first acquisition unit is used to acquire a deployment trigger indication, which is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state. The second acquisition unit is used to acquire status information and access information in response to the deployment trigger indication; A context generation unit is used to generate multiple candidate media transmission contexts based on the state information and the access information; The first frame generation unit is used to generate a first media frame through a portable control ball. The first media frame is a media frame that can be independently decoded by the target device, and the data volume of the first media frame is less than the data volume of the media frame generated by the portable control ball. A payload generation unit is used to generate an upgradable media detection payload based on the first media frame. The first sending unit is configured to send a first message carrying the upgradable media detection payload to the candidate streaming channel based on the plurality of candidate media transmission contexts. The determination unit is used to determine the target propulsion channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate propulsion channels; A state transition unit is used to transition a target media session from a probe state to a streaming state based on the target upgradable media probe payload, so that the first media frame is the first displayable media frame of the target media session; The second frame generation unit is used to generate a second media frame, such that the timestamp of the second media frame is continuous with the target upgradable media detection payload, and the second media frame is sent through the target streaming channel.

[0016] A third aspect of this application provides a portable video streaming rapid setup device for a PTZ camera, the device comprising: Processor, memory, input / output units, and bus; The processor is connected to the memory, the input / output unit, and the bus; The memory stores a program, which the processor invokes to execute the first aspect and any one of the optional methods in the first aspect.

[0017] A fourth aspect of this application provides a computer-readable storage medium on which a program is stored, which, when executed on a computer, performs the methods of the first aspect and any one of the first aspects.

[0018] As can be seen from the above technical solutions, this application has the following beneficial effects: 1. The portable surveillance ball's video streaming rapid establishment method provided in this application generates multiple candidate media transmission contexts based on status information and access information after the portable surveillance ball switches from a non-surveillance state to a surveillance state, so that the subsequent video streaming establishment process can be adapted to the current surveillance state and the target device. 2. This application generates a first media frame that can be independently decoded by the target device and has a small data volume, and generates an upgradable media detection payload based on the first media frame. This upgradable media detection payload can participate in the detection in the candidate push channel along with the first message, and can also serve as the basis for the start of the target media session after the target push channel is determined.

[0019] 3. The candidate channel detection process and the preparation process for the first displayable media frame are associated in the same media detection payload, which reduces the waiting time caused by completing channel detection first and then regenerating and sending the first decodable media frame.

[0020] 4. This application determines the target streaming channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate streaming channels, and converts the target upgradable media detection payload from the detection state to the streaming start state, making the first media frame the first displayable media frame of the target media session. In this way, the media detection payload already used for channel detection can be reused in the streaming start stage of the target media session, avoiding the complete separation of detection data and streaming start data. Attached Figure Description

[0021] To more clearly illustrate the technical solutions in this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0022] Figure 1 A schematic flowchart of an embodiment of the method for rapidly establishing video streaming using a portable surveillance sphere provided in this application; Figure 2 This is a flowchart illustrating a specific implementation of step S102 in the rapid video streaming establishment method for portable surveillance spheres provided in this application. Figure 3 This is a flowchart illustrating another specific implementation of step S102 in the method for rapidly establishing a video stream using a portable surveillance ball provided in this application. Figure 4 This is a flowchart illustrating a specific implementation of step S106 in the method for rapidly establishing a video stream using a portable surveillance ball provided in this application. Figure 5 This is a schematic flowchart of another embodiment of the method for rapidly establishing a video stream using a portable surveillance sphere provided in this application. Figure 6 This is a schematic diagram showing the unfolded structure of an embodiment of the portable control ball used in the rapid video streaming creation method of the portable control ball provided in this application; Figure 7 This is a schematic diagram of the storage structure of a portable control ball used in the rapid video streaming creation method for portable control balls provided in this application. Figure 8 A schematic diagram of an embodiment of the portable video streaming rapid setup device for a telescope provided in this application; Figure 9 This is a schematic diagram of an embodiment of a video streaming rapid setup device for another portable PTZ camera provided in this application. Detailed Implementation

[0023] The video streaming rapid setup method provided in this application can be applied to portable surveillance cameras. To better understand the embodiments provided in this application, the embodiments of the portable surveillance camera provided in this application are described below. (See attached document for details.) Figure 6 as well as Figure 7 The portable control ball provided in this embodiment may include a housing 01, a folding support structure 02, and a camera 03.

[0024] The housing 01 has a receiving cavity 04 and an opening communicating with the receiving cavity 04. The receiving cavity 04 is used to accommodate at least a portion of the folding support structure 02. The folding support structure 02 includes a fixed base 05, a telescopic rod assembly 06, and a PTZ camera mounting base 07. The fixed base 05 is disposed within the receiving cavity 04. One end of the telescopic rod assembly 06 is connected to the fixed base 05, and the other end is connected to the PTZ camera mounting base 07. The PTZ camera 03 is mounted on the PTZ camera mounting base 07.

[0025] The telescopic pole assembly 06 has a retracted state and an extended state. In the retracted state, the telescopic pole assembly 06 is stored in the accommodating cavity 04 for easy transport of the portable surveillance camera; in the extended state, the telescopic pole assembly 06 extends out of the accommodating cavity 04, raising the camera 03 relative to the housing 01 to capture on-site images.

[0026] In this embodiment, the portable PTZ camera can be stored in the housing 01 when not under control, and when under control, the camera PTZ camera 03 can be unfolded to the acquisition position through the folding support structure 02, thereby providing an image acquisition basis for the subsequent rapid establishment of video streaming.

[0027] Please see Figure 1This application first provides an embodiment of a rapid video streaming establishment method using a portable surveillance sphere. It should be noted that, in this embodiment, the rapid video streaming establishment method using the portable surveillance sphere can be executed by the portable surveillance sphere itself, or by a processing unit, controller, or electronic device with data processing capabilities installed within the portable surveillance sphere. After entering the field deployment state, the portable surveillance sphere can establish a media transmission connection with the target device via a wireless communication network. The target device can be a video access server, command and dispatch platform, video storage device, or mobile terminal, or any device capable of receiving video streams.

[0028] The following is a detailed description of this embodiment, which includes: S101. Obtain a deployment trigger indication, wherein the deployment trigger indication is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state; In this embodiment, the non-deployment state can be the state in which the portable surveillance camera is not performing on-site video acquisition tasks, such as in transportation, storage, standby, or low-power state. The deployment state can be the state in which the portable surveillance camera has been deployed to the site and is ready to perform image acquisition, network access, and video streaming.

[0029] Deployment trigger indications can be generated by the portable PTZ camera upon detecting a preset deployment event, or they can be triggered by user operation or remote control commands. For example, when the portable PTZ camera is moved to the maintenance work area, its housing is opened, its support structure is deployed, the camera is powered on, or the device is woken up from a low-power state, the portable PTZ camera can be considered to have met the conditions for entering deployment mode. At this time, the portable PTZ camera can generate a deployment trigger indication to initiate the subsequent video streaming and rapid setup process.

[0030] By setting deployment trigger indicators, the video streaming setup process can be correlated with the actual deployment actions of the device. In other words, the portable surveillance PTZ camera does not need to continuously attempt to establish a video stream during transportation or standby phases. Instead, it only initiates processes such as status acquisition, candidate channel generation, and media detection after detecting that it has entered the surveillance state.

[0031] S102. In response to the deployment trigger indication, generate multiple candidate media transmission contexts based on status information and access information; In this embodiment, after receiving the deployment trigger indication, the portable surveillance camera can acquire status information and access information. The status information reflects the current operating environment and device status of the portable surveillance camera, while the access information reflects the access conditions required for the portable surveillance camera to establish a media transmission connection with the target device.

[0032] Status information can include information related to the current location, network status, power supply status, or device operating status. For example, when a portable surveillance camera is deployed on a highway slope, bridge maintenance area, or temporary construction area, the wireless network quality may vary at different locations; therefore, status information can be used to characterize the communication conditions at the current deployment location. Access information can include the target device's address, access method, authentication information, or parameters related to media transmission, used to subsequently generate candidate media transmission contexts capable of accessing the target device.

[0033] In one example, after entering deployment mode, the portable surveillance camera can obtain its current location, battery level, current wireless network measurement results, and the access address of the target platform. This information can be used together to determine which candidate streaming paths should be generated subsequently, instead of directly using a fixed default streaming path.

[0034] In this embodiment, the portable surveillance sphere can generate multiple candidate media transmission contexts based on status and access information. A candidate media transmission context can be understood as contextual information describing a candidate media transmission scheme, and it can be associated with a candidate streaming channel. Different candidate media transmission contexts may differ in communication bearer, target endpoint, protocol parameters, authentication parameters, or media session parameters.

[0035] For example, when status information indicates that the current wireless network is available, and access information indicates that the target device supports multiple access points, a portable surveillance PTZ can generate multiple candidate media transmission contexts. Each candidate media transmission context can serve as the basis for subsequently sending the first message. In this way, the portable surveillance PTZ can probe and select among multiple candidate streaming channels, rather than directly establishing a continuous video stream before confirming channel availability.

[0036] By generating multiple candidate media transmission contexts, the portable surveillance sphere can combine the on-site conditions with the platform access conditions to provide a candidate set for subsequent determination of the target streaming channel. This process enables video streaming establishment to have a certain degree of adaptability, and is particularly suitable for situations where the deployment location changes, network status changes, or platform access changes in temporary deployment scenarios.

[0037] In some embodiments, step S102 is not limited to acquiring fixed information all at once. Since portable surveillance cameras are typically deployed in temporary locations, their network status, power supply status, or target device access conditions may change in a short period. Therefore, candidate media transmission contexts can be generated based on the initially acquired information, and then at least one candidate media transmission context can be updated based on subsequently acquired status information. This allows the candidate media transmission contexts to be more suitable for the actual communication environment after the portable surveillance camera enters the deployment state.

[0038] See Figure 2 In one specific embodiment, this application provides a specific implementation method for generating multiple candidate media transmission contexts based on status information and access information. This implementation method is described below and includes: S001. Determine the communication bearer set based on the status information, and determine the platform access set based on the access information; In this embodiment, the status information can be used to reflect the current communication capabilities and operating conditions of the portable surveillance sphere. The portable surveillance sphere can determine the communication bearer set based on the status information. The communication bearer set may include one or more communication bearers currently available for transmitting media data.

[0039] Access information can be used to reflect the access conditions available to the target device or platform. A portable surveillance camera can determine the platform access set based on this access information. The platform access set can include one or more platform access points, which can correspond to different target addresses, access protocols, authentication methods, access ports, or media reception services.

[0040] In some embodiments, the communication bearer set can be represented as follows: C = {c1, c2, ..., c m}; In this context, C represents the communication bearer set, c i Let represent the i-th communication bearer, and m represent the number of communication bearers. The platform access set can be represented as: P={p1,p2,...,p n}; Where P represents the platform access set, p j Let j represent the j-th platform access point, and n represent the number of platform access points.

[0041] In one example, the status information indicates that the portable surveillance sphere currently has two available communication bearers: a first cellular network bearer c1 and a second cellular network bearer c2; the access information indicates that the target platform has two available access points: a first platform access point p1 and a second platform access point p2. At this point, the portable surveillance sphere can obtain the communication bearer set C = {c1, c2} and the platform access set P = {p1, p2}.

[0042] S002. Based on the mapping relationship between the communication bearer set and the platform access set, generate multiple candidate push channels; After determining the communication bearer set and the platform access set, the portable surveillance sphere can generate multiple candidate streaming channels based on the mapping relationship between the communication bearer set and the platform access set. The mapping relationship can be used to indicate whether a candidate streaming channel can be formed between a certain communication bearer and a certain platform access point.

[0043] In some embodiments, the mapping relationship can be expressed as follows: R C×P; In this formula, R represents the mapping relationship between the communication bearer set C and the platform access set P, and C×P represents the Cartesian product of the communication bearer set and the platform access set. When (c i ,p j When )∈R, it represents the i-th communication bearer c i Access point p of the j-th platform j Candidate push channels can be formed between them; when (c i ,p j ) When R is in the range, it indicates that the two do not form a candidate push channel.

[0044] The mapping relationship can be determined based on the availability of the communication bearer, the reachability of the platform access point, protocol compatibility, authentication conditions, network quality, or preset access policies. For example, if a communication bearer can access a platform access point and the corresponding protocol and authentication conditions meet the requirements, a mapping relationship can be established between the communication bearer and the platform access point.

[0045] In some embodiments, the portable surveillance sphere can also calculate candidate channel evaluation values ​​for each set of mappable communication bearers and platform access points to assist in determining candidate streaming channels. The candidate channel evaluation value can be expressed as: Q ij =a·B i +b·S i -c·D i -d·L i +e·A j Among them, Q ij Indicates communication bearer c i With platform access point p j The evaluation value of the formed candidate push channel; Bi represents the communication bearer c i Corresponding available bandwidth; S i Indicates communication bearer c i The corresponding signal quality; Di represents the communication bearer c i To the platform access point p j Network latency; L i Indicates communication bearer c iTo the platform access point p j Packet loss level; A j Indicates the platform access point p j Access availability; a, b, c, d, and e are preset weight coefficients. This evaluation value is only used to illustrate one possible calculation method. In actual implementation, threshold judgment, rule matching, or other evaluation methods can also be used to determine candidate push channels.

[0046] If a communication bearer and a platform access point meet preset mapping conditions, the portable surveillance sphere can generate a candidate streaming channel based on these two conditions. The candidate streaming channel can be represented as: H ij =f(c i ,p j ) Among them, H ij Indicates that the communication carrier c i With platform access point p j The candidate push channels are formed, where f represents the channel generation rule.

[0047] In a specific example, the communication bearer set C = {c1, c2} and the platform access set P = {p1, p2}. If, based on network reachability and protocol compatibility, c1 can access both p1 and p2, while c2 can only access p2, then three candidate push channels H can be generated. 11 H 12 and H 22 , corresponding to (c1,p1), (c1,p2) and (c2,p2) respectively.

[0048] S003. Configure candidate channel identifiers and candidate media session identifiers for the multiple candidate streaming channels respectively; In this embodiment, after generating multiple candidate streaming channels, the portable monitoring ball can configure candidate channel identifiers and candidate media session identifiers for each candidate streaming channel. The candidate channel identifier is used to distinguish different candidate streaming channels, and the candidate media session identifier is used to distinguish the candidate media sessions corresponding to different candidate streaming channels.

[0049] Candidate channel identifiers can be generated based on communication bearers, platform access points, generation order, timestamps, or random numbers. Candidate media session identifiers can be generated based on candidate channel identifiers, device identifiers, target device identifiers, deployment trigger counts, or session counts. By configuring candidate channel identifiers and candidate media session identifiers, a correspondence can be established between subsequent first messages, second messages, and scalable media detection payloads.

[0050] In some more specific embodiments, the candidate channel identifier can be represented as follows: CID ij=G1(c i ,p j ,t) Among them, CID ij Indicates that the communication carrier c i and platform access point p j The candidate channel identifier of the formed candidate push channel, G1 represents the first identifier generation function, and t represents the current deployment trigger time or the current channel generation time.

[0051] Candidate media session identifiers can be represented as: SID ij =G2(C I D ij ,DID,k) Among them, SID ij Here, G2 represents the candidate media session identifier, DID represents the device identifier of the portable surveillance PTZ camera, and k represents the session count or deployment trigger number. The above formula indicates that the candidate media session identifier can be associated with candidate channel identifiers and device-side information, and does not limit the specific identifier generation algorithm.

[0052] In one example, the portable control ball generates three candidate push flow channels H. 11 H 12 and H 22 Then, candidate channel identifiers (CIDs) can be configured separately. 11 CID 12 and CID 22 Configure candidate media session identifiers (SIDs) accordingly. 11 SID 12 and SID 22 In this way, when a second message is subsequently received from a candidate push channel, the portable surveillance sphere can determine which first message and which upgradable media detection payload the second message corresponds to based on the candidate channel identifier and the candidate media session identifier.

[0053] S004. Construct a candidate media transmission context based on the candidate channel identifier and candidate media session identifier corresponding to the same candidate push channel.

[0054] In this step, the portable monitoring sphere can construct a candidate media transmission context based on the candidate channel identifier and candidate media session identifier corresponding to the same candidate streaming channel. The candidate media transmission context can be used to store the association between the candidate streaming channel and its identifier, session, and transmission configuration.

[0055] In some embodiments, a candidate media transport context can be represented as follows: CTX ij ={H ijCID ij SID ij} Among them, CTX ij Indicates the candidate push channel H ij Constructed candidate media transport context, CID ij Indicates the candidate channel identifier, SID ij This indicates the candidate media session identifier.

[0056] In practical implementation, candidate media transmission contexts can also be associated with information such as communication bearers, platform access points, transmission endpoints, protocol parameters, authentication parameters, media encapsulation parameters, or context states. For example, a candidate media transmission context can be represented as: CTX ij ={c i ,p j, H ij CID ij SID ij ,EP j ,Proto j ,Auth j State ij} Among them, EP j Indicates the platform access point p j The corresponding transmission endpoint, Proto j Indicates the platform access point p j The corresponding protocol parameters, Auth j Indicates the platform access point p j The corresponding authentication parameter, State ij This indicates the state of the candidate media transmission context.

[0057] In a specific example, candidate push channel H 11 Corresponding to the first cellular network bearer c1 and the first platform access point p1, the portable surveillance ball is configured with a candidate channel identifier (CID). 11 and candidate media session identifier (SID) 11 Then, a candidate media transport context (CTX) can be constructed. 11 The candidate media transport context CTX 11 This is used to indicate that when sending the first message from the first cellular network bearer c1 to the first platform access point p1, the candidate channel identifier (CID) should be carried or associated. 11 and candidate media session identifier (SID) 11 .

[0058] In this embodiment, the portable surveillance sphere can combine the communication bearer capability corresponding to the status information with the platform access capability corresponding to the access information to form multiple candidate media transmission contexts with clear identifiers and session relationships. Thus, when subsequently sending a first message carrying a scalable media detection payload, the portable surveillance sphere can perform detection based on different candidate media transmission contexts. Upon receiving a second message returned by a candidate streaming channel, it can also determine the first message and scalable media detection payload corresponding to the second message based on the candidate channel identifier and the candidate media session identifier, thereby providing a clear data association basis for determining the target streaming channel.

[0059] See Figure 3 This application provides a specific implementation of step S102, which includes: S1021. In response to the deployment trigger indication, obtain first status information and first access information; After receiving the deployment trigger indication, the portable surveillance camera can acquire first status information and first access information. The first status information can be the status information acquired by the portable surveillance camera at the initial stage of entering the deployment state, and the first access information can be the target device access information acquired by the portable surveillance camera at the initial stage of entering the deployment state.

[0060] The first state information can be used to reflect the device status and communication environment of the portable surveillance camera when it first enters the surveillance state. For example, the first state information may include the location of the portable surveillance camera, power supply status, wireless network status, or device operating status. The first access information can be used to reflect the access conditions of the target device, such as the target device address, access port, access protocol, or authentication-related information.

[0061] S1022. Generate multiple candidate media transmission contexts based on the first status information and the first access information; The portable PTZ camera can generate multiple candidate media transmission contexts based on the first state information and the first access information. A candidate media transmission context can be understood as a transmission configuration describing a candidate streaming channel. Multiple candidate media transmission contexts can each correspond to a different candidate streaming channel.

[0062] Specifically, the portable surveillance camera can determine the currently available communication conditions based on the first state information and the available target device access conditions based on the first access information. Then, the portable surveillance camera can combine the communication conditions and the target device access conditions to generate multiple candidate media transmission contexts. Each candidate media transmission context can be used to subsequently generate and send a first message.

[0063] In practical applications, the first state information indicates that the current cellular mobile communication network is available, and the first access information indicates that the target platform has multiple available access points. Therefore, the portable surveillance sphere can generate multiple candidate media transmission contexts. Different candidate media transmission contexts can correspond to different access points or different media session configurations. Thus, the portable surveillance sphere can proceed without relying on a single streaming channel during the subsequent channel detection phase.

[0064] S1023, Obtain the second state information; After generating multiple candidate media transmission contexts, the portable surveillance sphere can also acquire second state information. This second state information can be acquired after the first state information and reflects the state changes of the portable surveillance sphere after generating the candidate media transmission contexts.

[0065] The second state information can be of the same type as the first state information, or it can include state content different from the first state information. For example, the second state information may include updated wireless network measurement results, updated power supply status, device attitude change information, positioning change information, or target device access status change information. The second state information can be obtained after the candidate media transmission context is generated and before the first message is sent, or it can be obtained after the first message is sent and before the target streaming channel is determined.

[0066] S1024. Update at least one candidate media transmission context according to the second status information.

[0067] After acquiring the second state information, the portable surveillance sphere can update at least one candidate media transmission context based on this information. The updated object can be all candidate media transmission contexts, or one or more of them. The updated content may include the availability status of the candidate streaming channel, transmission endpoints, protocol parameters, media session parameters, candidate channel priority, or candidate context status, etc.

[0068] For example, when the second status information indicates a deterioration in communication conditions, the portable surveillance camera can lower the priority of the candidate media transmission context corresponding to that communication condition, or mark it as temporarily unused. As another example, when the second status information indicates an improvement in uplink conditions of a network bearer, the portable surveillance camera can maintain or increase the priority of the corresponding candidate media transmission context. Furthermore, when the second status information indicates that a certain access point of the target device is unreachable, the portable surveillance camera can update the access parameters or context state in the corresponding candidate media transmission context.

[0069] In one example, the portable surveillance sphere generates candidate media transmission contexts CTX1 and CTX2 based on first state information and first access information. CTX1 corresponds to a first candidate streaming channel, and CTX2 corresponds to a second candidate streaming channel. Then, the portable surveillance sphere acquires second state information indicating that the wireless network quality corresponding to the first candidate streaming channel has degraded, while the network quality corresponding to the second candidate streaming channel remains stable. At this point, the portable surveillance sphere can update the state or priority of CTX1 and maintain CTX2 as an available candidate media transmission context.

[0070] In this specific embodiment, the portable deployment ball can first form a set of candidate media transmission contexts after deployment is triggered, and then update the set according to subsequent state changes, so that the candidate media transmission contexts can better fit the dynamic communication conditions of the actual deployment site.

[0071] S103. A first media frame is generated by a portable control ball. The first media frame is a media frame that can be independently decoded by the target device, and the data volume of the first media frame is less than the data volume of the media frame generated by the portable control ball. The portable PTZ camera can generate a first media frame based on images captured by the PTZ camera. This first media frame can originate from the current image frame or from image frames cached before and after the device enters deployment mode. The first media frame provides candidate media data for the first displayable image during the rapid establishment of a video stream.

[0072] The first media frame is a media frame that can be independently decoded by the target device. In other words, given the appropriate media initialization conditions, the target device can obtain the live image based on this first media frame, without relying on other consecutive video frames preceding it. Thus, the first media frame can serve the purpose of rapid image output.

[0073] Meanwhile, the data size of the first media frame is smaller than that of the media frame generated by the portable surveillance sphere. Here, the media frame can be understood as the media frame generated by the portable surveillance sphere in regular video streaming mode, especially the key media frame generated in the main stream mode. By reducing the data size of the first media frame, the transmission burden when the first message is sent in the candidate streaming channel can be reduced, making the first media frame more suitable for participating in channel probing and rapid stream initiation.

[0074] For example, a portable PTZ camera can process high-definition images captured by a PTZ camera into key media frames with a lower data volume, so that the key media frames can still reflect the basic scene, but their transmission overhead is less than that of conventional high-definition key frames.

[0075] In a specific embodiment, step S103 is implemented by: determining a first encoding parameter based on the status information; and encoding the current image frame or cached image frame acquired by the portable surveillance ball based on the first encoding parameter to generate a first media frame.

[0076] In this embodiment, when the portable surveillance ball generates the first media frame, it can determine the first encoding parameters based on the current state information, and encode the current image frame or the cached image frame based on the first encoding parameters to obtain a first media frame with a small data volume that can be independently decoded by the target device. Therefore, the first media frame can both reflect the scene and reduce the transmission overhead when sent as a potential media detection payload in the candidate streaming channel.

[0077] In this embodiment, the status information may include at least one of the following: the wireless network status of the portable surveillance sphere, power supply status, device operating status, current location, or current deployment scenario information. The first encoding parameter may be an encoding control parameter used to generate the first media frame. The first encoding parameter may include at least one of the following: frame size, resolution, bit rate, quantization parameter, encoded frame type, frame rate, image cropping region, or region of interest parameter.

[0078] When determining the first encoding parameters, the portable surveillance sphere can comprehensively control the data volume and decodeability of the first media frame based on the status information. For example, when the status information indicates that the current wireless network quality is low, a lower bit rate, a smaller frame size, or a higher compression strength can be determined to reduce the data volume of the first media frame; when the status information indicates that the power supply margin is low, the encoding complexity of the first media frame can be reduced to reduce power consumption during the encoding process; when the status information indicates that the current network quality is good, the image quality of the first media frame can be appropriately improved to enable the target device to obtain a clearer first scene.

[0079] The portable PTZ camera can acquire the current image frame captured in real time by the PTZ camera, or it can read cached image frames from the buffer. The current image frame can be an image frame captured by the PTZ camera after the portable PTZ camera enters deployment mode. The cached image frames can be image frames cached within a preset time range before and after the deployment trigger indication is generated. When using cached image frames, even if the PTZ camera has just finished starting up or the current frame has not yet stabilized, the first media frame can be quickly generated based on the image frames already acquired in the buffer.

[0080] During the encoding process, the portable surveillance sphere can encode the current image frame or the cached image frame according to the first encoding parameters to generate a first media frame that can be independently decoded by the target device. This first media frame can be a critical media frame, such as an I-frame, an IDR frame, or other media frames that can be decoded without relying on preceding media frames. Since the first media frame can be independently decoded by the target device, when the first media frame is received by the target device along with the upgradable media detection payload and converted to the initial flow state, the target device can display the first scene based on the first media frame.

[0081] S104. Generate an upgradable media detection payload based on the first media frame; After generating the first media frame, the portable surveillance sphere can generate an escalable media detection payload based on the first media frame. The escalable media detection payload is a data object used in this embodiment to connect "candidate channel detection" and "media session initiation".

[0082] During the probing phase, the upgradable media probe payload can be carried as the data content of the first message to test whether the candidate streaming channel can receive, identify, or process relevant media data. During the initiation phase, once a candidate streaming channel is determined as the target streaming channel, the upgradable media probe payload corresponding to that channel can be further used in the initiation process of the target media session.

[0083] Therefore, the upgradable media probe payload is not simply network connectivity probe data, nor is it ordinary continuous video stream segments. It is at least related to the first media frame and can be converted from probe use to streaming use when certain conditions are met. With this setup, the data sent by the portable surveillance sphere during the channel probe phase can be reused when the target media session is established, thereby reducing the need for repeated preparation and retransmission of the first displayable media frame.

[0084] In one specific implementation, a portable surveillance sphere can combine a first media frame with relevant information used to support its identification, decoding, or timing continuation to form an upgradable media detection payload. The specific combination method can be determined based on the actual media encapsulation method or the target device's receiving method.

[0085] S105. Based on the multiple candidate media transmission contexts, send a first message carrying the upgradable media detection payload to the candidate streaming channel; In this application, the portable surveillance ball can determine the corresponding candidate streaming channels based on multiple candidate media transmission contexts and send a first message to the candidate streaming channels. The first message carries an upgradable media detection payload, enabling the candidate streaming channel or the target device to return channel response information based on the first message.

[0086] The first message can be understood as a message used for media probing. Unlike sending a continuous media stream directly to the target device, the first message carries a scalable media probing payload. Its data size is relatively small and it can correspond to the candidate media transmission context. In this way, even if the first message is sent to multiple candidate streaming channels simultaneously or sequentially, it will not consume as much uplink resources as sending multiple continuous video streams in parallel.

[0087] In one example, the portable surveillance camera can send a first message to a first candidate streaming channel based on a first candidate media transmission context, and a first message to a second candidate streaming channel based on a second candidate media transmission context. The two candidate streaming channels can correspond to different access points or different transmission conditions. The portable surveillance camera can determine which candidate streaming channel is more suitable for establishing the target media session based on the subsequent returned channel response information.

[0088] S106. Determine the target propulsion channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate propulsion channel; After receiving the first message, candidate streaming channels can return channel response information. This channel response information characterizes the candidate streaming channel's handling of the first message or the upgradable media detection payload. The portable sphere can determine the target streaming channel based on the channel response information returned by one or more candidate streaming channels.

[0089] The target streaming channel is the channel subsequently used to send the second media frame and establish the target media session. The scalable media probe payload corresponding to the target streaming channel is called the target scalable media probe payload. This target scalable media probe payload can be a scalable media probe payload sent through the target streaming channel, or it can be a scalable media probe payload associated with the candidate media transport context corresponding to the target streaming channel.

[0090] In one specific implementation, multiple candidate streaming channels all return channel response information. The portable PTZ camera can determine one of the candidate streaming channels as the target streaming channel based on factors such as channel reachability, response timeliness, and whether the target device can identify the payload. This selection process allows the portable PTZ camera to determine the streaming path using the actual response of the candidate channels before establishing a continuous video stream.

[0091] See Figure 4 This application provides a specific implementation of step S106, which is described in detail below. This embodiment includes: S1061, Receive the second message returned by the candidate push channel; In this embodiment, after the portable surveillance sphere sends a first message to the candidate streaming channel, the candidate streaming channel or the target device corresponding to the candidate streaming channel can return a second message based on the first message. The second message can be understood as a response message returned by the candidate streaming channel in response to the first message, which is used to characterize the candidate streaming channel's reception and processing of the first message or the upgradable media detection payload carried in the first message.

[0092] The portable surveillance sphere can receive second messages from one or more candidate streaming channels within a preset waiting time. Second messages from different candidate streaming channels may arrive sequentially, or some candidate streaming channels may not return second messages. The portable surveillance sphere can temporarily store the received second messages in a response buffer for subsequent parsing and matching.

[0093] In a specific example, after the portable surveillance sphere sends a first message to multiple candidate streaming channels based on multiple candidate media transmission contexts, it can receive a second message from one or more of these candidate streaming channels. Each second message can carry information to identify its corresponding candidate streaming channel or candidate media session, thereby facilitating the portable surveillance sphere to determine which first message the second message is a response to.

[0094] S1062. Parse the candidate channel identifier and candidate media session identifier from the second message; In this step, after receiving the second message, the portable surveillance camera can parse the second message to obtain the candidate channel identifier and the candidate media session identifier. The candidate channel identifier can be used to identify the candidate streaming channel that returned the second message, and the candidate media session identifier can be used to identify the candidate media session corresponding to that candidate streaming channel.

[0095] Candidate channel identifiers and candidate media session identifiers can be carried by the candidate streaming channel or the target device when returning the second message, or they can be generated and returned based on the relevant identifiers in the first message. By parsing the candidate channel identifiers and candidate media session identifiers, the portable surveillance PTZ can distinguish the responses of different candidate streaming channels, avoiding response confusion when multiple candidate streaming channels return the second message simultaneously or sequentially.

[0096] In one example, the first message carries a candidate channel identifier and a candidate media session identifier. When a candidate streaming channel returns a second message, it can carry the same or a corresponding candidate channel identifier and candidate media session identifier. The portable surveillance camera can determine which candidate media transmission context the second message corresponds to by parsing these identifiers.

[0097] S1063. Match the second message with the corresponding first message according to the candidate channel identifier and / or the candidate media session identifier; In this embodiment, the portable surveillance sphere can search for the first message corresponding to the second message in the sent first message record based on the candidate channel identifier and / or candidate media session identifier in the second message. The sent first message record may include the sending time of the first message, the candidate streaming channel, the candidate media transmission context, the candidate channel identifier, the candidate media session identifier, and the correlation between the scalable media detection payload carried by the first message.

[0098] When the candidate channel identifier in the second message matches the candidate channel identifier corresponding to a sent first message, and / or the candidate media session identifier in the second message matches the candidate media session identifier corresponding to a sent first message, it can be determined that the second message matches the first message. Through this matching relationship, the portable surveillance sphere can determine which candidate push channel and which upgradable media detection payload the second message is responding to.

[0099] In one example, a portable surveillance camera sends two first messages through a first candidate streaming channel and a second candidate streaming channel, respectively. If the received second message carries a first candidate channel identifier, it can be matched with the first message sent through the first candidate streaming channel. If the second message also carries a candidate media session identifier, the candidate media session corresponding to the second message can be further confirmed, reducing the possibility of mismatched responses.

[0100] S1064. Determine the target propulsion channel and the corresponding target upgradable media detection payload based on the matching results.

[0101] In this embodiment, after obtaining the matching result between the second message and the first message, the portable surveillance sphere can determine the target streaming channel and the corresponding target upgradable media detection payload based on the matching result. Specifically, when a certain second message is determined to match a certain first message, the candidate streaming channel corresponding to the first message can be used as an optional target streaming channel, and the upgradable media detection payload carried by the first message can be used as an optional target upgradable media detection payload.

[0102] If a portable surveillance sphere receives multiple second messages, and each of these second messages matches a different first message, the portable surveillance sphere can determine a target match from these matches based on preset selection rules. These preset selection rules can be related to the validity of the response, the order in which responses arrive, the channel availability status, or the media detection results. Based on the target match result, the target streaming channel and the target upgradable media detection payload can be determined.

[0103] In a specific example, the portable surveillance sphere receives second messages from two candidate streaming channels. One of these second messages matches the first message corresponding to the first candidate streaming channel, and the other matches the first message corresponding to the second candidate streaming channel. Based on these two matching results, the portable surveillance sphere can determine one of the candidate streaming channels as the target streaming channel and identify the upgradable media detection payload sent through that target streaming channel as the target upgradable media detection payload.

[0104] In this embodiment, the portable surveillance sphere can use the candidate channel identifier and candidate media session identifier in the second message to associate the response returned by the candidate streaming channel with the previously sent first message, thereby determining the scalable media detection payload corresponding to the response. This avoids the problem of unclear response sources or ambiguous payload correspondence in multi-candidate streaming channel detection scenarios, and provides a basis for subsequently converting the target scalable media detection payload from the detection state to the initiation state.

[0105] To better understand the embodiments of this application, the following examples are provided: In a specific example, after entering the deployment state, the portable surveillance sphere generates three candidate media transmission contexts based on the status information and access information, corresponding to candidate streaming channels CH1, CH2, and CH3, respectively. The portable surveillance sphere assigns candidate channel identifiers CID1, CID2, and CID3 to the three candidate streaming channels, and also assigns candidate media session identifiers SID1, SID2, and SID3, respectively.

[0106] The portable surveillance sphere generates an upgradable media detection payload based on the same first media frame and sends first messages M1-1, M1-2, and M1-3 based on three candidate media transmission contexts, respectively. First message M1-1 carries a candidate channel identifier (CID1) and a candidate media session identifier (SID1); first message M1-2 carries a candidate channel identifier (CID2) and a candidate media session identifier (SID2); and first message M1-3 carries a candidate channel identifier (CID3) and a candidate media session identifier (SID3). Each first message also carries an upgradable media detection payload associated with the corresponding candidate streaming channel.

[0107] Within a preset waiting time, the portable surveillance camera receives the second message M2-2 from candidate streaming channel CH2 and the second message M2-1 from candidate streaming channel CH1, but does not receive the second message from candidate streaming channel CH3. The portable surveillance camera parses the second message M2-2 to obtain the candidate channel identifier CID2 and the candidate media session identifier SID2; it parses the second message M2-1 to obtain the candidate channel identifier CID1 and the candidate media session identifier SID1.

[0108] The portable surveillance camera matches the second message M2-2 with the first message M1-2 based on the candidate channel identifier CID2 and the candidate media session identifier SID2; and matches the second message M2-1 with the first message M1-1 based on the candidate channel identifier CID1 and the candidate media session identifier SID1. Since no second message is received from the candidate streaming channel CH3, the portable surveillance camera may not consider the candidate streaming channel CH3 as a candidate for the current target streaming channel, or it may mark the candidate streaming channel CH3 as having a response timeout.

[0109] Furthermore, the portable control sphere can determine the target propulsion channel based on the matching results. For example, when the reception time of the second message M2-2 is earlier than that of the second message M2-1, and the second message M2-2 indicates that the candidate propulsion channel CH2 can receive the upgradable media detection payload in the first message, the portable control sphere can determine the candidate propulsion channel CH2 as the target propulsion channel and determine the upgradable media detection payload carried in the first message M1-2 as the target upgradable media detection payload. Subsequently, the portable control sphere can perform a transition from the detection state to the propulsion state based on the target upgradable media detection payload.

[0110] In another specific example, if both the second message M2-1 and the second message M2-2 are successfully matched, but the candidate streaming channel CH1 corresponding to the second message M2-1 indicates an abnormal media processing result, while the candidate streaming channel CH2 corresponding to the second message M2-2 indicates a normal media processing result, then the portable monitoring sphere can determine the candidate streaming channel CH2 as the target streaming channel. Therefore, even if multiple candidate streaming channels return the second message, the portable monitoring sphere can determine the target upgradable media detection payload corresponding to the target streaming channel based on the correspondence between the second message and the first message, thus avoiding the use of incorrect media detection payloads during subsequent streaming.

[0111] S107. Based on the target upgradable media detection payload, the target media session is converted from the detection state to the streaming state, so that the first media frame is the first displayable media frame of the target media session; In this step, after identifying the target propulsion channel and the target upgradable media detection payload, the portable control sphere can switch it from a detection state to a flow initiation state based on the target upgradable media detection payload. The detection state indicates that the target upgradable media detection payload is mainly used for candidate propulsion channel detection; the flow initiation state indicates that the target upgradable media detection payload is used for the initial stage of the target media session.

[0112] During this conversion process, the first media frame in the target upgradable media detection payload is used as the first displayable media frame of the target media session. In other words, the first media frame is not a newly generated first frame after channel selection is completed, but is already transmitted through the upgradable media detection payload during the channel detection phase and is assigned to the purpose of starting streaming after the target streaming channel is determined.

[0113] By transitioning the target upgradable media detection payload from the detection state to the flow-in state, the target device can obtain the first displayable scene in the target media session more quickly. This process establishes a continuous relationship between the detection phase and the flow-in phase, reducing the gap time between the two.

[0114] S108. Generate a second media frame, make the timestamp of the second media frame continue the target upgradable media detection payload, and send the second media frame through the target push channel.

[0115] After the target upgradable media detection payload enters the flow state, the portable deployment sphere continues to generate a second media frame. The second media frame can be a media frame generated after the first media frame, or it can be a subsequent media frame used in the target media session to continue forming a continuous video stream.

[0116] The portable surveillance PTZ allows the timestamp of the second media frame to be consecutively received by the target media detection payload. This continuation relationship enables the target device to identify that the second media frame and the first media frame belong to the same target media session, and that the second media frame follows the first media frame in the media playback sequence. Based on the transmission method, after displaying the first live image based on the first media frame, the target device can continue to receive and process the second media frame.

[0117] The portable surveillance sphere sends a second media frame through the target streaming channel, enabling the target media session to transition from the first displayable media frame to the subsequent media frame transmission stage. Through this step, the portable surveillance sphere completes the seamless process from deployment triggering, candidate channel detection, target channel determination, detection payload upgrade, to the establishment of a continuous video stream.

[0118] In some possible embodiments, after the portable surveillance sphere sends a first message to the candidate streaming channel based on multiple candidate media transmission contexts, the network state of the candidate streaming channel may change. For example, when the portable surveillance sphere is deployed at a road maintenance site, bridge repair site, or accident emergency site, the cellular network signal may be affected by vehicle obstruction, base station switching, equipment position adjustment, or antenna attitude changes. To avoid waiting for a response when the candidate streaming channel is no longer suitable for continued detection, this embodiment further updates or reconstructs the candidate media transmission context based on the network measurement information obtained after sending the first message and before determining the target streaming channel.

[0119] Based on the aforementioned embodiments of steps S1021 to S1024, this application further provides another embodiment of a method for rapidly establishing video streaming using a portable PTZ camera. This embodiment is described in detail below. (See attached document for details.) Figure 5 This embodiment includes: S201. Obtain a deployment trigger indication, wherein the deployment trigger indication is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state; S202. In response to the deployment trigger indication, generate multiple candidate media transmission contexts based on status information and access information; S203. A first media frame is generated by a portable surveillance ball. The first media frame is a media frame that can be independently decoded by the target device, and the data volume of the first media frame is less than the data volume of the media frame generated by the portable surveillance ball. S204. Generate an upgradable media detection payload based on the first media frame; S205. Based on the multiple candidate media transmission contexts, send a first message carrying the upgradable media detection payload to the candidate streaming channel; S206. Obtain second status information, the second status information including network measurement information obtained after sending the first message; In this embodiment, after sending the first message to the candidate streaming channel, the portable monitoring ball can continue to acquire second status information. The second status information can be status information remeasured after the first message was sent, and it includes at least network measurement information. This network measurement information can be used to reflect the communication status of the candidate streaming channel after the first message was sent.

[0120] Network measurement information may include at least one of the following: wireless signal strength, uplink bandwidth, network latency, packet loss rate, network standard, network cell identifier, connection hold status, or link quality indication. This network measurement information can be actively measured by the wireless communication unit of the portable surveillance sphere, or it can be obtained based on link feedback after the first message is sent, network interface status, or transport layer statistics.

[0121] S207. Determine whether the candidate push channel meets the conditions for continued detection based on the network measurement information; In this step, network measurement information can be used to determine whether the candidate streaming channel meets the conditions for continued probing. The conditions for continued probing can be used to characterize whether the candidate streaming channel still has the value of waiting for a second message or continuing media probing.

[0122] In some possible embodiments, the conditions for continued probing may be related to network signal strength, uplink bandwidth, network latency, packet loss rate, or connection hold-up status. For example, when the network signal strength is higher than a preset signal threshold, the uplink bandwidth is higher than a preset bandwidth threshold, the network latency is lower than a preset latency threshold, or the candidate streaming channel remains connected, it can be determined that the candidate streaming channel meets the conditions for continued probing. Conversely, if network measurements indicate that the communication quality of the candidate streaming channel is lower than the conditions required for continued probing, it can be determined that the candidate streaming channel does not meet the conditions for continued probing.

[0123] In one example, the portable surveillance camera has sent the first message to candidate push channel CH1. If the uplink latency of the network corresponding to CH1 is still within an acceptable range after the first message is sent, and the link is not broken, then CH1 can be determined to meet the conditions for continued probing. If continuous packet loss or connection interruption is detected in the network corresponding to CH1, then CH1 can be determined to not meet the conditions for continued probing.

[0124] S208. If the conditions for continued detection are met, the corresponding candidate media transmission context is kept in the detection waiting state. In this embodiment, if a candidate streaming channel meets the conditions for continued probing, the portable surveillance sphere can maintain the corresponding candidate media transmission context in a probing waiting state. The probing waiting state indicates that the portable surveillance sphere has already sent a first message to the candidate streaming channel, but is still allowed to receive a second message returned by the candidate streaming channel within a preset waiting time.

[0125] In this state, the portable surveillance PTZ camera does not need to regenerate the candidate media transmission context, nor does it need to immediately resend the first message. Instead, it continues to listen for the channel response information returned by the candidate push channel. This avoids unnecessary context reconstruction and message retransmission while the link is still available.

[0126] In the aforementioned example, after the portable surveillance ball sends the first message to the candidate push channel CH1, if it detects that the signal strength and latency of the network corresponding to CH1 still meet the conditions for continued detection, it can keep the candidate media transmission context CTX1 corresponding to CH1 in the detection waiting state and continue to wait for CH1 to return the second message.

[0127] S209. If the conditions for continued detection are not met, the candidate media transmission context is regenerated based on the updated second state information. In this embodiment, if the candidate streaming channel does not meet the conditions for continued probing, the portable surveillance sphere can regenerate the candidate media transmission context based on the updated second state information. The regenerated candidate media transmission context may differ from the candidate media transmission context generated before the first message was sent, and it can adjust the candidate streaming channel, transmission endpoint, session identifier, protocol parameters, or channel priority according to the new network measurement information.

[0128] In the aforementioned example, the first candidate media transmission context CTX1 originally corresponded to cellular network bearer A and platform entry point P1. If the second state information indicates that the uplink quality of cellular network bearer A has deteriorated and is no longer suitable for continued probing, the portable surveillance sphere can regenerate the candidate media transmission context CTX1′ based on the second state information. CTX1′ can correspond to another available communication bearer, another platform entry point, or updated session parameters.

[0129] S210. Resend the first message carrying the upgradable media detection payload based on the regenerated candidate media transmission context.

[0130] In this embodiment, the portable surveillance sphere can retransmit the first message based on the regenerated candidate media transmission context. The retransmitted first message can still carry an upgradable media detection payload. This upgradable media detection payload can be the originally generated upgradable media detection payload, or it can be a regenerated or updated upgradable media detection payload based on the current state.

[0131] In a specific example, after the portable surveillance sphere sends the first message to the candidate streaming channel CH1, it detects that CH1 does not meet the conditions for continuing probing. Therefore, it generates a new candidate media transmission context CTX2 based on the second state information. Subsequently, the portable surveillance sphere determines a new candidate streaming channel CH2 based on CTX2 and resends the first message carrying the upgradable media probing payload to CH2. In this way, even if the original candidate streaming channel deteriorates during probing, the portable surveillance sphere can still continue media probing based on the updated network state.

[0132] This embodiment can dynamically determine whether a candidate streaming channel is still suitable for continued probing based on real-time network measurement information after the first message is sent and before the target streaming channel is determined. When the candidate streaming channel still meets the conditions for continued probing, its probing waiting state is maintained; when the candidate streaming channel does not meet the conditions for continued probing, the candidate media transmission context is reconstructed in a timely manner and the first message is resent. In this way, invalid waiting on unavailable or low-quality candidate streaming channels can be reduced, thereby improving the efficiency of subsequent determination of the target streaming channel.

[0133] S211 determines the target propulsion channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate propulsion channel; S212 converts the target media session from the probe state to the streaming state according to the target upgradable media detection payload, so that the first media frame is the first displayable media frame of the target media session; S213 generates a second media frame, makes the timestamp of the second media frame continue the target upgradable media detection payload, and sends the second media frame through the target push channel.

[0134] The foregoing embodiments have described in detail the embodiments of the method provided in this application. The embodiments of the apparatus provided in this application will be described in detail below.

[0135] See Figure 8 This application provides an embodiment of a portable video streaming rapid setup device for a PTZ camera, the embodiment comprising: The first acquisition unit 801 is used to acquire a deployment trigger indication, wherein the deployment trigger indication is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state. Context generation unit 802 is used to generate multiple candidate media transmission contexts based on status information and access information in response to the deployment trigger indication; The first frame generation unit 803 is used to generate a first media frame through a portable control ball. The first media frame is a media frame that can be independently decoded by the target device, and the data volume of the first media frame is less than the data volume of the media frame generated by the portable control ball. The payload generation unit 804 is used to generate an upgradable media detection payload based on the first media frame. The first sending unit 805 is used to send a first message carrying the upgradable media detection payload to the candidate streaming channel based on the plurality of candidate media transmission contexts. The determination unit 806 is used to determine the target propulsion channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate propulsion channel; The state transition unit 807 is used to transition the target media session from the probe state to the streaming state according to the target upgradable media probe payload, so that the first media frame is the first displayable media frame of the target media session; The second frame generation unit 808 is used to generate a second media frame, such that the timestamp of the second media frame is continuous with the target upgradable media detection payload, and the second media frame is sent through the target streaming channel.

[0136] Optionally, the specific unit 806 is used for: Receive the second message returned by the candidate push stream channel; Parse the candidate channel identifier and candidate media session identifier from the second message; Based on the candidate channel identifier and / or the candidate media session identifier, the second message is matched with the corresponding first message; The target propulsion channel and the corresponding target upgradable media detection payload are determined based on the matching results.

[0137] Optionally, the context generation unit 802 is specifically used for: In response to the deployment trigger indication, first status information and first access information are obtained; Multiple candidate media transmission contexts are generated based on the first status information and the first access information; Obtain the second state information; Update at least one candidate media transmission context based on the second state information.

[0138] Optionally, it also includes a re-determination unit 809, specifically used for: Obtain second status information, which includes network measurement information obtained after sending the first message. Based on the network measurement information, determine whether the candidate push channel meets the conditions for continued detection; If the conditions for continued probing are met, the corresponding candidate media transmission context remains in the probing waiting state. If the conditions for continued detection are not met, the candidate media transmission context is regenerated based on the updated second state information; The first message carrying the upgradable media detection payload is retransmitted based on the regenerated candidate media transmission context.

[0139] Optionally, the first frame generation unit 803 is used for: The first encoding parameter is determined based on the state information; Based on the first encoding parameters, the current image frame or cached image frame acquired by the portable surveillance ball is encoded to generate the first media frame.

[0140] Optionally, the context generation unit 802 is specifically used for: The communication bearer set is determined based on the status information, and the platform access set is determined based on the access information; Based on the mapping relationship between the communication bearer set and the platform access set, multiple candidate push channels are generated; Configure candidate channel identifiers and candidate media session identifiers for the multiple candidate push channels respectively; Construct candidate media transmission contexts based on the candidate channel identifier and candidate media session identifier corresponding to the same candidate push channel.

[0141] Optionally, the candidate media transmission context includes at least one of the following: candidate channel identifier, candidate media session identifier, transmission endpoint parameters, protocol stack parameters, authentication parameters, media encapsulation parameters, and communication bearer identifier.

[0142] Optionally, the portable surveillance PTZ includes a housing, a folding support structure, and a camera PTZ. The housing has a receiving cavity and an opening communicating with the receiving cavity. The folding support structure includes a fixed base, a telescopic rod assembly and a PTZ camera mounting base. The fixed base is disposed in the receiving cavity. One end of the telescopic rod assembly is connected to the fixed base and the other end is connected to the PTZ camera mounting base. The PTZ camera is mounted on the PTZ camera mounting base. The telescopic rod assembly has a retracted state where it is housed within the accommodating cavity and an extended state where it extends out of the accommodating cavity.

[0143] Please see Figure 9 This application also provides a portable video streaming rapid setup device for a PTZ camera, comprising: Processor 901, memory 902, input / output unit 903, bus 904; The processor 901 is connected to the memory 902, the input / output unit 903, and the bus 904; The memory 902 stores a program, and the processor 901 calls the program to execute any of the methods described above.

[0144] This application also relates to a computer-readable storage medium on which a program is stored, which, when run on a computer, causes the computer to perform any of the methods described above.

[0145] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0146] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.

[0147] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0148] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0149] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

Claims

1. A method for rapidly establishing video streaming using a portable PTZ camera, characterized in that, Applied to portable surveillance cameras, the method includes: Obtain a deployment trigger indication, which is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state; In response to the deployment trigger indication, multiple candidate media transmission contexts are generated based on status information and access information; A first media frame is generated by a portable surveillance ball. The first media frame is a media frame that can be independently decoded by the target device, and the data size of the first media frame is smaller than the data size of the media frame generated by the portable surveillance ball. Generate an upgradable media detection payload based on the first media frame; Based on the multiple candidate media transmission contexts, a first message carrying the upgradable media detection payload is sent to the candidate streaming channel; The target propulsion channel and the corresponding target upgradable media detection payload are determined based on the channel response information returned by the candidate propulsion channels. The target media session is switched from the probe state to the streaming state according to the target upgradable media detection payload, so that the first media frame is the first displayable media frame of the target media session; A second media frame is generated, with its timestamp continuing from that of the target upgradable media detection payload, and then transmitted through the target streaming channel.

2. The method for rapid video streaming establishment using a portable PTZ camera according to claim 1, characterized in that, The step of determining the target propulsion channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate propulsion channels includes: Receive the second message returned by the candidate push stream channel; Parse the candidate channel identifier and candidate media session identifier from the second message; Based on the candidate channel identifier and / or the candidate media session identifier, the second message is matched with the corresponding first message; The target propulsion channel and the corresponding target upgradable media detection payload are determined based on the matching results.

3. The method for rapid video streaming establishment using a portable PTZ camera according to claim 1, characterized in that, In response to the deployment trigger indication, multiple candidate media transmission contexts are generated based on status information and access information, including: In response to the deployment trigger indication, first status information and first access information are obtained; Multiple candidate media transmission contexts are generated based on the first status information and the first access information; Obtain the second state information; Update at least one candidate media transmission context based on the second state information.

4. The method for rapid video streaming establishment using a portable PTZ camera according to claim 3, characterized in that, After sending a first message carrying the upgradable media detection payload to the candidate streaming channel, and before determining the target streaming channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate streaming channel, the method further includes: Obtain second status information, which includes network measurement information obtained after sending the first message. Based on the network measurement information, determine whether the candidate push channel meets the conditions for continued detection; If the conditions for continued probing are met, the corresponding candidate media transmission context remains in the probing waiting state. If the conditions for continued detection are not met, the candidate media transmission context is regenerated based on the updated second state information; The first message carrying the upgradable media detection payload is retransmitted based on the regenerated candidate media transmission context.

5. The method for rapid video streaming establishment using a portable PTZ camera according to claim 1, characterized in that, The step of generating a first media frame via a portable surveillance sphere, wherein the first media frame is a media frame that can be independently decoded by the target device, and the data size of the first media frame is less than the data size of the media frame generated by the portable surveillance sphere, includes: The first encoding parameter is determined based on the state information; Based on the first encoding parameters, the current image frame or cached image frame acquired by the portable surveillance ball is encoded to generate the first media frame.

6. The method for rapid video streaming establishment using a portable PTZ camera according to claim 1, characterized in that, The generation of multiple candidate media transmission contexts based on status information and access information includes: The communication bearer set is determined based on the status information, and the platform access set is determined based on the access information; Based on the mapping relationship between the communication bearer set and the platform access set, multiple candidate push channels are generated; Configure candidate channel identifiers and candidate media session identifiers for the multiple candidate push stream channels respectively; Construct candidate media transmission contexts based on the candidate channel identifier and candidate media session identifier corresponding to the same candidate push channel.

7. The method for rapid video streaming establishment using a portable PTZ camera according to any one of claims 1 to 6, characterized in that, The candidate media transmission context includes at least one of the following: candidate channel identifier, candidate media session identifier, transmission endpoint parameters, protocol stack parameters, authentication parameters, media encapsulation parameters, and communication bearer identifier.

8. The method for rapid video streaming establishment using a portable PTZ camera according to any one of claims 1 to 6, characterized in that, The portable surveillance PTZ includes a housing, a folding support structure, and a camera PTZ. The housing has a receiving cavity and an opening communicating with the receiving cavity. The folding support structure includes a fixed base, a telescopic rod assembly and a PTZ camera mounting base. The fixed base is disposed in the receiving cavity. One end of the telescopic rod assembly is connected to the fixed base and the other end is connected to the PTZ camera mounting base. The PTZ camera is mounted on the PTZ camera mounting base. The telescopic rod assembly has a retracted state where it is housed within the accommodating cavity and an extended state where it extends out of the accommodating cavity.

9. A portable video streaming rapid setup device for a PTZ camera, characterized in that, For controlling a portable surveillance ball, the device includes: The first acquisition unit is used to acquire a deployment trigger indication, which is used to instruct the portable deployment ball to switch from a non-deployment state to a deployment state. A context generation unit is used to generate multiple candidate media transmission contexts based on status information and access information in response to the deployment trigger indication; The first frame generation unit is used to generate a first media frame through a portable control ball. The first media frame is a media frame that can be independently decoded by the target device, and the data volume of the first media frame is less than the data volume of the media frame generated by the portable control ball. A payload generation unit is used to generate an upgradable media detection payload based on the first media frame. The first sending unit is configured to send a first message carrying the upgradable media detection payload to the candidate streaming channel based on the plurality of candidate media transmission contexts. The determination unit is used to determine the target propulsion channel and the corresponding target upgradable media detection payload based on the channel response information returned by the candidate propulsion channels; A state transition unit is used to transition a target media session from a probe state to a streaming state based on the target upgradable media probe payload, so that the first media frame is the first displayable media frame of the target media session; The second frame generation unit is used to generate a second media frame, such that the timestamp of the second media frame is continuous with the target upgradable media detection payload, and the second media frame is sent through the target streaming channel.

10. A portable video streaming rapid setup device for a PTZ camera, characterized in that, The device includes: Processor, memory, input / output units, and bus; The processor is connected to the memory, the input / output unit, and the bus; The memory stores a program, which the processor invokes to perform the method as described in any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that, The computer-readable storage medium contains a program that, when executed on a computer, performs the method as described in any one of claims 1 to 8.