background preloader

Graphics

Facebook Twitter

Xlib programming manual: function index. Cairographics.org. OpenGL Texture Tutorial. OpenGL Texture Tutorial home: e-mail: craterz@hotmail.com Texture Mapping Gregory Pierce in an e-mail requested information on texture mapping... here ya go! Nowadays, textures are pretty much standard as far as games go. OpenGL was designed with this in mind. Unlike the cruel and unusual DirectX API, creating textures is not a form of cruel and unusual punishment.

The only thing you need be concerned with is setting up some texture parameters and environment. Texture Names To start things off, we first need a texture name. GLuint texture; // allocate a texture name glGenTextures( 1, &texture ); Now that we have our texture name, we can switch between different textures we want using the function glBindTxeture. // select our current texture glBindTexture( GL_TEXTURE_2D, texture ); Texture Parameters Now we can begin to work on our current texture. Next, we have four texture parameters we need to setup. Texture Image and Mipmaps Texture Sample. Blender 3D: Noob to Pro - Wikibooks, collection of open-content textbooks. You are strongly encouraged (read as begged) to contribute to this book! There are many things you can do to help: edit existing modules (to correct errors, improve the writing, or make additions)add new modules (tutorials or reference material)upload new images (screen shots or sample renders)join the team responsible for this WikiBook How to Edit a Module To edit any wiki page (including this one): Click on the Edit tab at the top of the page.Make your change in the large text box.Type an explanation of your change in the Edit summary text box below.Click on the Show preview button below the edit summary to preview your change.If you're satisfied with the result, click on the Save page button.

Your contribution will be reviewed before it is officially published. Things you shouldn't add to modules: external links that are not directly related to the modulecomments or questions regarding the text To ask questions and make comments about any module: How to Add a Module Images How to Join the Team. Basic Graphics Programming With The Xlib Library. [ LUPG Home ] [ Tutorials ] [ Related Material ] [ Essays ] [ Project Ideas ] [ Send Comments ] v1.0 Preface This tutorial is the first in a series of "would-be" tutorials about graphical programming in the X window environment. By itself, it is useless. After reading this tutorial, one would be able to write very simple graphical programs, but not programs with a descent user interface.

The Client And Server Model Of The X Window System The X window system was developed with one major goal - flexibility. This model is the complete opposite of what one is used to when dealing with clients and servers. The whole session is carried out using the X message protocol. GUI programming - the Asynchronous Programming Model Unlike conventional computer programs, that carry some serial nature, a GUI program usually uses an asynchronous programming model, also known as "event-driven programming". So the way a GUI program looks is something like that: Perform initialization routines.

Basic Xlib Notions.