Resolution adaptation method and device for VGA image, video converter, system, medium and program product
By measuring and optimizing the weighting coefficients of VGA video signals, the problem of inaccurate resolution adaptation of VGA video data was solved, achieving high-accuracy resolution adaptation on digital displays.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SIEMENS SHENZHEN MAGNETIC RESONANCE
- Filing Date
- 2025-01-10
- Publication Date
- 2026-07-10
AI Technical Summary
Existing technologies make it difficult to accurately determine the appropriate resolution for VGA video data, resulting in mismatch issues when displaying VGA video data on digital monitors.
By measuring the VGA video signal, at least two measurement parameter values are obtained. These parameters are used to determine the search keywords and error range of the digital resolution information table. Then, the closest resolution information is found from the table, and the results are optimized by weighting coefficients during multiple measurements.
It improves the accuracy of VGA video data resolution adaptation, reduces the probability of retrieval failure, and ensures the accuracy of display on digital monitors.
Smart Images

Figure CN122372698A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of video transmission, and in particular to a method, apparatus, video converter, video conversion system, computer-readable storage medium, and program product for VGA image resolution adaptation. Background Technology
[0002] Video Graphics Array (VGA) is a video transmission standard that uses analog signals. Common VGA interface devices include: computer graphics cards, VGA matrices, VGA distributors, VGA switchers, VGA monitors, and VGA capture cards. To display VGA video data on digital displays such as Digital Video Interface (DVI) or High Definition Multimedia Interface (HDML) monitors, it is necessary to first obtain the appropriate resolution for the VGA video data.
[0003] Therefore, accurately determining the appropriate resolution for VGA video data is an urgent problem to be solved. Summary of the Invention
[0004] In view of this, this application proposes a resolution adaptation method for VGA images, and a resolution adaptation device, video converter, video conversion system, computer-readable storage medium, and program product for VGA images, in order to improve the accuracy of determining the adaptation resolution of VGA video data.
[0005] This application proposes a resolution adaptation method for VGA images, comprising: measuring the VGA video signal of a current video output device to obtain at least two measurement parameter values related to the resolution of the VGA video signal; determining, based on the at least two measurement parameter values, keywords for searching a digital resolution information table and an error range for verifying whether the retrieved resolution information meets set requirements, wherein the digital resolution information table stores various digital resolution information supported by the current digital display; and determining the closest resolution information from the digital resolution information table using the keywords and the error range.
[0006] In one embodiment, the method further includes: pre-setting an error range for some or all of the at least two measurement parameter values; determining the closest resolution information from the digital resolution information table using the keyword and the error range includes: searching the digital resolution information table using the keyword to obtain at least one candidate record; wherein each record corresponds to one resolution information; for each candidate record, determining the record value corresponding to the measurement parameter value with the set error range directly or indirectly included in the candidate record based on the measurement parameter value with the set error range, and determining whether the record value is within the corresponding error range; if so, determining the candidate record as a valid record; when there is one valid record, taking the resolution information corresponding to the valid record as the closest resolution information of the VGA video signal.
[0007] In one embodiment, when there are at least two valid records, the method further includes: pre-setting weighting coefficients for some or all of the at least two measurement parameter values; performing multiple measurements on the VGA video signal of the current video output device to obtain multiple sets of measurement parameter values; wherein each measurement yields a set of at least two measurement parameter values related to the resolution of the VGA video signal; for each valid record, determining, based on the measurement parameter values with set weighting coefficients, the record value directly or indirectly included in the valid record corresponding to the measurement parameter values with set weighting coefficients, and calculating the difference between the record value and the corresponding measurement parameter value in each set of measurement parameter values; calculating the weighted sum of the differences corresponding to the multiple measurements; taking the valid record with the smallest weighted sum as the final record, and taking the resolution information corresponding to the final record as the resolution information closest to the VGA video signal.
[0008] In one embodiment, the at least two measurement parameter values include: the line frequency Hfreq, field frequency Vfreq, and field synchronization Vsync of the VGA video signal; determining the keyword for searching a digital resolution information table based on the plurality of measurement parameter values, and the error range for verifying whether the retrieved resolution information meets the set requirements, includes: calculating the number of rows V-total of each frame image based on the line frequency Hfreq and the field frequency Vfreq, and using the number of rows V-total of each frame image as the keyword for searching the digital resolution information table; and pre-setting the error range of any one of the line frequency Hfreq and the field frequency Vfreq and the field synchronization Vsync.
[0009] In one implementation, the digital resolution information table includes: pixel clock, number of pixels per row H-Total, field synchronization Vsync, and number of rows per frame V-Total; determining the record value corresponding to the measurement parameter value with set error range directly or indirectly included in the candidate record based on the measurement parameter value with set error range includes: when the measurement parameter value with set error range includes line frequency Hfreq, calculating the record value of line frequency Hfreq indirectly included in the candidate record = pixel clock / number of pixels per row H-Total based on the pixel clock and number of pixels per row H-Total in the candidate record; when the measurement parameter value with set error range includes field frequency Vfreq, calculating the record value of field frequency Vfreq indirectly included in the candidate record = pixel clock / number of rows per frame H-Total based on the pixel clock, number of rows per frame V-Total, and number of pixels per row H-Total in the candidate record. clock / (number of pixels per line H-Total × number of lines per frame V-Total); when the measurement parameter value with the error range is included in the field synchronization Vsync, determine the field synchronization record value directly included in the candidate record.
[0010] In one implementation, determining the record value corresponding to the measurement parameter value with weighted coefficients that is directly or indirectly included in the valid record based on the measurement parameter value with weighted coefficients includes: when the measurement parameter value with weighted coefficients includes line frequency Hfreq, calculating the record value of line frequency Hfreq indirectly included in the valid record as Pixel clock / H-Total of the number of pixels per line, based on the pixel clock and the number of pixels per line H-Total in the valid record; when the measurement parameter value with weighted coefficients includes field frequency Vfreq, calculating the record value of field frequency Vfreq indirectly included in the valid record as Pixel clock / (H-Total of the number of pixels per line × V-Total of the number of lines per frame), based on the pixel clock, the number of lines per frame V-Total and the number of pixels per line H-Total in the valid record; when the measurement parameter value with weighted coefficients includes field synchronization Vsync, determining the record value of field synchronization directly included in the valid record.
[0011] In one embodiment, the error range of the line frequency Hfreq is ±(1,000,000 / number of pixels per line); the error range of the field frequency Vfreq is ±(1,000,000 / (number of pixels per line × number of lines per frame)); and the error range of the field synchronization Vsync is ±2.
[0012] This application proposes a VGA image resolution adaptation device, comprising: a parameter measurement module for measuring the VGA video signal of a current video output device to obtain at least two measurement parameter values related to the resolution of the VGA video signal; a key value determination module for determining, based on the at least two measurement parameter values, keywords for searching a digital resolution information table and an error range for verifying whether the retrieved resolution information meets set requirements, the digital resolution information table storing various digital resolution information supported by the current digital display; and a resolution information determination module for determining the closest resolution information from the digital resolution information table using the keywords and the error range.
[0013] Another VGA image resolution adaptation device proposed in this application includes: at least one memory and at least one processor, wherein: the at least one memory is used to store a computer program; the at least one processor is used to call the computer program stored in the at least one memory to execute the above-described VGA image resolution adaptation method.
[0014] A video converter proposed in this application includes: at least one input interface, wherein one input interface is used to connect to a VGA video output device; at least one output interface, wherein one output interface is used to connect to a digital display; and the resolution adaptation device for the aforementioned VGA image.
[0015] The video converter proposed in this application includes: a VGA video output device, a digital display, and the video converter described above.
[0016] In one embodiment, the VGA video output device includes a medical imaging system.
[0017] The computer-readable storage medium proposed in this application embodiment stores a computer program thereon; the computer program can be executed by a processor to implement the resolution adaptation method for VGA images as described in any of the above embodiments.
[0018] The computer program product proposed in this application includes a computer program; the computer program can be executed by a processor to implement the resolution adaptation method for VGA images as described in any of the above embodiments.
[0019] As can be seen from the above scheme, in this embodiment of the application, by measuring the VGA video signal and obtaining at least two measurement parameter values related to the resolution of the VGA video signal, and then based on the at least two measurement parameter values, determining the keywords for searching a digital resolution information table and the error range for verifying whether the retrieved resolution information meets the set requirements, the closest resolution information can be determined from the digital resolution information table using the keywords and the error range, thereby improving the accuracy of determining the appropriate resolution of VGA video data.
[0020] When there are at least two valid records, a weighted sum is calculated between the difference between the corresponding record value in each valid record and the corresponding measurement parameter value in each group of measurement parameter values. The resolution information corresponding to the valid record with the smallest weighted sum is taken as the resolution information closest to the VGA video signal. This can further improve the accuracy of determining the appropriate resolution of VGA video data while ensuring that the probability of retrieval failure is reduced. Attached Figure Description
[0021] Preferred embodiments of the present invention will now be described in detail with reference to the accompanying drawings, which will make the above and other features and advantages of the present invention more apparent to those skilled in the art. In the drawings:
[0022] Figure 1 This is an exemplary flowchart of a resolution adaptation method for VGA images in an embodiment of this application.
[0023] Figure 2 This is an exemplary structural diagram of the resolution adaptation device for VGA images in the embodiments of this application.
[0024] Figure 3 This is an exemplary structural diagram of a resolution adaptation device for VGA images in another embodiment of this application.
[0025] Figure 4 This is an exemplary structural diagram of the video converter in the embodiments of this application.
[0026] Figure 5 This is an exemplary structural diagram of the video conversion system of the medical imaging system in the embodiments of this application.
[0027] The accompanying figure is labeled as follows:
[0028]
[0029] Detailed Implementation
[0030] In this application, in order to determine the appropriate resolution for VGA video data, a video converter can be set up, such as a video converter used in conjunction with a medical imaging system. The video converter samples the VGA video signal from the video output device to measure the measurement parameter value related to the resolution of the VGA video signal, and searches a digital resolution information table based on the measurement parameter value to obtain the resolution information closest to the resolution of the VGA video signal.
[0031] To provide a clearer understanding of the objectives, technical solutions, and effects of this invention, specific embodiments of the invention are now described with reference to the accompanying drawings. In the drawings, the same reference numerals indicate components with the same or similar structures but the same function.
[0032] In this document, “exemplary” and “illustrative” mean “serving as an example, illustration or description”, and any illustration or implementation described herein as “exemplary” or “illustrative” should not be construed as a more preferred or more advantageous technical solution.
[0033] To keep the drawings simple, each drawing only schematically shows the parts related to the present invention, and they do not represent the actual structure of the product.
[0034] In this text, "a" can mean not only "only one" but also "more than one". In this text, "first", "second", etc., are used only to distinguish them from each other, not to indicate their degree of importance or order. "Including" means "including but not limited to", and "according to..." means "at least according to..., but not limited to only according to...".
[0035] Figure 1 This is an exemplary flowchart of a VGA image resolution adaptation method in an embodiment of this application. Figure 1 As shown, the method may include:
[0036] Step S11: Sample the VGA video signal of the current video output device to measure multiple measurement parameter values related to the resolution of the VGA video signal, such as at least two measurement parameter values.
[0037] In one example, the multiple measurement parameter values may include the horizontal frequency (Hfreq, number of lines per second), vertical frequency (Vfreq, refresh rate per second in the vertical direction), and vertical sync (Vsync) of the VGA video signal. Of course, in other examples, the multiple measurement parameter values may not be limited to the three measurements: horizontal frequency (Hfreq), vertical frequency (Vfreq), and vertical sync (Vsync). For example, in other examples, it may include: horizontal frequency (Hfreq), vertical frequency (Vfreq), and horizontal sync (Hsync), or it may include: horizontal frequency (Hfreq), vertical frequency (Vfreq), vertical sync (Vsync), and horizontal sync (Hsync).
[0038] Step S12: Based on the multiple measurement parameter values, determine the keywords used to retrieve a digital resolution information table and the error range used to verify whether the retrieved resolution information meets the set requirements. The digital resolution information table stores various digital resolution information supported by the current digital display. It is easy to understand that the digital resolution information table can be a pre-stored or retrieved information table; in other words, the formation process of the digital resolution information table is not the focus of this application's improvement and therefore will not be described in detail.
[0039] Table 1 below shows a table of digital resolution information for an application.
[0040]
[0041] Table 1
[0042] In Table 1 above, each record includes the following items: Pixel clock (number of pixels collected per second), line display leading edge Hf.por, line synchronization Hsync, line display trailing edge Hb.por, number of pixels per line H-Total, line synchronization polarity Hsync pol, number of vertical pixels Vert.Hight, field display leading edge Vf.por, field synchronization Vsync, field display trailing edge Vb.por, number of lines per frame V-Total, field synchronization polarity Vsync pol, and timing name Name.
[0043] For the example of the aforementioned multiple measurement parameter values including the horizontal frequency (Hfreq), vertical frequency (Vfreq), and vertical sync (Vsync) of the VGA video signal, in order to determine the keywords used to retrieve the digital resolution information table and the error range used to verify whether the retrieved resolution information meets the set requirements, the correspondence between the multiple measurement parameter values and the relevant items of each record in the table can be predetermined. For example, in this example, it can be seen that there is a vertical sync (Vsync) item in Table 1. Secondly, the following correspondence can also be determined:
[0044] The number of lines per frame, V-Total, equals the line frequency Hfreq and the field frequency Vfreq (1).
[0045] Line frequency Hfreq = Pixel clock / Number of pixels per line H - Total (2)
[0046] Field frequency Vfreq = Pixel clock / (Number of pixels per line H - Total × Number of lines per frame V - Total) (3)
[0047] Generally, keywords are those with high precision requirements, i.e., those with no margin of error.
[0048] Based on the above correspondence, in one embodiment of this example, the number of lines V-Total per frame can be calculated according to the measured line frequency Hfreq and field frequency Vfreq using the above formula (1), and the digital resolution information table can be searched using the number of lines V-Total per frame as the keyword. For each searched record, it can be verified whether the error of other measurement parameter values is within the allowable error range. In this example, error ranges can be preset for some or all of the multiple measurement parameter values. For example, in this embodiment, error ranges can be preset for either the line frequency Hfreq and the field frequency Vfreq, as well as the field synchronization Vsync.
[0049] For example, in one instance, error ranges can be pre-set for the field synchronization Vsync and the line frequency Hfreq. For instance, the error range for field synchronization VSync can be set to ±2, and the error range for line frequency Hfreq can be set to ±(1000000 / H-Total).
[0050] For example, in another instance, error ranges can be pre-set for the vertical synchronization Vsync and the horizontal frequency Vfreq. For instance, the error range for vertical synchronization VSync can be set to ±2, and the error range for vertical synchronization Vfreq can be set to ±(1000000 / (H-Total×V-Total)).
[0051] Of course, the above error range is just an example; other values may be used in other applications.
[0052] Step S13: Use the keyword and the error range to determine the closest resolution information from the digital resolution information table.
[0053] The reason for mentioning searching for the closest resolution information is twofold. First, the measured values of horizontal frequency (Hfreq), vertical frequency (Vfreq), and vertical sync (Vsync) may contain some errors. When searching based on the measured values, the values found in the records may not be exactly the same as the measured values. Second, the resolutions supported by digital displays may not include the resolution corresponding to the VGA video data. This is also the reason for setting the error range in step S12.
[0054] In one implementation, step S13 may specifically include:
[0055] Step S131: The digital resolution information table can be searched using the keyword to obtain at least one candidate record; wherein each record corresponds to one resolution information.
[0056] Step S132: For each candidate record, based on the measurement parameter value with the set error range, determine the record value that the candidate record directly or indirectly includes corresponds to the measurement parameter value with the set error range, and determine whether the record value is within the corresponding error range. If so, determine the candidate record as a valid record.
[0057] For example, when an error range is pre-set for the field synchronization Vsync and the line frequency Hfreq, when a corresponding candidate record is found from the digital resolution information table based on the number of lines V-Total per frame, for each candidate record found, the record value HfreqR of the line frequency Hfreq indirectly included in the candidate record can be calculated based on the number of pixels H-Total and the pixel clock of each line in the candidate record according to the above formula (2). It is then determined whether the record value VsycnR of the field synchronization Vsycn directly included in the candidate record and the record value HfreqR of the line frequency Hfreq indirectly included in the candidate record are within the error range of the measured field synchronization Vsync and the line frequency Hfreq. If so, the candidate record is confirmed as a valid record.
[0058] Similarly, for cases where error ranges are pre-set for the field synchronization Vsync and the field frequency Vfreq, when a corresponding candidate record is found from the digital resolution information table based on the number of rows V-Total per frame, for each candidate record found, the record value VfreqR of the field frequency Vfreq indirectly included in the candidate record can be calculated based on the number of rows V-Total per frame, the number of pixels H-Total per row, and the pixel clock in the candidate record according to the above formula (3). It is then determined whether the record value VsycnR of the field synchronization Vsycn directly included in the candidate record and the record value VfreqR of the field frequency Vfreq indirectly included in the candidate record are within the error range of the measured field synchronization Vsync and the field frequency Vfreq. If so, the candidate record is confirmed as a valid record.
[0059] Step S133: Determine whether the obtained valid record is one. If it is, proceed to step S134; otherwise, proceed to step S135.
[0060] In this example, when only one valid record is obtained, the resolution information corresponding to that valid record can be determined as the resolution information closest to the VGA video signal. Therefore, based on this closest resolution information, the VGA video signal can be converted into a digital video signal for display on a current digital display.
[0061] It's understandable that the error range cannot be set too small or too large. If it's set too small, no valid records might be found, resulting in a failed search. However, if it's set too large, more than one valid record might be found, making it impossible to determine the final resolution information. This is unless multiple experiments are conducted beforehand to set the exact appropriate error range.
[0062] Considering that setting a suitable error range requires numerous prior experiments, and to make the search scheme more universal and adaptable to different applications, this embodiment allows setting a slightly larger error range for each measurement parameter value. Furthermore, when more than one valid record is found (i.e., at least two valid records), the following steps can be performed:
[0063] Step S135: Pre-set weighting coefficients for some or all of the multiple measurement parameter values.
[0064] In this example, for test parameter values including horizontal frequency Hfreq, vertical frequency Vfreq, and vertical synchronization Vsync, weighting coefficients can be pre-set for either the horizontal frequency Hfreq or the vertical frequency Vfreq, as well as the vertical synchronization Vsync.
[0065] For example, in one implementation, a weighting factor of 1 can be set for the horizontal frequency (Hfreq) and a weighting factor of 0.05 can be set for the vertical synchronization (Vsync); in another implementation, a weighting factor of 1 can be set for the vertical frequency (Vfreq) and a weighting factor of 0.05 can be set for the vertical synchronization (Vsync). Of course, in other implementations, other weighting factor values can be set for the horizontal frequency (Hfreq), the vertical frequency (Vfreq), and the vertical synchronization (Vsync) as needed.
[0066] Step S136: Perform multiple measurements on the VGA video signal of the current video output device, that is, sample the VGA video signal multiple times, and obtain a set of multiple measurement parameter values related to the resolution of the VGA video signal in each measurement, and obtain multiple sets of measurement parameter values in multiple measurements.
[0067] For example, sampling can be performed 2, 3, 4, or 5 times. Taking 3 samplings as an example, three sets of measurement parameter values can be obtained: Hfreq1, Vfreq1, and Vsync1; Hfreq2, Vfreq2, and Vsync2; Hfreq3, Vfreq3, and Vsync3.
[0068] Step S137: For each valid record, based on the measurement parameter value with weighted coefficients, determine the record value directly or indirectly included in the valid record that corresponds to the measurement parameter value with weighted coefficients, and calculate the difference between the record value and the corresponding measurement parameter value in each group of measurement parameter values; and calculate the weighted sum of the differences corresponding to the multiple measurements.
[0069] For example, in the case where weighting coefficients are pre-set for the field synchronization Vsync and the line frequency Hfreq, for each valid record, the above formula (2) can be used to calculate the weighting coefficients based on the number of pixels H-Total and the pixel frequency Pixel of each line in the valid record. Clock calculates the recorded value HfreqR of the line frequency Hfreq indirectly included in the effective record, and calculates the recorded value VsyncR of the field synchronization Vsycn directly included in the effective record and the recorded value HfreqR of the line frequency Hfreq indirectly included in the effective record with the corresponding measurement parameter value in each group of measurement parameter values: (Hfreq1-HfreqR), (Vsycn1-VsyncR); (Hfreq2-HfreqR), (Vsycn2-VsyncR); (Hfreq3-HfreqR), (Vsycn3-VsyncR); and then calculates the weighted sum of the differences corresponding to the multiple measurements: a×((Hfreq1-HfreqR)+(Hfreq2-HfreqR)+(Hfreq3-HfreqR))+b×((Vsycn1-VsyncR)+(Vsycn1-VsyncR)+(Vsycn3-VsyncR)). In one embodiment, a can be 1 and b can be 0.05.
[0070] Similarly, for cases where weighting coefficients are pre-set for the field synchronization Vsync and the field frequency Vfreq, for each valid record, the above formula (3) can be used to calculate the weighting coefficients based on the number of rows V-Total, the number of pixels H-Total, and the pixel frequency Pixel of each frame in the valid record. Clock calculates the recorded value VfreqR of the field frequency Vfreq indirectly included in the effective record, and calculates the differences between (Vfreq1-VfreqR), (Vsycn1-VsyncR), (Vfreq2-VfreqR), (Vsycn2-VsyncR), (Vfreq3-VfreqR), and (Vsycn3-VsyncR) of the field synchronization Vsycn directly included in the effective record and the recorded value Vfreq of the field frequency Vfreq indirectly included in the candidate record, and the corresponding measurement parameter values in each group of measurement parameter values. Then, it calculates the weighted sum of the differences corresponding to the multiple measurements: c×((Hfreq1-HfreqR)+(Hfreq2-HfreqR)+(Hfreq3-HfreqR))+d×((Vsycn1-VsyncR)+(Vsycn1-VsyncR)+(Vsycn3-VsyncR)). In one embodiment, c can be 1 and d can be 0.05.
[0071] Step S138: The valid record with the smallest weighted sum is taken as the final record, and the resolution information corresponding to the final record is taken as the resolution information closest to the VGA video signal.
[0072] The resolution adaptation method for VGA images in the embodiments of this application has been described in detail above. The resolution adaptation device, video converter, and video conversion system for VGA images in the embodiments of this application will be described in detail below. The resolution adaptation device, video converter, and video conversion system for VGA images in the embodiments of this application can be used to implement the corresponding methods in the embodiments of this application. For details not disclosed in detail in the device embodiments of this invention, please refer to the corresponding descriptions in the method embodiments of this invention, which will not be repeated here.
[0073] Figure 2 This is an exemplary structural diagram of a VGA image resolution adaptation device in an embodiment of this application. Figure 2 As shown, the device may include: a parameter measurement module 201, a key value determination module 202, and a resolution information determination module 303.
[0074] The parameter measurement module 201 is used to measure the VGA video signal of the current video output device and obtain at least two measurement parameter values related to the resolution of the VGA video signal.
[0075] The key value determination module 202 is used to determine, based on the at least two measurement parameter values, keywords for searching a digital resolution information table and an error range for verifying whether the retrieved resolution information meets the set requirements. The digital resolution information table stores various digital resolution information supported by the current digital display.
[0076] The resolution information determination module 303 is used to determine the closest resolution information from the digital resolution information table using the keyword and the error range.
[0077] In one implementation, if an error range is pre-set for some or all of the at least two measurement parameter values, the resolution information determination module 303 can use the keyword to search the digital resolution information table to obtain at least one candidate record; wherein, each record corresponds to one resolution information; for each candidate record, based on the measurement parameter value with the set error range, determine the record value directly or indirectly included by the candidate record that corresponds to the measurement parameter value with the set error range, and determine whether the record value is within the corresponding error range. If so, determine that the candidate record is a valid record; when there is one valid record, use the resolution information corresponding to the valid record as the resolution information closest to the VGA video signal.
[0078] When there are at least two valid records, in this embodiment of the application, weighting coefficients can be pre-set for some or all of the measurement parameter values among the at least two measurement parameter values; accordingly, the resolution information determination module 303 can further perform multiple measurements on the VGA video signal of the current video output device to obtain multiple sets of measurement parameter values; wherein, each measurement obtains a set of at least two measurement parameter values related to the resolution of the VGA video signal; for each valid record, based on the measurement parameter values with weighting coefficients set, the record value corresponding to the measurement parameter values with weighting coefficients set directly or indirectly included in the valid record is determined, and the difference between the record value and the corresponding measurement parameter value in each set of measurement parameter values is calculated; and the weighted sum of the differences corresponding to the multiple measurements is calculated; the valid record with the smallest weighted sum is taken as the final record, and the resolution information corresponding to the final record is taken as the resolution information closest to the VGA video signal.
[0079] Figure 3 This is a schematic diagram of the structure of another VGA image resolution adaptation device in the embodiments of this application, as shown below. Figure 3 As shown, the device may include at least one memory 31 and at least one processor 32. Additionally, it may include other components, such as communication ports. These components communicate via a bus 33.
[0080] At least one memory 31 is used to store a computer program. In one embodiment, the computer program can be understood to include... Figure 2 The diagram shows various modules of a resolution adaptation device for a VGA image. Additionally, at least one memory 31 can store an operating system, etc. Operating systems include, but are not limited to: Android, Symbian, Windows, Linux, etc.
[0081] At least one processor 32 is used to invoke a computer program stored in at least one memory 31 to execute the VGA image resolution adaptation method described in the embodiments of this application. The processor 32 can be a CPU, processing unit / module, ASIC, logic module, or programmable gate array, etc. It can receive and send data through the communication port.
[0082] Furthermore, this application also proposes a video converter, such as... Figure 4 As shown, it includes at least one input interface 41, at least one output interface 42, and as shown in the figure. Figure 2 or Figure 3 The resolution adaptation device 43 for the VGA image.
[0083] One of the input interfaces 41 is used to connect a VGA video output device.
[0084] At least one of the output interfaces 42 is used to connect a digital display.
[0085] Figure 5 This is an exemplary structural diagram of a video conversion system for a medical imaging system, as exemplified in this application. The video conversion system includes a VGA video output device 51, a video converter 52, and a digital display 53.
[0086] Among them, the video converter 52 has the following features: Figure 4 The structure shown is used to measure the VGA video signal of the VGA video output device 51 to obtain at least two measurement parameter values related to the resolution of the VGA video signal; based on the at least two measurement parameter values, to determine keywords for searching a digital resolution information table and an error range for verifying whether the retrieved resolution information meets the set requirements, the digital resolution information table storing various digital resolution information supported by the current digital display; to determine the closest resolution information from the digital resolution information table using the keywords and the error range; and to provide the corresponding video signal to the digital display 53 based on the resolution information.
[0087] In this embodiment, the VGA video output device 51 is used as an example of a medical imaging system. The medical imaging system includes a VGA video signal source, which can provide video signals carrying medical data.
[0088] The medical imaging system may include:
[0089] (1) Ultrasound System: An ultrasound system uses ultrasound waves to generate real-time internal images. It forms medical images by sending ultrasound waves into the human body and receiving their echoes, based on the propagation and reflection of sound waves in different tissues. When a medical imaging system is implemented as an ultrasound system, a VGA video signal source can be implemented as an imaging workstation in the ultrasound system, and the medical data carried in the VGA video signal can be ultrasound images.
[0090] (2) Endoscopic Imaging System: An endoscopic imaging system typically includes an optical imaging system and an illumination system. The illumination system provides light or excitation light to the optical imaging system, enabling it to image internal tissues for lesion observation or surgical procedures. When a medical imaging system is implemented as an endoscopic imaging system, a VGA video signal source can be implemented as an image workstation within the endoscopic imaging system, and the medical data carried in the VGA video signal can be endoscopic images.
[0091] The above description uses a medical imaging system as an example to illustrate the embodiments of this application. Those skilled in the art will recognize that this description is merely exemplary and not intended to limit the scope of protection of the embodiments of this application. It is readily understood that the various video converters and video conversion systems described in this application by way of example can be applied to scenarios using multiple medical imaging systems, such as hybrid examination rooms or hybrid operating rooms. Simultaneously, the video converters or video conversion systems of the embodiments of this application can also be applied to occasions requiring high-quality video display, such as broadcast television, monitoring systems, video conferencing, and educational presentations.
[0092] It should be noted that not all steps and modules in the above processes and structural diagrams are mandatory; some steps or modules can be omitted as needed. The execution order of the steps is not fixed and can be adjusted as required. The division of modules is merely for the convenience of description and functional division. In actual implementation, a module can be implemented by multiple modules, and the functions of multiple modules can also be implemented by the same module. These modules can be located in the same device or in different devices.
[0093] It is understood that the hardware modules in the above embodiments can be implemented mechanically or electronically. For example, a hardware module may include specially designed permanent circuits or logic devices (such as dedicated processors, such as FPGAs or ASICs) to perform specific operations. A hardware module may also include programmable logic devices or circuits (such as general-purpose processors or other programmable processors) temporarily configured by software to perform specific operations. The specific method used to implement the hardware module—whether it is mechanical, a dedicated permanent circuit, or a temporarily configured circuit (such as one configured by software)—can be determined based on cost and time considerations.
[0094] Furthermore, this application embodiment also provides a computer program product, including a computer program that can be executed by a processor to implement the VGA image resolution adaptation method described in this application embodiment. This application embodiment also provides a computer-readable storage medium storing a computer program that can be executed by a processor to implement the VGA image resolution adaptation method described in this application embodiment. Specifically, a system or device equipped with a storage medium can be provided, on which software program code implementing the functions of any of the above embodiments is stored, and the computer (or CPU or MPU) of the system or device can read and execute the program code stored in the storage medium. Furthermore, the operating system or other system operating on the computer can perform some or all of the actual operations through instructions based on the program code. The program code read from the storage medium can also be written to a memory located in an expansion board inserted into the computer or to a memory located in an expansion unit connected to the computer. Subsequently, the CPU or other system installed on the expansion board or expansion unit can execute some or all of the actual operations based on the instructions of the program code, thereby implementing the functions of any of the above embodiments. Storage media implementations for providing program code include USB, floppy disk, hard disk, magneto-optical disk, optical disk (such as CD-ROM, CD-R, CD-RW, DVD-ROM, DVD-RAM, DVD-RW, DVD+RW), magnetic tape, non-volatile memory cards, and ROM, etc. Alternatively, program code can be downloaded from a server computer via a communication network.
[0095] As can be seen from the above scheme, in this embodiment of the application, by measuring the VGA video signal and obtaining at least two measurement parameter values related to the resolution of the VGA video signal, and then based on the at least two measurement parameter values, determining the keywords for searching a digital resolution information table and the error range for verifying whether the retrieved resolution information meets the set requirements, the closest resolution information can be determined from the digital resolution information table using the keywords and the error range, thereby accurately determining the adapted resolution of the VGA video data.
[0096] When there are at least two valid records, a weighted sum is calculated between the difference between the corresponding record value in each valid record and the corresponding measurement parameter value in each group of measurement parameter values. The resolution information corresponding to the valid record with the smallest weighted sum is taken as the resolution information closest to the VGA video signal. This can further improve the accuracy of determining the appropriate resolution of VGA video data while ensuring that the probability of retrieval failure is reduced.
[0097] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A resolution adaptation method for VGA images, characterized in that, include: Measure the VGA video signal of the current video output device to obtain at least two measurement parameter values related to the resolution of the VGA video signal; Based on the at least two measurement parameter values, keywords for searching a digital resolution information table and an error range for verifying whether the retrieved resolution information meets the set requirements are determined. The digital resolution information table stores various digital resolution information supported by the current digital display. The closest resolution information is determined from the digital resolution information table using the keywords and the error range.
2. The resolution adaptation method for VGA images according to claim 1, characterized in that, The method further includes: pre-setting an error range for some or all of the at least two measurement parameter values; The step of determining the closest resolution information from the digital resolution information table using the keyword and the error range includes: The digital resolution information table is searched using the keywords to obtain at least one candidate record; each record corresponds to one resolution information. For each candidate record, based on the measurement parameter value with the set error range, determine the record value that the candidate record directly or indirectly includes corresponds to the measurement parameter value with the set error range, and determine whether the record value is within the corresponding error range. If so, determine that the candidate record is a valid record. When there is only one valid record, the resolution information corresponding to the valid record is taken as the resolution information closest to the VGA video signal.
3. The resolution adaptation method for VGA images according to claim 2, characterized in that, When there are at least two valid records, the method further includes: Weighting coefficients are pre-set for some or all of the at least two measurement parameter values; The VGA video signal of the current video output device is measured multiple times to obtain multiple sets of measurement parameter values; wherein, each measurement yields at least two measurement parameter values related to the resolution of the VGA video signal. For each valid record, based on the measurement parameter value with a weighted coefficient, determine the record value corresponding to the measurement parameter value with the weighted coefficient that is directly or indirectly included in the valid record, and calculate the difference between the record value and the corresponding measurement parameter value in each group of measurement parameter values; and calculate the weighted sum of the differences corresponding to the multiple measurements; The valid record with the smallest weighted sum is taken as the final record, and the resolution information corresponding to the final record is taken as the resolution information closest to the VGA video signal.
4. The resolution adaptation method for VGA images according to claim 3, characterized in that, The at least two measured parameter values include: the horizontal frequency, vertical frequency, and vertical synchronization of the VGA video signal; The step of determining the keyword for retrieving a digital resolution information table based on the multiple measurement parameter values and verifying whether the retrieved resolution information meets the set error range includes: calculating the number of rows in each frame of the image based on the line frequency and the field frequency, and using the number of rows in each frame of the image as the keyword for retrieving the digital resolution information table; and pre-setting the error range of either the line frequency or the field frequency and the field synchronization.
5. The resolution adaptation method for VGA images according to claim 4, characterized in that, The digital resolution information table includes: point frequency, number of pixels per row, field synchronization, and number of rows per frame; The step of determining the record values corresponding to the measurement parameter values with set error ranges, which are directly or indirectly included in the candidate records, includes: When the measurement parameter value with an error range includes the line frequency, the record value of the line frequency indirectly included in the candidate record is calculated based on the point frequency and the number of pixels per line in the candidate record: point frequency / number of pixels per line. When the measurement parameter value with an error range includes the field frequency, the recorded value of the field frequency indirectly included in the candidate record is calculated based on the point frequency, the number of rows per frame, and the number of pixels per row in the candidate record: = point frequency / (number of pixels per row × number of rows per frame). When the measurement parameter values with set error ranges include field synchronization, determine the field synchronization record values directly included in the candidate records.
6. The resolution adaptation method for VGA images according to claim 5, characterized in that, The determination of the record values corresponding to the measurement parameter values with weighted coefficients, which are directly or indirectly included in the valid records based on the measurement parameter values with weighted coefficients, includes: When the measurement parameter value with weighting coefficients includes the line frequency, the record value of the line frequency indirectly included in the effective record is calculated based on the point frequency in the effective record and the number of pixels per line = point frequency / number of pixels per line; When the measurement parameter value with weighting coefficients includes the field frequency, the recorded value of the field frequency indirectly included in the effective record is calculated based on the point frequency in the effective record, the number of rows per frame, and the number of pixels per row = point frequency / (number of pixels per row × number of rows per frame). When the measurement parameter values with weighted coefficients include field synchronization, determine the field synchronization record values directly included in the valid records.
7. The resolution adaptation method for VGA images according to any one of claims 4 to 6, characterized in that, The error range of the line frequency is ±(1,000,000 / number of pixels per line); the error range of the field frequency is ±(1,000,000 / (number of pixels per line × number of lines per frame)); and the error range of the field synchronization is ±2.
8. A resolution adaptation device for VGA images, characterized in that, include: The parameter measurement module (201) is used to measure the VGA video signal of the current video output device and obtain at least two measurement parameter values related to the resolution of the VGA video signal. The key value determination module (202) is used to determine, based on the at least two measurement parameter values, the keywords for searching a digital resolution information table and the error range for verifying whether the retrieved resolution information meets the set requirements. The digital resolution information table stores various digital resolution information supported by the current digital display. and The resolution information determination module (303) is used to determine the closest resolution information from the digital resolution information table using the keyword and the error range.
9. A resolution adaptation device for VGA images, characterized in that, include: At least one memory (31) and at least one processor (32), wherein: The at least one memory (31) is used to store computer programs; The at least one processor (32) is used to call a computer program stored in the at least one memory (31) to execute the resolution adaptation method for VGA images as described in any one of claims 1 to 7.
10. A video converter, characterized in that, include: At least one input interface (41), one of which is used to connect a VGA video output device; At least one output interface (42), one of which is used to connect to a digital display; and The resolution adaptation device (43) for VGA images as described in claim 8 or 9.
11. A video conversion system, characterized in that, include: VGA video output device (51); Digital display (53); and The video converter (52) as described in claim 10.
12. The video conversion system according to claim 11, characterized in that, The VGA video output device (51) includes a medical imaging system.
13. A computer-readable storage medium having a computer program stored thereon; characterized in that, The computer program can be executed by a processor to implement the resolution adaptation method for VGA images as described in any one of claims 1 to 7.
14. A computer program product, comprising a computer program; characterized in that, The computer program can be executed by a processor to implement the resolution adaptation method for VGA images as described in any one of claims 1 to 7.