View visibility detection method, apparatus, device, readable storage medium and product

CN122547438APending Publication Date: 2026-08-11BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-10
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

[0005]本公开实施例提供一种视图可见性检测方法、装置、设备、可读存储介质及产品,用于解决当前视图可见性检测方法准确性不高的技术问题

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122547438A_ABST
    Figure CN122547438A_ABST
Patent Text Reader

Abstract

The method comprises: determining a first view to be detected in a plurality of preset views associated with a display interface; determining a display area in which the first view overlaps the display interface, drawing a plurality of key points in the display area according to preset drawing parameters; for each key point, determining a second view in which a first pixel corresponding to the position of the key point is displayed in the plurality of preset views; determining a first number of key points in which the second view is the same preset view as the first view; and determining the visibility of the first view based on the first number and a second number corresponding to the plurality of key points. By detecting the visibility based on the plurality of key points, the computational complexity of the visibility detection is effectively reduced. The upper layer of the first view can be effectively determined whether it is blocked by other preset views, thereby improving the accuracy of the visibility detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of computer vision technology, and in particular to a view visibility detection method, apparatus, device, readable storage medium, and product. Background Technology

[0002] For interactive devices, multiple views often exist simultaneously. Determining the currently visible view among these multiple views becomes a pressing issue.

[0003] In related technologies, it is generally possible to determine whether a view is displayed within the screen display area by calculating the offset of the view to be detected in the root view, and to determine whether the view is hidden by determining the view's hiding parameters.

[0004] However, when using the above method to detect view visibility, it is impossible to determine whether the top of the view is covered by other views, so the visibility of the view cannot be accurately determined. Summary of the Invention

[0005] This disclosure provides a view visibility detection method, apparatus, device, readable storage medium, and product to address the technical problem of low accuracy in current view visibility detection methods.

[0006] In a first aspect, embodiments of this disclosure provide a view visibility detection method, including:

[0007] Determine the first view to be detected from among the multiple preset views associated with the display interface;

[0008] Determine the display area where the first view overlaps with the display interface, and draw multiple key points within the display area according to preset drawing parameters;

[0009] For each key point, a second view associated with the key point is determined, wherein the second view is the first preset view that displays the target pixel, and the target pixel is the pixel displayed at the display position associated with the key point;

[0010] Determine the first number of key points that make the second view and the first view the same preset view;

[0011] The visibility of the first view is determined based on the first quantity and the second quantity corresponding to the plurality of key points.

[0012] In a second aspect, embodiments of this disclosure provide a view visibility detection device, comprising:

[0013] The filtering module is used to determine the first view to be detected among multiple preset views associated with the display interface;

[0014] The drawing module is used to determine the display area where the first view overlaps with the display interface, and draw multiple key points in the display area according to preset drawing parameters;

[0015] The processing module is used to determine a second view associated with each key point, wherein the second view is a first preset view that displays a target pixel, and the target pixel is a pixel that is displayed at the display position associated with the key point.

[0016] The determining module is used to determine the first number of key points where the second view and the first view are the same preset view;

[0017] A calculation module is used to determine the visibility of the first view based on the first quantity and the second quantity corresponding to the plurality of key points.

[0018] Thirdly, embodiments of this disclosure provide an electronic device, including: a processor and a memory;

[0019] The memory stores computer-executed instructions;

[0020] The processor executes computer execution instructions stored in the memory, causing the at least one processor to perform the view visibility detection method as described in the first aspect and various possible designs of the first aspect.

[0021] Fourthly, embodiments of this disclosure provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the view visibility detection method described in the first aspect and various possible designs of the first aspect.

[0022] Fifthly, embodiments of this disclosure provide a computer program product, including a computer program that, when executed by a processor, implements the view visibility detection method as described in the first aspect and various possible designs of the first aspect.

[0023] The view visibility detection method, apparatus, device, readable storage medium, and product provided in this embodiment, after determining the first view to be detected, draws multiple key points in the display area where the first view overlaps with the display interface. This allows for accurate determination of the visibility of the first view based on the number of key points in the second view (the first pixel displaying the key point position among multiple preset views). By detecting visibility based on multiple key points, it eliminates the need to perform visibility detection on every pixel in the first view, effectively reducing the computational load. Furthermore, by detecting visibility based on the number of key points in the first view (the first pixel displaying the key point position among multiple preset views), it effectively determines whether the upper layer of the first view is occluded by other preset views, thereby improving the accuracy of visibility detection. Attached Figure Description

[0024] To more clearly illustrate the technical solutions in the embodiments of this disclosure or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0025] Figure 1 A schematic flowchart of the view visibility detection method provided in the embodiments of this disclosure;

[0026] Figure 2 A schematic diagram of multiple preset views provided for embodiments of this disclosure;

[0027] Figure 3 A schematic flowchart of a view visibility detection method provided in yet another embodiment of this disclosure;

[0028] Figure 4 This is a schematic diagram of the display area provided in an embodiment of the present disclosure;

[0029] Figure 5 A schematic flowchart of a view visibility detection method provided in yet another embodiment of this disclosure;

[0030] Figure 6 A schematic diagram of the structure of the view visibility detection device provided in the embodiments of this disclosure;

[0031] Figure 7 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure. Detailed Implementation

[0032] To make the objectives, technical solutions, and advantages of the embodiments of this disclosure clearer, the technical solutions of the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this disclosure, and not all embodiments. Based on the embodiments of this disclosure, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this disclosure.

[0033] It is understood that before using the technical solutions disclosed in the various embodiments of this disclosure, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in this disclosure in an appropriate manner in accordance with relevant laws and regulations, and user authorization should be obtained.

[0034] For example, upon receiving a user's active request, a prompt message is sent to the user to explicitly inform them that the requested operation will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the software or hardware, such as the electronic device, application, server, or storage medium performing the operations of this disclosed technical solution, based on the prompt message.

[0035] As an optional but non-limiting implementation, in response to a user's active request, sending a prompt message to the user can be done via a pop-up window, where the prompt message can be presented in text format. Furthermore, the pop-up window can also include a selection control allowing the user to choose "agree" or "disagree" to provide personal information to the electronic device.

[0036] It is understood that the above notification and user authorization process are merely illustrative and do not constitute a limitation on the implementation of this disclosure. Other methods that comply with relevant laws and regulations may also be applied to the implementation of this disclosure.

[0037] For interactive devices, detecting view visibility is a critical technology. For example, in exposure detection scenarios, it is often necessary to determine whether a certain view is exposed to the user's line of sight. Or, in compliance detection scenarios, it is necessary to identify the currently exposed view and further determine whether the display of that view is authorized by the user.

[0038] In related technologies, multiple preset layers within the display interface are managed using a tree-like stacking structure. Generally, the offset of the current view within the root view is calculated using UIKit's view tree hierarchy traversal methods to determine if the view is within the display interface. Then, methods such as `hidden` or `opaque` associated with the current view are used to determine whether the current view is hidden.

[0039] However, while the above method can determine whether a view appears within the display interface and whether it is hidden, it cannot determine whether the current view is covered by other views.

[0040] In solving the aforementioned technical problems, the inventors discovered that, to accurately detect the visibility of a view, after determining the first view to be detected, multiple key points can be drawn within the overlapping area of ​​the first view and the display interface. For each key point, a second view is determined from among multiple preset views to display the pixel at the location of that key point. The user's line of sight can directly see the pixel at the location of the key point in the second view. This allows the determination of the number of key points in the second view that constitute the current first view to be detected. Based on this number, the visibility of the first view can be accurately determined.

[0041] To address the technical problem of low accuracy in current view visibility detection methods, this disclosure provides a view visibility detection method, apparatus, device, readable storage medium, and product.

[0042] It should be noted that the view visibility detection method, apparatus, device, readable storage medium and product provided in this disclosure can be applied to any view visibility detection scenario.

[0043] Figure 1 A schematic flowchart of the view visibility detection method provided in this disclosure embodiment is shown below. Figure 1 As shown, the method includes:

[0044] Step 101: Determine the first view to be detected from among the multiple preset views associated with the display interface.

[0045] The execution entity in this embodiment is a view visibility detection device. This view visibility detection device can be coupled into a terminal device, thereby enabling the detection of the visibility of a first view among multiple preset views.

[0046] In this embodiment, the display interface is often associated with multiple preset views.

[0047] Figure 2 A schematic diagram of multiple preset views provided for embodiments of this disclosure, such as... Figure 2 As shown, the display interface is associated with multiple preset views 21, among which the display size, display shape, and display position of the different preset views 21 are different. There are occlusions and overlaps among the multiple preset views 21, so during the visibility detection process, it is necessary to determine whether there is occlusion on the upper layer of the first view.

[0048] Optionally, the first view to be detected can be determined from multiple preset views associated with the display interface according to actual needs. For example, in an exposure detection scenario, it can be determined whether the preset view associated with a certain product is visible, and thus whether the product is exposed to the user's line of sight. Therefore, the preset view associated with the product can be determined as the first view.

[0049] Step 102: Determine the display area where the first view overlaps with the display interface, and draw multiple key points within the display area according to preset drawing parameters.

[0050] In this embodiment, the user can only view the first view when it overlaps with the display interface. However, other preset views may obstruct the first view.

[0051] Therefore, in order to accurately perform the visibility detection operation, the display area that overlaps with the first view and the display interface can be determined.

[0052] In related technologies, each pixel within an overlapping display area can be visually detected to determine whether the pixel is visible. However, this often involves a large amount of computation and is inefficient in terms of visibility detection.

[0053] Therefore, in order to save computational resources while achieving visibility detection, multiple key points can be drawn within the display area according to preset drawing parameters. The visibility of the first view is determined by checking whether each key point is visible.

[0054] Step 103: For each key point, determine the second view associated with the key point, wherein the second view is the first preset view for displaying the target pixel, and the target pixel is the pixel displayed at the display position associated with the key point.

[0055] In this embodiment, for each key point, the multiple preset views can be traversed to determine the second view associated with the key point. The second view is the first preset view that displays the target pixel, and the target pixel is the pixel displayed at the display position associated with the key point. That is, the second view is the first preset view among the multiple preset views that displays the pixel at the key point's position.

[0056] Step 104: Determine the first number of key points that the second view and the first view are the same preset view.

[0057] In this embodiment, for each key point, it can be determined whether the second view associated with that key point is a first view. If the second view is a first view, it indicates that the first view is visible to the user at the key point location. Therefore, a first number of key points where the second view and the first view are the same preset view can be further determined. The larger this first number, the greater the likelihood that the first view is visible.

[0058] Step 105: Determine the visibility of the first view based on the first quantity and the second quantity corresponding to the plurality of key points.

[0059] In this embodiment, the visibility of the first view is determined based on a first quantity and a second quantity corresponding to multiple key points. The more key points in the second view that are the same preset view as the first view, the larger the visible area of ​​the first view, meaning the higher the visibility of the first view.

[0060] The view visibility detection method provided in this embodiment, after determining the first view to be detected, draws multiple key points in the display area where the first view overlaps with the display interface. This allows for accurate determination of the visibility of the first view based on the number of key points in the second view (the first pixel to display the key point position among multiple preset views). By detecting visibility based on multiple key points, it eliminates the need to perform visibility detection on every pixel in the first view, effectively reducing the computational load. Furthermore, by using the second view (the first pixel to display the key point position among multiple preset views) to detect the number of key points in the first view to be detected, it is possible to effectively determine whether the upper layer of the first view is occluded by other preset views, thereby improving the accuracy of visibility detection.

[0061] Furthermore, based on any of the above embodiments, step 105 includes:

[0062] Calculate the ratio between the first quantity and the second quantity.

[0063] In response to the ratio being greater than a preset threshold, the first view is determined to be visible.

[0064] In response to the ratio being less than a preset threshold, it is determined that the first view is not visible.

[0065] In this embodiment, in order to accurately achieve view visibility detection, a preset threshold can be set in advance. This preset threshold can be set by the user according to actual needs, or it can be a preset empirical value, for example, 30%, and this disclosure does not impose any limitations on it.

[0066] Furthermore, after determining the first quantity and the second quantity, the ratio between the first quantity and the second quantity can be calculated. This ratio is then compared with a preset threshold. The larger the ratio, the greater the visibility of the first view. If the ratio is greater than the preset threshold, the first view can be determined to be visible. Conversely, if the ratio is less than the preset threshold, the first view can be determined to be invisible.

[0067] The view visibility detection method provided in this embodiment can accurately determine whether the proportion of the area that can be viewed by the user in the first view reaches the preset threshold by comparing the ratio between the first quantity and the second quantity with the preset threshold, thereby accurately determining the visibility of the first view.

[0068] Optionally, based on any of the above embodiments, step 102 includes:

[0069] Obtain the associated parameters of the first view, wherein the associated parameters include transparency parameters and / or display parameters.

[0070] If, based on the associated parameters, it is determined that the transparency parameter of the first view is greater than a preset transparency threshold and / or the display parameter of the first view is such that the first view is added to the display interface, then the display area where the first view overlaps with the display interface is determined.

[0071] In this embodiment, the user can only view the first view when it overlaps with the display interface. If the first view and the display interface do not overlap, or if the first view is transparent, the user cannot view the first view, meaning the first view is invisible.

[0072] Therefore, after determining the first view to be detected, the associated parameters of the first view can be obtained, including transparency parameters and / or display parameters. Subsequent visibility detection operations are performed when the first view is in a displayed state and / or a non-transparent state.

[0073] Conversely, if the first view is not displayed, or if the first view is transparent, the user cannot see the first view, meaning the first view is invisible. To save computing resources, subsequent visibility detection operations can be omitted.

[0074] The view visibility detection method provided in this embodiment can effectively improve the efficiency of visibility detection by first determining whether the first view is in a display state and / or whether the first view is in a non-transparent state after determining the first view. If the first view is in a display state and / or in a non-transparent state, the next visibility detection operation is then performed.

[0075] Optionally, based on any of the above embodiments, step 102 includes:

[0076] In response to whether the display area of ​​the display region overlapping the first view and the display interface meets the preset drawing conditions, multiple key points are drawn in the display region according to the preset drawing parameters.

[0077] In this embodiment, when the overlapping display area of ​​the first view and the display interface is small, or the display area is only a narrow boundary area, even if it is visible, the user cannot see more effective content within the display area.

[0078] Therefore, to conserve computational resources during the visibility detection process, subsequent visibility detection operations can be performed after determining whether the display area of ​​the display region overlapping the first view and the display interface meets preset drawing conditions. These preset drawing conditions can be that the display area of ​​the display region is greater than a preset area threshold. Alternatively, these preset drawing conditions can be that the display area of ​​the display region is greater than a preset area threshold, and the maximum side length of the display region is less than a preset side length threshold.

[0079] The view visibility detection method provided in this embodiment performs subsequent drawing operations only when the display area of ​​the overlapping display area between the first view and the display interface reaches a preset condition. This avoids wasting computational resources caused by performing visibility detection when the display area of ​​the overlapping display area between the first view and the display interface is small, thus effectively improving the efficiency of visibility detection.

[0080] Figure 3 This is a flowchart illustrating a view visibility detection method according to yet another embodiment of this disclosure. Based on any of the above embodiments, such as... Figure 3 As shown, step 102 includes:

[0081] Step 301: Determine the boundary region within the display area based on preset boundary parameters, and determine the remaining area within the display area after removing the boundary region as the drawing area.

[0082] Step 302: Draw multiple first lines in the horizontal direction of the drawing area according to a preset pixel interval, and draw multiple second lines in the vertical direction of the drawing area according to the pixel interval.

[0083] Step 303: Determine the multiple intersection points formed by the multiple first lines and the multiple second lines as the multiple key points.

[0084] In this embodiment, there may be boundary regions within the display area where the first view overlaps with the display interface. The effective content displayed within these boundary regions is limited. Therefore, to improve the accuracy of visual detection, the boundary regions within the display area can be determined based on preset boundary parameters, and the remaining area obtained by removing the boundary regions from the display area can be defined as the drawing area. These preset boundary parameters can be parameters such as the boundary's position, length / width, etc.

[0085] Furthermore, multiple first lines can be drawn horizontally in the drawing area according to a preset pixel interval, and multiple second lines can be drawn vertically in the drawing area according to a preset pixel interval. The pixel interval can be set by the user according to actual needs, or it can be a preset empirical value; this disclosure does not impose any restrictions on this.

[0086] During the visual inspection process, the number of key points can be adjusted by adjusting the pixel interval, thereby enabling different detection granularities.

[0087] Optionally, after drawing multiple first lines and multiple second lines, the multiple intersections formed by the multiple first lines and multiple second lines can be identified as multiple key points.

[0088] Figure 4 This is a schematic diagram of the display area provided in an embodiment of the present disclosure, such as... Figure 4 As shown, there is an overlapping display area 43 between the display interface 41 and the first view 42. A boundary area 44 can be defined within the display area 43, and multiple first lines and second lines are drawn at preset pixel intervals within the drawing area 45 excluding the boundary area 44. The multiple intersection points formed by the multiple first lines and multiple second lines are defined as multiple key points 46.

[0089] The view visibility detection method provided in this embodiment removes the boundary areas of the display area during the key point drawing process, thereby ensuring that all drawn key points are within the effective display area of ​​the first view. By setting a preset pixel interval, the number of key points can be accurately controlled. Consequently, in the subsequent visibility detection process, the visibility of the first view can be accurately determined while reducing computational load.

[0090] Furthermore, based on any of the above embodiments, the drawing area includes multiple preset sub-regions, and the pixel intervals corresponding to different sub-regions are different.

[0091] The method further includes:

[0092] Determine the pixel interval corresponding to each preset sub-region.

[0093] For each preset sub-region, key point drawing operations are performed according to the pixel intervals corresponding to the preset sub-region.

[0094] In this embodiment, the first view may include multiple different preset sub-regions. For example, in a practical application, the first view may be a product display image, which may include image display areas, text display areas, video display areas, and label display areas. In an exposure detection scenario, the detection intensity varies for different preset sub-regions. For example, the focus may be on detecting whether the image display area is visible.

[0095] Therefore, the drawing area within the display area overlapping the first view and the display interface can include multiple preset sub-regions, each with different pixel intervals. Continuing the previous example, for preset sub-regions that require focused detection, the corresponding pixel interval can be smaller, resulting in a relatively larger number of key points drawn within that sub-region, thus enabling a more accurate determination of whether the sub-region is visible. Conversely, for preset sub-regions that do not require focused detection, the corresponding pixel interval can be larger, resulting in a relatively smaller number of key points drawn within that sub-region, thus saving computational resources during the visualization detection process.

[0096] Optionally, during the visualization inspection process, the pixel interval corresponding to each preset sub-region can be determined separately. For each preset sub-region, key point drawing operations are performed according to the pixel interval corresponding to the preset sub-region.

[0097] The view visibility detection method provided in this embodiment can perform more accurate visibility detection operations on important preset sub-regions by setting different pixel intervals for different preset sub-regions.

[0098] Figure 5 This is a flowchart illustrating a view visibility detection method according to yet another embodiment of this disclosure. Based on any of the above embodiments, such as... Figure 5 As shown, step 103 includes:

[0099] Step 501: For each key point, determine the third view of the current traversal according to the preset traversal order.

[0100] Step 502: In response to the inclusion of the key point in the third view, determine whether the pixel displayed at the display position corresponding to the key point is a transparent pixel.

[0101] Step 503: If not, then the third view is determined as the second view associated with the key point.

[0102] Step 504: If yes, then the current third view is determined as the preset view that has been traversed, and the process returns to the step of determining the currently traversed third view according to the preset traversal order for each key point, until the pixel displayed at the display position corresponding to the key point in the currently traversed third view is an opaque pixel, and the third view is determined as the second view associated with the key point.

[0103] In this embodiment, for each key point, the third view to be traversed can be determined according to a preset traversal order. It is then determined whether the pixels at the key point's location can be seen by the user in that third view.

[0104] Optionally, since different preset views have different display sizes and positions, not every preset view includes the key point. Therefore, it can first be determined whether the display area corresponding to the third view includes the key point. This can be determined by whether the display area corresponding to the third view and the coordinates of the key point coincide.

[0105] Furthermore, in response to the inclusion of key points in the third view, it can be further determined whether the pixels at the location of the key point can be seen by the user. Therefore, it can be determined whether the pixels displayed at the display position corresponding to the key point are transparent pixels. If so, it indicates that the user cannot see the key point. In this case, the current third view can be determined as a preset view that has already been traversed, and the steps of determining the currently traversed third view for each key point according to the preset traversal order are returned until the pixels displayed at the display position corresponding to the key point in the currently traversed third view are opaque pixels. The third view is then determined as the second view associated with the key point. Conversely, if it is determined that the pixels displayed at the display position corresponding to the key point are non-transparent pixels, the third view can be determined as the second view associated with the key point.

[0106] The view visibility detection method provided in this embodiment, by sequentially traversing each preset view according to a preset traversal order for each key point, determines the first preset view that displays the pixel position of the key point, thereby accurately determining on which preset view the key point is displayed. Furthermore, it can accurately determine whether the first view is visible based on the number of second views.

[0107] Furthermore, based on any of the above embodiments, the plurality of preset views are displayed in a tree-like stacked structure. Step 501 includes:

[0108] The third view to be traversed is determined sequentially from top to bottom among the multiple preset views.

[0109] The method further includes:

[0110] If the key point is not included in the third view, the next preset view is determined as the current third view in a top-to-bottom order.

[0111] In this embodiment, multiple preset views are displayed in a tree-like stacked structure. If the upper preset view is hidden and not transparent, the user cannot see the lower view.

[0112] Therefore, in order to accurately determine the first second view that displays the pixel position of the key point, the third view to be traversed can be determined sequentially from top to bottom among multiple preset views.

[0113] Because different preset views have different display sizes and positions, not every preset view includes the key point. For the current third view, we first determine if it includes the key point. If it does, we then determine if the pixel at the key point's location is transparent. If so, it means that the pixel corresponding to the key point is invisible to the user within the third view, so we can continue to determine the next preset view as the current third view in a top-to-bottom order. Alternatively, if we determine that the current third view does not include the key point, we continue to determine the next preset view as the current third view in a top-to-bottom order. We then continue traversing the next third view.

[0114] The view visibility detection method provided in this embodiment determines the third view currently being traversed among a plurality of preset views in a top-to-bottom order, thereby accurately determining the first second view in a tree-like stacked structure that displays the pixel at the location of the key point.

[0115] Figure 6 This is a schematic diagram of the structure of the view visibility detection device provided in the embodiments of this disclosure, as shown below. Figure 6 As shown, the device includes: a filtering module 61, a drawing module 62, a processing module 63, a determining module 64, and a calculation module 65. The filtering module 61 is used to determine a first view to be detected from multiple preset views associated with the display interface. The drawing module 62 is used to determine the display area where the first view overlaps with the display interface, and draw multiple key points within the display area according to preset drawing parameters. The processing module 63 is used to determine a second view associated with each key point, wherein the second view is the first preset view displaying a target pixel, and the target pixel is a pixel displayed at the display position associated with the key point. The determining module 64 is used to determine a first number of key points where the second view and the first view are the same preset view. The calculation module 65 is used to determine the visibility of the first view based on the first number and a second number corresponding to the multiple key points.

[0116] Further, based on any of the above embodiments, the drawing module is configured to: obtain the associated parameters of the first view, wherein the associated parameters include transparency parameters and / or display parameters. If, based on the associated parameters, it is determined that the transparency parameter of the first view is greater than a preset transparency threshold and / or the display parameter of the first view indicates that the first view should be added to the display interface, then the display area where the first view overlaps with the display interface is determined.

[0117] Furthermore, based on any of the above embodiments, the drawing module is configured to: in response to whether the display area of ​​the display area overlapping the first view and the display interface meets the preset drawing conditions, draw multiple key points in the display area according to preset drawing parameters.

[0118] Further, based on any of the above embodiments, the drawing module is configured to: determine a boundary region within the display area based on preset boundary parameters; determine the remaining area within the display area after removing the boundary region as the drawing area; draw multiple first lines in the horizontal direction of the drawing area at preset pixel intervals; and draw multiple second lines in the vertical direction of the drawing area at the same pixel intervals. The multiple intersection points formed by the multiple first lines and the multiple second lines are defined as the multiple key points.

[0119] Furthermore, based on any of the above embodiments, the drawing area includes multiple preset sub-regions, with different pixel intervals corresponding to different sub-regions. The device further includes: a determining module, used to determine the pixel interval corresponding to each preset sub-region; and a drawing module, used to perform keypoint drawing operations for each preset sub-region according to the pixel interval corresponding to the preset sub-region.

[0120] Further, based on any of the above embodiments, the processing module is configured to: determine the currently traversed third view according to a preset traversal order for each key point. In response to the third view including the key point, determine whether the pixel displayed at the display position corresponding to the key point is a transparent pixel. If not, determine the third view as the second view associated with the key point. If yes, return to the step of determining the currently traversed third view according to a preset traversal order for each key point, until the pixel displayed at the display position corresponding to the key point in the currently traversed third view is an opaque pixel, and then determine the third view as the second view associated with the key point.

[0121] Furthermore, based on any of the above embodiments, the plurality of preset views are displayed in a tree-like stacked structure. The processing module is configured to: sequentially determine the currently traversed third view among the plurality of preset views in a top-to-bottom order. The device further includes: a determining module, configured to, in response to the third view not containing the key point, determine the next preset view as the current third view in a top-to-bottom order.

[0122] Further, based on any of the above embodiments, the calculation module is configured to: calculate the ratio between the first quantity and the second quantity; determine that the first view is visible if the ratio is greater than a preset threshold; and determine that the first view is not visible if the ratio is less than the preset threshold.

[0123] The device provided in this embodiment can be used to execute the technical solutions of the above method embodiments. Its implementation principle and technical effect are similar, and will not be described again here.

[0124] To implement the above embodiments, this disclosure also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the view visibility detection method as described in any of the above embodiments.

[0125] To implement the above embodiments, this disclosure also provides a computer program product, including a computer program that, when executed by a processor, implements the view visibility detection method as described in any of the above embodiments.

[0126] To implement the above embodiments, this disclosure also provides an electronic device, including: a processor and a memory;

[0127] The memory stores computer-executed instructions;

[0128] The processor executes computer execution instructions stored in the memory, causing the processor to perform the view visibility detection method as described in any of the above embodiments.

[0129] Figure 7This is a schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure. The electronic device 700 can be a terminal device or a server. The terminal device can include, but is not limited to, mobile terminals such as mobile phones, laptops, digital broadcast receivers, personal digital assistants (PDAs), tablet computers, portable media players (PMPs), and in-vehicle terminals (such as in-vehicle navigation terminals), as well as fixed terminals such as digital TVs and desktop computers. Figure 7 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments disclosed herein.

[0130] like Figure 7 As shown, the electronic device 700 may include a processing unit (e.g., a central processing unit, a graphics processing unit, etc.) 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage device 708 into a random access memory (RAM) 703. The RAM 703 also stores various programs and data required for the operation of the electronic device 700. The processing unit 701, ROM 702, and RAM 703 are interconnected via a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.

[0131] Typically, the following devices can be connected to I / O interface 705: input devices 706 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 707 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 708 including, for example, magnetic tapes, hard disks, etc.; and communication devices 709. Communication device 709 allows electronic device 700 to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 7 An electronic device 700 with various devices is shown; however, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively.

[0132] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication device 709, or installed from storage device 708, or installed from ROM 702. When the computer program is executed by processing device 701, it performs the functions defined in the methods of embodiments of this disclosure.

[0133] It should be noted that the computer-readable medium described in this disclosure can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this disclosure, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in connection with an instruction execution system, apparatus, or device. In this disclosure, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.

[0134] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device.

[0135] The aforementioned computer-readable medium carries one or more programs, which, when executed by the electronic device, cause the electronic device to perform the methods shown in the above embodiments.

[0136] Computer program code for performing the operations of this disclosure can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, and C++, and conventional procedural programming languages ​​such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0137] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0138] The units described in the embodiments of this disclosure can be implemented in software or in hardware. The name of a unit does not necessarily limit the unit itself; for example, the first acquisition unit can also be described as "a unit that acquires at least two Internet Protocol addresses".

[0139] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: Field Programmable Gate Arrays (FPGAs), Application-Specific Integrated Circuits (ASICs), Application Standard Products (ASSPs), System-on-Chip (SoCs), Complex Programmable Logic Devices (CPLDs), and so on.

[0140] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. Machine-readable media can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0141] In a first aspect, according to one or more embodiments of this disclosure, a view visibility detection method is provided, comprising:

[0142] Determine the first view to be detected from among the multiple preset views associated with the display interface;

[0143] Determine the display area where the first view overlaps with the display interface, and draw multiple key points within the display area according to preset drawing parameters;

[0144] For each key point, a second view associated with the key point is determined, wherein the second view is the first preset view that displays the target pixel, and the target pixel is the pixel displayed at the display position associated with the key point;

[0145] Determine the first number of key points that make the second view and the first view the same preset view;

[0146] The visibility of the first view is determined based on the first quantity and the second quantity corresponding to the plurality of key points.

[0147] According to one or more embodiments of this disclosure, determining the display area where the first view overlaps with the display interface includes:

[0148] Obtain the associated parameters of the first view, wherein the associated parameters include transparency parameters and / or display parameters;

[0149] If, based on the associated parameters, it is determined that the transparency parameter of the first view is greater than a preset transparency threshold and / or the display parameter of the first view is such that the first view is added to the display interface, then the display area where the first view overlaps with the display interface is determined.

[0150] According to one or more embodiments of this disclosure, drawing multiple key points in the display area according to preset drawing parameters includes:

[0151] In response to whether the display area of ​​the display region overlapping the first view and the display interface meets the preset drawing conditions, multiple key points are drawn in the display region according to the preset drawing parameters.

[0152] According to one or more embodiments of this disclosure, drawing multiple key points in the display area according to preset drawing parameters includes:

[0153] The boundary region within the display area is determined based on preset boundary parameters, and the remaining area obtained by removing the boundary region from the display area is determined as the drawing area.

[0154] Multiple first lines are drawn in the horizontal direction of the drawing area according to a preset pixel interval, and multiple second lines are drawn in the vertical direction of the drawing area according to the same pixel interval.

[0155] The multiple intersections formed by the multiple first lines and the multiple second lines are identified as the multiple key points.

[0156] According to one or more embodiments of this disclosure, the drawing area includes multiple preset sub-regions, and the pixel intervals corresponding to different sub-regions are different;

[0157] The method further includes:

[0158] Determine the pixel interval corresponding to each preset sub-region;

[0159] For each preset sub-region, key point drawing operations are performed according to the pixel intervals corresponding to the preset sub-region.

[0160] According to one or more embodiments of this disclosure, determining the second view associated with each key point includes:

[0161] For each key point, determine the third view of the current traversal according to the preset traversal order;

[0162] In response to the inclusion of the key point in the third view, determine whether the pixel displayed at the display position corresponding to the key point is a transparent pixel;

[0163] If not, then the third view is determined to be the second view associated with the key point;

[0164] If so, return to the step of determining the third view of the current traversal according to the preset traversal order for each key point, until the pixel displayed at the display position corresponding to the key point in the current traversal third view is an opaque pixel, and determine the third view as the second view associated with the key point.

[0165] According to one or more embodiments of this disclosure, the plurality of preset views are displayed in a tree-like stacked structure; determining the third view to be traversed according to a preset traversal order includes:

[0166] The third view to be traversed is determined sequentially from top to bottom among the multiple preset views;

[0167] The method further includes:

[0168] If the key point is not included in the third view, the next preset view is determined as the current third view in a top-to-bottom order.

[0169] According to one or more embodiments of this disclosure, determining the visibility of the first view based on the first quantity and the second quantity corresponding to the plurality of key points includes:

[0170] Calculate the ratio between the first quantity and the second quantity;

[0171] In response to the ratio being greater than a preset threshold, the first view is determined to be visible;

[0172] In response to the ratio being less than a preset threshold, it is determined that the first view is not visible.

[0173] Secondly, according to one or more embodiments of this disclosure, a view visibility detection device is provided, comprising:

[0174] The filtering module is used to determine the first view to be detected among multiple preset views associated with the display interface;

[0175] The drawing module is used to determine the display area where the first view overlaps with the display interface, and draw multiple key points in the display area according to preset drawing parameters;

[0176] The processing module is used to determine a second view associated with each key point, wherein the second view is a first preset view that displays a target pixel, and the target pixel is a pixel that is displayed at the display position associated with the key point.

[0177] The determining module is used to determine the first number of key points where the second view and the first view are the same preset view;

[0178] A calculation module is used to determine the visibility of the first view based on the first quantity and the second quantity corresponding to the plurality of key points.

[0179] According to one or more embodiments of this disclosure, the drawing module is configured to:

[0180] Obtain the associated parameters of the first view, wherein the associated parameters include transparency parameters and / or display parameters;

[0181] If, based on the associated parameters, it is determined that the transparency parameter of the first view is greater than a preset transparency threshold and / or the display parameter of the first view is such that the first view is added to the display interface, then the display area where the first view overlaps with the display interface is determined.

[0182] According to one or more embodiments of this disclosure, the drawing module is configured to:

[0183] In response to whether the display area of ​​the display region overlapping the first view and the display interface meets the preset drawing conditions, multiple key points are drawn in the display region according to the preset drawing parameters.

[0184] According to one or more embodiments of this disclosure, the drawing module is configured to:

[0185] The boundary region within the display area is determined based on preset boundary parameters, and the remaining area obtained by removing the boundary region from the display area is determined as the drawing area.

[0186] Multiple first lines are drawn in the horizontal direction of the drawing area according to a preset pixel interval, and multiple second lines are drawn in the vertical direction of the drawing area according to the same pixel interval.

[0187] The multiple intersections formed by the multiple first lines and the multiple second lines are identified as the multiple key points.

[0188] According to one or more embodiments of this disclosure, the drawing area includes multiple preset sub-regions, and the pixel intervals corresponding to different sub-regions are different;

[0189] The device further includes:

[0190] The determination module is used to determine the pixel interval corresponding to each preset sub-region;

[0191] The drawing module is used to draw key points for each preset sub-region according to the pixel interval corresponding to the preset sub-region.

[0192] According to one or more embodiments of this disclosure, the processing module is configured to:

[0193] For each key point, determine the third view of the current traversal according to the preset traversal order;

[0194] In response to the inclusion of the key point in the third view, determine whether the pixel displayed at the display position corresponding to the key point is a transparent pixel;

[0195] If not, then the third view is determined to be the second view associated with the key point;

[0196] If so, return to the step of determining the third view of the current traversal according to the preset traversal order for each key point, until the pixel displayed at the display position corresponding to the key point in the current traversal third view is an opaque pixel, and determine the third view as the second view associated with the key point.

[0197] According to one or more embodiments of this disclosure, the plurality of preset views are displayed in a tree-like stacked structure; the processing module is configured to:

[0198] The third view to be traversed is determined sequentially from top to bottom among the multiple preset views;

[0199] The device further includes:

[0200] The determination module is configured to determine the next preset view as the current third view in a top-to-bottom order if the key point is not included in the third view.

[0201] According to one or more embodiments of this disclosure, the computing module is configured to:

[0202] Calculate the ratio between the first quantity and the second quantity;

[0203] In response to the ratio being greater than a preset threshold, the first view is determined to be visible;

[0204] In response to the ratio being less than a preset threshold, it is determined that the first view is not visible.

[0205] Thirdly, according to one or more embodiments of the present disclosure, an electronic device is provided, comprising: at least one processor and a memory;

[0206] The memory stores computer-executed instructions;

[0207] The at least one processor executes computer execution instructions stored in the memory, causing the at least one processor to perform the view visibility detection method as described in the first aspect and various possible designs of the first aspect.

[0208] Fourthly, according to one or more embodiments of the present disclosure, a computer-readable storage medium is provided, wherein computer-executable instructions are stored therein, and when a processor executes the computer-executable instructions, the view visibility detection method described in the first aspect and various possible designs of the first aspect is implemented.

[0209] Fifthly, according to one or more embodiments of the present disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements the view visibility detection method as described in the first aspect and various possible designs of the first aspect.

[0210] The above description is merely a preferred embodiment of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features disclosed in this disclosure that have similar functions.

[0211] Furthermore, while the operations are described in a specific order, this should not be construed as requiring these operations to be performed in the specific order shown or in a sequential order. In certain environments, multitasking and parallel processing may be advantageous. Similarly, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of this disclosure. Certain features described in the context of individual embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented individually or in any suitable sub-combination in multiple embodiments.

[0212] Although the subject matter has been described using language specific to structural features and / or methodological logic, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. Rather, the specific features and actions described above are merely illustrative examples of implementing the claims.

Claims

1. A method of view visibility detection, the method comprising: include: Determine the first view to be detected from among the multiple preset views associated with the display interface; Determine the display area where the first view overlaps with the display interface, and draw multiple key points within the display area according to preset drawing parameters; For each key point, a second view associated with the key point is determined, wherein the second view is the first preset view that displays the target pixel, and the target pixel is the pixel displayed at the display position associated with the key point; Determine the first number of key points that make the second view and the first view the same preset view; The visibility of the first view is determined based on the first quantity and the second quantity corresponding to the plurality of key points.

2. The method of claim 1, wherein, Determining the display area where the first view overlaps with the display interface includes: Obtain the associated parameters of the first view, wherein the associated parameters include transparency parameters and / or display parameters; If, based on the associated parameters, it is determined that the transparency parameter of the first view is greater than a preset transparency threshold and / or the display parameter of the first view is such that the first view is added to the display interface, then the display area where the first view overlaps with the display interface is determined.

3. The method of claim 1, wherein, The drawing of multiple key points within the display area according to preset drawing parameters includes: In response to whether the display area of ​​the display region that overlaps with the first view and the display interface meets the preset drawing conditions, multiple key points are drawn in the display region according to the preset drawing parameters.

4. The method of claim 1, wherein, The drawing of multiple key points within the display area according to preset drawing parameters includes: The boundary region within the display area is determined based on preset boundary parameters, and the remaining area obtained by removing the boundary region from the display area is determined as the drawing area. Multiple first lines are drawn in the horizontal direction of the drawing area according to a preset pixel interval, and multiple second lines are drawn in the vertical direction of the drawing area according to the same pixel interval. The multiple intersections formed by the multiple first lines and the multiple second lines are identified as the multiple key points.

5. The method of claim 4, wherein, The drawing area includes multiple preset sub-regions, and the pixel intervals corresponding to different sub-regions are different. The method further includes: Determine the pixel interval corresponding to each preset sub-region; For each preset sub-region, key point drawing operations are performed according to the pixel intervals corresponding to the preset sub-region.

6. The method of claim 1, wherein, The step of determining the second view associated with each key point includes: For each key point, determine the third view of the current traversal according to the preset traversal order; In response to the inclusion of the key point in the third view, determine whether the pixel displayed at the display position corresponding to the key point is a transparent pixel; If not, then the third view is determined to be the second view associated with the key point; If so, return to the step of determining the third view of the current traversal according to the preset traversal order for each key point, until the pixel displayed at the display position corresponding to the key point in the current traversal third view is an opaque pixel, and determine the third view as the second view associated with the key point.

7. The method of claim 6, wherein, The multiple preset views are displayed in a tree-like stacked structure; The step of determining the third view of the current traversal according to a preset traversal order includes: The third view to be traversed is determined sequentially from top to bottom among the multiple preset views; The method further includes: If the key point is not included in the third view, the next preset view is determined as the current third view in a top-to-bottom order.

8. The method according to any one of claims 1 to 7, characterized in that, Determining the visibility of the first view based on the first quantity and the second quantity corresponding to the plurality of key points includes: Calculate the ratio between the first quantity and the second quantity; In response to the ratio being greater than a preset threshold, the first view is determined to be visible; In response to the ratio being less than a preset threshold, it is determined that the first view is not visible.

9. A view visibility detection apparatus characterized by comprising: include: The filtering module is used to determine the first view to be detected among multiple preset views associated with the display interface; The drawing module is used to determine the display area where the first view overlaps with the display interface, and draw multiple key points in the display area according to preset drawing parameters; The processing module is used to determine a second view associated with each key point, wherein the second view is a first preset view that displays a target pixel, and the target pixel is a pixel that is displayed at the display position associated with the key point. The determining module is used to determine the first number of key points where the second view and the first view are the same preset view; A calculation module is used to determine the visibility of the first view based on the first quantity and the second quantity corresponding to the plurality of key points.

10. An electronic device, comprising: include: Processor and memory; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory, causing the processor to perform the view visibility detection method as described in any one of claims 1 to 8.

11. A computer readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, implement the view visibility detection method as described in any one of claims 1 to 8.

12. A computer program product comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the view visibility detection method as described in any one of claims 1 to 8.