Questions tagged [gldrawpixels]
32 questions
6
votes
1 answer
Writing texture data onto depth buffer
I'm trying to implement the technique described at : Compositing Images with Depth.
The idea is to use an existing texture (loaded from an image) as a depth mask, to basically fake 3D.
The problem I face is that glDrawPixels is not available in…

sharvey
- 7,635
- 7
- 48
- 66
5
votes
3 answers
How to scale glDrawPixels?
I need to scale the result of glDrawPixels image.
I'm drawing a 640x480 pixels image buffer with glDrawPixels in a Qt QGLWidget.
I tryed to do the following in PaintGL:
glScalef(windowWidth/640, windowHeight/480,…

Hermandroid
- 2,120
- 4
- 29
- 35
4
votes
1 answer
opengl rotation using gldrawpixels
My team is currently limited to drawing images on an opengl 1.4 platform, which means that we can't use any nifty texture mapping to draw an image (yes, we're confined to using the intel integrated graphics platform, it's very annoying). So far,…

mmr
- 14,781
- 29
- 95
- 145
4
votes
3 answers
An alternative to glDrawPixels in OpenGL 3.0?
So I know that glDrawPixels is deprecated. Is there any function that does the same thing?
I thought of using textures, but they are modified by the current matrix, unlike pixels that are drawn by glDrawPixels.

Pilpel
- 231
- 1
- 7
- 11
2
votes
1 answer
How do I change color of pixels when using glDrawPixels, my pixels are always red
I have a function that draws pixels 1 by 1 on a window, but what I want to know is how to get the pixels to be drawn in a different color other than red. Thanks in advance. I've tried some stuff like glSetColor, glColor3f, etc. Just to try and get…

Eldandor
- 23
- 3
2
votes
2 answers
glutSwapBuffers "Access violation reading location 0x0000000004C0F000"
What I have to do is to display an image using a .ptm file.
So, I open the file, read the W and H and set the RGBA to each pixel. But when I try to display I get an Access Violation error at glutSwapBuffers().
Here is the code. It's kind of a mess…

Henrique Machado
- 21
- 3
2
votes
4 answers
Equiv of glDrawpixels that operates on GPU memory?
glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const ovid *pixels);
Is there a function like this, except instead of accessing CPU memory, it accesses GPU memory? [Either a texture of a frame buffer object]

anon
- 41,035
- 53
- 197
- 293
2
votes
3 answers
Wrong pixel locations with glDrawPixels
I have been playing around with trying to draw a 320 by 240 full screen resolution image in opengl using java and lwjgl. I set the resolution to 640 by 480 and doubled the size of the pixels to fill in the space. After a lot of google searching I…

user137
- 282
- 2
- 14
1
vote
1 answer
Copy arbitrarily sized block of pixels into OpenGL ES texture... somehow?
I'm writing a drawing application, and the drawing canvas is an OpenGL texture. When you draw onto the canvas, it determines which region of the canvas texture has been changed, and copies that pixel data out (using glReadPixels) before applying the…

Ben Gotow
- 14,805
- 3
- 42
- 47
1
vote
1 answer
Jogl gldrawpixels() problem
I hope that this ends up being a simple question.
I'm using JOGL in Netbeans to create a checkerboard of pixels where you can specify the number of tiles in each row/col, and also the color of each of these tiles (draw this tile with 0 alpha, draw…

viperld002
- 329
- 4
- 17
1
vote
2 answers
Using Adobe Alchemy to get the OpenGL image from c++ code to flash app
I have C++ application that use OpenGL. Need to convert this app to flash app. Is it possible to do this with Adobe Alchemy? Is it will be possible to get from that swc current image (for example, with glDrawPixels) and print it on screen

EthanHunt
- 473
- 2
- 9
- 19
1
vote
1 answer
gldrawpixels on pyopengl not drawing anything?
I create pixels buffer to be drawn with glDrawPixels. The code run ok and the pygame window shows up. But nothing to be drawn, only a blank white window shown. Even if I change the value of buffer, it doesn't draw anything.
import pygame
from…

Zukaru
- 320
- 2
- 11
1
vote
2 answers
Native Activity, GLES2.0: Uploading pixel array to screen
I created a pixmap using, for example, this code
//...
// Native Activity
#define HEIGHT 600
#define WIDTH 600
uint32_t texDat[WIDTH*HEIGHT*4];
static double it = 0;
uint8_t color = sin(it)*256;
for (int i = 0; i < WIDTH; i++) for (int j = 0; j <…

Twaik Yont
- 102
- 10
1
vote
1 answer
Drawpixels by glfw only renderer quarter screen. buffer use screen width * height
I don't know how to resolve this problem, I want to use this function to make a soft-renderer engine to study 3D pipeline.
This is code:
#define GLFW_INCLUDE_GLU
#include
int main(int argc, const char * argv[]) {
…

CodeSuperHero
- 11
- 1
1
vote
1 answer
Why is glDrawPixels not working in here?
Here's the code. The output is a greyish square - all the time, no matter what the input is and its clearly wrong. My objective is to be able to have all the pixels stored somewhere and display them so I can move on to a simple ray tracer and I…

whoadrian
- 77
- 1
- 7