Application of Database Technology in CAD of Packaging Containers (I)

Abstract : The application of database technology in the design process of packaging passengers is the basis for CAD of packaging containers. The basic idea in the article is to refer to the packaging national standards first, establish an Access database of standard series, model, dimensions, and various parameters of the package passengers, and provide a method for establishing a database. Combining the database to develop standard parameterized two-dimensional and three-story galleries of standard packaging containers, using size-driven or program-driven. According to the corresponding selection, the design process will look up the table to calculate the calculation parameters and calculation formulas, and the program will calculate, display and output the design results. The system is based on the WINDOWS platform and developed with Visual C++.

Keywords: Packaging Database CAD


At present, the design of packaging containers is still based on traditional empirical design methods. It is a complex and error-prone work. There are many formulas, design calculations are complex, and a large number of parameters need to be queried to make the design cycle longer and easier. Design calculation error and rapid drawing appear, drawings cannot be managed by computer. The packaging container CAD system aims to use a computer to complete the design of the packaging container system, including the planar structure design, the generation of two-dimensional engineering drawings, and the generation of three-dimensional graphics. The basic idea is to first determine the type of packaging container, and then according to the corresponding calculations. Formulas and standards are used for table lookups and design calculations. Based on the two-dimensional drawing of the structure, a three-dimensional graphic display design based on OpenGL is also established. This greatly reduces the designer's labor intensity, optimizes the design and the computer management of the drawings, and frees them from the heavy design work.

1 Packaging CAD System Analysis

The packaging container design process often includes a cumbersome process of selecting, querying, and selecting calculation parameters and calculation formulas. Therefore, the use of powerful computer information processing functions to establish a complete standard database of packaging containers is the beginning of automatic packaging container design. Two databases were built in the packaging container CAD: a calculation formula database and a calculation parameter database. Packaging CAD structural block diagram shown in Figure 1. The packaging container CAD system design process is


1) Structural relationship design module. The designer selects the type and model of the packaging container according to the need. The system determines the structural relationship from the database according to the type and model, and performs parametric drawing and display of parameters and calculation formulas.
2) Calculate the query design module. Designers according to the established structural relationship between the package, combined with the actual needs of the parameters, calculation formulas to modify the design, and finally write the design results into the information database, the entire data access calculation in the database. The database maintenance module and the drawing production module for various parts of the package are developed using Visual C + + combined with the Access database system. There are two main methods for handling database interfaces using VC++: OBDC (Open Database Connectivity) and DAO (Database Access Objects) ). DAO does not require a DSN (data source name), and for the packaging database is an extension of MDB, then DAO is certainly the technology of choice.
3) Three-dimensional display module. Based on OpenGL's 3D graphics display design [2], check whether the design satisfies the requirements, and return and redesign if it does not meet the requirements.
4) Output module. Complete the creation of 3D graphics and 2D engineering drawings, output the final designed packaging container parameters and verification results, and generate and print the specification module.

2 Application of Database System

2.1 The establishment of a DAO-based packaging database

Access database system is a visual relational database management system. Using Access database system, with reference to packaging national standards, establish a standard series, model, dimensions, various parameters of the packaging container data table, and establish a database maintenance function module, the database for a variety of operations. For example, in the carton carton CAD design, the box-type structure of the carton carton packaging container is fixed, but its structural size is different. Therefore, a carton carton database can be established to manage the corresponding size and graphic data so that it can be easily searched, searched, and invoked by designers.

Since the structural parameters and technical parameters of the packaging container are mostly given in the form of a table, the relational data model is used in this system to realize the management of the packaging container product sample. According to the data requirements of the packaging container CAD system. You can create an information model for the packaging container database. The packaging container category entity describes the classification of various packaging containers, such as: carton, carton, glass bottle, metal packaging, etc. It also provides information on the types and symbols of various packaging containers, as shown in Figure 2. The parameter table stores the structural dimensions of the packaging container. For the graphic description of the packaging container, the outline of each component and the main geometric elements are briefly expressed. The design only needs to call this block. This database gives the path of the block and the positioning base point. The path of the tile is used for browsing in the management module. The positioning base point is used when calling and inserting the block. In addition, because the packaging containers of the same type have a similar structure, the parameter-based database can be constructed using a program-driven method.