CN112181676B - Method, device, terminal equipment and readable storage medium for sharing recording data - Google Patents

Method, device, terminal equipment and readable storage medium for sharing recording data Download PDF

Info

Publication number
CN112181676B
CN112181676B CN202010872168.7A CN202010872168A CN112181676B CN 112181676 B CN112181676 B CN 112181676B CN 202010872168 A CN202010872168 A CN 202010872168A CN 112181676 B CN112181676 B CN 112181676B
Authority
CN
China
Prior art keywords
recording
program
service program
preset
instruction
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010872168.7A
Other languages
Chinese (zh)
Other versions
CN112181676A (en
Inventor
潘宇超
熊友军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Youbixuan Intelligent Robot Co ltd
Original Assignee
Ubtech Robotics Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ubtech Robotics Corp filed Critical Ubtech Robotics Corp
Priority to CN202010872168.7A priority Critical patent/CN112181676B/en
Publication of CN112181676A publication Critical patent/CN112181676A/en
Application granted granted Critical
Publication of CN112181676B publication Critical patent/CN112181676B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/545Interprogram communication where tasks reside in different layers, e.g. user- and kernel-space
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11BINFORMATION STORAGE BASED ON RELATIVE MOVEMENT BETWEEN RECORD CARRIER AND TRANSDUCER
    • G11B20/00Signal processing not specific to the method of recording or reproducing; Circuits therefor
    • G11B20/10Digital recording or reproducing
    • G11B20/10527Audio or video recording; Data buffering arrangements
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11BINFORMATION STORAGE BASED ON RELATIVE MOVEMENT BETWEEN RECORD CARRIER AND TRANSDUCER
    • G11B20/00Signal processing not specific to the method of recording or reproducing; Circuits therefor
    • G11B20/10Digital recording or reproducing
    • G11B20/10527Audio or video recording; Data buffering arrangements
    • G11B2020/10537Audio or video recording
    • G11B2020/10546Audio or video recording specifically adapted for audio data
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The application is applicable to the technical field of communication, and provides a method, a device, terminal equipment and a readable storage medium for sharing recording data, wherein the method comprises the following steps: receiving a first recording instruction, detecting a recording service program, calling the recording service program to acquire recording data and feeding back the recording data to a first application program corresponding to the first recording instruction when the recording service program is detected to be established and the working state of the recording service program is a non-recording state, receiving a second recording instruction, calling a preset socket program to access the recording service program to acquire the recording data, and feeding back the recording data to a second application program corresponding to the second recording instruction. The audio recording service program is accessed by calling the preset socket program corresponding to the name carried by the second audio recording instruction, and the obtained audio recording data is fed back to the second application program, so that the directional sharing operation of the audio recording data based on the multiple application programs is realized, the propagation speed and breadth of the audio and video and the safety of the audio recording data are improved, and the privacy of a user is ensured.

Description

Method, device, terminal equipment and readable storage medium for sharing recording data
Technical Field
The application belongs to the technical field of communication, and particularly relates to a method, a device, terminal equipment and a readable storage medium for sharing recording data.
Background
With the development of network information technology, audio and video data become an important information propagation medium.
The existing audio and video data is mainly generated through audio and video recording operation.
However, because the main control program of the existing system can only complete the recording task of a single thread, the propagation speed and the breadth of the audio and video are reduced, and the requirements of users cannot be met.
Disclosure of Invention
The embodiment of the application provides a method, a device, terminal equipment and a readable storage medium for sharing recording data, which can solve the problem that a main control program of the existing system can only complete a single-thread recording task, and reduce the propagation speed and breadth of audio and video.
In a first aspect, an embodiment of the present application provides a method for sharing recording data, including:
receiving a first recording instruction, and detecting a recording service program;
when the recording service program is detected to be established and the working state of the recording service program is a non-recording state, calling the recording service program to acquire recording data and feeding back the recording data to a first application program corresponding to the first recording instruction;
receiving a second recording instruction, calling a preset socket program to access the recording service program, and obtaining the recording data; wherein the second recording instruction comprises the name of the preset socket program;
and feeding the recording data back to a second application program corresponding to the second recording instruction.
In a second aspect, an embodiment of the present application provides an apparatus for sharing recording data, including:
the detection module is used for receiving the first recording instruction and detecting a recording service program;
the first feedback module is used for detecting that the recording service program is created, and the working state of the recording service program is a non-recording state, calling the recording service program to acquire recording data and feeding back the recording data to a first application program corresponding to the first recording instruction;
the calling module is used for receiving a second recording instruction, calling a preset socket program to access the recording service program and obtaining the recording data; wherein the second recording instruction comprises the name of the preset socket program;
and the second feedback module is used for feeding back the recording data to a second application program corresponding to the second recording instruction.
In a third aspect, an embodiment of the present application provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the method for sharing recording data as described in the first aspect above when executing the computer program.
In a fourth aspect, embodiments of the present application provide a computer readable storage medium storing a computer program which, when executed by a processor, implements a method of sharing recorded data as described in the first aspect above.
In a fifth aspect, embodiments of the present application provide a computer program product, which when run on a terminal device, causes the terminal device to perform the method of sharing recording data as described in the first aspect above.
When the first application program is detected to call the recording service program, a preset socket program corresponding to the name carried by the second recording instruction is called to access the recording service program to obtain recording data, the recording data is fed back to the second application program corresponding to the second recording instruction, the directional sharing operation of the corresponding recording data is achieved according to the recording instructions of the plurality of application programs, the propagation speed and breadth of the audio and video are improved, the safety of the recording data is improved, and privacy of a user is guaranteed.
It will be appreciated that the advantages of the second to fifth aspects may be found in the relevant description of the first aspect, and are not described here again.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following description will briefly introduce the drawings that are needed in the embodiments or the description of the prior art, it is obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method for sharing audio recording data according to an embodiment of the present application;
fig. 2 is an application scenario diagram of a method based on shared recording data according to an embodiment of the present application;
fig. 3 is an application scenario diagram of a method based on shared recording data according to another embodiment of the present application;
FIG. 4 is a schematic structural diagram of an apparatus for sharing recording data according to an embodiment of the present disclosure;
fig. 5 is a schematic structural diagram of a terminal device according to an embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system configurations, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It should be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be understood that the term "and/or" as used in this specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
As used in this specification and the appended claims, the term "if" may be interpreted as "when..once" or "in response to a determination" or "in response to detection" depending on the context. Similarly, the phrase "if a determination" or "if a [ described condition or event ] is detected" may be interpreted in the context of meaning "upon determination" or "in response to determination" or "upon detection of a [ described condition or event ]" or "in response to detection of a [ described condition or event ]".
In addition, in the description of the present application and the appended claims, the terms "first," "second," "third," and the like are used merely to distinguish between descriptions and are not to be construed as indicating or implying relative importance.
Reference in the specification to "one embodiment" or "some embodiments" or the like means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," and the like in the specification are not necessarily all referring to the same embodiment, but mean "one or more but not all embodiments" unless expressly specified otherwise. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless expressly specified otherwise.
The method for sharing the recording data can be applied to terminal equipment such as mobile phones, tablet computers, wearable equipment, vehicle-mounted equipment and notebook computers, and the specific type of the terminal equipment is not limited.
Fig. 1 shows a schematic flow chart of a method for sharing recording data provided in the present application, which can be applied to the above-mentioned notebook computer by way of example and not limitation.
S101, receiving a first recording instruction, and detecting a recording service program.
In a specific application, detecting a recording service program at the current moment when a first recording instruction sent by any application program is received; if the recording service program is detected to be established, detecting the state of the recording service program, if the working state of the recording service program is the recording state, judging that the recording service program is called by other application programs to perform recording operation, calling a preset socket program to access the recording service program according to a first recording instruction, obtaining recording data, and feeding back the recording data to the application program; wherein the non-working state comprises a stop recording state and a release recording data state.
It is understood that the first application refers to an application that invokes a recording service; the second application refers to one or more applications that access the recording service by calling a preset socket program.
For example, when a recording instruction of an application program is received, it may be detected by an audio server (audiopolicy service) whether a recording service program exists in an audio generator (audioplayer), and whether an operating state thereof is a recording state. The audio server is mainly used for controlling the start, stop and release of the recording service program.
S102, when the recording service program is detected to be established and the working state of the recording service program is a non-recording state, the recording service program is called to acquire recording data and the recording data is fed back to a first application program corresponding to the first recording instruction.
In a specific application, if it is detected that the recording service program is created and the working state of the recording service program is a non-recording state, the recording service program is called according to the first recording instruction, the working state of the recording service program is updated to a recording state, the recording service program obtains recording data through a hardware abstraction layer, and the recording data is fed back to a first application program (namely, a first application program corresponding to the first recording instruction) which is currently calling the recording service program in real time.
S103, receiving a second recording instruction, calling a preset socket program to access the recording service program, and obtaining the recording data; wherein the second recording instruction includes a name of the preset socket program.
In a specific application, if the second recording instruction is received after the recording service program is called by the first recording instruction, the recording data obtained by recording the recording service program is fed back to the first application program calling the recording service program, and a corresponding preset socket program is called according to the name carried in the second recording instruction to access the recording service program, so that the recording data recorded by the recording service program is obtained and written into the memory of the preset socket program. The name of the preset socket program may be specifically the name of a socket interface in the preset socket program, which is used for establishing a connection relationship between the socket interface and the second application program according to the name of the socket interface, so as to realize that recording data obtained by calling the recording service program according to the preset socket program is transmitted to the second application program through the socket interface.
And S104, feeding back the recording data to a second application program corresponding to the second recording instruction.
In a specific application, the recording data is fed back to a second application program corresponding to the second recording instruction through a preset socket program, and sharing of the recording data is completed.
In one embodiment, after the step S101, the method further includes:
s201, if the recording service program is not detected, initializing a socket interface and creating a memory to create the preset socket program.
In a specific application, when a first recording instruction is received, if a recording service program is not detected, initializing a socket interface (socket), and simultaneously creating a memory; the socket interface is used for transmitting the recording data, the memory is used for storing the recording data, and the creation of the preset socket program is completed.
It should be noted that, when the preset socket program is created, the format of the recording data actually obtained through the hardware abstraction layer may be recorded in the preset socket program, so that the recording data may be received when the recording service program is accessed, and the memory size of the preset socket program may be specifically set according to the format of the recording data actually obtained by the audio hardware abstraction layer.
In one embodiment, if the recording command is received, the working state of the recording service program is detected to be the recording state, and the preset socket program is simultaneously in the working state, a new socket interface is initialized and a memory is created to create a new preset socket program, so that another second application program can access the recording service program by calling the new preset socket program to obtain the recording data.
It will be appreciated that, since video data mainly includes audio data and image data, sharing of video data can be achieved while sharing recording data by the above-described method of sharing recording data.
In one embodiment, after the step S201, the method includes:
s202, creating the recording service program;
s203, establishing an association relationship between the recording service program and the preset socket program.
In a specific application, when a recording instruction is received, if the recording service program is not detected at the current moment, after a preset socket program is created, a corresponding recording service program is created according to the recording instruction, and an association relationship between the recording service program and the preset socket program is established, so that recording data can be written into the preset socket program when the recording service program is accessed through the preset socket program.
As shown in fig. 2, an application scenario diagram for implementing a recording service based on a method for sharing recording data is provided;
in fig. 2, after receiving a first recording instruction sent by a first application program in a java layer to a client in a local service (native) layer, controlling an audio server to start recording service through the client in the native service layer, controlling an audio generator to create a preset socket program and a recording service program by the audio server according to the first recording instruction, establishing an association relationship between the preset socket program and the recording service program, controlling the recording service program to start by the audio server, enabling the recording service program to acquire recording data from a microphone of a linux kernel layer through an audio hardware abstraction layer, and transmitting the recording data acquired by the recording service program to the first application program in the java layer by the client in the native service layer; if a second recording instruction sent by a second application program in the java layer to a client in the local service (native) layer is received at this time, a recording service program in a recording state in the current audio generator is detected, the second recording instruction is analyzed, connection between the second application program and a socket interface in the preset socket program is established according to the name of the preset socket program carried by the second recording instruction, then the preset socket program is called to access the recording service program, the recording service program writes recording data into a memory of the preset socket program, and the recording data is transmitted to the second application program through the socket interface.
In one embodiment, the step S103 includes:
receiving the second recording instruction, analyzing the second recording instruction, and obtaining the name of the preset socket program;
calling a preset socket program corresponding to the name to access the recording service program;
verifying whether an association relationship exists between the preset socket program and the recording service program;
and if the association relation exists between the preset socket program and the recording service program, writing the recording data into the preset socket program.
In a specific application, if a second recording instruction is received after the recording service program is called through a first recording instruction, the second recording instruction is analyzed while recording data obtained by recording the recording service program is fed back to a first application program calling the recording service program, the name of a preset socket program carried in the second recording instruction is obtained, a connection relation between a socket interface in the preset socket program corresponding to the name and the second application program is established according to the second recording instruction, the preset socket program is called to access the recording service program, whether the association relation exists between the preset socket program and the recording service program is verified, if the association relation exists between the preset socket program and the recording service program, the recording service program writes the recording data into a memory of the preset socket program, and the recording data is fed back to the second application program through the socket interface. If there is no association between the preset socket program and the recording service program, or the socket interface in the preset socket program corresponding to the name carried by the second recording instruction cannot be found (i.e., the connection relationship between the socket interface in the preset socket program corresponding to the name carried by the second recording instruction and the second application program cannot be established), it is determined that the access of the preset socket program fails, and the recording data cannot be acquired.
It can be understood that the second application program can call the preset socket program corresponding to the name to access the recording service program to obtain the recording data through the second recording instruction carrying the name of the preset socket interface only if the name of the preset socket interface is known. When the third party application program does not acquire the name of the preset socket program, the third party application program cannot access the recording service program through the preset socket program to acquire the recording data, so that the security of the recording data is improved, and the privacy of a user is ensured.
In one embodiment, after the step S103, the method includes:
analyzing the recording instruction to obtain a preset format contained in the recording instruction;
and if the format of the recording data is different from the preset format, calling an interface program to convert the format of the recording data into the preset format.
In a specific application, analyzing the recording instruction to obtain a preset format contained in the recording instruction, calling an interface program if the format of the recording data is different from the preset format, converting the format of the recording data into the preset format through the interface program, and feeding back the converted recording data to the second application program. The format of the recording data comprises parameters such as sampling rate, sampling bit number, channel number and the like.
It can be understood that when the recording service program runs, the obtained recording data is different from the format required by the first application program, the format of the recording data can be converted into the format required by the first application program by calling the interface program, and the converted recording data is fed back to the first application program.
The interface program may be specifically set according to different operating systems, for example, in an android system, the interface program may be a standard interface AudioRecord, i.e., getMinFrameCount (size_t) frameCount, uint32_tsamplerate, audio_format_tformat, audio_channel_mask_t channel mask; the frame number frame count and the memory size required by the recording data with different formats can be directly calculated through the standard interface.
In one embodiment, after the step S104, the method includes:
if the working state of the recording service program is detected to be updated to be a non-working state, stopping calling a preset socket program to access the recording service program;
and creating a new recording service program according to the second recording instruction, obtaining corresponding recording data, and feeding back the corresponding recording data to a second application program corresponding to the second recording instruction.
In a specific application, if the working state of the recording service program is detected to be updated to a non-working state in the process of calling the preset socket program to access the recording service program, the first application program is judged to control the recording service program to stop recording operation or release recording data, the preset socket program is stopped from being called to access the recording service program, a new recording service program is created according to the second recording instruction, corresponding recording data is obtained and written into a memory of the new recording service program, and the second application program corresponding to the second recording instruction is fed back. If the new recording service program does not have the memory, the memory is re-created and the recording data is written into the memory of the new recording service program.
It can be understood that if a plurality of second application programs call a preset socket program to access the recording service program, when the working state of the recording service program is detected to be updated to a non-working state, the second application program with the earliest time for sending the recording instruction is used as a new first application program, the recording service program is controlled to run according to the recording instruction to perform recording operation, and other second application programs still access the recording service program by calling the preset socket program to obtain recording data.
As shown in fig. 3, another application scenario diagram for implementing a recording service based on a method for sharing recording data is provided;
in fig. 3, when a first application program of the java layer sends a recording stopping instruction to a client in the local service (native) layer, the client in the local service (native) layer controls the audio server to stop recording service according to the instruction, and the audio server controls the recording service program 1 in the audio generator to stop recording or release recording data according to the instruction, at this time, a second application program of the java layer cannot obtain recording data from the recording service program 1. Therefore, the audio generator can create the recording service program 2 according to the second recording instruction sent by the second application program, and establish the association relationship between the recording service program 2 and the preset socket program. The audio server controls the starting of the recording service program 2 according to the recording instruction sent by the second application program, and the recording service program 2 acquires recording data from a microphone in the linux kernel layer through the audio hardware abstraction layer and stores the recording data in the memory. Because no other application program sends the recording instruction at this time, the recording service program 2 no longer writes recording data into the memory of the preset socket program, and correspondingly, the socket interface also stops transmitting the recording data to the second application program.
It can be understood that if a recording instruction sent by a new second application program is received, the second application program which currently calls the recording service program 2 is used as a first application program, and the new second application program accesses the recording service program 2 by calling a preset socket program to obtain recording data.
When the first application program is detected to call the recording service program, a preset socket program corresponding to the name carried by the second recording instruction is called to access the recording service program to obtain recording data, the recording data is fed back to the second application program corresponding to the second recording instruction, the directional sharing operation of the corresponding recording data is achieved according to the recording instructions of the plurality of application programs, the propagation speed and breadth of the audio and video are improved, the safety of the recording data is improved, and privacy of a user is guaranteed.
It should be understood that the sequence number of each step in the foregoing embodiment does not mean that the execution sequence of each process should be determined by the function and the internal logic of each process, and should not limit the implementation process of the embodiment of the present application in any way.
Corresponding to the method for sharing recording data described in the foregoing embodiments, fig. 4 shows a block diagram of a device 100 for sharing recording data provided in the embodiment of the present application, and for convenience of explanation, only a portion relevant to the embodiment of the present application is shown.
Referring to fig. 4, the apparatus for sharing recording data 100 includes:
the detection module 101 is configured to receive a first recording instruction, and detect a recording service program;
the first feedback module 102 is configured to detect that the recording service program has been created, and that the working state of the recording service program is a non-recording state, call the recording service program to obtain recording data, and feed back the recording data to a first application program corresponding to the first recording instruction;
the calling module 103 is configured to receive a second recording instruction, call a preset socket program to access the recording service program, and obtain the recording data; wherein the second recording instruction comprises the name of the preset socket program;
and the second feedback module 104 is configured to feed back the recording data to a second application program corresponding to the second recording instruction.
In one embodiment, the apparatus 100 further comprises:
and the initialization module is used for initializing the socket interface and creating a memory if the recording service program is not detected so as to create the preset socket program.
In one embodiment, the apparatus 100 further comprises:
the creating module is used for creating the recording service program;
and the establishing module is used for establishing the association relation between the recording service program and the preset socket program.
In one embodiment, the calling module 103 includes:
the analyzing unit is used for receiving the second recording instruction, analyzing the second recording instruction and obtaining the name of the preset socket program;
the calling unit is used for calling a preset socket program corresponding to the name to access the recording service program;
the verification unit is used for verifying whether the association relation exists between the preset socket program and the recording service program;
and the data reading and writing unit is used for writing the recording data into the preset socket program if the association relationship exists between the preset socket program and the recording service program.
In one embodiment, the apparatus 100 further comprises:
the analysis module is used for analyzing the recording instruction and obtaining a preset format contained in the recording instruction;
and the conversion module is used for calling an interface program to convert the format of the recording data into the preset format if the format of the recording data is different from the preset format.
In one embodiment, the apparatus 100 further comprises:
the control module is used for stopping calling a preset socket program to access the recording service program if the working state of the recording service program is detected to be updated to be a non-working state;
and the access module is used for creating a new recording service program according to the second recording instruction, obtaining corresponding recording data and feeding back the corresponding recording data to a second application program corresponding to the second recording instruction.
When the first application program is detected to call the recording service program, a preset socket program corresponding to the name carried by the second recording instruction is called to access the recording service program to obtain recording data, the recording data is fed back to the second application program corresponding to the second recording instruction, the directional sharing operation of the corresponding recording data is achieved according to the recording instructions of the plurality of application programs, the propagation speed and breadth of the audio and video are improved, the safety of the recording data is improved, and privacy of a user is guaranteed.
It should be noted that, because the content of information interaction and execution process between the above devices/units is based on the same concept as the method embodiment of the present application, specific functions and technical effects thereof may be referred to in the method embodiment section, and will not be described herein again.
Fig. 5 is a schematic structural diagram of a terminal device according to an embodiment of the present application. As shown in fig. 5, the terminal device 5 of this embodiment includes: at least one processor 50 (only one shown in fig. 5), a memory 51 and a computer program 52 stored in the memory 51 and executable on the at least one processor 50, the processor 50 implementing the steps in any of the various method embodiments of sharing recorded data described above when executing the computer program 52.
The terminal device 5 may be a computing device such as a desktop computer, a notebook computer, a palm computer, a cloud server, etc. The terminal device may include, but is not limited to, a processor 50, a memory 51. It will be appreciated by those skilled in the art that fig. 5 is merely an example of the terminal device 5 and is not meant to be limiting as the terminal device 5, and may include more or fewer components than shown, or may combine certain components, or different components, such as may also include input-output devices, network access devices, etc.
The processor 50 may be a central processing unit (Central Processing Unit, CPU), the processor 50 may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 51 may in some embodiments be an internal storage unit of the terminal device 5, such as a hard disk or a memory of the terminal device 5. The memory 51 may in other embodiments also be an external storage device of the terminal device 5, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital Card (SD), a Flash memory Card (Flash Card) or the like, which are provided on the terminal device 5. Further, the memory 51 may also include both an internal storage unit and an external storage device of the terminal device 5. The memory 51 is used for storing an operating system, application programs, boot loader (BootLoader), data, other programs, etc., such as program codes of the computer program. The memory 51 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-described division of the functional units and modules is illustrated, and in practical application, the above-described functional distribution may be performed by different functional units and modules according to needs, i.e. the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-described functions. The functional units and modules in the embodiment may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit, where the integrated units may be implemented in a form of hardware or a form of a software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working process of the units and modules in the above system may refer to the corresponding process in the foregoing method embodiment, which is not described herein again.
The embodiment of the application also provides a terminal device, which comprises: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, which when executed by the processor performs the steps of any of the various method embodiments described above.
Embodiments of the present application also provide a computer readable storage medium storing a computer program which, when executed by a processor, implements steps that may implement the various method embodiments described above.
Embodiments of the present application provide a computer program product which, when run on a mobile terminal, causes the mobile terminal to perform steps that may be performed in the various method embodiments described above.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the present application implements all or part of the flow of the method of the above embodiments, and may be implemented by a computer program to instruct related hardware, where the computer program may be stored in a computer readable storage medium, where the computer program, when executed by a processor, may implement the steps of each of the method embodiments described above. Wherein the computer program comprises computer program code which may be in source code form, object code form, executable file or some intermediate form etc. The computer readable medium may include at least: any entity or device capable of carrying computer program code to a photographing device/terminal apparatus, recording medium, computer Memory, read-Only Memory (ROM), random access Memory (RAM, random Access Memory), electrical carrier signals, telecommunications signals, and software distribution media. Such as a U-disk, removable hard disk, magnetic or optical disk, etc. In some jurisdictions, computer readable media may not be electrical carrier signals and telecommunications signals in accordance with legislation and patent practice.
In the foregoing embodiments, the descriptions of the embodiments are emphasized, and in part, not described or illustrated in any particular embodiment, reference is made to the related descriptions of other embodiments.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/network device and method may be implemented in other manners. For example, the apparatus/network device embodiments described above are merely illustrative, e.g., the division of the modules or units is merely a logical functional division, and there may be additional divisions in actual implementation, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection via interfaces, devices or units, which may be in electrical, mechanical or other forms.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
The above embodiments are only for illustrating the technical solution of the present application, and are not limiting; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present application, and are intended to be included in the scope of the present application.

Claims (3)

1. A method of sharing recorded data, comprising:
receiving a first recording instruction, and detecting a recording service program;
when the recording service program is detected to be established and the working state of the recording service program is a non-recording state, calling the recording service program to acquire recording data and feeding back the recording data to a first application program corresponding to the first recording instruction;
receiving a second recording instruction, calling a preset socket program to access the recording service program, and obtaining the recording data; wherein the second recording instruction comprises the name of the preset socket program;
feeding back the recording data to a second application program corresponding to the second recording instruction;
the receiving the second recording instruction, calling a preset socket program to access the recording service program, and obtaining the recording data, including:
receiving the second recording instruction, analyzing the second recording instruction, and obtaining the name of the preset socket program;
calling a preset socket program corresponding to the name to access the recording service program;
verifying whether an association relationship exists between the preset socket program and the recording service program;
if the association relation exists between the preset socket program and the recording service program, writing the recording data into the preset socket program;
the second application program can call a preset socket program corresponding to the name to access a recording service program through a second recording instruction carrying the name of the preset socket interface under the condition that the name of the preset socket interface is known, so as to obtain recording data;
the receiving of the first recording instruction, after detecting the recording service program, further includes:
if the recording service program is not detected, initializing a socket interface and creating a memory to create the preset socket program;
if the recording service program is not detected, initializing a socket interface and creating a memory, so as to create the preset socket program, and then, the method comprises the following steps:
creating the recording service program;
establishing an association relationship between the recording service program and the preset socket program;
the receiving the second recording instruction, calling a preset socket program to access the recording service program, and after obtaining the recording data, comprising:
analyzing the recording instruction to obtain a preset format contained in the recording instruction;
if the format of the recording data is different from the preset format, calling an interface program to convert the format of the recording data into the preset format;
after the recording data is fed back to the second application program corresponding to the second recording instruction, the method comprises the following steps:
if the working state of the recording service program is detected to be updated to be a non-working state, stopping calling a preset socket program to access the recording service program;
and creating a new recording service program according to the second recording instruction, obtaining corresponding recording data, and feeding back the corresponding recording data to a second application program corresponding to the second recording instruction.
2. An apparatus for sharing recorded data, comprising:
the detection module is used for receiving the first recording instruction and detecting a recording service program;
the first feedback module is used for detecting that the recording service program is created, and the working state of the recording service program is a non-recording state, calling the recording service program to acquire recording data and feeding back the recording data to a first application program corresponding to the first recording instruction;
the calling module is used for receiving a second recording instruction, calling a preset socket program to access the recording service program and obtaining the recording data; wherein the second recording instruction comprises the name of the preset socket program;
the second feedback module is used for feeding back the recording data to a second application program corresponding to the second recording instruction;
the receiving the second recording instruction, calling a preset socket program to access the recording service program, and obtaining the recording data, including:
receiving the second recording instruction, analyzing the second recording instruction, and obtaining the name of the preset socket program;
calling a preset socket program corresponding to the name to access the recording service program;
verifying whether an association relationship exists between the preset socket program and the recording service program;
if the association relation exists between the preset socket program and the recording service program, writing the recording data into the preset socket program;
the second application program can call a preset socket program corresponding to the name to access a recording service program through a second recording instruction carrying the name of the preset socket interface under the condition that the name of the preset socket interface is known, so as to obtain recording data;
the device further comprises:
the initialization module is used for initializing a socket interface and creating a memory if the recording service program is not detected so as to create the preset socket program;
the creating module is used for creating the recording service program;
the establishing module is used for establishing the association relationship between the recording service program and the preset socket program;
the analysis module is used for analyzing the recording instruction and obtaining a preset format contained in the recording instruction;
the conversion module is used for calling an interface program to convert the format of the recording data into the preset format if the format of the recording data is different from the preset format;
the control module is used for stopping calling a preset socket program to access the recording service program if the working state of the recording service program is detected to be updated to be a non-working state;
and the access module is used for creating a new recording service program according to the second recording instruction, obtaining corresponding recording data and feeding back the corresponding recording data to a second application program corresponding to the second recording instruction.
3. A terminal device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the method of claim 1 when executing the computer program.
CN202010872168.7A 2020-08-26 2020-08-26 Method, device, terminal equipment and readable storage medium for sharing recording data Active CN112181676B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010872168.7A CN112181676B (en) 2020-08-26 2020-08-26 Method, device, terminal equipment and readable storage medium for sharing recording data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010872168.7A CN112181676B (en) 2020-08-26 2020-08-26 Method, device, terminal equipment and readable storage medium for sharing recording data

Publications (2)

Publication Number Publication Date
CN112181676A CN112181676A (en) 2021-01-05
CN112181676B true CN112181676B (en) 2023-07-18

Family

ID=73925019

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010872168.7A Active CN112181676B (en) 2020-08-26 2020-08-26 Method, device, terminal equipment and readable storage medium for sharing recording data

Country Status (1)

Country Link
CN (1) CN112181676B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010165022A (en) * 2009-01-13 2010-07-29 Ricoh Co Ltd Inter-processor communication device, inter-processor communication method, program, and recording medium
CN110083468A (en) * 2019-05-05 2019-08-02 Oppo广东移动通信有限公司 A kind of data transmission method, electronic device and storage medium
CN110704202A (en) * 2018-07-10 2020-01-17 深圳市优必选科技有限公司 Multimedia recording data sharing method and terminal equipment
CN111540385A (en) * 2020-04-26 2020-08-14 西安广和通无线软件有限公司 Recording data sharing method and device, computer equipment and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010165022A (en) * 2009-01-13 2010-07-29 Ricoh Co Ltd Inter-processor communication device, inter-processor communication method, program, and recording medium
CN110704202A (en) * 2018-07-10 2020-01-17 深圳市优必选科技有限公司 Multimedia recording data sharing method and terminal equipment
CN110083468A (en) * 2019-05-05 2019-08-02 Oppo广东移动通信有限公司 A kind of data transmission method, electronic device and storage medium
CN111540385A (en) * 2020-04-26 2020-08-14 西安广和通无线软件有限公司 Recording data sharing method and device, computer equipment and storage medium

Also Published As

Publication number Publication date
CN112181676A (en) 2021-01-05

Similar Documents

Publication Publication Date Title
CN108595970B (en) Configuration method and device of processing assembly, terminal and storage medium
CN109213611B (en) Cross-process communication method, device, terminal and storage medium
US8661502B2 (en) Determining a sensitivity label of document information in real time
US20050278418A1 (en) System and method for use of multiple applications
US9560122B1 (en) Secure native application messaging with a browser application
CN106326018B (en) Data access method and terminal
CN111459673A (en) Secure memory expansion and release method and device and electronic equipment
CN110719590B (en) One-key login method, device, equipment and storage medium based on mobile phone number
CN112181676B (en) Method, device, terminal equipment and readable storage medium for sharing recording data
CN113467656B (en) Screen touch event notification method and vehicle machine
CN104714760A (en) Method and device for read and write storage device
CN115237481A (en) Method, device and equipment for driving external equipment and storage medium
WO2020064000A1 (en) Method and apparatus for displaying message box, terminal and storage medium
CN114356870A (en) Cross-device data sharing method and related devices
CN111447439A (en) Image coding method, image coding device and mobile terminal
CN110765426A (en) Equipment permission setting method, device, equipment and computer storage medium
CN111352357A (en) Robot control method and device and terminal equipment
CN113850633B (en) Information pushing method and device
CN113438419B (en) Camera starting method and device and electronic equipment
CN111061492B (en) Application processing method, device and computer storage medium
CN112199127A (en) Image data processing method and device, mobile terminal and storage medium
WO2020113531A1 (en) Data recovery method and device, and electronic device
CN117278549A (en) RDMA (remote direct memory Access) -based data transmission method, device, electronic equipment and storage medium
CN112925758A (en) Method and device for generating compressed packet and terminal equipment
CN117217173A (en) Document processing method, device, server and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20231211

Address after: Room 601, 6th Floor, Building 13, No. 3 Jinghai Fifth Road, Beijing Economic and Technological Development Zone (Tongzhou), Tongzhou District, Beijing, 100176

Patentee after: Beijing Youbixuan Intelligent Robot Co.,Ltd.

Address before: 518000 16th and 22nd Floors, C1 Building, Nanshan Zhiyuan, 1001 Xueyuan Avenue, Nanshan District, Shenzhen City, Guangdong Province

Patentee before: Shenzhen Youbixuan Technology Co.,Ltd.