How to add an image/C++ OpenGL?


Posted on 16th Feb 2014 07:03 pm by admin

Hi,

I have been trying to look online for this and, so far, I haven't found anything useful. I would like to add a .bmp image to an OpenGL window. The lines here (GL_LINES), are irrelevant, something else to put with the image.

I’m fairly new to C++. I would appreciate it if anybody could help with anything.
1
2
3
4
5
6
7
8
9
10
11
12
void myDisplay(void) { glClear(GL_COLOR_BUFFER_BIT); // clear the screen glBegin(GL_LINE_LOOP); glVertex2i(318,0); glVertex2i(318,250); glVertex2i(322,250); glVertex2i(322,0); glEnd(); //I want to add "Tiger (left)_.bmp" here glFlush(); // send all output to display }
Thanks.

No comments posted yet

Your Answer:

Login to answer
319 Like 48 Dislike
Previous forums Next forums
Other forums

passthru() help
Hi everyone,
I'm new to the forum and to PHP. I have some pretty good experience writing shell sc

Not Loading Function Into Div
I'm not sure whether to put this under the php forum or ajax forum but because I tink it's more of a

Add "width" check when upload
Hi!

Can someone add a function that is checking if picture witdh is bigger then 800px whwn up

A little help needed passing hidden values to next page
I have a page that has hidden values in a form.

example
Code: <input name='signupID

Inserting a variable in a link
I have this code that I want to insert for my own variable but I have no idea how. This is what I wa

Converting numbers to months
The porgram works -just need the last function(month_convert_ to convert numbers to months -thanks.

Open/Close Links in Php
Hello, Hoping someone can inform me how I can get PHP to automatically open a set of links in a new

imap: how to save a copy of sent emails to sent elements
Hello my friends,

I am writing an online emailing application with inbox outbox/sent elements

date function help
i need help with date function

Code: [Select]<!DOCTYPE HTML PUBLIC "-//W3C//DTD H

Help building / using array
First - this is a cross-posting, if this is wrong I apologise! What started out as a MySQL query que

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash