CN106933884A - A kind of picture loading method and device - Google Patents
A kind of picture loading method and device Download PDFInfo
- Publication number
- CN106933884A CN106933884A CN201511029954.6A CN201511029954A CN106933884A CN 106933884 A CN106933884 A CN 106933884A CN 201511029954 A CN201511029954 A CN 201511029954A CN 106933884 A CN106933884 A CN 106933884A
- Authority
- CN
- China
- Prior art keywords
- picture
- caching
- viewing area
- loaded
- preset range
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/02—Addressing or allocation; Relocation
- G06F12/08—Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
- G06F12/0802—Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
- G06F12/0862—Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches with prefetch
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/02—Addressing or allocation; Relocation
- G06F12/08—Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
- G06F12/12—Replacement control
- G06F12/121—Replacement control using replacement algorithms
- G06F12/123—Replacement control using replacement algorithms with age lists, e.g. queue, most recently used [MRU] list or least recently used [LRU] list
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/17—Details of further file system functions
- G06F16/172—Caching, prefetching or hoarding of files
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2212/00—Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
- G06F2212/10—Providing a specific technical effect
- G06F2212/1016—Performance improvement
- G06F2212/1024—Latency reduction
Abstract
The invention discloses a kind of picture loading method and device.The method includes:When the picture in current display area is shown, the picture outside the pre-loaded viewing area;The pre-loaded picture of caching.The present invention is preloaded to the picture outside on-screen display (osd) area, and picture is cached after completion is loaded, so that when user slides the page, quickly displaying picture improves Consumer's Experience effect.
Description
Technical field
The present invention relates to field of computer technology, more particularly to a kind of picture loading method and device.
Background technology
In the prior art, application program (Application, abbreviation APP) can disposably load multiple
Picture, and, in browsing list page, the picture number that can be shown in the page is usually not limited.By
In mobile terminal screen viewing area, size is fixed, so generally only loading is in page pictures in viewing area,
During user's slide downward page, the new picture appeared in viewing area is reloaded.At present, in order to reduce stream
The consumption of amount, while ensureing the smooth Consumer's Experiences of APP, the picture that will can have been loaded is delayed
Deposit, during position before be rolled back to for the page by user, it is allowed to which control Loads Image from caching, so may be used
To avoid re-downloading, processing the process of picture.
Existing cache policy is used mostly and at least uses algorithm (Least Recently Used, abbreviation in the recent period
LRU), will most recently used picture be inserted into a buffer queue, when caching beyond set size
When, reject the least recently used picture resource for arriving.So when App list pages are slided, can preferentially read
Picture in caching, just can be from network download pictures when picture does not exist in caching.
Although existing cache policy can be reused to caching picture, in sliding list page
During, can not show immediately due to the new picture that was never shown in viewing area not in the buffer
Show to come, user still needs to wait picture to load, and waits picture process from scratch, and Consumer's Experience is still
Need optimization.
The content of the invention
The present invention provides a kind of picture loading method and device, is used to solve in the prior art never in viewing area
Not in the buffer, user still needs to wait the problem of picture loading the new picture shown in domain.
For above-mentioned technical problem, the present invention is solved by the following technical programs.
The invention provides a kind of picture loading method, including:When the picture in current display area is shown,
Picture outside the pre-loaded viewing area;The pre-loaded picture of caching.
Wherein, also include:When the caching with capacity when being more than default threshold value, in the caching
Remove the picture farthest apart from current display area.
Wherein, the picture outside the pre-loaded viewing area, including:It is pre-loaded in described
Picture outside viewing area within preset range.
Wherein, the preset range is located at the viewing area both sides;Or, the preset range is located at institute
State viewing area side.
Wherein, before the picture in the display current display area, also include:Judge described current aobvious
Show that the picture in region whether there is in the caching;If so, then obtaining the picture from the caching
And show;If it is not, then loading the picture from network side and showing, and cache the picture of loading.
Present invention also offers a kind of picture loading device, including:Load-on module, for current aobvious in display
When showing the picture in region, the picture outside the pre-loaded viewing area;Cache module, for caching
The pre-loaded picture.
Wherein, described device also includes removing module;The removing module, for having used when the caching
When capacity is more than default threshold value, the picture farthest apart from current display area is removed in the caching.
Wherein, the load-on module is used for:It is pre-loaded outside the viewing area within preset range
Picture.
Wherein, the preset range is located at the viewing area both sides;Or, the preset range is located at institute
State viewing area side.
Wherein, the load-on module is additionally operable to:Before picture in the display current display area, sentence
Picture in the current display area of breaking whether there is in the caching;In the case where being judged to be,
The picture is then obtained from the caching and is shown;Be judged to it is no in the case of, then from network side load
The picture simultaneously shows, and caches the picture of loading.
The present invention has the beneficial effect that:
The present invention is preloaded to the picture outside on-screen display (osd) area, and right after completion is loaded
Picture is cached, so that when user slides the page, quickly displaying picture improves Consumer's Experience effect.
Brief description of the drawings
Fig. 1 is the flow chart of picture loading method according to an embodiment of the invention;
Fig. 2 is picture loading schematic diagram according to an embodiment of the invention;
Fig. 3 is the structure chart of picture loading device according to an embodiment of the invention.
Specific embodiment
The present invention in the case where APP needs the scene for loading a large amount of pictures, to outside on-screen display (osd) area
Picture is preloaded, and load complete after picture is cached, so as to user slide the page when,
Quickly displaying picture, improves Consumer's Experience effect.Further, the present invention reaches predetermined value in buffer memory capacity
When, according to picture apart from the distance of viewing area, the picture resource farthest apart from viewing area is first reclaimed, then
The picture resource nearer apart from viewing area is reclaimed, the effective rate of utilization of caching is improved successively.
Below in conjunction with accompanying drawing and embodiment, the present invention will be described in further detail.It should be appreciated that this
The described specific embodiment in place is only used to explain the present invention, does not limit of the invention.
The embodiment of the invention provides a kind of picture loading method.Fig. 1 is figure according to an embodiment of the invention
The flow chart of piece loading method.
Step S110, when the picture in current display area is shown, outside the pre-loaded viewing area
Picture.
Before picture in the display current display area, current display area of the page in screen is obtained
Domain;Judge that the picture in the current display area whether there is in caching;If so, then from the caching
It is middle to obtain the picture and show;If it is not, then load the picture from network side and show, and need by
The picture of loading is cached, can subsequently to reuse the picture.
When picture in the display current display area, in order that the picture that user will browse is quick
Show, the picture outside the pre-loaded viewing area, if buffer memory capacity is limited, can be advance
Loading is outside the viewing area, the picture within preset range.The preset range is located at viewing area
Around, and it is adjacent with viewing area.Include one or more picture in the preset range.
Specifically, preset range is located at viewing area both sides;Or preset range is located at viewing area side.
Preset range can be set according to the capacity of caching, i.e., the active volume according to caching allows to preload
Picture number preset range is set.
Preset range can be weighed with area, it is also possible to be weighed with picture number.For example:Preset range
Area be equal to viewing area area, in other words, preload the previous screen of current display area in the range of
Picture in the range of picture and/or latter screen.And for example:Preset range is the plurality of pictures institute close to viewing area
Scope.When the page is obtained, it is possible to know the position of every pictures in the page, therefore can basis
Which pictures position of the picture among the page is determine needs loading.
If preset range is located at the side of viewing area, the direction that can slide the page according to user determines
The position of preset range.For example:If user's upward sliding page, preset range is located under viewing area
Side;If user's slide downward page, preset range is located at viewing area top.
Step S120, caches the pre-loaded picture.
During user slides the page, constantly caching preloads picture, because the capacity for caching has
The upper limit, so when the caching with capacity when being more than default threshold value, distance is removed in the caching
The farthest picture of current display area.The threshold value is experiment value or empirical value.Cache overflow can be so prevented,
Can also ensure that the picture in the close region of current display area can quickly show.
For example:Fig. 2 is picture loading schematic diagram according to an embodiment of the invention.The page in this example is row
Table page, there is n (n is more than 0) pictures in list page;Picture of the page in on-screen display (osd) area is picture
3rd, picture 4 and picture 5, before display picture 3, picture 4 and picture 5, first determine in caching whether
Picture 3, picture 4 and picture 5 are stored, if stored, with direct access and can have been shown,
If do not stored, Loaded Image from network side and 3, picture 4 and picture 5 and shown, afterwards caching figure
Piece 3, picture 4 and picture 5;Picture 3, picture 4 and picture 5 are removed in the active volume of caching, is remained
Remaining active volume also allow cache 4 pictures, then can determine preset range for viewing area it is outside upper,
Under each two pictures scope, i.e. picture 1, picture 2, picture 6 and picture 7;In display picture 3, figure
During piece 4 and picture 5, picture 1, picture 2, picture 6 and picture 7 are preloaded, and be put into caching
In;User slides page process, if picture 3 removes viewing area, picture 6 enters viewing area, then
Picture 6 is directly obtained from caching and is shown, during display picture 4, picture 5 and picture 6,
Due to picture 7 in the buffer, picture 8 can be preloaded and is cached, by that analogy;If user is again
It is secondary to slide the page to the position of picture 3, picture 4 and the place of picture 5, figure can be obtained from caching again
Piece 3, picture 4 and picture 5 simultaneously show.
It will be appreciated by those skilled in the art that thought of the invention, presumptive area can also be viewing area
The scope of 4 pictures below domain, can also be the scope+viewing area of 1 pictures of viewing area top
The scope of the pictures of lower section 3.
Present invention also offers a kind of picture loading device.Fig. 3 is that picture according to an embodiment of the invention adds
Carry the structure chart put.
The device includes:
Load-on module 310, for show current display area in picture when, the pre-loaded display
Picture outside region.
Cache module 320, for caching the pre-loaded picture.
In one embodiment, described device also includes removing module (not shown);The removing module,
For when the caching with capacity when being more than default threshold value, distance being removed in the caching current aobvious
Show the farthest picture in region.
In another embodiment, load-on module 320, for pre-loaded pre- outside the viewing area
Picture within the scope of fixed.Load-on module 320 specifically for:The preset range is located at the viewing area
Both sides;Or, the preset range is located at the viewing area side.
In another embodiment, the load-on module 320 is additionally operable in the display current display area
Before picture, judge that the picture in the current display area whether there is in the caching;It is being judged to
In the case of being, then the picture is obtained from the caching and is shown;Be judged to it is no in the case of, then
The picture is loaded from network side and shown, and cache the picture of loading.
The function of the device described in the present embodiment is carried out in the embodiment of the method shown in Fig. 1, Fig. 2
Description, therefore not detailed part in the description of the present embodiment, may refer to the related description in previous embodiment,
Will not be described here.
Although being example purpose, the preferred embodiments of the present invention are had been disclosed for, those skilled in the art will
Recognize that various improvement, increase and substitution are also possible, therefore, the scope of the present invention should be not limited to
State embodiment.
Claims (10)
1. a kind of picture loading method, it is characterised in that including:
When the picture in current display area is shown, the picture outside the pre-loaded viewing area;
The pre-loaded picture of caching.
2. the method for claim 1, it is characterised in that also include:
When the caching with capacity when being more than default threshold value, distance is removed in the caching current aobvious
Show the farthest picture in region.
3. the method for claim 1, it is characterised in that the pre-loaded viewing area
Outside picture, including:
The pre-loaded picture outside the viewing area within preset range.
4. method as claimed in claim 3, it is characterised in that
The preset range is located at the viewing area both sides;Or,
The preset range is located at the viewing area side.
5. the method as any one of claim 1-4, it is characterised in that current in the display
Before picture in viewing area, also include:
Judge that the picture in the current display area whether there is in the caching;
If so, then obtaining the picture from the caching and showing;
If it is not, then loading the picture from network side and showing, and cache the picture of loading.
6. a kind of picture loading device, it is characterised in that including:
Load-on module, for show current display area in picture when, the pre-loaded viewing area
Outside picture;
Cache module, for caching the pre-loaded picture.
7. device as claimed in claim 6, it is characterised in that described device also includes removing module;
The removing module, for when the caching with capacity when being more than default threshold value, described slow
Deposit the middle removing picture farthest apart from current display area.
8. device as claimed in claim 6, it is characterised in that the load-on module is used for:
The pre-loaded picture outside the viewing area within preset range.
9. device as claimed in claim 8, it is characterised in that
The preset range is located at the viewing area both sides;Or,
The preset range is located at the viewing area side.
10. the device as any one of claim 6-9, it is characterised in that the load-on module is also
For:
Before picture in the display current display area, the picture in the current display area is judged
With the presence or absence of in the caching;
In the case where being judged to be, then the picture is obtained from the caching and is shown;
Be judged to it is no in the case of, then load the picture from network side and show, and cache loading
The picture.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201511029954.6A CN106933884A (en) | 2015-12-30 | 2015-12-30 | A kind of picture loading method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201511029954.6A CN106933884A (en) | 2015-12-30 | 2015-12-30 | A kind of picture loading method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106933884A true CN106933884A (en) | 2017-07-07 |
Family
ID=59443914
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201511029954.6A Pending CN106933884A (en) | 2015-12-30 | 2015-12-30 | A kind of picture loading method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106933884A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109388726A (en) * | 2017-08-11 | 2019-02-26 | 车伯乐(北京)信息科技有限公司 | A kind of image display method, device, equipment and computer-readable medium |
CN109634491A (en) * | 2018-12-14 | 2019-04-16 | 珠海市小源科技有限公司 | A kind of bi-directional segmented method, computer installation and computer readable storage medium for loading data and showing |
CN110209432A (en) * | 2018-02-28 | 2019-09-06 | 优酷网络技术(北京)有限公司 | View loading method and device |
CN110868624A (en) * | 2019-11-08 | 2020-03-06 | 青岛海信传媒网络技术有限公司 | Picture loading method and smart television |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101794567A (en) * | 2010-02-10 | 2010-08-04 | 中兴通讯股份有限公司 | Method and terminal for loading pictures |
CN102866898A (en) * | 2012-07-20 | 2013-01-09 | 厦门亿联网络技术股份有限公司 | Method for quickly displaying interface on embedded device |
CN103412827A (en) * | 2013-08-05 | 2013-11-27 | 广州唯品会信息科技有限公司 | Picture caching method and picture caching system |
CN104951317A (en) * | 2014-03-26 | 2015-09-30 | 北京奇虎科技有限公司 | Image loading device and method |
-
2015
- 2015-12-30 CN CN201511029954.6A patent/CN106933884A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101794567A (en) * | 2010-02-10 | 2010-08-04 | 中兴通讯股份有限公司 | Method and terminal for loading pictures |
CN102866898A (en) * | 2012-07-20 | 2013-01-09 | 厦门亿联网络技术股份有限公司 | Method for quickly displaying interface on embedded device |
CN103412827A (en) * | 2013-08-05 | 2013-11-27 | 广州唯品会信息科技有限公司 | Picture caching method and picture caching system |
CN104951317A (en) * | 2014-03-26 | 2015-09-30 | 北京奇虎科技有限公司 | Image loading device and method |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109388726A (en) * | 2017-08-11 | 2019-02-26 | 车伯乐(北京)信息科技有限公司 | A kind of image display method, device, equipment and computer-readable medium |
CN110209432A (en) * | 2018-02-28 | 2019-09-06 | 优酷网络技术(北京)有限公司 | View loading method and device |
CN109634491A (en) * | 2018-12-14 | 2019-04-16 | 珠海市小源科技有限公司 | A kind of bi-directional segmented method, computer installation and computer readable storage medium for loading data and showing |
CN110868624A (en) * | 2019-11-08 | 2020-03-06 | 青岛海信传媒网络技术有限公司 | Picture loading method and smart television |
CN110868624B (en) * | 2019-11-08 | 2023-08-22 | Vidaa(荷兰)国际控股有限公司 | Picture loading method and intelligent television |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106933884A (en) | A kind of picture loading method and device | |
CN107111553B (en) | System and method for providing dynamic caching extension in more cluster heterogeneous processor frameworks | |
CN103544207B (en) | A kind of method and system of picture loaded and displayed | |
US20130024869A1 (en) | Picture loading method and terminal | |
CN106791898B (en) | Live video loading method and device | |
AU2021202560B2 (en) | Application startup control method and control device | |
CN106066805A (en) | Method, device and the terminal that a kind of end application starts | |
EP3304317B1 (en) | Method and apparatus for managing memory | |
CN109684090A (en) | A kind of resource allocation methods and device | |
CN105046640A (en) | Picture memory managing method and apparatus | |
US20150326933A1 (en) | Video reproduction apparatus, control method thereof, and computer-readable storage medium storing program | |
CN106062662A (en) | System and method for providing power-saving static image display refresh in a DRAM memory system | |
CN106095461A (en) | The method and device of display module in interface | |
CN105677483B (en) | Data caching method and device | |
US9754391B2 (en) | Webpage display method and apparatus | |
CN104035921A (en) | Information processing method and electronic devices | |
CN108549575B (en) | Processing method and device for quitting split screen, storage medium and electronic equipment | |
CN108681469B (en) | Page caching method, device, equipment and storage medium based on Android system | |
CN105808324A (en) | Method for improving fluency of system and mobile terminal | |
CN105094858B (en) | A kind of loading method and device of list control | |
CN105095259A (en) | Waterfall flow object display method and device | |
CN109189579A (en) | A kind of method, apparatus and system optimizing game running environment | |
CN106933702A (en) | A kind of method of intelligent terminal storage space management, device and intelligent terminal | |
US9990427B2 (en) | Information processing apparatus and recording medium | |
EP2983105B1 (en) | Electronic device, on-chip memory and method of operating the on-chip memory |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170707 |
|
RJ01 | Rejection of invention patent application after publication |