Conventions
In this book, you will find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.
Code words in text are shown as follows: "The ambient component is computed and stored in the variable named ambient
".
A block of code is set as follows:
#version 400 in vec3 LightIntensity; layout( location = 0 ) out vec4 FragColor; void main() { FragColor = vec4(LightIntensity, 1.0); }
When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:
QGLFormat format;
format.setVersion(4,0);
format.setProfile(QGLFormat::CoreProfile);
QGLWidget *myWidget = new QGLWidget(format);
New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "The four corners of the quad are given by: e0 – ext, e0 – n – ext, e1 + ext, and e1 –n + ext as shown in the preceding diagram".
Note
Warnings or important notes appear in a box like this.
Tip
Tips and tricks appear like this.