CN111240622A - Drawing method and device - Google Patents

Drawing method and device Download PDF

Info

Publication number
CN111240622A
CN111240622A CN202010014892.6A CN202010014892A CN111240622A CN 111240622 A CN111240622 A CN 111240622A CN 202010014892 A CN202010014892 A CN 202010014892A CN 111240622 A CN111240622 A CN 111240622A
Authority
CN
China
Prior art keywords
box body
target
target box
coordinate
drawn
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
CN202010014892.6A
Other languages
Chinese (zh)
Other versions
CN111240622B (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.)
Colorlight Shenzhen Cloud Technology Co Ltd
Original Assignee
Colorlight Shenzhen Cloud Technology 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 Colorlight Shenzhen Cloud Technology Co Ltd filed Critical Colorlight Shenzhen Cloud Technology Co Ltd
Priority to CN202010014892.6A priority Critical patent/CN111240622B/en
Publication of CN111240622A publication Critical patent/CN111240622A/en
Application granted granted Critical
Publication of CN111240622B publication Critical patent/CN111240622B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • G06F3/1423Digital output to display device ; Cooperation and interconnection of the display device with other functional units controlling a plurality of local displays, e.g. CRT and flat panel display
    • G06F3/1446Digital output to display device ; Cooperation and interconnection of the display device with other functional units controlling a plurality of local displays, e.g. CRT and flat panel display display composed of modules, e.g. video walls

Abstract

The embodiment of the invention provides a drawing method and a drawing device, wherein the method comprises the following steps: acquiring box body parameters, performing parameter configuration on an implementation program of the box body by using the box body parameters, operating the implementation program after the parameters are configured, and generating a target box body, wherein the box body parameters comprise: the width and height of the box body; acquiring an initial coordinate of the target box body in a drawing area, and monitoring a current coordinate of the target box body in the drawing area; calculating the number of rows and columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters, and displaying the calculated number of rows and columns; and receiving a drawing instruction, and drawing the target box body in the drawing area according to the calculated row number and column number. By applying the scheme provided by the embodiment of the invention, the drawing operation of workers can be simplified.

Description

Drawing method and device
Technical Field
The invention relates to the technical field of computers, in particular to a drawing method and a drawing device.
Background
When the staff carries out the LED screen through LED screen control software and sets up, because the LED screen is constituteed by a plurality of box amalgamations usually, consequently, need draw each box that the LED screen contains one by one in LED screen control software usually to accomplish the drawing of LED screen, then can set up the display effect of the pixel that every box contained in the LED screen after accomplishing the drawing, in order to ensure that the LED screen can normally show.
In the related art, because each box body needs to be drawn one by one, the workload of workers is greatly increased, and the drawing operation is complicated.
Disclosure of Invention
The embodiment of the invention aims to provide a drawing method and a drawing device so as to simplify drawing operation of workers. The specific technical scheme is as follows:
in one aspect of the present invention, a rendering method is provided, where the method includes:
acquiring box body parameters, performing parameter configuration on an implementation program of the box body by using the box body parameters, operating the implementation program after the parameters are configured, and generating a target box body, wherein the box body parameters comprise: the width and height of the box body;
acquiring an initial coordinate of the target box body in a drawing area, and monitoring a current coordinate of the target box body in the drawing area;
calculating the number of rows and columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters, and displaying the calculated number of rows and columns;
and receiving a drawing instruction, and drawing the target box body in the drawing area according to the calculated row number and column number.
Optionally, before the step of receiving the drawing instruction and drawing the target box in the drawing area according to the calculated number of rows and columns, the method further includes:
determining the connection sequence of connecting lines between the target boxes to be drawn according to the initial coordinates and the current coordinates;
correspondingly, the step of receiving a drawing instruction and drawing the target box body in the drawing area according to the calculated number of rows and columns includes:
and receiving a drawing instruction, drawing the target box bodies in the drawing area according to the calculated line number and column number, and sequentially connecting the drawn target box bodies according to the connection sequence to obtain the connection line graph of each drawn target box body.
Optionally, the step of calculating the number of rows and the number of columns of the target box to be drawn according to the initial coordinate, the current coordinate, and the box parameter includes:
calculating a difference value of a vertical coordinate between the initial coordinate and the current coordinate to serve as a first difference value;
calculating a difference value of the horizontal coordinate between the initial coordinate and the current coordinate to serve as a second difference value;
calculating the number of lines of the target box body to be drawn by using the first difference and the height;
and calculating the column number of the target box body to be drawn by using the second difference and the width.
Optionally, the step of determining a connection sequence of connection lines between the target boxes to be drawn according to the initial coordinate and the current coordinate includes:
acquiring a moving distance of the current coordinate relative to the initial coordinate in the horizontal direction and a moving distance in the vertical direction, wherein the moving distances are respectively used as a first moving distance and a second moving distance;
taking the moving direction of the target box body in the horizontal direction as a first direction and taking the moving direction of the target box body in the vertical direction as a second direction under the condition that the first time is earlier than the second time;
taking the moving direction of the target box body in the vertical direction as a first direction and taking the moving direction of the target box body in the horizontal direction as a second direction under the condition that the first time is not earlier than the second time, wherein the first time is as follows: the first moving distance reaches the width, and the second time is: the moment when the second movement distance reaches the height;
and matching the first direction and the second direction with a preset connection sequence to determine the connection sequence of the connecting lines between the target boxes to be drawn.
Optionally, the method further includes:
recording drawing data generated in the drawing process;
under the condition that a rollback instruction is received, determining drawing data corresponding to the rollback instruction from the recorded drawing data;
a rollback operation is performed based on the determined rendering data.
In another aspect of the present invention, there is also provided a drawing apparatus, including:
the first acquisition module is used for acquiring box body parameters, performing parameter configuration on an implementation program of the box body by using the box body parameters, operating the implementation program after the parameters are configured, and generating a target box body, wherein the box body parameters comprise: the width and height of the box body;
the second acquisition module is used for acquiring the initial coordinate of the target box body in a drawing area and monitoring the current coordinate of the target box body in the drawing area;
the calculation module is used for calculating the number of rows and the number of columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters and displaying the calculated number of rows and columns;
and the drawing module is used for receiving a drawing instruction and drawing the target box body in the drawing area according to the calculated line number and column number.
Optionally, the apparatus further comprises:
the determining module is used for determining the connection sequence of the connecting lines between the target boxes to be drawn according to the initial coordinates and the current coordinates;
and the drawing module is used for receiving a drawing instruction, drawing the target boxes in the drawing area according to the calculated line number and column number, and sequentially connecting the drawn target boxes according to the connection sequence to obtain the connection line graph of each drawn target box.
Optionally, the computing module is used for
Calculating a difference value of a vertical coordinate between the initial coordinate and the current coordinate to serve as a first difference value;
calculating a difference value of the horizontal coordinate between the initial coordinate and the current coordinate to serve as a second difference value;
calculating the number of lines of the target box body to be drawn by using the first difference and the height;
and calculating the column number of the target box body to be drawn by using the second difference and the width.
Optionally, the determining module is used for
Acquiring a moving distance of the current coordinate relative to the initial coordinate in the horizontal direction and a moving distance in the vertical direction, wherein the moving distances are respectively used as a first moving distance and a second moving distance;
taking the moving direction of the target box body in the horizontal direction as a first direction and taking the moving direction of the target box body in the vertical direction as a second direction under the condition that the first time is earlier than the second time;
taking the moving direction of the target box body in the vertical direction as a first direction and taking the moving direction of the target box body in the horizontal direction as a second direction under the condition that the first time is not earlier than the second time, wherein the first time is as follows: the first moving distance reaches the width, and the second time is: the moment when the second movement distance reaches the height;
and matching the first direction and the second direction with a preset connection sequence to determine the connection sequence of the connecting lines between the target boxes to be drawn.
Optionally, the apparatus further comprises:
the recording module is used for recording drawing data generated in the drawing process;
the receiving module is used for determining drawing data corresponding to a rollback instruction from the recorded drawing data under the condition that the rollback instruction is received;
and the rollback module is used for executing rollback operation according to the determined drawing data.
In another aspect of the present invention, an electronic device is further provided, which includes a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory complete communication with each other through the communication bus;
a memory for storing a computer program;
a processor for implementing the rendering method of any one of the above when executing the program stored in the memory.
According to the drawing method and the drawing device, the initial coordinates of the target box body in the drawing area can be obtained after the target box body is generated according to the obtained box body parameters, and the current coordinates of the target box body in the drawing area are monitored; calculating the number of rows and columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters, and displaying the calculated number of rows and columns; and receiving a drawing instruction, and drawing the target box body in the drawing area according to the calculated row number and column number. By applying the scheme provided by the embodiment of the invention, the number of the rows and the number of the columns of the target box body to be drawn can be calculated in real time according to the initial coordinate, the current coordinate and the box body parameters of the target box body, and the calculated number of the rows and the calculated number of the columns are displayed.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic flow chart of a rendering method according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of a predetermined connection sequence according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a drawing apparatus according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, a schematic flow chart of a rendering method according to an embodiment of the present invention is provided, where the method includes:
s100, acquiring box body parameters, performing parameter configuration on the implementation program of the box body by using the box body parameters, and operating the implementation program after the parameters are configured to generate the target box body.
Wherein, the box parameter includes: width and height of the box.
In implementation, the LED screen control software can store an implementation program of the box body, when a worker needs to draw the box body, the LED screen control software can use the box body parameters to carry out parameter configuration on the implementation program by only inputting the box body parameters needing to draw the box body, and therefore the target box body is generated.
And S110, acquiring initial coordinates of the target box body in the drawing area, and monitoring the current coordinates of the target box body in the drawing area.
In implementation, a coordinate system can be established by taking the upper left corner of the drawing area in the LED screen control software as a coordinate origin to serve as a drawing coordinate system, wherein the horizontal direction in the drawing coordinate system gradually increases towards the right abscissa, and the vertical direction in the drawing coordinate system gradually increases towards the lower ordinate. The initial coordinates are those at which the first target box is drawn. After the LED screen control software generates the target box body, a worker can move the target box body in real time in a drawing area in the LED screen control software, and can input a determination instruction when the target box body moves to a proper position, for example, the determination instruction can be input by clicking a left mouse button; accordingly, after receiving the determination instruction, the LED screen control software takes the current coordinates as the initial coordinates of the target box.
After that, the staff can move the target box body again, and the LED screen control software can monitor the current coordinates of the target box body in the drawing area by monitoring the position of the mouse pointer.
And S120, calculating the number of rows and columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters, and displaying the calculated number of rows and columns.
In one implementation, a difference in vertical coordinate between the initial coordinate and the current coordinate may be calculated as a first difference; calculating a difference value of the horizontal coordinates between the initial coordinates and the current coordinates as a second difference value; calculating the number of lines of the target box body to be drawn by using the first difference and the height of the box body; and calculating the column number of the target box body to be drawn by using the second difference value and the box body width.
For example, the initial coordinates are (500, 1000), the current coordinates are (100, 2000), and the box parameters are (200, 100), then 500-.
And S130, receiving a drawing instruction, and drawing the target box body in the drawing area according to the calculated line number and column number.
In implementation, when the staff determines that the displayed row number and column number meet the drawing requirement, the staff can input a drawing instruction, and accordingly, the LED screen control software draws the target box bodies with the calculated row number and column number in the drawing area after receiving the drawing instruction. Continuing with the data above, 10 rows and 2 columns of target boxes are drawn within the drawing area.
In practice, the staff also needs to connect the drawn target boxes to form a connecting line diagram of the drawn target boxes. Based on this, in an implementation manner of the embodiment of the present invention, a connection order of connecting lines between target boxes to be drawn may be determined according to the initial coordinate and the current coordinate, and after the target boxes are drawn in the drawing area according to the calculated number of rows and number of columns, the drawn target boxes are sequentially connected according to the connection order.
Specifically, the connection sequence of the connecting lines between the target boxes to be drawn can be determined according to the initial coordinates and the current coordinates through the following steps a1-a 4:
step a1, a moving distance in the horizontal direction and a moving distance in the vertical direction of the current coordinate relative to the initial coordinate are acquired as the first moving distance and the second moving distance, respectively.
In implementation, the first difference and the second difference are already calculated in real time when the number of rows and the number of columns of the target box to be drawn are calculated, and therefore, the first difference and the second difference can be directly acquired as the second movement distance and the first movement distance, respectively.
In step a2, in the case where the first time is earlier than the second time, the moving direction of the target casing in the horizontal direction is taken as the first direction, and the moving direction in the vertical direction is taken as the second direction.
Step a3, in the case that the first time is not earlier than the second time, regarding the moving direction of the target box in the vertical direction as the first direction and regarding the moving direction in the horizontal direction as the second direction, where the first time is: the moment when the first moving distance reaches the width of the box body, the second moment is as follows: the second movement distance reaches the moment of the height of the box body.
For example, the initial coordinates (500, 1000), the current coordinates (200,900), and the box parameters (200, 300), first, 500-; the second direction is a vertical direction.
According to the conditions that 300 is less than 500, the horizontal direction moves to the left, and 900 is less than 1000, the vertical direction moves upwards, and finally the first direction is determined to be the horizontal direction to the left, and the second direction is determined to be the vertical direction to the upwards.
And step A4, matching the first direction and the second direction with a preset connection sequence, and determining the connection sequence of the connection lines between the target boxes to be drawn.
Referring to fig. 2, which is a schematic diagram of each preset connection sequence provided in the embodiment of the present invention, in the diagram, a is a corresponding connection sequence when the first direction is downward and the second direction is rightward; b is a corresponding connection sequence when the first direction is rightward and the second direction is downward; c is a corresponding connection sequence when the first direction is downward and the second direction is leftward; d is a corresponding connection sequence when the first direction is leftward and the second direction is downward; e is a corresponding connection sequence when the first direction is upward and the second direction is rightward; f is a corresponding connection sequence when the first direction is rightward and the second direction is upward; g is a corresponding connection sequence when the first direction is upward and the second direction is leftward; h is the corresponding connection sequence when the first direction is leftward and the second direction is upward.
In implementation, in order to facilitate the user to confirm whether the connection sequence obtained by matching meets the drawing requirement, the connection sequence obtained by matching can be displayed in real time. The first direction and the second direction are determined, that is, the connection sequence can be matched with each connection sequence shown in fig. 2, so that the connection sequence of the connection lines between the target boxes to be drawn is determined. After the connection order is determined, points with the same position in each drawn target box can be used as connection points, for example, the central point of each drawn target box is used as a connection point; after the connection points are determined, the connection points can be connected in sequence according to the connection order, so that a connection line graph drawn among the target boxes is obtained.
In implementation, in the drawing process, a worker may be unsatisfied with the drawing result of a certain step and needs to return to the drawing state before the step, so that in one implementation manner of the embodiment of the invention, the drawing data generated in the drawing process can be recorded; under the condition that a rollback instruction is received, determining drawing data corresponding to the rollback instruction from the recorded drawing data; a rollback operation is performed based on the determined rendering data.
By applying the scheme provided by the embodiment of the invention, the number of the rows and the number of the columns of the target box body to be drawn can be calculated in real time according to the initial coordinate, the current coordinate and the box body parameters of the target box body, and the calculated number of the rows and the calculated number of the columns are displayed.
Referring to fig. 3, a schematic structural diagram of a drawing apparatus provided in an embodiment of the present invention is shown, where the apparatus includes:
the first obtaining module 300 is configured to obtain box parameters, perform parameter configuration on an implementation program of a box by using the box parameters, run the implementation program after the parameter configuration, and generate a target box, where the box parameters include: the width and height of the box body;
a second obtaining module 310, configured to obtain an initial coordinate of the target box in a drawing area, and monitor a current coordinate of the target box in the drawing area;
the calculating module 320 is configured to calculate the number of rows and columns of the target box to be drawn according to the initial coordinate, the current coordinate, and the box parameter, and display the calculated number of rows and columns;
and the drawing module 330 is configured to receive a drawing instruction, and draw the target box in the drawing area according to the calculated number of rows and columns.
In one implementation, the apparatus further includes:
the determining module is used for determining the connection sequence of the connecting lines between the target boxes to be drawn according to the initial coordinates and the current coordinates;
the drawing module 330 is configured to receive a drawing instruction, draw the target box in the drawing area according to the calculated number of rows and columns, and sequentially connect the drawn target boxes according to the connection order to obtain a connection diagram of the drawn target boxes.
In one implementation, the calculating module 320 is configured to
Calculating a difference value of a vertical coordinate between the initial coordinate and the current coordinate to serve as a first difference value;
calculating a difference value of the horizontal coordinate between the initial coordinate and the current coordinate to serve as a second difference value;
calculating the number of lines of the target box body to be drawn by using the first difference and the height;
and calculating the column number of the target box body to be drawn by using the second difference and the width.
In one implementation, the determining module is configured to
Calculating the moving distance of the current coordinate relative to the initial coordinate in the horizontal direction and the moving distance in the vertical direction, wherein the moving distances are respectively used as a first moving distance and a second moving distance;
taking the moving direction of the target box body in the horizontal direction as a first direction and taking the moving direction of the target box body in the vertical direction as a second direction under the condition that the first time is earlier than the second time;
taking the moving direction of the target box body in the vertical direction as a first direction and taking the moving direction of the target box body in the horizontal direction as a second direction under the condition that the first time is not earlier than the second time, wherein the first time is as follows: the first moving distance reaches the width, and the second time is: the moment when the second movement distance reaches the height;
and matching the first direction and the second direction with a preset connection sequence, and determining the connection sequence of the connecting lines between the target boxes to be drawn.
In one implementation, the apparatus further includes:
the recording module is used for recording drawing data generated in the drawing process;
the receiving module is used for determining drawing data corresponding to a rollback instruction from the recorded drawing data under the condition that the rollback instruction is received;
and the rollback module is used for executing rollback operation according to the determined drawing data.
By applying the scheme provided by the embodiment of the invention, the number of the rows and the number of the columns of the target box body to be drawn can be calculated in real time according to the initial coordinate, the current coordinate and the box body parameters of the target box body, and the calculated number of the rows and the calculated number of the columns are displayed.
An embodiment of the present invention further provides an electronic device, as shown in fig. 4, including a processor 001, a communication interface 002, a memory 003 and a communication bus 004, where the processor 001, the communication interface 002 and the memory 003 complete mutual communication through the communication bus 004,
a memory 003 for storing a computer program;
the processor 001, when executing the program stored in the memory 003, is configured to implement any of the above-described rendering methods, and the method includes:
acquiring box body parameters, performing parameter configuration on an implementation program of the box body by using the box body parameters, operating the implementation program after the parameters are configured, and generating a target box body, wherein the box body parameters comprise: the width and height of the box body;
acquiring an initial coordinate of the target box body in a drawing area, and monitoring a current coordinate of the target box body in the drawing area;
calculating the number of target boxes to be drawn in the horizontal direction and the vertical direction according to the initial coordinates, the current coordinates and the box parameters, and displaying the calculated number;
and receiving drawing instructions, and drawing the target box body in the drawing area according to the calculated quantity.
By applying the scheme provided by the embodiment of the invention, the number of the target boxes to be drawn in the horizontal direction and the vertical direction can be calculated in real time according to the initial coordinates, the current coordinates and the box parameters of the target boxes, and the calculated number is displayed.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a Non-Volatile Memory (NVM), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the invention to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, as for the embodiments of the apparatus and the electronic device, since they are substantially similar to the embodiments of the method, the description is simple, and the relevant points can be referred to only in the partial description of the embodiments of the method.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (10)

1. A method of rendering, the method comprising:
acquiring box body parameters, performing parameter configuration on an implementation program of the box body by using the box body parameters, operating the implementation program after the parameters are configured, and generating a target box body, wherein the box body parameters comprise: the width and height of the box body;
acquiring an initial coordinate of the target box body in a drawing area, and monitoring a current coordinate of the target box body in the drawing area;
calculating the number of rows and columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters, and displaying the calculated number of rows and columns;
and receiving a drawing instruction, and drawing the target box body in the drawing area according to the calculated row number and column number.
2. The method of claim 1, wherein prior to the step of receiving rendering instructions to render the target box within the rendering area in terms of the computed number of rows and columns, further comprising:
determining the connection sequence of connecting lines between the target boxes to be drawn according to the initial coordinates and the current coordinates;
correspondingly, the step of receiving a drawing instruction and drawing the target box body in the drawing area according to the calculated number of rows and columns includes:
and receiving a drawing instruction, drawing the target box bodies in the drawing area according to the calculated line number and column number, and sequentially connecting the drawn target box bodies according to the connection sequence to obtain the connection line graph of each drawn target box body.
3. The method of claim 1, wherein the step of calculating the number of rows and columns of the target box to be drawn based on the initial coordinates, the current coordinates, and the box parameters comprises:
calculating a difference value of a vertical coordinate between the initial coordinate and the current coordinate to serve as a first difference value;
calculating a difference value of the horizontal coordinate between the initial coordinate and the current coordinate to serve as a second difference value;
calculating the number of lines of the target box body to be drawn by using the first difference and the height;
and calculating the column number of the target box body to be drawn by using the second difference and the width.
4. The method of claim 2, wherein the step of determining a connection sequence of the connection lines between the target boxes to be drawn according to the initial coordinates and the current coordinates comprises:
acquiring a moving distance of the current coordinate relative to the initial coordinate in the horizontal direction and a moving distance in the vertical direction, wherein the moving distances are respectively used as a first moving distance and a second moving distance;
taking the moving direction of the target box body in the horizontal direction as a first direction and taking the moving direction of the target box body in the vertical direction as a second direction under the condition that the first time is earlier than the second time;
taking the moving direction of the target box body in the vertical direction as a first direction and taking the moving direction of the target box body in the horizontal direction as a second direction under the condition that the first time is not earlier than the second time, wherein the first time is as follows: the first moving distance reaches the width, and the second time is: the moment when the second movement distance reaches the height;
and matching the first direction and the second direction with a preset connection sequence to determine the connection sequence of the connecting lines between the target boxes to be drawn.
5. The method of any one of claims 1-4, further comprising:
recording drawing data generated in the drawing process;
under the condition that a rollback instruction is received, determining drawing data corresponding to the rollback instruction from the recorded drawing data;
a rollback operation is performed based on the determined rendering data.
6. An apparatus for rendering, the apparatus comprising:
the first acquisition module is used for acquiring box body parameters, performing parameter configuration on an implementation program of the box body by using the box body parameters, operating the implementation program after the parameters are configured, and generating a target box body, wherein the box body parameters comprise: the width and height of the box body;
the second acquisition module is used for acquiring the initial coordinate of the target box body in a drawing area and monitoring the current coordinate of the target box body in the drawing area;
the calculation module is used for calculating the number of rows and the number of columns of the target box body to be drawn according to the initial coordinate, the current coordinate and the box body parameters and displaying the calculated number of rows and columns;
and the drawing module is used for receiving a drawing instruction and drawing the target box body in the drawing area according to the calculated line number and column number.
7. The apparatus of claim 6, wherein the apparatus further comprises:
the determining module is used for determining the connection sequence of the connecting lines between the target boxes to be drawn according to the initial coordinates and the current coordinates;
and the drawing module is used for receiving a drawing instruction, drawing the target boxes in the drawing area according to the calculated line number and column number, and sequentially connecting the drawn target boxes according to the connection sequence to obtain the connection line graph of each drawn target box.
8. The apparatus of claim 6, wherein the computing module is to compute
Calculating a difference value of a vertical coordinate between the initial coordinate and the current coordinate to serve as a first difference value;
calculating a difference value of the horizontal coordinate between the initial coordinate and the current coordinate to serve as a second difference value;
calculating the number of lines of the target box body to be drawn by using the first difference and the height;
and calculating the column number of the target box body to be drawn by using the second difference and the width.
9. The apparatus of claim 7, wherein the determination module is to determine the location of the mobile device
Acquiring a moving distance of the current coordinate relative to the initial coordinate in the horizontal direction and a moving distance in the vertical direction, wherein the moving distances are respectively used as a first moving distance and a second moving distance;
taking the moving direction of the target box body in the horizontal direction as a first direction and taking the moving direction of the target box body in the vertical direction as a second direction under the condition that the first time is earlier than the second time;
taking the moving direction of the target box body in the vertical direction as a first direction and taking the moving direction of the target box body in the horizontal direction as a second direction under the condition that the first time is not earlier than the second time, wherein the first time is as follows: the first moving distance reaches the width, and the second time is: the moment when the second movement distance reaches the height;
and matching the first direction and the second direction with a preset connection sequence to determine the connection sequence of the connecting lines between the target boxes to be drawn.
10. An electronic device is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor and the communication interface are used for realizing mutual communication by the memory through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any one of claims 1 to 5 when executing a program stored in the memory.
CN202010014892.6A 2020-01-07 2020-01-07 Drawing method and device Active CN111240622B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010014892.6A CN111240622B (en) 2020-01-07 2020-01-07 Drawing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010014892.6A CN111240622B (en) 2020-01-07 2020-01-07 Drawing method and device

Publications (2)

Publication Number Publication Date
CN111240622A true CN111240622A (en) 2020-06-05
CN111240622B CN111240622B (en) 2022-01-25

Family

ID=70875999

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010014892.6A Active CN111240622B (en) 2020-01-07 2020-01-07 Drawing method and device

Country Status (1)

Country Link
CN (1) CN111240622B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184893A (en) * 2020-10-15 2021-01-05 洛阳众智软件科技股份有限公司 Drawing method, device and equipment for integration of linear surface body and storage medium
CN113257182A (en) * 2021-06-29 2021-08-13 卡莱特云科技股份有限公司 Lamp point position correction method and device in LED display screen correction process

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102103582A (en) * 2009-12-17 2011-06-22 珠海金山软件有限公司 Method and system for drawing table utilizing computer
CN102411880A (en) * 2011-12-26 2012-04-11 深圳市奥拓电子股份有限公司 System and method for configuring load of LED display screen
CN102568378A (en) * 2011-12-13 2012-07-11 深圳市奥拓电子股份有限公司 Light-emitting diode (LED) display screen system and monitoring method thereof
CN202711656U (en) * 2012-04-17 2013-01-30 西安诺瓦电子科技有限公司 LED display screen rapid configuration apparatus
CN104299562A (en) * 2014-09-02 2015-01-21 深圳市奥拓电子股份有限公司 LED display screen automatic loaded configuring method and system
CN105117190A (en) * 2015-09-07 2015-12-02 西安诺瓦电子科技有限公司 LED display screen matching method
CN205487274U (en) * 2016-02-24 2016-08-17 西安诺瓦电子科技有限公司 LED box and LED display screen system
CN106557203A (en) * 2016-11-08 2017-04-05 武汉华星光电技术有限公司 Flexible touch screen and flexible touch display screen
ES2647622A2 (en) * 2011-09-23 2017-12-22 Kt Corporation Method for inducing a fusion candidate block and\rdevice using the same (Machine-translation by Google Translate, not legally binding)

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102103582A (en) * 2009-12-17 2011-06-22 珠海金山软件有限公司 Method and system for drawing table utilizing computer
ES2647622A2 (en) * 2011-09-23 2017-12-22 Kt Corporation Method for inducing a fusion candidate block and\rdevice using the same (Machine-translation by Google Translate, not legally binding)
CN102568378A (en) * 2011-12-13 2012-07-11 深圳市奥拓电子股份有限公司 Light-emitting diode (LED) display screen system and monitoring method thereof
CN102411880A (en) * 2011-12-26 2012-04-11 深圳市奥拓电子股份有限公司 System and method for configuring load of LED display screen
CN202711656U (en) * 2012-04-17 2013-01-30 西安诺瓦电子科技有限公司 LED display screen rapid configuration apparatus
CN104299562A (en) * 2014-09-02 2015-01-21 深圳市奥拓电子股份有限公司 LED display screen automatic loaded configuring method and system
CN105117190A (en) * 2015-09-07 2015-12-02 西安诺瓦电子科技有限公司 LED display screen matching method
CN205487274U (en) * 2016-02-24 2016-08-17 西安诺瓦电子科技有限公司 LED box and LED display screen system
CN106557203A (en) * 2016-11-08 2017-04-05 武汉华星光电技术有限公司 Flexible touch screen and flexible touch display screen

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
邵寅亮等: "租赁用LED显示屏多批次箱体混合使用的解决方案", 《现代显示》 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184893A (en) * 2020-10-15 2021-01-05 洛阳众智软件科技股份有限公司 Drawing method, device and equipment for integration of linear surface body and storage medium
CN113257182A (en) * 2021-06-29 2021-08-13 卡莱特云科技股份有限公司 Lamp point position correction method and device in LED display screen correction process
CN113257182B (en) * 2021-06-29 2021-09-17 卡莱特云科技股份有限公司 Lamp point position correction method and device in LED display screen correction process

Also Published As

Publication number Publication date
CN111240622B (en) 2022-01-25

Similar Documents

Publication Publication Date Title
CN108664461B (en) Automatic filling method and device for webpage form
CN111240622B (en) Drawing method and device
US10319129B2 (en) Snapping line generation
CN110490523B (en) Stock list generation method and device and electronic equipment
CN109409318B (en) Statistical model training method, statistical device and storage medium
CN112003729B (en) Heterogeneous cloud platform resource topology display method, system, terminal and storage medium
CN113095227A (en) Robot positioning method and device, electronic equipment and storage medium
CN110781427A (en) Method, device, equipment and storage medium for calculating first screen time
CN109213668B (en) Operation recording method and device and terminal
CN110825303A (en) Interaction method, device, terminal and computer readable medium
CN113282488B (en) Terminal test method and device, storage medium and terminal
CN110914810B (en) Monkey testing method and terminal
CN107844645B (en) BIM-based collaboration initiating method and device
CN111881049A (en) Acceptance method and device for application program interface and electronic equipment
CN110442266B (en) Object recognition method, object recognition device, electronic equipment and storage medium
CN110908899A (en) Application program debugging method, mobile terminal and computer readable storage medium
CN113808134B (en) Oil tank layout information generation method, oil tank layout information generation device, electronic apparatus, and medium
CN115860877A (en) Product marketing method, device, equipment and medium
CN111767206B (en) Statistical method and device for content unit exposure presentation rate and electronic equipment
US20130094761A1 (en) Electronic device and method for creating measurement codes
US11405276B2 (en) Device configuration management apparatus, system, and program
CN114359548A (en) Circle searching method and device, electronic equipment and storage medium
CN113420355A (en) Floor processing method and device and electronic equipment
CN110110260B (en) Page rendering method and device and electronic equipment
CN111859502A (en) Method and related equipment for positioning drawing review result

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
CB02 Change of applicant information

Address after: 518000 room 3801, block a, block 8, block C, Wanke Yuncheng phase III, Liuxin 4th Street, Xili community, Xili street, Nanshan District, Shenzhen City, Guangdong Province (37-39 floors)

Applicant after: Carlette cloud Technology Co.,Ltd.

Address before: 518000 101, integrated circuit Industrial Park, 1089 chaguang Road, Xili street, Shenzhen City, Guangdong Province

Applicant before: COLORLIGHT (SHENZHEN) CLOUD TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant