Image display method and system for providing eye protection mode, and storage medium

By monitoring and adjusting the display parameters of the electronic tablet device in real time, and generating and displaying simulated paper images, the eye fatigue problem caused by the use of the electronic tablet device is solved, and better eye protection effect is achieved.

CN118968947APending Publication Date: 2024-11-15GUANGZHOU LANGO ELECTRONICS TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411029019.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-30
Publication Date
2024-11-15

AI Technical Summary

Technical Problem

Long-term use of electronic tablet devices can lead to eye fatigue, and the existing eye protection mode cannot adapt to user needs in time and has poor results.

Method used

By monitoring the resolution and display parameters of the display screen in real time, calculate the scaling ratio and layout of the image, generate simulated paper images, and perform image enhancement to maintain good eye protection effect under different ambient light.

Benefits of technology

Improves eye protection effect, allowing the image to fill the entire screen on the display screen, adapt to different ambient light, and significantly reduces eye fatigue.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118968947A_ABST
    Figure CN118968947A_ABST
Patent Text Reader

Abstract

The invention discloses an image display method and system for providing an eye protection mode, and a storage medium, and the method comprises the steps: monitoring the resolution of a display screen in real time, and calculating the scaling corresponding to a first paper image according to the resolution and the first pixel data of the first paper image to be displayed; processing the first paper image according to the scaling to generate a second paper image, and calculating a display layout of the second paper image in the display screen according to second pixel data of the second paper image and the resolution; drawing the second paper image on the display screen according to the display layout, and generating a first eye protection image; and monitoring display parameters of the display screen in real time, performing image enhancement on the first eye protection image according to the display parameters, generating a second eye protection image, displaying the second eye protection image on the display screen, and simulating a paper eye protection effect.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of electronic display technology, and in particular to an image display method, system and storage medium that provide an eye protection mode. Background Art

[0002] With the development of science and technology and the increasingly fast pace of life, electronic tablet devices have become an important tool for close connection between people and society. In social activities, electronic tablet devices help users obtain information to improve work efficiency and communication efficiency. Electronic tablet devices have become an indispensable tool for people, and at the same time, users spend more and more time using electronic tablet devices.

[0003] However, during long-term use, electronic tablet devices can cause damage to the human eye. Not only can they easily lead to eye fatigue, but when the device is in high brightness and strong blue light display, it will also have a certain degree of impact on vision.

[0004] In order to reduce the impact of electronic devices on human eyes, the existing technology usually adopts the display method of the device's display screen to achieve eye protection. However, this improvement method often requires users to manually adjust the screen brightness or the intensity of the screen blue light. Not only can it not adapt to the user's needs in a timely manner, but it is often affected by the environment, resulting in extremely low eye protection effect. Summary of the invention

[0005] In order to solve the above technical problems, the present invention discloses an image display method, system and storage medium that provide an eye protection mode, which are used to simulate a paper eye protection method and improve the eye protection effect.

[0006] In order to achieve the above-mentioned object, in a first aspect, the present invention discloses an image display method providing an eye protection mode, comprising:

[0007] monitoring the resolution of the display screen in real time, so as to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed;

[0008] Processing the first paper image according to the scaling ratio to generate a second paper image and calculating a display layout of the second paper image on the display screen according to second pixel data of the second paper image and the resolution;

[0009] Drawing the second paper image on the display screen according to the display layout to generate a first eye protection image;

[0010] The display parameters of the display screen are monitored in real time, and the first eye protection image is enhanced according to the display parameters to generate a second eye protection image, and the second eye protection image is displayed on the display screen.

[0011] The present invention discloses an image display method that provides an eye protection mode. First, the resolution of the display screen is monitored in real time so that the image display method finally generated can adapt to the display screen and improve the eye protection effect. Then, a paper image is set to be displayed on the display screen to simulate the paper eye protection method and improve the eye protection effect. Furthermore, in the process of displaying the paper image on the display screen, a scaling ratio is first calculated according to the resolution of the screen and the first pixel data of the first paper image, so that the first paper image is scaled according to the scaling ratio to ensure that the scaled second paper image can cover the entire display screen, thereby ensuring the eye protection effect.

[0012] Secondly, the second pixel data of the scaled second paper image and the resolution of the screen are used to calculate the corresponding display layout when the image can cover the entire display screen, so that the first eye protection image formed by drawing the second image onto the display screen according to the display layout can cover the entire display screen, thereby improving the eye protection effect. Finally, the first eye protection image is enhanced according to the monitored display parameters of the screen, so that by enhancing the image, a good eye protection effect can be maintained under different ambient light.

[0013] As a preferred example, the real-time monitoring of the resolution of the display screen to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed includes:

[0014] By monitoring the change of the direction of the display screen in real time, the current screen direction of the display screen is obtained; the screen direction includes horizontal screen and vertical screen;

[0015] Acquire the resolution of the display screen according to the screen direction; the resolution is the screen width and screen height of the display screen;

[0016] Reading first pixel data of the first paper image, and acquiring a first image height and a first image width corresponding to the first paper image;

[0017] comparing the screen width and the screen height, and when the screen width is less than or equal to the screen height, obtaining the scaling ratio by calculating a ratio of the screen width to a width of the first image;

[0018] When the screen width is greater than the screen height, the scaling ratio is obtained by calculating the ratio of the screen height to the first image height.

[0019] The present invention obtains the screen resolution and the pixel data of the image for calculating the zoom ratio, so as to ensure that when tiling the image onto the display screen according to the obtained zoom ratio, the image just covers a specified number of pictures in at least one direction, thereby improving the eye protection effect.

[0020] As a preferred example, the calculating the display layout of the second paper image on the display screen according to the second pixel data and the resolution of the second paper image includes:

[0021] Calculate a second image height and a second image width corresponding to the second paper image according to the scaling ratio, the first image height and the first image width;

[0022] Obtaining the number of display lines of the second paper image in the display screen by calculating the ratio of the screen width to the second image width;

[0023] The number of display columns of the second paper image in the display screen is obtained by calculating the ratio of the screen height to the second image height.

[0024] The present invention uses the pixel data of the second paper image obtained after scaling and the screen width and screen height of the display screen to calculate the number of rows and columns of the second paper image that can be accommodated on the screen, ensuring that the display screen simulates the paper effect according to the number of rows and columns, thereby improving the eye protection effect.

[0025] As a preferred example, drawing the second paper image on the display screen according to the display layout to generate the first eye protection image includes:

[0026] The second paper image is drawn on the display screen according to the number of display rows and the number of display columns to generate the first eye protection image.

[0027] The present invention uses the number of rows and columns to draw the second paper images one by one to the corresponding positions in the display screen, ensuring that the drawn first eye protection image covers the entire screen, improving the effect of paper simulation, and further improving the eye protection effect.

[0028] As a preferred example, the real-time monitoring of the display parameters of the display screen and performing image enhancement on the first eye protection image according to the display parameters include:

[0029] Performing anti-aliasing and filtering processing on the first eye protection image, and monitoring brightness changes of the display screen in real time to obtain a current screen brightness corresponding to the display screen;

[0030] Adjusting the brightness of the color matrix initially set according to the screen brightness, and adjusting the blue light intensity and sharpness of the color matrix to generate a first color matrix;

[0031] A color matrix filter corresponding to the first color matrix is ​​obtained, and image enhancement is performed on the first eye protection image after anti-aliasing processing and filtering processing according to the color matrix filter.

[0032] The present invention monitors the brightness changes of the display screen to adjust the brightness and contrast of the pattern according to the brightness of the display screen, so that it can maintain a good display effect under different ambient light conditions and improve the eye protection effect. Furthermore, by setting the blue light intensity and sharpness of the color matrix, the first eye protection image is enhanced to optimize the image details, improve the image display effect, and thus improve the eye protection effect.

[0033] In a second aspect, the present invention discloses an image display system providing an eye protection mode, including a ratio calculation module, an image layout module, an image drawing module and an image display module;

[0034] The ratio calculation module is used to monitor the resolution of the display screen in real time, so as to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed;

[0035] The image layout module is used to process the first paper image according to the scaling ratio, generate a second paper image, and calculate a display layout of the second paper image on the display screen according to second pixel data of the second paper image and the resolution;

[0036] The image drawing module is used to draw the second paper image on the display screen according to the display layout to generate a first eye protection image;

[0037] The image display module is used to monitor the display parameters of the display screen in real time, and perform image enhancement on the first eye protection image according to the display parameters to generate a second eye protection image, and display the second eye protection image on the display screen.

[0038] The present invention discloses an image display system that provides an eye protection mode. The system first monitors the resolution of a display screen in real time so that a finally generated image display method can adapt to the display screen and improve the eye protection effect. Then, a paper image is set to be displayed on the display screen to simulate a paper eye protection method and improve the eye protection effect. Furthermore, in the process of displaying the paper image on the display screen, a scaling ratio is first calculated based on the resolution of the screen and first pixel data of the first paper image, so that the first paper image is scaled according to the scaling ratio to ensure that the scaled second paper image can cover the entire display screen, thereby ensuring the eye protection effect.

[0039] Secondly, the second pixel data of the scaled second paper image and the resolution of the screen are used to calculate the corresponding display layout when the image can cover the entire display screen, so that the first eye protection image formed by drawing the second image onto the display screen according to the display layout can cover the entire display screen, thereby improving the eye protection effect. Finally, the first eye protection image is enhanced according to the monitored display parameters of the screen, so that by enhancing the image, a good eye protection effect can be maintained under different ambient light.

[0040] As a preferred example, the ratio calculation module includes a parameter reading unit and a calculation unit;

[0041] The parameter reading unit is used to obtain the current screen direction of the display screen by monitoring the direction change of the display screen in real time; the screen direction includes horizontal screen and vertical screen; obtain the resolution of the display screen according to the screen direction; the resolution is the screen width and screen height of the display screen; read the first pixel data of the first paper image, and obtain the first image height and first image width corresponding to the first paper image;

[0042] The calculation unit is used to compare the screen width and the screen height. When the screen width is less than or equal to the screen height, the scaling ratio is obtained by calculating the ratio of the screen width to the first image width; when the screen width is greater than the screen height, the scaling ratio is obtained by calculating the ratio of the screen height to the first image height.

[0043] The present invention obtains the screen resolution and the pixel data of the image for calculating the zoom ratio, so as to ensure that when tiling the image onto the display screen according to the obtained zoom ratio, the image just covers a specified number of pictures in at least one direction, thereby improving the eye protection effect.

[0044] As a preferred example, the image layout module includes a parameter updating unit and a layout unit;

[0045] The parameter updating unit is used to calculate a second image height and a second image width corresponding to the second paper image according to the scaling ratio, the first image height and the first image width;

[0046] The layout unit is used to obtain the number of display rows of the second paper image in the display screen by calculating the ratio of the screen width to the width of the second image; and to obtain the number of display columns of the second paper image in the display screen by calculating the ratio of the screen height to the height of the second image.

[0047] The present invention uses the pixel data of the second paper image obtained after scaling and the screen width and screen height of the display screen to calculate the number of rows and columns of the second paper image that can be accommodated on the screen, ensuring that the display screen simulates the paper effect according to the number of rows and columns, thereby improving the eye protection effect.

[0048] As a preferred example, the image display module includes a monitoring unit and an image enhancement unit;

[0049] The monitoring unit is used to perform anti-aliasing processing and filtering processing on the first eye protection image, and monitor the brightness change of the display screen in real time to obtain the current screen brightness corresponding to the display screen;

[0050] The image enhancement unit is used to adjust the brightness of the color matrix initialized according to the screen brightness, and adjust the blue light intensity and sharpness of the color matrix to generate a first color matrix; obtain the color matrix filter corresponding to the first color matrix, and perform image enhancement on the first eye protection image after anti-aliasing and filtering according to the color matrix filter.

[0051] The present invention monitors the brightness changes of the display screen to adjust the brightness and contrast of the pattern according to the brightness of the display screen, so that it can maintain a good display effect under different ambient light conditions and improve the eye protection effect. Furthermore, by setting the blue light intensity and sharpness of the color matrix, the first eye protection image is enhanced to optimize the image details, improve the image display effect, and thus improve the eye protection effect.

[0052] In a third aspect, the present invention discloses a computer-readable storage medium storing computer instructions, which, when executed by a processor, implements an image display method providing an eye protection mode as described in the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] Figure 1 : A schematic diagram of a flow chart of an image display method providing an eye protection mode disclosed in an embodiment of the present invention;

[0054] Figure 2 : is a structural schematic diagram of an image display system providing an eye protection mode disclosed in an embodiment of the present invention;

[0055] Figure 3 : A flowchart of an image display method providing an eye protection mode disclosed in another embodiment of the present invention;

[0056] Figure 4 : A schematic diagram of a rice paper simulation image disclosed in another embodiment of the present invention;

[0057] Figure 5 : A schematic diagram of a simulated image on sketch paper disclosed in another embodiment of the present invention;

[0058] Figure 6 : A schematic diagram of a kraft paper simulation image disclosed in another embodiment of the present invention;

[0059] Figure 7 : A schematic diagram of a watercolor paper simulated image disclosed in another embodiment of the present invention. DETAILED DESCRIPTION

[0060] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0061] Embodiment 1

[0062] This embodiment discloses an image display method that provides an eye protection mode. For the specific implementation process of the display method, please refer to Figure 1 , mainly including steps 101 to 104, wherein the steps are mainly:

[0063] Step 101: monitoring the resolution of a display screen in real time, so as to calculate a zoom ratio corresponding to a first paper image to be displayed according to the resolution and first pixel data of the first paper image to be displayed.

[0064] In this embodiment, the steps mainly include: obtaining the current screen direction of the display screen by real-time monitoring of the direction change of the display screen; the screen direction includes horizontal screen and vertical screen; obtaining the resolution of the display screen according to the screen direction; the resolution is the screen width and screen height of the display screen; reading the first pixel data of the first paper image, obtaining the first image height and the first image width corresponding to the first paper image; comparing the screen width and the screen height, when the screen width is less than or equal to the screen height, obtaining the scaling ratio by calculating the ratio of the screen width to the first image width; when the screen width is greater than the screen height, obtaining the scaling ratio by calculating the ratio of the screen height to the first image height.

[0065] In this embodiment, this step obtains the screen resolution and pixel data of the image for calculating the scaling ratio, so as to ensure that when the image is tiled onto the display screen according to the obtained scaling ratio, the image is exactly covered with a specified number of pictures in at least one direction, thereby improving the eye protection effect.

[0066] Step 102: Processing the first paper image according to the scaling ratio to generate a second paper image and calculating a display layout of the second paper image on the display screen according to second pixel data of the second paper image and the resolution.

[0067] In this embodiment, the step mainly includes: calculating a second image height and a second image width corresponding to the second paper image according to the scaling ratio, the first image height and the first image width;

[0068] The number of display rows of the second paper image in the display screen is obtained by calculating the ratio of the screen width to the width of the second image; the number of display columns of the second paper image in the display screen is obtained by calculating the ratio of the screen height to the height of the second image.

[0069] In this embodiment, this step uses the pixel data of the second paper image obtained after scaling and the screen width and screen height of the display screen to calculate the number of rows and columns of the second paper image that can be accommodated on the screen, ensuring that the display screen simulates the paper effect according to the number of rows and columns, thereby improving the eye protection effect.

[0070] Step 103: Draw the second paper image on the display screen according to the display layout to generate a first eye protection image.

[0071] In this embodiment, this step mainly includes: drawing the second paper image on the display screen according to the number of display rows and the number of display columns to generate the first eye protection image.

[0072] In this embodiment, this step uses the number of rows and columns to draw the second paper images one by one to the corresponding positions in the display screen, ensuring that the drawn first eye protection image covers the entire screen, improving the effect of paper simulation, and further improving the eye protection effect.

[0073] Step 104: monitor the display parameters of the display screen in real time, perform image enhancement on the first eye protection image according to the display parameters, generate a second eye protection image, and display the second eye protection image on the display screen.

[0074] In this embodiment, the steps mainly include: performing anti-aliasing and filtering processing on the first eye protection image, and monitoring the brightness changes of the display screen in real time to obtain the current screen brightness corresponding to the display screen; adjusting the brightness of the color matrix initialized according to the screen brightness, and adjusting the blue light intensity and sharpness of the color matrix to generate a first color matrix; obtaining the color matrix filter corresponding to the first color matrix, and performing image enhancement on the first eye protection image after anti-aliasing and filtering processing according to the color matrix filter.

[0075] In this embodiment, this step monitors the brightness changes of the display screen to adjust the brightness and contrast of the pattern according to the brightness of the display screen, so that it can maintain a good display effect under different ambient light conditions and improve the eye protection effect. Furthermore, the first eye protection image is enhanced by setting the blue light intensity and sharpness of the color matrix to optimize image details, improve image display effects, and thereby improve eye protection effects.

[0076] On the other hand, this embodiment also discloses an image display system that provides an eye protection mode. For the specific structure of the display system, please refer to Figure 2 , including a ratio calculation module 201, an image layout module 202, an image drawing module 203 and an image display module 204.

[0077] The ratio calculation module 201 is used to monitor the resolution of the display screen in real time, so as to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed.

[0078] The image layout module 202 is used to process the first paper image according to the scaling ratio, generate a second paper image, and calculate a display layout of the second paper image on the display screen according to second pixel data of the second paper image and the resolution.

[0079] The image drawing module 203 is used to draw the second paper image on the display screen according to the display layout to generate a first eye protection image.

[0080] The image display module 204 is used to monitor the display parameters of the display screen in real time, and perform image enhancement on the first eye protection image according to the display parameters to generate a second eye protection image, and display the second eye protection image on the display screen.

[0081] In this embodiment, the ratio calculation module 201 includes a parameter reading unit and a calculation unit.

[0082] The parameter reading unit is used to obtain the current screen direction of the display screen by monitoring the direction change of the display screen in real time; the screen direction includes horizontal screen and vertical screen; obtain the resolution of the display screen according to the screen direction; the resolution is the screen width and screen height of the display screen; read the first pixel data of the first paper image, and obtain the first image height and first image width corresponding to the first paper image.

[0083] The calculation unit is used to compare the screen width and the screen height. When the screen width is less than or equal to the screen height, the scaling ratio is obtained by calculating the ratio of the screen width to the first image width; when the screen width is greater than the screen height, the scaling ratio is obtained by calculating the ratio of the screen height to the first image height.

[0084] In this embodiment, the image layout module 202 includes a parameter updating unit and a layout unit.

[0085] The parameter updating unit is used to calculate a second image height and a second image width corresponding to the second paper image according to the scaling ratio, the first image height and the first image width.

[0086] The layout unit is used to obtain the number of display rows of the second paper image in the display screen by calculating the ratio of the screen width to the width of the second image; and to obtain the number of display columns of the second paper image in the display screen by calculating the ratio of the screen height to the height of the second image.

[0087] In this embodiment, the image drawing module 203 is further configured to draw the second paper image on the display screen according to the number of display rows and the number of display columns to generate the first eye protection image.

[0088] In this embodiment, the image display module 204 includes a monitoring unit and an image enhancement unit.

[0089] The monitoring unit is used to perform anti-aliasing processing and filtering processing on the first eye protection image, and monitor the brightness changes of the display screen in real time to obtain the current screen brightness corresponding to the display screen.

[0090] The image enhancement unit is used to adjust the brightness of the color matrix initialized according to the screen brightness, and adjust the blue light intensity and sharpness of the color matrix to generate a first color matrix; obtain the color matrix filter corresponding to the first color matrix, and perform image enhancement on the first eye protection image after anti-aliasing and filtering according to the color matrix filter.

[0091] In this embodiment, a computer-readable storage medium is further disclosed, which stores computer instructions. When the computer instructions are executed by a processor, an image display method for providing an eye protection mode described in this embodiment is implemented.

[0092] The present embodiment discloses an image display method and system that provides an eye protection mode. First, the resolution of the display screen is monitored in real time so that the image display method finally generated can adapt to the display screen and improve the eye protection effect. Then, a paper image is set to be displayed on the display screen to simulate the paper eye protection method and improve the eye protection effect. Furthermore, in the process of displaying the paper image on the display screen, a scaling ratio is first calculated according to the resolution of the screen and the first pixel data of the first paper image, so that the first paper image is scaled according to the scaling ratio to ensure that the scaled second paper image can cover the entire display screen, thereby ensuring the eye protection effect.

[0093] Secondly, the second pixel data of the scaled second paper image and the resolution of the screen are used to calculate the corresponding display layout when the image can cover the entire display screen, so that the first eye protection image formed by drawing the second image onto the display screen according to the display layout can cover the entire display screen, thereby improving the eye protection effect. Finally, the first eye protection image is enhanced according to the monitored display parameters of the screen, so that by enhancing the image, a good eye protection effect can be maintained under different ambient light.

[0094] Embodiment 2

[0095] In an image display method for providing an eye protection mode provided in this embodiment, a specific image with a paper display effect is tiled on the display screen of an electronic tablet to simulate the paper effect to achieve eye protection. Specifically, the implementation process of the image display method can refer to Figure 3 , including step 301 to step 304, the steps are:

[0096] Step 301: loading a pre-saved first paper simulation image, and reading first pixel data of the first paper simulation image.

[0097] In this embodiment, this step mainly includes: reading the first pixel data of the first paper simulation image, and acquiring the first image height and the first image width corresponding to the first paper simulation image.

[0098] Specifically, a pre-designed paper eye protection picture, that is, the first paper simulation image, is loaded from a storage device of the electronic tablet, and pixel data of the paper eye protection picture is read by a preset data reading method. Preferably, the pixel data is obtained by running a code that can read pixel data and is stored in the electronic tablet, wherein the running code is:

[0099] mItemList.add(new TextureInfoBean(TextureType.TEXTURE_PAPER,"rice paper",R.drawable.ic_texture_paper,true));

[0100] mItemList.add(new TextureInfoBean(TextureType.TEXTURE_SKETCH,"sketch paper",R.drawable.ic_texture_sketch,true));

[0101] mItemList.add(new TextureInfoBean(TextureType.TEXTURE_KRAFT,"Kraft Paper",R.drawable.ic_texture_kraft,true));

[0102] mItemList.add(newTextureInfoBean(TextureType.TEXTURE_WATERCOLOR,"Watercolor Paper",R.drawable.ic_texture_watercolor,true))

[0103] setBackground(textureBean.iconId).

[0104] Further, see Figures 4 to 7 For the paper eye protection pictures stored in the storage device in this embodiment, different types of paper are simulated, including rice paper, sketch paper, kraft paper and watercolor paper, so that different types of paper eye protection pictures can adapt to the format requirements of different electronic tablets.

[0105] Step 302: Monitor the resolution of the display screen to calculate the image scaling ratio according to the first pixel data and the resolution, and then create a second paper simulation image according to the scaling ratio and the first pixel data.

[0106] In this embodiment, the step is specifically as follows: by real-time monitoring of the direction changes of the display screen, the current screen direction corresponding to the display screen is obtained, and then the screen resolution is read according to the screen direction, and then the scaling ratio is calculated according to the ratio of the screen resolution to the first pixel data, so as to create the second paper simulation image.

[0107] Specifically, the screen resolution of the current display screen is read by running a screen resolution reading code in the electronic tablet to obtain the width and height of the display screen. The screen resolution reading code is specifically:

[0108] screenWidth=getResources().getDisplayMetrics().widthPixels;

[0109] screenHeight=getResources().getDisplayMetrics().heightPixels.

[0110] After obtaining the screen width and screen height of the display screen through the above reading code, before drawing the image on the display screen, it is necessary to calculate the image scaling ratio to ensure that the scaled image can just cover the specified number of pictures in at least one direction of the display screen. Specifically, the scaling ratio is output through the code for calculating the scaling ratio stored in the electronic whiteboard. Among them, the code for calculating the scaling ratio is:

[0111]

[0112]

[0113] The width and height of the display screen are input into the above code, and the scaling ratio is calculated through the code. During the running of the code, the size of the width and height is determined. When the width is greater than or equal to the height, the scaling ratio is generated by calculating the ratio of the height of the screen to the height of the image with the purpose of filling the horizontal direction of the display screen. On the contrary, when the width is less than the height, the scaling ratio is generated by calculating the ratio of the width of the screen to the width of the image with the purpose of filling the vertical direction of the display screen.

[0114] According to the scaling ratio and the first pixel data, a second paper simulation image, that is, the second paper image, is created. Specifically, the second paper simulation image is created by a code for creating an image stored in the electronic whiteboard. The code for creating an image is:

[0115] int scaledWidth=(int)(bitmapWidth*scale);

[0116] int scaledHeight=(int)(bitmapHeight*scale);

[0117] Bitmap scaledBitmap=Bitmap.createScaledBitmap(bitmap,scaledWidth,scaledHeight,true).

[0118] In this embodiment, the above code is used to create the second paper simulation image, and the height and width corresponding to the second paper simulation image are calculated.

[0119] Furthermore, in order to ensure that the created second paper simulation image can be tiled to cover the entire display screen, in this embodiment, the direction of the display screen is monitored in real time to determine whether the display screen is currently in landscape or portrait mode, so that the resolution of the display screen is adjusted according to the change in the direction, and then the size of the second paper simulation image is adjusted according to the adjusted resolution. Specifically, in this embodiment, a monitoring code is set to update the second paper simulation image. Among them, the monitoring code is:

[0120] orientationListener=new OrientationEventListener(context)

[0121] @Override

[0122] public void onOrientationChanged(int orientation){

[0123] if(orientation==ORIENTATION_UNKNOWN){

[0124] return;}

[0125] Update the screen width and height:

[0126] screenWidth=getResources().getDisplayMetrics().widthPixels;

[0127] screenHeight=getResources().getDisplayMetrics().heightPixels;

[0128] invalidate(); / / Redraw the view}.

[0129] Step 303: Calculate a tiled grid of the second paper simulation image on the display screen according to the second pixel data of the second paper simulation image and the resolution, and draw the second paper simulation image on the display screen according to the tiled grid to generate a first eye protection image.

[0130] In this embodiment, the step mainly includes: obtaining the number of display rows of the second paper image in the display screen by calculating the ratio of the screen width to the width of the second image; and obtaining the number of display columns of the second paper image in the display screen by calculating the ratio of the screen height to the height of the second image.

[0131] Specifically, in this embodiment, before drawing the newly created second paper simulation image onto the display screen, the number of rows and columns of the complete image that can be accommodated on the display screen is first calculated, wherein the number of rows is calculated according to the width of the display screen and the width of the second paper simulation image, and the number of columns is calculated according to the length of the display screen and the length of the second paper simulation image, and a tile grid of the second paper simulation image on the display screen is generated according to the number of rows and the number of columns. Optionally, the tile grid is calculated by a code for calculating the number of rows and columns stored in the electronic whiteboard. The code for calculating the number of rows and columns is:

[0132]

[0133]

[0134] According to the above code, a tiled grid of the second paper simulation image on the display screen is outputted at the current screen resolution.

[0135] Furthermore, in order to ensure that the second paper simulation image drawn on the display screen according to the tiled grid can cover the entire display screen, in this embodiment, the direction of the display screen is monitored in real time to determine whether the display screen is currently in landscape or portrait orientation, so that the resolution of the display screen is adjusted according to the change in direction, and then the size of the second paper simulation image is adjusted according to the adjusted resolution, and then the number of image tiles and the tiled grid are recalculated according to the size of the second paper simulation image.

[0136] Step 304: monitor the display parameters of the display screen in real time, use image enhancement technology to enhance the first eye protection image, generate a second eye protection image, and display the second eye protection image on the display screen.

[0137] In this embodiment, the steps mainly include: performing anti-aliasing and filtering on the first eye protection image, and monitoring the brightness changes of the display screen in real time to obtain the current screen brightness corresponding to the display screen; adjusting the brightness of the color matrix initialized according to the screen brightness, and adjusting the blue light intensity and sharpness of the color matrix to generate a first color matrix; obtaining the color matrix filter corresponding to the first color matrix, and performing image enhancement on the first eye protection image after anti-aliasing and filtering according to the color matrix filter.

[0138] Specifically, in this embodiment, the first eye protection image is enhanced using image enhancement technology. The image enhancement technology is to turn on anti-aliasing and filtering to perform preliminary processing on the first eye protection image, then initialize the color matrix and set the initial color matrix filter, and then adjust the color matrix filter. During the adjustment process, the brightness of the color matrix initialized and set is adjusted according to the screen brightness, and the blue light intensity and sharpness of the color matrix are adjusted to generate an adjusted color matrix filter, and then the color matrix filter is applied to enhance the first eye protection image. Optionally, the first eye protection image is enhanced by running an image enhancement code in the electronic tablet. The image enhancement code is:

[0139]

[0140]

[0141] In this embodiment, the pattern details are optimized by the above-mentioned image enhancement code, and during the operation of the code, the brightness ratio is calculated to convert the integer value (ranging from 0 to 255) of the system brightness setting of the screen into a floating point number between 0 and 1, which is used to represent the relative brightness. In the process of adjusting the color matrix to reduce the blue light intensity, the ColorMatrix is ​​a tool class for processing the image color, and the ColorMatrix can change the color of the image through matrix transformation. The third row of the matrix is ​​the coefficient of the blue channel, where the blue coefficient is set to 0.8, which means that the blue intensity in the image will be reduced to 80% of the original.

[0142] Furthermore, the brightness change of the screen is monitored in real time to adjust the brightness and contrast of the pattern according to the brightness change, so that it can maintain a good display effect under different ambient light. Specifically, the brightness and contrast of the pattern are adjusted by the brightness monitoring code stored in the electronic tablet.

[0143] Among them, the brightness monitoring code is:

[0144] Monitor screen brightness changes:

[0145] brightnessObserver=new ContentObserver(new Handler()){

[0146] @Override

[0147] public void onChange(boolean selfChange,Uri uri){

[0148] super.onChange(selfChange,uri);

[0149] applyColorFilter(context);

[0150] invalidate();}};

[0151] Redraw the view:

[0152] context.getContentResolver().registerContentObserver(Settings.System.getUriFor(Settings.System.SCREEN_BRIGHTNESS),true,brightnessObserver).

[0153] In this embodiment, the brightness and details of the pattern are adjusted in real time according to the brightness of the screen through the above-mentioned pattern enhancement method and the monitoring method of the screen brightness.

[0154] The specific embodiments described above further illustrate the purpose, technical solutions and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. It is particularly pointed out that for those skilled in the art, any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of protection of the present invention.

Claims

1. An image display method providing an eye protection mode, characterized in that: include: monitoring the resolution of the display screen in real time, so as to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed; Processing the first paper image according to the scaling ratio to generate a second paper image and calculating a display layout of the second paper image on the display screen according to second pixel data of the second paper image and the resolution; Drawing the second paper image on the display screen according to the display layout to generate a first eye protection image; The display parameters of the display screen are monitored in real time, and the first eye protection image is enhanced according to the display parameters to generate a second eye protection image, and the second eye protection image is displayed on the display screen.

2. The image display method for providing an eye protection mode according to claim 1, characterized in that: The real-time monitoring of the resolution of the display screen to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed includes: By monitoring the change of the direction of the display screen in real time, the current screen direction of the display screen is obtained; the screen direction includes horizontal screen and vertical screen; Acquire the resolution of the display screen according to the screen direction; the resolution is the screen width and screen height of the display screen; Reading first pixel data of the first paper image, and acquiring a first image height and a first image width corresponding to the first paper image; comparing the screen width and the screen height, and when the screen width is less than or equal to the screen height, obtaining the scaling ratio by calculating a ratio of the screen width to a width of the first image; When the screen width is greater than the screen height, the scaling ratio is obtained by calculating the ratio of the screen height to the first image height.

3. The image display method for providing an eye protection mode according to claim 2, characterized in that: The calculating the display layout of the second paper image on the display screen according to the second pixel data and the resolution of the second paper image includes: Calculate a second image height and a second image width corresponding to the second paper image according to the scaling ratio, the first image height and the first image width; Obtaining the number of display lines of the second paper image in the display screen by calculating the ratio of the screen width to the second image width; The number of display columns of the second paper image in the display screen is obtained by calculating the ratio of the screen height to the second image height.

4. The image display method for providing an eye protection mode according to claim 3, characterized in that: Drawing the second paper image on the display screen according to the display layout to generate a first eye protection image includes: The second paper image is drawn on the display screen according to the number of display rows and the number of display columns to generate the first eye protection image.

5. The image display method for providing an eye protection mode according to claim 1, characterized in that: The real-time monitoring of the display parameters of the display screen and performing image enhancement on the first eye protection image according to the display parameters includes: Performing anti-aliasing and filtering processing on the first eye protection image, and monitoring brightness changes of the display screen in real time to obtain a current screen brightness corresponding to the display screen; Adjusting the brightness of the color matrix initially set according to the screen brightness, and adjusting the blue light intensity and sharpness of the color matrix to generate a first color matrix; A color matrix filter corresponding to the first color matrix is ​​obtained, and image enhancement is performed on the first eye protection image after anti-aliasing processing and filtering processing according to the color matrix filter.

6. An image display system providing an eye protection mode, characterized in that: It includes a ratio calculation module, an image layout module, an image drawing module and an image display module; The ratio calculation module is used to monitor the resolution of the display screen in real time, so as to calculate the zoom ratio corresponding to the first paper image according to the resolution and the first pixel data of the first paper image to be displayed; The image layout module is used to process the first paper image according to the scaling ratio, generate a second paper image, and calculate a display layout of the second paper image on the display screen according to second pixel data of the second paper image and the resolution; The image drawing module is used to draw the second paper image on the display screen according to the display layout to generate a first eye protection image; The image display module is used to monitor the display parameters of the display screen in real time, and perform image enhancement on the first eye protection image according to the display parameters to generate a second eye protection image, and display the second eye protection image on the display screen.

7. The image display system providing an eye protection mode according to claim 6, characterized in that: The ratio calculation module includes a parameter reading unit and a calculation unit; The parameter reading unit is used to obtain the current screen direction of the display screen by monitoring the direction change of the display screen in real time; the screen direction includes horizontal screen and vertical screen; obtain the resolution of the display screen according to the screen direction; the resolution is the screen width and screen height of the display screen; read the first pixel data of the first paper image, and obtain the first image height and first image width corresponding to the first paper image; The calculation unit is used to compare the screen width and the screen height. When the screen width is less than or equal to the screen height, the scaling ratio is obtained by calculating the ratio of the screen width to the first image width; when the screen width is greater than the screen height, the scaling ratio is obtained by calculating the ratio of the screen height to the first image height.

8. The image display system providing an eye protection mode according to claim 7, characterized in that: The image layout module includes a parameter updating unit and a layout unit; The parameter updating unit is used to calculate a second image height and a second image width corresponding to the second paper image according to the scaling ratio, the first image height and the first image width; The layout unit is used to obtain the number of display rows of the second paper image in the display screen by calculating the ratio of the screen width to the width of the second image; and to obtain the number of display columns of the second paper image in the display screen by calculating the ratio of the screen height to the height of the second image.

9. The image display system providing an eye protection mode according to claim 6, characterized in that: The image display module includes a monitoring unit and an image enhancement unit; The monitoring unit is used to perform anti-aliasing processing and filtering processing on the first eye protection image, and monitor the brightness change of the display screen in real time to obtain the current screen brightness corresponding to the display screen; The image enhancement unit is used to adjust the brightness of the color matrix initialized according to the screen brightness, and adjust the blue light intensity and sharpness of the color matrix to generate a first color matrix; obtain the color matrix filter corresponding to the first color matrix, and perform image enhancement on the first eye protection image after anti-aliasing and filtering according to the color matrix filter.

10. A computer-readable storage medium storing computer instructions, characterized in that: When the computer instructions are executed by the processor, an image display method for providing an eye protection mode as described in any one of claims 1 to 5 is implemented.

Citation Information

Cited By

  • Intelligent self-adaptive eye protection display system

    CN120872211A

  • Intelligent adaptive eye-care display system

    CN120872211B