Image data acquisition method, terminal device and medium

文档序号:1354689 发布日期:2020-07-24 浏览:37次 中文

阅读说明:本技术 图像数据的采集方法、终端设备及介质 (Image data acquisition method, terminal device and medium ) 是由 熊友军 潘宇超 于 2018-12-28 设计创作,主要内容包括:本发明适用于移动终端技术领域,提供了一种图像数据的采集方法、终端设备及介质,该方法包括:当相机应用程序切换至后台运行时,创建可见度低于第一阈值的对象区域,并在对象区域中加载显示控件;创建与相机应用程序关联的图像预览请求,将图像预览请求与显示控件进行绑定;通过显示控件所绑定的图像预览请求,在对象区域中展示摄像头所拍摄得到的各帧图像数据;若接收到用户发出的图像拍摄指令,则创建图像控件及其所绑定的图像拍摄请求;对图像控件所调用的图像数据进行存储。本发明保证了用户能够在前台界面操控其他非相机业务的应用程序的同时,还能够使用相机应用程序所提供的图像数据采集功能,故提高了相机应用程序的交互能力。(The invention is suitable for the technical field of mobile terminals, and provides an image data acquisition method, terminal equipment and a medium, wherein the method comprises the following steps: when the camera application program is switched to background operation, creating an object area with the visibility lower than a first threshold value, and loading a display control in the object area; creating an image preview request associated with the camera application program, and binding the image preview request with the display control; displaying each frame of image data shot by a camera in an object area through an image preview request bound by a display control; if an image shooting instruction sent by a user is received, an image control and an image shooting request bound by the image control are created; and storing the image data called by the image control. The invention ensures that the user can control the application programs of other non-camera services on the foreground interface and can use the image data acquisition function provided by the camera application program, thereby improving the interaction capability of the camera application program.)

1. A method of acquiring image data, comprising:

when the camera application program is switched to background operation, creating an object area with the visibility lower than a first threshold value, and loading a display control in the object area;

creating an image preview request associated with the camera application program, and binding the image preview request with the display control;

displaying each frame of image data shot by a camera in the object area through the image preview request bound by the display control;

if an image shooting instruction sent by a user is received, an image control and an image shooting request bound by the image control are created; the image control is used for calling the image data read by the display control in real time according to the detected image shooting request;

and storing the image data called by the image control.

2. The method for acquiring image data according to claim 1, wherein the creating an object area with visibility lower than a first threshold and loading a display control in the object area when the camera application program is switched to a background operation comprises:

when the camera application program is switched to background operation, a dialog box containing a display control is created;

setting the length of the dialog box to be less than a second threshold value and the width of the dialog box to be less than a third threshold value respectively so that the visibility of the dialog box is lower than the first threshold value.

3. The method for acquiring image data according to claim 1, wherein the creating an object area with visibility lower than a first threshold and loading a display control in the object area when the camera application program is switched to a background operation comprises:

when the camera application program is switched to the background operation, the display mode of the terminal screen is switched from the single-screen display mode to the multi-screen display mode, and a plurality of object areas are obtained;

setting the area ratio of any one object region to be smaller than a first threshold value, and loading a display control in the object region.

4. The method for acquiring image data according to claim 2, further comprising, after the setting of the length of the dialog box to be less than a second threshold value and the setting of the width of the dialog box to be less than a third threshold value, respectively:

when an image preview event is triggered, acquiring an initial size parameter of the dialog box;

adjusting the length and the width of the dialog box to the initial size parameters, respectively, such that the visibility of the dialog box is greater than the first threshold.

5. The method of acquiring image data according to claim 1, further comprising:

if a video recording instruction sent by a user is received, a video recording container is created;

generating a video recording request associated with the camera application program, and controlling an interface layer of the video recording container to bind the video recording request so as to obtain image stream data shot by the camera through the interface layer of the video recording container;

and storing the image stream data in the video recording container.

6. An apparatus for acquiring image data, comprising:

the camera application program comprises a first creating unit, a second creating unit and a display control unit, wherein the first creating unit is used for creating an object area with the visibility lower than a first threshold value when the camera application program is switched to the background operation, and loading the display control in the object area;

a second creating unit, configured to create an image preview request associated with the camera application, and bind the image preview request with the display control;

the display unit is used for displaying each frame of image data shot by the camera in the object area through the image preview request bound by the display control;

the third creating unit is used for creating the image control and the image shooting request bound by the image control if receiving an image shooting instruction sent by a user; the image control is used for calling the image data read by the display control in real time according to the detected image shooting request;

and the storage unit is used for storing the image data called by the image control.

7. The apparatus for acquiring image data according to claim 6, wherein the first creating unit includes:

the creating subunit is used for creating a dialog box containing a display control when the camera application program is switched to the background operation;

and the first setting subunit is used for respectively setting the length of the dialog box to be smaller than a second threshold value and setting the width of the dialog box to be smaller than a third threshold value so as to enable the visibility of the dialog box to be lower than the first threshold value.

8. The apparatus for acquiring image data according to claim 6, wherein the first creating unit includes:

the switching subunit is used for switching the display mode of the terminal screen from the single-screen display mode to the multi-screen display mode to obtain a plurality of object areas when the camera application program is switched to the background operation;

and the second setting subunit is used for setting the area occupation ratio of any one object region to be smaller than the first threshold value and loading the display control in the object region.

9. A terminal device comprising a memory and a processor, the memory storing a computer program operable on the processor, wherein the processor implements the steps of the method according to any one of claims 1 to 5 when executing the computer program.

10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 5.

Technical Field

The invention belongs to the technical field of mobile terminals, and particularly relates to an image data acquisition method, terminal equipment and a computer-readable storage medium.

Background

In a terminal device operating an android system, if a user wants to acquire external image data, a camera application is usually started first, so as to generate a preview interface visible in the foreground on a display screen of the terminal. By viewing the image rendered in real time by the preview interface, the user can send a shooting confirmation instruction, so that the image data required by the user is acquired.

However, in the process of image capturing and shooting, if a user wants to operate other applications in the terminal device, the user can only temporarily move the camera application to the background for running. At this time, the android system will temporarily close the camera application program, so that the user cannot simultaneously perform the acquisition operation of the image data, thereby reducing the interaction capability of the camera application program.

Disclosure of Invention

In view of this, embodiments of the present invention provide an image data acquisition method, a terminal device, and a computer-readable storage medium, so as to solve the problem that an interaction capability of a camera application is low in an existing image data acquisition manner.

A first aspect of an embodiment of the present invention provides an image data acquisition method, including:

when the camera application program is switched to background operation, creating an object area with the visibility lower than a first threshold value, and loading a display control in the object area;

creating an image preview request associated with the camera application program, and binding the image preview request with the display control;

displaying each frame of image data shot by a camera in the object area through the image preview request bound by the display control;

if an image shooting instruction sent by a user is received, an image control and an image shooting request bound by the image control are created; the image control is used for calling the image data read by the display control in real time according to the detected image shooting request;

and storing the image data called by the image control.

A second aspect of an embodiment of the present invention provides an image data acquisition apparatus, including:

the camera application program comprises a first creating unit, a second creating unit and a display control unit, wherein the first creating unit is used for creating an object area with the visibility lower than a first threshold value when the camera application program is switched to the background operation, and loading the display control in the object area;

a second creating unit, configured to create an image preview request associated with the camera application, and bind the image preview request with the display control;

the display unit is used for displaying each frame of image data shot by the camera in the object area through the image preview request bound by the display control;

the third creating unit is used for creating the image control and the image shooting request bound by the image control if receiving an image shooting instruction sent by a user; the image control is used for calling the image data read by the display control in real time according to the detected image shooting request;

and the storage unit is used for storing the image data called by the image control.

A third aspect of the embodiments of the present invention provides a terminal device, including a memory and a processor, where the memory stores a computer program operable on the processor, and the processor implements the steps of the image data acquisition method when executing the computer program.

A fourth aspect of the embodiments of the present invention provides a computer-readable storage medium, in which a computer program is stored, and when the computer program is executed by a processor, the steps of the image data acquisition method are implemented as described above.

In the embodiment of the invention, by creating the object area with the visibility lower than the first threshold when the camera application program is switched to the background operation, and a display control is loaded in the object area, and through the image preview request bound by the display control, each frame of image data shot by the camera is displayed in the object area, so that the visibility of each frame of image data is lower than the first threshold value, the preview picture of the camera application program can still run in the object area of the foreground under the condition that the preview picture is invisible to naked eyes, therefore, the automatic closing of the camera application program by an android system is avoided, thereby ensuring that while the user can control the application programs of other non-camera services in the foreground interface, the image data acquisition function provided by the camera application program can be used, so that the interaction capability of the camera application program is improved.

Drawings

In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.

FIG. 1 is a flow chart of an implementation of a method for acquiring image data according to an embodiment of the present invention;

FIG. 2 is a flowchart illustrating an implementation of a method for acquiring image data according to another embodiment of the present invention;

fig. 3 is a flowchart of a specific implementation of the image data acquisition method S101 according to an embodiment of the present invention;

fig. 4 is a flowchart of a specific implementation of the image data acquisition method S101 according to another embodiment of the present invention;

fig. 5 is a flowchart illustrating a specific implementation of the image data acquisition method S101 according to another embodiment of the present invention;

fig. 6 is a block diagram of an image data acquisition apparatus according to an embodiment of the present invention;

fig. 7 is a schematic diagram of a terminal device according to an embodiment of the present invention.

Detailed Description

In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the invention. It will be apparent, however, to one skilled in the art that the present invention 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 invention with unnecessary detail.

In order to explain the technical means of the present invention, the following description will be given by way of specific examples.

Fig. 1 shows an implementation flow of the image data acquisition method provided in the embodiment of the present invention, and the method is suitable for terminal devices running camera applications, including but not limited to various mobile terminals carrying cameras, such as mobile phones, tablet pcs, and handheld computers. The above method flow includes steps S101 to S105. The specific realization principle of each step is as follows:

s101: when the camera application program is switched to the background operation, an object area with the visibility lower than a first threshold value is created, and a display control is loaded in the object area.

In the embodiment of the invention, the camera application program is used for starting the camera of the terminal equipment and controlling the terminal equipment to execute shooting operation according to various preset camera parameters. And starting the camera application program when a selection instruction sent by a user to the camera application program is detected. At this point, the camera application is running in the foreground interface. If it is detected that the user temporarily exits the camera application program or enters other application programs in response to an interrupt event, the camera application program is switched to background operation.

For example, if the mobile terminal receives an incoming call request during the running process of the camera application program, the camera application program will be switched to run in the background during the incoming call answering process, and at this time, the foreground running program of the mobile terminal is a telephone calling program.

In the embodiment of the invention, when the camera application program is switched to the background operation, the object area with the visibility lower than the first threshold value is created. And loading a preset display control through the activity component, and displaying the display control in the object area. The display control may be a control with a View display interface, such as TextureView, surface View, and surface texture, and is configured to acquire image data of each frame captured by a camera and perform real-time preview display on the image data. And the length and width value of the display control is the same as that of the object region, so that the display control is filled into the object region.

The visibility of the object area is used to measure the clear view of the content contained in the object area by the human eye. The visibility of the object region may be determined according to the transparency and/or size value of the object region. Wherein the first threshold is a minimum visibility value when the human eye can clearly view the object region, and is determined according to a test experience value entered by a developer.

S102: and creating an image preview request associated with the camera application program, and binding the image preview request with the display control.

S103: and displaying each frame of image data shot by the camera in the object area through the image preview request bound by the display control.

When the camera application program runs (including foreground running and background running), various pre-stored camera parameters are obtained, and a camera preset in the terminal equipment is started. The camera parameters include width pixels, height pixels, image format, and the number of images allowed to be read, and may be read from a default configuration file of the camera application program, or may be determined according to a setting instruction issued by a user, which is not limited herein.

And creating an image preview request based on the currently started camera application program, so as to acquire each frame of image data obtained by real-time shooting of the camera through the image preview request. And binding the loaded display control with the image preview request. And importing each frame of image data obtained by the image preview request into the display control according to the display control bound by the image preview request.

In the embodiment of the invention, when the display control exists in the object area and the visibility of the object area is lower than the first threshold value, only the preview interface of the image data is rendered in the display control on the display interface of the terminal equipment. At this time, the visibility of the preview interface is also lower than the first threshold. Therefore, it is impossible for the terminal user to view the preview interface in the terminal interface.

S104: if an image shooting instruction sent by a user is received, an image control and an image shooting request bound by the image control are created; the image control is used for calling the image data read by the display control in real time according to the detected image shooting request.

S105: and storing the image data called by the image control.

In the embodiment of the invention, when a user wants to perform image shooting operation on a scene at any time, shooting keys provided by the terminal equipment in advance can be clicked, wherein the shooting keys comprise a physical key, a virtual key, a gesture key and the like. The image shooting instruction comprises a shooting instruction and a video recording instruction. The photographing instruction is used for capturing one frame of image data, and the video recording instruction is used for starting the recording operation of continuous multi-frame image data. Different shooting keys are preset to correspond to different shooting instructions.

For example, if it is detected that the user presses the volume up key for a long time, it is determined that the user needs to photograph a scene at the current time, and at this time, the terminal device detects that a photographing instruction is obtained.

And if a photographing instruction sent by a user is received, creating an image control Imagereader, and binding the image control Imagereader with the image photographing request. At the current moment, the camera application calls one frame of image data in the display control based on the associated image control ImageReader. The image photographing function is realized by storing the frame of image data.

In the embodiment of the invention, by creating the object area with the visibility lower than the first threshold when the camera application program is switched to the background operation, and a display control is loaded in the object area, and through the image preview request bound by the display control, each frame of image data shot by the camera is displayed in the object area, so that the visibility of each frame of image data is lower than the first threshold value, the preview picture of the camera application program can still run in the object area of the foreground under the condition that the preview picture is invisible to naked eyes, therefore, the automatic closing of the camera application program by an android system is avoided, thereby ensuring that while the user can control the application programs of other non-camera services in the foreground interface, the image data acquisition function provided by the camera application program can be used, so that the interaction capability of the camera application program is improved.

If a video recording instruction sent by the user is received, as another embodiment of the present invention, as shown in fig. 2, after the step S105, the method further includes:

s106: and generating a video recording request associated with the camera application program, and controlling an interface layer of the video recording container to bind the video recording request so as to obtain image stream data shot by the camera through the interface layer of the video recording container.

S107: and storing the image stream data in the video recording container.

In the embodiment of the invention, for the shooting key corresponding to the preset video recording event, if the user selects the shooting key, the video recording instruction sent by the user is determined to be received. At this time, a video recording container MediaRecord is created for accessing video data captured by the camera application.

And creating a video recording request based on the currently started camera application program so as to acquire video data continuously shot by the camera through the video recording request. In the embodiment of the invention, the interface layer surface of the video recording container is bound with the video recording request, so that the video data obtained by the video recording request can be stored in the Mediarecord of the video recording container.

After receiving the video recording instruction, the camera application calls the video data read by the video recording container MediaRecord during the period before receiving the video recording stop instruction. The video recording function is realized by storing the continuously obtained video data.

The embodiment of the invention ensures that the user can execute the image photographing and use the video data recording function provided by the camera application program when operating other application programs of non-camera services on the foreground interface, thereby improving the interaction capability of the camera application program.

As an embodiment of the present invention, fig. 3 shows a specific implementation flow of the image data acquisition method S101 provided in the embodiment of the present invention, which is detailed as follows:

s1011: when the camera application switches to background operation, a dialog box containing a display control is created.

S1012: setting the length of the dialog box to be less than a second threshold value and the width of the dialog box to be less than a third threshold value respectively so that the visibility of the dialog box is lower than the first threshold value.

When the camera application program is switched to the background operation, a dialog box is created on the terminal display interface, and the dialog box is used as the object area in the above embodiment. Dialog boxes include, but are not limited to, android system pre-established Dialog controls, developer-customized Dialog controls, and the like. And filling the display control associated with the camera application program into the dialog box, and controlling the length and the width of the display control to be respectively kept the same as those of the dialog box.

In the embodiment of the present invention, adjusting the length and the width of the dialog box includes: the method comprises the steps of setting the length of the dialog box to be smaller than a second threshold value and setting the width of the dialog box to be smaller than a third threshold value respectively, so that the area of the area occupied by the dialog box in a terminal display picture is smaller than a preset threshold value, a display control in the dialog box can not be seen by people, and the dialog box can be guaranteed to have low visibility.

Under the precondition that the dialog box cannot be viewed by human eyes, the maximum length value and the maximum width value of the dialog box are the second threshold value and the third threshold value respectively. The second threshold value and the third threshold value may be determined according to the developer's experience in developing the test. For example, the second threshold value and the third threshold value may be 1 px.

Preferably, as another embodiment of the present invention, as shown in fig. 4, after S1012, the method further includes:

s1013: and when the image preview event is triggered, acquiring the initial size parameter of the dialog box.

S1014: adjusting the length and the width of the dialog box to the initial size parameters, respectively, such that the visibility of the dialog box is greater than the first threshold.

The user can trigger an image preview event related to the camera application program by controlling a function key or a gesture key of the terminal display interface so as to restore the invisible image preview interface of the foreground at the current moment to a state visible to naked eyes of the user, and then display the image data read in real time in the display control.

In particular, in addition to the user actively triggering the image preview event, for the above-mentioned example, if the mobile terminal receives an incoming call request during the operation of the camera application, the camera application will be temporarily switched to the background operation during the incoming call answering process; when the incoming call is answered, the camera application program can automatically trigger an image preview event.

In the embodiment of the present invention, when the image preview event is triggered, the initial size parameters of the dialog box generated in step S1011 above are obtained, where the initial size parameters include an initial width value and an initial length value of the dialog box. In a display interface of the terminal device, the length of the dialog box at the current moment is restored to the initial length value, and the width of the dialog box is restored to the initial width value, so that the visibility of the dialog box is larger than a first threshold value.

The initial size parameter is a size parameter that the dialog box has in a state that can be viewed by human eyes, and may be a factory size parameter that is default for the terminal device or a size parameter that is preset by a developer.

Preferably, the initial size parameter of the dialog box is the same as the size parameter of the display interface of the terminal device, so that the user can view the display control in the dialog box through naked eyes, and simultaneously, the image preview data can be displayed in the display control in an image maximization mode, thereby improving the shooting experience of the user and improving the visual effect of the image preview picture.

In the embodiment of the invention, because the Dialog control is a common system control, when the camera application program is switched to the background operation, the Dialog box containing the display control is created, the length of the Dialog box is set to be smaller than the second threshold value, and the width of the Dialog box is set to be smaller than the third threshold value, so that the creation of an object area with the visibility lower than the first threshold value is realized, the reliability of the image data acquisition method provided by the invention is enhanced, and the realization difficulty is reduced; under the condition that a user has an image preview requirement, the length and the width of the dialog box are adjusted to initial size parameters by triggering an image preview event, so that a hidden image preview interface can be quickly recovered, the flexible switching of the image preview interface is realized, and the interaction capacity of a camera application program is improved.

As a further embodiment of the invention, the way in which the object region is created is further defined. Specifically, fig. 5 shows a specific implementation flow of the image data acquisition method S101 provided by the embodiment of the present invention, which is detailed as follows:

s1015: and when the camera application program is switched to the background operation, switching the display mode of the terminal screen from the single-screen display mode to the multi-screen display mode to obtain a plurality of object areas.

The display modes of the terminal screen comprise a single-screen display mode and a multi-screen display mode. Under the multi-screen display mode, the terminal display interface generates a separation bar to divide the terminal display interface into two or more object areas.

In the embodiment of the invention, the image which is originally displayed on the display interface of the terminal in a full screen manner is reduced, and the sub-image obtained after reduction is displayed in each object area in the full screen manner. For example, if the terminal display interface in the single-screen display mode is used for displaying the address book page, the address book page is displayed in a reduced size in a plurality of object areas of the terminal display interface after the display mode of the terminal screen is switched from the single-screen display mode to the multi-screen display mode.

And adjusting the area of each object region by detecting a moving instruction sent by a user to the partition bar. In each object area, by detecting a manipulation instruction issued by a user, a response operation corresponding to the manipulation instruction is performed in the object area.

In the embodiment of the invention, if the camera application program running in the foreground is detected in the single-screen display mode, the display mode of the terminal screen is automatically controlled to be switched from the single-screen display mode to the multi-screen display mode when the camera application program is switched to the background running, so that a plurality of object areas are obtained.

S1016: setting the area ratio of any one object region to be smaller than a first threshold value, and loading a display control in the object region.

In the embodiment of the present invention, the area ratio of the object region represents a ratio of the area of the object region to the area of the terminal display interface. Any one of the target regions obtained in S1015 is selected. And changing the area ratio of the object region through the position of the separating bar in the display interface of the mobile terminal, and enabling the area ratio of the object region to be smaller than a first threshold value. And loading a display control associated with the camera application program in the object area with the area ratio smaller than the first threshold value.

The first threshold is an area ratio maximum value when the human eye cannot view the object region. For example, the area ratio of the target region is set to be less than 0.001%.

In the embodiment of the invention, when the camera application program is switched to the background operation, the display mode of the terminal screen is switched from the single-screen display mode to the multi-screen display mode to obtain a plurality of object areas, and the display control is loaded in the object area after the area occupation ratio of any one object area is set to be smaller than the first threshold value, so that the area occupation ratio of the display control is also ensured to be smaller than the first threshold value, and therefore, a user can not obstruct the operation of the non-camera application program due to the existence of the display control in the process of using other non-camera application programs, and can control the camera application program to execute the image data acquisition work through various gesture instructions under the condition that no visible preview interface exists, and therefore, the interaction capacity of the camera application program is improved.

Fig. 6 shows a block diagram of an image data acquisition apparatus according to an embodiment of the present invention, which corresponds to the image data acquisition method according to an embodiment of the present invention. For convenience of explanation, only the portions related to the present embodiment are shown.

Referring to fig. 6, the apparatus includes:

the first creating unit 61 is configured to create an object area with visibility lower than a first threshold when the camera application is switched to the background operation, and load a display control in the object area.

A second creating unit 62, configured to create an image preview request associated with the camera application, and bind the image preview request with the display control.

And a display unit 63, configured to display, in the object area, each frame of image data captured by the camera according to the image preview request bound to the display control.

A third creating unit 64, configured to create an image control and an image capturing request bound to the image control if an image capturing instruction sent by a user is received; the image control is used for calling the image data read by the display control in real time according to the detected image shooting request.

A first storage unit 65, configured to store the image data called by the image control.

Optionally, the first creating unit 61 includes:

and the creating subunit is used for creating a dialog box containing the display control when the camera application program is switched to the background operation.

And the first setting subunit is used for respectively setting the length of the dialog box to be smaller than a second threshold value and setting the width of the dialog box to be smaller than a third threshold value so as to enable the visibility of the dialog box to be lower than the first threshold value.

Optionally, the first creating unit 61 includes:

and the switching subunit is used for switching the display mode of the terminal screen from the single-screen display mode to the multi-screen display mode to obtain a plurality of object areas when the camera application program is switched to the background operation.

And the second setting subunit is used for setting the area occupation ratio of any one object region to be smaller than the first threshold value and loading the display control in the object region.

Optionally, the first creating unit 61 further includes:

and the acquisition subunit is used for acquiring the initial size parameter of the dialog box when the image preview event is triggered.

An adjusting subunit, configured to adjust the length and the width of the dialog box to the initial size parameters, respectively, so that the visibility of the dialog box is greater than the first threshold.

Optionally, the image data acquisition device further includes:

and the fourth creating unit is used for creating a video recording container if a video recording instruction sent by a user is received.

And the control unit is used for generating a video recording request associated with the camera application program and controlling an interface layer of the video recording container to bind the video recording request so as to obtain image stream data shot by the camera through the interface layer of the video recording container.

And the second storage unit is used for storing the image stream data in the video recording container.

In the embodiment of the invention, by creating the object area with the visibility lower than the first threshold when the camera application program is switched to the background operation, and a display control is loaded in the object area, and through the image preview request bound by the display control, each frame of image data shot by the camera is displayed in the object area, so that the visibility of each frame of image data is lower than the first threshold value, the preview picture of the camera application program can still run in the object area of the foreground under the condition that the preview picture is invisible to naked eyes, therefore, the automatic closing of the camera application program by an android system is avoided, thereby ensuring that while the user can control the application programs of other non-camera services in the foreground interface, the image data acquisition function provided by the camera application program can be used, so that the interaction capability of the camera application program is improved.

Fig. 7 is a schematic diagram of a terminal device according to an embodiment of the present invention. As shown in fig. 7, the terminal device 7 of this embodiment includes: a processor 70, a memory 71 and a computer program 72, such as an image capturing program, stored in said memory 71 and executable on said processor 70. The processor 70, when executing the computer program 72, implements the steps in the above-described respective embodiments of the image data acquisition method, such as the steps 101 to 105 shown in fig. 1. Alternatively, the processor 70, when executing the computer program 72, implements the functions of the modules/units in the above-described device embodiments, such as the functions of the units 61 to 65 shown in fig. 6.

Illustratively, the computer program 72 may be partitioned into one or more modules/units that are stored in the memory 71 and executed by the processor 70 to implement the present invention. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution process of the computer program 72 in the terminal device 7.

The terminal device 7 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices. The terminal device may include, but is not limited to, a processor 70, a memory 71. It will be appreciated by those skilled in the art that fig. 7 is merely an example of a terminal device 7 and does not constitute a limitation of the terminal device 7 and may comprise more or less components than shown, or some components may be combined, or different components, for example the terminal device may further comprise input output devices, network access devices, buses, etc.

The Processor 70 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.

The memory 71 may be an internal storage unit of the terminal device 7, such as a hard disk or a memory of the terminal device 7. The memory 71 may also be an external storage device of the terminal device 7, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the terminal device 7. Further, the memory 71 may also include both an internal storage unit and an external storage device of the terminal device 7. The memory 71 is used for storing the computer program and other programs and data required by the terminal device. The memory 71 may also be used to temporarily store data that has been output or is to be output.

In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.

The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.

The above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; 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 solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

15页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种造价辅助算量便携感应笔及其图纸快速识别方法

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!