Video screen projection method, device, equipment and storage medium
By receiving and decoding video data packets from mobile terminals in the vehicle computer, determining and hiding video frames, and directly projecting video frames, the problem of high performance occupancy of vehicle computers in the existing technology is solved, and the smoothness of video playback is improved.
Patent Information
- Application Number
- CN202211530998.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-01
- Publication Date
- 2025-04-22
- Estimated Expiration
- 2042-12-01
AI Technical Summary
When the prior art projects the video data of a mobile terminal to the screen of the vehicle computer, each packet of video data needs to be decoded, cropped and amplified, resulting in high performance occupancy of the vehicle computer, which can easily lead to lag and affect the video playback performance.
By receiving the video data packet to be cast, the border size of the multi-frame target video frame and its video border are decoded, and all border pixel points are determined according to the border size, and these pixel points are hidden when casting, thereby directly decoding and playing video packets.
It improves the smoothness of video playback, reduces the performance occupancy rate when casting the screen of the car, and avoids additional processing of video data.
Smart Images

Figure CN115942038B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of vehicle networking technology, and in particular to a video projection method, device, equipment and storage medium. Background Art
[0002] In some scenarios, users will synchronize the video in the mobile terminal to the car computer for playback. For example, the user sitting in the front passenger seat will project the video on the mobile terminal onto the front passenger screen for a better visual experience while driving. Or the user sitting in the back seat of the vehicle will project the video on the mobile terminal onto the back screen. Or the driver will project the video in the terminal onto the main control screen of the vehicle when he is not driving (for example, waiting for someone or needing to rest due to driving fatigue).
[0003] In the prior art, in order to ensure that the video data sent by the mobile terminal can be adapted and played on the vehicle screen, a decoder is usually used to process each packet of video data sent by the mobile phone separately, such as cropping, enlarging, cropping first and then enlarging, or enlarging first and then cropping each video frame, so that the size of each frame of video data after processing can be adapted to the screen size of the vehicle, and then the processed video data is played on the vehicle screen. As a result, the vehicle performance is highly occupied, which can easily cause the vehicle to freeze and affect the video playback performance. Summary of the invention
[0004] In view of the above problems, the present invention is proposed to provide a video projection method, device, equipment and storage medium that overcome the above problems or at least partially solve the above problems.
[0005] According to a first aspect of the present invention, a video screen projection method is provided, the method comprising:
[0006] Receive the video data packet to be projected;
[0007] Decoding the video data packet to obtain multiple target video frames and the frame size of the video frame corresponding to each target video frame, wherein the frame size is determined according to the screen resolution of the vehicle computer;
[0008] According to the frame size, all corresponding frame pixel points in each target video frame are determined;
[0009] Each target video frame is projected onto the screen, wherein all border pixels in the target video frame are in a hidden state.
[0010] According to a second aspect of the present invention, a video projection device is provided, the device comprising:
[0011] A data packet receiving module, used to receive video data packets to be projected;
[0012] A data decoding module, used for decoding the video data packet to obtain multiple target video frames and the frame size of the video frame corresponding to each target video frame, wherein the frame size is determined according to the screen resolution of the vehicle computer;
[0013] A border pixel determination module, used to determine all corresponding border pixel points in the target video frame according to the border size;
[0014] The video frame projection module is used to project each target video frame, wherein all border pixels in the target video frame are in a hidden state.
[0015] According to another aspect of the present invention, there is provided an electronic device, comprising:
[0016] one or more processors;
[0017] Memory;
[0018] One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute any of the methods described above.
[0019] According to another aspect of the present invention, a computer-readable storage medium is provided, storing a computer program for use in conjunction with an electronic device, wherein the computer program can be executed by a processor to implement any of the methods described above.
[0020] In the scheme of the present invention, firstly, a video data packet to be projected is received, and then the video data packet is decoded to obtain multiple target video frames and the border size of the video border corresponding to each target video frame, wherein the border size is determined according to the screen resolution of the vehicle computer. Then, based on the border size, all corresponding border pixels in the target video frame are determined, and finally each target video frame is projected, wherein all border pixels in the target video frame are in a hidden state. Therefore, after receiving each packet of video data, it is only necessary to decode and play it, and no additional operations are required on the video data, thereby improving the smoothness of video playback and reducing the performance occupancy rate when projecting the vehicle computer.
[0021] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented according to the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] By reading the detailed description of the preferred embodiment below, various other advantages and benefits will become clear to those of ordinary skill in the art. The accompanying drawings are only used for the purpose of illustrating the preferred embodiment and are not considered to be limitations of the present invention. In addition, the same reference symbols are used to represent the same components throughout the accompanying drawings.
[0023] In the attached picture:
[0024] Figure 1 is a flowchart of the steps of a video screen projection method provided by an embodiment of the present invention;
[0025] Figure 2 is a flowchart of another video screen projection method provided by an embodiment of the present invention;
[0026] Figure 3 is a moving schematic diagram of a display interface provided by an embodiment of the present invention;
[0027] Figure 4 It is a block diagram of a video projection device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0028] The exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present invention and to enable the scope of the present invention to be fully communicated to those skilled in the art.
[0029] Reference Figure 1 , shows a flowchart of the steps of a video screen projection method provided by an embodiment of the present invention, the method may include:
[0030] S101, receiving a video data packet to be projected.
[0031] S102, decoding the video data packet to obtain multiple target video frames and a frame size of a video frame corresponding to each target video frame, wherein the frame size is determined according to a screen resolution of the vehicle computer.
[0032] In an embodiment of the present invention, after establishing communication with the vehicle computer, the user terminal device can send a video data packet to be projected to the vehicle computer. The video data packet to be projected refers to a data packet obtained by compressing multiple frames of terminal video frames displayed by the user terminal. In one embodiment, the encoded video resolution corresponding to the terminal video frame protected in the video data sent by the user terminal device to the vehicle computer is generally pre-set. For example, the encoded video resolution can include three forms: 800*480, 1280*720 and 1920*1080.
[0033] After receiving the video data packet, the vehicle computer decodes the video data packet and obtains multiple target video frames and the frame size of the video frame corresponding to each target video frame. In one embodiment, due to different vehicle service providers, the vehicle computer screen resolutions corresponding to different models are quite different. Therefore, the target video frame corresponding to the encoded video resolution needs to be fully displayed on the vehicle computer screen in equal proportion. Therefore, in the case where the horizontal resolution and the vertical resolution corresponding to the encoded video resolution and the vehicle computer screen resolution are not in the same proportional relationship, it will be scaled according to the vehicle computer screen resolution, and on the basis of the scaled resolution, the horizontal pixel points or the vertical pixel point rate will be increased at the edge until the encoded video resolution supported by the user terminal device is obtained, and the video frame is generated. In one embodiment, all the corresponding frame pixels in the video frame can be filled with the target pixel value. Thus, a frame of video can be obtained and compressed. Among them, the frame size of the video frame can include the increased number of horizontal pixels or the increased number of vertical pixels.
[0034] S103: Determine all corresponding border pixel points in the target video frame according to the border size.
[0035] S104, projecting each target video frame onto the screen, wherein all border pixels in the target video frame are in a hidden state.
[0036] In an embodiment of the present invention, after obtaining the target video frame, the vehicle computer can determine all the corresponding border pixels in the target video frame according to the corresponding border size. In this way, each target video frame can be projected in sequence, and the video playback corresponding to the video data packet can be realized. Among them, when projecting the target video frame, the border pixels are hidden, and the target pixels other than the border pixels are visualized (that is, the only target pixels other than the border pixels in the target video frame that the user can see based on the vehicle computer screen). As a result, what is played on the vehicle computer screen is the complete and proportionally scaled video data projected by the user terminal. Therefore, after receiving each packet of video data, it only needs to be decoded and played, and no additional operations are required on the video data, thereby improving the smoothness of video playback and reducing the performance occupancy rate when the vehicle computer is projecting the screen.
[0037] Reference Figure 2 , shows a flowchart of another video screen projection method provided by an embodiment of the present invention, the method may include:
[0038] S201. Send a screen projection instruction to the user terminal, wherein the screen projection instruction includes at least the vehicle screen resolution, so that the user terminal adds a video border to the terminal video frame according to the vehicle screen resolution, and compresses the terminal video frame after adding the video border, compresses and generates a video data packet to be projected and returns it.
[0039] S202, receiving a video data packet to be projected.
[0040] S203 , decoding the video data packet to obtain multiple target video frames and the frame size of a video frame corresponding to each target video frame.
[0041] In an embodiment of the present invention, after the user terminal device establishes communication with the vehicle computer, the vehicle computer can send a screen projection instruction to the user terminal, wherein the screen projection instruction is used to send an instruction to the user terminal to start transmitting video data. After receiving the screen projection instruction, the user terminal sends the video data to the vehicle computer, plays the video data on the vehicle computer, and enables the user to see the video data displayed on the user terminal based on the vehicle computer screen and operate the user terminal based on the vehicle computer screen.
[0042] In one embodiment, the screen projection instruction may include at least the vehicle screen resolution. The encoded video resolution corresponding to the terminal video frame protected in the video data sent by the user terminal device to the vehicle is generally pre-set, for example, the encoded video resolution may include 800*480, 1280*720 and 1920*1080.
[0043] Due to different vehicle service providers, the vehicle screen resolutions corresponding to different vehicle models vary greatly. Therefore, the target video frame corresponding to the coded video resolution needs to be fully displayed on the vehicle screen in equal proportion. For example, the vehicle screen resolution can be 1200*600, and the coded video resolution is 800*480. Based on this, it can be seen that the horizontal resolution and vertical resolution corresponding to the coded video resolution and the vehicle screen resolution are not in the same proportional relationship.
[0044] In the case where the lateral resolution and vertical resolution corresponding to the encoded video resolution and the vehicle screen resolution are not in the same proportional relationship, the lateral resolution and vertical resolution of the encoded video resolution can be multiplied by a proportional coefficient at the same time. For example, the proportional coefficient is 1.5, that is, the lateral resolution and vertical resolution of the encoded video resolution are simultaneously enlarged by 1.5 times. The enlarged lateral resolution is 1200, and the enlarged vertical resolution is 720, which is 120 larger than the vertical resolution corresponding to the vehicle screen resolution. At this time, in order to ensure that the video data of the user terminal device can be displayed in proportion on the vehicle screen. A video border can be added to the terminal video frame according to the inconsistent lateral resolution or vertical resolution after scaling (lateral pixels or vertical pixels are added to the edge until the encoded video resolution supported by the user terminal device is obtained). Thereby, the terminal video frame can be scaled in proportion on the vehicle screen, and the encoded video resolution supported by the user terminal device can be satisfied at the same time.
[0045] In one embodiment, the frame size of the video frame may include an increased number of horizontal pixels or an increased number of vertical pixels, which may be calculated according to the following formula (1):
[0046] M=(L / B) / 2 (1)
[0047] Among them, M represents the number of pixels added horizontally or vertically; L refers to the resolution difference between inconsistent horizontal resolutions or the resolution difference between vertical resolutions after scaling; B refers to the scaling coefficient.
[0048] For example, by combining the vertical resolution after enlargement, which is greater than 120, and the above formula (1), it can be determined that the frame size is 40 in the vertical direction.
[0049] Thus, the terminal video frame can be compressed to a resolution of 800*400, and 40 pixels are added vertically at the two vertical edges of the terminal video frame to determine the video border. And all corresponding border pixels within the video border can be filled with the target pixel value. Among them. The target pixel value can be marked with RGB (0, 0, 0). Thus, the terminal video frame after adding the video border is 800*480. It meets the encoded video resolution supported by the user terminal device. And the terminal video frame after adding the video border is compressed. Compress and generate the video data packet to be projected and send it to the car computer.
[0050] The vehicle computer receives the video data packet to be projected, and decodes the video data packet to be projected to obtain multiple target video frames and the frame size of the video frame corresponding to each target video frame. The frame size of the video frame may include the increased number of horizontal pixels or the increased number of vertical pixels. For example, the resolution of the target video frame is 800*480, and the frame size is 40 vertically.
[0051] S204: Determine all corresponding border pixel points in the target video frame according to the border size.
[0052] In the embodiment of the present invention, one of the four vertices of the target video frame is selected as the target pixel point. For example, one of the upper left vertex, the lower left vertex, the upper right vertex, and the lower right vertex of the target video frame can be selected as the target pixel point. And the target pixel point can be used as the coordinate origin to establish a rectangular coordinate system. Therefore, the coordinate information of all the border pixel points in the target video frame located in the video border can be determined according to the coordinate information of the target pixel point and the corresponding border size.
[0053] For example, when a rectangular coordinate system is established using the lower left vertex as the coordinate origin, the coordinate information of the corresponding border pixel points can be (0, 0), (0, 40), (0, 441) and (1, 1), etc.
[0054] S205: Provide a display interface.
[0055] S206: Cover the display interface of the vehicle computer with the display interface.
[0056] S207: Projecting each video frame on the display interface.
[0057] In an embodiment of the present invention, the interface resolution of the display interface of the vehicle computer is consistent with the resolution of the vehicle computer screen. Therefore, the display part of the vehicle computer screen overlaps with the display interface. In the prior art, the display interface is generally used to project the corresponding video frame. Since the cross-sectional resolution of the display interface is constant, the video frame needs to be processed in advance, and the video frame content projected in the display interface is the video content seen by the user. The vehicle computer can also provide a display interface, wherein the interface resolution of the display interface is greater than the resolution of the vehicle computer screen, and the display interface is covered by the display interface. Among them, the interface resolution of the display interface is determined according to the product of the editing video resolution and the scaling factor. For example, the interface resolution of the display interface is 1200*600, and the interface resolution of the display interface is 1200*720. Therefore, the resolution of each target video frame after decoding is 800*480. After enlarging it by 1.5 times, it is 1200*720. Therefore, display interfaces with different interface resolutions can be generated according to different target video frames, and after the target video frame is scaled, it can also be projected into the display interface and displayed on the entire screen.
[0058] S208: Move the display interface after projection until all border pixels of the target video frame displayed in the display interface are in a hidden state.
[0059] In an embodiment of the present invention, since the interface resolution of the display interface is greater than the resolution of the vehicle screen, the user will inevitably not be able to see part of the content in the display interface based on the vehicle screen. At this time, the display interface can be moved. Correspondingly, the target video frame will also move with the display interface, so that the border pixels in each target frame can be moved out of the display interface, and the border pixels are hidden (that is, they will not be displayed on the vehicle screen). Therefore, it can be determined that after the target video frame is projected, the pixels of the target video frame located in the interface area of the display interface will be displayed on the vehicle screen, that is, they are in a display state. The pixels of other areas of the target video frame except those located in the interface area of the display interface will not be displayed on the vehicle screen, that is, they are in a hidden state.
[0060] Detect whether multiple target border pixel points in the target video frame coincide with the interface vertices of the corresponding direction in the display interface. The target border pixel points refer to the inner vertices corresponding to the video border. Figure 3As shown, when all the target pixels coincide with the four vertices of the display interface, stop moving the display interface, and determine that all the border pixels in the target video frame are in a hidden state. At this time, what is played on the car screen is the complete and proportionally scaled video data projected by the user terminal. Therefore, after receiving each packet of video data, it is only necessary to decode, play and move the display interface, and no additional operations are required on the video data, thereby improving the smoothness of video playback and reducing the performance occupancy rate when the car screen is projected. The user sees the video data displayed by the user terminal based on the car screen and operates the user terminal based on the car screen.
[0061] In one embodiment, when the display interface covers the display interface, it can be completely covered or partially covered. The covering path of the display interface to completely cover the display interface can be determined based on the rectangular coordinate system determined by the target pixel point. For example, when the lower left vertex is selected as the coordinate origin and the rectangular coordinate system is established, the corresponding covering path is that the lower left vertex of the display interface coincides with the lower left vertex of the display interface. At this time, the rectangular coordinate system corresponding to the display interface is consistent with the rectangular coordinate system corresponding to the display interface. Based on this and the frame size, the display interface is moved.
[0062] In another optional embodiment of the invention, the receiving of the video data packet to be projected includes:
[0063] Send a screen projection instruction to the user terminal, wherein the screen projection instruction includes at least a border size, so that the user terminal scales the terminal video frame according to the border size, adds a video border adapted to the border size, compresses the terminal video frame after adding the video border, compresses and generates a video data packet to be projected and returns it.
[0064] Receive the video data packet to be projected.
[0065] In an embodiment of the present invention, after the user terminal device establishes communication with the vehicle computer, the vehicle computer may send a screen projection instruction to the user terminal, wherein the screen projection instruction is used to send an instruction to the user terminal to start transmitting video data. After receiving the screen projection instruction, the user terminal sends the video data to the vehicle computer, plays the video data on the vehicle computer, and enables the user to see the video data displayed on the user terminal based on the vehicle computer screen and operate the user terminal based on the vehicle computer screen. The screen projection instruction may include the border size.
[0066] In other words, the border size can be calculated by the car computer according to the encoded video resolution and the car computer screen resolution after obtaining the encoded video resolution supported by the user terminal device. Therefore, the user terminal can directly scale the terminal video frame according to the border size, add a video border adapted to the border size, compress the terminal video frame after adding the video border, compress and generate a video data packet to be projected and send it to the car computer. After receiving the video data packet to be projected, the car computer performs the next decoding operation.
[0067] In summary, an embodiment of the present invention provides a method for video screen projection, which may include first receiving a video data packet to be projected, and then decoding the video data packet to obtain multiple target video frames and the border size of the video border corresponding to each target video frame, wherein the border size is determined according to the screen resolution of the vehicle computer. Then, based on the border size, all corresponding border pixels in the target video frame are determined, and finally each frame of the target video frame is projected, wherein all border pixels in the target video frame are in a hidden state. Therefore, after receiving each packet of video data, it only needs to be decoded and played, and no additional operations are required on the video data, thereby improving the smoothness of video playback and reducing the performance occupancy rate when projecting the vehicle computer.
[0068] The video screen projection method described in the above-mentioned embodiments of the invention can be applied to a car computer, and the function used in the screen projection can be the car computer and mobile phone interconnection function. This function is pre-integrated in the car's central control screen.
[0069] It should be noted that, for the method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the embodiments of the present application are not limited by the described order of actions, because according to the embodiments of the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present application.
[0070] Reference Figure 4 , shows a video screen projection device provided by an embodiment of the present invention, the device may include:
[0071] The data packet receiving module 401 is used to receive the video data packet to be projected.
[0072] The data decoding module 402 is used to decode the video data packet to obtain multiple target video frames and the frame size of the video frame corresponding to each target video frame, wherein the frame size is determined according to the screen resolution of the vehicle computer.
[0073] The border pixel determination module 403 is used to determine all corresponding border pixel points in each target video frame according to the border size.
[0074] The video frame screen projection module 404 is used to project each target video frame, wherein all the border pixels in the target video frame are in a hidden state.
[0075] In an optional embodiment of the invention, the data packet receiving module 401 may include:
[0076] The first instruction sending submodule is used to send a screen projection instruction to the user terminal, wherein the screen projection instruction includes at least the vehicle screen resolution, so that the user terminal adds a video border to the terminal video frame according to the vehicle screen resolution, and compresses the terminal video frame after adding the video border, compresses and generates a video data packet to be projected and returns it.
[0077] The data packet receiving submodule is used to receive the video data packet to be projected.
[0078] In an optional embodiment of the invention, the border pixel determination module 403 may include:
[0079] A pixel point determination submodule, used for selecting one of the four vertices of the target video frame as a target pixel point;
[0080] The border pixel point determination submodule is used to determine all corresponding border pixel points in the target video frame according to the target pixel points and the border size.
[0081] In an optional embodiment of the invention, the video frame projection module 404 may include:
[0082] The display interface provides a submodule, which is used to provide a display interface, and the interface resolution of the display interface is greater than the resolution of the vehicle computer screen.
[0083] The target display submodule is used to project each target video frame in the display interface.
[0084] The pixel hiding submodule is used to move the display interface after projection until all the border pixels of the target video frame displayed in the display interface are in a hidden state.
[0085] In an optional embodiment of the invention, the target display submodule may include:
[0086] An interface covering unit is used to cover the display interface of the vehicle computer through the display interface.
[0087] The target display unit is used to project each target video frame on the display interface.
[0088] In an optional embodiment of the invention, the pixel hiding submodule may further include:
[0089] The interface moving unit is used to move the display interface and detect whether multiple target border pixel points in the target video frame coincide with interface vertices in corresponding directions in the display interface, wherein the target border pixel points refer to inner vertices corresponding to the video border.
[0090] The pixel hiding unit is used to stop moving the display interface when the target pixel coincides with the interface vertex, and determine that all the border pixels in the target video frame are in a hidden state.
[0091] In an optional embodiment of the invention, the data packet receiving module 401 may further include:
[0092] The second instruction sending submodule is used to send a screen projection instruction to the user terminal, wherein the screen projection instruction includes at least a border size, so that the user terminal scales the terminal video frame according to the border size, adds a video border adapted to the border size, compresses the terminal video frame after adding the video border, compresses and generates a video data packet to be projected and returns it.
[0093] The data packet receiving submodule is used to receive the video data packet to be projected.
[0094] In summary, an embodiment of the present invention provides a video screen projection device, which may include first receiving a video data packet to be projected, and then decoding the video data packet to obtain multiple target video frames and the border size of the video border corresponding to each target video frame, wherein the border size is determined according to the screen resolution of the vehicle computer. Then, based on the border size, all corresponding border pixels in the target video frame are determined, and finally each frame of the target video frame is projected, wherein all border pixels in the target video frame are in a hidden state. Therefore, after receiving each packet of video data, it only needs to be decoded and played, and no additional operations are required on the video data, thereby improving the smoothness of video playback and reducing the performance occupancy rate when projecting the vehicle computer.
[0095] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0096] It is easy for a person skilled in the art to think that any combination of the above embodiments is feasible, so any combination of the above embodiments is an implementation scheme of the present invention. However, due to space limitations, this specification will not describe them in detail here.
[0097] In the description provided herein, a large number of specific details are described. However, it is understood that embodiments of the present invention can be practiced without these specific details. In some instances, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this description.
[0098] Similarly, it should be understood that in order to streamline the present invention and aid in understanding one or more of the various inventive aspects, in the above description of exemplary embodiments of the present invention, various features of the present invention are sometimes grouped together into a single embodiment, figure, or description thereof. However, this disclosed method should not be interpreted as reflecting the intention that the claimed invention requires more features than those expressly recited in each claim. Rather, as reflected in the claims, inventive aspects lie in less than all of the features of the individual embodiments previously disclosed. Therefore, the claims that follow the detailed description are hereby expressly incorporated into the detailed description, with each claim itself serving as a separate embodiment of the present invention.
[0099] Those skilled in the art will appreciate that the modules in the devices in the embodiments may be adaptively changed and arranged in one or more devices different from the embodiments. The modules or units or components in the embodiments may be combined into one module or unit or component, and in addition they may be divided into a plurality of submodules or subunits or subcomponents. Except that at least some of such features or processes or units are mutually exclusive, all features disclosed in this specification (including the accompanying claims, abstracts and drawings) and all processes or units of any method or device disclosed in this manner may be combined in any combination. Unless otherwise expressly stated, each feature disclosed in this specification (including the accompanying claims, abstracts and drawings) may be replaced by an alternative feature providing the same, equivalent or similar purpose.
[0100] An electronic device, comprising:
[0101] one or more processors;
[0102] Memory;
[0103] One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method described in the above embodiment.
[0104] A computer-readable storage medium stores a computer program used in combination with an electronic device, wherein the computer program can be executed by a processor to implement the method described in the above embodiment.
[0105] It will be appreciated by those skilled in the art that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0106] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0107] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0108] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0109] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.
[0110] Finally, 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 terminal 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 terminal 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 terminal device including the elements.
[0111] The video projection method and the video projection device provided by the present invention are introduced in detail above. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
Claims
1. A video screen projection method, characterized in that: The method comprises: Sending a screen projection instruction to the user terminal, wherein the screen projection instruction at least includes the vehicle screen resolution, so that the user terminal adds a video border to the terminal video frame according to the vehicle screen resolution, and compresses the terminal video frame after adding the video border, compresses and generates a video data packet to be projected, and returns it; The method of enabling the user terminal to add a video border to the terminal video frame according to the vehicle computer screen resolution includes: Determining a proportionality factor according to the resolution of the user terminal video and the resolution of the vehicle computer screen; Scaling the horizontal resolution or the vertical resolution of the user terminal video according to the scaling factor; Determine the number of horizontal pixels or vertical pixels that need to be added to the edge of the user terminal video according to the horizontal resolution or vertical resolution of the vehicle screen, the horizontal resolution or vertical resolution of the user terminal video after scaling, and the proportional coefficient; Adding horizontal pixel points or vertical pixel points at the edge of the user terminal video to add a video border according to the horizontal pixel points or vertical pixel points that need to be added at the edge of the user terminal video; Receive the video data packet to be projected; Decoding the video data packet to obtain multiple target video frames and the frame size of the video frame corresponding to each target video frame, wherein the frame size is determined according to the screen resolution of the vehicle computer; Determine all border pixel points in each target video frame according to the border size; Each target video frame is projected onto the screen, wherein all border pixels in the target video frame are in a hidden state.
2. The video screen projection method according to claim 1, characterized in that: Determining all corresponding border pixel points in the target video frame according to the border size includes: Selecting one of the four vertices of the target video frame as a target pixel point; According to the target pixel points and the frame size, all corresponding frame pixel points in the target video frame are determined.
3. The video screen projection method according to claim 2, characterized in that: The projecting of each target video frame includes: Providing a display interface, wherein the interface resolution of the display interface is greater than the resolution of the vehicle computer screen; Projecting each target video frame on the display interface; The display interface after projection is moved until all border pixels of the target video frame displayed in the display interface are in a hidden state.
4. The video screen projection method according to claim 3, characterized in that: The projecting of each target video frame in the display interface includes: Covering the display interface of the vehicle computer with the display interface; Each target video frame is projected on the display interface.
5. The video screen projection method according to claim 4, characterized in that: The step of moving the projection display interface until all border pixels of the target video frame displayed in the display interface are in a hidden state includes: The display interface is moved, and a plurality of target border pixel points in the target video frame are detected to determine whether they coincide with interface vertices in corresponding directions in the display interface, wherein the target border pixel points refer to inner vertices corresponding to the video border; When the target pixel point coincides with the interface vertex, the display interface is stopped from moving, and it is determined that all the border pixel points in the displayed target video frame are in a hidden state.
6. The video screen projection method according to claim 1, characterized in that: The receiving of the video data packet to be projected includes: Sending a screen projection instruction to the user terminal, wherein the screen projection instruction includes at least a frame size, so that the user terminal scales the terminal video frame according to the frame size, adds a video frame adapted to the frame size, compresses the terminal video frame after adding the video frame, compresses and generates a video data packet to be projected, and returns the compressed data packet; Receive the video data packet to be projected.
7. A video projection device, characterized in that: The device comprises: A data packet receiving module, used to receive video data packets to be projected; A data decoding module, used for decoding the video data packet to obtain multiple target video frames and the frame size of the video frame corresponding to each target video frame, wherein the frame size is determined according to the screen resolution of the vehicle computer; A border pixel determination module, used to determine all corresponding border pixel points in the target video frame according to the border size; A video frame projection module is used to project each target video frame, wherein all border pixels in the target video frame are in a hidden state; Wherein, the data packet receiving module includes: The first instruction sending submodule is used to send a screen projection instruction to the user terminal, wherein the screen projection instruction at least includes the vehicle screen resolution, so that the user terminal adds a video border to the terminal video frame according to the vehicle screen resolution, and compresses the terminal video frame after adding the video border, compresses and generates a video data packet to be projected, and returns it; The method of enabling the user terminal to add a video border to the terminal video frame according to the vehicle computer screen resolution includes: Determining a proportionality factor according to the resolution of the user terminal video and the resolution of the vehicle computer screen; Scaling the horizontal resolution or the vertical resolution of the user terminal video according to the scaling factor; Determine the number of horizontal pixels or vertical pixels that need to be added to the edge of the user terminal video according to the horizontal resolution or vertical resolution of the vehicle screen, the horizontal resolution or vertical resolution of the user terminal video after scaling, and the proportional coefficient; Adding horizontal pixel points or vertical pixel points at the edge of the user terminal video to add a video border according to the horizontal pixel points or vertical pixel points that need to be added at the edge of the user terminal video; The data packet receiving submodule is used to receive the video data packet to be projected.
8. An electronic device comprising: one or more processors; Memory; One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method according to any one of claims 1 to 6.
9. A computer-readable storage medium storing a computer program for use in conjunction with an electronic device, wherein the computer program can be executed by a processor to implement the method of any one of claims 1 to 6.
Citation Information
Patent Citations
Image display method and device
CN111212310A