CGI is a term with multiple uses in the technology space.
Common Gateway Interface
Common Gateway Interface is an interface specification for transferring information between WWW servers and external databases and information sources known as CGI programs (sometimes referred to as scripts). The specifics of how the script is executed is determined by the server. A CGI program is any program designed to accept and return data that conforms to the CGI’s specification and is the most common way for web servers to interact dynamically with users.
History of Common Gateway Interface specifications
In 1993, The National Center for Supercomputing Applications (NCSA) developed standards in 1993 to interface with servers, like HTTP, to execute any external program, and developers accepted it as a standard for web servers. In 1997 NCSA formed a team—including Rob McCool, the author of NCSA HTTPd Web Server, and Ken Coar—and they formally defined CGI, which is specified in RFC 3875: “The Common Gateway Interface, or CGI, is a standard for external gateway programs to interface with information servers such as HTTP servers.”
Common Gateway Interface features
The following are some of the most significant features of CGI that attracts developers to generate dynamic web content:
- Highly compatible with all web browsers.
- Written in a simple and clear scripting language like Perl or C.
- Can easily interface with HTML.
For example, when a user fills out a form on a Web page and submits it, it needs to be processed by an application program. The Web server passes the form information to a small application program that then processes the data and sends a confirmation message back. This passing of data back and forth between the server and application is the CGI; it works as a mechanism that is part of the Hypertext Transfer Protocol (HTTP).
Common Gateway Interface advantages
Being a powerful data exchanging mechanism between the servers and the external databases, CGI web technology possesses the following advantages to users:
- Users can perform advanced tasks much easier by using CGI instead of using other programming languages like Java.
- It is easy to use an existing code rather than writing a new code from scratch.
- CGI programs are language-independent; therefore, they can be written in any language.
- Counters and codes based on CGI are available to perform simple tasks.
Common Gateway Interface disadvantages
Although CGI provides enough flexibility and versatility to run applications on a server, it has some disadvantages:
- Page loading incurs overhead, as it needs to call on a new process each time an HTTP request is initiated, and it uses significant server memory. Therefore, CGI scripts are not suitable for high-traffic web pages.
- The process of data caching between page loads is normally slow under CGI.
- Though CGI has a huge codebase, it is mostly in Perl and is not suitable for developing client-side applications.
- Scripts take a lot of processing time, as they need to create a separate process each time an HTTP request is initiated.
Another disadvantage is that a new process is started each time a script is executed. For busy websites, this can noticeably slow down the server. Using the server’s API, such as ISAPI or NSAPI, can be more efficient but difficult to implement. Another popular solution is using Java’s servlets.
Common Gateway Interface alternatives
Due to some disadvantages like processing time and slow data caching processes, the use of CGI is falling. Here are some alternatives to CGI:
ASP
Active Server Pages (ASP) is a web technology based on Internet Information Services (IIS) developed by Microsoft to develop dynamic web pages and quickly respond to the request initiated from HTML forms. ASP scripts are performed on the server, and it also contains HTML, XML, and text. While compared with CGI, ASP is simple, secure, and fast.
PHP
Hypertext Preprocessor, popularly known as PHP, is a server-side open-source scripting language. Like ASP and CGI, PHP scripts are performed on the server, and it comprises scripts, text, and HTML tags. PHP also supports several databases, including Oracle, Solid, MySQL, etc.
CFML
ColdFusion Markup Language (CFML) lets developers build dynamic web pages based on HTML. When a browser requests data in CFML, its application server automatically pre-processes the request. Therefore, it’s a fast and feasible way to develop dynamic pages that can link with any database.
FastCGI
FastCGI is an extended version of CGI; however, it’s simple, fast, and more secure than CGI. The main purpose of FastCGI is to reduce the overhead of using CGI by allowing a separate server to handle more HTTP requests.
Computer-generated imagery
Computer-generated imagery (CGI) is the creation of still or animated visual content with computer software. Computer graphics are used to create images in art, printed media, video games, films, television, commercials, and simulators. These images can be dynamic or static, two-dimensional (2D) or three-dimensional (3D). CGI is most commonly used to refer to 3D computer graphics used to create characters, scenes, and special effects in films and games.
Evolution of computer-generated Imagery
Computer-generated imagery was first used in the 1950s when Alfred Hitchcock incorporated it into the feature film VERTIGO to create some elements onto animation cells, such as patterns. The first blend of CGI appeared in the feature film Westworld in 1973, and it used first-hand animation created by Edwin Catmull.
The evolution of CGI contributed a lot to films, games, and arts in the forms of images, graphics, simulators, VFX (visual effects), etc. Apart from the arts, NASA began to use CGI to simulate the outside world and passed simulations to Vertical Motion Simulator (VMS) labs, which help engineers monitor information, communicate with pilots, and with later analysis of data.
Computer-generated imagery uses
CGI is used in a wide range of industries such as games, architecture, VFX, advertising, and so on. 3D modeling and 3D sculpting are the main parts of CGI. For example, video gaming and movie environments use them to create objects and characters. The advancements in CGI, like 3D simulations, are used to generate simulated environments that provide players a feel of the virtual world.
Artists use 3D modeling and 3D sculpting to quickly design and create anatomical models without losing their focus on the art side. 3D model rendering helps artists to provide more realism to a model by designing suitable skin, hair, cloth, fur, metals, etc. As technology develops, the possibilities of applications also increase, for example, the application of artificial intelligence (AI) to CGI creations makes it possible for characters to learn and behave like humans.
CGI is cheaper than using physical methods for creating effects such as hiring extras for crowd scenes and constructing complicated miniatures. In some circumstances, it’s humanly impossible to create the visuals needed without CGI.
Well-known movies that have extensive CGI use include Avatar (2009), The Matrix (1999), and Interstellar (2014).
Computer-generated imagery software
CGI software is an essential tool for artists to create 3D modeling, VFX, animation, and more.
Maya
Owned by Autodesk, Maya’s 3D animation software helps designers create realistic characters and visual effects. It supports operating systems including Windows, Linux, and macOS.
Houdini
Houdini is 3D procedural software developed by SideFX to create different VFX, lighting, and rendering in video games, films, advertising, and so on. It can run on Windows, Linux, and macOS.
Modo
Modo is a software package developed by Luxology for modeling, sculpting, rendering, and more. It incorporates n-gons and edge weighting features and runs on Windows, Linux, and macOS.
This definition was updated in January 2022 by Siji Roy.