Audio transmission method, audio playback method, storage medium and related equipment
By converting audio data into visual data and collecting and playing it through the camera, it solves the problem of audio transmission occupying channel resources, improves transmission efficiency and supports simultaneous transmission by multiple devices, enhancing the flexibility and privacy of audio transmission.
Patent Information
- Application Number
- CN202111632207.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-28
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2041-12-28
AI Technical Summary
Existing audio transmission technology occupies a large number of channel resources, resulting in low transmission efficiency. Especially when the audio quality is improved, the amount of transmitted data is large and the resources are seriously occupied.
Convert audio data into visual data, generate visual data through descriptor images and sampling point grayscale images, and collect and play through the camera to avoid directly occupying channel resources.
It achieves resource saving in the audio transmission process, improves transmission efficiency, and supports multiple audio playback devices to transmit audio at the same time, enhancing the flexibility and privacy of audio transmission.
Smart Images

Figure CN114338622B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of audio transmission, and in particular to an audio transmission method, an audio playback method, a storage medium and related equipment. Background Art
[0002] VR (Virtual Reality) devices, AR devices and other electronic devices can receive and play audio transmitted by other devices. Currently, audio data is usually transmitted directly through channels. However, as the quality of audio improves, the amount of audio data that needs to be transmitted is larger, and the transmission process requires more channel resources.
[0003] Therefore, how to avoid the occupation of channel resources by audio transmission and improve the efficiency of audio transmission is a technical problem that technical personnel in this field currently need to solve. Summary of the invention
[0004] The purpose of this application is to provide an audio transmission method, an audio transmission device, an audio playback method, an audio playback device, a storage medium and an electronic device, which can avoid the occupation of channel resources by audio transmission and improve the efficiency of audio transmission.
[0005] In order to solve the above technical problems, the present application provides an audio transmission method, which is applied to an audio transmission device, comprising:
[0006] Determine target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data;
[0007] Convert the audio header information into a descriptor image, and convert the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows;
[0008] Generate visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image;
[0009] The visual data is displayed so that the audio playback device uses a camera to collect the visual data and plays the audio corresponding to the visual data.
[0010] Optionally, determining the target audio PCM data includes:
[0011] Determine a plurality of target audio PCM data corresponding to the plurality of audio playback devices;
[0012] Accordingly, generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image includes:
[0013] Generate visual sub-data corresponding to each target audio PCM data according to the descriptor image and the sampling point grayscale image;
[0014] All the visual sub-data are spliced together to obtain the visual data.
[0015] Optionally, before displaying the visual data, the method further includes:
[0016] A grayscale contrast area is added to the visual data so that the audio playback device can perform deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value.
[0017] Optionally, converting the audio header information into a descriptor image includes:
[0018] Querying a user key corresponding to the target audio PCM data, and using the user key to encrypt the audio header information to obtain a descriptor vector;
[0019] The descriptor image corresponding to the descriptor vector is generated.
[0020] Optionally, converting the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows comprises:
[0021] Converting the sampling point data into a corresponding byte stream according to the sampling depth of the target audio PCM data;
[0022] A corresponding grayscale window is created for each byte in the byte stream, and the value of the byte is set as the grayscale value of the grayscale window to obtain the grayscale image of the sampling point.
[0023] The present application also provides an audio playback method, which is applied to an audio playback device, comprising:
[0024] The visual data displayed by the audio transmission device is collected by using a camera; wherein the process of the audio transmission device displaying the visual data comprises: determining target audio PCM data; wherein the target audio PCM data comprises audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image comprising a plurality of grayscale windows; generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; and displaying the visual data;
[0025] converting the descriptor image in the visual data into the audio header information;
[0026] Converting the sampling point grayscale image into the sampling point data according to the audio header information;
[0027] The audio corresponding to the target audio PCM data is played according to the sampling point data.
[0028] Optionally, converting the descriptor image in the visual data into the audio header information comprises:
[0029] Generate a descriptor vector corresponding to the descriptor image; wherein the generation process of the descriptor image is: query the user key corresponding to the target audio PCM data, and use the user key to encrypt the audio header information to obtain the descriptor vector, and generate the descriptor image corresponding to the descriptor vector;
[0030] Decrypting the descriptor vector using the target user key corresponding to the audio playback device, and determining whether the descriptor vector is successfully decrypted;
[0031] If so, the audio header information is determined according to the decryption result.
[0032] Optionally, converting the sampling point grayscale image into the sampling point data according to the audio header information includes:
[0033] Determine a header index, a sampling rate, and a sampling depth according to the audio header information;
[0034] Performing grayscale segmentation on the grayscale image of the sampling point to obtain a plurality of grayscale windows, and calculating the grayscale value corresponding to each grayscale window;
[0035] The grayscale values corresponding to all grayscale windows are converted into the sampling point data using the head index, the sampling rate and the sampling depth.
[0036] Optionally, calculating the grayscale value corresponding to each grayscale window includes:
[0037] Determine a measured grayscale value and an actual grayscale value of a grayscale contrast area in the visual data, and determine a grayscale measurement deviation according to the measured grayscale value and the actual grayscale value of the grayscale contrast area;
[0038] The grayscale measurement deviation is used to perform deviation correction on the measured grayscale values of the grayscale windows to obtain the grayscale value corresponding to each of the grayscale windows.
[0039] The present application also provides an audio transmission device, comprising:
[0040] A data determination module, used to determine target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data;
[0041] An audio conversion module, used for converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows;
[0042] A visual data generating module, used for generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image;
[0043] The display module is used to display the visual data so that the audio playback device can use a camera to collect the visual data and play the audio corresponding to the visual data.
[0044] The present application also provides an audio playback device, comprising:
[0045] A visual data acquisition module, used for acquiring visual data displayed by an audio transmission device using a camera; wherein the process of displaying the visual data by the audio transmission device comprises: determining target audio PCM data; wherein the target audio PCM data comprises audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image comprising a plurality of grayscale windows; generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; and displaying the visual data;
[0046] a header information conversion module, configured to convert the descriptor image in the visual data into the audio header information;
[0047] A sampling point data conversion module, used for converting the sampling point grayscale image into the sampling point data according to the audio header information;
[0048] The audio playing module is used to play the audio corresponding to the target audio PCM data according to the sampling point data.
[0049] The present application also provides a storage medium on which a computer program is stored. When the computer program is executed, the steps of the above-mentioned audio transmission method and / or the above-mentioned audio playback method are implemented.
[0050] The present application also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and when the processor calls the computer program in the memory, the steps executed by the above-mentioned audio transmission method and / or the above-mentioned audio playback method are implemented.
[0051] The present application provides an audio transmission method, which is applied to an audio transmission device, including: determining target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image containing multiple grayscale windows; generating visual data corresponding to the target audio PCM data based on the descriptor image and the sampling point grayscale image; and displaying the visual data so that an audio playback device uses a camera to collect the visual data and play the audio corresponding to the visual data.
[0052] The present application converts the audio header information of the target audio PCM data into a descriptor image, converts the sampling point data of the target audio PCM data into a sampling point grayscale image, and then generates corresponding visual data based on the descriptor image and the sampling point grayscale image. The target audio PCM data can be converted into visual data in the above manner. After displaying the visual data, the audio playback device can use the visual data collected by the camera to play the corresponding audio. The present embodiment converts the transmission process of audio data into the transmission process of visual data without occupying channel resources, can avoid the occupation of channel resources by audio transmission, and improves the efficiency of audio transmission. The present application also provides an audio transmission device, an audio playback method, an audio playback device, a storage medium and an electronic device, which have the above-mentioned beneficial effects and are not repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0054] Figure 1 A flowchart of an audio transmission method provided in an embodiment of the present application;
[0055] Figure 2 A schematic diagram of video data provided by an embodiment of the present application;
[0056] Figure 3 A schematic diagram of a visual data structure in a scenario where three audio frequencies are transmitted simultaneously provided by an embodiment of the present application;
[0057] Figure 4 A schematic diagram of a visual data structure including a grayscale contrast area provided in an embodiment of the present application;
[0058] Figure 5 A flowchart of an audio transmission method provided in an embodiment of the present application;
[0059] Figure 6 A flowchart of a method for performing directional one-to-many audio transmission using visual information provided by an embodiment of the present application;
[0060] Figure 7 A schematic diagram of the structure of a grayscale video stream provided in an embodiment of the present application;
[0061] Figure 8 A schematic diagram of the structure of an audio transmission device provided in an embodiment of the present application;
[0062] Fig. 9 A schematic diagram of the structure of an audio playback device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0063] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are 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 without creative work are within the scope of protection of this application.
[0064] See below Figure 1 , Figure 1 A flowchart of an audio transmission method provided in an embodiment of the present application.
[0065] Specific steps may include:
[0066] S101: Determine target audio PCM data;
[0067] Among them, this embodiment can be applied to an audio transmission device, which can play an audio playback device. The target audio PCM (Pulse Code Modulation) data is the audio that the audio playback device needs to play, and the target audio PCM data includes audio header information and sampling point data. The audio header information may include a header index, a sampling rate, and a sampling depth. The audio playback device can sample the sampling point data according to the audio header information, and then play the corresponding audio according to the sampling result. The above-mentioned header index is used to indicate the starting position of the sampling.
[0068] S102: converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows;
[0069] Among them, this embodiment can map the audio header information into a corresponding vector, and then generate a corresponding descriptor image based on the vector. This embodiment can pre-set the conversion relationship between the audio header information and the descriptor image, and generate a corresponding descriptor image based on the conversion relationship. In order to improve the recognition efficiency of the descriptor image, the descriptor image can be a grayscale image. The descriptor images corresponding to different audio header information are different, and the audio header information can be reversely derived according to the descriptor image. The audio sampling point data can include multiple sampling points. This embodiment can synthesize N sampling points into one byte according to the sampling depth to obtain a byte stream corresponding to the sampling point data. Each byte in the byte stream corresponds to a grayscale window, and the grayscale value of each grayscale window is the value of the corresponding byte. Specifically, this embodiment can convert the sampling point data into a corresponding byte stream according to the sampling depth of the target audio PCM data; create a corresponding grayscale window for each byte in the byte stream, and set the value of the byte to the grayscale value of the grayscale window to obtain the sampling point grayscale image. The arrangement order of the grayscale windows in the grayscale image is the same as the arrangement order of each byte in the byte stream. With a sampling depth of 16 bits, two sampling points can be combined into one byte, which corresponds to a grayscale window. The value range of the byte is 0 to 255, and the value of the byte is the grayscale value of the grayscale window. The grayscale values of all pixels in the grayscale window are the same.
[0070] S103: Generate visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image;
[0071] In this embodiment, the descriptor image and the grayscale image can be spliced to obtain the visual data corresponding to the target audio PCM data. The visual data can be an image data or a video data including multiple frames of images. Figure 2 , Figure 2 A schematic diagram of video data provided in an embodiment of the present application.
[0072] S104: Display the visual data so that the audio playback device can collect the visual data using a camera and play the audio corresponding to the visual data.
[0073] Among them, after obtaining the visual data, the visual data can be displayed using the display screen of the audio transmission device. Specifically, if the visual data is an image data, the image can be displayed; if the visual data is video data, each frame of the video data can be displayed in sequence. The audio playback device can use a camera to shoot in order to collect visual data. After the audio playback device obtains the visual data, it can parse the audio header information from the visual data, and convert the sampling point grayscale image into the sampling point data according to the audio header information, so as to play the corresponding audio.
[0074] This embodiment converts the audio header information of the target audio PCM data into a descriptor image, converts the sampling point data of the target audio PCM data into a sampling point grayscale image, and then generates corresponding visual data based on the descriptor image and the sampling point grayscale image. The target audio PCM data can be converted into visual data in the above manner. After displaying the visual data, the audio playback device can use the visual data collected by the camera to play the corresponding audio. This embodiment converts the transmission process of audio data into the transmission process of visual data, without occupying channel resources, can avoid the occupation of channel resources by audio transmission, and improves the efficiency of audio transmission.
[0075] As a feasible implementation method, Figure 1 The corresponding embodiment can convert multiple target audio PCM data into the same visual data so as to transmit audio to multiple audio playback devices at the same time. Specifically, the above embodiment can determine multiple target audio PCM data corresponding to multiple audio playback devices, and then generate a descriptor image and a sampling point grayscale image for each target audio PCM data. The visual sub-data corresponding to each target audio PCM data is generated according to the descriptor image and the sampling point grayscale image; all the visual sub-data are spliced to obtain the visual data. Please refer to Figure 3 , Figure 3 A schematic diagram of a visual data structure in a scenario of simultaneous transmission of three audios provided by an embodiment of the present application. At this time, audio playback device 1 can play the corresponding audio 1 according to the visual sub-data in the same row of descriptor image 1, audio playback device 2 can play the corresponding audio 2 according to the visual sub-data in the same row of descriptor image 2, and audio playback device 3 can play the corresponding audio 3 according to the visual sub-data in the same row of descriptor image 3.
[0076] As a feasible implementation, before displaying the visual data, a grayscale contrast area may be added to the visual data so that the audio playback device can perform deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value (such as a grayscale value of 0). Specifically, the grayscale contrast area is set between the descriptor image and the sampling point grayscale image. Since the grayscale value collected by the camera will be affected by the ambient light intensity, this embodiment provides a grayscale contrast area with a grayscale value of a preset value to correct the detected grayscale deviation. Please refer to Figure 4 , Figure 4 A schematic diagram of a visual data structure including a grayscale contrast area provided in an embodiment of the present application.
[0077] As a feasible implementation method, this embodiment can convert the audio header information into a descriptor image in the following manner: query the user key corresponding to the target audio PCM data, and use the user key to encrypt the audio header information to obtain a descriptor vector; generate the descriptor image corresponding to the descriptor vector. In the above embodiment, the audio playback device, the target audio PCM data and the user key have a preset corresponding relationship. By using the user key to encrypt the audio header information, only a specific audio playback device can correctly decrypt the descriptor vector, thereby improving the privacy of audio transmission.
[0078] See below Figure 5 , Figure 5 A flowchart of an audio transmission method provided in an embodiment of the present application.
[0079] Specific steps may include:
[0080] S501: using a camera to collect visual data displayed by an audio transmission device;
[0081] This embodiment can be applied to an audio playback device, which can be Figure 1 The audio playback device in the corresponding embodiment, the visual data is Figure 1 The visual data displayed by the audio transmission device in the corresponding embodiment.
[0082] The process of the audio transmission device displaying the visual data includes: determining the target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image containing multiple grayscale windows; generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image, and displaying the visual data.
[0083] S502: Convert the descriptor image in the visual data into the audio header information;
[0084] In this step, the descriptor image in the visual data may be converted into the audio header information according to the inverse process of the audio transmission device generating the descriptor image.
[0085] Specifically, the generation process of the above-mentioned descriptor image is as follows: querying the user key corresponding to the target audio PCM data, and using the user key to encrypt the audio header information to obtain the descriptor vector, and generating the descriptor image corresponding to the descriptor vector. On the basis that the descriptor image is encrypted, the descriptor image in the visual data can be converted into the audio header information in the following manner: generating a descriptor vector corresponding to the descriptor image; decrypting the descriptor vector using the target user key corresponding to the audio playback device, and determining whether the descriptor vector is successfully decrypted; if so, determining the audio header information according to the decryption result.
[0086] S503: Converting the sampling point grayscale image into the sampling point data according to the audio header information;
[0087] Based on the audio header information, this step can determine the header index, sampling rate and sampling depth according to the audio header information; perform grayscale segmentation on the sampling point grayscale image to obtain multiple grayscale windows, and calculate the grayscale value corresponding to each grayscale window; use the header index, the sampling rate and the sampling depth to convert the grayscale values corresponding to all grayscale windows into the sampling point data.
[0088] As a feasible implementation method, the audio transmission device can add M (such as 3) reference grayscale windows to the head of the sampling point grayscale image, and the grayscale value difference between the reference grayscale windows is a fixed value. This embodiment can determine whether the grayscale value difference between the first M grayscale windows is a fixed value; if so, the grayscale segmentation is determined to be successful, and the operation of converting the grayscale values corresponding to all grayscale windows into the sampling point data using the head index, sampling rate and sampling depth is entered; if not, the grayscale segmentation is determined to have failed, and a prompt message of grayscale segmentation failure can be sent to the audio transmission device at this time, so that the audio transmission device can increase the size of the grayscale window in the visual data.
[0089] Specifically, if there is a grayscale contrast area in the visual data, this embodiment can calculate the grayscale value corresponding to each grayscale window in the following way: determine the measured grayscale value and the actual grayscale value of the grayscale contrast area in the visual data, and determine the grayscale measurement deviation based on the measured grayscale value and the actual grayscale value of the grayscale contrast area; use the grayscale measurement deviation to correct the deviation of the measured grayscale value of the grayscale window to obtain the grayscale value corresponding to each grayscale window.
[0090] S504: Play the audio corresponding to the target audio PCM data according to the sampling point data.
[0091] This embodiment uses visual data collected by a camera, and uses the visual data to play the corresponding audio. The audio transmission device converts the audio header information of the target audio PCM data into a descriptor image, converts the sampling point data of the target audio PCM data into a sampling point grayscale image, and then generates corresponding visual data based on the descriptor image and the sampling point grayscale image. The target audio PCM data can be converted into visual data in the above manner. This embodiment converts the audio data transmission process into the visual data transmission process, without occupying channel resources, and can avoid the occupation of channel resources by audio transmission, thereby improving the audio transmission efficiency.
[0092] The process described in the above embodiment is explained below through an embodiment in actual application.
[0093] In the related technologies, audio transmission has the disadvantages of large amount of transmitted data, poor privacy, and large amount of channel resources occupied during the transmission process. In addition, current external speaker products can only play a single channel when playing sound sources, have poor privacy and targeting, and cannot dynamically and flexibly select audio receiving objects.
[0094] In order to solve the defects in the above-mentioned related technologies, this application transmits audio data in a visual method through grayscale visual information, which can achieve targeted audio transmission and low resource consumption. Figure 6 , Figure 6 This is a flowchart of a method for using visual information to perform audio directional one-to-many transmission provided by an embodiment of the present application. This embodiment transmits audio information through visual information, reduces transmission costs, and makes the transmission method more flexible. It can transmit audio data in a one-to-many targeted manner, and specifically includes the following steps:
[0095] S601: Obtain the corresponding user key value from the server.
[0096] S602: The audio PCM data is digitally gray-scaled to obtain a gray-scale video stream (ie, visual data) carrying the audio data.
[0097] S603: The display device plays the grayscale video stream carrying the audio data according to the set grayscale window size.
[0098] S604: The VR / AR head display or other audio playback device captures a grayscale video stream through a visual camera.
[0099] S605: The audio playback device determines whether the grayscale segmentation operation is completed; if so, the process proceeds to S606; if not, the process proceeds to S611.
[0100] S606: The audio playback device analyzes the captured grayscale video stream, extracts the pre-stored key value and the feature description vector of the ID identification area, and performs verification and decryption operations.
[0101] S607: Determine whether the ID verification is successful; if so, proceed to S608; if not, continue to traverse other channels and perform verification in the ID recognition area.
[0102] S608: Decrypt the header index of the audio PCM data.
[0103] S609: Convert the grayscale value of the grayscale window into an audio PCM sampling point according to the header index, sampling rate and sampling depth.
[0104] S610: Storing the sampling points in the fifo area so as to retrieve the sampling points for playback.
[0105] S611: The audio playback device returns grayscale segmentation failure information to the display device through the wireless channel (spp / ble).
[0106] S612: Readjust the size of the two-dimensional grayscale window according to the feedback result, ie, the size of the audio data.
[0107] See also Figure 7 , Figure 7 A schematic diagram of the structure of a grayscale video stream provided in an embodiment of the present application, wherein the grayscale video stream includes multiple channels, each channel has corresponding audio PCM data and an audio playback device, and an ID identification area is provided with a descriptor image, the descriptor image includes circular feature points and annular descriptors, which are used to identify the user to whom the audio belongs and bind the audio header information (channel, sampling rate, sampling depth). The grayscale contrast area is a color block with a grayscale value of 0, and the grayscale value corresponding to a grayscale window represents 1 byte in the audio sampling point. Index represents the index value of the grayscale window, and the grayscale value corresponding to a grayscale window represents 1 byte in the audio sampling point. Figure 7 The numbers in the Mid-Gray window represent grayscale values.
[0108] This embodiment provides a solution for accurately extracting grayscale window values in different scenes through grayscale contrast areas. Figure 7 When performing grayscale extraction in the grayscale window, the grayscale information in the grayscale contrast area can be used according to the following formula to calculate the grayscale value offset caused by factors such as lighting, thereby ensuring that accurate grayscale values can be extracted for audio data conversion in different lighting scenes. The formula for calculating the grayscale value is as follows:
[0109] G=g+g offset ;
[0110] In the above formula, G is Figure 7 The final grayscale value of each grayscale window in , g is the intuitive grayscale value directly extracted from the grayscale window, g offsetThe offset calibration value is obtained by subtracting 0 (pure black) from the grayscale value of the grayscale contrast area of the channel. Because the preset value of the grayscale contrast area is pure black, if a certain grayscale increase occurs (black becomes lighter) due to factors such as lighting, then this increased grayscale value is the offset value. Due to the limited change in local lighting, this offset value can be used to calibrate the intuitive grayscale value of the channel as described in the above formula.
[0111] Figure 6 The user key value in is the key that exists in the server and is agreed upon by the user. This key is used to generate the descriptor of the ID area based on a certain encryption algorithm. The user can also use this key value to decrypt the descriptor of the ID area. The decryption result is a 2D vector, indicating whether the decryption is successful or not and the serial number of the starting grayscale window, as shown in the following formula:
[0112]
[0113] In the above formula, The encryption and decryption algorithm is preset and selected according to the security level requirements. (r, i) is the two-dimensional decryption result, r indicates the decryption success mark, and i indicates the serial number of the starting grayscale window. Taking the audio data with a conventional 16k sampling rate and 16bit sampling depth as an example, each sampling point is composed of two bytes (corresponding to two grayscale windows in this embodiment), and these two bytes have high and low bits. If the starting byte of a continuous audio data stream is wrong, the subsequent sampling points will not get the correct audio stream because of the continuous inversion of high and low bits, thus playing a certain role in security encryption. d That is the descriptor vector of the ID identification area, k d are user key vectors, and the subscript d indicates the dimension of these vectors. The higher the dimension, the higher the security level. The privacy of audio transmission is improved in the above manner.
[0114] See also Figure 8 , Figure 8 A schematic diagram of the structure of an audio transmission device provided in an embodiment of the present application;
[0115] The equipment may include:
[0116] The data determination module 801 is used to determine the target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data;
[0117] An audio conversion module 802, configured to convert the audio header information into a descriptor image, and convert the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows;
[0118] A visual data generating module 803, configured to generate visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image;
[0119] The display module 804 is used to display the visual data so that the audio playback device can use a camera to collect the visual data and play the audio corresponding to the visual data.
[0120] This embodiment converts the audio header information of the target audio PCM data into a descriptor image, converts the sampling point data of the target audio PCM data into a sampling point grayscale image, and then generates corresponding visual data based on the descriptor image and the sampling point grayscale image. The target audio PCM data can be converted into visual data in the above manner. After displaying the visual data, the audio playback device can use the visual data collected by the camera to play the corresponding audio. This embodiment converts the transmission process of audio data into the transmission process of visual data, without occupying channel resources, can avoid the occupation of channel resources by audio transmission, and improves the efficiency of audio transmission.
[0121] Furthermore, the data determination module 801 is used to determine a plurality of target audio PCM data corresponding to the plurality of audio playback devices;
[0122] Correspondingly, the visual data generating module 803 is used to generate visual sub-data corresponding to each of the target audio PCM data according to the descriptor image and the sampling point grayscale image; and to splice all the visual sub-data to obtain the visual data.
[0123] Furthermore, it also includes:
[0124] A grayscale contrast area setting module is used to add a grayscale contrast area to the visual data before displaying the visual data, so that the audio playback device can perform deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value.
[0125] Furthermore, the audio conversion module 802 includes:
[0126] The descriptor image generating unit is used to query the user key corresponding to the target audio PCM data, and use the user key to encrypt the audio header information to obtain a descriptor vector; and is also used to generate the descriptor image corresponding to the descriptor vector.
[0127] And / or, a sampling point grayscale image generation unit, used to convert the sampling point data into a corresponding byte stream according to the sampling depth of the target audio PCM data; and also used to create a corresponding grayscale window for each byte in the byte stream, and set the value of the byte to the grayscale value of the grayscale window to obtain the sampling point grayscale image.
[0128] See also Fig. 9 , Fig. 9A schematic diagram of the structure of an audio playback device provided in an embodiment of the present application;
[0129] The equipment may include:
[0130] The visual data acquisition module 901 is used to use a camera to acquire visual data displayed by an audio transmission device; wherein the process of the audio transmission device displaying the visual data includes: determining target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image containing multiple grayscale windows; generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; and displaying the visual data;
[0131] A header information conversion module 902, configured to convert the descriptor image in the visual data into the audio header information;
[0132] A sampling point data conversion module 903, configured to convert the sampling point grayscale image into the sampling point data according to the audio header information;
[0133] The audio playing module 904 is used to play the audio corresponding to the target audio PCM data according to the sampling point data.
[0134] This embodiment uses visual data collected by a camera, and uses the visual data to play the corresponding audio. The audio transmission device converts the audio header information of the target audio PCM data into a descriptor image, converts the sampling point data of the target audio PCM data into a sampling point grayscale image, and then generates corresponding visual data based on the descriptor image and the sampling point grayscale image. The target audio PCM data can be converted into visual data in the above manner. This embodiment converts the audio data transmission process into the visual data transmission process, without occupying channel resources, and can avoid the occupation of channel resources by audio transmission, thereby improving the audio transmission efficiency.
[0135] Furthermore, the header information conversion module 902 is used to generate a descriptor vector corresponding to the descriptor image; wherein the generation process of the descriptor image is: querying the user key corresponding to the target audio PCM data, and using the user key to encrypt the audio header information to obtain the descriptor vector, and generating the descriptor image corresponding to the descriptor vector; and also used to decrypt the descriptor vector using the target user key corresponding to the audio playback device, and determine whether the descriptor vector is decrypted successfully; if so, determine the audio header information according to the decryption result.
[0136] Furthermore, the sampling point data conversion module 903 is used to determine the header index, sampling rate and sampling depth according to the audio header information; it is also used to perform grayscale segmentation on the sampling point grayscale image to obtain multiple grayscale windows, and calculate the grayscale value corresponding to each grayscale window; it is also used to use the header index, the sampling rate and the sampling depth to convert the grayscale values corresponding to all grayscale windows into the sampling point data.
[0137] Furthermore, the process of the sampling point data conversion module 903 calculating the grayscale value corresponding to each grayscale window includes: determining the measured grayscale value and the actual grayscale value of the grayscale contrast area in the visual data, and determining the grayscale measurement deviation according to the measured grayscale value and the actual grayscale value of the grayscale contrast area; using the grayscale measurement deviation to correct the deviation of the measured grayscale value of the grayscale window to obtain the grayscale value corresponding to each grayscale window.
[0138] The present application also provides a storage medium on which a computer program is stored, and when the computer program is executed, the steps provided in the above embodiment can be implemented. The storage medium may include: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program codes.
[0139] The present application also provides an electronic device, which may include a memory and a processor, wherein a computer program is stored in the memory, and when the processor calls the computer program in the memory, the steps provided in the above embodiment may be implemented. Of course, the electronic device may also include various network interfaces, power supplies and other components.
[0140] Since the embodiments of the device part correspond to the embodiments of the method part, please refer to the description of the embodiments of the method part for the embodiments of the device part, which will not be repeated here.
[0141] The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the various embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of this application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of this application.
[0142] It should also be noted that, in this specification, 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 "comprises", "comprising" 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, an element defined by the statement "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.
Claims
1. An audio transmission method, characterized in that: Applicable to audio transmission equipment, including: Determine target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data; Convert the audio header information into a descriptor image, and convert the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows; Generate visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; wherein the visual data corresponding to the target audio PCM data is obtained by splicing the descriptor image and the grayscale image; Displaying the visual data so that the audio playback device uses a camera to collect the visual data and plays the audio corresponding to the visual data; Before displaying the visual data, the method further includes: A grayscale contrast area is added to the visual data so that the audio playback device can perform deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value.
2. The audio transmission method according to claim 1, characterized in that: The determining of the target audio PCM data comprises: Determine a plurality of target audio PCM data corresponding to the plurality of audio playback devices; Accordingly, generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image includes: Generate visual sub-data corresponding to each target audio PCM data according to the descriptor image and the sampling point grayscale image; All the visual sub-data are spliced together to obtain the visual data.
3. The audio transmission method according to claim 1, characterized in that: Converting the audio header information into a descriptor image includes: Querying a user key corresponding to the target audio PCM data, and using the user key to encrypt the audio header information to obtain a descriptor vector; The descriptor image corresponding to the descriptor vector is generated.
4. The audio transmission method according to claim 1, characterized in that: The sampling point data is converted into a sampling point grayscale image containing a plurality of grayscale windows, including: Converting the sampling point data into a corresponding byte stream according to the sampling depth of the target audio PCM data; A corresponding grayscale window is created for each byte in the byte stream, and the value of the byte is set as the grayscale value of the grayscale window to obtain the grayscale image of the sampling point.
5. An audio playing method, characterized in that: Applicable to audio playback devices, including: The visual data displayed by the audio transmission device is collected by a camera; wherein the process of the audio transmission device displaying the visual data comprises: determining target audio PCM data; wherein the target audio PCM data comprises audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image comprising a plurality of grayscale windows; generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; displaying the visual data; before displaying the visual data, adding a grayscale contrast area to the visual data so that the audio playback device performs deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value; the visual data corresponding to the target audio PCM data is obtained by splicing the descriptor image and the grayscale image; converting the descriptor image in the visual data into the audio header information; Converting the sampling point grayscale image into the sampling point data according to the audio header information; The audio corresponding to the target audio PCM data is played according to the sampling point data.
6. The audio playback method according to claim 5, characterized in that: Converting the descriptor image in the visual data into the audio header information comprises: Generate a descriptor vector corresponding to the descriptor image; wherein the generation process of the descriptor image is: query the user key corresponding to the target audio PCM data, and use the user key to encrypt the audio header information to obtain the descriptor vector, and generate the descriptor image corresponding to the descriptor vector; Decrypting the descriptor vector using the target user key corresponding to the audio playback device, and determining whether the descriptor vector is successfully decrypted; If so, the audio header information is determined according to the decryption result.
7. The audio playback method according to claim 5, characterized in that: Converting the sampling point grayscale image into the sampling point data according to the audio header information includes: Determine a header index, a sampling rate, and a sampling depth according to the audio header information; Performing grayscale segmentation on the grayscale image of the sampling point to obtain a plurality of grayscale windows, and calculating the grayscale value corresponding to each grayscale window; The grayscale values corresponding to all grayscale windows are converted into the sampling point data using the head index, the sampling rate and the sampling depth.
8. The audio playback method according to claim 7, characterized in that: Calculating the grayscale value corresponding to each grayscale window includes: Determine a measured grayscale value and an actual grayscale value of a grayscale contrast area in the visual data, and determine a grayscale measurement deviation according to the measured grayscale value and the actual grayscale value of the grayscale contrast area; The grayscale measurement deviation is used to perform deviation correction on the measured grayscale values of the grayscale windows to obtain the grayscale value corresponding to each of the grayscale windows.
9. An audio transmission device, characterized in that: include: A data determination module, used to determine target audio PCM data; wherein the target audio PCM data includes audio header information and sampling point data; An audio conversion module, used for converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image containing a plurality of grayscale windows; A visual data generation module, used to generate visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; wherein the visual data corresponding to the target audio PCM data is obtained by splicing the descriptor image and the grayscale image; A display module, used to display the visual data so that the audio playback device can use a camera to collect the visual data and play the audio corresponding to the visual data; A grayscale contrast area setting module is used to add a grayscale contrast area to the visual data before displaying the visual data, so that the audio playback device can perform deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value.
10. An audio playback device, characterized in that: include: A visual data acquisition module, used for acquiring visual data displayed by an audio transmission device using a camera; wherein the process of the audio transmission device displaying the visual data comprises: determining target audio PCM data; wherein the target audio PCM data comprises audio header information and sampling point data; converting the audio header information into a descriptor image, and converting the sampling point data into a sampling point grayscale image comprising a plurality of grayscale windows; generating visual data corresponding to the target audio PCM data according to the descriptor image and the sampling point grayscale image; displaying the visual data; before displaying the visual data, adding a grayscale contrast area to the visual data so that the audio playback device performs deviation correction on the measured grayscale value according to the grayscale contrast area; wherein the grayscale value of the grayscale contrast area is a preset value; the visual data corresponding to the target audio PCM data is obtained by splicing the descriptor image and the grayscale image; a header information conversion module, configured to convert the descriptor image in the visual data into the audio header information; A sampling point data conversion module, used for converting the sampling point grayscale image into the sampling point data according to the audio header information; The audio playing module is used to play the audio corresponding to the target audio PCM data according to the sampling point data.
11. An electronic device, characterized in that: It comprises a memory and a processor, wherein the memory stores a computer program, and when the processor calls the computer program in the memory, it implements the steps of the audio transmission method according to any one of claims 1 to 4 and / or the audio playback method according to any one of claims 5 to 8.
12. A storage medium, characterized in that: The storage medium stores computer executable instructions, which, when loaded and executed by a processor, implement the steps of the audio transmission method according to any one of claims 1 to 4 and / or the audio playback method according to any one of claims 5 to 8.
Citation Information
Patent Citations
Audio processing method, device and storage medium
CN108281152A
Audio generation method and device
CN112863481A
