An image display method, device, equipment and storage medium
By generating image aggregation files through preset sorting and a doubly linked list structure, the problem of disordered image browsing in DICOM reading software is solved, enabling orderly playback and management of grouped images and improving browsing efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-24
- Publication Date
- 2026-04-10
AI Technical Summary
Existing DICOM reading software struggles to achieve orderly browsing and management of images. This results in a time-consuming and resource-intensive process of loading, parsing, and sorting all images each time the software is opened, making it impossible to achieve orderly playback of grouped images. The browsing method is also limited and there is no way to return to the previous image.
Image data is grouped and sorted using a preset sorting method. A target aggregated image file is generated using a doubly linked list structure. During parsing, the parsed image data is obtained based on the sorting relationship of the image data and displayed sequentially on the page.
It enables grouped and orderly playback of images, saving sorting time, increasing the diversity of browsing methods, and supporting grouped management and orderly display of images.
Smart Images

Figure CN115910291B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of image processing, in particular to an image display method, device, equipment and storage medium. BACKGROUND
[0002] The current DICOM (Digital Imaging and Communications in Medicine) reading software has the following problems: 1. Some DICOM reader software supports "previous" or "next" loading of image DICOM files in an image directory, but since the image DICOM files are usually stored in the form of DICOMDIR directory, it is difficult to browse the images of a check sequence in order. 2. Since a check may generate hundreds of image DICOMs, DICOMDIR will generate hundreds of files, which is not conducive to file management. Some archives will compress all DICOMs of a check into a zip, but the image files in the compressed file cannot guarantee the order of the images. 3. Some DICOM reading software can play the images of a check (or sequence) in order, but each time the software is opened to browse the check, all DICOM images need to be loaded and parsed to sort them according to the image code before playing and browsing. However, the sorted image DICOM cannot be reused when the software is opened next time. In this way, it takes time and resources to load and parse all images to sort them every time the same check image is read in the reading software. 4. Usually, after playing and pausing, the DICOM reading software cannot "rewind" (or "previous"). Therefore, if a certain image is observed during browsing, it is not possible to return to the previous image due to the fast playing speed. The usual reason is also the disordered nature of the image files. 5. The current DICOM reading software has a single browsing mode: only two browsing modes of single image or multiple image playing are provided, and other image sequential browsing modes are not supported. SUMMARY
[0003] Therefore, the purpose of the present application is to provide an image display method, device, equipment and storage medium, which can realize the sequential playing of grouped images and save sorting time. The specific scheme is as follows:
[0004] In a first aspect, the present application discloses an image display method, comprising:
[0005] obtaining all to-be-displayed image data, and sorting all the to-be-displayed image data according to a preset sorting method to obtain sorted image data;
[0006] processing the sorted image data by using a preset image data processing method to obtain a target aggregated image file;
[0007] analyzing the target aggregated image file by using a preset analysis method to obtain analyzed image data based on a sorting relationship between the target aggregated image file and the sorted image data;
[0008] displaying corresponding images based on the sorting relationship of the analyzed image data.
[0009] Optionally, the method further includes:
[0010] obtaining all the image data to be displayed, and dividing all the image data to be displayed based on serial numbers of the image data to be displayed to obtain corresponding serial groups;
[0011] sorting the image data to be displayed in each serial group based on image codes of the image data to be displayed in each serial group to obtain the sorted image data of each sorted serial group.
[0012] Optionally, the method further includes:
[0013] aggregating the sorted serial groups by using a double-linked list structure to obtain the target aggregated image file.
[0014] Optionally, the method further includes:
[0015] storing the target aggregated image file in a designated aggregation directory to obtain the target aggregated image file from the aggregation directory and analyze the target aggregated image file.
[0016] Optionally, the method further includes:
[0017] traversing a linked list in the target aggregated image file by using an aggregated image reader.
[0018] Optionally, the method further includes:
[0019] reading the target aggregated image file to obtain a current total number of serials and a byte start position array of serials;
[0020] acquire a target element currently traversed in a byte start position array of the sequence, jump to a target byte start position of a target sequence corresponding to the target element to obtain a total number of image data of the target sequence and a byte start position of target image data of the target sequence;
[0021] jump to the byte start position of the target image data so as to parse the target image data to obtain corresponding parsed target image data;
[0022] determine a byte start position of next image data based on a size of the target image data and the byte start position of the target image data;
[0023] determine the byte start position of the next image data as the byte start position of the target image data, and re-enter the step of jumping to the byte start position of the target image data so as to parse the target image data to obtain corresponding parsed target image data.
[0024] Optionally, the displaying corresponding images based on the sorting relationship of the parsed image data comprises:
[0025] acquiring metadata and image data of the parsed image data, and sequentially displaying corresponding metadata and image data on a target page based on a preset image display mode and the sorting relationship.
[0026] In a second aspect, the present application discloses an image display device, comprising:
[0027] a sorting module configured to acquire all image data to be displayed, and sort all the image data to be displayed according to a preset sorting method to obtain sorted image data;
[0028] a file acquisition module configured to process the sorted image data by using a preset image data processing method to obtain a target aggregated image file;
[0029] a file parsing module configured to parse the target aggregated image file by using a preset parsing method so as to acquire parsed image data based on a sorting relationship between the target aggregated image file and the sorted image data;
[0030] an image display module configured to display corresponding images based on the sorting relationship of the parsed image data.
[0031] In a third aspect, the present application discloses an electronic device, comprising:
[0032] a memory configured to save a computer program;
[0033] A processor is configured to execute the computer program to implement the steps of the image display method disclosed above.
[0034] Fourthly, this application discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the image display method disclosed above.
[0035] As can be seen, this application provides an image display method, including: acquiring all image data to be displayed, and sorting all the image data to be displayed according to a preset sorting method to obtain sorted image data; processing the sorted image data using a preset image data processing method to obtain a target aggregated image file; parsing the target aggregated image file using a preset parsing method to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data; and displaying the corresponding image based on the sorting relationship of the parsed image data. Therefore, this application achieves orderly grouping and playback of images and saves sorting time by sorting the image data, obtaining the target aggregated image file based on the sorted image data, and displaying the corresponding image according to the sorting relationship of the image data obtained when parsing the target aggregated image file. Attached Figure Description
[0036] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0037] Figure 1 This is a flowchart of an image display method disclosed in this application;
[0038] Figure 2 This is a schematic diagram of the target aggregated image file generation process disclosed in this application;
[0039] Figure 3 This is a data structure diagram of the aggregated DICOM disclosed in this application;
[0040] Figure 4 This is a flowchart of a specific image display method disclosed in this application;
[0041] Figure 5 A schematic diagram of the image display device provided in this application;
[0042] Figure 6 This application provides a structural diagram of an electronic device. Detailed Implementation
[0043] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art without creative effort belong to the scope of protection of the present application.
[0044] At present, since the image DICOM file is usually stored in the form of DICOMDIR directory, it is difficult to sequentially browse the images of a check sequence; DICOMDIR will generate hundreds of files, which is not conducive to file management, and also cannot guarantee the order of the images. Each time the same check image is read by opening the reading software, all the images are loaded and parsed for sorting, which consumes time and resources. When a certain image is observed, due to the disorder of the image file, the previous image cannot be returned. The current DICOM reading software has a single browsing mode: only two browsing modes of single image or multiple image playing are provided, and other image sequential browsing modes are not supported. Therefore, the present application provides an image display method, which can realize the sequential playing of grouped images and save sorting time.
[0045] The embodiment of the present application discloses an image display method, referring to Figure 1 The method comprises the following steps:
[0046] Step S11: acquiring all the to-be-displayed image data, and sorting all the to-be-displayed image data according to a preset sorting method to obtain sorted image data.
[0047] In the embodiment, all the to-be-displayed image data is acquired, and all the to-be-displayed image data is sorted according to a preset sorting method to obtain sorted image data. It can be understood that all the original image DICOM data (i.e. to-be-displayed image data) of the current check is acquired, and then all the original image DICOM data is grouped and sorted by the preset sorting method to obtain a plurality of sorted groups, i.e. to obtain the sorted image data in the above check. Specifically, all the to-be-displayed image data is acquired, and all the to-be-displayed image data is divided based on the sequence number of the to-be-displayed image data to obtain a corresponding sequence group. The to-be-displayed image data in each sequence group is sorted according to the image code to obtain the sorted image data of each sorted sequence group. For example, Figure 2As shown, the DICOM data of the images of one examination is first grouped according to the sequence number Tag (for example, Tag (0020, 0011)) to obtain sequence 1, sequence 2, and sequence 3, and then the image data to be displayed in each sequence is sorted according to the image code Tag (for example, Tag (0020, 0013)), for example, in ascending order, and the obtained sequences are aggregated using a double-linked list structure to form a new aggregated image data format.
[0048] Step S12: processing the sorted image data using a preset image data processing method to obtain a target aggregated image file.
[0049] In this embodiment, after obtaining all the image data to be displayed and sorting all the image data to be displayed according to a preset sorting method to obtain sorted image data, the sorted image data is processed using a preset image data processing method to obtain a target aggregated image file. It can be understood that the sorted sequences are aggregated using a double-linked list structure to obtain the target aggregated image file. After obtaining the target aggregated image file, the target aggregated image file is stored in a designated aggregation directory, so that the corresponding target aggregated image file can be obtained from the aggregation directory and parsed. As described above Figure 2 As shown, after sorting the image data to be displayed in each sequence, the image sequence array is sorted according to the sequence number Tag (0020, 0011) value, and then the DICOM related data corresponding to the above sequences is written according to the sorting structure and the aggregated file format to obtain a target aggregated image file.
[0050] Specifically, in the designated aggregation directory, the DICOM aggregated file of the examination image with a unique identifier (for example, Tag (0020, 000D)) is checked by a retrieval operation. If the above image DICOM aggregated file does not exist, all the images of the examination are grouped by sequence (for example, sequence number Tag (0020, 0011)), and then the image DICOM of each group is sorted in ascending order according to the image code (for example, Tag (0020, 0013)), and finally the data structure of the aggregated DICOM as shown in the data structure diagram is used to write the corresponding data into the DICOM aggregated file, the aggregated file name is named using the unique identifier of the examination (for example, Tag (0020, 000D)), and the obtained target aggregated image file is saved in the designated aggregation directory. Figure 3 As shown, the DICOM aggregated file of the examination image with a unique identifier (for example, Tag (0020, 000D)) is checked by a retrieval operation. If the above image DICOM aggregated file does not exist, all the images of the examination are grouped by sequence (for example, sequence number Tag (0020, 0011)), and then the image DICOM of each group is sorted in ascending order according to the image code (for example, Tag (0020, 0013)), and finally the data structure of the aggregated DICOM as shown in the data structure diagram is used to write the corresponding data into the DICOM aggregated file, the aggregated file name is named using the unique identifier of the examination (for example, Tag (0020, 000D)), and the obtained target aggregated image file is saved in the designated aggregation directory.
[0051] Step S13: parsing the target aggregated image file through a preset parsing method to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data.
[0052] In the embodiment, after the sorted image data is processed by the preset image data processing method to obtain the target aggregated image file, the target aggregated image file is parsed by a preset parsing method, so as to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data. For example, the chain table in the target aggregated image file is traversed by an aggregated image reader. It can be understood that, since the sorted sequence image information is input when the target aggregated image file is generated, the sorting relationship between the sequences and the sorting relationship between the to-be-displayed image data in each sequence can be directly obtained when the target aggregated image file is parsed, that is, the to-be-displayed image data does not need to be sorted when parsed, and all the to-be-displayed image data can be parsed directly according to the existing sorting relationship.
[0053] Step S14: displaying corresponding images based on the sorting relationship of the parsed image data.
[0054] In the embodiment, after the target aggregated image file is parsed by a preset parsing method, parsed image data is obtained based on the sorting relationship between the target aggregated image file and the sorted image data, and corresponding images are displayed based on the sorting relationship of the parsed image data. Specifically, the metadata and image data of the parsed image data are obtained, and the metadata and image data are displayed on a target page in sequence based on a preset image display method and the sorting relationship. It can be understood that the metadata is the basic information of the parsed image data, such as image name, image size and the like, and the image data is the data directly used to generate corresponding images. The ordered display method of the image DICOM in the scheme mainly includes two parts of image DICOM aggregation data generation and DICOM aggregation data parsing. After the examination images are sequentially aggregated and stored as a new data format file, the aggregated image file reader is used to sequentially parse and browse the aggregated file, and the corresponding images are browsed in the form of slide show and carousel, so as to realize the diversification of the browsing form.
[0055] The present scheme groups all image files of an examination according to sequences and sorts them according to image codes, and then sequentially aggregates all DICOM data in a bidirectional linked list structure and writes them into a new DICOM aggregation file, and then when loading and browsing the images of the examination, the new DICOM aggregation file is read to achieve sequential loading and display, avoiding the need to reload all DICOM and sort the loaded DICOM data to achieve the effect of sequential display of images each time the images of the examination are opened and browsed. It can be understood that by aggregating and storing all image DICOMs to be examined in order in advance, avoiding the dispersion of the image DICOMs of the examination, omitting the sorting operation required each time the images of a certain examination are loaded and browsed, the effect of "one-time sorting, permanent order" of all image DICOMs of the examination is achieved, the process of loading and sorting all images each time of browsing is reduced, the sorting time is saved, and through grouping and sorting of all image DICOMs to be examined, the effect of grouped and ordered playing is achieved.
[0056] In addition, zip compressed files can be used instead of aggregation image data files to achieve aggregation and sequential reading of image files. Specifically, the first fixed entry of the zip file is a DICOM index file (indexing the data files of the DICOMs grouped by sequences), and the other entries are DICOMs. When reading, the first DICOM index file is read first to obtain the entry index of the image DICOMs grouped by sequences and sorted by image codes in the examination, and the image is loaded and browsed in order based on the entry index.
[0057] It can be seen that the present application provides an image display method, comprising: acquiring all to-be-displayed image data, and sorting all the to-be-displayed image data according to a preset sorting method to obtain sorted image data; processing the sorted image data using a preset image data processing method to obtain a target aggregation image file; parsing the target aggregation image file through a preset parsing method to obtain parsed image data based on the sorting relationship between the target aggregation image file and the sorted image data; and displaying corresponding images based on the sorting relationship of the parsed image data. It can be seen that the present application sorts image data, then obtains a target aggregation image file based on the sorted image data, and displays corresponding images according to the sorting relationship of the image data obtained by parsing the target aggregation image file, thereby achieving grouped and ordered playing of images and saving sorting time.
[0058] Referring to Figure 4 The embodiment of the present application discloses an image display method, which is further described and optimized compared with the previous embodiment.
[0059] Step S21: acquiring all to-be-displayed image data, and sorting all the to-be-displayed image data according to a preset sorting method to obtain sorted image data.
[0060] Step S22: processing the sorted image data by using a preset image data processing method to obtain a target aggregated image file.
[0061] Step S23: reading the target aggregated image file to acquire a current sequence total number and a sequence byte start position array.
[0062] In this embodiment, after the sorted image data is processed by using the preset image data processing method to obtain the target aggregated image file, the target aggregated image file is read to acquire the current sequence total number and the sequence byte start position array. It can be understood that when the DICOM aggregated data file is read, the sequence total number and the sequence byte start position array (each element in the array occupies 8 bytes, and the value is the byte start position of the sequence) are read first, and then each element (i.e., the byte start position of the sequence) in the sequence byte start position array is traversed.
[0063] Step S24: acquiring a target element currently traversed in the sequence byte start position array, jumping to a target byte start position of a target sequence corresponding to the target element to obtain an image data total number of the target sequence and a byte start position of target image data.
[0064] In this embodiment, after the target aggregated image file is read to acquire the current sequence total number and the sequence byte start position array, the target element currently traversed in the sequence byte start position array is acquired, and the target byte start position of the target sequence corresponding to the target element is jumped to to obtain the image data total number of the target sequence and the byte start position of the target image data. It can be understood that the DICOM total number of the current sequence and the byte start position of the head DICOM of the current sequence are read by jumping to the byte start position of the sequence.
[0065] Step S25: jumping to the byte start position of the target image data to parse the target image data to obtain corresponding parsed target image data.
[0066] In this embodiment, the target element jumps to the target sequence corresponding to the target byte start position to obtain the total number of image data of the target sequence and the byte start position of the target image data, and then jumps to the byte start position of the target image data to parse the target image data to obtain the corresponding parsed target image data. It can be understood that the byte start position of the head DICOM of the current sequence is jumped to, the byte start position of the next DICOM, the size of the current DICOM are read, then the head DICOM data (the byte range calculation formula is described below) is read, the DICOM data is parsed (the metadata and image data are extracted), and the DICOM data is displayed in the front-end UI interface. Then, according to the byte start position of the next DICOM, the relevant data of the next DICOM is read, and then parsed and displayed in the front end. The display mode can interact with the click trigger event of the "next" button in the front end, or can be automatically displayed as "next" such as playing, slideshow, and carousel. Until the last DICOM image is read and displayed, the "previous" can also be read.
[0067] For example, as shown in the above Figure 3 The target aggregate image file is read to obtain the total number of current sequences (4 bytes) and the byte start position array of the sequence (8*sequence total number bytes). The byte start position array of the sequence includes the start position information of each sequence in the target aggregate image file. The target element currently traversed in the byte start position array of the sequence is obtained, for example, the target element currently traversed is the byte start position of the first sequence (4+(8*sequence total number)+1 bytes). At this time, the byte start position of the first sequence is jumped to to obtain the total number of DICOM image data of the first sequence (4 bytes) and the byte start position of the target image data (that is, the byte start position of the head DICOM of the current sequence, 8 bytes). The byte start position of the target image data (that is, the first DICOM of the current sequence) is jumped to to parse the target image data to obtain the corresponding parsed target image data.
[0068] The calculation formula for specifically obtaining the relevant data is described below.
[0069] Specifically, the byte range calculation formula is as follows:
[0070] The total number of sequences: 0-3;
[0071] The byte start position array of the sequence: 4-(8*sequence total number);
[0072] The byte start position of the nth sequence: (4+(8*(n-1)))-(4+(8*n)-1);
[0073] The number of DICOMs in the nth sequence: the starting position of the bytes in the nth sequence ~ (the starting position of the bytes in the nth sequence + 7);
[0074] The starting position of the byte of the head DICOM of the nth sequence: (starting position of the byte of the nth sequence + 8) to (starting position of the byte of the nth sequence + 15);
[0075] The data size of the head DICOM of the nth sequence is: (starting byte position of the head DICOM of the nth sequence + 16) to (starting byte position of the head DICOM of the nth sequence + 23).
[0076] The data of the head DICOM of the nth sequence: (starting byte position of the head DICOM of the nth sequence + 24) ~ (starting byte position of the head DICOM of the nth sequence + 24 + data size of the head DICOM element of the nth sequence - 1);
[0077] The starting position of the byte of the previous DICOM of the current DICOM in the nth sequence: the starting position of the byte of the current DICOM in the nth sequence ~ (the starting position of the byte of the current DICOM in the nth sequence + 7);
[0078] The data size of the previous DICOM of the current DICOM in the nth sequence is: (starting position of the byte of the previous DICOM of the current DICOM in the nth sequence + 16) ~ (starting position of the byte of the previous DICOM of the current DICOM in the nth sequence + 23).
[0079] The data of the previous DICOM of the current DICOM in the nth sequence: (starting position of the byte of the previous DICOM of the current DICOM in the nth sequence + 24) ~ (starting position of the byte of the previous DICOM of the current DICOM in the nth sequence + 24 + data size of the previous DICOM of the current DICOM in the nth sequence - 1);
[0080] The starting position of the next DICOM after the current DICOM in the nth sequence: (starting position of the current DICOM in the nth sequence + 8) ~ (starting position of the current DICOM in the nth sequence + 15);
[0081] The data size of the next DICOM of the current DICOM in the nth sequence is: (starting position of the next DICOM of the current DICOM in the nth sequence + 16) to (starting position of the next DICOM of the current DICOM in the nth sequence + 23).
[0082] Data of next DICOM of current DICOM of nth sequence: (byte start position of next DICOM of current DICOM of nth sequence + 24) ~ (byte start position of next DICOM of current DICOM of nth sequence + 24 + data size of next DICOM of current DICOM of nth sequence - 1).
[0083] Step S26: determining a byte start position of next image data based on the size of the target image data and the byte start position of the target image data.
[0084] In the embodiment, after jumping to the byte start position of the target image data to parse the target image data to obtain corresponding parsed target image data, a byte start position of next image data is determined based on the size of the target image data and the byte start position of the target image data. It can be understood that if there is next image data, the byte start position of the next image data is determined as the byte start position of the target image data, and the step of jumping to the byte start position of the target image data to parse the target image data to obtain corresponding parsed target image data is re-entered, and if there is no next image data, the parsing process is ended.
[0085] Step S27: displaying corresponding images based on the sorting relationship of the parsed image data.
[0086] The specific content of the above steps S21, S22 and S27 can refer to the corresponding content disclosed in the foregoing embodiments, which will not be described here again.
[0087] It can be seen that, by the embodiments of the present application, all the image data to be displayed is acquired, and all the image data to be displayed is sorted according to a preset sorting method to obtain sorted image data; the sorted image data is processed by a preset image data processing method to obtain a target aggregated image file; the target aggregated image file is read to acquire a total number of sequences and a byte start position array of sequences; a target element currently traversed in the byte start position array of sequences is acquired, a target byte start position of a target sequence corresponding to the target element is jumped to to obtain a total number of image data of the target sequence and a byte start position of target image data; the byte start position of the target image data is jumped to to parse the target image data to obtain corresponding parsed target image data; a byte start position of next image data is determined based on the size of the target image data and the byte start position of the target image data; and corresponding images are displayed based on the sorting relationship of the parsed image data, which realizes the ordered playing of image grouping and saves sorting time.
[0088] Referring to Figure 5 The embodiment of the application also discloses an image display device, which comprises:
[0089] The sorting module 11 is configured to obtain all the image data to be displayed, and sort all the image data to be displayed according to a preset sorting method, so as to obtain sorted image data.
[0090] The file obtaining module 12 is configured to process the sorted image data by using a preset image data processing method, so as to obtain a target aggregated image file.
[0091] The file parsing module 13 is configured to parse the target aggregated image file by using a preset parsing method, so as to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data.
[0092] The image display module 14 is configured to display corresponding images based on the sorting relationship of the parsed image data.
[0093] It can be seen that the application comprises the following steps: obtaining all the image data to be displayed, and sorting all the image data to be displayed according to a preset sorting method, so as to obtain sorted image data; processing the sorted image data by using a preset image data processing method, so as to obtain a target aggregated image file; parsing the target aggregated image file by using a preset parsing method, so as to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data; and displaying corresponding images based on the sorting relationship of the parsed image data. It can be seen that the application sorts image data, then obtains a target aggregated image file based on the sorted image data, and displays corresponding images based on the sorting relationship of the image data obtained by parsing the target aggregated image file, so that the grouping and ordered playing of images are realized, and the sorting time is saved.
[0094] In some specific embodiments, the sorting module 11 specifically comprises:
[0095] The image data to be displayed obtaining unit is configured to obtain all the image data to be displayed.
[0096] The sequence group determining unit is configured to divide all the image data to be displayed based on the sequence numbers of the image data to be displayed, so as to obtain corresponding sequence groups.
[0097] The image data to be displayed sorting unit is configured to sort the image data to be displayed in each sequence group according to the image codes of the image data to be displayed in each sequence group, so as to obtain the sorted image data of each sorted sequence group.
[0098] In some specific embodiments, the file obtaining module 12 specifically comprises:
[0099] an aggregated image file obtaining unit, configured to aggregate the sorted sequence groups by a double-linked list structure to obtain the target aggregated image file;
[0100] an aggregated image file storage unit, configured to store the target aggregated image file to a designated aggregated directory, so as to obtain the corresponding target aggregated image file from the aggregated directory and parse the target aggregated image file.
[0101] In some embodiments, the file parsing module 13 specifically comprises:
[0102] a linked list traversal unit, configured to traverse a linked list in the target aggregated image file by an aggregated image reader;
[0103] a sequence byte start position array obtaining unit, configured to read the target aggregated image file to obtain a total number of sequences and a sequence byte start position array;
[0104] a target element determining unit, configured to obtain a target element currently traversed in the sequence byte start position array;
[0105] a target byte start position jumping unit, configured to jump to a target byte start position of a target sequence corresponding to the target element to obtain a total number of image data of the target sequence and a byte start position of target image data;
[0106] a first target image data byte start position jumping unit, configured to jump to the byte start position of the target image data, so as to parse the target image data to obtain corresponding parsed target image data;
[0107] a next image data byte start position determining unit, configured to determine a byte start position of next image data based on a size of the target image data and the byte start position of the target image data;
[0108] a second target image data byte start position jumping unit, configured to determine the byte start position of the next image data as the byte start position of the target image data, and re-enter the step of jumping to the byte start position of the target image data, so as to parse the target image data to obtain corresponding parsed target image data.
[0109] In some embodiments, the image display module 14 specifically comprises:
[0110] a data obtaining unit, configured to obtain metadata and image data of the parsed image data;
[0111] The display unit is configured to display the metadata and the image data corresponding to the target page in sequence based on a preset image display mode and the sorting relationship.
[0112] Further, the embodiment of the present application further provides an electronic device. Figure 6 The electronic device 20 is shown in the structure diagram according to an exemplary embodiment, and the content in the diagram cannot be considered as any limitation on the use range of the present application.
[0113] Figure 6 The electronic device 20 is shown in the structure diagram according to an exemplary embodiment, and the content in the diagram cannot be considered as any limitation on the use range of the present application. The electronic device 20 specifically can include at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25 and a communication bus 26. The memory 22 is configured to store a computer program, and the computer program is loaded and executed by the processor 21 to implement the related steps in the image display method disclosed in any of the preceding embodiments. In addition, the electronic device 20 in the embodiment can be an electronic computer.
[0114] In the embodiment, the power supply 23 is configured to provide working voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol followed by the communication interface 24 can be any communication protocol applicable to the technical solution of the present application, which is not limited here; the input / output interface 25 is configured to obtain external input data or output data to the outside, and the specific interface type can be selected according to the specific application needs, which is not limited here.
[0115] In addition, the memory 22 as a carrier for resource storage can be a read-only memory, a random access memory, a magnetic disk or an optical disk, etc., and the resources stored thereon can include an operating system 221, a computer program 222, etc., and the storage mode can be temporary storage or permanent storage.
[0116] The operating system 221 is configured to manage and control each hardware device and the computer program 222 on the electronic device 20, and can be Windows Server, Netware, Unix, Linux, etc. The computer program 222 can further include computer programs for completing other specific work in addition to the computer programs for completing the image display method executed by the electronic device 20 disclosed in any of the preceding embodiments.
[0117] Further, the embodiment of the present application further discloses a storage medium, and the storage medium stores a computer program. When the computer program is loaded and executed by a processor, the steps of the image display method disclosed in any of the preceding embodiments are implemented. Further, the embodiment of the present application further discloses a storage medium, and the storage medium stores a computer program. When the computer program is loaded and executed by a processor, the steps of the image display method disclosed in any of the preceding embodiments are implemented.
[0118] The various embodiments described in this specification are presented by way of example, and are not intended to limit the scope of the application. The various embodiments described in this specification can be combined, sub-combined, or substituted for one another, unless expressly stated otherwise. The description of the embodiments is merely illustrative of the application, and is not intended to limit the scope of the application.
[0119] Finally, it should be noted that the terms "first", "second", and the like, herein do not denote any order, quantity, combination, or importance, but are used to identify one entity from another, and do not imply any actual relationship or sequence among entities. Also, the terms "include", "contain", or any other variant thereof are intended to cover a non-exclusive inclusion, so that a process, method, article, or apparatus including a list of elements does not only include those elements, but also includes other elements not explicitly listed, or further includes elements inherent in such a process, method, article, or apparatus. Without more limitations, an element defined by the phrase "including a" does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes the element.
[0120] The above describes in detail the image display method, device, equipment and storage medium provided by the present application. The principles and implementation manners of the present application are described by applying specific examples. The above description of the embodiments is only used to help understand the method of the present application and its core idea. Meanwhile, for those skilled in the art, the specific implementation manners and application scope can be changed according to the idea of the present application. In summary, the content of the specification should not be understood as limiting the present application.
Claims
1. An image display method, characterized in that, include: All image data to be displayed is acquired, and all image data to be displayed is sorted according to a preset sorting method to obtain sorted image data; The sorted image data is processed using a preset image data processing method to obtain a target aggregated image file; The target aggregated image file is parsed using a preset parsing method so as to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data. Display the corresponding images based on the sorting relationship of the parsed image data; The step of parsing the target aggregated image file using a preset parsing method includes: The linked list in the target aggregated image file is traversed using an aggregated image reader; The step of parsing the target aggregated image file using a preset parsing method to obtain parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data includes: Read the target aggregated image file to obtain the current total number of sequences and the array of byte start positions of the sequences; Obtain the target element currently being traversed in the byte start position array of the sequence, and jump to the target byte start position of the target sequence corresponding to the target element, so as to obtain the total number of image data of the target sequence and the byte start position of the target image data; Jump to the beginning of the bytes of the target image data in order to parse the target image data and obtain the corresponding parsed target image data; The starting position of the bytes of the next image data is determined based on the size of the target image data and the starting position of the bytes of the target image data. The step of determining the byte start position of the next image data as the byte start position of the target image data, and re-entering the step of jumping to the byte start position of the target image data in order to parse the target image data and obtain the corresponding parsed target image data.
2. The image display method according to claim 1, characterized in that, The step of acquiring all image data to be displayed and sorting all the image data to be displayed according to a preset sorting method to obtain sorted image data includes: Acquire all image data to be displayed, and divide all image data to be displayed into corresponding sequence groups based on the sequence number of the image data to be displayed; The image data to be displayed in each sequence group is sorted according to the image code to obtain the sorted image data of each sorted sequence group.
3. The image display method according to claim 2, characterized in that, The step of processing the sorted image data using a preset image data processing method to obtain a target aggregated image file includes: The sorted sequence groups are aggregated using a doubly linked list structure to obtain the target aggregated image file.
4. The image display method according to claim 1, characterized in that, After processing the sorted image data using a preset image data processing method to obtain the target aggregated image file, the method further includes: The target aggregated image file is stored in a designated aggregated directory so that the corresponding target aggregated image file can be retrieved from the aggregated directory and parsed.
5. The image display method according to any one of claims 1 to 4, characterized in that, The display of the corresponding images based on the sorting relationship of the parsed image data includes: Obtain the metadata and image data of the parsed image data, and display the corresponding metadata and image data sequentially on the target page based on the preset image display method and the sorting relationship.
6. An image display device, characterized in that, include: The sorting module is used to acquire all image data to be displayed and sort all the image data to be displayed according to a preset sorting method to obtain sorted image data. The file acquisition module is used to process the sorted image data using a preset image data processing method to obtain the target aggregated image file; The file parsing module is used to parse the target aggregated image file using a preset parsing method, so as to obtain the parsed image data based on the sorting relationship between the target aggregated image file and the sorted image data. The image display module is used to display the corresponding image based on the sorting relationship of the parsed image data; The file parsing module includes: A linked list traversal unit is used to traverse the linked list in the target aggregated image file using an aggregated image reader. The sequence byte start position array acquisition unit is used to read the target aggregated image file to obtain the current total number of sequences and the sequence byte start position array; The target element determination unit is used to obtain the target element currently being traversed in the byte start position array of the sequence; The target byte start position jump unit is used to jump to the target byte start position of the target sequence corresponding to the target element, so as to obtain the total number of image data of the target sequence and the byte start position of the target image data; The first target image data byte start position jump unit is used to jump to the byte start position of the target image data in order to parse the target image data and obtain the corresponding parsed target image data; The next image data byte start position determination unit is used to determine the byte start position of the next image data based on the size of the target image data and the byte start position of the target image data. The second target image data byte start position jump unit is used to determine the byte start position of the next image data as the byte start position of the target image data, and re-enter the step of jumping to the byte start position of the target image data in order to parse the target image data and obtain the corresponding parsed target image data.
7. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the steps of the image display method as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, Used to store a computer program; wherein, when the computer program is executed by a processor, it implements the image display method as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Audio transmission method, audio playing method, storage medium and related equipment
CN114338622A
Random access at resync points of dash segments
US20210105542A1