CN110162728A - Determine the method, apparatus and electronic equipment of electronics scratch card scratch-off area accounting - Google Patents

Determine the method, apparatus and electronic equipment of electronics scratch card scratch-off area accounting Download PDF

Info

Publication number
CN110162728A
CN110162728A CN201910264827.6A CN201910264827A CN110162728A CN 110162728 A CN110162728 A CN 110162728A CN 201910264827 A CN201910264827 A CN 201910264827A CN 110162728 A CN110162728 A CN 110162728A
Authority
CN
China
Prior art keywords
layer
doctored
son
scratch
accounting
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.)
Granted
Application number
CN201910264827.6A
Other languages
Chinese (zh)
Other versions
CN110162728B (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.)
Advanced New Technologies Co Ltd
Advantageous New Technologies Co Ltd
Original Assignee
Alibaba Group Holding 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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201910264827.6A priority Critical patent/CN110162728B/en
Publication of CN110162728A publication Critical patent/CN110162728A/en
Application granted granted Critical
Publication of CN110162728B publication Critical patent/CN110162728B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9577Optimising the visualization of content, e.g. distillation of HTML documents
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • 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/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Human Computer Interaction (AREA)
  • Credit Cards Or The Like (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The embodiment of the present application provides the method, apparatus and electronic equipment of a kind of scratch-off area accounting of determining electronics scratch card, this method comprises: motion track of the detection finger in the figure layer to be doctored, the figure layer to be doctored includes the son figure layer to be doctored of M arranged adjacent;Determine target coverage area of the motion track in the figure layer to be doctored;Determine the quantity N of the son figure layer to be doctored of the target coverage area covering;The ratio of N and M is determined as to the scratch-off area accounting of the electronics scratch card;When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.

Description

Determine the method, apparatus and electronic equipment of electronics scratch card scratch-off area accounting
Technical field
This application involves field of computer technology more particularly to a kind of generation sides of electronics scratch card scratch-off area accounting Method, device and electronic equipment.
Background technique
The scratch card function that general application software or page end are realized, can only be by finger on touch screen screen or mouse Movement routine of the gesture on the drawing board page is marked to show the base map layer for showing result, it is unlapped in the gesture of finger or mouse Place will not be scraped off, cause to show base map layer completely;In addition the motion track of finger and mouse gestures is irregular And there are track overlapping, cause the accounting of scratch-off area to calculate relatively difficult, it is difficult to according to scraping award region scrape off ratio come The operation customized is set, such as scratch-off area reaches 80% and scrapes remainder off automatically.
Therefore, optimize the determination method of scratch-off area accounting, it is urgently to be resolved for promoting the experience of user terminal scratch card Problem.
Summary of the invention
The embodiment of the present application provides the method, apparatus and electronic equipment of a kind of determining electronics scratch card scratch-off area accounting, It is intended to optimize the calculation method of scratch-off area accounting, promotes the experience of user terminal scratch card.
In order to solve the above technical problems, the embodiment of the present application adopts the following technical solutions:
In a first aspect, providing a kind of method of determining electronics scratch card scratch-off area accounting, the electronics scratch card includes It shows the base map layer of result and covers the figure layer to be doctored of the base map layer, which comprises
Detect motion track of the finger in the figure layer to be doctored, the figure layer to be doctored include M arranged adjacent it is sub to Figure layer is scraped, M is the integer more than or equal to 2;Determine target coverage area of the motion track in the figure layer to be doctored;Really The quantity N of the son figure layer to be doctored of the fixed target coverage area covering;The ratio of N and M is determined as the electronics scratch card Scratch-off area accounting;When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
Second aspect, provides a kind of device of determining electronics scratch card scratch-off area accounting, and the scratch card includes exhibition Show the base map layer of result and cover the figure layer to be doctored of the base map layer, described device includes
Touch detection module: motion track of the detection finger in the figure layer to be doctored, the figure layer to be doctored includes M phase The son figure layer to be doctored of neighbour's arrangement, M are the integer more than or equal to 2;
Target coverage area generation module: target coverage area of the finger motion track in the figure layer to be doctored is determined Domain;
Counting module: the quantity N of the son figure layer to be doctored of the target coverage area covering is determined;
It scrapes accounting generation module off: the ratio of N and M is determined as to the scratch-off area accounting of the scratch card;
Display module: when the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
The third aspect provides a kind of electronic equipment, comprising:
Processor;And
It is arranged to the memory of storage computer executable instructions, the executable instruction makes the place when executed It manages device and executes following operation:
Detect motion track of the finger in the figure layer to be doctored, the figure layer to be doctored include M arranged adjacent it is sub to Figure layer is scraped, M is the integer more than or equal to 2;Determine target coverage area of the motion track in the figure layer to be doctored;Really The quantity N of the son figure layer to be doctored of the fixed target coverage area covering;By the ratio of N and M, it is determined as the electronics scratch card Scratch-off area accounting;When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
Fourth aspect provides a kind of computer-readable medium, the computer-readable medium storage one or more journey Sequence, one or more of programs when by include multiple application programs electronic equipment execute when so that electronic equipment execute with Lower operation:
Detect motion track of the finger in the figure layer to be doctored, the figure layer to be doctored include M arranged adjacent it is sub to Figure layer is scraped, M is the integer more than or equal to 2;Determine target coverage area of the motion track in the figure layer to be doctored;Really The quantity N of the son figure layer to be doctored of the fixed target coverage area covering;The ratio of N and M is determined as the electronics scratch card Scratch-off area accounting;When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
The embodiment of the present application use at least one above-mentioned technical solution can reach it is following the utility model has the advantages that
In the embodiment of the present application, figure layer to be doctored is divided into multiple son figure layers to be doctored, i.e., by figure layer to be doctored from Pixel-level shape Formula is converted into dot matrix graphic, to simplify the calculating of finger motion track;On the basis of simplified figure layer to be doctored, finger The calculation amount of motion track accordingly reduces, and covers according to motion track figure layer to be doctored in form, by the son to covering to Figure layer statistics is scraped, the overlapping cases of finger motion track can be ignored, the accounting for being conducive to scratch card scratch-off area calculates.
Detailed description of the invention
Attached drawing described herein is used to provide to further understand this specification, constitutes part of this application, this The illustrative embodiments and their description of specification are not constituted an undue limitation on the present application for explaining the application.In attached drawing In:
Fig. 1 is the flow diagram of the method for determining electronics scratch card scratch-off area accounting provided by the embodiments of the present application;
Fig. 2 is that the movement is determined in the method for determining electronics scratch card scratch-off area accounting provided by the embodiments of the present application The flow diagram of target coverage area of the track in the figure layer to be doctored;
Fig. 3 is by determining the mesh in the method for determining electronics scratch card scratch-off area accounting provided by the embodiments of the present application Mark the flow diagram of the quantity N of the son figure layer to be doctored of overlay area covering;
Fig. 4 is figure layer to be doctored in the method for determining electronics scratch card scratch-off area accounting provided by the embodiments of the present application and son The schematic layout pattern of figure layer to be doctored;
Fig. 5 is that each touch surface is determined in the method for determining electronics scratch card scratch-off area accounting provided by the embodiments of the present application The flow diagram of the son figure layer number to be doctored of covering;
Fig. 6 is the structural schematic diagram of the device of determining electronics scratch card scratch-off area accounting provided by the embodiments of the present application;
Fig. 7 is the structural schematic diagram of electronic equipment provided by the embodiments of the present application.
Specific embodiment
To keep the purposes, technical schemes and advantages of the application clearer, below in conjunction with the application specific embodiment and Technical scheme is clearly and completely described in corresponding attached drawing.Obviously, described embodiment is only the application one Section Example, instead of all the embodiments.Based on the embodiment in the application, those of ordinary skill in the art are not doing Every other embodiment obtained under the premise of creative work out, shall fall in the protection scope of this application.
Current electronics scratch card is a kind of structure of multi-layer image, is used to show the base map layer of result positioned at bottommost and covers The figure layer to be doctored of the base map layer is covered, the embodiment of the present application provides a kind of method of determining electronics scratch card scratch-off area accounting, It is handled by doing dot matrixed simplifying to figure layer to be doctored, figure layer to be doctored is divided into multiple son figure layers to be doctored, can be reduced to meter The occupancy of resource and memory space is calculated, the process of data processing is simplified.The idiographic flow schematic diagram of this method is as shown in Figure 1, packet Include following steps:
S101: motion track of the detection finger in the figure layer to be doctored.
To the detection of finger in the embodiment, it can be the level signal that finger generates on the touchscreen, be also possible to electricity The gesture instruction of mouse in sub- computer system;
The figure layer to be doctored of the embodiment includes the son figure layer to be doctored of M arranged adjacent, and M is the integer more than or equal to 2;
One embodiment of the graphic structure of the son figure layer to be doctored is square, is conducive to the parameter for simplifying figure layer to be doctored Setting;The graphic structure of the son figure layer to be doctored is not limited to square, can also be oval, round, trapezoidal or irregular figure One of.
S103: target coverage area of the motion track in the figure layer to be doctored is determined.
The position passed through in figure layer to be doctored of the characterization finger of motion track described in the embodiment, be finger on the touchscreen Movement routine or mouse gestures movement routine;The target coverage area be finger or mouse gestures movement routine to The projection or virtual figure layer in figure layer are scraped, two-dimensional coordinate region is mathematically shown as;
S105: the quantity N of the son figure layer to be doctored of the target coverage area covering is determined.
S107: capped son layer count N to be doctored and the ratio of the son figure layer sum M to be doctored of figure layer to be doctored are determined as The scratch-off area accounting of the electronics scratch card.
S109: when the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
As one embodiment, when the scratch-off area accounting of electronics scratch card has been determined, accounting is preset by being arranged, it is described Accounting reaches 80%, and region to be doctored is removed automatically, shows base map layer;In addition, the accounting is less than 80%, then Pop-up message mentions Show that user continues to scrape region to be doctored off;Therefore scratch-off area accounting be provided be conducive to optimization scratch card user experience.
Further, as one embodiment, the calculating of the son figure layer sum M to be doctored of the figure layer to be doctored is as follows:
Referring to the schematic layout pattern of figure layer to be doctored shown in Fig. 4 and son figure layer to be doctored, figure layer width to be doctored is set as w, Height h, reflection be the distribution situation of son figure layer to be doctored in unit area dot matrix fineness coefficient q, in the present embodiment, q is The maximal side or longest diameter of subgraph layer, the son figure layer sum M to be doctored of the figure layer to be doctored are calculated horizontal using area formula The product of son figure layer number to be doctored and longitudinal upper son figure layer number to be doctored upwards, obtains the son figure layer sum M to be doctored of figure layer to be doctored, tool Body formula is as follows:
M=((int) w/q+1) * ((int) h/q+1), wherein int is round numbers operation.
One specific embodiment of this specification as shown in Figure 2 determines the motion track in the figure layer to be doctored Target coverage area flow diagram comprising:
S1031: obtaining the position of the motion track corresponding K finger touch point, and K is just whole more than or equal to 2 Number;
S1033: position and finger width based on K finger touch point determine the touching of K finger touch point Touch face;
Specifically, setting the touch surface diameter of above-mentioned finger touch point according to illustrating for i-th of finger touch point as L, touching Touch a coordinate (pi1,pi2), touch surface generation module generates corresponding touch areal coordinate (x, y, width, height), wherein x =pi1- L/2, y=pi2- L/2, width=L, height=L.
S1035: the touch surface based on K finger touch point determines the target coverage area.
As one embodiment, the target coverage area is that the K touch surface is suitable according to the generation of finger touch point Sequence covers corresponding touch surface in figure layer to be doctored, forms the scratch-off area in figure layer to be doctored.
One specific embodiment of this specification as shown in Figure 3 determines the number of the son figure layer to be doctored of mark overlay area covering Measure the flow diagram of N comprising:
S1051: according to the corresponding coordinate in position of K finger touch point, the touch surface of K finger touch point Border circular areas coordinate and dot matrix fineness coefficient, determine the son figure layer number to be doctored of the touch surface covering of K finger touch point Amount;
S1053: the son layer count to be doctored of the touch surface covering based on K finger touch point determines the target The quantity N of the son figure layer to be doctored of overlay area covering.
Referring to Fig. 5, shown in this specification a specific embodiment because being needed in the functional effect for realizing scratch card According to the movement routine or mouse gestures movement routine of finger on the touchscreen, the figure layer struck off, user are shown to user It is the movement routine of finger or mouse gestures the case where there are approach overlappings in operation, excellent by the method for following examples Change the calculating of movement routine:
The touch surface diameter of (i-1)-th finger touch point is set as L, touch point coordinate (p(i-1)1,p(i-1)2), corresponding touching Areal coordinate (x, y, width, height) is touched, wherein x=p(i-1)1- L/2, y=p(i-1)2- L/2, width=L, height=L,
The son figure layer number to be doctored that touch surface laterally covers: (int) (width-offsetX)/q+1
It sets touch point laterally to overflow: offsetX=x%q;If offsetX > 0 at this time, offsetX=q-x% Q, wherein % is modulo operation;
The longitudinally covered son figure layer number to be doctored of touch surface: (int) (height-offsetY)/q+1
It laterally overflows touch point: offsetY=y%q;If offsetY > 0 at this time, offsetY=q-y%q;
By above touch surface laterally, the son of the longitudinally covered touch surface covering for calculating (i-1)-th finger touch point to Scrape figure layer number Ni-1And each son figure layer coordinate to be doctored.
The son figure layer to be doctored of the touch surface covering of (i-1)-th finger touch point is labeled to scrape label off.
S10551: judge that the son figure layer to be doctored of the touch surface covering of i-th of finger touch point scrapes off with the presence or absence of labeled Label;
S10555: if so, according to the quantity of the labeled son figure layer to be scraped off for scraping label off and i-th finger The quantity N of the son figure layer to be doctored of the touch surface covering of touch pointi
S10557: determine that the not labeled son for scraping label off of the touch surface covering of i-th of finger touch point is to be doctored Open the amount Δ N of figure layeri
S10553: and label, i=1 ... K are scraped off to the not labeled son for scraping label off figure layer label to be scraped off;
In addition, the son of the embodiment of the present application figure layer label to be doctored scrapes label off, it is by setting figure layer data knot to be doctored What the mode of structure body was set, specifically, the data structure includes at least the coordinate and tag identifiers of son figure layer to be doctored;
Another embodiment is also included using the coordinate for the son figure layer to be doctored for being capped touch surface to data acquisition system Mode sets label and scrapes label off.
The son layer count to be doctored that the S1053 is covered based on the touch surface of K finger touch point, determines the mesh Mark the quantity N=N of the son figure layer to be doctored of overlay area covering1+ΔN2+…+ΔNi+…+Δ NK
In addition, the method for the determination electronics scratch card scratch-off area accounting of the embodiment of the present application, further includes by the ratio of N and M Value, is determined as the scratch-off area accounting of the electronics scratch card.
In addition, S107 described in the embodiment of the present application by the son of capped son layer count N to be doctored and figure layer to be doctored to The ratio for scraping figure layer sum M is determined as the scratch-off area accounting of the electronics scratch card, further includes: if detecting, finger stops Scratch-off area accounting mobile then that the electronics scratch card is determined according to N and M.
As another embodiment, the S107 according to the son of capped son layer count N to be doctored and figure layer to be doctored to The ratio for scraping figure layer sum M is determined as the scratch-off area accounting of the electronics scratch card, further includes: with the motion track Path change and synchronous the ratio of N and M be determined as the scratch-off area accounting.
As one embodiment, can be arranged with the dot matrix fineness coefficient of antithetical phrase figure layer sum to be doctored, i.e. a fixed area Class divides how many a points, and granularity too large scale calculates error with regard to big, and the too small calculation amount of ratio just will increase, in the present embodiment, It can be arranged according to figure layer flexible in size to be doctored, select the dot matrix fineness coefficient of corresponding scale.
In order to realize label figure layer to be doctored, the coordinate of finger touch point is obtained, then further according to the corresponding touching in touch point The face of touching calculates the son figure layer number to be doctored and coordinate of current touch points covering, and caches the number of son figure layer to be doctored, and finger moves After dynamic operation, accounting is scraped off according to calculating after the son figure layer coordinate duplicate removal to be doctored of caching, to reduce to computing resource It occupies, avoids the repetition area for calculating finger motion track, and simplify the process of data processing.
Above instructions part describes the embodiment of the method for determining electronics scratch card scratch-off area accounting, Fig. 6 institute in detail Show, this specification additionally provides a kind of device of determining electronics scratch card scratch-off area accounting, which includes:
Touch detection module 601: motion track of the detection finger in the figure layer to be doctored, the figure layer to be doctored includes M The son figure layer to be doctored of a arranged adjacent, M are the integer more than or equal to 2;
Detection of the touch detection module 601 to finger in the embodiment can be the level that finger generates on the touchscreen Signal is also possible to the gesture instruction of mouse in electronic computer system;
The figure layer to be doctored of the embodiment includes the son figure layer to be doctored of M arranged adjacent, and M is the integer more than or equal to 2;
One embodiment of the graphic structure of the son figure layer to be doctored is square, is conducive to the parameter for simplifying figure layer to be doctored Setting;The graphic structure of the son figure layer to be doctored is not limited to square, can also be oval, round, trapezoidal or irregular figure One of.
Target coverage area generation module 603: determine that target of the finger motion track in the figure layer to be doctored is covered Cover area;
Target coverage area module 603 described in the embodiment obtains the motion track characterization finger in figure layer to be doctored The position of upper process is the movement routine or mouse gestures movement routine of finger on the touchscreen;The target coverage area It is projection or virtual figure layer of the movement routine of finger or mouse gestures in figure layer to be doctored, mathematically shows as two dimension Coordinates regional;
Counting module 605: the quantity N of the son figure layer to be doctored of the target coverage area covering is determined;
It scrapes accounting generation module 607 off: the ratio of N and M is determined as to the scratch-off area accounting of the scratch card;
Display module 609: when the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
As one embodiment, when the scratch-off area accounting of electronics scratch card has been determined, accounting is preset by being arranged, it is described Accounting reaches 80%, and region to be doctored is removed automatically, shows base map layer;In addition, the accounting is less than 80%, then Pop-up message mentions Show that user continues to scrape region to be doctored off;Therefore scratch-off area accounting be provided be conducive to optimization scratch card user experience.
Optionally, as one embodiment, the calculating of the son figure layer sum M to be doctored of the figure layer to be doctored is as follows:
Referring to the schematic layout pattern of figure layer to be doctored shown in Fig. 4 and son figure layer to be doctored, figure layer width to be doctored is set as w, Height h, reflection be the distribution situation of son figure layer to be doctored in unit area dot matrix fineness coefficient q, in the present embodiment, q is The maximal side or longest diameter of subgraph layer, the son figure layer sum M to be doctored of the figure layer to be doctored are calculated horizontal using area formula The product of son figure layer number to be doctored and longitudinal upper son figure layer number to be doctored upwards, obtains the son figure layer sum M to be doctored of figure layer to be doctored, tool Body formula is as follows:
M=((int) w/q+1) * ((int) h/q+1), wherein int is round numbers operation.
The target coverage area generation module 603 obtains the corresponding K of the motion track by touch detection module 601 The position of a finger touch point, K are the positive integer more than or equal to 2;
Optionally, as one embodiment, the target coverage area generation module 603 further include:
Touch surface generation module: position and finger width based on K finger touch point determine the K finger The touch surface of touch point;
Zone-accumulation module: the touch surface based on K finger touch point determines the target coverage area.
As one embodiment, the touch surface generation module illustrates by taking (i-1)-th finger touch point as an example, in setting The touch surface diameter for stating finger touch point is L, touch point coordinate (pi1,pi2), touch surface generation module generates corresponding touch surface Coordinate (x, y, width, height), wherein x=pi1- L/2, y=pi2- L/2, width=L, height=L.
As one embodiment, the zone-accumulation module is according to above-mentioned K touch surface according to the generation of finger touch point Sequentially, corresponding touch surface is covered in figure layer to be doctored, forms the scratch-off area in figure layer to be doctored.
The counting module 605 further include:
Element count module, according to the corresponding coordinate in position of K finger touch point, K finger touch point Touch surface border circular areas coordinate and dot matrix fineness coefficient, determine K finger touch point touch surface covering son to Scrape layer count;
Accumulator module, the son layer count to be doctored of the touch surface covering based on K finger touch point, determines the mesh Mark the quantity N of the son figure layer to be doctored of overlay area covering.
Because, need to be according to the movement routine of finger on the touchscreen or mouse gestures in the functional effect for realizing scratch card Movement routine shows the figure layer struck off to user, and the movement routine of finger or mouse gestures exists user in operation The case where approach is overlapped optimizes the calculating of movement routine, as one embodiment, the counting module by counting module 605 605 element count module, method, sets i and is incremented by from 1 to K according to figure 5, progress circulate operation:
The touch surface diameter of (i-1)-th finger touch point is set as L, touch point coordinate (p(i-1)1,p(i-1)2), corresponding touching Areal coordinate (x, y, width, height) is touched, wherein x=p(i-1)1- L/2, y=p(i-1)2- L/2, width=L, height=L,
The son figure layer number to be doctored that touch surface laterally covers: (int) (width-offsetX)/q+1
It sets touch point laterally to overflow: offsetX=x%q;If offsetX > 0 at this time, offsetX=q-x% Q, wherein % is modulo operation;
The longitudinally covered son figure layer number to be doctored of touch surface: (int) (height-offsetY)/q+1
It laterally overflows touch point: offsetY=y%q;If offsetY > 0 at this time, offsetY=q-y%q;
By above touch surface laterally, the son of the longitudinally covered touch surface covering for calculating (i-1)-th finger touch point to Scrape figure layer number Ni-1And each son figure layer coordinate to be doctored.
The son figure layer to be doctored of the touch surface covering of (i-1)-th finger touch point is labeled to scrape label off.
S10551: judge that the son figure layer to be doctored of the touch surface covering of i-th of finger touch point scrapes off with the presence or absence of labeled Label;
S10555: if so, according to the quantity of the labeled son figure layer to be scraped off for scraping label off and i-th finger The quantity N of the son figure layer to be doctored of the touch surface covering of touch pointi
S10557: determine that the not labeled son for scraping label off of the touch surface covering of i-th of finger touch point is to be doctored Open the amount Δ N of figure layeri
S10553: and label, i=1 ... K are scraped off to the not labeled son for scraping label off figure layer label to be scraped off;
In addition, the son of the embodiment of the present application figure layer label to be doctored scrapes label off, it is by setting figure layer data knot to be doctored What the mode of structure body was set, specifically, the data structure includes at least the coordinate and tag identifiers of son figure layer to be doctored;
Another embodiment is also included using the coordinate for the son figure layer to be doctored for being capped touch surface to data acquisition system Mode sets label and scrapes label off.
The accumulator module of the counting module 605, the son figure to be doctored of the touch surface covering based on K finger touch point Layer number determines the quantity N=N of the son figure layer to be doctored of the target coverage area covering1+Δ N2+…+ΔNi+…+ΔNK
In addition, the device of the determination electronics scratch card scratch-off area accounting of the embodiment of the present application, described to scrape accounting generation off Module 607 further include: finger stops movement if detecting, scrapes area off for what the ratio of N and M was determined as the electronics scratch card Domain accounting.
As another embodiment, accounting generation module 607 is scraped described in the embodiment of the present application off, further includes: with institute The path for stating motion track, which changes to synchronize, is determined as the scratch-off area accounting for the ratio of N and M.
As one embodiment, can be arranged with the dot matrix fineness coefficient of antithetical phrase figure layer sum to be doctored, i.e. a fixed area Class divides how many a points, and granularity too large scale calculates error with regard to big, and the too small calculation amount of ratio just will increase, in the present embodiment, It can be arranged according to figure layer flexible in size to be doctored, select the dot matrix fineness coefficient of corresponding scale.
In order to realize label figure layer to be doctored, the coordinate of finger touch point is obtained, then further according to the corresponding touching in touch point The face of touching calculates the son figure layer number to be doctored and coordinate of current touch points covering, and caches the number of son figure layer to be doctored, and finger moves After dynamic operation, accounting is scraped off according to calculating after the son figure layer coordinate duplicate removal to be doctored of caching, to reduce to computing resource It occupies, avoids the repetition area for calculating finger motion track, and simplify the process of data processing.
Fig. 7 is the structural schematic diagram of one embodiment electronic equipment of the application.Referring to FIG. 7, in hardware view, the electricity Sub- equipment includes processor, optionally further comprising internal bus, network interface, memory.Wherein, memory may be comprising interior It deposits, such as high-speed random access memory (Random-Access Memory, RAM), it is also possible to further include non-volatile memories Device (non-volatile memory), for example, at least 1 magnetic disk storage etc..Certainly, which is also possible that other Hardware required for business.
Processor, network interface and memory can be connected with each other by internal bus, which can be ISA (Industry Standard Architecture, industry standard architecture) bus, PCI (Peripheral Component Interconnect, Peripheral Component Interconnect standard) bus or EISA (Extended Industry Standard Architecture, expanding the industrial standard structure) bus etc..The bus can be divided into address bus, data/address bus, control always Line etc..Only to be indicated with a four-headed arrow in Fig. 7, it is not intended that an only bus or a type of convenient for indicating Bus.
Memory, for storing program.Specifically, program may include program code, and said program code includes calculating Machine operational order.Memory may include memory and nonvolatile memory, and provide instruction and data to processor.
Processor is from the then operation into memory of corresponding computer program is read in nonvolatile memory, in logical layer Resource presentation device is formed on face estimates device.Processor executes the program that memory is stored, and is specifically used for executing above-mentioned The step of method of electronics scratch card scratch-off area accounting is determined described in specification embodiment.
The device of determination electronics scratch card scratch-off area accounting disclosed in the above-mentioned embodiment illustrated in fig. 1 such as the application executes Method can be applied in processor, or be realized by processor.Processor may be a kind of IC chip, have signal Processing capacity.During realization, each step of the above method can pass through the integrated logic circuit of the hardware in processor Or the instruction of software form is completed.Above-mentioned processor can be general processor, including central processing unit (Central Processing Unit, CPU), network processing unit (Network Processor, NP) etc.;It can also be Digital Signal Processing Device (Digital Signal Processor, DSP), specific integrated circuit (Application Specific Integrated Circuit, ASIC), field programmable gate array (Field-Programmable Gate Array, FPGA) Either other programmable logic device, discrete gate or transistor logic, discrete hardware components.It may be implemented or execute Disclosed each method, step and logic diagram in the embodiment of the present application.General processor can be microprocessor or this at Reason device is also possible to any conventional processor etc..The step of method in conjunction with disclosed in the embodiment of the present application, can directly embody Execute completion for hardware decoding processor, or in decoding processor hardware and software module combination execute completion.Software Module can be located at random access memory, flash memory, read-only memory, programmable read only memory or electrically erasable programmable storage In the storage medium of this fields such as device, register maturation.The storage medium is located at memory, and processor reads the letter in memory Breath completes the step of method of electronics scratch card scratch-off area accounting is determined described in description above embodiment in conjunction with its hardware.
The electronic equipment can also carry out the method for determining that the device of electronics scratch card scratch-off area accounting executes in Fig. 1, and Realize the function of determining the device embodiment shown in Fig. 1 of electronics scratch card scratch-off area accounting, the embodiment of the present application is herein not It repeats again.
The embodiment of the present application also proposed a kind of computer readable storage medium, the computer-readable recording medium storage one A or multiple programs, the one or more program include instruction, which holds when by the electronic equipment including multiple application programs When row, the electronic equipment can be made to execute and determine that the device of electronics scratch card scratch-off area accounting executes in embodiment illustrated in fig. 1 Method, and be specifically used for executing this specification being described above and determine electronics scratch card scratch-off area accounting described in book embodiment The operation of method.
It should be understood by those skilled in the art that, embodiments herein can provide as method, system or computer program Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the application Apply the form of example.Moreover, it wherein includes the computer of computer usable program code that the application, which can be used in one or more, The computer program implemented in usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) produces The form of product.
The application is referring to method, the process of equipment (system) and computer program product according to the embodiment of the present application Figure and/or block diagram describe.It should be understood that can be realized by computer program instructions each in flowchart and/or the block diagram The combination of process and/or box in process and/or box and flowchart and/or the block diagram.It can provide these computer journeys Sequence instruct to general purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices processor with A machine is generated, so that the instruction generation executed by computer or the processor of other programmable data processing devices is used for Realize the dress for the function of specifying in one or more flows of the flowchart and/or one or more blocks of the block diagram It sets.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates, Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one The step of function of being specified in a box or multiple boxes.
In a typical configuration, calculating equipment includes one or more processors (CPU), input/output interface, net Network interface and memory.
Memory may include the non-volatile memory in computer-readable medium, random access memory (RAM) and/ Or the forms such as Nonvolatile memory, such as read-only memory (ROM) or flash memory (flash RAM).Memory is computer-readable medium Example.
Computer-readable medium includes permanent and non-permanent, removable and non-removable media can be by any method Or technology come realize information store.Information can be computer readable instructions, data structure, the module of program or other data. The example of the storage medium of computer include, but are not limited to phase change memory (PRAM), static random access memory (SRAM), Dynamic random access memory (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electrically erasable Except programmable read only memory (EEPROM), flash memory or other memory techniques, read-only disc read only memory (CD-ROM) (CD- ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, tape magnetic disk storage or other magnetism are deposited Equipment or any other non-transmission medium are stored up, can be used for storage can be accessed by a computing device information.According to boundary herein Fixed, computer-readable medium does not include temporary computer readable media (transitory media), such as the data-signal of modulation and Carrier wave.
It should also be noted that, the terms "include", "comprise" or its any other variant are intended to nonexcludability It include so that the process, method, commodity or the equipment that include a series of elements not only include those elements, but also to wrap Include other elements that are not explicitly listed, or further include for this process, method, commodity or equipment intrinsic want Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including described want There is also other identical elements in the process, method of element, commodity or equipment.
It will be understood by those skilled in the art that embodiments herein can provide as method, system or computer program product. Therefore, complete hardware embodiment, complete software embodiment or embodiment combining software and hardware aspects can be used in the application Form.It is deposited moreover, the application can be used to can be used in the computer that one or more wherein includes computer usable program code The shape for the computer program product implemented on storage media (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) Formula.
The above description is only an example of the present application, is not intended to limit this application.For those skilled in the art For, various changes and changes are possible in this application.All any modifications made within the spirit and principles of the present application are equal Replacement, improvement etc., should be included within the scope of the claims of this application.

Claims (10)

1. a kind of method of determining electronics scratch card scratch-off area accounting, the electronics scratch card includes the base map layer for showing result With the figure layer to be doctored for covering the base map layer, which comprises
Motion track of the finger in the figure layer to be doctored is detected, the figure layer to be doctored includes the son figure to be doctored of M arranged adjacent Layer, M are the integer more than or equal to 2;
Determine target coverage area of the motion track in the figure layer to be doctored;
Determine the quantity N of the son figure layer to be doctored of the target coverage area covering;
The ratio of N and M is determined as to the scratch-off area accounting of the electronics scratch card;
When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
2. according to the method described in claim 1, target coverage of the determination motion track in the figure layer to be doctored Region, comprising:
The position of the motion track corresponding K finger touch point is obtained, K is the positive integer more than or equal to 2;
Position and finger width based on K finger touch point, determine the touch surface of K finger touch point;
Based on the touch surface of K finger touch point, the target coverage area is determined.
3. according to the method described in claim 2, the quantity of the son figure layer to be doctored of the determination target coverage area covering N, comprising:
According to the corresponding coordinate in position of K finger touch point, the border circular areas of the touch surface of K finger touch point Coordinate and dot matrix fineness coefficient determine the son layer count to be doctored of the touch surface covering of K finger touch point;
The son layer count to be doctored of touch surface covering based on K finger touch point, determines that the target coverage area is covered The quantity N of the son figure layer to be doctored of lid.
4. according to the method described in claim 3, the son figure layer to be doctored that the touch surface of the finger touch point covers is labeled and scrapes Opening of bid label, the method also includes:
Judge that the son figure layer to be doctored of the touch surface covering of i-th of finger touch point scrapes label off with the presence or absence of labeled;
If so, according to the touch of the quantity of the labeled son figure layer to be scraped off for scraping label off and i-th of finger touch point The quantity of the son figure layer to be doctored of face covering determines that the not labeled of the touch surface covering of i-th of finger touch point scrapes opening of bid The quantity of the son figure layer to be scraped off of label, and label, i=1 ... are scraped off to the not labeled son for scraping label off figure layer label to be scraped off K;
Wherein, the son layer count to be doctored of the touch surface covering based on K finger touch point, determines that the target is covered The quantity N of the son figure layer to be doctored of cover area covering, comprising:
The quantity of the labeled son figure layer to be scraped off for scraping label off of touch surface covering based on K finger touch point, really Determine N.
5. method according to claim 4, the scratch-off area that the ratio by N and M is determined as the electronics scratch card is accounted for Than, including,
The ratio of N and M is determined as to the scratch-off area accounting of the electronics scratch card if detecting that finger stops movement.
6. being wrapped according to the method described in claim 4, described be determined as the scratch-off area accounting according to by the ratio of N and M It includes:
The ratio of N and M is determined as the scratch-off area accounting as the path of the motion track changes to synchronize.
7. method according to any one of claim 1 to 6, the method also includes:
According to the width of the figure layer to be doctored, height and dot matrix fineness coefficient, determine that M, the dot matrix fineness coefficient are the son The maximal side of figure layer to be doctored.
8. a kind of device of determining electronics scratch card scratch-off area accounting, the scratch card includes showing the base map layer of result and covering The figure layer to be doctored of the base map layer is covered, described device includes
Touch detection module: motion track of the detection finger in the figure layer to be doctored, the figure layer to be doctored includes M adjacent row The son figure layer to be doctored of cloth, M are the integer more than or equal to 2;
Target coverage area generation module: target coverage area of the finger motion track in the figure layer to be doctored is determined;
Counting module: the quantity N of the son figure layer to be doctored of the target coverage area covering is determined;
It scrapes accounting generation module off: the ratio of N and M is determined as to the scratch-off area accounting of the scratch card;
Display module: when the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
9. a kind of electronic equipment, comprising:
Processor;And
It is arranged to the memory of storage computer executable instructions, the executable instruction makes the processor when executed Execute following operation:
Motion track of the finger in the figure layer to be doctored is detected, the figure layer to be doctored includes the son figure to be doctored of M arranged adjacent Layer, M are the integer more than or equal to 2;
Determine target coverage area of the motion track in the figure layer to be doctored;
Determine the quantity N of the son figure layer to be doctored of the target coverage area covering;
The ratio of N and M is determined as to the scratch-off area accounting of the electronics scratch card;
When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
10. a kind of computer-readable medium, the computer-readable medium storage one or more program is one or more of Program is when the electronic equipment for being included multiple application programs executes, so that the electronic equipment executes following operation: detection hand Refer to motion track in the figure layer to be doctored, the figure layer to be doctored includes the son figure layer to be doctored of M arranged adjacent, M for greater than Or the integer equal to 2;
Determine target coverage area of the motion track in the figure layer to be doctored;
Determine the quantity N of the son figure layer to be doctored of the target coverage area covering;
The ratio of N and M is determined as to the scratch-off area accounting of the electronics scratch card;
When the scratch-off area accounting is greater than or equal to default accounting, the figure layer to be doctored is scraped off.
CN201910264827.6A 2019-04-03 2019-04-03 Method and device for determining scraping area ratio of electronic scraping card and electronic equipment Active CN110162728B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910264827.6A CN110162728B (en) 2019-04-03 2019-04-03 Method and device for determining scraping area ratio of electronic scraping card and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910264827.6A CN110162728B (en) 2019-04-03 2019-04-03 Method and device for determining scraping area ratio of electronic scraping card and electronic equipment

Publications (2)

Publication Number Publication Date
CN110162728A true CN110162728A (en) 2019-08-23
CN110162728B CN110162728B (en) 2023-05-02

Family

ID=67638841

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910264827.6A Active CN110162728B (en) 2019-04-03 2019-04-03 Method and device for determining scraping area ratio of electronic scraping card and electronic equipment

Country Status (1)

Country Link
CN (1) CN110162728B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111221461A (en) * 2019-11-19 2020-06-02 北京字节跳动网络技术有限公司 Method, apparatus, device and storage medium for gradually presenting image presentation content
CN111263210A (en) * 2020-03-23 2020-06-09 腾讯科技(深圳)有限公司 Video interaction method and related device
CN115270528A (en) * 2022-09-28 2022-11-01 中国兵器科学研究院 Method, device, equipment and medium for distributing ammunition

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101539966A (en) * 2008-03-17 2009-09-23 英华达股份有限公司 System and method for electronic scratch lottery
CN103049866A (en) * 2012-12-19 2013-04-17 上海宏蝠网络有限公司 Application method and system of electronic scratch card
CN103440586A (en) * 2013-08-02 2013-12-11 福建天晴数码有限公司 Scratch card implementation method based on browser
CN109254705A (en) * 2018-08-06 2019-01-22 无锡天脉聚源传媒科技有限公司 A kind of electronics scraping award method, system and device based on Canvas

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101539966A (en) * 2008-03-17 2009-09-23 英华达股份有限公司 System and method for electronic scratch lottery
CN103049866A (en) * 2012-12-19 2013-04-17 上海宏蝠网络有限公司 Application method and system of electronic scratch card
CN103440586A (en) * 2013-08-02 2013-12-11 福建天晴数码有限公司 Scratch card implementation method based on browser
CN109254705A (en) * 2018-08-06 2019-01-22 无锡天脉聚源传媒科技有限公司 A kind of electronics scraping award method, system and device based on Canvas

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111221461A (en) * 2019-11-19 2020-06-02 北京字节跳动网络技术有限公司 Method, apparatus, device and storage medium for gradually presenting image presentation content
CN111263210A (en) * 2020-03-23 2020-06-09 腾讯科技(深圳)有限公司 Video interaction method and related device
CN111263210B (en) * 2020-03-23 2021-07-16 腾讯科技(深圳)有限公司 Video interaction method and related device
CN115270528A (en) * 2022-09-28 2022-11-01 中国兵器科学研究院 Method, device, equipment and medium for distributing ammunition

Also Published As

Publication number Publication date
CN110162728B (en) 2023-05-02

Similar Documents

Publication Publication Date Title
CN110162728A (en) Determine the method, apparatus and electronic equipment of electronics scratch card scratch-off area accounting
CN104583891B (en) For the devices, systems and methods that the adaptable caching in non-volatile main memory system is changed
CN104777987B (en) The control method and device of smartwatch
CN109189682A (en) A kind of script method for recording and device
CN104025003B (en) Translate animation
JP6123631B2 (en) Information processing apparatus and information processing program
CN106527915B (en) A kind of information processing method and electronic equipment
CN107861682A (en) The control method for movement and device of virtual objects
US8542207B1 (en) Pencil eraser gesture and gesture recognition method for touch-enabled user interfaces
JP6784784B2 (en) Slider control control method and device and slider selector
KR102188543B1 (en) Graphic processing unit
CN103809954A (en) Method and device for realizing interface element selection
CN107945248A (en) A kind of bubble diagram word methods of exhibiting and device
CN110308835A (en) Control the method, apparatus and electronic equipment of view control
CN108519902A (en) Interface position adjusting method and device of interactive intelligent equipment
CN106201234A (en) The inspection method of content of pages and device
CN109858542A (en) A kind of character identifying method and device
CN111524211A (en) Handwriting erasing method, device and equipment
CN109683773A (en) Corpus labeling method and device
US11036442B2 (en) Transparent interactive printing interface
WO2016040076A2 (en) Layout engine
CN103150361A (en) Web page display method and device
Gemsa et al. Multirow boundary-labeling algorithms for panorama images
CN114879869A (en) Note erasing method, electronic device and computer storage medium
CN110471607A (en) Handwriting display methods, hand-written arrangement for reading and computer storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20200929

Address after: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman, British Islands

Applicant after: Advanced innovation technology Co.,Ltd.

Address before: A four-storey 847 mailbox in Grand Cayman Capital Building, British Cayman Islands

Applicant before: Alibaba Group Holding Ltd.

Effective date of registration: 20200929

Address after: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman, British Islands

Applicant after: Innovative advanced technology Co.,Ltd.

Address before: Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman, British Islands

Applicant before: Advanced innovation technology Co.,Ltd.

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant