CN106445337B - The implementation method and device of spotlight effect - Google Patents

The implementation method and device of spotlight effect Download PDF

Info

Publication number
CN106445337B
CN106445337B CN201610820578.0A CN201610820578A CN106445337B CN 106445337 B CN106445337 B CN 106445337B CN 201610820578 A CN201610820578 A CN 201610820578A CN 106445337 B CN106445337 B CN 106445337B
Authority
CN
China
Prior art keywords
transparent
transparency
region
transparent region
mouse
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
Application number
CN201610820578.0A
Other languages
Chinese (zh)
Other versions
CN106445337A (en
Inventor
薄景仁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Shiyuan Electronics Thecnology Co Ltd
Guangzhou Shirui Electronics Co Ltd
Original Assignee
Guangzhou Shiyuan Electronics Thecnology Co Ltd
Guangzhou Shirui Electronics Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Guangzhou Shiyuan Electronics Thecnology Co Ltd, Guangzhou Shirui Electronics Co Ltd filed Critical Guangzhou Shiyuan Electronics Thecnology Co Ltd
Priority to CN201610820578.0A priority Critical patent/CN106445337B/en
Publication of CN106445337A publication Critical patent/CN106445337A/en
Application granted granted Critical
Publication of CN106445337B publication Critical patent/CN106445337B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range

Abstract

The invention discloses a kind of implementation method of spotlight effect and devices.The implementation method of the spotlight effect includes: monitoring and the changing coordinates for obtaining the mouse being located in transparent pattern window;Wherein, the figure layer of the transparent pattern window is located on display area, and the size of the transparent pattern window is identical as the size of the display area;According to the changing coordinates of the mouse and preset transparent region template, corresponding transparent region is generated in the transparent pattern window;It wherein, include transparent region shape and transparent region size in the transparent region template;First transparent processing is done to the transparency of the transparent region, and the second transparent processing is done to the transparency in other regions in addition to the transparent region in the transparent pattern window, so that the transparency of the transparent region is bigger than the transparency in other regions.Using the present invention, can make to realize that the process of spotlight effect is simple, speed is fast, and the resource occupied is small.

Description

The implementation method and device of spotlight effect
Technical field
The present invention relates to field of computer technology more particularly to the implementation methods and device of a kind of spotlight effect.
Background technique
Perhaps instructor or speaker usually need when telling about some contents during speech in teaching process The core of said content is pointed out in PPT or document or display screen.Due to using laser pen or hand or mouse Mode may be too small and occur indicating unconspicuous feelings due to laser point or finger or mouse when pointing out core content Condition, to bring inconvenience to teaching or speech.By realizing the poly- effect turned off the light to mouse on computers, by mouse week The content enclosed highlights, and the content from the farther away region of mouse is weakened, to solve the problems, such as above-mentioned.
The existing method that spotlight effect is realized in display screen is by after obtaining mouse current location, to mouse The gray value of pixel around current location is divided, is calculated, and is carried out according to calculated result to these neighbor pixels What rendering was realized.Since existing method needs to carry out the division, calculating and rendering of pixel, spotlight effect is realized Process is complicated, and the speed of display is slow, and the computer resource occupied is more.
Summary of the invention
The present invention proposes the implementation method and device of a kind of spotlight effect, can make the process letter for realizing spotlight effect Single, speed is fast, and the resource occupied is small.
A kind of implementation method of spotlight effect provided by the invention, specifically includes:
Monitor and obtain the changing coordinates of the mouse in transparent pattern window;Wherein, the transparent pattern window Figure layer is located on display area, and the size of the transparent pattern window is identical as the size of the display area;
According to the changing coordinates of the mouse and preset transparent region template, phase is generated in the transparent pattern window The transparent region answered;It wherein, include transparent region shape and transparent region size in the transparent region template;
First transparent processing is done to the transparency of the transparent region, and described to removing in the transparent pattern window The transparency in other regions other than the domain of area pellucida does the second transparent processing so that the transparency of the transparent region than it is described other The transparency in region is big.
Further, it before the changing coordinates monitored and obtain the mouse in transparent pattern window, also wraps It includes:
Obtain the size of the display area in screen;
Size transparent pattern window identical with the size of the display area is created on the figure layer of the display area Mouthful.
Further, described after the changing coordinates monitored and obtain the mouse in transparent pattern window According to the changing coordinates of the mouse and preset transparent region template, generated in the transparent pattern window corresponding transparent Before region, further includes:
It monitors and obtains the mouse action in the transparent pattern window;
When judging the type of the mouse action for click action type, pre-set transparent region template number is inquired According to library, next transparent region template of the current transparent region template in the transparent region template database is obtained, and It is next transparent region template by the current transparent region template-setup;Wherein, the transparent region template number It is arranged according to the transparent region template in library according to preset sequencing.
Further, in the changing coordinates according to the mouse and preset transparent region template, described transparent After generating corresponding transparent region in pattern window, the transparency to the transparent region does the first transparent processing, and Second transparent processing is done to the transparency in other regions in addition to the transparent region in the transparent pattern window, so that Before the transparency of the transparent region is bigger than the transparency in other regions, further includes:
Record the original size of the display area;
According to the original size and preset dimension difference, to corresponding to the transparent region in the display area Destination display area carry out size enhanced processing, and to the area in addition to the destination display area in the display area Domain carries out size reduction treatment.
Further, the transparency to the transparent region does the first transparent processing, and to the transparent pattern window The transparency in other regions in addition to the transparent region in mouthful does the second transparent processing, so that the transparent region is saturating The transparency in other regions described in brightness ratio is big, specifically includes:
According to preset clear central area shape and clear central area size, the transparent region is divided, Obtain the clear central area centered on the changing coordinates of the mouse;
According to preset transparent cyclic region shape and transparent cyclic area size, in the transparent region except described Region other than clear central area is divided, at least one transparent ring centered on the changing coordinates of the mouse is obtained Shape region;
The first transparency is set by the transparency of the clear central area, and according to first transparency and is preset Adjacent area transparency difference, according to the distance between changing coordinates with the mouse by closely to remote sequence it is successively right The transparency in the transparent cyclic region is configured;
It is transparent that second is set by the transparency in the region in addition to the transparent region in the transparent pattern window Degree;Wherein, second transparency is than the distance between changing coordinates of the mouse in the transparent region more farthest The transparency in the transparent cyclic region is small.
Correspondingly, it the present invention also provides a kind of realization device of spotlight effect, specifically includes:
Mouse changing coordinates obtain module, for monitoring and obtaining the current seat of the mouse in transparent pattern window Mark;Wherein, the figure layer of the transparent pattern window is located on display area, and the size of the transparent pattern window with it is described The size of display area is identical;
Transparent region generation module, for according to the mouse changing coordinates and preset transparent region template, in institute It states in transparent pattern window and generates corresponding transparent region;Wherein, in the transparent region template include transparent region shape and Transparent region size;And
Transparency processing module does the first transparent processing for the transparency to the transparent region, and to described transparent The transparency in other regions in addition to the transparent region in pattern window does the second transparent processing, so that the clear area The transparency in domain is bigger than the transparency in other regions.
Further, the realization device of the spotlight effect, further includes:
Display area size obtains module, for obtaining the size of the display area in screen;And
Transparent pattern window creating module, for creating size and the viewing area on the figure layer of the display area The identical transparent pattern window of the size in domain.
Further, the realization device of the spotlight effect, further includes:
Mouse action obtains module, for monitoring and obtaining the mouse action in the transparent pattern window;And
Current transparent region template setup module, for working as the type for judging the mouse action for click action type When, pre-set transparent region template database is inquired, is obtained current transparent in the transparent region template database Next transparent region template of region template, and be next clear area by the current transparent region template-setup Domain template;Wherein, the transparent region template in the transparent region template database is arranged according to preset sequencing.
Further, the realization device of the spotlight effect, further includes:
Original size logging modle, for recording the original size of the display area;And
Zoom module is used for according to the original size and preset dimension difference, in the display area Destination display area corresponding to the transparent region carries out size enhanced processing, and removes the mesh in the display area It marks the region other than display area and carries out size reduction treatment.
Further, the transparency processing module, specifically includes:
Clear central area obtaining unit, for big according to preset clear central area shape and clear central area It is small, the transparent region is divided, the clear central area centered on the changing coordinates of the mouse is obtained;
Transparent cyclic region obtaining unit, for big according to preset transparent cyclic region shape and transparent cyclic region It is small, the region in addition to the clear central area in the transparent region is divided, working as with the mouse is obtained At least one transparent cyclic region centered on preceding coordinate;
First transparency setting unit, for setting the first transparency for the transparency of the clear central area, and According to the transparency difference of first transparency and preset adjacent area, between the changing coordinates according to the mouse Distance is by being closely successively configured the transparency in the transparent cyclic region to remote sequence;And
Second transparency setting unit, for by the region in addition to the transparent region in the transparent pattern window Transparency be set as the second transparency;Wherein, second transparency in the transparent region with the mouse than working as The transparency in the farthest transparent cyclic region of the distance between preceding coordinate is small.
The invention has the following beneficial effects:
The implementation method and device of spotlight effect provided by the invention, by pre-set positioned at display area The changing coordinates of mouse are obtained in transparent pattern window on figure layer, and saturating to this according to pre-set transparent region template Bright pattern window is handled, and the content around the changing coordinates of the mouse in certain area is highlighted, Light beam so as to realize spotlight is projected on screen and with the display effect of the beam ray tracing mouse, and due to the mistake Cheng Wuxu divides pixel, calculated and is rendered, therefore can make to realize that the process of spotlight effect is simple, and speed is fast, And the resource occupied is small.
Detailed description of the invention
Fig. 1 is the flow diagram of one embodiment of the implementation method of spotlight effect provided by the invention;
Fig. 2 is the structural schematic diagram of one embodiment of the realization device of spotlight effect provided by the invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
It is the flow diagram of one embodiment of the implementation method of spotlight effect provided by the invention referring to Fig. 1, packet Step S11 to S13 is included, specific as follows:
S11: monitoring and obtains the changing coordinates of the mouse in transparent pattern window;Wherein, the transparent pattern window The figure layer of mouth is located on display area, and the size of the transparent pattern window is identical as the size of the display area;
S12: raw in the transparent pattern window according to the changing coordinates of the mouse and preset transparent region template At corresponding transparent region;It wherein, include transparent region shape and transparent region size in the transparent region template;
S13: the first transparent processing is done to the transparency of the transparent region, and removes institute in the transparent pattern window The transparency for stating other regions other than transparent region does the second transparent processing, so that described in the transparency ratio of the transparent region The transparency in other regions is big.
It should be noted that changing coordinates of the embodiment of the present invention by the mouse on acquisition screen, and according to the mouse Content in certain area around the mouse is carried out intensive treatment by target changing coordinates, and will be certain around the mouse Content outside region carries out Weakening treatment, the light beam of spotlight is projected on screen and to realize with the beam ray tracing mouse Display effect so that the content in certain area around mouse is highlighted.
In a preferred embodiment, when need in the display area in device display screen partial content carry out When highlighting, a transparent pattern window is created first on the display area.Wherein, where the transparent pattern window Figure layer is on the figure layer where display area.Then, equipment is monitored and obtains working as the mouse in transparent pattern window in real time Preceding coordinate, and according to the changing coordinates of mouse and current transparent region template, it is generated in transparent pattern window corresponding saturating Area pellucida domain.Transparent region template is preset by user or administrator and is stored in equipment.In each transparent region template Including a kind of transparent region shape and corresponding transparent region size.Finally, equipment does first thoroughly to the transparency of transparent region Daylight reason, and the second transparent processing is done to other regions in addition to transparent region in transparent pattern window, so that thoroughly The transparency of transparent region in bright pattern window is bigger than the transparency in other regions so that the position in display area with it is transparent The content in the corresponding region in the position in region can highlight, and the reduction of the content in other regions in display area is aobvious Show.
For example, in Windows system, high to 1/4 screen width, 1/4 screen around the mouse in system desktop When content in the elliptic region of degree is highlighted, a transparent pattern window is created first on system desktop.With Afterwards, monitor and obtain in real time the changing coordinates of the mouse in the transparent pattern window.Then, using the figure of Windows system Correlation function in equipment interface creates one using the changing coordinates of mouse as the center of circle and long axial length in the transparent pattern window Degree is 1/4 screen width, the ellipse that half shaft length is 1/4 screen height.Finally, by the oval inner region in transparent pattern window The value of transparency be set as 1, the value of the transparency in other regions outside ellipse is set greater than 1 value, such as preferably, can set It is set to 255.In this example, when some region of transparence value be 0 when, the region be it is fully transparent, when the transparency in the region When value is 255, which is completely opaque.
By obtaining the current of mouse in the pre-set transparent pattern window on the figure layer of display area Coordinate, and the transparent pattern window is handled according to pre-set transparent region template, so that the current seat of the mouse Content in mark surrounding certain area can be highlighted, so as to realize that the light beam by spotlight is projected on screen And with the display effect of the beam ray tracing mouse, and since the process is without dividing pixel, being calculated and being rendered, It can make to realize that the process of spotlight effect is simple, speed is fast, and the resource occupied is small.
Further, it before the changing coordinates monitored and obtain the mouse in transparent pattern window, also wraps It includes:
Obtain the size of the display area in screen;
Size transparent pattern window identical with the size of the display area is created on the figure layer of the display area Mouthful.
It should be noted that when needing to highlight the partial content in the display area in device display screen When, it needs to create a transparent pattern window first on the display area.Equipment obtains the size of the display area first, And a size transparent pattern window identical with the size of the display area is created on the figure layer where display area.With Afterwards, equipment is monitored and obtains the changing coordinates of the mouse on the transparent pattern window in real time, and according to the changing coordinates of the mouse Content in certain area around mouse is highlighted.
For example, in Windows system, when needing to highlight to the partial content in system for computer desktop When, computer obtains the size of system desktop by the GetSystemMetrics function in calling system programming interface, and leads to It crosses and the CreateWindowEx function in the System Programming interface is called (wherein, to be passed to the ex_ of the CreateWindowEx function Value in style parameter is WS_EX_LAYERED, indicates that the pattern of newly created window is transparent pattern) in the system desktop A size transparent pattern window identical with the size of the system desktop is created on the figure layer at place.Then, computer is supervised Listen and obtain in real time the changing coordinates of the mouse on the transparent pattern window, and according to the changing coordinates of the mouse to mouse around Content in certain area is highlighted.
Further, described after the changing coordinates monitored and obtain the mouse in transparent pattern window According to the changing coordinates of the mouse and preset transparent region template, generated in the transparent pattern window corresponding transparent Before region, further includes:
It monitors and obtains the mouse action in the transparent pattern window;
When judging the type of the mouse action for click action type, pre-set transparent region template number is inquired According to library, next transparent region template of the current transparent region template in the transparent region template database is obtained, and It is next transparent region template by the current transparent region template-setup;Wherein, the transparent region template number It is arranged according to the transparent region template in library according to preset sequencing.
It should be noted that transparent region template database is provided in equipment, it is defeated for storing user or administrator The transparent region template for entering or generating.Wherein, it is wrapped in each transparent region template in the transparent region template database Include a kind of transparent region shape and corresponding transparent region size, and the transparent region mould in the transparent region template database Plate arranges in a certain order.Wherein, certain sequence can for generate time sequencing, the time sequencing of update or Name order etc..Equipment is monitored simultaneously after monitoring and obtaining the changing coordinates for the mouse being located in transparent pattern window in real time The mouse action of the mouse in transparent pattern window is obtained in real time.If the type of the mouse action of the mouse is click action class Type then illustrates that user clicks mouse, the transparent region template database in the equipment query equipment, and obtains the transparent region Next transparent region template of current transparent region template in template database, and current transparent region template is set It is set to next transparent region template.
For example, being stored in advance in transparent region template database in a certain equipment there are three transparent region template, by life It is respectively " equilateral triangle at chronological order;The distance between changing coordinates of each angle and mouse are 1/4 screen height ", It is " oval;Using the changing coordinates of mouse as the center of circle, and long axis length is 1/4 screen width, half shaft length is 1/4 screen height " with And " circle;Using the changing coordinates of mouse as the center of circle, and the length of radius is 100 pixels ".Assuming that current transparent region mould Plate is " equilateral triangle;The distance between changing coordinates of each angle and mouse are 1/4 screen height ".The equipment monitor and it is real When obtain the changing coordinates of the mouse being located in transparent pattern window after, monitor and obtain in real time this in transparent pattern window The mouse action of mouse.If the type of the mouse action of the mouse is click action type, saturating in the equipment query equipment Area pellucida domain template database obtains next transparent region template according to current transparent region template, i.e., " oval;With mouse Changing coordinates be the center of circle, and long axis length is 1/4 screen width, half shaft length is 1/4 screen height ", and will be current saturating Bright region template replaces with " oval;Using the changing coordinates of mouse as the center of circle, and long axis length is 1/4 screen width, half shaft length For 1/4 screen height ".When the mouse action that equipment obtains in real time again is click action, equipment is from transparent region template number It is according to the next transparent region template for obtaining current transparent region template in library, i.e., " round;It is circle with the changing coordinates of mouse The heart, and the length of radius is 100 pixels ", and current transparent region template is replaced with into " circle;With the current seat of mouse It is designated as the center of circle, and the length of radius is 100 pixels ".
Further, in the changing coordinates according to the mouse and preset transparent region template, described transparent After generating corresponding transparent region in pattern window, the transparency to the transparent region does the first transparent processing, and Second transparent processing is done to the transparency in other regions in addition to the transparent region in the transparent pattern window, so that Before the transparency of the transparent region is bigger than the transparency in other regions, further includes:
Record the original size of the display area;
According to the original size and preset dimension difference, to corresponding to the transparent region in the display area Destination display area carry out size enhanced processing, and to the area in addition to the destination display area in the display area Domain carries out size reduction treatment.
The target in display area is shown it should be noted that the present embodiment additionally uses the method amplified to content Show that the content in region is further highlighted.Wherein, in the position of destination display area and transparent pattern window The position of transparent region is corresponding.Before equipment zooms in or out processing to the content in display area, Yong Huhuo Person administrator presets the dimension difference to zoom in or out to the content in a device.In in display area Appearance zooms in or out when handling, and equipment records the original size of display area first, and according to the original difference and ruler Very little difference amplifies processing to the content in destination display area, so that the content in the destination display area is exaggerated this The size of dimension difference.At the same time, equipment also carries out ruler to the region in addition to the destination display area in display area Very little reduction treatment, so that the size of the content in the region is restored to original size.
By amplifying processing to the content in destination display area, therefore enable to the changing coordinates week of the mouse Enclosing the content in certain area can further be highlighted.
Further, the transparency to the transparent region does the first transparent processing, and to the transparent pattern window The transparency in other regions in addition to the transparent region in mouthful does the second transparent processing, so that the transparent region is saturating The transparency in other regions described in brightness ratio is big, specifically includes:
According to preset clear central area shape and clear central area size, the transparent region is divided, Obtain the clear central area centered on the changing coordinates of the mouse;
According to preset transparent cyclic region shape and transparent cyclic area size, in the transparent region except described Region other than clear central area is divided, at least one transparent ring centered on the changing coordinates of the mouse is obtained Shape region;
The first transparency is set by the transparency of the clear central area, and according to first transparency and is preset Adjacent area transparency difference, according to the distance between changing coordinates with the mouse by closely to remote sequence it is successively right The transparency in the transparent cyclic region is configured;
It is transparent that second is set by the transparency in the region in addition to the transparent region in the transparent pattern window Degree;Wherein, second transparency is than the distance between changing coordinates of the mouse in the transparent region more farthest The transparency in the transparent cyclic region is small.
It should be noted that equipment does the first transparent processing in the transparency to the transparent region in transparent pattern window When, according to pre-set clear central area shape and clear central area size, marked off in transparent in transparent region Heart district domain.Wherein, the clear central area is centered on the changing coordinates of mouse.Then, according to pre-set transparent cyclic Region shape and transparent cyclic area size carry out in the region in addition to clear central area in transparent region with mouse Division centered on changing coordinates, to be at least one transparent cyclic region by the region division.Finally, by clear central area The transparency in domain is set as the first transparency, and according to the difference of first transparency and the transparency of pre-set adjacent area Value, according to the distance between changing coordinates with mouse by closely to remote sequence successively to the transparency in each transparent cyclic region It is configured, so that the transparency in the closer transparent cyclic region of the changing coordinates apart from mouse is bigger, apart from the current of mouse The transparency in the remoter transparent cyclic region of coordinate is smaller.At the same time, equipment will also remove clear area in transparent pattern window The transparency in the region other than domain is set as the second transparency.Wherein, second transparency than in transparent region with mouse The transparency in the maximum transparent cyclic region of the distance between changing coordinates is small.
Gradual change processing is carried out by the transparency to transparent region, so that final display effect is closer to spotlight The effect of projection, therefore the content around the changing coordinates of the mouse in destination display area in certain area is enabled to obtain Display more outstanding.
The implementation method of spotlight effect provided in an embodiment of the present invention, by pre-set positioned at display area The changing coordinates of mouse are obtained in transparent pattern window on figure layer, and saturating to this according to pre-set transparent region template Bright pattern window is handled, and the content around the changing coordinates of the mouse in certain area is highlighted, Light beam so as to realize spotlight is projected on screen and with the display effect of the beam ray tracing mouse, and due to the mistake Cheng Wuxu divides pixel, calculated and is rendered, therefore can make to realize that the process of spotlight effect is simple, and speed is fast, And the resource occupied is small.In addition, by amplifying processing to the content in destination display area, therefore enable to the mouse Changing coordinates around content in certain area can further be highlighted, and by destination display area Content amplify processing, therefore enable to the content around the changing coordinates of the mouse in certain area can obtain into One step highlights.
Correspondingly, it the present invention also provides a kind of realization device of spotlight effect, can be realized poly- in above-described embodiment All processes of the implementation method of light lamp effect.
Referring to fig. 2, be spotlight effect provided by the invention realization device one embodiment structural schematic diagram, tool Body is as follows:
Mouse changing coordinates obtain module 21, for monitoring and obtaining the current seat of the mouse in transparent pattern window Mark;Wherein, the figure layer of the transparent pattern window is located on display area, and the size of the transparent pattern window with it is described The size of display area is identical;
Transparent region generation module 22, for according to the mouse changing coordinates and preset transparent region template, Corresponding transparent region is generated in the transparent pattern window;It wherein, include transparent region shape in the transparent region template With transparent region size;And
Transparency processing module 23 does the first transparent processing for the transparency to the transparent region, and to described The transparency in other regions in addition to the transparent region in bright pattern window does the second transparent processing, so that described transparent The transparency in region is bigger than the transparency in other regions.
Further, the realization device of the spotlight effect, further includes:
Display area size obtains module, for obtaining the size of the display area in screen;And
Transparent pattern window creating module, for creating size and the viewing area on the figure layer of the display area The identical transparent pattern window of the size in domain.
Further, the realization device of the spotlight effect, further includes:
Mouse action obtains module, for monitoring and obtaining the mouse action in the transparent pattern window;And
Current transparent region template setup module, for working as the type for judging the mouse action for click action type When, pre-set transparent region template database is inquired, is obtained current transparent in the transparent region template database Next transparent region template of region template, and be next clear area by the current transparent region template-setup Domain template;Wherein, the transparent region template in the transparent region template database is arranged according to preset sequencing.
Further, the realization device of the spotlight effect, further includes:
Original size logging modle, for recording the original size of the display area;And
Zoom module is used for according to the original size and preset dimension difference, in the display area Destination display area corresponding to the transparent region carries out size enhanced processing, and removes the mesh in the display area It marks the region other than display area and carries out size reduction treatment.
Further, the transparency processing module 23, specifically includes:
Clear central area obtaining unit, for big according to preset clear central area shape and clear central area It is small, the transparent region is divided, the clear central area centered on the changing coordinates of the mouse is obtained;
Transparent cyclic region obtaining unit, for big according to preset transparent cyclic region shape and transparent cyclic region It is small, the region in addition to the clear central area in the transparent region is divided, working as with the mouse is obtained At least one transparent cyclic region centered on preceding coordinate;
First transparency setting unit, for setting the first transparency for the transparency of the clear central area, and According to the transparency difference of first transparency and preset adjacent area, between the changing coordinates according to the mouse Distance is by being closely successively configured the transparency in the transparent cyclic region to remote sequence;And
Second transparency setting unit, for by the region in addition to the transparent region in the transparent pattern window Transparency be set as the second transparency;Wherein, second transparency in the transparent region with the mouse than working as The transparency in the farthest transparent cyclic region of the distance between preceding coordinate is small.
The realization device of spotlight effect provided in an embodiment of the present invention, by pre-set positioned at display area The changing coordinates of mouse are obtained in transparent pattern window on figure layer, and saturating to this according to pre-set transparent region template Bright pattern window is handled, and the content around the changing coordinates of the mouse in certain area is highlighted, Light beam so as to realize spotlight is projected on screen and with the display effect of the beam ray tracing mouse, and due to the mistake Cheng Wuxu divides pixel, calculated and is rendered, therefore can make to realize that the process of spotlight effect is simple, and speed is fast, And the resource occupied is small.In addition, by amplifying processing to the content in destination display area, therefore enable to the mouse Changing coordinates around content in certain area can further be highlighted, and by destination display area Content amplify processing, therefore enable to the content around the changing coordinates of the mouse in certain area can obtain into One step highlights.
The above is a preferred embodiment of the present invention, it is noted that for those skilled in the art For, without departing from the principle of the present invention, it can also make several improvements and retouch, these improvements and modifications are also considered as Protection scope of the present invention.

Claims (8)

1. a kind of implementation method of spotlight effect characterized by comprising
Monitor and obtain the changing coordinates of the mouse in transparent pattern window;Wherein, the figure layer of the transparent pattern window On display area, and the size of the transparent pattern window is identical as the size of the display area;
According to the changing coordinates of the mouse and preset transparent region template, generated in the transparent pattern window corresponding Transparent region;It wherein, include transparent region shape and transparent region size in the transparent region template;
First transparent processing is done to the transparency of the transparent region, and removes the clear area in the transparent pattern window The transparency in other regions other than domain does the second transparent processing, so that the transparency of the transparent region is than other described regions Transparency it is big;
Wherein, the transparency to the transparent region does the first transparent processing, and to removing in the transparent pattern window The transparency in other regions other than the transparent region does the second transparent processing, so that the transparency of the transparent region compares institute The transparency for stating other regions is big, specifically includes:
According to preset clear central area shape and clear central area size, the transparent region is divided, is obtained Clear central area centered on the changing coordinates of the mouse;
According to preset transparent cyclic region shape and transparent cyclic area size, in the transparent region except described transparent Region other than central area is divided, at least one transparent cyclic area centered on the changing coordinates of the mouse is obtained Domain;
The first transparency is set by the transparency of the clear central area, and according to first transparency and preset phase The transparency difference in neighbouring region, according to the distance between changing coordinates with the mouse by closely to remote sequence successively to described The transparency in transparent cyclic region is configured;
The second transparency is set by the transparency in the region in addition to the transparent region in the transparent pattern window;Its In, described more farthest than the distance between changing coordinates of the mouse in the transparent region of second transparency The transparency of bright annular section is small.
2. the implementation method of spotlight effect as described in claim 1, which is characterized in that in the monitoring and obtain positioned at saturating Before the changing coordinates of mouse in bright pattern window, further includes:
Obtain the size of the display area in screen;
Size transparent pattern window identical with the size of the display area is created on the figure layer of the display area.
3. the implementation method of spotlight effect as described in claim 1, which is characterized in that in the monitoring and obtain positioned at saturating After the changing coordinates of mouse in bright pattern window, the changing coordinates and preset transparent region mould according to the mouse Plate, before generating corresponding transparent region in the transparent pattern window, further includes:
It monitors and obtains the mouse action in the transparent pattern window;
When judging the type of the mouse action for click action type, pre-set transparent region template data is inquired Library obtains next transparent region template of the current transparent region template in the transparent region template database, and will The current transparent region template-setup is next transparent region template;Wherein, the transparent region template data Transparent region template in library is arranged according to preset sequencing.
4. the implementation method of spotlight effect as described in claim 1, which is characterized in that in the working as according to the mouse Preceding coordinate and preset transparent region template are described right after generating corresponding transparent region in the transparent pattern window The transparency of the transparent region does the first transparent processing, and in the transparent pattern window in addition to the transparent region The transparency in other regions do the second transparent processing so that the transparency of the transparent region is more transparent than other regions Before degree is big, further includes:
Record the original size of the display area;
According to the original size and preset dimension difference, to mesh corresponding to the transparent region in the display area Mark display area carry out size enhanced processing, and to the region in addition to the destination display area in the display area into Row size reduction treatment.
5. a kind of realization device of spotlight effect characterized by comprising
Mouse changing coordinates obtain module, for monitoring and obtaining the changing coordinates of the mouse in transparent pattern window;Its In, the figure layer of the transparent pattern window is located on display area, and the size of the transparent pattern window and the display The size in region is identical;
Transparent region generation module, for according to the mouse changing coordinates and preset transparent region template, described Corresponding transparent region is generated in bright pattern window;It wherein, include transparent region shape and transparent in the transparent region template Area size;And
Transparency processing module does the first transparent processing for the transparency to the transparent region, and to the transparent pattern The transparency in other regions in addition to the transparent region in window does the second transparent processing, so that the transparent region Transparency is bigger than the transparency in other regions;
Wherein, the transparency processing module, specifically includes:
Clear central area obtaining unit is used for according to preset clear central area shape and clear central area size, right The transparent region is divided, and the clear central area centered on the changing coordinates of the mouse is obtained;
Transparent cyclic region obtaining unit is used for according to preset transparent cyclic region shape and transparent cyclic area size, right The region in addition to the clear central area in the transparent region is divided, and is obtained with the changing coordinates of the mouse Centered at least one transparent cyclic region;
First transparency setting unit, for setting the first transparency for the transparency of the clear central area, and according to The transparency difference of first transparency and preset adjacent area, according to the distance between the changing coordinates with the mouse By being closely successively configured to remote sequence to the transparency in the transparent cyclic region;And
Second transparency setting unit, for by the saturating of the region in addition to the transparent region in the transparent pattern window Lightness is set as the second transparency;Wherein, second transparency is than the current seat with the mouse in the transparent region The transparency in the farthest transparent cyclic region of the distance between mark is small.
6. the realization device of spotlight effect as claimed in claim 5, which is characterized in that the realization of the spotlight effect fills It sets, further includes:
Display area size obtains module, for obtaining the size of the display area in screen;And
Transparent pattern window creating module, for creating size and the display area on the figure layer of the display area The identical transparent pattern window of size.
7. the realization device of spotlight effect as claimed in claim 5, which is characterized in that the realization of the spotlight effect fills It sets, further includes:
Mouse action obtains module, for monitoring and obtaining the mouse action in the transparent pattern window;And
Current transparent region template setup module, for looking into when judging the type of the mouse action for click action type Pre-set transparent region template database is ask, the current transparent region mould in the transparent region template database is obtained Next transparent region template of plate, and be next transparent region mould by the current transparent region template-setup Plate;Wherein, the transparent region template in the transparent region template database is arranged according to preset sequencing.
8. the realization device of spotlight effect as claimed in claim 5, which is characterized in that the realization of the spotlight effect fills It sets, further includes:
Original size logging modle, for recording the original size of the display area;And
Zoom module is used for according to the original size and preset dimension difference, described in the display area Destination display area corresponding to transparent region carries out size enhanced processing, and shows to the target of removing in the display area Show that the region other than region carries out size reduction treatment.
CN201610820578.0A 2016-09-13 2016-09-13 The implementation method and device of spotlight effect Active CN106445337B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610820578.0A CN106445337B (en) 2016-09-13 2016-09-13 The implementation method and device of spotlight effect

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610820578.0A CN106445337B (en) 2016-09-13 2016-09-13 The implementation method and device of spotlight effect

Publications (2)

Publication Number Publication Date
CN106445337A CN106445337A (en) 2017-02-22
CN106445337B true CN106445337B (en) 2019-06-14

Family

ID=58168779

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610820578.0A Active CN106445337B (en) 2016-09-13 2016-09-13 The implementation method and device of spotlight effect

Country Status (1)

Country Link
CN (1) CN106445337B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107340964A (en) * 2017-06-02 2017-11-10 武汉斗鱼网络科技有限公司 The animation effect implementation method and device of a kind of view
CN110597431A (en) * 2019-09-19 2019-12-20 北京科加触控技术有限公司 Display function presenting method and device
CN111208926A (en) * 2020-01-02 2020-05-29 南京巨鲨显示科技有限公司 Local focusing display method and system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102298504A (en) * 2011-09-27 2011-12-28 汉王科技股份有限公司 Method and system for magnifying display
CN102782638A (en) * 2010-03-09 2012-11-14 微软公司 Map spotlights
CN104571892A (en) * 2013-10-15 2015-04-29 北大方正集团有限公司 Method and device for displaying content

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102782638A (en) * 2010-03-09 2012-11-14 微软公司 Map spotlights
CN102298504A (en) * 2011-09-27 2011-12-28 汉王科技股份有限公司 Method and system for magnifying display
CN104571892A (en) * 2013-10-15 2015-04-29 北大方正集团有限公司 Method and device for displaying content

Also Published As

Publication number Publication date
CN106445337A (en) 2017-02-22

Similar Documents

Publication Publication Date Title
CN106445337B (en) The implementation method and device of spotlight effect
CN108279964B (en) Method and device for realizing covering layer rendering, intelligent equipment and storage medium
JP5221370B2 (en) Masking tool
CN105608319B (en) A kind of mask method and annotation equipment of digital pathological section
US11086916B2 (en) System and method for analyzing and visualizing team conversational data
JP7107354B2 (en) Information processing device, information processing method and program
CN106575291A (en) Detecting selection of digital ink
CN107545057A (en) Show method, apparatus, equipment and the storage medium of mind map
US20180004820A1 (en) An automatically invoked unified visualization interface
CN109446832A (en) A kind of screenshotss method and device
CN106157344A (en) The generation method and device of checking picture
CN110018765A (en) Page display method, device, terminal and storage medium
CN110221759A (en) A kind of element dragging method, device, storage medium and interactive intelligent tablet computer
CN107422937A (en) The method, apparatus, equipment and storage medium of color are taken on a graphical user interface
US9071520B2 (en) Spatial representation of temporal value distributions
CN104881307B (en) Download implementation method and device
CN106296129A (en) A kind of status indicator method and device
US10762116B2 (en) System and method for analyzing and visualizing team conversational data
CN110018866B (en) User interface theme updating method, device and system, vehicle machine and vehicle
CN114724170A (en) BOM generation method and device, electronic equipment and storage medium
CN108021353A (en) Generating means, method, equipment and the storage medium of the explanation document of software product
JP6526856B2 (en) 3D model cutting method and electronic device
CN112579144A (en) Data processing method and device
US20230367556A1 (en) Code Editing Tracking and Management for Vision Impaired
CN104866303A (en) Information processing method and mobile terminal

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant