CFanatic

Go Back   CFanatic > Advance Programming > OpenGL Programming

Join CFanatic Forum Now

OpenGL - Display single color channel topic posted under OpenGL Programming which is a part of Advance Programming category in CFanatic Forum
Reply
 
Thread Tools Display Modes
  #1  
Old 06-22-2010, 07:21 AM
Junior Member
 
Join Date: Jun 2010
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
lechoo is on a distinguished road
| More
OpenGL - Display single color channel

Hi,
using imagemagick I'm loading image form file. Code below gives normal RGB colors.

im.read(filename);
im.write(&blob, "RGB", 8);
glTexImage2D(GL_TEXTURE_2D, 0, 3, im.columns(), im.rows(), 0, GL_RGB, GL_UNSIGNED_BYTE, blob.data());

Then texture is applied onto geometry.

Is it possible to force OpenGL to display only (for example) green channel but in all color components, I'm looking for something like GL_GGG. I want to avoid reloading different color components every time user wants to see different color channel.

regards
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
display Text on right side kinnera MFC Programming 3 01-24-2010 10:49 PM
Vibrant new color shabbir Announcements 0 01-15-2009 05:11 AM
C++ openGL User_m2vdvm OpenGL Programming 0 04-08-2007 10:40 PM
Display bitmap in different app's window? ajcrm125 Win32 Programming 0 09-30-2006 06:49 PM
VS 2005 - MFC Dialog won't display in resources cmplx80 Driver Development 0 09-29-2006 06:17 AM

 

Advertisement

CFanatic Search
Custom Search

Advertisement

All times are GMT -5. The time now is 01:51 AM.



Powered by vBulletin® Version 3.7.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO ©2010, Crawlability, Inc.
Cfanatic.com is a premier member of the IDG TechNetwork. For advertising opportunities contact here
Get Paid for Working on Projects Matching Your Expertise at Go4Expert's Jobs Board