WO2018201993A1 - Image drawing method, terminal and storage medium - Google Patents
Image drawing method, terminal and storage medium Download PDFInfo
- Publication number
- WO2018201993A1 WO2018201993A1 PCT/CN2018/084978 CN2018084978W WO2018201993A1 WO 2018201993 A1 WO2018201993 A1 WO 2018201993A1 CN 2018084978 W CN2018084978 W CN 2018084978W WO 2018201993 A1 WO2018201993 A1 WO 2018201993A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- parameter
- splitting
- terminal
- duration
- split
- 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.)
- Ceased
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/11—Region-based segmentation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/14—Digital output to display device ; Cooperation and interconnection of the display device with other functional units
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T11/00—2D [Two Dimensional] image generation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T11/00—2D [Two Dimensional] image generation
- G06T11/40—Filling a planar surface by adding surface attributes, e.g. colour or texture
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20021—Dividing image into blocks, subimages or windows
Definitions
- the present invention relates to the field of image processing technologies, and in particular, to an image drawing method and a terminal.
- the picture display is that the terminal draws the picture onto the screen of the terminal, and the terminal draws the picture by texture, but the size of the single texture that can be drawn is limited by the capability of the terminal. Therefore, when the size of the picture is less than or equal to the size of a single texture that the terminal can draw, the terminal can directly draw the picture. However, when the size of the picture is larger than the size of a single texture that the terminal can draw, the terminal cannot directly draw the picture directly.
- the technical problem to be solved by the embodiments of the present invention is to provide an image drawing method and a terminal to improve the splitting and drawing efficiency of the image data to be drawn.
- an embodiment of the present invention provides an image drawing method, including:
- Each of the sub-image data to be drawn is drawn to a corresponding drawing sub-region, and a drawing image of the image data to be drawn is obtained.
- An embodiment of the present invention provides a terminal, including: a processor and a memory, where the processor executes readable machine instructions in the memory for
- Each of the sub-image data to be drawn is drawn to a corresponding drawing sub-region, and a drawing image of the image data to be drawn is obtained.
- An embodiment of the invention provides a computer storage medium, characterized in that
- the computer storage medium may store a program, and the program includes an image drawing method according to an embodiment of the present invention.
- FIG. 1 is a schematic diagram of a network architecture according to an embodiment of the present invention
- FIG. 2 is a schematic flowchart of an image drawing method according to an embodiment of the present invention.
- FIG. 3 is a schematic diagram of splitting image data to be drawn according to an embodiment of the present invention.
- FIG. 3b is a schematic diagram of splitting a drawing area corresponding to image data to be drawn according to an embodiment of the present invention
- FIG. 4 is a schematic flow chart of another image drawing method according to an embodiment of the present invention.
- FIG. 5 is a schematic flowchart diagram of still another image drawing method according to an embodiment of the present invention.
- FIG. 6 is a schematic structural diagram of a terminal according to an embodiment of the present disclosure.
- FIG. 7 is a schematic structural diagram of another terminal according to an embodiment of the present invention.
- the size of the picture that the terminal needs to draw is larger and larger, even larger than the size of a single texture that the terminal can draw, that is, when the picture is a large size picture
- a large-size picture refers to a picture that exceeds the viewable range of the screen.
- a picture that exceeds half of the maximum texture supported by the hard-dissolving mode of the terminal device is referred to as a large-size picture.
- the hard solution method is hardware decoding, which means that the GPU is used to partially replace the CPU for decoding.
- a part of the image data that is originally processed by the CPU is handed over to the GPU, and the parallel computing power of the GPU is much higher than the CPU. It can greatly reduce the load on the CPU. After the CPU usage is low, you can run some other programs at the same time.
- the large-size picture is split according to a unified splitting manner, resulting in unsatisfactory splitting effect of some large-sized pictures, and further There is no guarantee that the picture will be drawn.
- An image drawing method provided by an embodiment of the present invention can be applied to a scene in which an image is drawn by a terminal.
- FIG. 1 is a schematic diagram of a network architecture disclosed in an embodiment of the present invention.
- a server 1 for providing image data to be drawn and a terminal 2 for drawing image data to be drawn may be included, wherein the server 1 and the terminal 2 may be connected through a network.
- the terminal 2 may send a request to the server 1 to obtain image data to be drawn, and the server 1 may acquire image data to be drawn in response to the request of the terminal 2, and send the image data to be drawn to the terminal 2 through the network, and the terminal 2 may pass The image data to be drawn sent by the network receiving server 1 is drawn and displayed.
- the execution subject of the embodiment is a terminal
- the terminal that is, the terminal device 2
- the terminal device 2 may include: a mobile phone, a computer, a tablet computer,
- a smart terminal that can play a video file, such as a notebook, is only an example, and is not exhaustive, and includes, but is not limited to, the above terminal.
- FIG. 2 is a schematic flowchart diagram of an embodiment of an image drawing method according to an embodiment of the present invention.
- An image drawing method according to an embodiment of the present invention includes the following steps:
- the image data to be drawn may be image data that the terminal needs to display and display.
- the image data to be drawn may be image data received by the terminal from the image server, or may be a terminal, for example, image data obtained by the terminal device processing the locally stored image data, such as performing an enlargement operation on the currently displayed image.
- the terminal may receive a drawing instruction to draw the image data to be drawn.
- the image data to be drawn obtained by the terminal after performing the zoom-in operation on the currently displayed image may be: the terminal determines the zoom-in ratio according to the zoom-in operation, and performs an enlargement operation on the data corresponding to the displayed image according to the zoom-in ratio to obtain image data to be drawn.
- the terminal may first acquire size information of image data to be drawn, and the size information may include information of length and width of an image to be drawn and displayed on the page. After the terminal obtains the size information of the image data to be drawn, the terminal may detect whether the size information satisfies a preset condition, where the preset condition may be associated with the size information of the maximum texture that the terminal can support when drawing the image data. If the preset condition is greater than or equal to the size information that the terminal can support the maximum texture when the image data is drawn, or the preset condition may be greater than or equal to the size information of the maximum texture that can be supported when the terminal draws the image data. half.
- the preset condition may be related to the size information of the display interface of the terminal, for example, the preset condition may be greater than or equal to the size information of the display interface of the terminal, wherein the preset condition may also be other conditions. There is no restriction here.
- the terminal when the terminal determines that the size information of the image data to be drawn satisfies the preset condition, the terminal may determine that the image data to be drawn is image data of a large size, and needs to be split and drawn.
- the terminal can perform the split drawing on the image data to be drawn, which can be understood as that the terminal splits the image data to be drawn into a plurality of sub-image data to be drawn, and respectively renders multiple sub-image data to be rendered on the page.
- a sub-image, the plurality of sub-images may constitute a post-image of the image data to be drawn. Therefore, when the terminal determines that the image data to be drawn is split and drawn, the terminal may acquire a target split parameter that matches the terminal.
- the terminal may first query, in the storage area of the terminal, whether to store the target split parameter that matches the terminal.
- the terminal may acquire the target split parameter.
- the terminal may preset a correspondence between the terminal identifier and the split parameter. Therefore, the terminal can obtain the target terminal identifier of the terminal, and query whether there is a target split parameter corresponding to the target terminal identifier according to the correspondence between the terminal identifier and the split parameter, and when the target split identifier corresponding to the target terminal identifier is queried, The terminal may determine that the target splitting parameter matching the terminal is stored, and obtain the target splitting parameter corresponding to the target terminal identifier.
- the splitting parameter may be a natural number, such as a natural number such as 1, 2, and 4. It can also be a function related to a preset argument.
- S101 Perform a splitting process on the drawing area on the terminal corresponding to the image data to be drawn and the image data to be drawn according to the target splitting parameter.
- the terminal when the terminal obtains the image data to be drawn, the terminal may also acquire a drawing area corresponding to the image data to be drawn, and the drawing area is used to draw an image corresponding to the image data to be drawn. Therefore, when the terminal acquires the target splitting parameter, the terminal may separately split the image to be drawn and the corresponding drawing area according to the target splitting parameter.
- FIG. 3a When the target split parameter obtained by the terminal is 4, FIG. 3a is image data to be drawn, and the terminal divides the image data to be drawn according to the target split parameter. The split can be split as shown by the dotted line.
- FIG. 3b is a drawing area corresponding to the image data to be drawn, and the terminal splits the drawing area corresponding to the image data to be drawn according to the target splitting parameter, and can be split and split as shown by a broken line.
- the terminal may obtain at least one sub-image data to be drawn and each to be drawn after the splitting process.
- the drawing sub-region corresponding to the image data For details, refer to the split diagram shown in FIG. 3a and FIG. 3b.
- FIG. 3a is image data to be drawn
- the terminal divides the image data to be drawn according to the target split parameter.
- the terminal can obtain four sub-image data to be drawn after the split processing.
- the drawing area corresponding to the image data to be drawn may be as shown in the drawing area in FIG.
- the terminal may The four drawing sub-regions after the splitting process are obtained, wherein the terminal can establish a correspondence between the sub-image data to be drawn and the drawing sub-region according to the position drawn by each sub-image data to be drawn in the image data to be drawn.
- the terminal may use the hard solution method to draw the sub-image data to be drawn according to the corresponding relationship between the sub-image data to be drawn and the drawing sub-region to the corresponding drawing.
- the area is such that the drawn drawing sub-area can be spliced into a post-image of the image data to be drawn, wherein the image after drawing can be understood as an image displayed after the image data to be drawn is drawn.
- the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn.
- the terminal can obtain the preset target splitting parameter matching the terminal, and split the drawing area corresponding to the image data to be drawn and the image data to be drawn according to the obtained target splitting parameter of the terminal, and respectively obtain the to-be-drawn child.
- the image data and the drawing sub-region corresponding to each sub-image data to be drawn are drawn to each corresponding sub-image region.
- the technical solution can ensure that the target splitting parameter is obtained for the terminal, and the splitting parameter and the subsequent drawing operation are performed by using the target splitting parameter of the terminal, so that different splitting and drawing schemes can be ensured for different terminals to ensure Draw the effect.
- FIG. 4 is a schematic flowchart diagram of an embodiment of an image drawing method according to an embodiment of the present invention.
- An image drawing method according to an embodiment of the present invention includes the following steps:
- the terminal may first query whether to store the target split parameter that matches the terminal.
- the correspondence between the terminal identifier and the split parameter may be preset. Therefore, the terminal can obtain the target terminal identifier of the terminal, and query whether there is a target splitting parameter corresponding to the target terminal identifier according to the correspondence between the terminal identifier and the splitting parameter.
- the terminal may determine that the target splitting parameter matching the terminal is not stored, and step S201 is performed.
- the split parameter set may include at least one split parameter.
- the split parameter set may include: a set consisting of 1, 2, 4, 6, and 8. It may also include more collections of natural numbers, or may be a collection of all natural numbers within a certain range of values.
- the set of split parameters may be a natural number in the range of 1 to 10, which can be set by the user, Make restrictions.
- the terminal searches in the preset split parameter set, and obtains the target split parameter matched with the terminal, which may be: the terminal first draws the image data to be drawn by using each split parameter in the split parameter set, and the record is based on each The duration of the drawing parameter to draw the image data, so as to obtain the duration of the drawing corresponding to each split parameter, wherein the drawing duration is the length of time used to draw the image data to be drawn based on each split parameter.
- the terminal may start recording the duration used by the terminal to draw the image data to be drawn based on the split parameter, and the terminal determines to wait based on the split parameter.
- the terminal may end the length of time used by the recording terminal to draw the image data to be drawn based on the splitting parameter, so that the terminal can obtain the corresponding parameter of the splitting parameter.
- the duration of the drawing is long.
- the drawing duration is a duration used to draw the image data to be drawn based on the split parameter. Therefore, the terminal can obtain the duration of the drawing corresponding to each split parameter in the above manner.
- the terminal when the terminal obtains the duration of the drawing duration corresponding to each splitting parameter, the terminal may obtain the shortest duration of the drawing duration corresponding to each of the splitting parameters.
- the sub-parameter that is, the shortest splitting parameter used by the terminal to obtain the drawing process, is determined as the splitting parameter to be determined, and the splitting parameter to be determined is set as the target splitting parameter.
- the terminal searches in the preset split parameter set, and obtains the target split parameter that matches the terminal.
- the terminal may first arrange all the split parameters in the split parameter set according to the preset order.
- the arranged split parameter arrangement set for example, the terminal may arrange the split parameter sets according to the numerical order from small to large, and obtain the arranged split parameter arrangement set. For example, when the split parameter set includes 1, 8, 6, 2, 4, 3, 5, 7, the terminal can arrange the split parameter sets according to the order of the values from small to large, and obtain the arranged split parameter arrangement set. It is 1, 2, 3, 4, 5, 6, 7, 8.
- the terminal may search, in the split parameter arrangement set, that the corresponding drawing duration is less than or equal to the mapping duration of the adjacent split parameter.
- the splitting parameter is determined, and the splitting parameter to be determined is set as the target splitting parameter, wherein the drawing duration is the length of time used to draw the image data to be drawn based on the splitting parameter.
- the terminal may determine that the drawing duration corresponding to the determined splitting parameter is split.
- the shortest duration of the drawing duration corresponding to all the splitting parameters in the parameter arrangement set, and the time required to split and draw the image data to be drawn by the splitting parameter is the shortest, thereby effectively saving the processing steps of the terminal and improving the terminal. operating efficiency.
- the determining, by the terminal, in the split parameter arrangement set, the corresponding mapping duration duration is less than or equal to the mapping duration of the adjacent splitting parameter, and the determining the splitting parameter may be: the terminal may be in the split parameter ranking set.
- the terminal when the split parameter arrangement set is 1, 2, 3, 4, 5, 6, 7, 8, 9, and 10, when the split parameter determined by the terminal is 3, the incremental direction is positive, for example, split.
- the terminal can obtain the first split parameter of interval 1 of 4 in the positive direction of 3.
- the terminal may obtain the second drawing duration corresponding to the first splitting parameter. Therefore, the terminal may determine whether the duration of the first drawing duration is less than or equal to the duration of the second drawing duration.
- the terminal may obtain any one of the split parameter arrangement sets.
- the second splitting parameter of the adjacent parameter is arranged by the parameter.
- the terminal may obtain the second splitting parameter of the adjacent arrangement of any splitting parameter according to the opposite direction and the incremental value of the preset incremental direction.
- the split parameter arrangement set is 1, 2, 3, 4, 5, 6, 7, 8, 9, and 10
- the split parameter determined by the terminal is 3, the incremental direction is positive direction and increment.
- the terminal can obtain the second split parameter of interval 1 in the opposite direction of the positive direction of 3, that is, the direction in which the split parameter number is decreased.
- the terminal when the terminal acquires the second splitting parameter, the terminal may obtain the third drawing duration of the second splitting parameter, and determine whether the first drawing duration is less than or equal to the third drawing duration.
- the terminal may set any of the splitting parameters to the to-be-determined splitting parameter, and the to-be-determined splitting parameter may be in the splitting parameter arrangement set.
- the corresponding drawing durations are less than or equal to the to-be-determined splitting parameters of the drawing duration corresponding to the adjacent splitting parameters.
- the terminal may obtain the adjacent third splitting parameter of the first splitting parameter according to the incremental direction and the incremental value, and the third splitting The sub-parameter is set to any of the split parameters to perform the first drawing duration step corresponding to any split parameter in the split parameter arrangement set.
- the terminal may obtain the adjacent fourth splitting parameter of the second splitting parameter according to the opposite direction and the incremental value of the incremental direction, and the fourth splitting The sub-parameter is set to any of the split parameters to perform the first drawing duration step corresponding to any split parameter in the split parameter arrangement set.
- the terminal when the terminal traverses to the last split parameter in the split parameter arrangement set, the terminal may set the last split parameter to the split parameter to be determined. After the terminal acquires the split parameter to be determined, the terminal may set the to-be-determined target split parameter.
- the terminal may further record, as a set of record information, a drawing duration corresponding to the to-be-determined splitting parameter and the to-be-determined splitting parameter, into the preset recording area, where the recording area may be Store the list.
- S204 Draw each sub-image data to be drawn to a corresponding drawing sub-region, and obtain a post-image of the image data to be drawn.
- the specific implementation manners of the step S100, the step S202, the step S203, and the step S204 are also referred to the specific implementation manners of the step S100, the step S101, the step S102, and the step S103 in the foregoing embodiment. Narration.
- the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn.
- the terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
- FIG. 5 is a schematic flowchart diagram of an embodiment of an image drawing method according to an embodiment of the present invention.
- An image drawing method according to an embodiment of the present invention includes the following steps:
- the recording area may record a plurality of sets of record information, and each set of record information may include a split parameter to be determined and a corresponding draw duration. Therefore, the terminal can divide the record information including the same split parameter into the same split parameter to be determined. Wherein, when the terminal detects that there is data update in the recording area, the terminal may perform the step, or the terminal may trigger the execution of the step according to a preset period.
- the terminal may perform a summation and averaging operation on all the durations of the drawing included in the at least one group of the record information including the same type of the split parameter to be determined, thereby obtaining an average corresponding to the determined split parameter.
- Draw duration Similarly, according to the step of obtaining the average duration of the splitting parameter, the terminal can obtain the average drawing duration corresponding to each of the determined splitting parameters.
- step S304, step S305, step S306, and step S307 can also refer to the specific implementation manners of step S100, step S101, step S102, and step S103 in the foregoing embodiment, where no specific implementation is performed. Narration.
- the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn.
- the terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
- the terminal provided by the embodiment of the present invention will be described in detail below with reference to FIG. 6-7. It should be noted that the terminal shown in FIG. 6-7 is used to perform the method of the embodiment shown in FIG. 1 to FIG. 5 of the present invention. For the convenience of description, only the part related to the embodiment of the present invention is specifically illustrated. The technical details are not disclosed, please refer to the embodiment shown in Figs. 1 to 5 of the present invention.
- FIG. 6 is a schematic structural diagram of a terminal according to an embodiment of the present invention. As shown in FIG. 7, the terminal in the embodiment of the present invention may include:
- the first obtaining unit 100 is configured to acquire a target splitting parameter that matches the terminal.
- the splitting unit 200 is configured to separately perform a splitting process on the image to be drawn and the drawing area corresponding to the image data to be drawn according to the target splitting parameter;
- the second obtaining unit 300 is configured to obtain at least one sub-image data to be drawn after the split processing and a drawing sub-region corresponding to each sub-image data to be drawn.
- the drawing unit 400 is configured to draw each to-be-drawn sub-image data to a corresponding drawing sub-region, and obtain a post-rendering image of the image data to be drawn.
- the terminal further includes:
- a third acquiring unit configured to acquire size information of the image data to be drawn
- a detecting unit configured to detect whether the size information meets a preset condition
- the first acquiring unit 100 is notified to acquire a target splitting parameter that matches the terminal.
- the first obtaining unit 100 includes:
- a detecting subunit configured to detect whether the terminal stores a target splitting parameter that matches the terminal
- the detecting subunit detects that the terminal stores the target splitting parameter, notifying the first acquiring unit to acquire a target splitting parameter that matches the terminal;
- Searching a subunit configured to perform a search in a preset split parameter set when the detecting subunit detects that the terminal does not store the target split parameter, and acquire a target split parameter that matches the terminal
- the set of split parameters includes at least one split parameter.
- the search subunit includes:
- a first obtaining sub-unit configured to obtain a drawing duration duration corresponding to each of the splitting parameters, wherein the drawing duration is a duration used to draw the image data to be drawn based on each of the splitting parameters;
- a second obtaining sub-unit configured to obtain a to-be-determined splitting parameter corresponding to a drawing duration that has the shortest duration in each of the drawing durations corresponding to each of the splitting parameters
- a first setting subunit configured to set the to-be-determined splitting parameter to the target splitting parameter.
- the search subunit includes:
- Arranging subunits for arranging all the splitting parameters in the split parameter set according to a preset arrangement order, and obtaining the arranged split parameter arrangement set;
- a third obtaining sub-unit configured to search, in the split parameter arrangement set, a corresponding splitting parameter whose mapping duration duration is less than or equal to a drawing duration duration corresponding to the adjacent splitting parameter, where the drawing The duration is a duration used to draw the image data to be drawn based on the split parameter;
- a second setting subunit configured to set the to-be-determined splitting parameter to the target splitting parameter.
- the third obtaining subunit includes:
- a fourth acquiring sub-unit configured to obtain, in the split parameter arrangement set, a first drawing duration duration corresponding to any one of the splitting parameters
- a fifth obtaining sub-unit configured to acquire, in the split parameter arrangement set, a first splitting parameter adjacent to any one of the splitting parameters, and obtain a second drawing duration corresponding to the first splitting parameter duration;
- a sixth obtaining subunit when it is determined that the first drawing duration is less than or equal to the second drawing duration, acquiring, in the split parameter arrangement set, adjacent to the any one of the splitting parameters Dividing the parameters, and obtaining a third drawing duration corresponding to the second splitting parameter;
- a seventh acquiring sub-unit when determining that the first drawing duration is less than or equal to the third drawing duration, setting any one of the splitting parameters to the to-be-determined splitting parameter.
- the third obtaining subunit further includes:
- a third setting subunit configured to acquire an adjacent third splitting parameter of the first splitting parameter when determining that the first drawing duration is greater than the second drawing duration, and The three split parameters are set to any one of the split parameters;
- the third obtaining subunit further includes:
- a fourth setting subunit configured to: when determining that the first drawing duration is greater than the third drawing duration, acquiring an adjacent fourth splitting parameter of the second splitting parameter, and The four split parameters are set to any one of the split parameters;
- the fourth obtaining sub-unit is notified to obtain the first drawing duration duration corresponding to any one of the splitting parameters in the split parameter arrangement set.
- the terminal further includes:
- a recording unit configured to record the duration of the drawing corresponding to the to-be-determined splitting parameter and the to-be-determined splitting parameter as a set of record information into the preset recording area.
- the terminal further includes:
- a classifying unit configured to classify at least one set of record information included in the record area according to at least one type of the split parameter to be determined included in the record area, and obtain at least one corresponding to each of the to-be-determined split parameters Group record information;
- a calculating unit configured to calculate, according to a duration included in each of the at least one set of record information corresponding to each of the to-be-determined split parameters, an average draw duration corresponding to each of the to-be-determined split parameters to be determined;
- a fourth obtaining unit configured to obtain an average drawing duration of the shortest duration in the average drawing duration corresponding to each of the to-be-determined splitting parameters
- a setting unit configured to store the to-be-determined split parameter corresponding to the shortest average draw duration of the duration as the target split parameter matched with the terminal.
- the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn.
- the terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
- FIG. 7 is a schematic structural diagram of another terminal according to an embodiment of the present invention.
- the terminal 1000 may include at least one processor 1001, such as a CPU, at least one network interface 1004, a user interface 1003, a memory 1005, and at least one communication bus 1002.
- the communication bus 1002 is used to implement connection communication between these components.
- the user interface 1003 can include a display and a keyboard.
- the optional user interface 1003 can also include a standard wired interface and a wireless interface.
- the network interface 1004 can include a standard wired interface, a wireless interface (such as a WI-FI interface).
- the memory 1005 may be a high speed RAM memory or a non-volatile memory such as at least one disk memory.
- the memory 1005 may also be at least one storage device located remotely from the aforementioned processor 1001. As shown in FIG. 7, an operating system, a network communication module, a user interface module, and a communication connection application may be included in the memory 1005 as a computer storage medium.
- the user interface 1003 is mainly used to provide an input interface for the user to acquire data input by the user;
- the network interface 1004 is configured to connect with the news server to acquire data sent by the news server;
- the processor 1001 may be used to call a communication connection application stored in the memory 1005, and specifically perform the steps in the method shown in FIG. 2, FIG. 4, and FIG. 5, and the operation of the terminal shown in FIG. 6, for example,
- Each of the sub-image data to be drawn is drawn to a corresponding drawing sub-region, and the post-image of the image data to be drawn is obtained.
- the processor 1001 performs: before the processor 1001 acquires a target split parameter that matches the terminal:
- the step of acquiring a target split parameter matching the terminal is performed.
- the processor 1001 acquires target split parameters that match the terminal, including:
- the terminal When it is detected that the terminal does not store the target splitting parameter, searching for a target splitting parameter that matches the terminal in a preset split parameter set, where the split parameter set includes at least one split Sub-parameters.
- the processor 1001 performs a search in a preset split parameter set, and obtains a target split parameter that matches the terminal, including:
- the drawing duration is a length of time for drawing the image data to be drawn based on each of the splitting parameters
- the to-be-determined split parameter is set as the target split parameter.
- the processor 1001 searches for a target split parameter that matches the terminal in a preset split parameter set, including:
- the to-be-determined split parameter is set as the target split parameter.
- the processor 1001 searches for the to-be-determined splitting parameters in the split parameter arrangement set, where the corresponding mapping durations are less than or equal to the mapping durations of the adjacent splitting parameters, including:
- the any one of the splitting parameters is set as the to-be-determined splitting parameter.
- the processor 1001 obtains a first split parameter adjacent to the split parameter in the split parameter arrangement set, and acquires a second draw duration corresponding to the first split parameter. After the duration, the processor 1001 also performs:
- the method After obtaining the first splitting parameter adjacent to the splitting parameter in the split parameter arrangement set, and acquiring the second drawing duration duration corresponding to the first splitting parameter, the method includes:
- the processor 1001 further performs: after the processor 1001 searches for a target split parameter that matches the terminal in a preset split parameter set, the processor 1001 further performs:
- the processor 1001 further performs: before the processor 1001 acquires a target split parameter that matches the terminal:
- the to-be-determined split parameter corresponding to the shortest average draw duration of the duration is stored as a target split parameter that matches the terminal.
- the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn.
- the terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
- the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Human Computer Interaction (AREA)
- General Engineering & Computer Science (AREA)
- Processing Or Creating Images (AREA)
- Image Processing (AREA)
Abstract
Description
本申请要求于2017年5月2日提交中国专利局、申请号为201710301745.5、发明名称为“一种图像绘制方法及终端”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。The present application claims priority to Chinese Patent Application No. 200910301745.5, entitled "An Image Drawing Method and Terminal", filed on May 2, 2017, the entire contents of which is incorporated herein by reference. .
本发明涉及图像处理技术领域,尤其涉及一种图像绘制方法及终端。The present invention relates to the field of image processing technologies, and in particular, to an image drawing method and a terminal.
随着智能终端的发展和普及,用户使用智能终端显示图片越来越普遍。并且随着页面的内容越来越丰富,图片的尺寸也越来越大。对于终端来说,图片显示是终端将图片绘制至终端的屏幕上,终端是通过纹理来绘制图片,但其可绘制的单个纹理的尺寸大小是受限于终端的能力。因此,当图片的尺寸小于或等于终端可绘制的单个纹理的尺寸大小时,终端可直接对图片进行绘制。但是,当图片的尺寸大于终端可绘制的单个纹理的尺寸大小时,终端无法直接对该图片进行直接绘制。With the development and popularization of smart terminals, it is more and more common for users to display pictures using smart terminals. And as the content of the page becomes more and more abundant, the size of the image is also getting larger and larger. For the terminal, the picture display is that the terminal draws the picture onto the screen of the terminal, and the terminal draws the picture by texture, but the size of the single texture that can be drawn is limited by the capability of the terminal. Therefore, when the size of the picture is less than or equal to the size of a single texture that the terminal can draw, the terminal can directly draw the picture. However, when the size of the picture is larger than the size of a single texture that the terminal can draw, the terminal cannot directly draw the picture directly.
发明内容Summary of the invention
本发明实施例所要解决的技术问题在于,提供一种图像绘制方法及终端,以提高待绘制图像数据的拆分及绘制效率。The technical problem to be solved by the embodiments of the present invention is to provide an image drawing method and a terminal to improve the splitting and drawing efficiency of the image data to be drawn.
为了解决上述技术问题,本发明一实施例提供了一种图像绘制方法,包括:In order to solve the above technical problem, an embodiment of the present invention provides an image drawing method, including:
获取与终端匹配的目标拆分参数;Obtain a target split parameter that matches the terminal;
按所述目标拆分参数对待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分处理;Performing splitting processing on the drawing area corresponding to the image data to be drawn and the image data to be drawn according to the target splitting parameter;
获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域;Obtaining at least one sub-image data to be drawn after the splitting process and a drawing sub-region corresponding to each sub-image data to be drawn;
将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制图像。Each of the sub-image data to be drawn is drawn to a corresponding drawing sub-region, and a drawing image of the image data to be drawn is obtained.
本发明一实施例提供了一种终端,包括:处理器和存储器,所述处理器执行所述存储器中的可读机器指令,用于An embodiment of the present invention provides a terminal, including: a processor and a memory, where the processor executes readable machine instructions in the memory for
获取与终端匹配的目标拆分参数;Obtain a target split parameter that matches the terminal;
按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分处理;Splitting the drawing area corresponding to the image data to be drawn and the image data to be drawn according to the target splitting parameter;
获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域;Obtaining at least one sub-image data to be drawn after the splitting process and a drawing sub-region corresponding to each sub-image data to be drawn;
将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制图像。Each of the sub-image data to be drawn is drawn to a corresponding drawing sub-region, and a drawing image of the image data to be drawn is obtained.
本发明一实施例提供了一种计算机存储介质,其特征在于,An embodiment of the invention provides a computer storage medium, characterized in that
所述计算机存储介质可存储有程序,该程序执行时包括本发明实施例所述的一种图像绘制方法。The computer storage medium may store a program, and the program includes an image drawing method according to an embodiment of the present invention.
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments or the description of the prior art will be briefly described below. Obviously, the drawings in the following description are only It is a certain embodiment of the present invention, and other drawings can be obtained from those skilled in the art without any creative work.
图1是本发明实施例提供的一种网络构架示意图;FIG. 1 is a schematic diagram of a network architecture according to an embodiment of the present invention;
图2是本发明实施例提供的一种图像绘制方法的流程示意图;2 is a schematic flowchart of an image drawing method according to an embodiment of the present invention;
图3a是本发明实施例提供的一种待绘制图像数据的拆分示意图;FIG. 3 is a schematic diagram of splitting image data to be drawn according to an embodiment of the present invention; FIG.
图3b是本发明实施例提供的一种待绘制图像数据对应的绘制区域的拆分示意图;FIG. 3b is a schematic diagram of splitting a drawing area corresponding to image data to be drawn according to an embodiment of the present invention; FIG.
图4是本发明实施例提供的另一种图像绘制方法的流程示意图;4 is a schematic flow chart of another image drawing method according to an embodiment of the present invention;
图5是本发明实施例提供的又一种图像绘制方法的流程示意图;FIG. 5 is a schematic flowchart diagram of still another image drawing method according to an embodiment of the present invention; FIG.
图6是本发明实施例提供的一种终端结构示意图;FIG. 6 is a schematic structural diagram of a terminal according to an embodiment of the present disclosure;
图7是本发明实施例提供的另一种终端结构示意图。FIG. 7 is a schematic structural diagram of another terminal according to an embodiment of the present invention.
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are only a part of the embodiments of the present invention, but not all embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
在本申请一实施例中,随着拍摄技术的提高,终端需进行绘制的图片的尺寸越来越大,甚至大于终端可绘制的单个纹理的尺寸大小,即该图片为大尺寸图片时,其中大尺寸图片是指超过屏幕可视范围的图片,例如对于屏幕比较大的终端设备来说,则将超过该终端设备的硬解方式所支持的最大纹理的一半的图片称为大尺寸图片。硬解方式就是硬件解码,指利用GPU来部分代替CPU进行解码,将原来全部交由CPU来处理的图像数据的一部分交由GPU来做,而GPU的并行运算能力要远远高于CPU,这样可以大大的降低CPU的负载,CPU的占用率较低了之后就可以同时运行一些其他的程序了。在本实施例中,当在终端设备显示大尺寸图片时,对于具有不同显示能力的终端设备,根据统一的拆分方式拆分大尺寸图片,导致部分大尺寸图片的拆分效果不理想,进而无法保证图片的绘制效果。In an embodiment of the present application, as the shooting technique is improved, the size of the picture that the terminal needs to draw is larger and larger, even larger than the size of a single texture that the terminal can draw, that is, when the picture is a large size picture, A large-size picture refers to a picture that exceeds the viewable range of the screen. For example, for a terminal device having a relatively large screen, a picture that exceeds half of the maximum texture supported by the hard-dissolving mode of the terminal device is referred to as a large-size picture. The hard solution method is hardware decoding, which means that the GPU is used to partially replace the CPU for decoding. A part of the image data that is originally processed by the CPU is handed over to the GPU, and the parallel computing power of the GPU is much higher than the CPU. It can greatly reduce the load on the CPU. After the CPU usage is low, you can run some other programs at the same time. In this embodiment, when a large-size picture is displayed on the terminal device, for a terminal device having different display capabilities, the large-size picture is split according to a unified splitting manner, resulting in unsatisfactory splitting effect of some large-sized pictures, and further There is no guarantee that the picture will be drawn.
本发明实施例提供的一种图像绘制方法可以应用于终端绘制图像的场景。An image drawing method provided by an embodiment of the present invention can be applied to a scene in which an image is drawn by a terminal.
为了更好理解本发明实施例公开的方案,下面先对本发明实施例适用的网络构架进行描述。请参阅图1,图1是本发明实施例公开的一种网络构架示意图。在图1所示的网络构架中,可以包括用于提供待绘制图像数据的服务器1和用于绘制待绘制图像数据的终端2,其中,服务器1和终端2可以通过网络连接。在具体应用中,终端2可向服务器1发送请求获取待绘制图像数据,服务器1可响应终端2的请求获取待绘制图像数据,并将待绘制图像数据通过网络发送给终端2,终端2可通过网络接收服务器1发送的待绘制图像数据进行绘制并显示。In order to better understand the solution disclosed in the embodiments of the present invention, the following describes the network architecture to which the embodiments of the present invention apply. Please refer to FIG. 1. FIG. 1 is a schematic diagram of a network architecture disclosed in an embodiment of the present invention. In the network architecture shown in FIG. 1, a server 1 for providing image data to be drawn and a
下面将结合附图2-附图4,对本发明实施例提供的图像绘制方法进行详细介绍,其中,实施例的执行主体为终端,终端,即终端设备2可以包括:手机、电脑、平板电脑、笔记本等可以进行播放视频文件的智能终端,上述终端仅是举例,而非穷举,包含但不限于上述终端。The image drawing method provided by the embodiment of the present invention is described in detail below with reference to FIG. 2 to FIG. 4, wherein the execution subject of the embodiment is a terminal, and the terminal, that is, the
参见图2,是本发明实施例提供的一种图像绘制方法的一种实施例流程示意图。 本发明实施例的一种图像绘制方法包括如下步骤:FIG. 2 is a schematic flowchart diagram of an embodiment of an image drawing method according to an embodiment of the present invention. An image drawing method according to an embodiment of the present invention includes the following steps:
S100,获取与终端匹配的目标拆分参数。S100: Obtain a target splitting parameter that matches the terminal.
在本发明实施例中,待绘制图像数据可以是终端需进行绘制显示的图像数据。其中,待绘制图像数据可以是终端从图像服务器接收到的图像数据,也可以是终端,例如终端设备对本地存储的图像数据进行处理后的得到的图像数据,如对当前显示的图像进行放大操作后获得的待绘制图像数据。当终端获得待绘制图像数据时,终端可接收到对待绘制图像数据进行绘制的绘制指令。其中,终端对当前显示的图像进行放大操作后获得的待绘制图像数据具体可以是:终端根据放大操作确定放大比例,根据放大比例对显示的图像对应的数据进行放大操作,获得待绘制图像数据。In the embodiment of the present invention, the image data to be drawn may be image data that the terminal needs to display and display. The image data to be drawn may be image data received by the terminal from the image server, or may be a terminal, for example, image data obtained by the terminal device processing the locally stored image data, such as performing an enlargement operation on the currently displayed image. The image data to be drawn obtained afterwards. When the terminal obtains image data to be drawn, the terminal may receive a drawing instruction to draw the image data to be drawn. The image data to be drawn obtained by the terminal after performing the zoom-in operation on the currently displayed image may be: the terminal determines the zoom-in ratio according to the zoom-in operation, and performs an enlargement operation on the data corresponding to the displayed image according to the zoom-in ratio to obtain image data to be drawn.
在本发明实施例中,终端可首先获取待绘制图像数据的尺寸信息,尺寸信息可包括待绘制图像数据在页面进行绘制显示的图像的长和宽的信息。当终端获取到待绘制图像数据的尺寸信息后,终端可检测尺寸信息是否满足预设的条件,其中,预设的条件可以是与终端绘制图像数据时所能支持的最大纹理的尺寸信息相关联,如预设的条件可以是大于或等于终端绘制图像数据时所能支持最大纹理的尺寸信息,或者预设的条件还可以是大于或等于终端绘制图像数据时所能支持最大纹理的尺寸信息的一半。进一步的,预设的条件还可以是与终端的显示界面的尺寸信息相关联,如预设的条件可以是大于或等于终端的显示界面的尺寸信息,其中,预设的条件还可以是其他条件,在此不进行限制。In the embodiment of the present invention, the terminal may first acquire size information of image data to be drawn, and the size information may include information of length and width of an image to be drawn and displayed on the page. After the terminal obtains the size information of the image data to be drawn, the terminal may detect whether the size information satisfies a preset condition, where the preset condition may be associated with the size information of the maximum texture that the terminal can support when drawing the image data. If the preset condition is greater than or equal to the size information that the terminal can support the maximum texture when the image data is drawn, or the preset condition may be greater than or equal to the size information of the maximum texture that can be supported when the terminal draws the image data. half. Further, the preset condition may be related to the size information of the display interface of the terminal, for example, the preset condition may be greater than or equal to the size information of the display interface of the terminal, wherein the preset condition may also be other conditions. There is no restriction here.
在本发明实施例中,当终端判断待绘制图像数据的尺寸信息满足预设的条件时,终端可确定待绘制图像数据为大尺寸的图像数据,需对其进行拆分绘制。其中,终端对待绘制图像数据进行拆分绘制可以理解为,终端将待绘制图像数据拆分为多个待绘制子图像数据,并分别对多个待绘制子图像数据在页面上进行渲染绘制出多个子图像,多个子图像可构成待绘制图像数据的绘制后图像。因此,当终端确定对待绘制图像数据进行拆分绘制时,终端可获取与终端匹配的目标拆分参数。In the embodiment of the present invention, when the terminal determines that the size information of the image data to be drawn satisfies the preset condition, the terminal may determine that the image data to be drawn is image data of a large size, and needs to be split and drawn. The terminal can perform the split drawing on the image data to be drawn, which can be understood as that the terminal splits the image data to be drawn into a plurality of sub-image data to be drawn, and respectively renders multiple sub-image data to be rendered on the page. A sub-image, the plurality of sub-images may constitute a post-image of the image data to be drawn. Therefore, when the terminal determines that the image data to be drawn is split and drawn, the terminal may acquire a target split parameter that matches the terminal.
在本发明实施例中,终端可首先在终端的存储区中查询是否存储与终端匹配的目标拆分参数。当终端确定存储有与终端匹配的目标拆分参数时,终端可获取目标拆分参数。具体的,终端可预置终端标识与拆分参数的对应关系。因此,终端可获取本终端的目标终端标识,并根据终端标识与拆分参数的对应关系,查询是否有目标终端标识对应的目标拆分参数,当查询有目标终端标识对应的目标拆分参数时, 终端可确定存储有与终端匹配的目标拆分参数,并获取目标终端标识对应的目标拆分参数。In the embodiment of the present invention, the terminal may first query, in the storage area of the terminal, whether to store the target split parameter that matches the terminal. When the terminal determines that the target split parameter matching the terminal is stored, the terminal may acquire the target split parameter. Specifically, the terminal may preset a correspondence between the terminal identifier and the split parameter. Therefore, the terminal can obtain the target terminal identifier of the terminal, and query whether there is a target split parameter corresponding to the target terminal identifier according to the correspondence between the terminal identifier and the split parameter, and when the target split identifier corresponding to the target terminal identifier is queried, The terminal may determine that the target splitting parameter matching the terminal is stored, and obtain the target splitting parameter corresponding to the target terminal identifier.
在本发明实施例中,拆分参数可以是自然数,如可以是1,2,4等自然数。也可以是与预置的自变量相关的函数。In the embodiment of the present invention, the splitting parameter may be a natural number, such as a natural number such as 1, 2, and 4. It can also be a function related to a preset argument.
S101,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的该终端上的绘制区域分别进行拆分处理。S101: Perform a splitting process on the drawing area on the terminal corresponding to the image data to be drawn and the image data to be drawn according to the target splitting parameter.
在本发明实施例中,当终端获得待绘制图像数据时,终端也可获取到待绘制图像数据所对应的绘制区域,该绘制区域用于绘制待绘制图像数据对应的图像。因此,当终端获取到目标拆分参数时,终端可根据目标拆分参数对待绘制图像数据以及对应的绘制区域分别进行等分拆分。具体的,可参见图3a和图3b所示的拆分示意图,当终端获得的目标拆分参数为4时,图3a为待绘制图像数据,终端按目标拆分参数对待绘制图像数据进行等分拆分可如图虚线所示的拆分处理。图3b为待绘制图像数据对应的绘制区域,终端按目标拆分参数对待绘制图像数据对应的绘制区域进行等分拆分可如图虚线所示的拆分处理。In the embodiment of the present invention, when the terminal obtains the image data to be drawn, the terminal may also acquire a drawing area corresponding to the image data to be drawn, and the drawing area is used to draw an image corresponding to the image data to be drawn. Therefore, when the terminal acquires the target splitting parameter, the terminal may separately split the image to be drawn and the corresponding drawing area according to the target splitting parameter. For details, refer to the split diagram shown in FIG. 3a and FIG. 3b. When the target split parameter obtained by the terminal is 4, FIG. 3a is image data to be drawn, and the terminal divides the image data to be drawn according to the target split parameter. The split can be split as shown by the dotted line. FIG. 3b is a drawing area corresponding to the image data to be drawn, and the terminal splits the drawing area corresponding to the image data to be drawn according to the target splitting parameter, and can be split and split as shown by a broken line.
S102,获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域。S102. Obtain at least one sub-image data to be drawn after the splitting process and a drawing sub-region corresponding to each sub-image data to be drawn.
在本发明实施例中,当终端对待绘制图像数据和待绘制图像数据对应的绘制区域分别进行拆分处理后,终端可获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域。具体的,可参见图3a和图3b所示的拆分示意图,当终端获得的目标拆分参数为4时,图3a为待绘制图像数据,终端按目标拆分参数对待绘制图像数据进行等分拆分如图虚线所示的进行拆分处理后,终端可获得拆分处理后的4个待绘制子图像数据。进一步的,待绘制图像数据对应的绘制区域可如图3b中的绘制区域所示,该绘制区域用于绘制待绘制图像数据,因此,终端对绘制区域可进行等分拆分处理后,终端可获得拆分处理后的4个绘制子区域,其中,终端可按待绘制图像数据中每个待绘制子图像数据所绘制的位置,建立待绘制子图像数据与绘制子区域的对应关系。In the embodiment of the present invention, after the terminal performs the split processing on the drawing area corresponding to the image data to be drawn and the image data to be drawn, the terminal may obtain at least one sub-image data to be drawn and each to be drawn after the splitting process. The drawing sub-region corresponding to the image data. For details, refer to the split diagram shown in FIG. 3a and FIG. 3b. When the target split parameter obtained by the terminal is 4, FIG. 3a is image data to be drawn, and the terminal divides the image data to be drawn according to the target split parameter. After splitting as shown in the dotted line, the terminal can obtain four sub-image data to be drawn after the split processing. Further, the drawing area corresponding to the image data to be drawn may be as shown in the drawing area in FIG. 3b, and the drawing area is used to draw image data to be drawn. Therefore, after the terminal can equally divide and divide the drawing area, the terminal may The four drawing sub-regions after the splitting process are obtained, wherein the terminal can establish a correspondence between the sub-image data to be drawn and the drawing sub-region according to the position drawn by each sub-image data to be drawn in the image data to be drawn.
S103,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制图像。S103. Draw each sub-image data to be drawn to a corresponding drawing sub-region, and obtain a drawing image of the image data to be drawn.
在本发明实施例中,当终端对待绘制子图像数据进行拆分后,终端可采用硬解 方式将待绘制子图像数据按待绘制子图像数据与绘制子区域的对应关系绘制至对应的绘制子区域,使得绘制后的绘制子区域可拼接成待绘制图像数据的绘制后图像,其中,绘制后图像可以理解的是待绘制图像数据进行绘制后所显示的图像。In the embodiment of the present invention, after the terminal performs the splitting of the sub-image data to be drawn, the terminal may use the hard solution method to draw the sub-image data to be drawn according to the corresponding relationship between the sub-image data to be drawn and the drawing sub-region to the corresponding drawing. The area is such that the drawn drawing sub-area can be spliced into a post-image of the image data to be drawn, wherein the image after drawing can be understood as an image displayed after the image data to be drawn is drawn.
在本发明实施例中,终端获取与终端匹配的目标拆分参数,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分,获得至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。这使得终端可获取预设的与终端匹配的目标拆分参数,根据获取的该终端的目标拆分参数对待绘制图像数据和该待绘制图像数据对应的绘制区域进行拆分,分别得到待绘制子图像数据和每个待绘制子图像数据对应的绘制子区域,将每个待绘制子图像数据绘制至对应的绘制子区域。利用本技术方案可以保证为终端获取与其对应的目标拆分参数,利用该终端的目标拆分参数执行拆分以及后续的绘制操作,因此可以保证为不同终端采用不同的拆分和绘制方案,保证绘制效果。In the embodiment of the present invention, the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn. The terminal can obtain the preset target splitting parameter matching the terminal, and split the drawing area corresponding to the image data to be drawn and the image data to be drawn according to the obtained target splitting parameter of the terminal, and respectively obtain the to-be-drawn child. The image data and the drawing sub-region corresponding to each sub-image data to be drawn are drawn to each corresponding sub-image region. The technical solution can ensure that the target splitting parameter is obtained for the terminal, and the splitting parameter and the subsequent drawing operation are performed by using the target splitting parameter of the terminal, so that different splitting and drawing schemes can be ensured for different terminals to ensure Draw the effect.
参见图4,是本发明实施例提供的一种图像绘制方法的一种实施例流程示意图。本发明实施例的一种图像绘制方法包括如下步骤:FIG. 4 is a schematic flowchart diagram of an embodiment of an image drawing method according to an embodiment of the present invention. An image drawing method according to an embodiment of the present invention includes the following steps:
S200,检测是否存储有与终端匹配的目标拆分参数。S200. Detect whether a target split parameter matching the terminal is stored.
在本发明实施例中,终端可首先查询是否存储与终端匹配的目标拆分参数。其中,可预设终端标识与拆分参数的对应关系。因此,终端可获取本终端的目标终端标识,并根据终端标识与拆分参数的对应关系,查询是否有目标终端标识对应的目标拆分参数,当查询没有目标终端标识对应的目标拆分参数时,终端可确定没有存储有与终端匹配的目标拆分参数,并执行步骤S201。In the embodiment of the present invention, the terminal may first query whether to store the target split parameter that matches the terminal. The correspondence between the terminal identifier and the split parameter may be preset. Therefore, the terminal can obtain the target terminal identifier of the terminal, and query whether there is a target splitting parameter corresponding to the target terminal identifier according to the correspondence between the terminal identifier and the splitting parameter. When the query does not have the target splitting parameter corresponding to the target terminal identifier, The terminal may determine that the target splitting parameter matching the terminal is not stored, and step S201 is performed.
S201,当检测到没有存储所述目标拆分参数时,在预设的拆分参数集合中进行搜索,获取与所述终端匹配的目标拆分参数。S201. When it is detected that the target splitting parameter is not stored, perform a search in a preset split parameter set to obtain a target splitting parameter that matches the terminal.
在本发明实施例中,拆分参数集合可包括至少一个拆分参数。具体的,拆分参数集合可以包括:1,2,4,6,和8组成的集合。还可以包括更多的自然数组成的集合,或者可以是某个数值范围内的所有自然数组成的集合,如拆分参数集合可以是范围1~10内的自然数,在此用户可自行设定,不进行限制。In an embodiment of the invention, the split parameter set may include at least one split parameter. Specifically, the split parameter set may include: a set consisting of 1, 2, 4, 6, and 8. It may also include more collections of natural numbers, or may be a collection of all natural numbers within a certain range of values. For example, the set of split parameters may be a natural number in the range of 1 to 10, which can be set by the user, Make restrictions.
终端在预设的拆分参数集合中进行搜索,获取与终端匹配的目标拆分参数具体可以是:终端首先采用拆分参数集合中的每个拆分参数对待绘制图像数据进行绘制, 记录基于每个拆分参数对待绘制图像数据进行绘制所用的时长,从而获得每个拆分参数对应的绘制持续时长,其中,绘制持续时长为基于每个拆分参数对待绘制图像数据进行绘制所用的时长。具体可以是:当终端确定采用一个拆分参数对待绘制图像数据进行绘制时,终端可开始记录终端基于该拆分参数对待绘制图像数据进行绘制所用的时长,当终端确定基于该拆分参数将待绘制图像数据成功绘制至对应的区域获得待绘制图像数据的绘制后图像时,终端可结束记录终端基于该拆分参数对待绘制图像数据进行绘制的所用的时长,从而终端可获取该拆分参数对应的绘制持续时长。其中,绘制持续时长为基于该拆分参数对所述待绘制图像数据进行绘制所用的时长。因此,终端可采用上述方式获取每个拆分参数对应的绘制持续时长。其中,终端采用每个拆分参数对待绘制图像进行绘制的具体实现过程可参见上述的步骤S101和步骤S102的具体实现过程,在此不进行赘述。The terminal searches in the preset split parameter set, and obtains the target split parameter matched with the terminal, which may be: the terminal first draws the image data to be drawn by using each split parameter in the split parameter set, and the record is based on each The duration of the drawing parameter to draw the image data, so as to obtain the duration of the drawing corresponding to each split parameter, wherein the drawing duration is the length of time used to draw the image data to be drawn based on each split parameter. Specifically, when the terminal determines to use a split parameter to draw the image data to be drawn, the terminal may start recording the duration used by the terminal to draw the image data to be drawn based on the split parameter, and the terminal determines to wait based on the split parameter. When the drawing image data is successfully drawn to the corresponding area to obtain the drawn image of the image data to be drawn, the terminal may end the length of time used by the recording terminal to draw the image data to be drawn based on the splitting parameter, so that the terminal can obtain the corresponding parameter of the splitting parameter. The duration of the drawing is long. The drawing duration is a duration used to draw the image data to be drawn based on the split parameter. Therefore, the terminal can obtain the duration of the drawing corresponding to each split parameter in the above manner. For a specific implementation process of the terminal to draw the image to be drawn by using the splitting parameter, refer to the specific implementation process of step S101 and step S102, which are not described herein.
在本发明实施例中,当终端获取到每个拆分参数对应的绘制持续时长时,终端可在每个拆分参数分别对应的绘制持续时长中获取时长最短的绘制持续时长对应的待确定拆分参数,即终端获取用于绘制过程中所用的时长最短的拆分参数确定为待确定拆分参数,并将待确定拆分参数设为目标拆分参数。In the embodiment of the present invention, when the terminal obtains the duration of the drawing duration corresponding to each splitting parameter, the terminal may obtain the shortest duration of the drawing duration corresponding to each of the splitting parameters. The sub-parameter, that is, the shortest splitting parameter used by the terminal to obtain the drawing process, is determined as the splitting parameter to be determined, and the splitting parameter to be determined is set as the target splitting parameter.
终端在预设的拆分参数集合中进行搜索,获取与终端匹配的目标拆分参数具体还可以是:终端可首先按预置排列顺序对拆分参数集合中的所有拆分参数进行排列,获排列后的拆分参数排列集合,如终端可按数值从小到大的排列顺序对拆分参数集合进行排列,获得排列后的拆分参数排列集合。如当拆分参数集合包括1,8,6,2,4,3,5,7,终端可按数值从小到大的排列顺序对拆分参数集合进行排列,获得排列后的拆分参数排列集合为1,2,3,4,5,6,7,8。The terminal searches in the preset split parameter set, and obtains the target split parameter that matches the terminal. The terminal may first arrange all the split parameters in the split parameter set according to the preset order. The arranged split parameter arrangement set, for example, the terminal may arrange the split parameter sets according to the numerical order from small to large, and obtain the arranged split parameter arrangement set. For example, when the split parameter set includes 1, 8, 6, 2, 4, 3, 5, 7, the terminal can arrange the split parameter sets according to the order of the values from small to large, and obtain the arranged split parameter arrangement set. It is 1, 2, 3, 4, 5, 6, 7, 8.
在本发明实施例中,当终端获得排列后的拆分参数排列集合后,终端可在拆分参数排列集合中搜索对应的绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数,并将待确定拆分参数设为目标拆分参数,其中,绘制持续时长为基于拆分参数对所述待绘制图像数据进行绘制所用的时长。可以理解的是,当终端确定绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数时,终端可确定待确定拆分参数对应的绘制持续时长是拆分参数排列集合中所有拆分参数分别对应的绘制持续时长中的最短时长,利用该拆分参数对待绘制图像数据进行拆分和绘制所需的时长最短,从而有效节省终端的处理步骤, 提高终端的运行效率。In the embodiment of the present invention, after the terminal obtains the arranged split parameter arrangement set, the terminal may search, in the split parameter arrangement set, that the corresponding drawing duration is less than or equal to the mapping duration of the adjacent split parameter. The splitting parameter is determined, and the splitting parameter to be determined is set as the target splitting parameter, wherein the drawing duration is the length of time used to draw the image data to be drawn based on the splitting parameter. It can be understood that, when the terminal determines that the drawing duration is less than or equal to the to-be-determined splitting parameter of the drawing duration corresponding to the adjacent splitting parameter, the terminal may determine that the drawing duration corresponding to the determined splitting parameter is split. The shortest duration of the drawing duration corresponding to all the splitting parameters in the parameter arrangement set, and the time required to split and draw the image data to be drawn by the splitting parameter is the shortest, thereby effectively saving the processing steps of the terminal and improving the terminal. operating efficiency.
其中,终端在拆分参数排列集合中搜索对应的绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数具体可以是:终端可在拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长,并在拆分参数排列集合中按预置的增量方向和增量数值,获取任一个拆分参数相邻的第一拆分参数,其中,在拆分参数排列集合中按预置的增量方向和增量数值,获取任一个拆分参数相邻的第一拆分参数具体可以是:终端可以增量数值为间隔,按增量方向获取任一个拆分参数相邻的第一拆分参数。如当拆分参数排列集合为1,2,3,4,5,6,7,8,9和10,当终端确定的任一个拆分参数为3,增量方向为正方向,例如拆分参数序号增加的方向和增量数值为1时,则终端可在3的正方向上获取间隔为1的第一拆分参数为4。当终端获取到第一拆分参数时,终端可获取第一拆分参数对应的第二绘制持续时长。从而终端可判断第一绘制持续时长是否小于或等于第二绘制持续时长,当终端判断第一绘制持续时长小于或等于第二绘制持续时长时,终端可在拆分参数排列集合中获取任一个拆分参数相邻排列的第二拆分参数,此时,终端可按预置的增量方向的相反方向和增量数值获取任一个拆分参数相邻排列的第二拆分参数。如当拆分参数排列集合为1,2,3,4,5,6,7,8,9和10时,当终端确定的任一个拆分参数为3,增量方向为正方向和增量数值为1时,则终端可在3的正方向的相反方向,即拆分参数序号减少的方向上获取间隔为1的第二拆分参数为2。The determining, by the terminal, in the split parameter arrangement set, the corresponding mapping duration duration is less than or equal to the mapping duration of the adjacent splitting parameter, and the determining the splitting parameter may be: the terminal may be in the split parameter ranking set. Obtaining a first drawing duration corresponding to any splitting parameter, and obtaining a first splitting parameter adjacent to any splitting parameter according to a preset incremental direction and an increment value in the splitting parameter arrangement set, wherein In the split parameter arrangement set, according to the preset increment direction and the increment value, obtaining the first split parameter adjacent to any split parameter may be: the terminal may increment the value as the interval, according to the incremental direction Get the first split parameter adjacent to any split parameter. For example, when the split parameter arrangement set is 1, 2, 3, 4, 5, 6, 7, 8, 9, and 10, when the split parameter determined by the terminal is 3, the incremental direction is positive, for example, split. When the direction and increment value of the parameter number increase is 1, the terminal can obtain the first split parameter of interval 1 of 4 in the positive direction of 3. When the terminal obtains the first splitting parameter, the terminal may obtain the second drawing duration corresponding to the first splitting parameter. Therefore, the terminal may determine whether the duration of the first drawing duration is less than or equal to the duration of the second drawing duration. When the terminal determines that the duration of the first drawing duration is less than or equal to the duration of the second drawing duration, the terminal may obtain any one of the split parameter arrangement sets. The second splitting parameter of the adjacent parameter is arranged by the parameter. At this time, the terminal may obtain the second splitting parameter of the adjacent arrangement of any splitting parameter according to the opposite direction and the incremental value of the preset incremental direction. For example, when the split parameter arrangement set is 1, 2, 3, 4, 5, 6, 7, 8, 9, and 10, when the split parameter determined by the terminal is 3, the incremental direction is positive direction and increment. When the value is 1, the terminal can obtain the second split parameter of interval 1 in the opposite direction of the positive direction of 3, that is, the direction in which the split parameter number is decreased.
在本发明实施例中,当终端获取到第二拆分参数时,终端可获取第二拆分参数对应的第三绘制持续时长,并判断第一绘制持续时长是否小于或等于第三绘制持续时长,当终端判断第一绘制持续时长小于或等于第三绘制持续时长时,终端可将任一个拆分参数设为待确定拆分参数,该待确定拆分参数可以是在拆分参数排列集合中对应的绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数。In the embodiment of the present invention, when the terminal acquires the second splitting parameter, the terminal may obtain the third drawing duration of the second splitting parameter, and determine whether the first drawing duration is less than or equal to the third drawing duration. When the terminal determines that the first drawing duration is less than or equal to the third drawing duration, the terminal may set any of the splitting parameters to the to-be-determined splitting parameter, and the to-be-determined splitting parameter may be in the splitting parameter arrangement set. The corresponding drawing durations are less than or equal to the to-be-determined splitting parameters of the drawing duration corresponding to the adjacent splitting parameters.
进一步的,当终端判断第一绘制持续时长大于第二绘制持续时长时,终端可按增量方向和增量数值获取第一拆分参数的相邻的第三拆分参数,并将第三拆分参数设为任一个拆分参数执行在拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长步骤。当终端判断第一绘制持续时长大于第三绘制持续时长时,终端可按增量方向的相反方向和增量数值获取第二拆分参数的相邻的第四拆分参数,并将 第四拆分参数设为任一个拆分参数执行在拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长步骤。Further, when the terminal determines that the first drawing duration is greater than the second drawing duration, the terminal may obtain the adjacent third splitting parameter of the first splitting parameter according to the incremental direction and the incremental value, and the third splitting The sub-parameter is set to any of the split parameters to perform the first drawing duration step corresponding to any split parameter in the split parameter arrangement set. When the terminal determines that the first drawing duration is greater than the third drawing duration, the terminal may obtain the adjacent fourth splitting parameter of the second splitting parameter according to the opposite direction and the incremental value of the incremental direction, and the fourth splitting The sub-parameter is set to any of the split parameters to perform the first drawing duration step corresponding to any split parameter in the split parameter arrangement set.
在本发明实施例中,当终端在拆分参数排列集合中遍历至最后一个拆分参数时,终端可将该最后一个拆分参数设为待确定拆分参数。当终端获取到待确定拆分参数后,终端可将待确定设为目标拆分参数。In the embodiment of the present invention, when the terminal traverses to the last split parameter in the split parameter arrangement set, the terminal may set the last split parameter to the split parameter to be determined. After the terminal acquires the split parameter to be determined, the terminal may set the to-be-determined target split parameter.
进一步的,在本发明实施例中,终端还可将待确定拆分参数与待确定拆分参数对应的绘制持续时长作为一组记录信息记录至预置的记录区中,其中,记录区可以是存储列表。Further, in the embodiment of the present invention, the terminal may further record, as a set of record information, a drawing duration corresponding to the to-be-determined splitting parameter and the to-be-determined splitting parameter, into the preset recording area, where the recording area may be Store the list.
S202,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分处理。S202. Perform a splitting process on the to-be-drawn image data and the drawing area corresponding to the to-be-drawn image data according to the target splitting parameter.
S203,获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域。S203. Obtain at least one sub-image data to be drawn after the splitting process and a drawing sub-region corresponding to each sub-image data to be drawn.
S204,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。S204: Draw each sub-image data to be drawn to a corresponding drawing sub-region, and obtain a post-image of the image data to be drawn.
在本发明实施例中,步骤S200、步骤S202、步骤S203和步骤S204的具体实现方式还可参见上述实施例中的步骤S100、步骤S101、步骤S102和步骤S103的具体实现方式,在此不进行赘述。In the embodiment of the present invention, the specific implementation manners of the step S100, the step S202, the step S203, and the step S204 are also referred to the specific implementation manners of the step S100, the step S101, the step S102, and the step S103 in the foregoing embodiment. Narration.
在本发明实施例中,终端获取与终端匹配的目标拆分参数,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分,获得至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。这使得终端可自动获取与终端匹配的目标拆分参数对待绘制图像数据进行拆分绘制,从而使得终端可获取最适用于终端进行拆分绘制的目标拆分参数对待绘制图像数据进行拆分绘制,有效提高终端对待绘制图像数据进行拆分绘制的效率以及处理速度。In the embodiment of the present invention, the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn. The terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
参见图5,是本发明实施例提供的一种图像绘制方法的一种实施例流程示意图。本发明实施例的一种图像绘制方法包括如下步骤:FIG. 5 is a schematic flowchart diagram of an embodiment of an image drawing method according to an embodiment of the present invention. An image drawing method according to an embodiment of the present invention includes the following steps:
S300,按记录区中所包括的至少一种待确定拆分参数的种类对所述记录区所包括的至少一组记录信息进行分类,获得每种待确定拆分参数对应的至少一组记录信 息。S300, classifying at least one group of record information included in the record area according to at least one type of the split parameter to be determined included in the record area, and obtaining at least one set of record information corresponding to each split parameter to be determined. .
在本发明实施例中,记录区可记录多组记录信息,每组记录信息可包括待确定拆分参数以及对应的绘制持续时长。因此,终端可将包括相同的拆分参数的记录信息分为同一种待确定拆分参数。其中,当终端检测到记录区有数据更新时,终端可执行该步骤,或者终端可按预置的周期触发执行该步骤。In the embodiment of the present invention, the recording area may record a plurality of sets of record information, and each set of record information may include a split parameter to be determined and a corresponding draw duration. Therefore, the terminal can divide the record information including the same split parameter into the same split parameter to be determined. Wherein, when the terminal detects that there is data update in the recording area, the terminal may perform the step, or the terminal may trigger the execution of the step according to a preset period.
S301,根据每种待确定拆分参数对应的至少一组记录信息所包括的持续时间计算每种待确定拆分参数对应的平均绘制持续时长。S301. Calculate, according to a duration included in each of the at least one set of record information corresponding to each of the to-be-determined split parameters, an average draw duration of each of the to-be-determined split parameters.
在本发明实施例中,终端可将包括同种待确定拆分参数的至少一组记录信息所包括的所有绘制持续时长进行求和再平均运算,从而获得该种待确定拆分参数对应的平均绘制持续时长。同理,按照获得该种拆分参数的平均绘制持续时长的步骤,终端可获取每种待确定拆分参数对应的平均绘制持续时长。In the embodiment of the present invention, the terminal may perform a summation and averaging operation on all the durations of the drawing included in the at least one group of the record information including the same type of the split parameter to be determined, thereby obtaining an average corresponding to the determined split parameter. Draw duration. Similarly, according to the step of obtaining the average duration of the splitting parameter, the terminal can obtain the average drawing duration corresponding to each of the determined splitting parameters.
S302,在所述每种待确定拆分参数对应的平均绘制持续时长中获取时长最短的平均绘制持续时长。S302. Acquire an average duration of the duration of the duration of the average duration of the duration of each of the to-be-determined split parameters.
S303,将所述时长最短的平均绘制持续时长对应的待确定拆分参数存储为与所述终端匹配的目标拆分参数。S303. Store the to-be-determined split parameter corresponding to the shortest average duration of the duration as the target split parameter that matches the terminal.
S304,获取与终端匹配的目标拆分参数。S304. Acquire a target splitting parameter that matches the terminal.
S305,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分处理。S305. Perform a splitting process on the to-be-drawn image data and the drawing area corresponding to the to-be-drawn image data according to the target splitting parameter.
S306,,获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域。S306. Obtain at least one sub-image data to be drawn after the splitting process and a drawing sub-region corresponding to each sub-image data to be drawn.
S307,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。S307. Draw each sub-image data to be drawn to a corresponding drawing sub-region, and obtain a post-image of the image data to be drawn.
在本发明实施例中,步骤S304、步骤S305、步骤S306和步骤S307的具体实现方式还可参见上述实施例中的步骤S100、步骤S101、步骤S102和步骤S103的具体实现方式,在此不进行赘述。In the embodiment of the present invention, the specific implementation manners of step S304, step S305, step S306, and step S307 can also refer to the specific implementation manners of step S100, step S101, step S102, and step S103 in the foregoing embodiment, where no specific implementation is performed. Narration.
在本发明实施例中,终端获取与终端匹配的目标拆分参数,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分,获得至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后 图像。这使得终端可自动获取与终端匹配的目标拆分参数对待绘制图像数据进行拆分绘制,从而使得终端可获取最适用于终端进行拆分绘制的目标拆分参数对待绘制图像数据进行拆分绘制,有效提高终端对待绘制图像数据进行拆分绘制的效率以及处理速度。In the embodiment of the present invention, the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn. The terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
下面将结合附图6-7,对本发明实施例提供的终端进行详细介绍。需要说明的是,附图6-7所示的终端,用于执行本发明图1-图5所示实施例的方法,为了便于说明,仅示出了与本发明实施例相关的部分,具体技术细节未揭示的,请参照本发明图1-图5所示的实施例。The terminal provided by the embodiment of the present invention will be described in detail below with reference to FIG. 6-7. It should be noted that the terminal shown in FIG. 6-7 is used to perform the method of the embodiment shown in FIG. 1 to FIG. 5 of the present invention. For the convenience of description, only the part related to the embodiment of the present invention is specifically illustrated. The technical details are not disclosed, please refer to the embodiment shown in Figs. 1 to 5 of the present invention.
请参见图6,为本发明实施例提供了一种终端的结构示意图。如图7所示,本发明实施例的所述终端可以包括:FIG. 6 is a schematic structural diagram of a terminal according to an embodiment of the present invention. As shown in FIG. 7, the terminal in the embodiment of the present invention may include:
第一获取单元100,用于获取与终端匹配的目标拆分参数。The first obtaining
拆分单元200,用于按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分处理;The
第二获取单元300,用于获拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域。The second obtaining
绘制单元400,用于将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。The
其中,所述终端还包括:The terminal further includes:
第三获取单元,用于获取所述待绘制图像数据的尺寸信息;a third acquiring unit, configured to acquire size information of the image data to be drawn;
检测单元,用于检测所述尺寸信息是否满足预设的条件;a detecting unit, configured to detect whether the size information meets a preset condition;
当所述检测单元检测到所述尺寸信息满足预设的条件时,通知所述第一获取单元100获取与终端匹配的目标拆分参数。When the detecting unit detects that the size information meets a preset condition, the first acquiring
其中,所述第一获取单元100包括:The first obtaining
检测子单元,用于检测所述终端是否存储与终端匹配的目标拆分参数;a detecting subunit, configured to detect whether the terminal stores a target splitting parameter that matches the terminal;
当所述检测子单元检测到所述终端存储有所述目标拆分参数时,通知所述第一获取单元获取与终端匹配的目标拆分参数;When the detecting subunit detects that the terminal stores the target splitting parameter, notifying the first acquiring unit to acquire a target splitting parameter that matches the terminal;
搜索子单元,用于当所述检测子单元检测到所述终端没有存储所述目标拆分参数时,在预设的拆分参数集合中进行搜索,获取与所述终端匹配的目标拆分参数,其中,所述拆分参数集合包括至少一个拆分参数。Searching a subunit, configured to perform a search in a preset split parameter set when the detecting subunit detects that the terminal does not store the target split parameter, and acquire a target split parameter that matches the terminal The set of split parameters includes at least one split parameter.
其中,所述搜索子单元包括:The search subunit includes:
第一获取子单元,用于获取每个拆分参数对应的绘制持续时长,其中,所述绘制持续时长为基于所述每个拆分参数对所述待绘制图像数据进行绘制所用的时长;a first obtaining sub-unit, configured to obtain a drawing duration duration corresponding to each of the splitting parameters, wherein the drawing duration is a duration used to draw the image data to be drawn based on each of the splitting parameters;
第二获取子单元,用于在所述每个拆分参数分别对应的绘制持续时长中获取时长最短的绘制持续时长对应的待确定拆分参数;a second obtaining sub-unit, configured to obtain a to-be-determined splitting parameter corresponding to a drawing duration that has the shortest duration in each of the drawing durations corresponding to each of the splitting parameters;
第一设置子单元,用于将所述待确定拆分参数设为所述目标拆分参数。a first setting subunit, configured to set the to-be-determined splitting parameter to the target splitting parameter.
其中,所述搜索子单元包括:The search subunit includes:
排列子单元,用于按预置排列顺序对所述拆分参数集合中的所有拆分参数进行排列,获得排列后的拆分参数排列集合;Arranging subunits for arranging all the splitting parameters in the split parameter set according to a preset arrangement order, and obtaining the arranged split parameter arrangement set;
第三获取子单元,用于在所述拆分参数排列集合中搜索对应的绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数,其中,所述绘制持续时长为基于拆分参数对所述待绘制图像数据进行绘制所用的时长;a third obtaining sub-unit, configured to search, in the split parameter arrangement set, a corresponding splitting parameter whose mapping duration duration is less than or equal to a drawing duration duration corresponding to the adjacent splitting parameter, where the drawing The duration is a duration used to draw the image data to be drawn based on the split parameter;
第二设置子单元,用于将所述待确定拆分参数设为所述目标拆分参数。a second setting subunit, configured to set the to-be-determined splitting parameter to the target splitting parameter.
其中,所述第三获取子单元包括:The third obtaining subunit includes:
第四获取子单元,用于在所述拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长;a fourth acquiring sub-unit, configured to obtain, in the split parameter arrangement set, a first drawing duration duration corresponding to any one of the splitting parameters;
第五获取子单元,用于在所述拆分参数排列集合中获取与所述任一个拆分参数相邻的第一拆分参数,并获取所述第一拆分参数对应的第二绘制持续时长;a fifth obtaining sub-unit, configured to acquire, in the split parameter arrangement set, a first splitting parameter adjacent to any one of the splitting parameters, and obtain a second drawing duration corresponding to the first splitting parameter duration;
第六获取子单元,当判断所述第一绘制持续时长小于或等于所述第二绘制持续时长时,在所述拆分参数排列集合中获取与所述任一个拆分参数相邻排列的第二拆分参数,并获取所述第二拆分参数对应的第三绘制持续时长;a sixth obtaining subunit, when it is determined that the first drawing duration is less than or equal to the second drawing duration, acquiring, in the split parameter arrangement set, adjacent to the any one of the splitting parameters Dividing the parameters, and obtaining a third drawing duration corresponding to the second splitting parameter;
第七获取子单元,当判断所述第一绘制持续时长小于或等于所述第三绘制持续时长时,将所述任一个拆分参数设为所述待确定拆分参数。And a seventh acquiring sub-unit, when determining that the first drawing duration is less than or equal to the third drawing duration, setting any one of the splitting parameters to the to-be-determined splitting parameter.
其中,所述第三获取子单元还包括:The third obtaining subunit further includes:
第三设置子单元,用于当判断所述第一绘制持续时长大于所述第二绘制持续时长时,获取所述第一拆分参数的相邻的第三拆分参数,并将所述第三拆分参数设为所述任一个拆分参数;a third setting subunit, configured to acquire an adjacent third splitting parameter of the first splitting parameter when determining that the first drawing duration is greater than the second drawing duration, and The three split parameters are set to any one of the split parameters;
通知所述第四获取子单元在所述拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长;Notifying the fourth obtaining sub-unit to obtain a first drawing duration duration corresponding to any one of the splitting parameters in the split parameter arrangement set;
所述第三获取子单元还包括:The third obtaining subunit further includes:
第四设置子单元,用于当判断所述第一绘制持续时长大于所述第三绘制持续时长时,获取所述第二拆分参数的相邻的第四拆分参数,并将所述第四拆分参数设为所述任一个拆分参数;a fourth setting subunit, configured to: when determining that the first drawing duration is greater than the third drawing duration, acquiring an adjacent fourth splitting parameter of the second splitting parameter, and The four split parameters are set to any one of the split parameters;
通知所述第四获取子单元在所述拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长。The fourth obtaining sub-unit is notified to obtain the first drawing duration duration corresponding to any one of the splitting parameters in the split parameter arrangement set.
其中,所述终端还包括:The terminal further includes:
记录单元,用于将所述待确定拆分参数与所述待确定拆分参数对应的绘制持续时长作为一组记录信息记录至预置的记录区中。And a recording unit, configured to record the duration of the drawing corresponding to the to-be-determined splitting parameter and the to-be-determined splitting parameter as a set of record information into the preset recording area.
其中,所述终端还包括:The terminal further includes:
分类单元,用于按记录区中所包括的至少一种待确定拆分参数的种类对所述记录区所包括的至少一组记录信息进行分类,获得每种待确定拆分参数对应的至少一组记录信息;a classifying unit, configured to classify at least one set of record information included in the record area according to at least one type of the split parameter to be determined included in the record area, and obtain at least one corresponding to each of the to-be-determined split parameters Group record information;
计算单元,用于根据每种待确定拆分参数对应的至少一组记录信息所包括的持续时间计算每种待确定每种待确定拆分参数对应的平均绘制持续时长;a calculating unit, configured to calculate, according to a duration included in each of the at least one set of record information corresponding to each of the to-be-determined split parameters, an average draw duration corresponding to each of the to-be-determined split parameters to be determined;
第四获取单元,用于在所述每种待确定拆分参数对应的平均绘制持续时长中获取时长最短的平均绘制持续时长;a fourth obtaining unit, configured to obtain an average drawing duration of the shortest duration in the average drawing duration corresponding to each of the to-be-determined splitting parameters;
设置单元,用于将所述时长最短的平均绘制持续时长对应的待确定拆分参数存储为与所述终端匹配的目标拆分参数。And a setting unit, configured to store the to-be-determined split parameter corresponding to the shortest average draw duration of the duration as the target split parameter matched with the terminal.
其中,可以理解的是,本实施例的终端中的单元的各功能模块的功能可根据上述方法实施例中的方法具体实现,其具体实现过程可以参照上述方法实施例的相关描述,此处不再进行赘述。It is to be understood that the functions of the functional modules of the unit in the terminal in this embodiment may be specifically implemented according to the method in the foregoing method embodiment, and the specific implementation process may refer to the related description of the foregoing method embodiment, where Repeatedly.
在本发明实施例中,终端获取与终端匹配的目标拆分参数,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分,获得至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。这使得终端可自动获取与终端匹配的目标拆分参数对待绘制图像数据进行拆分绘制,从而使得终端可获取最适用于终端进行拆分绘制的目标拆分参数对待绘制图像数据进行拆分绘制,有效提高终端对待绘制图像数据进行拆分绘制的效率以及 处理速度。In the embodiment of the present invention, the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn. The terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
请参见图7,为本发明实施例提供了另一种终端的结构示意图。如图7所示,所述终端1000可以包括:至少一个处理器1001,例如CPU,至少一个网络接口1004,用户接口1003,存储器1005,至少一个通信总线1002。其中,通信总线1002用于实现这些组件之间的连接通信。其中,用户接口1003可以包括显示屏(Display)、键盘(Keyboard),可选用户接口1003还可以包括标准的有线接口、无线接口。网络接口1004可以包括标准的有线接口、无线接口(如WI-FI接口)。存储器1005可以是高速RAM存储器,也可以是非易失性的存储器(non-volatile memory),例如至少一个磁盘存储器。存储器1005还可以是至少一个位于远离前述处理器1001的存储装置。如图7所示,作为一种计算机存储介质的存储器1005中可以包括操作系统、网络通信模块、用户接口模块以及通信连接应用程序。FIG. 7 is a schematic structural diagram of another terminal according to an embodiment of the present invention. As shown in FIG. 7, the terminal 1000 may include at least one
在图7所示的终端1000中,用户接口1003主要用于为用户提供输入的接口,获取用户输入的数据;网络接口1004用于与新闻服务器相连接,获取新闻服务器发送的数据;而处理器1001可以用于调用存储器1005中存储的通信连接应用程序,并具体执行图2、图4和图5所示方法中的步骤,以及图6所示终端的操作,例如,In the terminal 1000 shown in FIG. 7, the
获取与终端匹配的目标拆分参数;Obtain a target split parameter that matches the terminal;
按所述目标拆分参数对待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分处理;Performing splitting processing on the drawing area corresponding to the image data to be drawn and the image data to be drawn according to the target splitting parameter;
获得拆分处理后的至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域;Obtaining at least one sub-image data to be drawn after the splitting process and a drawing sub-region corresponding to each sub-image data to be drawn;
将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。Each of the sub-image data to be drawn is drawn to a corresponding drawing sub-region, and the post-image of the image data to be drawn is obtained.
其中,在所述处理器1001获取与终端匹配的目标拆分参数之前,所述处理器1001执行:The
获取所述待绘制图像数据的尺寸信息;Obtaining size information of the image data to be drawn;
检测所述尺寸信息是否满足预设的条件;Detecting whether the size information meets a preset condition;
当检测到所述尺寸信息满足预设的条件时,执行所述获取与终端匹配的目标拆分参数步骤。When it is detected that the size information satisfies a preset condition, the step of acquiring a target split parameter matching the terminal is performed.
其中,所述处理器1001获取与终端匹配的目标拆分参数包括:The
检测所述终端是否存储与终端匹配的目标拆分参数;Detecting whether the terminal stores a target splitting parameter that matches the terminal;
当检测到所述终端存储有所述目标拆分参数时,执行获取与终端匹配的目标拆分参数步骤;When it is detected that the terminal stores the target splitting parameter, performing a step of acquiring a target splitting parameter that matches the terminal;
当检测到所述终端没有存储所述目标拆分参数时,在预设的拆分参数集合中进行搜索与所述终端匹配的目标拆分参数,其中,所述拆分参数集合包括至少一个拆分参数。When it is detected that the terminal does not store the target splitting parameter, searching for a target splitting parameter that matches the terminal in a preset split parameter set, where the split parameter set includes at least one split Sub-parameters.
其中,所述处理器1001在预设的拆分参数集合中进行搜索,获取与所述终端匹配的目标拆分参数包括:The
获取每个拆分参数对应的绘制持续时长,其中,所述绘制持续时长为基于所述每个拆分参数对所述待绘制图像数据进行绘制所用的时长;Obtaining a duration of the drawing corresponding to each of the splitting parameters, wherein the drawing duration is a length of time for drawing the image data to be drawn based on each of the splitting parameters;
在所述每个拆分参数分别对应的绘制持续时长中获取时长最短的绘制持续时长对应的待确定拆分参数;Determining a splitting parameter corresponding to a drawing duration that has the shortest duration in each of the drawing durations corresponding to each of the splitting parameters;
将所述待确定拆分参数设为所述目标拆分参数。The to-be-determined split parameter is set as the target split parameter.
其中,所述处理器1001在预设的拆分参数集合中进行搜索与所述终端匹配的目标拆分参数包括:The
按预置排列顺序对所述拆分参数集合中的所有拆分参数进行排列,获得排列后的拆分参数排列集合;Arranging all the splitting parameters in the split parameter set according to a preset arrangement order, and obtaining the arranged split parameter arrangement set;
在所述拆分参数排列集合中搜索对应的绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数,其中,所述绘制持续时长为基于拆分参数对所述待绘制图像数据进行绘制所用的时长;Searching, in the split parameter arrangement set, that the corresponding drawing durations are less than or equal to the mapping duration duration corresponding to the adjacent splitting parameters, wherein the drawing duration is based on the splitting parameter pair The length of time taken for the image data to be drawn to be drawn;
将所述待确定拆分参数设为所述目标拆分参数。The to-be-determined split parameter is set as the target split parameter.
其中,所述处理器1001在所述拆分参数排列集合中搜索对应的绘制持续时长均小于或等于相邻的拆分参数对应的绘制持续时长的待确定拆分参数包括:The
在所述拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长;Obtaining, in the split parameter arrangement set, a first drawing duration corresponding to any one of the split parameters;
在所述拆分参数排列集合中获取与所述任一个拆分参数相邻的第一拆分参数,并获取所述第一拆分参数对应的第二绘制持续时长;Obtaining, in the split parameter arrangement set, a first splitting parameter that is adjacent to the one of the splitting parameters, and acquiring a second drawing duration that corresponds to the first splitting parameter;
当判断所述第一绘制持续时长小于或等于所述第二绘制持续时长时,在所述拆分参数排列集合中获取与所述任一个拆分参数相邻排列的第二拆分参数,并获取所述第二拆分参数对应的第三绘制持续时长;When it is determined that the first drawing duration is less than or equal to the second drawing duration, acquiring a second splitting parameter that is adjacent to the one of the splitting parameters in the split parameter arrangement set, and Obtaining a third drawing duration corresponding to the second splitting parameter;
当判断所述第一绘制持续时长小于或等于所述第三绘制持续时长时,将所述任一个拆分参数设为所述待确定拆分参数。When it is determined that the first drawing duration is less than or equal to the third drawing duration, the any one of the splitting parameters is set as the to-be-determined splitting parameter.
其中,在所述处理器1001在所述拆分参数排列集合中获取与所述任一个拆分参数相邻的第一拆分参数,并获取所述第一拆分参数对应的第二绘制持续时长之后,所述处理器1001还执行:The
当判断所述第一绘制持续时长大于所述第二绘制持续时长时,获取所述第一拆分参数的相邻的第三拆分参数,并将所述第三拆分参数设为所述任一个拆分参数;When it is determined that the first drawing duration is greater than the second drawing duration, acquiring an adjacent third splitting parameter of the first splitting parameter, and setting the third splitting parameter to the Any split parameter;
执行所述在所述拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长步骤;Performing the first drawing duration duration step corresponding to obtaining any one of the split parameters in the split parameter arrangement set;
所述在所述拆分参数排列集合中获取与所述任一个拆分参数相邻的第一拆分参数,并获取所述第一拆分参数对应的第二绘制持续时长之后,包括:After obtaining the first splitting parameter adjacent to the splitting parameter in the split parameter arrangement set, and acquiring the second drawing duration duration corresponding to the first splitting parameter, the method includes:
当判断所述第一绘制持续时长大于所述第三绘制持续时长时,获取所述第二拆分参数的相邻的第四拆分参数,并将所述第四拆分参数设为所述任一个拆分参数;When it is determined that the first drawing duration is greater than the third drawing duration, acquiring an adjacent fourth splitting parameter of the second splitting parameter, and setting the fourth splitting parameter to the Any split parameter;
执行所述在所述拆分参数排列集合中获取任一个拆分参数对应的第一绘制持续时长步骤。Performing the step of acquiring the first drawing duration duration corresponding to any one of the split parameters in the split parameter arrangement set.
其中,其特征在于,在所述处理器1001在预设的拆分参数集合中进行搜索与所述终端匹配的目标拆分参数之后,所述处理器1001还执行:The
将所述待确定拆分参数与所述待确定拆分参数对应的绘制持续时长作为一组记录信息记录至预置的记录区中。And the drawing duration of the to-be-determined splitting parameter and the to-be-determined splitting parameter is recorded as a group of record information into the preset recording area.
其中,在所述处理器1001获取与终端匹配的目标拆分参数之前,所述处理器1001还执行:The
按记录区中所包括的至少一种待确定拆分参数的种类对所述记录区所包括的至少一组记录信息进行分类,获得每种待确定拆分参数对应的至少一组记录信息;And classifying at least one set of record information included in the record area according to at least one type of the split parameter to be determined included in the record area, and obtaining at least one set of record information corresponding to each of the to-be-determined split parameters;
根据每种待确定拆分参数对应的至少一组记录信息所包括的持续时间计算每种待确定每种待确定拆分参数对应的平均绘制持续时长;Calculating, according to the duration included in each of the at least one set of record information corresponding to each of the to-be-determined split parameters, an average draw duration corresponding to each of the to-be-determined split parameters to be determined;
在所述每种待确定拆分参数对应的平均绘制持续时长中获取时长最短的平均绘制持续时长;And obtaining, in the average drawing duration duration corresponding to each of the to-be-determined splitting parameters, a shortest average drawing duration;
将所述时长最短的平均绘制持续时长对应的待确定拆分参数存储为与所述终端匹配的目标拆分参数。The to-be-determined split parameter corresponding to the shortest average draw duration of the duration is stored as a target split parameter that matches the terminal.
其中,可以理解的是,本实施例的终端中的单元的各功能模块的功能可根据上述方法实施例中的方法具体实现,其具体实现过程可以参照上述方法实施例的相关描述,此处不再进行赘述。It is to be understood that the functions of the functional modules of the unit in the terminal in this embodiment may be specifically implemented according to the method in the foregoing method embodiment, and the specific implementation process may refer to the related description of the foregoing method embodiment, where Repeatedly.
在本发明实施例中,终端获取与终端匹配的目标拆分参数,按所述目标拆分参数对所述待绘制图像数据和所述待绘制图像数据对应的绘制区域分别进行拆分,获得至少一个待绘制子图像数据以及每个待绘制子图像数据对应的绘制子区域,将每个待绘制子图像数据绘制至对应的绘制子区域,获得所述待绘制图像数据的绘制后图像。这使得终端可自动获取与终端匹配的目标拆分参数对待绘制图像数据进行拆分绘制,从而使得终端可获取最适用于终端进行拆分绘制的目标拆分参数对待绘制图像数据进行拆分绘制,有效提高终端对待绘制图像数据进行拆分绘制的效率以及处理速度。In the embodiment of the present invention, the terminal acquires a target splitting parameter that matches the terminal, and separately splits the to-be-drawn image data and the drawing area corresponding to the image to be drawn according to the target splitting parameter, to obtain at least A sub-image data to be drawn and a drawing sub-region corresponding to each sub-image data to be drawn are drawn, and each sub-image data to be drawn is drawn to a corresponding drawing sub-region to obtain a post-image of the image data to be drawn. The terminal can automatically obtain the target splitting parameter matching the terminal to perform splitting and drawing the image data to be drawn, so that the terminal can obtain the target splitting parameter that is most suitable for the terminal to perform splitting and drawing, and split and draw the image data to be drawn. Effectively improve the efficiency and processing speed of the terminal to draw and draw image data.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)或随机存储记忆体(Random Access Memory,RAM)等。One of ordinary skill in the art can understand that all or part of the process of implementing the foregoing embodiments can be completed by a computer program to instruct related hardware, and the program can be stored in a computer readable storage medium. When executed, the flow of an embodiment of the methods as described above may be included. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
以上所揭露的仅为本发明较佳实施例而已,当然不能以此来限定本发明之权利范围,因此依本发明权利要求所作的等同变化,仍属本发明所涵盖的范围。The above is only the preferred embodiment of the present invention, and the scope of the present invention is not limited thereto, and thus equivalent changes made in the claims of the present invention are still within the scope of the present invention.
Claims (15)
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201710301745.5A CN108805945B (en) | 2017-05-02 | 2017-05-02 | A kind of image drawing method and terminal |
| CN201710301745.5 | 2017-05-02 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2018201993A1 true WO2018201993A1 (en) | 2018-11-08 |
Family
ID=64015980
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2018/084978 Ceased WO2018201993A1 (en) | 2017-05-02 | 2018-04-28 | Image drawing method, terminal and storage medium |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN108805945B (en) |
| WO (1) | WO2018201993A1 (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111739025A (en) * | 2020-05-08 | 2020-10-02 | 北京迈格威科技有限公司 | An image processing method, device, terminal and storage medium |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109712222B (en) * | 2018-12-29 | 2023-12-19 | 超级魔方(北京)科技有限公司 | Image processing method and device |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101604453A (en) * | 2009-07-08 | 2009-12-16 | 西安电子科技大学 | Large-scale data field volume rendering method based on partition strategy |
| CN103455973A (en) * | 2012-05-28 | 2013-12-18 | 方正国际软件(北京)有限公司 | Method and device for drawing screen images |
| CN104751494A (en) * | 2015-04-27 | 2015-07-01 | 国家电网公司 | Processing and drawing method for OpenGL huge textures |
| CN104849755A (en) * | 2015-05-04 | 2015-08-19 | 中国石油天然气集团公司 | Parallel earthquake data rendering method |
-
2017
- 2017-05-02 CN CN201710301745.5A patent/CN108805945B/en active Active
-
2018
- 2018-04-28 WO PCT/CN2018/084978 patent/WO2018201993A1/en not_active Ceased
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101604453A (en) * | 2009-07-08 | 2009-12-16 | 西安电子科技大学 | Large-scale data field volume rendering method based on partition strategy |
| CN103455973A (en) * | 2012-05-28 | 2013-12-18 | 方正国际软件(北京)有限公司 | Method and device for drawing screen images |
| CN104751494A (en) * | 2015-04-27 | 2015-07-01 | 国家电网公司 | Processing and drawing method for OpenGL huge textures |
| CN104849755A (en) * | 2015-05-04 | 2015-08-19 | 中国石油天然气集团公司 | Parallel earthquake data rendering method |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111739025A (en) * | 2020-05-08 | 2020-10-02 | 北京迈格威科技有限公司 | An image processing method, device, terminal and storage medium |
| CN111739025B (en) * | 2020-05-08 | 2024-03-19 | 北京迈格威科技有限公司 | Image processing method, device, terminal and storage medium |
Also Published As
| Publication number | Publication date |
|---|---|
| CN108805945A (en) | 2018-11-13 |
| CN108805945B (en) | 2019-10-18 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US11019133B2 (en) | System and method for transferring states between electronic devices | |
| US10289603B2 (en) | Dynamic search partitioning | |
| US12179098B2 (en) | Rendering method and apparatus | |
| US10848434B2 (en) | Performance management for query processing | |
| CN110377391B (en) | Picture display method and device, mobile terminal and storage medium | |
| CN106453572B (en) | Method and system based on Cloud Server synchronous images | |
| US20210026905A1 (en) | Search Method, and Apparatus | |
| CN104509092B (en) | Method of controlling camera, related computing device and computer-readable storage medium | |
| US11232066B2 (en) | Method for data migration and terminal | |
| US11080322B2 (en) | Search methods, servers, and systems | |
| WO2018006833A1 (en) | Method and device for decoding variable-length coding file | |
| WO2017008646A1 (en) | Method of selecting a plurality targets on touch control terminal and equipment utilizing same | |
| WO2022242281A1 (en) | File storage method and apparatus, and electronic device and storage medium | |
| WO2020135131A1 (en) | Network hotspot switching method, intelligent terminal and computer-readable storage medium | |
| CN107943921B (en) | Page sharing information generation method and device, computer equipment and storage medium | |
| WO2018201993A1 (en) | Image drawing method, terminal and storage medium | |
| WO2015000417A1 (en) | Method, apparatus, application interactive platform, terminal, and system for uploading an image | |
| CN110413360A (en) | Image display method, device, mobile terminal and storage medium | |
| CN114546171A (en) | Data distribution method, device, storage medium and electronic device | |
| CN112383623B (en) | Multimedia file processing method and device, terminal and network access point equipment | |
| WO2015035899A1 (en) | Search methods and terminals | |
| CN106855816B (en) | Resource file loading method and device of application program in terminal | |
| CN120011263A (en) | Data sharing method, device and electronic equipment | |
| WO2024212965A1 (en) | Method and apparatus for sliding image preview and terminal device | |
| CN102571965A (en) | Method and device for starting service group in high-availability cluster |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 18794117 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 18794117 Country of ref document: EP Kind code of ref document: A1 |