Video recorder and video processing method
By using the main control unit and image processing unit in the video recorder to adjust the status of the video output link, the processing of the target video channel is enabled, and the problem of poor video preview fluency in the prior art is solved, and more efficient task processing is achieved. Screen switching.
Patent Information
- Application Number
- CN202411138003.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-19
- Publication Date
- 2024-12-03
- Estimated Expiration
- 2044-08-19
AI Technical Summary
The existing video recorders have low task processing efficiency during video preview, which leads to insufficient smoothness of picture preview, especially when switching video channels, which requires the destruction and reconstruction of the video output link, which takes a long time and affects the user experience.
By introducing the main control unit, image processing unit and task execution unit into the video recorder, the status adjustment of the preset video output link is realized, so that the link state of the target video channel is adjusted from the default state to the enable state, avoiding video output Link establishment and destruction operations directly enable image processing and task execution units.
It improves task processing efficiency, reduces delays during video preview and switching, improves the smoothness and user experience of screen preview, and simplifies the video channel switching process.
Smart Images

Figure CN118678010B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of data processing, and in particular to a video recorder and a video processing method. Background Art
[0002] A video recorder usually has functions such as video preview and video encoding, that is, the video recorder can perform tasks such as video preview and video encoding. As for the preview function, the image data of at least one video channel connected to the video recorder can be previewed through the preview function. The data source of each video channel can be a network camera, an analog camera, or an image or video input through an input interface.
[0003] In the related art, taking the video preview task as an example, when previewing the screen for at least one video channel, a video output link of the at least one video channel is established, and the video output link of each video channel includes the various processing units required for previewing the image data of the video channel and the order relationship of the processing data of each processing unit; when the preview of the video channel is ended, the video output link is destroyed, and the destruction operation may include unbinding the video output link and destroying the resources generated when the video output link is enabled. Taking the network camera as an example, for the video channel with the network camera as the video source, the video output link is: video acquisition unit->image processing unit->video output unit, which represents that the image data of the network camera is processed by the video acquisition unit, image processing unit, and video output unit in sequence to perform screen preview.
[0004] However, since it takes a certain amount of time to establish and destroy the video output link, the task processing efficiency is low. After the user issues an instruction to preview the screen, it will not be able to respond quickly to output the screen, which ultimately leads to the problem of insufficient smoothness of the screen preview in the prior art; in particular, when a screen preview demand for certain video channels is generated through a screen switching operation, the video output links of the video channels originally displayed by the preview device need to be destroyed, and then the video output link of the video channel to be displayed currently needs to be established, which will cause the problem of poor smoothness of the screen preview to be particularly serious.
[0005] It can be seen that how to improve task processing efficiency in related technologies is an urgent problem to be solved. Summary of the invention
[0006] The purpose of the embodiment of the present application is to provide a video recorder and a video processing method to improve task processing efficiency. The specific technical solution is as follows:
[0007] In a first aspect, an embodiment of the present application provides a video recorder, comprising: a main control unit, an image processing unit, and a task execution unit;
[0008] The main control unit is used to perform a state adjustment process in response to satisfying a trigger condition for executing a target task for at least one target video channel; wherein the state adjustment process is a process for the state of a link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel of the video recorder with data access capability and a default state of the first state, and the state adjustment process is used to make the state of the preset video output link of each target video channel the second state, and other preset video output links the first state; for each preset video output link, the first state is used to indicate that the image processing unit and the task execution unit are not enabled for the video channel to which the preset video output link belongs, and the second state is used to indicate that the image processing unit and the task execution unit are enabled for the video channel to which the preset video output link belongs;
[0009] The image processing unit is used for, for each target video channel, in response to the state of the preset video output link of the target video channel being the second state, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel;
[0010] The task execution unit is used to obtain, for each target video channel, an image data processing result corresponding to the target video channel in response to the state of the preset video output link of the target video channel being the second state; and execute the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel.
[0011] In a second aspect, an embodiment of the present application provides a video processing method, which is applied to a video processing device, and the method includes:
[0012] In response to satisfying a trigger condition for executing a target task for at least one target video channel, a state adjustment process is performed; wherein the state adjustment process is a process for the state of a link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel of the video processing device with data access capability and having a first state by default, and the state adjustment process is used to make the state of the preset video output link of each target video channel a second state, and other preset video output links the first state; for each preset video output link, the first state is used to instruct the video processing unit to disable the video channel to which the preset video output link belongs, and the second state is used to instruct the video processing unit to enable the video channel to which the preset video output link belongs;
[0013] For each target video channel, in response to the state of the preset video output link of the target video channel being the second state, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel;
[0014] Obtaining the image data processing result corresponding to the target video channel; and executing the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel.
[0015] Beneficial effects of the embodiments of the present application:
[0016] The main control unit in the video recorder provided by the embodiment of the present application can respond to the trigger condition of performing the target task for at least one target video channel, perform state adjustment processing, so that the state of the preset video output link of each target video channel is the second state, the image processing unit in the video recorder can respond to the state of the preset video output link of any target video channel being the second state, perform image data processing on the image data of the target video channel, and the task execution unit in the video recorder can respond to the state of the preset video output link of any target video channel being the second state, obtain the image data processing result corresponding to the target video channel, and execute the processing action corresponding to the target task. It can be seen that when the embodiment of the present application performs the target task for the target video channel, there is no need to perform time-consuming operations on the video output link, but only needs to adjust the state for each preset video output link, so that the image processing unit and the video output unit can be enabled for each target video channel, and the target task can be performed for each target video channel. Therefore, the task processing efficiency can be improved through this solution.
[0017] Of course, implementing any product or method of the present application does not necessarily require achieving all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application, and for ordinary technicians in this field, other embodiments can also be obtained based on these drawings.
[0019] FIG. 1 (a) is a schematic diagram showing the principle of a video processing solution in the related art;
[0020] FIG1( b ) is a schematic diagram of a video switching effect in the related art;
[0021] Figure 2 A schematic diagram of the structure of a video recorder provided in an embodiment of the present application;
[0022] FIG3 (a) is a schematic diagram of the effect of a video channel provided in an embodiment of the present application;
[0023] FIG3 (b) is a schematic diagram of a video switching effect provided by an embodiment of the present application;
[0024] Figure 4 A schematic diagram of a screen preview effect provided in an embodiment of the present application;
[0025] Figure 5 A schematic diagram of another video switching effect provided in an embodiment of the present application;
[0026] Figure 6 A flowchart of a video processing method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0027] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field based on the present application belong to the scope of protection of the present application.
[0028] First, some professional terms in the embodiments of the present application are briefly introduced:
[0029] Video output unit: can be called VO (Video Output) or VO unit or video output module, which is used to actively read video / image data and output it to the preview device.
[0030] Video decoding unit: may be called VDEC (Video Decoder) or VDEC unit or video decoding module, used to decode the compressed video stream into raw data and store it into a specified memory, wherein the format of the video stream may be H.264 / H.265 / MJPEG.
[0031] Video capture unit: can be called VCAP (Video Capture) or VCAP unit or video capture module, which is used to collect the image data of the video channel into the specified memory through the corresponding interface, where the specific interface can transmit the data stream in BT.656 / BT.1120 / MIPI format.
[0032] Image processing unit: can be called VP (Video Process) or VP unit or image processing module, which is used to perform scaling, cropping, denoising, deinterlacing and other processing on image data.
[0033] IPC (IP CAMERA, network camera): It is composed of a network coding module and an analog camera. The captured image data is transmitted to the video decoding unit in the form of a compressed video stream.
[0034] Binding: The data receiver and the data source can establish a binding relationship. After binding, the data source can automatically send data to the data receiver.
[0035] BT.656: A video acquisition and processing standard that defines a digital video signal transmission method based on a parallel interface. This standard is applicable to video signals with standard resolution. ITU-R BT.656 defines a parallel hardware interface for transmitting a 4:2:2 YCbCr digital video stream. BT refers to Broadcasting Service television. The protocol specifies the digital interfaces for high-definition television studio signals (Digital interfaces for studio signals with 1920 × 1080 image formats), mainly from the supported video formats, digital signal encoding parameters, image timing, etc. In addition, BT656 defines a parallel hardware interface for transmitting a 4:2:2 YCbCr digital video stream. YCbCr is a color space, usually used for continuous image processing in movies or in digital photography systems. Y is luminance, while Cb and Cr are the concentration offset components of blue and red.
[0036] BT.1120: The full name of the BT1120 protocol is ITU-R BT.1120. ITU is the abbreviation of International Telecommunication Union. R is the abbreviation of Radiocommunications sector.
[0037] MIPI (Mobile Industry Processor Interface): is an open standard and specification for mobile application processors initiated by the MIPI Alliance. In addition, BT1120 can be a digital interface for HDTV (High Definition Television) studio signals, which can encode 4:4:4 and 4:4:2 video data into a video data stream with an embedded synchronization timing reference code.
[0038] YUV: "Y" represents brightness, "U" and "V" represent chromaticity, "U" is used to describe the color and saturation of the image, and "V" is used to specify the color of the pixel. YUV type image data has multiple formats. YUV data can also be called YUV image, for example: YUV420 format data, YUV422 format data, etc.
[0039] In order to better understand the present application, before introducing the solution provided by the embodiment of the present application, the video processing solution and the solution for switching the screen preview in the related art are introduced, as shown in Figure 1 (a) and Figure 1 (b):
[0040] FIG1 (a) is a schematic diagram of the principle of a video processing solution in the related art. The unit used for output can be a video output unit or a virtual output unit. The right side of the dotted line is the subsequent steps of the virtual output unit. Since the virtual output unit has no actual hardware, that is, the virtual output unit is a software module, it is impossible to directly output image data to the preview device. The main control unit can obtain YUV data from the virtual output unit and bind it to the video encoding unit / video preview unit to achieve encoding / preview.
[0041] The video output unit can directly output the image data to the preview device, so there is no need for the part on the right side of the dotted line. The following is an introduction to the screen preview process in the related art:
[0042] The video decoding unit can be bound with the image processing unit (not shown in the figure) and the video output unit to form a video output link, so that based on the video output link, the image data decoded by the video decoding unit can be sent to the video output unit; the video acquisition unit can be bound with the image processing unit (not shown in the figure) and the video output unit to form a video output link, so that based on the video output link, the image data acquired by the video acquisition unit can be sent to the video output unit; the YUV data can be sent by the main control unit, at this time, the formed video output link can be a binding link of the YUV data, the image processing unit (not shown in the figure) and the video output unit, so that when the user wants to preview the YUV data, the YUV data can be sent directly to the video output unit through the main control unit. In addition, after receiving multiple channels of image data, the video output unit can splice the multiple channels of image data to achieve the preview effect of the 5 views in Figure 1 (a).
[0043] FIG1 (b) is a schematic diagram of the effect of video switching in the related art. The scenario may be a case where switching is performed during the execution of a video preview task. In FIG1 (b), the view before switching on the left side is 4 views, and the view after switching on the right side is 5 views. Therefore, it can be considered that the view is switched from 4 views to 5 views. Among them, the 4 views are equally divided into 4 screens, and the video channels are A0, A1, D0 and D1 respectively. The video channels involved in the 5 views are A0, A1, D1, D2 and D3 respectively. Among them, A0 and A1 are analog channel 0 and analog channel 1 respectively, and D0 and D1 are digital channel 0 and digital channel 1 respectively. The digital channel can also be called an IPC channel; and Chn represents the output channel of the video output unit, and Chn0 represents the output channel 0 of the video output unit. The channel divided by the video output unit is used to output to the preview device. The image data of each output channel represents a channel of image data displayed on the preview device. Obviously, this is different from the video channel introduced above. In the four-view diagram, Chn0 is the output channel of the video output unit for A0, Chn1 is the output channel of the video output unit for A1, Chn2 is the output channel of the video output unit for D0, and Chn3 is the output channel of the video output unit for D1. In the five-view diagram, Chn0 is the output channel of the video output unit for A1, Chn1 is the output channel of the video output unit for A0, Chn2 is the output channel of the video output unit for D2, Chn3 is the output channel of the video output unit for D3, and Chn4 is the output channel of the video output unit for D1.
[0044] The specific switching steps are as follows:
[0045] Step 1: Stop enabling the video output links of all video channels in the 4 views in a serial manner. The video output links of A0 and A1 are video acquisition unit->image processing unit->video output unit, and the video output links of D0 and D1 are video decoding unit->image processing unit->video output unit. Destroy all the video output links of A0, A1, D0 and D1 in the 4 views, clear the preview interface of the preview device, and, if the IPC has no other output services, destroy the resources of the video decoding unit. It can be understood that the above process can be considered as an unbinding process.
[0046] Step 2: Create and set the attribute information of the image data of each video channel in the 5 views for the preview interface. The attribute information may be display position, output width and height, display priority, etc.
[0047] Step three, establish a binding relationship between the video channel and the video output link in the 5 views in a serial manner, wherein the process of establishing the video output link includes: respectively establishing the video output links of A0 and A1: video acquisition unit->image processing unit->video output unit, and then respectively establishing the video output links of D1-D3: video decoding unit->image processing unit->video output unit; and setting the output parameters of the image processing unit, the output parameters are parameters for scaling the image data; and then enabling the video output link established above. Exemplarily, the video output link of A0 is video acquisition unit->image processing unit->video output unit, and the image processing unit and the video output unit can identify the processing unit of the previous level based on the video output link of A0 to obtain the processing result of the processing unit of the previous level for the image data of A0, and then use the obtained processing result for subsequent processing.
[0048] In addition, if the resources required by the video decoding unit are not created, the resources required by the video decoding unit need to be created when the IPC is accessed, and the link binding is completed, and finally the video channel to which the video output link belongs is enabled.
[0049] It can be seen that the establishment and destruction of the video output link in the related technology will take a certain amount of time, the delay problem is more serious, and the task processing efficiency is low.
[0050] Based on the problems existing in the related technologies, an embodiment of the present application provides a video recorder to improve task processing efficiency.
[0051] The video recorder provided in the embodiment of the present application is introduced below.
[0052] The video recorder provided in the embodiment of the present application can be any electronic device capable of preview display, such as a DVR (Digital Video Recorder), an NVR (Network Video Recorder), etc. DVR is a computer system for image storage and processing, and has the function of long-term recording and control of images. NVR is mostly used in back-end products in the security industry. It can access multiple analog cameras and decode, display, record, store, and transmit the video stream signals transmitted by each analog camera.
[0053] The following is a brief introduction to the application scenarios of the video recorder in the embodiment of the present application:
[0054] The video recorder of the embodiment of the present application can be applied to various scenarios for image data. For example: scenarios with high requirements for the smoothness of the screen preview. For example, in the scenario of online teaching, the preview interface watched by all students only displays the teacher's screen. When the teacher interacts with the students online, student A applies for interaction. At this time, the preview interface of all students needs to display the screens of the teacher and student A at the same time. This scenario has high requirements for the smoothness of the screen preview. If the screen switching is not smooth enough, it will affect the user experience of teachers and students. Another example: the scenario of encoding and saving the image data of the video stream.
[0055] Of course, the embodiments of the present application are not limited to the above-mentioned scenarios, and the embodiments of the present application do not specifically limit the scenarios in which the video recorder is used. In addition, it should be noted that the "video recorder" mentioned in the present application does not only include devices with the narrow product name of "video recorder", but refers to video processing devices with video processing functions in a broad sense; it also includes new product forms generated with the development of technology and business.
[0056] It should be noted that the main control unit, image processing unit or task execution unit included in the video recorder described in the embodiment of the present application does not limit the video recorder to include these three hardware parts or these three hardware parts in physical form. The term "unit" and "module" in the embodiment of the present application can be a hardware part, a software program, or a software program and the necessary carrier for the operation of the software program. With the evolution of technology, the steps required to execute these "units" or "modules" or the functions undertaken (for example, a certain unit or a certain module is "used for" the steps described later) may use hardware, software, or a combination of hardware and software. As long as it is hardware, software, or a combination of hardware and software that can execute the steps required to be executed by the "unit", it can be considered as a "unit" or "module" in the embodiment of the present application.
[0057] The video recorder provided in the embodiment of the present application includes: a main control unit, an image processing unit and a video output unit;
[0058] The main control unit is used to perform a state adjustment process in response to satisfying a trigger condition for executing a target task for at least one target video channel; wherein the state adjustment process is a process for the state of a link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel of the video recorder with data access capability and a default state of the first state, and the state adjustment process is used to make the state of the preset video output link of each target video channel the second state, and other preset video output links the first state; for each preset video output link, the first state is used to indicate that the image processing unit and the task execution unit are not enabled for the video channel to which the preset video output link belongs, and the second state is used to indicate that the image processing unit and the task execution unit are enabled for the video channel to which the preset video output link belongs;
[0059] The image processing unit is used for, for each target video channel, in response to the state of the preset video output link of the target video channel being the second state, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel;
[0060] The task execution unit is used to obtain, for each target video channel, an image data processing result corresponding to the target video channel in response to the state of the preset video output link of the target video channel being the second state; and execute the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel.
[0061] It can be seen that when the embodiment of the present application performs screen preview for the target video channel, there is no need to perform time-consuming operations on the video output link. Instead, it is only necessary to adjust the status of each preset video output link to enable the image processing unit and the video output unit for each target video channel, thereby realizing the execution of the target task for each target video channel. Therefore, the task processing efficiency can be improved through this solution.
[0062] The video recorder provided in the embodiment of the present application will be described in detail below in conjunction with the accompanying drawings of the specification.
[0063] like Figure 2 As shown, the embodiment of the present application provides a video recorder, including: a main control unit 210, an image processing unit 220 and a task execution unit 230;
[0064] The main control unit 210 is used to perform a state adjustment process in response to satisfying a trigger condition for executing a target task for at least one target video channel; wherein the state adjustment process is a process for the state of a link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel of the video recorder with data access capability and a default state of the first state, and the state adjustment process is used to make the state of the preset video output link of each target video channel the second state, and other preset video output links the first state; for each preset video output link, the first state is used to indicate that the image processing unit and the task execution unit are not enabled for the video channel to which the preset video output link belongs, and the second state is used to indicate that the image processing unit and the task execution unit are enabled for the video channel to which the preset video output link belongs;
[0065] The image processing unit 220 is configured to, for each target video channel, perform image data processing on the image data of the target video channel in response to the state of the preset video output link of the target video channel being the second state, to obtain an image data processing result corresponding to the target video channel;
[0066] The task execution unit 230 is used to obtain, for each target video channel, an image data processing result corresponding to the target video channel in response to the state of the preset video output link of the target video channel being the second state; and execute the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel.
[0067] It should be emphasized that the main control unit 210 does not necessarily immediately perform the state adjustment process in response to satisfying the trigger condition for executing the target task for at least one target video channel. Before executing the state adjustment process, a certain delay is allowed, and this application does not make specific limitations on this.
[0068] It is understandable that the trigger condition for executing the target task for at least one target video channel responded by the main control unit 210 may be in response to an execution instruction for the target task for at least one target video channel, and the execution instruction may be generated by a task switching operation or by a predetermined task start operation. For the sake of clarity of the layout, the content about the trigger condition may be introduced in subsequent embodiments, and no further elaboration is given here. It is understandable that each video channel may actually be connected to a video source, and exemplarily, YUV data, a network camera, and an analog camera may all be used as video sources, wherein YUV data may be considered as an image data sent by the main control unit, and the embodiment of the present application does not specifically limit the video source; in addition, exemplarily, the target task may be a video preview task or a video encoding task, and the present application does not limit the specific task type of the target task.
[0069] It should be emphasized that the main control unit 210 can pre-establish various preset video output links. First, the main control unit 210 can estimate the video channels of the recorder with data access capabilities, and set the channel number of video channels of each channel type. The data of each video channel is the data of the video source corresponding to the video channel. For example, when the video source is YUV data, the data of the video channel is the YUV data sent by the main control unit 210. When the video source is an analog camera, the data of the video channel is the analog data collected by the analog camera; secondly, the main control unit 210 can create a preset video output link based on the video channel with data access capabilities. The preset video output links of video channels of different channel types are also different. Among them, the channel type may include: analog channel type, digital channel type or picture channel type, etc., and the embodiments of the present application do not make specific limitations on this. Exemplarily, the preset video output link of the video channel of analog channel type is video acquisition unit->image processing unit->video output unit, and the preset video output link of the video channel of digital channel type is video decoding unit->image processing unit->video output unit; finally, the main control unit 210 adjusts the status of each preset video output link created to the first state, that is, the default state, the first state can also be called a hidden state, that is, the main control unit 210 adjusts the status of each preview video output link created to a hidden state, in the first state, the image processing unit and the task execution unit are not enabled for the video channels to which each preset video output link belongs, that is, the image processing unit and the task execution unit do not work for the video channels to which each preset video output link belongs. Of course, the above-mentioned method of creating a preset video output link is only an exemplary introduction, and this application does not make specific limitations on this. In addition, it should be emphasized that, exemplarily, each preset video output link can be established during the initialization process of the video recorder. At this time, the video recorder may not have access to any data source, but it can pre-estimate each video channel of the video recorder with data access capability based on the types of various data sources that the video recorder can access and the number of accessible channels of each type of data source, thereby establishing a video output link corresponding to each video channel and obtaining each preset video output link; wherein each data source can correspond to a video channel with data access capability. Of course, in specific applications, each preset video output link can also be periodically rebuilt, and before each reconstruction, the resource content generated when each preset video link is enabled can be cleared.
[0070] It can be understood that, in response to satisfying the trigger condition for executing the target task for at least one target video channel, the main control unit 210 can adjust the state of the preset video output link of each target video channel to the second state, and the second state can also be called a non-hidden state, that is, the main control unit 210 adjusts the state of the preset video output link of each target video channel to the non-hidden state, and adjusts the state of other preset video output links in each preset video output link to the first state, then, the image processing unit and the task execution unit are only enabled for the video channel described in the preset video output link of the second state, so that the image processing unit and the task execution unit only work for the target video channel. Exemplarily, there are analog channel 0 and analog channel 1, digital channel 0 and digital channel 1, the main control unit adjusts the state of the preset video output link of analog channel 0 and digital channel 1 to the second state, and adjusts the state of the preset video output link of analog channel 1 and digital channel 0 to the first state, the image processing unit and the task execution unit are enabled for analog channel 0 and digital channel 1, and are not enabled for analog channel 1 and digital channel 0.
[0071] In one implementation, the implementation is a video preview scenario, the task execution unit is a video output unit, the main control unit 210 can send a first processing instruction for the target video channel to the image processing unit 220, wherein the first processing instruction carries size information of the image data for at least one target video channel displayed on the preview interface, and send a second processing instruction for the target video channel to the video output unit, wherein the second processing instruction carries position information of the image data for at least one target video channel displayed on the preview interface of the preview device, after the image processing unit 220 responds to the first processing instruction, it executes subsequent steps according to the above size information, and after the video output unit responds to the second processing instruction, it executes subsequent steps according to the above position information. This process can be considered as an interaction on instructions, and this application does not make specific limitations on this.
[0072] It can be understood that the image processing unit 220 can respond to the state of the preset video output link of the target video channel being in the second state. Based on the preset video output link of the target video channel, the image data of the target video channel can be read from the data storage space corresponding to the front-stage unit in the preset video output link, and image data processing can be performed on the image data of the target video channel. The front-stage unit can be a video decoding unit, a video acquisition unit, etc. The front-stage unit can respond to the creation of the preset video output link and enable the video channels belonging to each preset video output link. That is, the front-stage unit can continue to work on the video channels belonging to each preset video output link. Of course, it can also be disabled, and the present application does not make specific limitations on this. The content of the front-stage unit will be introduced in other embodiments and will not be repeated here. Among them, the image data processing may include scaling processing, noise reduction processing, etc., and the present application does not make specific limitations on this.
[0073] In one implementation, the main control unit 210 may send the size information of the image data of at least one target video channel displayed on the preview interface of the preview device to the image processing unit 220, and the image processing unit 220 may perform image data processing on the image data of the target video channel according to the size information, and obtain the image data after the image data processing, which may be used as the image data processing result corresponding to the target video channel. Exemplarily, the target video channel is analog channel 1, and the size information of analog channel 1 displayed on the preview device is 1920×1080. The image processing unit may perform scaling processing on the image data of analog channel 1 according to the size information, and the size information of the image data after scaling processing is also 1920×1080.
[0074] It is understandable that the task execution unit 230 can respond to the state of the preset video output link of the target video channel being in the second state, and based on the preset video output link of the target video channel, can directly obtain the image data processing result corresponding to the target video channel from the image processing unit 220, and execute the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel. It should be emphasized that when the target task is a video preview task, the task execution unit can be a video output unit, and when the target task is a video encoding task, the task execution unit can be a virtual output unit. For the sake of clarity, this part of the content can be introduced later, and no further elaboration is made here.
[0075] In one implementation, the implementation is a video preview scenario, the task execution unit is a video output unit, the main control unit 210 can send the position information of the preview interface of the preview device for displaying the image data of at least one target video channel to the video output unit, and the video output unit can output the image data processing results corresponding to each target video channel to the preview device according to the position information. Exemplarily, the position information is that the image data of analog channel 1 is located in the upper left corner of the preview interface, and the image data of digital channel 0 is located in the lower right corner of the preview interface. In addition, the target video channel can be one channel or multiple channels. When the target video channel is one channel, the video output unit can directly output the image data of the target video channel to the preview device. When the target video channel is multiple channels, the video output unit can first splice the image data of the multiple target video channels and then output them to the preview device.
[0076] It can be seen that when the embodiment of the present application executes the target task for the target video channel, there is no need to perform time-consuming operations on the video output link. Instead, it is only necessary to adjust the state of each preset video output link, so that the image processing unit and the video output unit can be enabled for each target video channel, thereby realizing the execution of the target task for each target video channel. Therefore, the task processing efficiency can be improved through this solution.
[0077] Optionally, in another embodiment of the present application, in response to satisfying a trigger condition for executing a target task for at least one target video channel, the main control unit performs a state adjustment process, including step A1:
[0078] Step A1, in response to an execution instruction of a target task for at least one target video channel generated by triggering a task switching operation, performing a state adjustment process based on the at least one target video channel and each historical video channel;
[0079] The historical video channels are video channels targeted by the tasks being executed by the video processing device before the target switching operation is issued.
[0080] It can be understood that in this case, there is currently a task being executed. If the user wants to switch the video channel of the task being executed, the task switching operation can be performed to generate an execution instruction for the target task for at least one target video channel. Then, the main control unit can respond to the execution instruction and process the status of the link in each preset video output link based on at least one target video channel and each historical video channel. The specific execution status adjustment process can be introduced in subsequent embodiments and will not be elaborated here.
[0081] In one implementation, the state adjustment process is performed based on the at least one target video channel and each historical video channel, including step A11:
[0082] Step A11, performing state adjustment processing based on the at least one target video channel and each historical video channel according to a predetermined adjustment strategy;
[0083] Wherein, the predetermined adjustment strategy includes a first adjustment strategy or a second adjustment strategy;
[0084] The first adjustment strategy includes: keeping the state of the preset video output link of the first type of channel unchanged, setting the state of the preset video output link of the second type of channel to the first state, and setting the state of the preset video output link of the third type of channel to the second state; wherein, the first type of channel is a channel in each of the historical video channels that is the same as any target video channel, the second type of channel is a channel in each of the historical video channels that is different from the at least one target video channel, and the third type of channel is a channel in the at least one target video channel other than the first type of channel; or,
[0085] The second adjustment strategy includes: setting the state of the preset video output link of each historical video channel in each preset video output link to a first state, and setting the state of the preset video output link of at least one target video channel in each preset video output link to a second state.
[0086] It is understandable that when performing the state adjustment process, a predetermined adjustment strategy may be followed, wherein the predetermined adjustment strategy may include a first adjustment strategy or a second adjustment strategy. When performing the state adjustment process, any one of the adjustment strategies may be selected.
[0087] It can be understood that, for the first adjustment strategy, the state of the preset video output link of the first category channel can be kept unchanged, that is, there is no need to adjust the state of the preset video output link of the channel in each historical video channel that is the same as any target video channel, then the state of the preset video output link of the first category channel is maintained in the second state; the state of the preset video output link of the second category channel can be set to the first state, that is, the state of the preset video output link of the channel in each historical video channel that is different from any target video channel is set to the first state; the state of the preset video output link of the third category channel can also be set to the second state, that is, the state of the preset video output link of other channels in at least one target video channel except the first category channel is set to the second state; the subsequent image processing unit and the task execution unit are not enabled for the video channel to which the preset video output link in the first state belongs, and are enabled for the video channel to which the preset video output link in the second state belongs.
[0088] It can be understood that, for the second adjustment strategy, the state of the preset video output link of the historical video channel is set to the first state, the image processing unit and the task execution unit are not enabled for the historical video channel, and it can also be considered that the state of the preset video output link of the historical video channel is set to a hidden state. Obviously, the image data of the historical video channel cannot be used to continue to perform the target task later; and the main control unit can also set the state of the preset video output link of at least one target video channel in each preset video output link to the second state, and the image processing unit and the task execution unit are enabled for at least one target video channel, which can also be considered to set the state of the preset video output link of at least one target video channel to a non-hidden state. Obviously, the image data of at least one target video channel can be used to perform the target task later. It should be emphasized that by adjusting the state of the preset video output link of each target video channel to the second state and setting the state of the preset video output link of each historical video channel to the first state, in the video preview scene, fast screen preview switching can be achieved, and the screen preview switching is smoother, and the user will not feel the switching process. Furthermore, in the process of executing the state adjustment processing, both the first adjustment strategy and the second adjustment strategy introduced above are feasible, and the embodiment of the present application does not make any specific limitation on this.
[0089] Exemplarily, the image data of analog channel 1 is currently being previewed on the preview device, and the main control unit receives a screen preview instruction for digital channel 0 and analog channel 0, sets the state of the preset video output link of analog channel 1 to the first state, and sets the state of the preset video output link of digital channel 0 and analog channel 0 to the second state, so as to display the image data of digital channel 0 and analog channel 0 on the preview device.
[0090] It can be seen that in the scenario of task switching, the present application does not need to destroy the video output links of each video channel before switching, nor does it need to establish the video output links of each target video channel to be switched to, but only performs state adjustment processing on each preset video output link, so that the preview video output link of each target video channel to be switched to is in the second state, and other video output links are in the first state, so that task switching can be quickly realized. It can be seen that for the task switching scenario, the present application does not need to perform complex destruction and reconstruction on the video output link, and the state of the preset video output link of the video channel can be adjusted, so when the task is switched, the efficiency of task switching can be improved. And, when the state adjustment processing is performed according to the first adjustment strategy, the state of the preset video output link of the first type of channel remains unchanged, which simplifies the switching process; and when the state adjustment processing is performed according to the second adjustment strategy, fast switching can be achieved, and the user will not feel the switching process.
[0091] In addition, for the screen preview switching scenario, the present application does not need to perform complicated destruction and reconstruction of the video output link, but only needs to adjust the status of the preset video output link of the video channel. Therefore, when the screen preview is switched, the smoothness of the screen switching can be improved, and the screen connection is smoother when the screen preview is switched, and the effect of imperceptible switching can be achieved.
[0092] Optionally, in another embodiment of the present application, in response to satisfying a trigger condition for executing a target task for at least one target video channel, the main control unit performs a state adjustment process, including step B1:
[0093] Step B1, in response to an execution instruction of a target task for at least one target video channel generated by triggering a predetermined task start operation, setting the state of a video output link of at least one target video channel among the preset video output links to a second state.
[0094] Among them, the task start operation can be a start operation for a video preview task, or it can be a start operation for other tasks, and this application does not make specific limitations on this.
[0095] It can be understood that, in this case, there is no target task being executed. If the user wants to execute the target task for at least one target video channel, the user can trigger a predetermined task start operation to generate an execution instruction for the target task for at least one target video channel. Then, the main control unit can set the state of the preset video output link of at least one target video channel among each preset video output link to the second state, and the image processing unit and the task execution unit can enable at least one target video channel. Obviously, the target task can be executed subsequently using the image data of at least one target video channel.
[0096] Exemplarily, the main control unit receives a picture preview instruction of analog channel 0, and sets the state of a preset video output link of analog channel 0 to the second state, so as to display the image data of analog channel 0 on the preview device.
[0097] In one implementation, the main control unit is further used to maintain the status of other video output links among the preset video output links, except the video output link of the at least one target video channel, as a default state in response to an execution instruction of a target task for at least one target video channel generated by triggering a predetermined task start operation.
[0098] It can be understood that, since the status of each preset video output link in the initial state is the default status, that is, the first status, then, in response to the execution instruction of the target task for at least one target video channel generated by triggering the predetermined task start operation, the main control unit can first set the status of the video output link of at least one target video channel in each preset video output link to the second status, and then keep the status of other video output links in each preset video output link except the video output link of at least one target video channel as the default status, so that the status of the video output link of at least one target video channel is the second status, and the status of the video output links of other video channels is the first status, and the image processing unit and the task execution unit can be enabled for at least one target video channel.
[0099] It can be seen that when the embodiment of the present application responds to the execution instruction of the target task generated by triggering a predetermined task start operation, the status of other video output links in each preset video output link except the video output link of at least one target video channel can be kept as the default state, and the image processing unit and the task execution unit can be enabled only for at least one target video channel, which can improve the task processing efficiency.
[0100] It can be seen that when the embodiment of the present application responds to the execution instruction of the target task generated by triggering a predetermined task start operation, there is no need to create a video link. It is only necessary to set the state of the preset video output link of at least one target video channel to the second state, so as to execute the target task for the target video channel and improve the task processing efficiency.
[0101] Optionally, in another embodiment of the present application, the target task may be a video encoding task, and the task execution unit may be a virtual output unit;
[0102] The task execution unit executes the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel, which may include step C1:
[0103] In step C1, the virtual output unit splices the image data processing results corresponding to each target video channel to obtain spliced image data, and sends the spliced image data to the video encoding unit so that the video encoding unit encodes the spliced image data.
[0104] It can be understood that when the target task is a video encoding task, the task execution unit can be a virtual output unit. The virtual output unit is different from the video output unit. As a software unit, the virtual output unit does not have the ability to directly output image data to a preset device, but the virtual output unit can splice the image data processing results corresponding to each target video channel to obtain the spliced image data, and send the spliced image data to the video encoding unit. The video encoding unit can subsequently encode the spliced image data to execute the video encoding task.
[0105] In addition, when the target task is a video encoding task, the virtual output unit can splice the image data processing results corresponding to each target video channel according to the interface layout mode of the image data of each target video channel. It can be understood that the interface layout mode can be configured by the user through the configuration interface, and the layout position of the image data of each target video channel can be known through the user's configuration; or, the interface layout mode can also be a layout mode pre-configured in the virtual output unit and matched with the number of channels. Different numbers of channels can have different layout modes, which is also reasonable.
[0106] Moreover, for the target task being a video encoding task, the image processing unit, for each target video channel, responds to the state of the preset video output link of the target video channel being in the second state, and when performing image data processing on the image data of the target video channel, the image data processing involved may include but is not limited to denoising, scaling and other processing, and the present application does not make any specific limitation on this.
[0107] It can be seen that the virtual output unit in the present embodiment can splice the image data processing results corresponding to each target video channel and send them to the video encoding unit. The video encoding unit can encode the received image data, thereby improving the processing efficiency of the video encoding task.
[0108] Optionally, in another embodiment of the present application, the target task is a video preview task, and the task execution unit is a video output unit;
[0109] The task execution unit executes the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel, which may include step D1:
[0110] Step D1: The video output unit outputs image data for preview display for each target video channel to a preview device based on the image data processing result corresponding to each target video channel.
[0111] It can be understood that when the target task is a video preview task, the task execution unit can be a video output unit, and the video output unit can directly output image data for pre-display to the preview device based on the image data processing results corresponding to each target video channel, so that the preview device can preview the image data.
[0112] It can be seen that when the embodiment of the present application performs screen preview for the target video channel, there is no need to perform time-consuming operations on the video output link. Instead, it is only necessary to adjust the status of each preset video output link to enable the image processing unit and the video output unit for each target video channel, thereby realizing screen preview for each target video channel. Therefore, this solution can improve the smoothness of screen preview; and, compared with the related art, the present application can adjust the status of each preset video output link to achieve fast switching, without switching the video output link, thereby reducing memory and hardware performance consumption.
[0113] Optionally, in another embodiment of the present application, when the target task is a video preview task, the image processing unit performs image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel, including steps E1-E2:
[0114] Step E1, obtaining a parameter value of a processing parameter for the image data of the target video channel; wherein the parameter value of the processing parameter is: a parameter value matching the picture preview indicated by the video preview task;
[0115] It can be understood that the parameter value of the processing parameter can be the size information of the image data of at least one target video channel displayed on the preview device. Of course, it is not limited to this. The parameter value of the processing parameter can also include: parameter values related to noise reduction processing. The embodiment of the present application does not specifically limit the parameter value of the processing parameter.
[0116] Furthermore, the video preview task may indicate a parameter value of a processing parameter, and the main control unit may send the parameter value of the processing parameter to the image processing unit after responding to a trigger condition for executing the video preview task.
[0117] Step E2, performing image data processing on the image data of the target video channel obtained by processing the previous-stage unit in the preset video output link of the target video channel according to the parameter value of the processing parameter to obtain a data processing result of the target video channel;
[0118] Wherein, for each preset video output link, the preceding unit of the image processing unit in the video output link enables the video channel to which the preset video output link belongs in response to the creation of the preset video output link;
[0119] It can be understood that the pre-stage unit is a pre-stage unit of the image processing unit in the preset video output link, the pre-stage unit in the preset video output link of the analog channel is a video acquisition unit, the pre-stage unit in the preset video output link of the digital channel is a video decoding unit, and the pre-stage unit in the preset video output link of the picture channel is a main control unit; then, the image processing unit can directly read the image data of the target video channel processed by the pre-stage unit from the storage space of the pre-stage unit, and then process the image data according to the parameter value of the processing parameter to obtain the data processing result of the target video channel. Among them, the storage space of the pre-stage unit is the space where the pre-stage unit stores the image data of the target video channel after processing. For example, the pre-stage unit is a video acquisition unit, and the video acquisition unit can collect image data from the target video channel and store the collected image data in the display memory, and the subsequent image processing unit can directly read the collected image data from the display memory.
[0120] Exemplarily, the target video channel is A1, and the parameter value of the processing parameter is that the size information of A1 displayed on the preview device is 1920×1080. The image processing unit can scale the image data of A1 according to the size information to obtain the data processing result of the target video channel.
[0121] Correspondingly, the video output unit outputs image data for preview display for each target video channel to the preview device based on the image data processing results corresponding to each target video channel, including steps F1-F2:
[0122] Step F1, obtaining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device; wherein the parameter value of the preview position parameter is: a parameter value matching the screen preview indicated by the video preview task;
[0123] It is understandable that the parameter value of the preview position parameter can be the position information of the image data of at least one target video channel displayed on the preview device, which can be in the form of a four-dimensional coordinate, with the upper left corner of the preview interface as the coordinate origin to establish a coordinate system, the first two digits of the four-dimensional coordinate represent the coordinates of the upper left corner of the image data of the video channel, and the last two digits of the four-dimensional coordinate represent the width and height of the image data of the video channel. Of course, other representation methods can also be used to represent the parameter value of the preview position parameter, and this application does not specifically limit this.
[0124] In order to better understand the content about four-dimensional coordinates, a brief introduction is given below with reference to the accompanying drawings, as shown in Figure 3 (a) and Figure 3 (b):
[0125] Figure 3 (a) shows 4 views. The width of the entire preview interface is 1920 and the height is 1080. Therefore, the parameter value of the preview position parameter of A0 is (0, 0, 960, 540), the parameter value of the preview position parameter of A1 is (960, 0, 960, 540), the parameter value of the preview position parameter of D0 is (0, 540, 960, 540), and the parameter value of the preview position parameter of D1 is (960, 540, 960, 540).
[0126] Furthermore, the video preview task may indicate a parameter value of a preview position parameter, and the main control unit may send the parameter value of the preview position parameter to the video output unit in response to a trigger condition for executing the video preview task.
[0127] FIG3 (b) shows the case where the 4 views in FIG3 (a) are switched to the 5 views. The width of the entire preview interface is 1920 and the height is 1080. The parameter value of the preview position parameter of A0 is adjusted from (0, 0, 960, 540) to (0, 0, 1920, 1080), and the parameter value of the preview position parameter of A1 is adjusted from (960, 0, 960, 540) to (1280, 0, 640, 360). The state of the video output link of D0 is adjusted to the first state. It is assumed that D0 is hidden and appears transparent in the view, but the video output link of D0 still exists. The parameter value of the preview position parameter of D1 is adjusted from (960, 540, 960, 540) to (1280, 360, 640, 360), the parameter value of the preview position parameter of D2 is updated from the default value to (1280, 720, 640, 360), and the parameter value of the preview position parameter of D3 is updated from the default value to (640, 720, 640, 360).
[0128] Step F2, generating image data for preview display for each target video channel according to the parameter value of the preview position parameter and based on the image data processing result corresponding to each target video channel, and outputting the image data for preview display to the preview device.
[0129] Among them, the number of channels of the target video channel can be one or more. When the target video channel is one, the preview position of the image data processing result corresponding to the target video channel can be determined by the parameter value of the preview position parameter, thereby directly generating image data for preview display, and outputting the image data for preview display to the preview device; when the number of channels of the target video channel is multiple, at this time, the video output unit needs to splice the image data processing results corresponding to multiple target video channels according to the parameter value of the preview position parameter, thereby generating image data for preview display, and then outputting the image data for preview display to the preview device.
[0130] Exemplarily, when the number of target video channels is 4, namely analog channel 0, analog channel 1, digital channel 0 and digital channel 1, the preview device displays 4 views, and the parameter value of the preview position parameter indicates that the image data of analog channel 0 is located in the upper left corner of the preview device, the image data of analog channel 1 is located in the upper right corner of the preview device, the image data of digital channel 0 is located in the lower left corner of the preview device, and the image data of digital channel 1 is located in the lower right corner of the preview device. The video output unit can splice the image data of the 4 target video channels, generate image data for preview display, and output it to the preview device to achieve 4-view preview.
[0131] It can be seen that the image processing unit of the embodiment of the present application can obtain the parameter value of the processing parameter, and perform image data processing on the image data according to the parameter value of the processing parameter to obtain image data of a size that meets the requirements of the screen preview instruction. The video output unit can obtain the parameter value of the preview position parameter, and generate image data for preview display according to the parameter value of the preview position parameter, and output it to the preview device, thereby meeting the requirements of the screen preview instruction for the preview position and satisfying the user's preview needs.
[0132] In one implementation, the main control unit is further used to determine parameter values of processing parameters of image data of each target video channel in response to satisfying a trigger condition for executing a target task for at least one target video channel, and to determine parameter values of processing parameters of each target video channel in a preview interface of the preview device;
[0133] Correspondingly, in step E1, the image processing unit obtains parameter values of processing parameters for the image data of the target video channel, including step E11:
[0134] Step E11, obtaining parameter values of processing parameters for the image data of the target video channel determined by the main control unit;
[0135] Correspondingly, in step F1, the video output unit obtains the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device, including step F11:
[0136] Step F11, obtaining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device determined by the main control unit.
[0137] It can be understood that the main control unit determines the parameter values of the processing parameters in steps E1-E2 and the parameter values of the preview position parameters in steps F1-F2 in response to satisfying the trigger condition for executing the target task for at least one target video channel. The parameter values of the processing parameters and the parameter values of the preview position parameters are both set by the user and are used to meet the preview requirements of the user.
[0138] It is understandable that the image processing unit can directly obtain the parameter value of the processing parameter determined by the main control unit. Similarly, the video output unit can also directly obtain the parameter value of the preview position parameter determined by the main control unit, so as to facilitate use in steps E2 and F2.
[0139] In addition, the parameter values of the preview position parameter and the processing parameter can be represented by the four-dimensional coordinates introduced above, where the first two digits of the four-dimensional coordinate represent the parameter value of the preview position parameter, and the last two digits represent the parameter value of the processing parameter.
[0140] It can be seen that the main control unit can determine the parameter values of the processing parameters and the parameter values of the processing parameters, and the image processing unit and the video output unit can process and output image data based on the parameter values, thereby meeting the user's preview needs.
[0141] In one implementation, the main control unit is further used to set a target parameter with a default parameter value for each video channel of the video recorder with data access capability, the target parameter of each video channel including a preview position parameter of the video channel;
[0142] The main control unit is further configured to update the parameter value of the preview position parameter included in the target parameter of each target video channel according to the determined parameter value after determining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device;
[0143] Correspondingly, in step F11, the video output unit obtains the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device determined by the main control unit, including step F111:
[0144] Step F111 , reading the parameter value of the preview position parameter included in the target parameter of each target video channel, and obtaining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
[0145] It is understandable that the main control unit can pre-set target parameters with default parameter values for each video channel. The target parameters of each video channel may include the preview position parameters of the video channel. Of course, there may be other parameters, for example, the size parameters of the video channel may be included, and this application does not specifically limit this. Exemplarily, the default parameter value of the video channel may be (0, 0, 704, 576), where the first two digits represent the preview position parameters of the video channel, which default to (0, 0), and the last two digits represent the default size of the image data of the video channel, which is 704×576.
[0146] It is understandable that after determining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device, the main control unit can update the default parameter value in the target parameter according to the determined parameter value, that is, update the parameter value of the preview position parameter included in the target parameter. Exemplarily, the default parameter value of a target video channel is (0, 0, 704, 576), and the parameter value determined by the main control unit is (1920, 540), then the parameter value of the preview position parameter included in the target parameter of the target video channel can be updated, and the updated parameter value is (1920, 540, 704, 576).
[0147] It is understandable that the parameter value of the preview position parameter included in the target parameter of each target video channel read by the video output unit can be directly used as the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
[0148] It can be seen that the embodiment of the present application can pre-set target parameters with default parameter values for each video channel, so that the parameter values of the preview position parameters included in the target parameters can be directly updated later. During the preview process, there is no need to create a video output link, thereby improving the smoothness of the screen preview.
[0149] Optionally, in another embodiment of the present application, the image processing unit is further configured to, for a preset auxiliary channel, in response to a state of a video output link of the preset auxiliary channel being in a second state, process image data of the preset auxiliary channel to obtain an image data processing result corresponding to the preset auxiliary channel;
[0150] The video output unit is further configured to obtain, for the preset auxiliary channel, an image data processing result corresponding to the preset auxiliary channel in response to the state of the video output link of the preset auxiliary channel being the second state;
[0151] The video output unit outputs image data for preview display for each target video channel to the preview device based on the image data processing result corresponding to each target video channel, including step G1:
[0152] Step G1, based on the image data processing results corresponding to each target video channel and the image data processing results corresponding to the preset auxiliary channel, according to the priority of each target video channel for display level and the priority of the preset auxiliary channel for display level, outputting the image data for preview display for each target video channel to the preview device;
[0153] Among them, the preset auxiliary channel is a preset channel for transmitting a predetermined background image and having a specified preview position parameter, the video output link of the preset auxiliary channel is a video output link pre-created by the main control unit for the preset auxiliary channel and maintained in the second state, and the specified preview position parameter is a position parameter used to make the predetermined background image full-screen in the preview interface of the preview device; the priority of the preset auxiliary channel for the display level in the preview interface is lower than the priority of each video channel of the recorder with data access capability.
[0154] Among them, the black frame channel introduced above is also one of the preset auxiliary channels. The image data of the preset auxiliary channel is a predetermined background image, and the predetermined background image generally covers the entire preview interface. Therefore, the specified preview position parameter of the image data of the preset auxiliary channel is used to make the predetermined background image full screen in the preview interface. Of course, the image data of the preset auxiliary channel is not limited to black frame images, but can also be other background images, such as white frame images, and this application does not make specific limitations on this.
[0155] It can be understood that the image processing unit can respond to the state of the video output link of the preset auxiliary channel being in the second state, and based on the video output link of the preset auxiliary channel, process the image data of the preset auxiliary channel, and obtain the image data processing result corresponding to the preset auxiliary channel. The process of the image processing unit processing the image data of the preset auxiliary channel is similar to the above-mentioned process of processing the image data of the target video channel, so it will not be elaborated here.
[0156] It can be understood that the video output unit can respond to the state of the video output link of the preset auxiliary channel being in the second state, and based on the video output link of the preset auxiliary channel, obtain the image data processing result corresponding to the preset auxiliary channel. This part of the content is similar to the video output unit obtaining the image data processing result corresponding to the target video channel introduced above, so it will not be elaborated here.
[0157] It can be understood that, since the predetermined background image is usually placed at the bottom layer of the preview interface, the priority of the preset auxiliary channel in the preview interface for the display level is lower than the priority of each video channel of the recorder with data access capability, that is, the image data processing results corresponding to each video channel can be overlaid on the image data processing results corresponding to the preset auxiliary channel. Under normal circumstances, the display priority of the predetermined background image is the lowest; and, the state of the video output link of the preset auxiliary channel is always maintained in the second state, then the image processing unit and the video output unit are continuously enabled for the preset auxiliary channel, so that the predetermined background image can be continuously displayed on the preview interface.
[0158] It should be emphasized that the image data processing results corresponding to each target video channel may not be able to fill the screen on the preview interface of the preview device. Since there is a predetermined background image on the preview interface, the image data processing results that cannot fill the screen can be directly output to the preview device, so that the predetermined background image is used as the screen background of the preview interface to perform screen preview for the image data processing results that cannot fill the screen. In addition, when the screen preview is switched, the image processing unit and the video output unit continue to enable the preset auxiliary channel. The priority of the predetermined background image is higher than the residual image data of the historical video channel, and the residual image data of the historical video channel can be overwritten, thereby achieving a clear screen effect without the need for additional clear screen operations and without screen flickering.
[0159] It should be emphasized that during the screen switching process, the main control unit can set the state of the preset video output link of each historical video channel to the first state, and set the state of the preset video output link of at least one target video channel to the second state. There may be a short switching time during this period. At this time, the preview screen of the preview device can display the image data with the lowest priority of the display level, usually a predetermined background image.
[0160] In another implementation, there is no predetermined background image in the preview screen. At this time, the preview screen can display the image data of the historical video channel remaining before the state of the preset video output link of the historical video channel is set to the second state. However, due to the high smoothness of the switching, the remaining image data of the historical video channel cannot be clearly perceived by the naked eye.
[0161] In order to better understand the content of the screen preview, the following is an exemplary introduction with reference to the accompanying drawings. Figure 4 As shown:
[0162] The video channels include: 1 black frame channel, A0-A8, 9 analog channels in total, D0-D3, 4 digital channels in total, and 2 picture channels YUV0-YUV1, 16 video channels in total; in this embodiment, the preset auxiliary channel is the black frame channel.
[0163] It can be understood that Chn0 is the output channel of the video output unit for the black frame channel, Chn1 is the output channel of the video output unit for A0, Chn2 is the output channel of the video output unit for A1, Chn3 is the output channel of the video output unit for A2, Chn4 is the output channel of the video output unit for A3, Chn5 is the output channel of the video output unit for A4, Chn6 is the output channel of the video output unit for A5, Chn7 is the output channel of the video output unit for A6, Chn8 is the output channel of the video output unit for A7, Chn9 is the output channel of the video output unit for A8, Chn10 is the output channel of the video output unit for D0, Chn11 is the output channel of the video output unit for D1, Chn12 is the output channel of the video output unit for D2, Chn13 is the output channel of the video output unit for D3, Chn14 is the output channel of the video output unit for the picture channel YUV0, and Chn15 is the output channel of the video output unit for the picture channel YUV1.
[0164] In order to better understand the content of the preset background image, the following is a brief introduction with reference to the accompanying drawings. Figure 5 As shown:
[0165] Before switching, the preview screen is 4 views, and the video channels are A0, A1, D0 and D1 respectively. After switching, the preview screen is 2 views, and the video channels are A0 and A1 respectively. The effect after switching can be seen in the figure on the right. The predetermined background image is a black frame image, and the image data of A0 and A1 are displayed.
[0166] It can be seen that the embodiment of the present application can pre-create a preset auxiliary channel. When the screen preview is switched, the preset background image of the preview auxiliary channel can cover the residual image data of the historical video channel to achieve the effect of clearing the screen. When the preview screen is cleared in the related technology, the existing video output link needs to be destroyed, which takes a certain amount of time. Therefore, the present application takes less time when switching the screen preview, and can improve the smoothness of the screen switching.
[0167] In one implementation, the main control unit is further used for:
[0168] In response to the creation condition being met, determining the channel type of each video channel of the video recorder with data access capability and the channel type of the preset auxiliary channel, and creating the preset video output link of each video channel and the video output link of the preset auxiliary channel according to the determined channel type and the mapping relationship between each channel type and the corresponding processing unit;
[0169] Setting the state of a preset video output link of each video channel to a first state, and setting the state of a video output link of a preset auxiliary channel to a second state;
[0170] Among them, the channel types include: analog channel type, digital channel type or picture channel type, and the processing units corresponding to any channel type include: video output unit, image processing unit and other processing units required to process image data of the channel of this channel type.
[0171] It can be understood that the above steps may be executed by the main control unit before the state adjustment processing is performed on each preset video output link in response to the trigger condition for performing picture preview for at least one target video channel being met.
[0172] The creation condition may be a user initiating an instruction to the main control unit to create a video output link, which is not specifically limited in this application.
[0173] It should be emphasized that the main control unit can first determine the channel type of each video channel of the video recorder with data access capability and the channel type of the preset auxiliary channel. Usually, the channel type of the preset auxiliary channel is a picture channel type, and the channel type of each video channel can be multiple, which can be an analog channel type, a digital channel type or a picture channel type, etc.; then, the processing unit corresponding to the analog channel type may include a video acquisition unit, an image processing unit and a video output unit, and the other processing units required to process the image data of the channel of this channel type are the video acquisition unit, and the processing unit corresponding to the digital channel type may include a video decoding unit, an image processing unit and a video output unit. The other processing units required to process the image data of the channel of this channel type are the video decoding unit, and the processing units corresponding to the picture channel type may include a main control unit, an image processing unit and a video output unit. The other processing units required to process the image data of the channel of this channel type are the main control unit, and this application does not make any specific limitations on this.
[0174] It is understandable that each channel type of video channel corresponds to a preset video output link, which has been introduced in the above embodiment, so it will not be repeated here. Also, the state of the preset video output link for each video channel can be set to the first state, and the state of the video output link for the preset auxiliary channel can be set to the second state, which has also been introduced in the above embodiment, so it will not be repeated here.
[0175] It can be seen that the embodiment of the present application can predetermine the channel type of each video channel and the channel type of the preset auxiliary channel, and create a preset video output link for each video channel and a video output link for the preset auxiliary channel, and set the state of the preset video output link of each video channel to the first state, and set the state of the video output link of the preset auxiliary channel to the second state. When the screen preview is switched subsequently, there is no need to perform complicated destruction and reconstruction of the video output link, and the state of the preset video output link of the video channel can be adjusted. Therefore, when the screen preview is switched, the smoothness of the screen switching can be improved.
[0176] A video processing method provided by an embodiment of the present application is described below in conjunction with the accompanying drawings. In one implementation, the video processing method can be applied to a video processing device. Figure 6 As shown, a video processing method provided in an embodiment of the present application may include the following steps:
[0177] S601, in response to satisfying a trigger condition for executing a target task for at least one target video channel, performing a state adjustment process;
[0178] The state adjustment process is a process for the state of a link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel of the video processing device with data access capability and having a first state by default, and the state adjustment process is used to make the state of the preset video output link of each target video channel the second state, and other preset video output links the first state; for each preset video output link, the first state is used to indicate that the video processing device is not enabled for the video channel to which the preset video output link belongs, and the second state is used to indicate that the video processing device is enabled for the video channel to which the preset video output link belongs;
[0179] S602, for each target video channel, in response to the state of the preset video output link of the target video channel being the second state, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel;
[0180] S603, obtaining the image data processing result corresponding to the target video channel; and executing the processing action corresponding to the target task based on the image data processing result corresponding to each target video channel.
[0181] It can be understood that the video processing device can be provided with the image processing unit, task processing unit, etc. introduced in the above system embodiment. The video processing device can also be the video recorder in the above system embodiment, and of course it can also be other devices, such as an all-in-one device. The embodiment of the present application does not make specific limitations on this.
[0182] Optionally, in response to satisfying a trigger condition for executing a target task for at least one target video channel, executing state adjustment processing includes: in response to an execution instruction of a target task for at least one target video channel generated by triggering a task switching operation, performing state adjustment processing based on the at least one target video channel and various historical video channels; wherein the various historical video channels are video channels targeted by the tasks being executed by the video processing device before the target switching operation is issued.
[0183] Optionally, performing state adjustment processing based on the at least one target video channel and each historical video channel comprises: performing state adjustment processing based on the at least one target video channel and each historical video channel according to a predetermined adjustment strategy; wherein the predetermined adjustment strategy comprises a first adjustment strategy or a second adjustment strategy;
[0184] The first adjustment strategy includes: keeping the state of the preset video output link of the first type of channel unchanged, setting the state of the preset video output link of the second type of channel to the first state, and setting the state of the preset video output link of the third type of channel to the second state; wherein, the first type of channel is a channel in each of the historical video channels that is the same as any target video channel, the second type of channel is a channel in each of the historical video channels that is different from the at least one target video channel, and the third type of channel is a channel in the at least one target video channel other than the first type of channel; or,
[0185] The second adjustment strategy includes: setting the state of the preset video output link of each historical video channel in each preset video output link to a first state, and setting the state of the preset video output link of at least one target video channel in each preset video output link to a second state.
[0186] Optionally, in response to satisfying a trigger condition for executing a target task for at least one target video channel, executing state adjustment processing includes: in response to an execution instruction for the target task for at least one target video channel generated by triggering a predetermined task start operation, setting the state of the video output link of the at least one target video channel among the respective preset video output links to a second state.
[0187] Optionally, the method further includes: in response to an execution instruction of a target task for at least one target video channel generated by triggering a predetermined task start operation, maintaining the status of other video output links among the preset video output links except the video output link of the at least one target video channel as a default state.
[0188] Optionally, the target task is a video preview task; and based on the image data processing results corresponding to each target video channel, executing the processing action corresponding to the target task includes: based on the image data processing results corresponding to each target video channel, outputting image data for preview display for each target video channel to a preview device.
[0189] Optionally, the target task is a video encoding task; based on the image data processing results corresponding to each target video channel, the processing action corresponding to the target task is executed, including: splicing the image data processing results corresponding to each target video channel to obtain spliced image data, and sending the spliced image data to a video encoding unit so that the video encoding unit encodes the spliced image data.
[0190] Optionally, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel includes: obtaining a parameter value of a processing parameter for the image data of the target video channel; wherein the parameter value of the processing parameter is: a parameter value matching the screen preview indicated by the video preview task;
[0191] The image data for image data processing of the target video channel is obtained, and the image data processing is performed according to the parameter value of the processing parameter to obtain the data processing result of the target video channel; the image data for preview display of each target video channel is output to the preview device based on the image data processing result corresponding to each target video channel, including: obtaining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device; wherein the parameter value of the preview position parameter is: a parameter value matching the screen preview indicated by the video preview task; according to the parameter value of the preview position parameter, based on the image data processing result corresponding to each target video channel, the image data for preview display of each target video channel is generated, and the image data for preview display is output to the preview device.
[0192] Optionally, the method further comprises: in response to satisfying a trigger condition for executing a target task for at least one target video channel, determining parameter values of processing parameters of image data of each target video channel, and determining parameter values of preview position parameters of each target video channel in a preview interface of the preview device;
[0193] The obtaining of the parameter value of the processing parameter of the image data for the target video channel includes: obtaining the determined parameter value of the processing parameter of the image data for the target video channel; the obtaining of the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device includes: obtaining the determined parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
[0194] Optionally, the method further comprises: setting a target parameter having a default parameter value for each video channel of the video processing device having data access capability, the target parameter of each video channel comprising a preview position parameter of the video channel;
[0195] After determining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device, the method further includes:
[0196] According to the determined parameter value, updating the parameter value of the preview position parameter included in the target parameter of each target video channel;
[0197] The obtaining of the determined parameter values of the preview position parameters of each target video channel in the preview interface of the preview device includes:
[0198] The parameter value of the preview position parameter included in the target parameter of each target video channel is read to obtain the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
[0199] Optionally, after performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel, the method further comprises: for a preset auxiliary channel, in response to the state of the video output link of the preset auxiliary channel being the second state, processing the image data of the preset auxiliary channel to obtain an image data processing result corresponding to the preset auxiliary channel;
[0200] The method further comprises:
[0201] For the preset auxiliary channel, in response to the state of the video output link of the preset auxiliary channel being the second state, obtaining an image data processing result corresponding to the preset auxiliary channel;
[0202] The step of outputting image data for preview display of each target video channel to the preview device based on the image data processing result corresponding to each target video channel includes:
[0203] Based on the image data processing results corresponding to the target video channels and the image data processing results corresponding to the preset auxiliary channels, according to the priorities of the target video channels for display levels and the priorities of the preset auxiliary channels for display levels, outputting the image data for preview display for the target video channels to the preview device;
[0204] Among them, the preset auxiliary channel is a preset channel for transmitting a predetermined background image and having a specified preview position parameter, the video output link of the preset auxiliary channel is a video output link pre-created for the preset auxiliary channel and maintained in the second state, and the specified preview position parameter is a position parameter used to make the predetermined background image full-screen in the preview interface of the preview device; the priority of the preset auxiliary channel for the display level in the preview interface is lower than the priority of each video channel with data access capability of the video processing device.
[0205] Optionally, the method further comprises:
[0206] In response to satisfying the creation condition, determining the channel type of each video channel with data access capability of the video processing device and the channel type of the preset auxiliary channel, and creating the preset video output link of each video channel and the video output link of the preset auxiliary channel according to the determined channel type;
[0207] Setting the state of a preset video output link of each video channel to a first state, and setting the state of a video output link of a preset auxiliary channel to a second state;
[0208] The channel type includes: analog channel type, digital channel type or image channel type.
[0209] It can be understood that in the process of creating the preset video output link of each video channel and the video output link of the preset auxiliary channel, it can be based on the determined channel type or on the mapping relationship between each channel type and the corresponding processing unit, wherein the processing unit corresponding to any channel type includes: a video output unit, an image processing unit, and other processing units required to process the image data of the channel of this channel type.
[0210] Also, the specific implementation of the above video processing method can refer to the above system embodiment, and this application will not go into details here.
[0211] It can be seen that when the embodiment of the present application executes the target task for the target video channel, there is no need to perform time-consuming operations on the video output link. Instead, it is only necessary to adjust the state of each preset video output link to enable the video processing device for each target video channel, thereby realizing the execution of the target task for each target video channel. Therefore, the task processing efficiency can be improved through this solution.
[0212] Optionally, in another embodiment, taking the video processing device as a video recorder and the target task as a video preview task as an example, the video processing method of the present application is exemplarily introduced.
[0213] The present application provides a video processing method, which is applied to a video recorder and may specifically include the following steps:
[0214] Step 1: Create a preset video output link for each video channel, and adjust the state of each created preset video output link to a hidden state;
[0215] It is understandable that in step 1, the preset video output link of each video channel can be pre-allocated, and this process can also be considered as an initialization process. In addition, the status of each preset video output link created can be adjusted to be hidden, so that the image processing unit and the video output unit can not enable the video channel to which each preset video output link belongs.
[0216] Step 2: setting the status of each preset video output link and each historical video channel in each preset video output link to a hidden state;
[0217] It can be understood that step two can be executed after responding to the trigger condition for screen preview for the target video channel, and the state of the preset video output link of each historical video channel can be directly adjusted to a hidden state, so that the image processing unit and the video output unit are not enabled for each historical video channel, and the image data of the target video channel can be the image data to be previewed.
[0218] Step three: determine the parameter value of the new view; wherein the new view is the view corresponding to the image data to be previewed, that is, the view corresponding to the image data of the target video channel.
[0219] It can be understood that the parameter values of the new view can be dynamically adjusted according to the instructions issued by the user through the main control unit, wherein the parameter values of the new view may include: the parameter values of the processing parameters of the image data of each target video channel, and the parameter values of the preview position parameters of each target video channel in the preview interface of the preview device.
[0220] Step 4: Set the state of the preset video output link of the target video channel to a non-hidden state, so that the image processing unit and the video output unit enable the target video channel. It can be understood that after the state of the preset video output link of the target video channel is set to a non-hidden state, the image processing unit can perform image processing on the image data of the target video channel, and the video output unit can output the processed image data, thereby realizing screen preview.
[0221] In addition, in the fields of recorded teaching, analog cameras and IPCs can be connected to the recorder in this application, and this solution can be used to switch the directing function. The pictures before and after the switching are connected smoothly, and the effect of imperceptible switching of the directing content can be achieved.
[0222] It can be seen that this solution can optimize video preview. For DVR devices in the field of video preview, in the scenario of screen preview switching, it can greatly speed up the image output speed after view switching and improve user experience. In addition, when this solution is used to switch the director function, the screen connection before and after the switch is smooth, and the effect of imperceptible switching of the director content can be achieved.
[0223] In the technical solution of this application, the operations involved in obtaining, storing, using, processing, transmitting, providing and disclosing user personal information are all carried out with the user's authorization.
[0224] In the above embodiments, all or part of the embodiments may be implemented by software, hardware, firmware, or any combination thereof. When implemented by software, all or part of the embodiments may be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of the present application are generated.
[0225] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
Claims
1. A video recorder, characterized in that: include: Main control unit, image processing unit and task execution unit; The main control unit is used to perform state adjustment processing in response to satisfying a trigger condition for executing a target task for at least one target video channel; wherein the state adjustment processing is processing of the state of the link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel of the video recorder with data access capability and a default state of the first state, and the state adjustment processing is used to make the state of the preset video output link of each target video channel the second state, and other preset video output links the first state; for each preset video output link, the first state is used to indicate that the image processing unit and the task execution unit are not enabled for the video channel to which the preset video output link belongs, and the second state is used to indicate that the image processing unit and the task execution unit are enabled for the video channel to which the preset video output link belongs; wherein the preset video output link of each video channel includes: various processing units required for executing the target task on the image data of the video channel, and the various processing units include the image processing unit and the task execution unit; The image processing unit is used for, for each target video channel, in response to the state of the preset video output link of the target video channel being the second state, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel; The task execution unit is used to obtain, for each target video channel, an image data processing result corresponding to the target video channel in response to the state of the preset video output link of the target video channel being the second state; and execute the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel.
2. The video recorder according to claim 1, characterized in that The main control unit performs a state adjustment process in response to satisfying a trigger condition for executing a target task for at least one target video channel, including: In response to an execution instruction of a target task for at least one target video channel generated by triggering a task switching operation, performing a state adjustment process based on the at least one target video channel and each historical video channel; The historical video channels are video channels targeted by the tasks being executed by the video recorder before the target switching operation is issued.
3. The video recorder according to claim 2, characterized in that The performing of state adjustment processing based on the at least one target video channel and each historical video channel includes: According to a predetermined adjustment strategy, based on the at least one target video channel and each historical video channel, performing state adjustment processing; Wherein, the predetermined adjustment strategy includes a first adjustment strategy or a second adjustment strategy; The first adjustment strategy includes: keeping the state of the preset video output link of the first type of channel unchanged, setting the state of the preset video output link of the second type of channel to the first state, and setting the state of the preset video output link of the third type of channel to the second state; wherein, the first type of channel is a channel in each of the historical video channels that is the same as any target video channel, the second type of channel is a channel in each of the historical video channels that is different from the at least one target video channel, and the third type of channel is a channel in the at least one target video channel other than the first type of channel; or, The second adjustment strategy includes: setting the state of the preset video output link of each historical video channel in each preset video output link to a first state, and setting the state of the preset video output link of at least one target video channel in each preset video output link to a second state.
4. The video recorder according to claim 1, characterized in that The main control unit performs a state adjustment process in response to satisfying a trigger condition for executing a target task for at least one target video channel, including: In response to an execution instruction for a target task for at least one target video channel generated by triggering a predetermined task start operation, a state of a video output link of the at least one target video channel among the preset video output links is set to a second state.
5. The video recorder according to claim 4, characterized in that The main control unit is also used to maintain the status of other video output links among the preset video output links except the video output link of the at least one target video channel as a default state in response to an execution instruction of a target task for at least one target video channel generated by triggering a predetermined task start operation.
6. The video recorder according to any one of claims 1 to 5, characterized in that: The target task is a video preview task, and the task execution unit is a video output unit; The task execution unit executes the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel, including: The video output unit outputs image data for preview display for each target video channel to the preview device based on the image data processing result corresponding to each target video channel.
7. The video recorder according to any one of claims 1 to 5, characterized in that: The target task is a video encoding task, and the task execution unit is a virtual output unit; The task execution unit executes the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel, including: The virtual output unit splices the image data processing results corresponding to each target video channel to obtain spliced image data, and sends the spliced image data to the video encoding unit so that the video encoding unit encodes the spliced image data.
8. The video recorder according to claim 6, characterized in that The image processing unit performs image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel, including: Obtaining a parameter value of a processing parameter for the image data of the target video channel; wherein the parameter value of the processing parameter is: a parameter value that matches the picture preview indicated by the video preview task; Performing image data processing on the target video channel obtained by processing the previous-stage unit in the preset video output link of the target video channel according to the parameter value of the processing parameter to obtain a data processing result of the target video channel; Wherein, for each preset video output link, the preceding unit of the image processing unit in the video output link enables the video channel to which the preset video output link belongs in response to the creation of the preset video output link; The video output unit outputs image data for preview display for each target video channel to the preview device based on the image data processing result corresponding to each target video channel, including: Obtaining parameter values of preview position parameters of each target video channel in the preview interface of the preview device; wherein the parameter value of the preview position parameter is: a parameter value matching the screen preview indicated by the video preview task; According to the parameter value of the preview position parameter and based on the image data processing results corresponding to each target video channel, image data for preview display is generated for each target video channel, and the image data for preview display is output to the preview device.
9. The video recorder according to claim 8, characterized in that The main control unit is further used to determine parameter values of processing parameters of image data of each target video channel and parameter values of preview position parameters of each target video channel in a preview interface of the preview device in response to satisfying a trigger condition for executing a target task for at least one target video channel; The image processing unit obtains parameter values of processing parameters for the image data of the target video channel, including: Acquire parameter values of processing parameters of image data for the target video channel determined by the main control unit; The video output unit obtains the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device, including: Obtaining parameter values of preview position parameters of each target video channel in the preview interface of the preview device determined by the main control unit.
10. The video recorder according to claim 9, characterized in that The main control unit is also used to set a target parameter with a default parameter value for each video channel of the video recorder with data access capability, and the target parameter of each video channel includes a preview position parameter of the video channel; The main control unit is further configured to update the parameter value of the preview position parameter included in the target parameter of each target video channel according to the determined parameter value after determining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device; The video output unit obtains the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device determined by the main control unit, including: The parameter value of the preview position parameter included in the target parameter of each target video channel is read to obtain the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
11. The video recorder according to claim 6, characterized in that The image processing unit is further configured to process the image data of the preset auxiliary channel in response to the state of the video output link of the preset auxiliary channel being the second state, so as to obtain the image data processing result corresponding to the preset auxiliary channel; The video output unit is further configured to obtain, for the preset auxiliary channel, an image data processing result corresponding to the preset auxiliary channel in response to the state of the video output link of the preset auxiliary channel being the second state; The video output unit outputs image data for preview display for each target video channel to the preview device based on the image data processing result corresponding to each target video channel, including: Based on the image data processing results corresponding to the target video channels and the image data processing results corresponding to the preset auxiliary channels, according to the priorities of the target video channels for display levels and the priorities of the preset auxiliary channels for display levels, outputting the image data for preview display for the target video channels to the preview device; The preset auxiliary channel is a preset channel for transmitting a preset background image and having a specified preview position parameter, the video output link of the preset auxiliary channel is a video output link pre-created by the main control unit for the preset auxiliary channel and maintained in the second state, and the specified preview position parameter is a position parameter for making the preset background image appear full screen in the preview interface of the preview device; The priority of the preset auxiliary channel for display level in the preview interface is lower than the priority of each video channel of the video recorder with data access capability.
12. The video recorder according to claim 11, characterized in that The main control unit is also used for: In response to the creation condition being met, determining the channel type of each video channel of the video recorder with data access capability and the channel type of the preset auxiliary channel, and creating the preset video output link of each video channel and the video output link of the preset auxiliary channel according to the determined channel type and the mapping relationship between each channel type and the corresponding processing unit; Setting the state of a preset video output link of each video channel to a first state, and setting the state of a video output link of a preset auxiliary channel to a second state; Among them, the channel types include: analog channel type, digital channel type or picture channel type, and the processing units corresponding to any channel type include: video output unit, image processing unit and other processing units required to process image data of the channel of this channel type.
13. A video processing method, characterized in that: Applied to a video processing device, the method comprises: In response to satisfying a trigger condition for executing a target task for at least one target video channel, a state adjustment process is performed; wherein the state adjustment process is a process for the state of a link in each preset video output link, wherein each preset video output link includes a preset video output link pre-created for each video channel with data access capability of the video processing device and having a first state by default, and the state adjustment process is used to make the state of the preset video output link of each target video channel a second state, and other preset video output links the first state; for each preset video output link, the first state is used to indicate that the video processing device is not enabled for the video channel to which the preset video output link belongs, and the second state is used to indicate that the video processing device is enabled for the video channel to which the preset video output link belongs; wherein the preset video output link of each video channel includes: various processing units required for executing the target task on the image data of the video channel, and the various processing units include an image processing unit and a task execution unit in the video processing device; For each target video channel, in response to the state of the preset video output link of the target video channel being the second state, performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel; Obtaining the image data processing result corresponding to the target video channel; and executing the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel.
14. The method according to claim 13, characterized in that The step of performing state adjustment processing in response to satisfying a trigger condition for executing a target task for at least one target video channel comprises: In response to an execution instruction of a target task for at least one target video channel generated by triggering a task switching operation, performing a state adjustment process based on the at least one target video channel and each historical video channel; The historical video channels are video channels targeted by the tasks being executed by the video processing device before the target switching operation is issued.
15. The method according to claim 14, characterized in that The performing of state adjustment processing based on the at least one target video channel and each historical video channel includes: According to a predetermined adjustment strategy, based on the at least one target video channel and each historical video channel, performing state adjustment processing; Wherein, the predetermined adjustment strategy includes a first adjustment strategy or a second adjustment strategy; The first adjustment strategy includes: keeping the state of the preset video output link of the first type of channel unchanged, setting the state of the preset video output link of the second type of channel to the first state, and setting the state of the preset video output link of the third type of channel to the second state; wherein, the first type of channel is a channel in each of the historical video channels that is the same as any target video channel, the second type of channel is a channel in each of the historical video channels that is different from the at least one target video channel, and the third type of channel is a channel in the at least one target video channel other than the first type of channel; or, The second adjustment strategy includes: setting the state of the preset video output link of each historical video channel in each preset video output link to a first state, and setting the state of the preset video output link of at least one target video channel in each preset video output link to a second state.
16. The method according to claim 13, characterized in that The step of performing state adjustment processing in response to satisfying a trigger condition for executing a target task for at least one target video channel comprises: In response to an execution instruction for a target task for at least one target video channel generated by triggering a predetermined task start operation, a state of a video output link of the at least one target video channel among the preset video output links is set to a second state.
17. The method according to claim 16, characterized in that The method further comprises: In response to an execution instruction of a target task for at least one target video channel generated by triggering a predetermined task start operation, the states of other video output links among the preset video output links except the video output link of the at least one target video channel are maintained as a default state.
18. The method according to any one of claims 13 to 17, characterized in that: The target task is a video preview task; The performing of the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel includes: Based on the image data processing results corresponding to each target video channel, the image data for preview display for each target video channel is output to the preview device.
19. The method according to any one of claims 13 to 17, characterized in that: The target task is a video encoding task; The performing of the processing action corresponding to the target task based on the image data processing results corresponding to each target video channel includes: The image data processing results corresponding to each target video channel are spliced to obtain spliced image data, and the spliced image data is sent to a video encoding unit so that the video encoding unit performs encoding processing on the spliced image data.
20. The method according to claim 18, characterized in that The performing image data processing on the image data of the target video channel to obtain the image data processing result corresponding to the target video channel includes: Obtaining a parameter value of a processing parameter for the image data of the target video channel; wherein the parameter value of the processing parameter is: a parameter value matching the screen preview indicated by the video preview task; Acquire image data for image data processing of the target video channel, perform image data processing according to parameter values of the processing parameters, and obtain a data processing result of the target video channel; The step of outputting image data for preview display of each target video channel to the preview device based on the image data processing result corresponding to each target video channel includes: Obtaining parameter values of preview position parameters of each target video channel in the preview interface of the preview device; wherein the parameter value of the preview position parameter is: a parameter value matching the screen preview indicated by the video preview task; According to the parameter value of the preview position parameter and based on the image data processing results corresponding to each target video channel, image data for preview display is generated for each target video channel, and the image data for preview display is output to the preview device.
21. The method according to claim 20, characterized in that The method further comprises: In response to satisfying a trigger condition for executing a target task for at least one target video channel, determining parameter values of processing parameters of image data of each target video channel, and determining parameter values of preview position parameters of each target video channel in a preview interface of the preview device; The step of obtaining the parameter value of the processing parameter for the image data of the target video channel includes: Obtaining the parameter value of the determined processing parameter for the image data of the target video channel; The obtaining of the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device includes: Obtain the determined parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
22. The method according to claim 21, characterized in that The method further comprises: setting a target parameter having a default parameter value for each video channel having data access capability of the video processing device, wherein the target parameter of each video channel comprises a preview position parameter of the video channel; After determining the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device, the method further includes: According to the determined parameter value, updating the parameter value of the preview position parameter included in the target parameter of each target video channel; The obtaining of the determined parameter values of the preview position parameters of each target video channel in the preview interface of the preview device includes: The parameter value of the preview position parameter included in the target parameter of each target video channel is read to obtain the parameter value of the preview position parameter of each target video channel in the preview interface of the preview device.
23. The method according to claim 18, characterized in that After performing image data processing on the image data of the target video channel to obtain an image data processing result corresponding to the target video channel, the method further includes: for a preset auxiliary channel, in response to the state of the video output link of the preset auxiliary channel being the second state, processing the image data of the preset auxiliary channel to obtain an image data processing result corresponding to the preset auxiliary channel; The method further comprises: For the preset auxiliary channel, in response to the state of the video output link of the preset auxiliary channel being the second state, obtaining an image data processing result corresponding to the preset auxiliary channel; The step of outputting image data for preview display of each target video channel to the preview device based on the image data processing result corresponding to each target video channel includes: Based on the image data processing results corresponding to the target video channels and the image data processing results corresponding to the preset auxiliary channels, according to the priorities of the target video channels for display levels and the priorities of the preset auxiliary channels for display levels, outputting the image data for preview display for the target video channels to the preview device; Among them, the preset auxiliary channel is a preset channel for transmitting a predetermined background image and having a specified preview position parameter, the video output link of the preset auxiliary channel is a video output link pre-created for the preset auxiliary channel and maintained in the second state, and the specified preview position parameter is a position parameter used to make the predetermined background image full-screen in the preview interface of the preview device; the priority of the preset auxiliary channel for the display level in the preview interface is lower than the priority of each video channel with data access capability of the video processing device.
24. The method according to claim 23, characterized in that The method further comprises: In response to satisfying the creation condition, determining the channel type of each video channel with data access capability of the video processing device and the channel type of the preset auxiliary channel, and creating the preset video output link of each video channel and the video output link of the preset auxiliary channel according to the determined channel type; Setting the state of a preset video output link of each video channel to a first state, and setting the state of a video output link of a preset auxiliary channel to a second state; The channel type includes: analog channel type, digital channel type or image channel type.
