CN113360687A - Picture saving method and device, mobile terminal and storage medium - Google Patents

Picture saving method and device, mobile terminal and storage medium Download PDF

Info

Publication number
CN113360687A
CN113360687A CN202110706774.6A CN202110706774A CN113360687A CN 113360687 A CN113360687 A CN 113360687A CN 202110706774 A CN202110706774 A CN 202110706774A CN 113360687 A CN113360687 A CN 113360687A
Authority
CN
China
Prior art keywords
picture
pictures
type
page
target
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.)
Pending
Application number
CN202110706774.6A
Other languages
Chinese (zh)
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.)
Ping An Puhui Enterprise Management Co Ltd
Original Assignee
Ping An Puhui Enterprise Management Co Ltd
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 Ping An Puhui Enterprise Management Co Ltd filed Critical Ping An Puhui Enterprise Management Co Ltd
Priority to CN202110706774.6A priority Critical patent/CN113360687A/en
Publication of CN113360687A publication Critical patent/CN113360687A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/51Indexing; Data structures therefor; Storage structures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • G06F16/2237Vectors, bitmaps or matrices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/55Clustering; Classification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformations in the plane of the image
    • G06T3/40Scaling of whole images or parts thereof, e.g. expanding or contracting
    • G06T3/4038Image mosaicing, e.g. composing plane images from plane sub-images
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2200/00Indexing scheme for image data processing or generation, in general
    • G06T2200/32Indexing scheme for image data processing or generation, in general involving image mosaicing

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application relates to picture processing, and provides a picture saving method, a device, a mobile terminal and a storage medium, wherein the method comprises the following steps: when a monitoring event preset on a webpage view is triggered, traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal; determining the picture type of each picture according to the plurality of picture tags; generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures; and acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page, and storing the plurality of target pictures according to the storage instruction. The application also relates to artificial intelligence, and aims to improve efficiency and convenience of saving pictures in batches.

Description

Picture saving method and device, mobile terminal and storage medium
Technical Field
The present application relates to the field of image processing technologies, and in particular, to an image saving method and apparatus, a mobile terminal, and a storage medium.
Background
With the development of multimedia technology and network technology, users can browse a large number of pictures through the mobile terminal every day, and the pictures are born and displayed on an H5(html5, hypertext markup language) page of the mobile terminal through a Web View Web View. When browsing pictures, a user has the action of downloading and storing pictures, but the current H5 page only supports the downloading of a single picture, so that when browsing a picture detail page consisting of a plurality of pictures, the user is not convenient to download a plurality of pictures in batches. For example, a product detailed introduction page of an online shopping mall is linked with a plurality of pictures, when a user wants to store a plurality of pictures, the user can only slide down and click the pictures one by one after storing the current picture, the workload is large, the user easily forgets that the current picture is the second picture, and the user experience is not good.
Disclosure of Invention
The application mainly aims to provide a picture saving method, a picture saving device, a mobile terminal and a storage medium, and aims to apply relevant means of artificial intelligence and improve efficiency and convenience of saving pictures in batches.
In a first aspect, the present application provides a method for saving pictures, including:
when a monitoring event preset on a webpage view is triggered, traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal;
determining the picture type of each picture according to the plurality of picture tags;
generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures;
and acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page, and storing the plurality of target pictures according to the storage instruction.
In a second aspect, the present application further provides a picture saving apparatus, including:
the system comprises a traversing module, a monitoring module and a display module, wherein the traversing module is used for traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal when a preset monitoring event on a webpage view is triggered;
the determining module is used for determining the picture type of each picture according to the plurality of picture tags;
the generating module is used for generating a picture selecting page according to the picture type of each picture and displaying the picture selecting page, and the picture selecting page comprises a plurality of pictures;
and the storage module is used for acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page and storing the plurality of target pictures according to the storage instruction.
In a third aspect, the present application further provides a mobile terminal, which includes a processor, a memory, and a computer program stored on the memory and executable by the processor, wherein when the computer program is executed by the processor, the steps of the picture saving method as described above are implemented.
In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, where the computer program, when executed by a processor, implements the steps of the picture saving method as described above.
The application provides a picture storage method, a picture storage device, a mobile terminal and a storage medium, and when a monitoring event preset on a webpage view is triggered, picture tags of a plurality of pictures of a current browsing page of the mobile terminal are traversed; determining the picture type of each picture according to the plurality of picture tags; generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures; the method comprises the steps of obtaining a storage instruction of a plurality of target pictures triggered based on a picture selection page, storing the plurality of target pictures according to the storage instruction, and effectively improving efficiency and convenience of storing the pictures in batches without clicking the pictures one by one for storing.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flowchart illustrating steps of a picture saving method according to an embodiment of the present application;
FIG. 2 is a flow chart illustrating sub-steps of the picture saving method shown in FIG. 1;
fig. 3 is a schematic diagram of a picture selection page provided in this embodiment;
fig. 4 is another schematic diagram of a picture selecting page provided in the embodiment;
fig. 5 is a schematic block diagram of a picture saving device according to an embodiment of the present application;
FIG. 6 is a schematic block diagram of a sub-module of the picture saving device of FIG. 5;
fig. 7 is a schematic block diagram of a structure of a mobile terminal according to an embodiment of the present application.
The implementation, functional features and advantages of the objectives of the present application will be further explained with reference to the accompanying drawings.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some, but not all, embodiments of the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The flow diagrams depicted in the figures are merely illustrative and do not necessarily include all of the elements and operations/steps, nor do they necessarily have to be performed in the order depicted. For example, some operations/steps may be decomposed, combined or partially combined, so that the actual execution sequence may be changed according to the actual situation. In addition, although the division of the functional blocks is made in the device diagram, in some cases, it may be divided in blocks different from those in the device diagram.
The embodiment of the application provides a picture saving method and device, a mobile terminal and a storage medium. The image saving method can be applied to a mobile terminal, and the mobile terminal can be an electronic device such as a mobile phone, a tablet computer, a notebook computer, a desktop computer, a personal digital assistant and a wearable device.
Some embodiments of the present application will be described in detail below with reference to the accompanying drawings. The embodiments described below and the features of the embodiments can be combined with each other without conflict.
Referring to fig. 1, fig. 1 is a schematic flow chart illustrating steps of a picture saving method according to an embodiment of the present disclosure.
As shown in fig. 1, the picture saving method includes steps S101 to S104.
Step S101, when a monitoring event preset on a webpage view is triggered, picture tags of a plurality of pictures of a current browsing page of the mobile terminal are traversed.
A monitoring event is set on a webpage View Web View in advance, and the monitoring event is, for example, a Long press event on Long CLick Lister, a sliding event, a dragging event, a double CLick event and the like. The monitoring event may also be an event that a picture saving instruction is detected, where the picture saving instruction is used to instruct the mobile terminal to download or save a picture.
In an embodiment, a user triggers a saving instruction of a first picture through a mobile terminal, the mobile terminal saves the first picture based on the saving instruction and triggers a monitoring event preset on a webpage view, a prompt popup window for the user to select whether to download multiple pictures in batch is generated, the user can select whether to download multiple pictures of a current browsing page in batch based on the prompt popup window, if the user sends out a picture saving instruction for downloading multiple pictures in batch based on the prompt popup window, picture tags of the multiple pictures of the current browsing page of the mobile terminal are traversed, subsequent operations are executed, and therefore the user does not need to click pictures one by one to save, and efficiency and convenience for saving the multiple pictures in batch are greatly improved.
In an embodiment, a current browsing page of the mobile terminal is an H5 page, H5 is a universal web language in which html (internet hypertext markup language) is developed to the fifth generation, and after continuous updating and improvement, H5 has a series of new web page display effect functions including a web page drawing board, a dynamic effect and the like, which provides a good technical basis for dynamic display of a mobile terminal web page. Different from the traditional enterprise website production, a large number of webpages are required to jointly form a complete website, and the H5 page only has one top-down page and can also be simply understood as a single webpage matched with various designs.
Illustratively, a user browses a plurality of pictures through the H5 page, and traverses all picture tabs on the current H5 page when a preset listening event on the web page view is triggered. The picture tab is, for example, an img tab by which the pictures in the H5 page are defined, and a placeholder is created for the referenced pictures so that the pictures can be linked to the H5 page.
In one embodiment, before traversing picture tags of a plurality of pictures of a currently browsed page of a mobile terminal, determining whether a monitoring event is triggered based on at least one picture; if the monitoring event is triggered based on at least one picture, traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal; if the monitoring event is not triggered based on the picture, no response is needed. Specifically, the determining whether the monitoring event is triggered based on at least one picture includes: if the identifier of the trigger object corresponding to the at least one trigger point is a picture identifier, determining that the monitoring event is triggered based on the at least one picture; and if the identification of the trigger object corresponding to each trigger point is not the picture identification, determining that the monitoring event is not triggered based on at least one picture.
Illustratively, the monitoring event is a long press monitoring event, when a preset long press monitoring event is triggered, an enumeration value in the Hit Test Result object is obtained, whether the enumeration value is an IMAGE identification IMAGE _ TYPE is determined, if the enumeration value is the IMAGE _ TYPE, it is determined that the long press monitoring event is triggered based on the IMAGE, which indicates that the user wants to save at least one IMAGE, and the IMAGE tags of a plurality of IMAGEs of a currently browsed page of the mobile terminal can be traversed, so that the user can select at least one IMAGE from the plurality of IMAGEs for saving.
And step S102, determining the picture type of each picture according to the plurality of picture labels.
The picture types of the pictures comprise a first type and a second type, the first type is used for representing that the pictures are network pictures, and the second type is used for representing that the pictures are local pictures. It should be noted that the picture tag is, for example, an img tag, and the img tag includes a src value, which is required, and the picture in the H5 page can be defined by the src value of the img tag. The URL (uniform resource locator) of the picture, i.e. the absolute path or relative path of the file referencing the image, can be set or returned by the src value.
In one embodiment, the URL of the picture can be changed at any time, the initial value of the URL is set by the src value of the tag img tag, when the URL of a new image is set by the src value, the browser loads and displays the new image, and the new image inherits the height and width attributes of the original image.
In one embodiment, the src value of each picture tag is obtained; determining a reference path of each picture according to the src value of each picture tag; and determining the picture type of each picture according to the reference path of each picture. The picture types comprise a first type and a second type, the first type is used for representing that the picture is a network picture, and the second type is used for representing that the picture is a local picture. The reference path of the network picture is started from http/https, the reference path of the local picture is a local storage path, and the local storage path is, for example, C \ Users \ Administrator \ Desktop, and is started from a disk code. Whether the picture type of the picture is the first type or the second type can be accurately determined according to the reference path of the picture.
Step S103, generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures.
After the picture type of each picture is determined, a picture selection page needs to be generated according to the picture type of each picture, and it needs to be noted that different processing needs to be performed on the pictures to generate the picture selection page including a plurality of pictures only when the picture types of the pictures are different. For example, if the picture type of the picture is the second type, that is, the picture is a local picture, the transcoding processing needs to be performed on the local picture to generate the picture selection page, and if the transcoding processing is not performed, the local picture cannot be inserted into a blank area of the picture selection page, and the picture selection page including the local picture cannot be generated. By generating and displaying the picture selection page, a user can selectively store pictures in batch on the basis of the picture selection page, and the picture storage efficiency and convenience are improved.
In an embodiment, as shown in fig. 2, generating the picture selection page according to the picture type of each picture includes: sub-step S1031 to sub-step S1032.
And a substep S1031, obtaining the cache information of each picture according to the picture type of each picture, and generating a coding sequence number of each picture.
In an embodiment, determining a picture type of a picture as a first type or a second type, wherein the first type is used for representing that the picture is a network picture, and the second type is used for representing that the picture is a local picture; if the picture type of the picture is the first type, obtaining cache information of the picture from a memory of the mobile terminal; if the picture type of the picture is the second type, transcoding the picture, and acquiring cache information of the transcoded picture; the cache information comprises cache position information and cache picture data.
It should be noted that, if the picture type of the picture is the first type, the picture is a network picture, and the cache information of the picture, including the cache position information of the picture and the cache picture data, may be directly obtained from the memory of the mobile terminal. If the picture type of the picture is the second type, the picture is a local picture, transcoding processing needs to be performed on the picture, and it is ensured that a picture selection page including the local picture can be generated, for example, the local picture is converted into Base64 coding, the Base64 coding is a process from binary to character, and can be used for transmitting longer identification information in an HTTP environment, so that the mobile terminal in the subsequent step can generate the picture selection page according to the cache position information and the cache picture data of the transcoded picture.
In an embodiment, the src value in the picture tag is obtained, and a serial number is added to the picture corresponding to each picture tag through the src value, so as to obtain a coding serial number of each picture. The picture adding sequence number may be randomly selected to obtain a coding sequence number, or each picture may be sorted according to src, and the coding sequence number of each picture is sequentially generated according to a sorting result, which is not limited in this embodiment.
In an embodiment, the coding sequence numbers of the pictures include a first coding sequence number of the network picture and a second coding sequence number of the local picture, and a picture selection page is generated according to the first coding sequence number and the second coding sequence number, so that a user can select the network picture and the local picture to be stored through the picture selection page conveniently.
And a substep S1032 of generating a picture selection page according to the cache information and the coding sequence number of each picture.
The mobile terminal determines the corresponding position of the picture in the picture selection page according to the coding sequence number of each picture, and then inserts the picture into the corresponding position according to the cache information of each picture to obtain the picture selection page, so that a user can selectively store a plurality of pictures based on the picture selection page.
In one embodiment, a blank page is created, the blank page comprising a plurality of blank regions; acquiring a mapping relation table between the coding serial number of the picture and the blank area; determining a blank area corresponding to each picture in the blank page according to the coding sequence number of each picture and the mapping relation table; and inserting the cache picture data in the cache information of each picture into the corresponding blank area in the blank page to obtain the picture selection page. It should be noted that each blank area corresponds to a selectable picture, and the cached picture data of the picture is inserted into the blank area, and the cached picture data is, for example, a thumbnail picture or a compressed picture, so as to obtain a picture selection page, and the picture selection page is displayed on the display interface of the mobile terminal.
In one embodiment, the blank page is created according to a preset template, for example, a template of a selected page for a blank picture including a plurality of blank areas. Wherein, the shape, position, size, arrangement mode and other parameter information of each blank area can be flexibly set by the user. Optionally, after the cached image data of the image is inserted into the blank area, the blank area is changed into a target area, a target frame is generated in the target area, and the user may select a target image to be stored from the image selection page in a manner of checking the target frame.
Illustratively, as shown in fig. 3, the picture selection page includes a plurality of blank areas 10 and a target area 20, and the target area 20 includes a target frame 21. The picture tags of a plurality of pictures of a current browsing page of the mobile terminal are traversed to obtain picture tags of 11 pictures, a picture selecting page is generated according to the picture tags of the 11 pictures, namely cache picture data of the 11 pictures are inserted into the blank area 10 to obtain 11 target areas 20, and meanwhile a target frame 21 is generated in each target area 20, so that a user can conveniently select corresponding pictures based on the target frames 21.
And S104, acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page, and storing the plurality of target pictures according to the storage instruction.
After the cached picture data of the pictures are inserted into the blank area, the blank area is changed into the target area, so that the picture selecting page comprises a plurality of target areas, the user selects a plurality of target pictures based on the plurality of target areas of the picture selecting page, and triggers a storage instruction for generating the plurality of target pictures, so that the mobile terminal can store the plurality of target pictures according to the storage instruction, the user does not need to click the pictures one by one for storage, and the efficiency and the convenience for storing the plurality of target pictures in batches are effectively improved.
In an embodiment, after the picture selection page is displayed, a trigger instruction for triggering a target area in the picture selection page by a user is acquired, an enlarged page of a corresponding picture in the target area is generated according to the trigger instruction, the target picture in the target area is selected through a control, a button and the like in the enlarged page, and a storage instruction of a plurality of target pictures is generated. The triggering mode comprises clicking operation, sliding operation, long-time pressing operation or dragging operation and the like. The user can trigger a single target area in the picture selection page for multiple times, and can also trigger multiple target areas in the picture selection page at one time. The present embodiment is not particularly limited.
In an embodiment, a user triggers a target frame of a plurality of target areas of a picture selection page so as to anchor a plurality of target pictures to be selected, then the user triggers a storage confirmation button on the picture selection page so as to generate a storage instruction of the plurality of target pictures, and the mobile terminal downloads and stores the plurality of target pictures to a default folder or an appointed folder according to the storage instruction.
In one embodiment, saving a plurality of target pictures according to the saving instruction includes: determining whether the storage instruction carries a preset identifier, wherein the preset identifier is used for indicating the mobile terminal to generate a combined picture; if the storage instruction carries a preset identifier, vue data of a plurality of target pictures are obtained from the current browsing page; converting vue data of each target picture to obtain a plurality of Bitmap data (bitmaps); and splicing the target pictures according to the bitmap data to generate a target combined picture, and storing the target combined picture. It should be noted that the target combined picture is generated and stored, so that the target combined picture is convenient for subsequent unified viewing and sharing of the plurality of target pictures, and a user does not need to send and share the target combined picture to a friend one by one, thereby facilitating sharing of the plurality of target pictures.
The method for splicing a plurality of target pictures according to a plurality of bitmap data to generate a target combined picture comprises the following steps: creating a blank canvas; determining the splicing sequence and the splicing position of each bitmap data; and splicing a plurality of bitmap data in the blank canvas according to the splicing sequence and the splicing position of each bitmap data to obtain a target combined picture. The splicing strategy for splicing a plurality of bitmap data in the blank canvas may be: and according to the splicing sequence and the splicing position of the bitmap data, splicing from top to bottom, from bottom to top, from left to right or from right to left, for example, splicing into a long picture from top to bottom to obtain a target combined picture, wherein the width of the target combined picture is the width of at least one bitmap data. The storing of the multiple target pictures according to the storing instruction may be downloading and storing only the target combination picture, or downloading and storing the target combination picture and the multiple targets at the same time, which is not limited in this embodiment.
Illustratively, as shown in fig. 4, a display interface of the mobile terminal displays a picture selection page, a user clicks target frames of a target area 201, a target area 202, a target area 203, and a target area 204 in the picture selection page, the target frames from the target area 201 to the target area 204 show a hook-shaped selection identifier, the user can click a save button 30 in the picture selection page after selecting 4 target pictures corresponding to the target area 201 to the target area 204 based on the picture selection page, so as to generate a save instruction for the 4 target pictures corresponding to the target area 201 to the target area 204, and the mobile terminal downloads and saves the 4 target pictures corresponding to the target area 201 to the target area 204 according to the save instruction.
For example, as shown in fig. 4, after the user clicks the target frames of the target area 201, the target area 202, the target area 203, and the target area 204 in the picture selection page, the user may click the composition button 40 in the picture selection page, then click the save button 30 in the picture selection page, if the user clicks the composition button 40 and then clicks the save button 30, then a save instruction of 4 target pictures corresponding to the target areas 201 to 204 is generated, where the save instruction carries a preset identifier, where the preset identifier is used to instruct the mobile terminal to generate a combined picture of the selected multiple target pictures, and the mobile terminal generates a target combined picture of the multiple target pictures according to the save instruction, and saves the target combined picture.
In the picture saving method provided by the embodiment, when a preset monitoring event on a webpage view is triggered, picture tags of a plurality of pictures of a current browsing page of the mobile terminal are traversed; determining the picture type of each picture according to the plurality of picture tags; generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures; the method comprises the steps of obtaining a storage instruction of a plurality of target pictures triggered based on a picture selection page, storing the plurality of target pictures according to the storage instruction, and effectively improving efficiency and convenience of storing the pictures in batches without clicking the pictures one by one for storing.
Referring to fig. 5, fig. 5 is a schematic block diagram of a picture saving device according to an embodiment of the present disclosure.
As shown in fig. 5, the picture saving apparatus 200 includes: a traversal module 201, a determination module 202, a generation module 203, and a save module 204.
The traversing module 201 is configured to traverse picture tags of a plurality of pictures of a currently browsed page of the mobile terminal when a monitoring event preset on a web page view is triggered;
a determining module 202, configured to determine, according to a plurality of the picture tags, a picture type of each of the pictures;
the generating module 203 is configured to generate a picture selection page according to the picture type of each picture, and display the picture selection page, where the picture selection page includes a plurality of pictures;
the storage module 204 is configured to obtain a storage instruction of multiple target pictures triggered based on the picture selection page, and store the multiple target pictures according to the storage instruction.
In one embodiment, the determination module 202 is further configured to:
acquiring the src value of each picture tag;
determining a reference path of each picture according to the src value of each picture tag;
and determining the picture type of each picture according to the reference path of each picture.
In one embodiment, as shown in fig. 6, the generating module 203 comprises:
the first generating sub-module 2031 is configured to obtain cache information of each picture according to a picture type of each picture, and generate a coding sequence number of each picture;
the second generating sub-module 2032 is configured to generate a picture selection page according to the cache information and the coding sequence number of each picture.
In one embodiment, the generation module 203 is further configured to:
determining the picture type of the picture as a first type or a second type, wherein the first type is used for representing that the picture is a network picture, and the second type is used for representing that the picture is a local picture;
if the picture type of the picture is the first type, obtaining cache information of the picture from a memory of the mobile terminal;
if the picture type of the picture is the second type, transcoding the picture, and acquiring cache information of the transcoded picture;
the cache information comprises cache position information and cache picture data.
In one embodiment, the generation module 203 is further configured to:
creating a blank page, wherein the blank page comprises a plurality of blank areas;
acquiring a mapping relation table between the coding serial number of the picture and the blank area;
determining a blank area corresponding to each picture in the blank page according to the coding sequence number of each picture and the mapping relation table;
and inserting the cache picture data in the cache information of each picture into the corresponding blank area in the blank page to obtain a picture selection page.
In one embodiment, the saving module 204 is further configured to:
determining whether the storage instruction carries a preset identifier, wherein the preset identifier is used for indicating the mobile terminal to generate a combined picture;
if the storage instruction carries a preset identifier, vue data of a plurality of target pictures are obtained from the current browsing page;
converting vue data of each target picture to obtain a plurality of bitmap data;
and splicing the target pictures according to the bitmap data to generate a target combined picture, and storing the target combined picture.
In one embodiment, the saving module 204 is further configured to:
creating a blank canvas;
determining the splicing sequence and the splicing position of each bitmap data;
and splicing a plurality of bitmap data in the blank canvas according to the splicing sequence and the splicing position of each bitmap data to obtain a target combined picture.
It should be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the apparatus and the modules and units described above may refer to the corresponding processes in the foregoing embodiment of the picture saving method, and are not described herein again.
The apparatus provided by the above embodiments may be implemented in the form of a computer program, which may be run on a mobile terminal as shown in fig. 7.
Referring to fig. 7, fig. 7 is a schematic block diagram of a structure of a mobile terminal according to an embodiment of the present disclosure.
As shown in fig. 7, the mobile terminal 300 includes a processor 301 and a memory 302 connected by a system bus 303, wherein the memory 302 may include a nonvolatile storage medium and an internal memory.
The non-volatile storage medium may store an operating system and a computer program. The computer program comprises program instructions that, when executed, cause the processor 301 to perform any of the picture saving methods.
The processor 301 is configured to provide computing and control capabilities that support the operation of the overall mobile terminal 300.
The internal memory provides an environment for running a computer program in the non-volatile storage medium, which when executed by the processor, causes the processor 301 to perform any one of the picture saving methods.
The mobile terminal 300 may also include a network interface for performing network communications, such as transmitting assigned tasks, etc. Those skilled in the art will appreciate that the architecture shown in fig. 7 is a block diagram of only a portion of the architecture associated with the subject application, and does not constitute a limitation on the mobile terminal to which the subject application applies, as a particular mobile terminal may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
It should be understood that the Processor may be a Central Processing Unit (CPU), and the Processor may be other general purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, etc. Wherein a general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
Wherein, in one embodiment, the processor is configured to execute a computer program stored in the memory to implement the steps of:
when a monitoring event preset on a webpage view is triggered, traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal;
determining the picture type of each picture according to the plurality of picture tags;
generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures;
and acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page, and storing the plurality of target pictures according to the storage instruction.
In one embodiment, the processor, when implementing the determining of the picture type for each of the pictures according to the plurality of picture tags, is configured to implement:
acquiring the src value of each picture tag;
determining a reference path of each picture according to the src value of each picture tag;
and determining the picture type of each picture according to the reference path of each picture.
In one embodiment, the processor, when implementing the generating of the picture selection page according to the picture type of each of the pictures, is configured to implement:
according to the picture type of each picture, obtaining the cache information of each picture, and generating a coding sequence number of each picture;
and generating a picture selection page according to the cache information and the coding sequence number of each picture.
In an embodiment, when implementing that the obtaining of the cache information of each of the pictures according to the picture type of each of the pictures is implemented, the processor is configured to implement:
determining the picture type of the picture as a first type or a second type, wherein the first type is used for representing that the picture is a network picture, and the second type is used for representing that the picture is a local picture;
if the picture type of the picture is the first type, obtaining cache information of the picture from a memory of the mobile terminal;
if the picture type of the picture is the second type, transcoding the picture, and acquiring cache information of the transcoded picture;
the cache information comprises cache position information and cache picture data.
In one embodiment, when the processor generates the picture selection page according to the buffering information and the coding sequence number of each picture, the processor is configured to implement:
creating a blank page, wherein the blank page comprises a plurality of blank areas;
acquiring a mapping relation table between the coding serial number of the picture and the blank area;
determining a blank area corresponding to each picture in the blank page according to the coding sequence number of each picture and the mapping relation table;
and inserting the cache picture data in the cache information of each picture into the corresponding blank area in the blank page to obtain a picture selection page.
In one embodiment, when the saving of the plurality of target pictures according to the saving instruction is implemented, the processor is configured to implement:
determining whether the storage instruction carries a preset identifier, wherein the preset identifier is used for indicating the mobile terminal to generate a combined picture;
if the storage instruction carries a preset identifier, vue data of a plurality of target pictures are obtained from the current browsing page;
converting vue data of each target picture to obtain a plurality of bitmap data;
and splicing the target pictures according to the bitmap data to generate a target combined picture, and storing the target combined picture.
In one embodiment, the processor, when implementing the splicing of the plurality of target pictures according to the plurality of bitmap data to generate a target combined picture, is configured to implement:
creating a blank canvas;
determining the splicing sequence and the splicing position of each bitmap data;
and splicing a plurality of bitmap data in the blank canvas according to the splicing sequence and the splicing position of each bitmap data to obtain a target combined picture.
It should be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working process of the mobile terminal described above may refer to the corresponding process in the foregoing embodiment of the picture saving method, and details are not described herein again.
Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, where the computer program includes program instructions, and a method implemented when the program instructions are executed may refer to the embodiments of the image saving method in the present application.
The computer-readable storage medium may be an internal storage unit of the mobile terminal described in the foregoing embodiment, for example, a hard disk or a memory of the mobile terminal. The computer readable storage medium may also be an external storage device of the mobile terminal, 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, provided on the mobile terminal.
It is to be understood that the terminology used in the description of the present application herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in the specification of the present application and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should also be understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items. It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
The above-mentioned serial numbers of the embodiments of the present application are merely for description and do not represent the merits of the embodiments. While the invention has been described with reference to specific embodiments, the scope of the invention is not limited thereto, and those skilled in the art can easily conceive various equivalent modifications or substitutions within the technical scope of the invention. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (10)

1. A picture saving method is characterized by comprising the following steps:
when a monitoring event preset on a webpage view is triggered, traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal;
determining the picture type of each picture according to the plurality of picture tags;
generating a picture selection page according to the picture type of each picture, and displaying the picture selection page, wherein the picture selection page comprises a plurality of pictures;
and acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page, and storing the plurality of target pictures according to the storage instruction.
2. The picture saving method of claim 1, wherein the determining the picture type of each of the pictures according to the plurality of picture tags comprises:
acquiring the src value of each picture tag;
determining a reference path of each picture according to the src value of each picture tag;
and determining the picture type of each picture according to the reference path of each picture.
3. The picture saving method according to claim 1, wherein the generating of the picture selection page according to the picture type of each of the pictures comprises:
according to the picture type of each picture, obtaining the cache information of each picture, and generating a coding sequence number of each picture;
and generating a picture selection page according to the cache information and the coding sequence number of each picture.
4. The picture saving method according to claim 3, wherein the obtaining the cache information of each of the pictures according to the picture type of each of the pictures comprises:
determining the picture type of the picture as a first type or a second type, wherein the first type is used for representing that the picture is a network picture, and the second type is used for representing that the picture is a local picture;
if the picture type of the picture is the first type, obtaining cache information of the picture from a memory of the mobile terminal;
if the picture type of the picture is the second type, transcoding the picture, and acquiring cache information of the transcoded picture;
the cache information comprises cache position information and cache picture data.
5. The picture saving method according to claim 3, wherein the generating a picture selection page according to the cache information and the coding sequence number of each picture comprises:
creating a blank page, wherein the blank page comprises a plurality of blank areas;
acquiring a mapping relation table between the coding serial number of the picture and the blank area;
determining a blank area corresponding to each picture in the blank page according to the coding sequence number of each picture and the mapping relation table;
and inserting the cache picture data in the cache information of each picture into the corresponding blank area in the blank page to obtain a picture selection page.
6. The picture saving method according to any one of claims 1 to 5, wherein the saving a plurality of the target pictures according to the saving instruction comprises:
determining whether the storage instruction carries a preset identifier, wherein the preset identifier is used for indicating the mobile terminal to generate a combined picture;
if the storage instruction carries a preset identifier, vue data of a plurality of target pictures are obtained from the current browsing page;
converting vue data of each target picture to obtain a plurality of bitmap data;
and splicing the target pictures according to the bitmap data to generate a target combined picture, and storing the target combined picture.
7. The picture saving method according to claim 6, wherein the splicing the plurality of target pictures according to the plurality of bitmap data to generate a target combined picture comprises:
creating a blank canvas;
determining the splicing sequence and the splicing position of each bitmap data;
and splicing a plurality of bitmap data in the blank canvas according to the splicing sequence and the splicing position of each bitmap data to obtain a target combined picture.
8. A picture saving apparatus, comprising:
the system comprises a traversing module, a monitoring module and a display module, wherein the traversing module is used for traversing picture tags of a plurality of pictures of a current browsing page of the mobile terminal when a preset monitoring event on a webpage view is triggered;
the determining module is used for determining the picture type of each picture according to the plurality of picture tags;
the generating module is used for generating a picture selecting page according to the picture type of each picture and displaying the picture selecting page, and the picture selecting page comprises a plurality of pictures;
and the storage module is used for acquiring a storage instruction of a plurality of target pictures triggered based on the picture selection page and storing the plurality of target pictures according to the storage instruction.
9. A mobile terminal, characterized in that the mobile terminal comprises a processor, a memory, and a computer program stored on the memory and executable by the processor, wherein the computer program, when executed by the processor, implements the steps of the picture saving method as claimed in any one of claims 1 to 7.
10. A computer-readable storage medium, having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the picture saving method as claimed in any one of claims 1 to 7.
CN202110706774.6A 2021-06-24 2021-06-24 Picture saving method and device, mobile terminal and storage medium Pending CN113360687A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110706774.6A CN113360687A (en) 2021-06-24 2021-06-24 Picture saving method and device, mobile terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110706774.6A CN113360687A (en) 2021-06-24 2021-06-24 Picture saving method and device, mobile terminal and storage medium

Publications (1)

Publication Number Publication Date
CN113360687A true CN113360687A (en) 2021-09-07

Family

ID=77536298

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110706774.6A Pending CN113360687A (en) 2021-06-24 2021-06-24 Picture saving method and device, mobile terminal and storage medium

Country Status (1)

Country Link
CN (1) CN113360687A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110235902A1 (en) * 2010-03-29 2011-09-29 Ebay Inc. Pre-computing digests for image similarity searching of image-based listings in a network-based publication system
CN103544207A (en) * 2013-08-19 2014-01-29 Tcl集团股份有限公司 Picture loading and displaying method and system
WO2018191889A1 (en) * 2017-04-19 2018-10-25 广东欧珀移动通信有限公司 Photo processing method and apparatus, and computer device
CN110222209A (en) * 2019-06-14 2019-09-10 北京马赫谷科技有限公司 Picture storage method, querying method, device and access system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110235902A1 (en) * 2010-03-29 2011-09-29 Ebay Inc. Pre-computing digests for image similarity searching of image-based listings in a network-based publication system
CN103544207A (en) * 2013-08-19 2014-01-29 Tcl集团股份有限公司 Picture loading and displaying method and system
WO2018191889A1 (en) * 2017-04-19 2018-10-25 广东欧珀移动通信有限公司 Photo processing method and apparatus, and computer device
CN110222209A (en) * 2019-06-14 2019-09-10 北京马赫谷科技有限公司 Picture storage method, querying method, device and access system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
腾讯视频: "《存图宝—怎么保存淘宝视频和淘宝图片》", 《腾讯视频》 *

Similar Documents

Publication Publication Date Title
US7805495B2 (en) Method and system for transferring web browser data between web browsers
US8122104B2 (en) Method and system for providing XML-based asynchronous and interactive feeds for web applications
US9612715B2 (en) Real-time preview of uniform resource identifier addressable dynamic content
US20140380229A1 (en) System, method and user interface for designing customizable products from a mobile device
US10691875B2 (en) Populating visual designs with web content
CN102929599B (en) The amending method at browser of mobile terminal interface and device, mobile terminal
US20210149842A1 (en) System and method for display of document comparisons on a remote device
CN108595697B (en) Webpage integration method, device and system
WO2023093673A1 (en) Information processing method, apparatus and system, and storage medium
US9003309B1 (en) Method and apparatus for customizing content displayed on a display device
CN110968314B (en) Page generation method and device
TWI519980B (en) Method and device for displaying web page and computer-readable storage medium
CN108319474B (en) Page information generation method, device and equipment
CN104598467B (en) Webpage picture display method and device
CN113792208B (en) Picture interaction method, device, equipment, medium and program product based on webpage
CN117093386B (en) Page screenshot method, device, computer equipment and storage medium
JP6505849B2 (en) Generation of element identifier
US20190138577A1 (en) Providing dynamic web content without flicker
CN105867984A (en) Method, device and client for displaying task state in web page as well as mobile equipment
CN103136273A (en) Method and device for displaying user information in webpage
CN113360687A (en) Picture saving method and device, mobile terminal and storage medium
CN114417226A (en) Page generation method, display method, device, electronic equipment and storage medium
CN114168875A (en) Page program generation method and device, computer equipment and storage medium
CN112287261A (en) Resource loading method and electronic equipment
CN113918142B (en) Data acquisition task code generation method, device and computer equipment

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210907