CN102541538B - Picture displaying method and device based on mobile terminal - Google Patents
Picture displaying method and device based on mobile terminal Download PDFInfo
- Publication number
- CN102541538B CN102541538B CN201110401619.XA CN201110401619A CN102541538B CN 102541538 B CN102541538 B CN 102541538B CN 201110401619 A CN201110401619 A CN 201110401619A CN 102541538 B CN102541538 B CN 102541538B
- Authority
- CN
- China
- Prior art keywords
- picture
- list
- thread
- display
- loading
- 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.)
- Expired - Fee Related
Links
- 238000000034 method Methods 0.000 title claims abstract description 48
- 230000008859 change Effects 0.000 claims description 16
- 238000000151 deposition Methods 0.000 claims description 15
- 230000000694 effects Effects 0.000 abstract description 20
- 230000008569 process Effects 0.000 description 14
- 238000012217 deletion Methods 0.000 description 6
- 230000037430 deletion Effects 0.000 description 6
- 238000010276 construction Methods 0.000 description 3
- 238000001914 filtration Methods 0.000 description 3
- 230000004044 response Effects 0.000 description 3
- 230000001737 promoting effect Effects 0.000 description 2
- 230000001360 synchronised effect Effects 0.000 description 2
- 230000009471 action Effects 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
Landscapes
- Stored Programmes (AREA)
- User Interface Of Digital Computer (AREA)
Abstract
The invention is suitable for the technical field of a mobile terminal and provides a picture displaying method and device based on the mobile terminal. The method comprises a first thread and a second thread which is performed concurrently with the first thread, wherein the first thread comprises the steps of: establishing and initializing a picture list, a loading list and a displaying list, and displaying a preset background picture, and when the loading list is changed, updating the loading list and the displaying list; and the second thread comprises the steps of: when the loading list is not empty, acquiring a first ID (identifier) from the loading list and a picture object corresponding to the ID from the picture list, and when the ID is existent in the displaying list, updating the currently displayed picture into the picture object, deleting the ID in the loading list, updating the loading list, returning to the step of continuously acquiring the first ID from the loading list, and stopping until the loading list is empty. In such a way, the picture displaying speed is increased, the occupied system resource is reduced, and the user experience effect is improved.
Description
Technical field
The invention belongs to technical field of mobile terminals, particularly relate to a kind of image display method based on mobile terminal and device.
Background technology
At present, in the mobile terminal (televisor, mobile phone etc.) using Android system, when carrying out preview picture by grid view GridView control, make Consumer's Experience sense poor because existing image display method exists some defects, such as, if need the picture of preview too many, the picture needing to destroy cannot be located, internal memory will be caused to overflow; If (such as: picture cutting, network gets picture) shows again after every pictures all needs process, according to multithreading load mode, when running into, cpu processing power is poor, will have a strong impact on the display speed of picture; In addition, when using other asynchronous methods load and Show Picture, picture sequence can not be made to show, also cause the experience effect of user poor.
Summary of the invention
The object of the embodiment of the present invention is to provide a kind of image display method based on mobile terminal and device, be intended to solution utilize existing image display method in the terminal browsing pictures time, picture display speed is slow, and occupying system resources is more, causes the problem that Consumer's Experience effect is poor.
The embodiment of the present invention is achieved in that a kind of image display method based on mobile terminal, and described method comprises the first thread and the second thread with described first thread concurrence performance, wherein:
Described first thread comprises the following steps:
A1: build and initialization for deposit all pictorial informations just list, order deposit need load picture ID loading list and deposit current page need display picture the display list of ID and the picture of the current display of initialization is default background picture;
B1: when described loading list changes, upgrade described loading list and described display list, and show described default background picture; And
Described second thread comprises the following steps:
A2: when described loading list is not empty, obtains the object picture that described in first ID in described loading list and described just list, ID is corresponding;
B2: when there is described ID in described display list, the picture upgrading described current display is described object picture;
C2: delete the described ID in described loading list, upgrades described loading list;
D2: return and perform steps A 2, until stop when described loading list is empty.
Another object of the embodiment of the present invention is to provide a kind of image display apparatus based on mobile terminal, and described device comprises the first thread units and the second thread units with described first thread units concurrence performance, wherein:
First thread units, for building also initialization for depositing the just list of all pictorial informations, sequentially depositing the display list of the ID needing the loading list of the ID of the picture loaded and deposit the picture that current page needs show, and the picture of the current display of initialization is default background picture, and when described loading list changes, upgrade described loading list and described display list, and show described default background picture; And
Second thread units, for when judging described loading list not as sky, obtain the object picture that described in first ID in described loading list and described just list, ID is corresponding, when there is described ID in described display list, the picture upgrading described current display is described object picture, deletes the described ID in described loading list, upgrades described loading list, return the step continuing to perform first ID obtained in described loading list, until stop when described loading list is empty.
The image display method based on mobile terminal that the embodiment of the present invention proposes can concurrence performance first thread and the second thread, by utilize this first threading building and initialization for depositing the just list of all pictorial informations, order deposits the display list of the ID of the picture needing the loading list of the ID of the picture loaded and deposit the display of current page needs, and the picture of the current display of initialization is default background picture, and when this loading list changes, upgrade this loading list and this display list, this second thread is utilized to judge when this loading list is not as time empty, when there is the ID of the first width picture in this loading list in this display list, the picture upgrading this current display is the object picture that in this just list, this ID is corresponding, and this ID deleted in this loading list, and then upgrade this loading list, return the step continued included by execution second thread, until this loading list is empty, solve utilize existing image display method in the terminal browsing pictures time, picture display speed is slow, occupying system resources is more, causes the problem that Consumer's Experience effect is poor, improves picture display speed, reduce taking of system resource, reach the object promoting Consumer's Experience effect.
Accompanying drawing explanation
Fig. 1 is the realization flow figure of the first thread of the image display method based on mobile terminal that first embodiment of the invention provides;
Fig. 2 is the realization flow figure of the second thread of the image display method based on mobile terminal that first embodiment of the invention provides;
Fig. 3 is the realization flow figure of the first thread of the image display method based on mobile terminal that second embodiment of the invention provides;
Fig. 4 is the realization flow figure of the second thread of the image display method based on mobile terminal that second embodiment of the invention provides;
Fig. 5 is the structural drawing of the image display apparatus based on mobile terminal that third embodiment of the invention provides.
Embodiment
In order to make object of the present invention, technical scheme and advantage clearly understand, below in conjunction with drawings and Examples, the present invention is further elaborated.Should be appreciated that specific embodiment described herein only in order to explain the present invention, be not intended to limit the present invention.
The embodiment of the present invention passes through the step of concurrence performance first thread and the second thread, dynamically update in time and load list and display list, until stop the execution of the second thread when this loading list is sky, make in the terminal browsing pictures time, picture display speed is accelerated, occupying system resources is less, and Consumer's Experience effect gets a promotion.
Embodiments provide a kind of image display method based on mobile terminal, described method comprises the first thread and the second thread with described first thread concurrence performance, wherein:
Described first thread comprises the following steps:
A1: build and initialization for depositing the just list of all pictorial informations, order is deposited needs the loading list of the ID of the picture loaded and deposit the display list of ID that current page needs the picture of display, and the picture of the current display of initialization is default background picture;
B1: when described loading list changes, upgrade described loading list and described display list, and show described default background picture; And
Described second thread comprises the following steps:
A2: when described loading list is not empty, obtains the object picture that described in first ID in described loading list and described just list, ID is corresponding;
B2: when there is described ID in described display list, the picture upgrading described current display is described object picture;
C 2: delete the described ID in described loading list, upgrades described loading list;
D2: return and perform steps A 2, until stop when described loading list is empty.
The embodiment of the present invention additionally provides a kind of image display apparatus based on mobile terminal, and described device comprises the first thread units and the second thread units with described first thread units concurrence performance, wherein:
First thread units, for building also initialization for depositing the just list of all pictorial informations, sequentially depositing the display list of the ID needing the loading list of the ID of the picture loaded and deposit the picture that current page needs show, and the picture of the current display of initialization is default background picture, and when described loading list changes, upgrade described loading list and described display list, and show described default background picture; And
Second thread units, for when judging described loading list not as sky, obtain the object picture that described in first ID in described loading list and described just list, ID is corresponding, when there is described ID in described display list, the picture upgrading described current display is described object picture, deletes the described ID in described loading list, upgrades described loading list, return the step continuing to perform first ID obtained in described loading list, until stop when described loading list is empty.
The embodiment of the present invention is by concurrence performance first thread and the second thread, utilize the first threading building initialization list related, and when the reference position of this loading list changes, dynamically update and load list and display list, second thread to load this picture according to the loading list of synchronized update and display list and shows, the Image ID that timely deletion has loaded, until stop the execution of the second thread when loading list is sky, improve the display speed of picture, decrease taking of system resource, thus achieve the object promoting Consumer's Experience effect.
Below in conjunction with specific embodiment, specific implementation of the present invention is described in detail:
embodiment one:
Fig. 1,2 shows the first thread of the image display method based on mobile terminal that first embodiment of the invention provides and the realization flow of the second thread, and details are as follows:
The first thread and the second thread with this first thread concurrence performance should be comprised based on the image display method of mobile terminal, wherein:
This first thread comprises the following steps, as shown in Figure 1:
In step S101, build and initialization for depositing the just list of all pictorial informations, order is deposited needs the loading list of the ID of the picture loaded and deposit the display list of ID that current page needs the picture of display, and the picture of the current display of initialization is default background picture.
Wherein, this pictorial information comprises the ID of all pictures, corresponding picture path, object picture etc., this ID is for identifying each width picture, can be the sequence number, picture name etc. of picture, this object picture refers to a picture entity, and such as the picture of a width jpg form is an object picture or picture entity.It is to be noted initialization time, ID and the picture path of this picture all exist, and object picture does not exist, for sky, and only in subsequent step implementation, when getting the object picture needing display, this object picture is processed into required dimension of picture, after rationally showing, just this object picture is filled into the corresponding position in this just list, avoids the wasting of resources.
Particularly, this loading list is used for sequentially depositing the ID needing the picture in just list loaded, after the second thread starts, also after namely picture adds the startup of carrier thread, by the ID deposited in this loading list, from this just list, find corresponding pictorial information, and then obtain corresponding object picture, when this object picture is empty, then obtain this object picture according to the Image ID in this pictorial information, path etc.
Particularly, this display list is used for depositing the ID that current page needs the picture in the just list of display, and this display list can be used for judging that photo current loads picture in list the need of loading or show.
In embodiments of the present invention, by building list and the construction method of data structure form, accurately can control this just list, loading list and display list; Due to when initialization, current display is generally sky, and Consumer's Experience effect is poor, is default background picture by the picture of the current display of initialization, and the picture that this background picture preset can be sky or arranges arbitrarily, Consumer's Experience effect can be promoted.
In step s 102, when this loading list changes, upgrade this loading list and this display list, and show this background picture preset.
Wherein, this loading list changes as the scroll bar of mobile terminal screen is dragged by the mode of quick key or touch or slided, or the change caused when current screen occurs to convert.Particularly, during beginning, if screen one page shows 15 width pictures, the picture that so current needs load is front 15 width in just list, the ID of these pictures will deposit according to loading sequence in this loading list, such as No. ID is followed successively by 0 to 14, if when loading that in this loading list, ID is the picture of 0, user has slided screen, now, in this loading list, ID order becomes 0 to 19, after a few second, ID be 0 picture loaded after, its ID will be removed from this loading list, now, in this loading list, ID just becomes 1 to 19, and order Loads Image and can improve the experience effect of user, and the length of this loading list also can add carrier thread according to picture, also namely the second thread loading progress and slide up and down screen and reduce and increase.
In specific implementation process, when the reference position of this loading list does not change, then delete in just list, showed and the object picture that do not show of this page at upper page, thus obtain the picture needing to destroy in time, with releasing memory, reduce the probability that internal memory overflows, it should be noted that the step of this deletion can utilize existing GridView control to realize automatically deleting, and be confirmed whether to delete or destroy picture without terminal, and delete this this display list and the ID loading the corresponding picture of list, to upgrade this display list further and to load list.
This second thread comprises the following steps, as shown in Figure 2:
In step s 201, when this loading list is not empty, obtain the object picture that in first ID in this loading list and this just list, this ID is corresponding.
In specific implementation process, after the second thread starts, need to judge whether this loading list is empty, also can judge whether the length of this loading list is 0, if this loading list is not empty, or this length is not 0, then perform the step of the second thread, obtain first ID in this loading list, otherwise, stop execution second thread, and now, only have this first thread in execution.
This step S201 is further comprising the steps of:
When the object picture that this ID in this just list is corresponding does not exist, obtain corresponding object picture according to the corresponding already present pictorial information of this ID;
The size of this object picture is processed into required size, position corresponding in this object picture after specimens preserving to this just list.
Particularly, after obtaining first ID in this loading list, also loading first width picture is namely needed, because the Image ID in this loading list loads sequence in order, when having loaded a width picture, ID corresponding for this picture will be deleted, thus next width Image ID of this picture is the first width Image ID, for first ID in this loading list, carry out dynamically updating of this loading list, therefore obtaining in the Image ID process loaded, only need first ID obtained in this loading list can realize order to load, and realization order display further, improve Consumer's Experience.
In step S202, when there is this ID in this display list, the picture upgrading this current display is this object picture.
This step S202 also comprises:
When there is not this ID in this display list, directly deleting this ID in this loading list, upgrading this loading list.
In specific implementation process, by the mode of filtering, only resolve the current picture needing display in display list, replace the background picture that this is preset simultaneously, when there is not the ID Loaded Image in this display list, no longer show the object picture that this ID is corresponding, particularly, due to this first thread and this second thread concurrence performance, when mobile terminal screen current state changes, real-time update this loading list and display list, now carry out judging whether there is this ID in this display list, when display list can be avoided to change and there is not corresponding ID, still show corresponding object picture, resource is caused to use too high, picture display speed is slow, and button is without the generation of response condition, effectively point out the display speed of picture.
In step S203, delete this ID in this loading list, upgrade this loading list.
In step S204, return and continue to perform this above-mentioned steps included by the second thread, until the stopping when this loading list be sky.
Particularly, when having loaded a width picture, this ID in this loading list will be deleted, thus the ID of next width picture of this picture being first ID, having carried out loading dynamically updating of list, having achieved the object that order Loads Image.After loading completes, this second thread needs to continue to load other pictures, then now jump to step S201 and perform, until when this loading list is empty, stop the execution of this second thread.
In embodiments of the present invention, the method loaded based on picture in the image display method of mobile terminal due to this is Asynchronous loading, then it first thread comprised and the second thread are concurrence performance in no particular order, also namely corresponding main thread and picture add carrier thread respectively, when the loading list in main thread and display list change, picture adds in carrier thread the picture loading and show and also can dynamically change.And do not adopt multithreading in the embodiment of the present invention, but directly to adopt the mode of HandlerThread to control single-threaded picture process consuming time of carrying out, because for low terminal, multithreading consumes very much cpu resource, in picture decode and this workload hard work of reduction, not only can not play and propose high performance effect, and can performance be reduced.Can be used for creating a new thread easily by HandlerThread, then a looper is obtained, to specify follow-up handler to perform in new thread, and without oneself removing to write a thread class again, then the operations such as looper are created, so avoid the expense creating new thread, improve thread utilization factor, reduce taking of system resource.
embodiment two:
Fig. 3 shows the realization flow of the first thread of the image display method based on mobile terminal that second embodiment of the invention provides, be specially the realization flow of first thread of this image display method based on mobile terminal, this first thread is served as theme journey, and with this second thread concurrence performance, details are as follows:
In step S301, build and initialization just list, load list and display list.
Wherein, this just list is for depositing all pictorial informations, this pictorial information comprises the ID of all pictures, corresponding picture path, object picture etc., this ID, for identifying each width picture, can be the sequence number, picture name etc. of picture, this object picture refers to a picture entity, and such as the picture of a width jpg form is an object picture or picture entity.It is to be noted initialization time, ID and the picture path of this picture all exist, and object picture does not exist, for sky, and only in subsequent step implementation, when getting the object picture needing display, this object picture is processed into required dimension of picture, after rationally showing, just this object picture is filled into the corresponding position in this just list, avoids the wasting of resources.
This loading list is used for sequentially depositing the ID needing the picture in just list loaded, after the second thread starts, also after namely picture adds the startup of carrier thread, by the ID deposited in this loading list, corresponding pictorial information is found from this just list, and then obtain corresponding object picture, when this object picture is empty, then obtain this object picture according to the Image ID in this pictorial information, path etc.
This display list is used for depositing the ID that current page needs the picture in the just list of display, and this display list can be used for judging that photo current loads picture in list the need of loading or show.
In step s 302, the background picture that display is default.
Particularly, due to when initialization, current screen display is generally sky, Consumer's Experience effect is poor, be default background picture by the picture of the current display of initialization, and this background picture preset can be the picture arranged arbitrarily, can promote Consumer's Experience effect.
In step S303, judge whether the second thread starts, and is, performs step S304, otherwise perform step S307.
In step s 304, judge whether this loading list changes, and is, then perform step S305, otherwise perform step S306.
In step S305, after upgrading this loading list and display list, return and perform step S302.
In step S306, delete upper page display in just list and the object picture that do not show of this page.
In step S307, judge whether this loading list is empty, is then return and perform step S304, otherwise performs step S308, start this second thread.
Wherein, this loading list changes as the scroll bar of mobile terminal screen is dragged by the mode of quick key or touch or slided, or the change caused when current screen occurs to convert.
In specific implementation process, no matter whether this second thread starts, as long as when this loading list changes, then upgrades this loading list and display list, if now this second thread starts, then the loading list used in this thread and display list synchronous dynamic upgrade; When the reference position of this loading list does not change, then delete in just list, showed and the object picture that do not show of this page at upper page, thus obtain the picture needing to destroy in time, with releasing memory, reduce the probability that internal memory overflows, it should be noted that the step of this deletion can utilize existing GridView control to realize automatically deleting, and be confirmed whether to delete or destroy picture without terminal, and delete this this display list and the ID loading the corresponding picture of list, to upgrade this display list further and to load list.
In addition, if this second thread starts, then in execution second thread process, after completing the loading of picture, this loading list is empty, then stop performing this second thread, thus only perform this first thread, now according to Rule of judgment, can show that should go to step S304 place performs.
In embodiments of the present invention, by building list and the construction method of data structure form, accurately can control this just list, loading list and display list; By dynamically updating this loading list, display list, picture implementation order being loaded and order display, user's effect can be promoted; According to when the reference position of this loading list changes, display list and the loading list of the second thread also can synchronously dynamically update, to improve the utilization factor of thread; According to when the reference position of this loading list does not change, in no deletion just list, showed and the object picture that do not show of this page at upper page, to obtain the picture needing to destroy in time, with releasing memory, reduced the probability that internal memory overflows.
Fig. 4 shows the realization flow of the second thread of the image display method based on mobile terminal that second embodiment of the invention provides, be specially the realization flow of second thread of this image display method based on mobile terminal, this second thread is that picture adds carrier thread, and with this first thread concurrence performance, details are as follows:
In step S401, start this second thread.
In step S402, judge whether this loading list is empty, no, then perform step S404, be, then perform step S403, stops performing this second thread.
In specific implementation process, if the second thread starts, then after the loading completing picture, this loading list is empty, then stop performing this second thread, thus only perform this first thread.
In step s 404, the object picture that in first ID in this loading list and this just list, this ID is corresponding is obtained.
In step S405, judge whether this ID exists in this display list, is, then jump to and perform step S408, otherwise perform step S406.
In step S406, the already present pictorial information corresponding according to this ID obtains corresponding object picture.
In step S 407, the size of this object picture is processed into required size, position corresponding in this object picture after specimens preserving to this just list.
Particularly, after obtaining first ID in this loading list, also loading first width picture is namely needed, because the Image ID in this loading list loads sequence in order, when having loaded a width picture, ID corresponding for this picture will be deleted, thus next width Image ID of this picture is the first width Image ID, for first ID in this loading list, carry out dynamically updating of this loading list, therefore obtaining in the Image ID process loaded, only need first ID obtained in this loading list can realize order to load, and realization order display further, improve Consumer's Experience.When obtaining object picture corresponding to first ID in this loading list, due to reasons such as initialization, when may not store this object picture in this just list, then obtain this object picture according to the information such as ID, picture path of picture in this just list, after this object picture process, be saved in described just list, thus just storing all object pictures without during initialization, saving memory source.
In step S408, judge whether this ID exists in this display list, is, then perform step S409, no, then perform step S410.
In specific implementation process, when there is this ID in this display list, then show corresponding object picture, but, also may in the very short time before execution judges action, there is this ID in this display list, but when performing this determining step, because in the first thread, the change of this display list makes this ID not exist, and upgrade due to the dynamic synchronization of this display list, make judged result be that this ID does not exist in this display list, so utilize two thread concurrence performance, effectively can improve the display speed of picture or its thumbnail.
In step S409, utilize the background picture display that this picture replaces this to preset.
In step S410, delete this ID in this loading list, upgrade this loading list, and return execution step S402.
In specific implementation process, by the mode of filtering, only resolve the current picture needing display in display list, replace the background picture that this is preset simultaneously, when there is not the ID Loaded Image in this display list, no longer show the object picture that this ID is corresponding, particularly, due to this first thread and this second thread concurrence performance, when mobile terminal screen current state changes, real-time update this loading list and display list, now carry out judging whether there is this ID in this display list, when display list can be avoided to change the ID that there is not correspondence, still show corresponding object picture, resource is caused to use too high, picture display speed is slow, and button is without the generation of response condition, effectively point out the display speed of picture.And when having loaded a width picture, this ID in this loading list will be deleted, thus the ID of the lower piece image of this picture is first ID, carry out loading dynamically updating of list, achieve the object that order Loads Image, then return and judge whether this loading list is empty step, repeats above-mentioned steps, until this is loaded as sky, stop performing this second thread.
In embodiments of the present invention, utilize loading and the display of carrying out picture with this second thread of the first thread concurrence performance, can effectively must load picture and show, improve the display speed of picture, improve thread utilization factor, reduce the resource overhead etc. when opening thread.
One of ordinary skill in the art will appreciate that all or part of step realized in above-described embodiment method is that the hardware that can carry out instruction relevant by program has come, described program can be stored in a computer read/write memory medium, described storage medium, as ROM/RAM, disk, CD etc.
embodiment three:
Fig. 5 shows the structure of the image display apparatus based on mobile terminal that third embodiment of the invention provides, and for convenience of explanation, illustrate only the part relevant to the embodiment of the present invention.
The first thread units 51 and the second thread units 52 with this first thread units 51 concurrence performance should be comprised based on the image display apparatus of mobile terminal, wherein:
First thread units 51 is for building also initialization for depositing the just list of all pictorial informations, sequentially depositing the display list of the ID needing the loading list of the ID of the picture loaded and deposit the picture that current page needs show, and the picture of the current display of initialization is default background picture, and when this loading list changes, upgrade this loading list and this display list, and show this background picture preset.
Wherein, this pictorial information comprises the ID of all pictures, corresponding picture path, object picture etc., this ID is for identifying each width picture, can be the sequence number, picture name etc. of picture, this object picture refers to a picture entity, and such as the picture of a width jpg form is an object picture or picture entity.
This background picture preset is picture that is empty or that arrange arbitrarily.
This loading list changes as the scroll bar of mobile terminal screen is dragged by the mode of quick key or touch or slided, or the change caused when current screen occurs to convert.
In embodiments of the present invention, by building list and the construction method of data structure form, accurately can control this just list, loading list and display list; Due to when initialization, current display is generally sky, and Consumer's Experience effect is poor, is default background picture, can promotes Consumer's Experience effect by the picture of the current display of initialization.
This first thread units 51 also for when the reference position of this loading list does not change, then deletes the display of upper page and the picture that do not show of this page.
In embodiments of the present invention, when the reference position of this loading list does not change, then delete in just list, showed and the object picture that do not show of this page at upper page, thus obtain the picture needing to destroy in time, with releasing memory, reduce the probability that internal memory overflows, it should be noted that the step of this deletion can utilize existing GridView control to realize automatically deleting, and be confirmed whether to delete or destroy picture without terminal, and delete this this display list and the ID loading the corresponding picture of list, to upgrade this display list further and to load list.
When second thread units 52 is not for being empty when this loading list, obtain the object picture that in the first width ID in this loading list and this just list, this ID is corresponding, and when there is this ID in this display list, the picture upgrading this current display is this object picture, delete the described ID in this loading list, upgrade this loading list, return and continue to perform the step obtaining first ID in this loading list, until stop when this loading list is empty.
When this second thread units 52 does not also exist for the object picture corresponding as this ID in this just list, corresponding object picture is obtained according to the corresponding already present pictorial information of this ID, and the size of this object picture is processed into required size, position corresponding in this object picture after specimens preserving to this just list.
In embodiments of the present invention, when utilizing this second thread units 52 to obtain object picture corresponding to first ID in this loading list, due to reasons such as initialization, when may not store this object picture in this just list, then obtain this object picture according to the information such as ID, picture path of picture in this just list, after this object picture process, be saved in described just list, thus just store all object pictures without during initialization, save memory source.
This second thread units 52, also for when there is not this ID in this display list, directly being deleted this ID in this loading list, being upgraded this loading list.
In embodiments of the present invention, by the mode of filtering, only resolve the current picture needing display in display list, replace the background picture that this is preset simultaneously, when judging there is not the ID Loaded Image in this display list when utilizing this second thread units 52, no longer show the object picture that this ID is corresponding, particularly, due to this first thread and this second thread concurrence performance, when mobile terminal screen current state changes, real-time update this loading list and display list, now carry out judging whether there is this ID in this display list, when display list can be avoided to change the ID that there is not correspondence, still show corresponding object picture, resource is caused to use too high, picture display speed is slow, and button is without the generation of response condition, effectively point out the display speed of picture.
In embodiments of the present invention, utilize the image display apparatus based on mobile terminal comprising the first thread units 51 and the second thread units 52 with this first thread units 51 concurrence performance, improve in the terminal browsing pictures time, picture display speed is slow, occupying system resources is more, causes the problem that Consumer's Experience effect is poor, improves picture display speed, reduce taking of system resource, thus improve Consumer's Experience effect.
Embodiments provide the image display method based on mobile terminal of a kind of concurrence performance first thread and the second thread, by the first thread execution when loading list and changing, dynamically update this loading list and display list, second thread execution is not when this loading list is empty, obtain the object picture that in first ID in this loading list and just list, this ID is corresponding, when there is this ID in this display list, the picture upgrading this current display is this object picture, this ID in this loading list of timely deletion, upgrade this loading list, until stop execution second thread when this loading list is empty, solve utilize existing image display method in the terminal browsing pictures time, picture display speed is slow, occupying system resources is more, cause the problem that Consumer's Experience effect is poor, improve picture display speed, reduce taking of system resource, thus improve Consumer's Experience effect.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, all any amendments done within the spirit and principles in the present invention, equivalent replacement and improvement etc., all should be included within protection scope of the present invention.
Claims (7)
1. based on an image display method for mobile terminal, it is characterized in that, described method comprises the first thread and the second thread with described first thread concurrence performance, wherein:
Described first thread comprises the following steps:
A1: build and initialization for deposit all pictorial informations just list, order deposit need load picture ID loading list and deposit current page need display picture the display list of ID and the picture of the current display of initialization is default background picture;
B1: when described loading list changes, upgrade described loading list and described display list, and show described default background picture; And
Described second thread comprises the following steps:
A2: when described loading list is not empty, obtains the object picture that described in first ID in described loading list and described just list, first ID is corresponding;
B2: when there is described first ID in described display list, the picture upgrading described current display is described object picture;
C2: delete described first ID in described loading list, upgrade described loading list;
D2: return and perform steps A 2, until stop when described loading list is empty;
Described pictorial information comprises the ID of picture, corresponding picture path, object picture, and during initialization, ID and the picture path of each width picture all exist, and object picture does not exist, and described object picture is a picture entity;
After described steps A 2, before step B2, described second thread is further comprising the steps of:
When the object picture that first ID described in described just list is corresponding does not exist, obtain corresponding object picture according to the corresponding already present pictorial information of described first ID;
The size of described object picture is processed into required size, position corresponding in the described object picture after specimens preserving to described just list.
2. the method for claim 1, is characterized in that, described first thread is further comprising the steps of:
When described loading list does not change, then delete the display of upper page and the picture that do not show of this page.
3. the method for claim 1, is characterized in that, described second thread also comprises:
When there is not described first ID in described display list, directly deleting described first ID in described loading list, upgrading described loading list.
4. based on an image display apparatus for mobile terminal, it is characterized in that, described device comprises the first thread units and the second thread units with described first thread units concurrence performance, wherein:
First thread units, for building also initialization for depositing the just list of all pictorial informations, order deposits the display list of the ID of the picture needing the loading list of the ID of the picture loaded and deposit the display of current page needs, and the picture of the current display of initialization is default background picture, and when described loading list changes, upgrade described loading list and described display list, and show described default background picture, described pictorial information comprises the ID of picture, corresponding picture path, object picture, and during initialization, ID and the picture path of each width picture all exist, and object picture does not exist, described object picture is a picture entity, and
Second thread units, for when judging described loading list not as sky, obtain the object picture that described in first ID in described loading list and described just list, first ID is corresponding, when there is described first ID in described display list, the picture upgrading described current display is described object picture, delete described first ID in described loading list, upgrade described loading list, return the step continuing to perform first ID obtained in described loading list, until stop when described loading list is empty;
When second thread units does not also exist for the object picture corresponding as first ID described in described just list, corresponding object picture is obtained according to the corresponding already present pictorial information of described first ID, and the size of described object picture is processed into required size, position corresponding in the described object picture after specimens preserving to described just list.
5. device as claimed in claim 4, is characterized in that, described default background picture is empty or any image.
6. device as claimed in claim 4, is characterized in that, described first thread units also for when described loading list does not change, is then deleted upper page and shown and the picture that do not show of this page.
7. device as claimed in claim 4, is characterized in that, described second thread units, also for when there is not described first ID in described display list, directly being deleted described first ID in described loading list, being upgraded described loading list.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110401619.XA CN102541538B (en) | 2011-12-06 | 2011-12-06 | Picture displaying method and device based on mobile terminal |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110401619.XA CN102541538B (en) | 2011-12-06 | 2011-12-06 | Picture displaying method and device based on mobile terminal |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102541538A CN102541538A (en) | 2012-07-04 |
CN102541538B true CN102541538B (en) | 2015-02-11 |
Family
ID=46348515
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201110401619.XA Expired - Fee Related CN102541538B (en) | 2011-12-06 | 2011-12-06 | Picture displaying method and device based on mobile terminal |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102541538B (en) |
Families Citing this family (20)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103593231B (en) | 2012-08-14 | 2016-06-01 | 腾讯科技(深圳)有限公司 | A kind of data processing method, device and mobile terminal |
CN103678357B (en) * | 2012-09-13 | 2018-12-11 | 腾讯科技(深圳)有限公司 | A kind of method and device of acquisition for mobile terminal picture thumbnail |
CN103760966B (en) * | 2013-05-02 | 2017-01-11 | 乐视网信息技术(北京)股份有限公司 | Picture buffering implementation method |
CN104252367B (en) * | 2013-06-27 | 2017-12-19 | 北京新媒传信科技有限公司 | The method and system of Asynchronous loading picture in a kind of intelligent terminal |
CN104252350B (en) * | 2013-06-28 | 2018-05-11 | 北京新媒传信科技有限公司 | A kind of method and apparatus of picture in loading list box |
CN103324740B (en) * | 2013-06-28 | 2017-08-25 | 深圳市九洲电器有限公司 | A kind of image display method, device and set top box |
CN103544207B (en) * | 2013-08-19 | 2019-01-29 | Tcl集团股份有限公司 | A kind of method and system of picture loaded and displayed |
CN104424333A (en) * | 2013-09-11 | 2015-03-18 | 北大方正集团有限公司 | Method and system for loading table data |
CN103593158B (en) * | 2013-11-27 | 2017-11-10 | 广东欧珀移动通信有限公司 | The display methods and device of picture in picture wall |
CN103678612A (en) * | 2013-12-17 | 2014-03-26 | 深圳市东信时代信息技术有限公司 | Photo-wall distributing device and method |
CN104391618A (en) * | 2014-07-01 | 2015-03-04 | 贵阳朗玛信息技术股份有限公司 | Method and device for loading pictures |
CN104238888B (en) * | 2014-09-18 | 2019-06-07 | 努比亚技术有限公司 | A kind of mobile terminal and its global method and apparatus for checking picture |
CN105573767A (en) * | 2014-10-10 | 2016-05-11 | 惠州市德赛西威汽车电子股份有限公司 | Interface image loading method in vehicle-mounted entertainment system |
CN105512170A (en) * | 2015-11-19 | 2016-04-20 | 南京信息工程大学 | Radar mosaic display optimizing method based on gestures |
CN105843831A (en) * | 2016-01-15 | 2016-08-10 | 乐视移动智能信息技术(北京)有限公司 | Mobile terminal image display method and system |
CN110058764A (en) * | 2016-03-21 | 2019-07-26 | 青岛海信移动通信技术股份有限公司 | A kind of picture loading method, device and terminal |
CN108874477B (en) * | 2017-05-11 | 2021-06-15 | 武汉斗鱼网络科技有限公司 | Method and device for displaying static pictures and dynamic pictures |
JP7028698B2 (en) * | 2018-04-13 | 2022-03-02 | シャープ株式会社 | Electronics, controls, control methods, and control programs |
CN109240766A (en) * | 2018-08-31 | 2019-01-18 | 北京龙创悦动网络科技有限公司 | A kind of method and apparatus for the resource that Loads Image |
CN109756709A (en) * | 2018-12-28 | 2019-05-14 | 北京工业大学 | A kind of performance improvement method in infrared panorama monitoring software |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101183386A (en) * | 2007-12-07 | 2008-05-21 | 腾讯科技(深圳)有限公司 | Multi-page browsers web page sub-windows process method and multi-page browsers |
CN101794567A (en) * | 2010-02-10 | 2010-08-04 | 中兴通讯股份有限公司 | Method and terminal for loading pictures |
-
2011
- 2011-12-06 CN CN201110401619.XA patent/CN102541538B/en not_active Expired - Fee Related
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101183386A (en) * | 2007-12-07 | 2008-05-21 | 腾讯科技(深圳)有限公司 | Multi-page browsers web page sub-windows process method and multi-page browsers |
CN101794567A (en) * | 2010-02-10 | 2010-08-04 | 中兴通讯股份有限公司 | Method and terminal for loading pictures |
Also Published As
Publication number | Publication date |
---|---|
CN102541538A (en) | 2012-07-04 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102541538B (en) | Picture displaying method and device based on mobile terminal | |
WO2021218327A1 (en) | Page processing method and related device | |
US9619275B2 (en) | Data processing method, apparatus and mobile terminal | |
EP3514689A1 (en) | Memory management method and apparatus | |
CN103186919B (en) | A kind of word rendering intent and device | |
CN105630478B (en) | A kind of method and apparatus for realizing page switching | |
CN103760966B (en) | Picture buffering implementation method | |
CN103544207B (en) | A kind of method and system of picture loaded and displayed | |
US20200084182A1 (en) | System for remotely controlling electronic device and method of operating the same | |
CN110300328B (en) | Video playing control method and device and readable storage medium | |
CN104657380A (en) | Picture loading method and device | |
CN103428251A (en) | Download task allocation method and device | |
WO2020220971A1 (en) | File loading method and apparatus, electronic device, and storage medium | |
US11232066B2 (en) | Method for data migration and terminal | |
KR20180019158A (en) | METHOD AND DEVICE FOR PREVIEWING A DYNAMIC IMAGE, AND METHOD AND DEVICE FOR DISPLAYING A DISPLAY PACKAGE | |
CN105955770A (en) | Application program uninstalling method and terminal | |
CN103902575A (en) | Pictorial information loading method and related device | |
CN104601535B (en) | Method for processing video frequency and system | |
CN103856507A (en) | Network dynamic picture static display method and device | |
CN104424333A (en) | Method and system for loading table data | |
US20130097555A1 (en) | Dynamic content preview cycling model for answers with transitions | |
CN103699296A (en) | Intelligent terminal and episode serial number prompt method | |
CN108958808A (en) | Method for starting terminal and device, terminal and storage medium | |
CN103377071A (en) | Data batch delete method and system | |
CN103618961A (en) | Method, system and browser for displaying video title |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20150211 |