CN117290627B - Server-side page component rendering method, system and medium - Google Patents
Server-side page component rendering method, system and medium Download PDFInfo
- Publication number
- CN117290627B CN117290627B CN202311590008.3A CN202311590008A CN117290627B CN 117290627 B CN117290627 B CN 117290627B CN 202311590008 A CN202311590008 A CN 202311590008A CN 117290627 B CN117290627 B CN 117290627B
- Authority
- CN
- China
- Prior art keywords
- information
- rendering
- page
- page component
- display area
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000009877 rendering Methods 0.000 title claims abstract description 283
- 238000000034 method Methods 0.000 title claims abstract description 50
- 230000011218 segmentation Effects 0.000 claims description 9
- 230000004927 fusion Effects 0.000 claims description 5
- 230000000694 effects Effects 0.000 abstract description 12
- 238000010586 diagram Methods 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 230000006870 function Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/957—Browsing optimisation, e.g. caching or content distillation
- G06F16/9577—Optimising the visualization of content, e.g. distillation of HTML documents
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/958—Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/30—Creation or generation of source code
- G06F8/36—Software reuse
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/30—Creation or generation of source code
- G06F8/38—Creation or generation of source code for implementing user interfaces
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Databases & Information Systems (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- Human Computer Interaction (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The embodiment of the application provides a server-side page component rendering method, a system and a medium, wherein the method comprises the following steps: acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas; acquiring access information, and generating page loading information according to the access information; calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component; matching the rendering information of the page component with the sub-region to obtain matching degree; judging whether the matching degree is larger than or equal to a preset matching degree threshold value; if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information; if the page component is smaller than the sub-region, displaying the page component in the corresponding sub-region; and the display parameters are adjusted in real time by analyzing the matching degree of the display area and the page assembly, so that the display effect of the page assembly is improved.
Description
Technical Field
The application relates to the field of page component rendering, in particular to a server-side page component rendering method, a system and a medium.
Background
The existing rendering methods such as single page component (vue, act) have the problems that SEO is poor, loading of the first page is too slow, and the existing server side rendering can solve the problems, but a tool corresponding to a corresponding frame or a corresponding server side rendering frame such as nuxt and next are needed, so that flexibility in application is lacking, and the existing single page component (vue, act) is difficult to render multiple frames at the server side at the same time, so that an effective technical solution is needed at present for the problems.
Disclosure of Invention
An object of the embodiments of the present application is to provide a method, a system, and a medium for rendering a server-side page component, which adjust display parameters in real time by analyzing a matching degree between a display area and the page component, so as to improve a display effect of the page component.
The embodiment of the application also provides a server-side page component rendering method, which comprises the following steps:
acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas;
acquiring access information, and generating page loading information according to the access information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component;
matching the rendering information of the page component with the sub-region to obtain matching degree;
judging whether the matching degree is larger than or equal to a preset matching degree threshold value;
if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information;
and if the display area is smaller than the corresponding subarea, displaying the page component in the corresponding subarea.
Optionally, in the method for rendering a server-side page component according to the embodiment of the present application, a server-side display area is obtained, and sub-area segmentation is performed according to the display area, so as to obtain a plurality of sub-areas, which specifically are:
acquiring a display area of a server side, and calculating area information of the display area;
setting page display parameters, and generating area information of a single page component according to the page realization parameters;
the method comprises the steps of performing equal area segmentation on the area information of a display area according to the area information of a single page assembly to obtain a plurality of sub-areas;
calculating the area difference of adjacent subregions, and if the area difference is smaller than a preset area threshold value, obtaining the area of each subregion;
and if the area difference is larger than a preset area threshold value, generating adjustment information, and adjusting the area information of the single page assembly according to the adjustment information.
Optionally, in the method for rendering a server-side page component according to the embodiment of the present application, access information is obtained, and page loading information is generated according to the access information, which specifically includes:
acquiring access information, and generating a page component of the access information according to the access information;
calculating a display area according to the page component;
matching the display area with the area of the subarea;
if the matching is successful, displaying the page component in the subarea;
if the matching fails, the access information is compressed, and the display area of the page component is adjusted.
Optionally, in the method for rendering a server-side page component according to the embodiment of the present application, a page component package is called according to page loading information to generate a page component, and rendering information of the page component is obtained, which specifically includes:
acquiring page loading information, and generating standard rendering information according to the page loading information;
according to the current rendering information of the display area of the server side;
comparing the current rendering information with the standard rendering information to obtain a rendering deviation rate;
if the rendering deviation rate is larger than a first rendering deviation rate threshold and smaller than a second rendering deviation rate threshold, generating first feedback information, generating a first rendering mode according to the first feedback information, and rendering a server side display area according to the first rendering mode to obtain first rendering information;
if the rendering deviation rate is larger than a second rendering deviation rate threshold value, generating second feedback information, generating a second rendering mode according to the second feedback information, and rendering a server-side display area according to the second rendering mode to obtain second rendering information;
carrying out fusion calculation on the first rendering information and the second rendering information to obtain total rendering information;
the first rendering bias ratio threshold is less than the second rendering bias ratio threshold.
Optionally, in the method for rendering a page component at a server side according to the embodiment of the present application, if the page component is greater than or equal to the page component at the server side, correction information is generated, and display parameters of the page component are adjusted according to the correction information, specifically:
acquiring display area image information, and calculating a display area gray value;
acquiring a gray value of a page component, and comparing the gray value of the page component with a preset gray value to obtain gray deviation information;
and generating rendering compensation information according to the gray scale deviation information, and compensating the rendering information according to the rendering compensation information.
Optionally, in the method for rendering a server-side page component according to the embodiment of the present application, access information is obtained, and after page loading information is generated according to the access information, the method further includes:
acquiring page loading information, and generating a plurality of single page components according to the page loading information;
integrating a plurality of single page components to form a loading package;
receiving an access request to obtain access information, generating a request path according to the access information, matching the request path with a loading packet, and configuring a single page component;
rendering information is obtained according to the single page component;
rendering the single page assembly according to the rendering information to obtain a rendering result;
if the rendering result meets the requirement, returning an access request;
and if the rendering result does not meet the requirement, adjusting the request path and adjusting the rendering information.
In a second aspect, an embodiment of the present application provides a server-side page component rendering system, including: the system comprises a memory and a processor, wherein the memory comprises a program of a server-side page component rendering method, and the program of the server-side page component rendering method realizes the following steps when being executed by the processor:
acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas;
acquiring access information, and generating page loading information according to the access information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component;
matching the rendering information of the page component with the sub-region to obtain matching degree;
judging whether the matching degree is larger than or equal to a preset matching degree threshold value;
if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information;
and if the display area is smaller than the corresponding subarea, displaying the page component in the corresponding subarea.
Optionally, in the server-side page component rendering system according to the embodiment of the present application, a server-side display area is obtained, and sub-area segmentation is performed according to the display area, so as to obtain a plurality of sub-areas, which specifically are:
acquiring a display area of a server side, and calculating area information of the display area;
setting page display parameters, and generating area information of a single page component according to the page realization parameters;
the method comprises the steps of performing equal area segmentation on the area information of a display area according to the area information of a single page assembly to obtain a plurality of sub-areas;
calculating the area difference of adjacent subregions, and if the area difference is smaller than a preset area threshold value, obtaining the area of each subregion;
and if the area difference is larger than a preset area threshold value, generating adjustment information, and adjusting the area information of the single page assembly according to the adjustment information.
Optionally, in the server-side page component rendering system described in the embodiment of the present application, access information is obtained, and page loading information is generated according to the access information, which specifically includes:
acquiring access information, and generating a page component of the access information according to the access information;
calculating a display area according to the page component;
matching the display area with the area of the subarea;
if the matching is successful, displaying the page component in the subarea;
if the matching fails, the access information is compressed, and the display area of the page component is adjusted.
In a third aspect, an embodiment of the present application further provides a computer readable storage medium, where the computer readable storage medium includes a server-side page component rendering method program, where the server-side page component rendering method program, when executed by a processor, implements the steps of the server-side page component rendering method according to any one of the foregoing embodiments.
As can be seen from the above, according to the method, the system and the medium for rendering the page component at the server provided by the embodiments of the present application, a plurality of sub-areas are obtained by obtaining a display area at the server and dividing the sub-areas according to the display area; acquiring access information, and generating page loading information according to the access information; calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component; matching the rendering information of the page component with the sub-region to obtain matching degree; judging whether the matching degree is larger than or equal to a preset matching degree threshold value; if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information; if the page component is smaller than the sub-region, displaying the page component in the corresponding sub-region; and the display parameters are adjusted in real time by analyzing the matching degree of the display area and the page assembly, so that the display effect of the page assembly is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the embodiments of the present application will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and should not be considered as limiting the scope, and other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of a server-side page component rendering method provided in an embodiment of the present application;
fig. 2 is a flowchart for adjusting a display area of a single page component in the server-side page component rendering method according to the embodiment of the present application;
fig. 3 is a flowchart of matching a display area and a sub-area of a rendering method of a server-side page component according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a server-side page component rendering system according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the drawings in the embodiments of the present application, and it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. The components of the embodiments of the present application, which are generally described and illustrated in the figures herein, may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, as provided in the accompanying drawings, is not intended to limit the scope of the application, as claimed, but is merely representative of selected embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, are intended to be within the scope of the present application.
It should be noted that like reference numerals and letters refer to like items in the following figures, and thus once an item is defined in one figure, no further definition or explanation thereof is necessary in the following figures. Meanwhile, in the description of the present application, the terms "first", "second", and the like are used only to distinguish the description, and are not to be construed as indicating or implying relative importance.
Referring to fig. 1, fig. 1 is a flowchart of a method for rendering a server-side page component according to some embodiments of the present application. The server-side page component rendering method is used in terminal equipment and comprises the following steps:
s101, acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas;
s102, access information is acquired, and page loading information is generated according to the access information;
s103, calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component;
s104, matching the rendering information of the page component with the sub-region to obtain a matching degree, and judging whether the matching degree is larger than or equal to a preset matching degree threshold value;
s105, if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information; and if the display area is smaller than the corresponding subarea, displaying the page component in the corresponding subarea.
The page assembly is generated through the page loading information, the page assembly is rendered, the rendered page assembly is displayed in the corresponding subarea, and the rendering effect is improved.
Referring to fig. 2, fig. 2 is a flow chart illustrating adjustment of display area of a single page component of a server-side page component rendering method according to some embodiments of the present application. According to the embodiment of the invention, the display area of the server side is obtained, and the subareas are segmented according to the display area to obtain a plurality of subareas, specifically:
s201, acquiring a server-side display area, and calculating area information of the display area;
s202, setting page display parameters, and generating area information of a single page component according to page realization parameters;
s203, carrying out equal area segmentation on the area information of the display area according to the area information of the single page assembly to obtain a plurality of sub-areas;
s204, calculating the area difference of the adjacent subareas, and if the area difference is smaller than a preset area threshold value, obtaining the area of each subarea;
and S205, if the area difference is larger than a preset area threshold, generating adjustment information, and adjusting the area information of the single page assembly according to the adjustment information.
It should be noted that, whether the area division of the display area is accurate is judged by the area of the single page component, and the area of the page component is adjusted, so that the page component can be completely displayed in the subareas, and when the complete display cannot be performed, the display area is secondarily divided, and the area of the display subareas is adjusted.
Referring to fig. 3, fig. 3 is a flowchart illustrating a matching of a display area and a sub-area of a rendering method of a server-side page component according to some embodiments of the present application. According to the embodiment of the invention, access information is acquired, and page loading information is generated according to the access information, specifically:
s301, access information is acquired, and a page component of the access information is generated according to the access information;
s302, calculating a display area according to the page component;
s303, matching the display area with the area of the subarea;
s304, if the matching is successful, displaying the page component in the subarea;
s305, if the matching fails, the access information is compressed, and the display area of the page component is adjusted.
It should be noted that, the page component calculates whether the display area is matched in the display process, so as to ensure that the page component can be completely displayed.
According to the embodiment of the invention, a page component package is called according to page loading information to generate a page component, and rendering information of the page component is acquired, specifically:
acquiring page loading information, and generating standard rendering information according to the page loading information;
according to the current rendering information of the display area of the server side;
comparing the current rendering information with the standard rendering information to obtain a rendering deviation rate;
if the rendering deviation rate is larger than the first rendering deviation rate threshold and smaller than the second rendering deviation rate threshold, generating first feedback information, generating a first rendering mode according to the first feedback information, and rendering a server side display area according to the first rendering mode to obtain first rendering information;
if the rendering deviation rate is larger than a second rendering deviation rate threshold value, generating second feedback information, generating a second rendering mode according to the second feedback information, and rendering the server-side display area according to the second rendering mode to obtain second rendering information;
carrying out fusion calculation on the first rendering information and the second rendering information to obtain total rendering information;
the first rendering bias ratio threshold is less than the second rendering bias ratio threshold.
It should be noted that, different feedback information is generated by analyzing the rendering deviation rate, and rendering is performed on the display area at the server end in different modes, so that the rendering effect is improved.
According to the embodiment of the invention, if the display parameters are larger than or equal to the display parameters, the display parameters of the page component are adjusted according to the correction information, and the display parameters are specifically as follows:
acquiring display area image information, and calculating a display area gray value;
acquiring a gray value of a page component, and comparing the gray value of the page component with a preset gray value to obtain gray deviation information;
and generating rendering compensation information according to the gray scale deviation information, and compensating the rendering information according to the rendering compensation information.
The display device analyzes the rendering effect by analyzing the gray level of the display area, and performs real-time compensation adjustment on the rendering information according to the rendering compensation information.
According to the embodiment of the invention, after access information is acquired and page loading information is generated according to the access information, the method further comprises the steps of:
acquiring page loading information, and generating a plurality of single page components according to the page loading information;
integrating a plurality of single page components to form a loading package;
receiving an access request to obtain access information, generating a request path according to the access information, matching the request path with a loading packet, and configuring a single page component;
rendering information is obtained according to the single page component;
rendering the single page assembly according to the rendering information to obtain a rendering result;
if the rendering result meets the requirement, returning an access request;
and if the rendering result does not meet the requirement, adjusting the request path and adjusting the rendering information.
It should be noted that, different request paths correspond to different rendering information, and the rendering result obtained by analyzing the rendering information is used to determine whether the rendering result meets the requirement, and the request path is adjusted according to the rendering result, so as to improve the rendering effect.
According to an embodiment of the present invention, further comprising:
acquiring rendering color information of a display area, and calculating resolution of the display area according to the rendering color information of the display area;
calculating the resolution of the page component according to the access information;
judging whether the resolution of the display area is matched with the resolution of the page component;
if so, rendering the page component according to the set rendering color;
and if the set information is not matched, adjusting the rendering setting information of the page component.
It should be noted that, different page component rendering setting information is different, the resolution of the page component is calculated according to the page component rendering setting information, whether the resolution of the display area meets the requirement is analyzed, and only when the resolution meets the requirement, the page component can be displayed in the display area.
Referring to fig. 4, fig. 4 is a schematic structural diagram of a server-side page component rendering system according to some embodiments of the present application. In a second aspect, embodiments of the present application provide a server-side page component rendering system 4, including: the memory 41 and the processor 42, the memory 41 includes a program of the server side page component rendering method, and when the program of the server side page component rendering method is executed by the processor, the following steps are implemented:
acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas;
acquiring access information, and generating page loading information according to the access information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component;
matching the rendering information of the page component with the sub-region to obtain matching degree;
judging whether the matching degree is larger than or equal to a preset matching degree threshold value;
if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information;
and if the display area is smaller than the corresponding subarea, displaying the page component in the corresponding subarea.
The page assembly is generated through the page loading information, the page assembly is rendered, the rendered page assembly is displayed in the corresponding subarea, and the rendering effect is improved.
According to the embodiment of the invention, the display area of the server side is obtained, and the subareas are segmented according to the display area to obtain a plurality of subareas, specifically:
acquiring a display area of a server side, and calculating area information of the display area;
setting page display parameters, and generating area information of a single page component according to the page realization parameters;
the method comprises the steps of performing equal area segmentation on the area information of a display area according to the area information of a single page assembly to obtain a plurality of sub-areas;
calculating the area difference of adjacent subregions, and if the area difference is smaller than a preset area threshold value, obtaining the area of each subregion;
and if the area difference is larger than a preset area threshold value, generating adjustment information, and adjusting the area information of the single page assembly according to the adjustment information.
It should be noted that, whether the area division of the display area is accurate is judged by the area of the single page component, and the area of the page component is adjusted, so that the page component can be completely displayed in the subareas, and when the complete display cannot be performed, the display area is secondarily divided, and the area of the display subareas is adjusted.
According to the embodiment of the invention, access information is acquired, and page loading information is generated according to the access information, specifically:
acquiring access information, and generating a page component of the access information according to the access information;
calculating a display area according to the page component;
matching the display area with the area of the subarea;
if the matching is successful, displaying the page component in the subarea;
if the matching fails, the access information is compressed, and the display area of the page component is adjusted.
It should be noted that, the page component calculates whether the display area is matched in the display process, so as to ensure that the page component can be completely displayed.
According to the embodiment of the invention, a page component package is called according to page loading information to generate a page component, and rendering information of the page component is acquired, specifically:
acquiring page loading information, and generating standard rendering information according to the page loading information;
according to the current rendering information of the display area of the server side;
comparing the current rendering information with the standard rendering information to obtain a rendering deviation rate;
if the rendering deviation rate is larger than the first rendering deviation rate threshold and smaller than the second rendering deviation rate threshold, generating first feedback information, generating a first rendering mode according to the first feedback information, and rendering a server side display area according to the first rendering mode to obtain first rendering information;
if the rendering deviation rate is larger than a second rendering deviation rate threshold value, generating second feedback information, generating a second rendering mode according to the second feedback information, and rendering the server-side display area according to the second rendering mode to obtain second rendering information;
carrying out fusion calculation on the first rendering information and the second rendering information to obtain total rendering information;
the first rendering bias ratio threshold is less than the second rendering bias ratio threshold.
It should be noted that, different feedback information is generated by analyzing the rendering deviation rate, and rendering is performed on the display area at the server end in different modes, so that the rendering effect is improved.
According to the embodiment of the invention, if the display parameters are larger than or equal to the display parameters, the display parameters of the page component are adjusted according to the correction information, and the display parameters are specifically as follows:
acquiring display area image information, and calculating a display area gray value;
acquiring a gray value of a page component, and comparing the gray value of the page component with a preset gray value to obtain gray deviation information;
and generating rendering compensation information according to the gray scale deviation information, and compensating the rendering information according to the rendering compensation information.
The display device analyzes the rendering effect by analyzing the gray level of the display area, and performs real-time compensation adjustment on the rendering information according to the rendering compensation information.
According to the embodiment of the invention, after access information is acquired and page loading information is generated according to the access information, the method further comprises the steps of:
acquiring page loading information, and generating a plurality of single page components according to the page loading information;
integrating a plurality of single page components to form a loading package;
receiving an access request to obtain access information, generating a request path according to the access information, matching the request path with a loading packet, and configuring a single page component;
rendering information is obtained according to the single page component;
rendering the single page assembly according to the rendering information to obtain a rendering result;
if the rendering result meets the requirement, returning an access request;
and if the rendering result does not meet the requirement, adjusting the request path and adjusting the rendering information.
It should be noted that, different request paths correspond to different rendering information, and the rendering result obtained by analyzing the rendering information is used to determine whether the rendering result meets the requirement, and the request path is adjusted according to the rendering result, so as to improve the rendering effect.
According to an embodiment of the present invention, further comprising:
acquiring rendering color information of a display area, and calculating resolution of the display area according to the rendering color information of the display area;
calculating the resolution of the page component according to the access information;
judging whether the resolution of the display area is matched with the resolution of the page component;
if so, rendering the page component according to the set rendering color;
and if the set information is not matched, adjusting the rendering setting information of the page component.
It should be noted that, different page component rendering setting information is different, the resolution of the page component is calculated according to the page component rendering setting information, whether the resolution of the display area meets the requirement is analyzed, and only when the resolution meets the requirement, the page component can be displayed in the display area.
A third aspect of the present invention provides a computer readable storage medium having embodied therein a server-side page component rendering method program which, when executed by a processor, implements the steps of a server-side page component rendering method as in any one of the above.
According to the rendering method, the rendering system and the rendering medium for the page component of the server, a display area of the server is obtained, and sub-area segmentation is carried out according to the display area to obtain a plurality of sub-areas; acquiring access information, and generating page loading information according to the access information; calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component; matching the rendering information of the page component with the sub-region to obtain matching degree; judging whether the matching degree is larger than or equal to a preset matching degree threshold value; if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information; if the page component is smaller than the sub-region, displaying the page component in the corresponding sub-region; real-time adjustment of display parameters is performed by analyzing the matching degree of the display area and the page component, so that the display effect of the page component is improved
In the several embodiments provided in this application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above described device embodiments are only illustrative, e.g. the division of units is only one logical function division, and there may be other divisions in actual implementation, such as: multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or not performed. In addition, the various components shown or discussed may be coupled or directly coupled or communicatively coupled to each other via some interface, whether indirectly coupled or communicatively coupled to devices or units, whether electrically, mechanically, or otherwise.
The units described above as separate components may or may not be physically separate, and components shown as units may or may not be physical units; can be located in one place or distributed to a plurality of network units; some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present invention may be integrated in one processing unit, or each unit may be separately used as one unit, or two or more units may be integrated in one unit; the integrated units may be implemented in hardware or in hardware plus software functional units.
Those of ordinary skill in the art will appreciate that: all or part of the steps for implementing the above method embodiments may be implemented by hardware related to program instructions, and the foregoing program may be stored in a readable storage medium, where the program, when executed, performs steps including the above method embodiments; and the aforementioned storage medium includes: a mobile storage device, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk or an optical disk, or the like, which can store program codes.
Alternatively, the above-described integrated units of the present invention may be stored in a readable storage medium if implemented in the form of software functional modules and sold or used as separate products. Based on such understanding, the technical solution of the embodiments of the present invention may be embodied in essence or a part contributing to the prior art in the form of a software product stored in a storage medium, including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the methods described in the embodiments of the present invention. And the aforementioned storage medium includes: a removable storage device, ROM, RAM, magnetic or optical disk, or other medium capable of storing program code.
Claims (6)
1. The method for rendering the page component at the server side is characterized by comprising the following steps:
acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas;
acquiring access information, and generating page loading information according to the access information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component;
matching the rendering information of the page component with the sub-region to obtain matching degree;
judging whether the matching degree is larger than or equal to a preset matching degree threshold value;
if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information;
if the page component is smaller than the sub-region, displaying the page component in the corresponding sub-region;
the method comprises the steps of obtaining a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas, wherein the sub-areas are specifically as follows:
acquiring a display area of a server side, and calculating area information of the display area;
setting page display parameters, and generating area information of a single page component according to the page realization parameters;
the method comprises the steps of performing equal area segmentation on the area information of a display area according to the area information of a single page assembly to obtain a plurality of sub-areas;
calculating the area difference of adjacent subregions, and if the area difference is smaller than a preset area threshold value, obtaining the area of each subregion;
if the area difference is larger than a preset area threshold value, generating adjustment information, and adjusting the area information of the single page assembly according to the adjustment information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component, wherein the rendering information comprises the following specific steps:
acquiring page loading information, and generating standard rendering information according to the page loading information;
according to the current rendering information of the display area of the server side;
comparing the current rendering information with the standard rendering information to obtain a rendering deviation rate;
if the rendering deviation rate is larger than a first rendering deviation rate threshold and smaller than a second rendering deviation rate threshold, generating first feedback information, generating a first rendering mode according to the first feedback information, and rendering a server side display area according to the first rendering mode to obtain first rendering information;
if the rendering deviation rate is larger than a second rendering deviation rate threshold value, generating second feedback information, generating a second rendering mode according to the second feedback information, and rendering a server-side display area according to the second rendering mode to obtain second rendering information;
carrying out fusion calculation on the first rendering information and the second rendering information to obtain total rendering information;
the first rendering deviation rate threshold is smaller than the second rendering deviation rate threshold;
if the display parameters are greater than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information, wherein the display parameters are specifically as follows:
acquiring display area image information, and calculating a display area gray value;
acquiring a gray value of a page component, and comparing the gray value of the page component with a preset gray value to obtain gray deviation information;
generating rendering compensation information according to the gray scale deviation information, and compensating the rendering information according to the rendering compensation information;
further comprises:
acquiring rendering color information of a display area, and calculating resolution of the display area according to the rendering color information of the display area;
calculating the resolution of the page component according to the access information;
judging whether the resolution of the display area is matched with the resolution of the page component;
if so, rendering the page component according to the set rendering color;
and if the set information is not matched, adjusting the rendering setting information of the page component.
2. The method for rendering the page component at the server side according to claim 1, wherein access information is acquired, and page loading information is generated according to the access information, specifically:
acquiring access information, and generating a page component of the access information according to the access information;
calculating a display area according to the page component;
matching the display area with the area of the subarea;
if the matching is successful, displaying the page component in the subarea;
if the matching fails, the access information is compressed, and the display area of the page component is adjusted.
3. The method for rendering the page component at the server side according to claim 2, wherein after obtaining the access information and generating the page loading information according to the access information, further comprises:
acquiring page loading information, and generating a plurality of single page components according to the page loading information;
integrating a plurality of single page components to form a loading package;
receiving an access request to obtain access information, generating a request path according to the access information, matching the request path with a loading packet, and configuring a single page component;
rendering information is obtained according to the single page component;
rendering the single page assembly according to the rendering information to obtain a rendering result;
if the rendering result meets the requirement, returning an access request;
and if the rendering result does not meet the requirement, adjusting the request path and adjusting the rendering information.
4. A server-side page component rendering system, the system comprising: the system comprises a memory and a processor, wherein the memory comprises a program of a server-side page component rendering method, and the program of the server-side page component rendering method realizes the following steps when being executed by the processor:
acquiring a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas;
acquiring access information, and generating page loading information according to the access information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component;
matching the rendering information of the page component with the sub-region to obtain matching degree;
judging whether the matching degree is larger than or equal to a preset matching degree threshold value;
if the display parameters are larger than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information;
if the page component is smaller than the sub-region, displaying the page component in the corresponding sub-region;
the method comprises the steps of obtaining a server side display area, and dividing sub-areas according to the display area to obtain a plurality of sub-areas, wherein the sub-areas are specifically as follows:
acquiring a display area of a server side, and calculating area information of the display area;
setting page display parameters, and generating area information of a single page component according to the page realization parameters;
the method comprises the steps of performing equal area segmentation on the area information of a display area according to the area information of a single page assembly to obtain a plurality of sub-areas;
calculating the area difference of adjacent subregions, and if the area difference is smaller than a preset area threshold value, obtaining the area of each subregion;
if the area difference is larger than a preset area threshold value, generating adjustment information, and adjusting the area information of the single page assembly according to the adjustment information;
calling a page component package according to page loading information to generate a page component, and acquiring rendering information of the page component, wherein the rendering information comprises the following specific steps:
acquiring page loading information, and generating standard rendering information according to the page loading information;
according to the current rendering information of the display area of the server side;
comparing the current rendering information with the standard rendering information to obtain a rendering deviation rate;
if the rendering deviation rate is larger than a first rendering deviation rate threshold and smaller than a second rendering deviation rate threshold, generating first feedback information, generating a first rendering mode according to the first feedback information, and rendering a server side display area according to the first rendering mode to obtain first rendering information;
if the rendering deviation rate is larger than a second rendering deviation rate threshold value, generating second feedback information, generating a second rendering mode according to the second feedback information, and rendering a server-side display area according to the second rendering mode to obtain second rendering information;
carrying out fusion calculation on the first rendering information and the second rendering information to obtain total rendering information;
the first rendering deviation rate threshold is smaller than the second rendering deviation rate threshold;
if the display parameters are greater than or equal to the display parameters, generating correction information, and adjusting the display parameters of the page assembly according to the correction information, wherein the display parameters are specifically as follows:
acquiring display area image information, and calculating a display area gray value;
acquiring a gray value of a page component, and comparing the gray value of the page component with a preset gray value to obtain gray deviation information;
generating rendering compensation information according to the gray scale deviation information, and compensating the rendering information according to the rendering compensation information;
further comprises:
acquiring rendering color information of a display area, and calculating resolution of the display area according to the rendering color information of the display area;
calculating the resolution of the page component according to the access information;
judging whether the resolution of the display area is matched with the resolution of the page component;
if so, rendering the page component according to the set rendering color;
and if the set information is not matched, adjusting the rendering setting information of the page component.
5. The server-side page component rendering system of claim 4, wherein access information is obtained, and page loading information is generated according to the access information, specifically:
acquiring access information, and generating a page component of the access information according to the access information;
calculating a display area according to the page component;
matching the display area with the area of the subarea;
if the matching is successful, displaying the page component in the subarea;
if the matching fails, the access information is compressed, and the display area of the page component is adjusted.
6. A computer readable storage medium, characterized in that a server-side page component rendering method program is included in the computer readable storage medium, which, when executed by a processor, implements the steps of the server-side page component rendering method according to any one of claims 1 to 3.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311590008.3A CN117290627B (en) | 2023-11-27 | 2023-11-27 | Server-side page component rendering method, system and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311590008.3A CN117290627B (en) | 2023-11-27 | 2023-11-27 | Server-side page component rendering method, system and medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN117290627A CN117290627A (en) | 2023-12-26 |
CN117290627B true CN117290627B (en) | 2024-03-08 |
Family
ID=89244880
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311590008.3A Active CN117290627B (en) | 2023-11-27 | 2023-11-27 | Server-side page component rendering method, system and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117290627B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111596998A (en) * | 2020-05-13 | 2020-08-28 | 青岛海信移动通信技术股份有限公司 | Page processing method of ink screen and terminal |
CN111767051A (en) * | 2020-06-30 | 2020-10-13 | 平安国际智慧城市科技股份有限公司 | Rendering method and device for web page |
CN111783008A (en) * | 2019-04-04 | 2020-10-16 | 百度在线网络技术(北京)有限公司 | Information display method, device, equipment and medium |
CN116610304A (en) * | 2023-07-18 | 2023-08-18 | 腾讯科技(深圳)有限公司 | Page code generation method, device, equipment and storage medium |
CN116661786A (en) * | 2023-06-06 | 2023-08-29 | 中国工商银行股份有限公司 | Design page generation method and device |
CN117115404A (en) * | 2023-09-12 | 2023-11-24 | 腾讯科技(深圳)有限公司 | Method, device, computer equipment and storage medium for three-dimensional virtual scene adjustment |
-
2023
- 2023-11-27 CN CN202311590008.3A patent/CN117290627B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111783008A (en) * | 2019-04-04 | 2020-10-16 | 百度在线网络技术(北京)有限公司 | Information display method, device, equipment and medium |
CN111596998A (en) * | 2020-05-13 | 2020-08-28 | 青岛海信移动通信技术股份有限公司 | Page processing method of ink screen and terminal |
CN111767051A (en) * | 2020-06-30 | 2020-10-13 | 平安国际智慧城市科技股份有限公司 | Rendering method and device for web page |
CN116661786A (en) * | 2023-06-06 | 2023-08-29 | 中国工商银行股份有限公司 | Design page generation method and device |
CN116610304A (en) * | 2023-07-18 | 2023-08-18 | 腾讯科技(深圳)有限公司 | Page code generation method, device, equipment and storage medium |
CN117115404A (en) * | 2023-09-12 | 2023-11-24 | 腾讯科技(深圳)有限公司 | Method, device, computer equipment and storage medium for three-dimensional virtual scene adjustment |
Also Published As
Publication number | Publication date |
---|---|
CN117290627A (en) | 2023-12-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3965431A1 (en) | Video data processing method and related device | |
CN103823620B (en) | Screen adaption method and device | |
CN110288614B (en) | Image processing method, device, equipment and storage medium | |
CN111031346B (en) | Method and device for enhancing video image quality | |
CN109977952B (en) | Candidate target detection method based on local maximum | |
CN113313083B (en) | Text detection method and device | |
CN110366001A (en) | The determination method and apparatus of video definition, storage medium, electronic device | |
CN112233049B (en) | Image fusion method for improving image definition | |
CN111881846B (en) | Image processing method, image processing apparatus, image processing device, image processing apparatus, storage medium, and computer program | |
US20080002904A1 (en) | Adaptive image sharpening method | |
CN105718254A (en) | Interface display method and device | |
CN113657370B (en) | Character recognition method and related equipment thereof | |
CN117290627B (en) | Server-side page component rendering method, system and medium | |
CN109559707B (en) | Gamma value processing method and device of display panel and display equipment | |
CN112967191A (en) | Image processing method, image processing device, electronic equipment and storage medium | |
CN113657369B (en) | Character recognition method and related equipment thereof | |
CN115797267A (en) | Image quality evaluation method, system, electronic device, and storage medium | |
CN113220909B (en) | Chart data processing method, device, electronic equipment and storage medium | |
CN111127701B (en) | Vehicle failure scene detection method and system | |
CN113886745B (en) | Page picture testing method and device and electronic equipment | |
US20140050401A1 (en) | Fast Image Processing for Recognition Objectives System | |
US9830692B2 (en) | Method and device for processing image data based on characteristic values of pixel values of pixels | |
CN110992447B (en) | Image-text adaptation method, device, storage medium and equipment | |
CN116912181B (en) | Screen uniformity detection method, system and readable storage medium | |
CN117793684B (en) | Processing method, system and medium for Bluetooth intelligent device to access APP |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |