Instant GLEW [Instant]


This title is available as an eBook only
Instant GLEW [Instant]
eBook: $14.99
Formats: PDF, PacktLib, ePub and Mobi formats
$12.74
save 15%!
Print & eBook also available on:
Learn in an Instant - Short, Fast, Focused
Overview
Table of Contents
Author
Support
Sample Chapters
  • Learn something new in an Instant! A short, fast, focused guide delivering immediate results
  • Learn about the usages of GLEW and how to use OpenGL extensions in your programs
  • Learn about the functionalities of GLEW
  • Discover utilities to use OpenGL extensions
  • You can find the updated code here.

Book Details

Language : English
eBook : 42 pages
Release Date : July 2013
ISBN : 1783280476
ISBN 13 : 9781783280476
Author(s) : Ashwin Nanjappa
Topics and Technologies : All Books, Application Development, Instant, Open Source

Table of Contents

Instant GLEW
  • Instant GLEW
    • So, what is GLEW?
      • OpenGL
      • OpenGL extensions
      • GLEW
    • Installation
      • Step 1 – what do I need?
      • Step 2 – downloading GLEW
      • Step 3 – configuring GLEW header and library paths
        • Method 1 – using standard paths
        • Method 2 – using relative paths
      • Step 4 – configuring GLEW library and DLL files
      • And that's it!
    • Quick start – using GLEW
      • Step 1 – using an OpenGL program to display a teapot
      • Step 2 – using OpenGL extensions to apply vertex and fragment shaders
      • Step 3 – including the GLEW header file
      • Step 4 – initializing GLEW
      • Step 5 – checking if an OpenGL extension is supported
      • Step 6 – calling OpenGL extension functions
    • Top 5 features you need to know about
      • Checking GLEW and OpenGL versions
        • Using older versions of GLEW
      • OpenGL extensions specific to Windows
      • visualinfo and glewinfo
        • visualinfo
        • glewinfo
      • The OpenGL Extensions Viewer
      • Accessing function pointers of extensions manually
    • People and places you should get to know
      • Official sites
      • Community
      • Books

Ashwin Nanjappa

Ashwin Nanjappa is a post-doctoral research fellow at the Bioinformatics Institute of Singapore. He works on GPU algorithms for drug discovery and matching drug molecules. He holds a Ph.D. in Computer Science from the National University of Singapore specializing in massively parallel GPU algorithms for 3D computational geometry. He likes writing software using CUDA, OpenGL, C++, and Python and loves tinkering with open source tools. He blogs regularly about programming at http://choorucode.com.
Sorry, we don't have any reviews for this title yet.

Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


Errata

- 2 submitted: last submission 02 Sep 2013

Errata type: Code    Page No: 16
Step 6 – calling OpenGL extension functions

void setShaders()

{
v = glCreateShaderObjectARB(GL_VERTEX_SHADER_ARB);

f = glCreateShaderObjectARB(GL_FRAGMENT_SHADER_ARB);

This should be:

GLhandleARB v;

GLhandleARB f;

GLhandleARB p;

void setShaders()

{

v = glCreateShaderObjectARB(GL_VERTEX_SHADER_ARB);
f = glCreateShaderObjectARB(GL_FRAGMENT_SHADER_ARB);

Errata type: Code    Page No: 17
The second code snippet under Step 6 – calling OpenGL extension functions

char* readShaderFile(const char* fname)

{

FILE* f = fopen(fname, "r");

fseek(f, 0, SEEK_END);

const long charNum = ftell(f);

This should be:

#include <cstdio> 

char* readShaderFile(const char* fname)

{

FILE* f = fopen(fname, "r");

fseek(f, 0, SEEK_END);

const long charNum = ftell(f);

Sorry, there are currently no downloads available for this title.

Frequently bought together

Instant GLEW [Instant] +    Java EE 5 Development using GlassFish Application Server =
50% Off
the second eBook
Price for both: $24.00

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • Learn how to install GLEW on Windows and build your programs to use it
  • Learn how to employ OpenGL extensions in your program
  • Explore all the functions and capabilities of GLEW
  • Learn about applications that make use of OpenGL extensions interesting

In Detail

3D graphics hardware is evolving quickly and expanding across devices ranging from smartphones to tablets to computers. OpenGL Extensions help vendors to expose the cutting-edge features of their hardware to developers in a usable manner. However, the mix of different hardware and operating system versions can make the use of these extensions quite difficult. The solution to this is the OpenGL Extension Wrangler (GLEW) library.

"Instant GLEW" is a quick guide to learn how to install GLEW on Windows and how to use it in your OpenGL programs. You will learn how to use any OpenGL Extension you want in your program in a safe and portable manner.

"Instant GLEW" explains how OpenGL Extensions are used to expose cutting-edge features through the OpenGL API. You will learn how to install GLEW on Windows and configure your OpenGL program to build with it. The book starts with an introduction to GLEW and details the benefits of its usage in OpenGL programs.

Later, the book guides you through configuring Visual Studio or a Linux compile environment for using GLEW. This book comprises of short codes that illustrate simple common extensions. You will also find out about alternatives to GLEW and how to use extensions without GLEW.

Approach

Get to grips with a new technology, understand what it is and what it can do for you, and then get to work with the most important features and tasks. A starter guide that walks you through the GLEW library and its utilities.

Who this book is for

"Instant GLEW" is a guide for students learning OpenGL programming and is also useful for graphics and game developers who want to use GLEW to write portable and feature-filled OpenGL applications and games. Experience with any programming language (C, Java, Lisp, Javascript, and so on) is better to fully understand the code, but is not necessary.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software