# Search:

Type: Posts; User: Agent D

Page 1 of 10 1

1. ## Thread: How to write commands in Vertex Shader to rotate points?

by Agent D
Replies
15
Views
661

### "left multiplying" a vetor with a matrix is when...

"left multiplying" a vetor with a matrix is when I write the vector to the left of the opartor and the matrix to the right.
In this case, the vector must be a row vector and the result is a row...
2. ## Thread: program for flowing fountain, what is eachh function actually doing

by Agent D
Replies
1
Views
107

### You need to perform the following steps: ...

You need to perform the following steps:

Learn the programming language used in this program
Learn OpenGL(R)

"Here have some code, explain it to me" won't work. Even...
3. ## Thread: How to write commands in Vertex Shader to rotate points?

by Agent D
Replies
15
Views
661

### How the vectors are stored in memory and how they...

How the vectors are stored in memory and how they are accessed is irrelevant.

GLSL interprets the vec2, vec3 and vec4 data types as column vectors.

Try it out. If you flip it around, your...
4. ## Thread: No color shown in this simple code?

by Agent D
Replies
16
Views
412

### Do you mean that nothing is drawn or that the...

Do you mean that nothing is drawn or that the color is not the one you want?

Also, (0.0,1.0,1.0) is more turquoise than blue.
5. ## Thread: How to write commands in Vertex Shader to rotate points?

by Agent D
Replies
15
Views
661

### No. Since v_position is a column vector, we...

No. Since v_position is a column vector, we right-multiply it with the matrix. If it was a row vector, we would left multiply it with the
transpose matrix, to get the transpose of the result (i.e....

by Agent D
Replies
2
Views
134

void parse_file_into_str(const char* file_name, std::string shader_str)
{
std::ifstream file(file_name);
while (file.good())
...
7. ## Thread: How to write commands in Vertex Shader to rotate points?

by Agent D
Replies
15
Views
661

### This is probably the simplest vertex shader...

This is probably the simplest vertex shader applying a transformation:

#version 330

uniform mat4 matrix;

layout(location=0) in vec4 V_POSITION;

void main( )
8. ## Thread: How to write commands in Vertex Shader to rotate points?

by Agent D
Replies
15
Views
661

### As has been suggested to you many times before:...

As has been suggested to you many times before: Read a beginner tutorial.

You need to get at least some basic knowledge of linear algebra.

Rotating a vector around the origin is a linear...
9. ## Thread: use a custom color paletted texture

by Agent D
Replies
3
Views
176

### AFAIK older versions (and compatibillity profile)...

AFAIK older versions (and compatibillity profile) did support color index mode and color index textures, but current, core profile GL
does not support that anymore.

But it can be easily emulated...

by Agent D
Replies
2
Views
253

### Simple: Draw a bunch of lines. Similar to drawing...

Simple: Draw a bunch of lines. Similar to drawing triangles, except you use the GL_LINES mode instead of GL_TRIANGLES.

Use a simple vertex shader that only applies a transformation and a fragment...
11. ## Thread: Is it always good to use Vec3f / Vec4f class defined by yourself?

by Agent D
Replies
3
Views
364

### If you do not intend to do any mesh processing or...

If you do not intend to do any mesh processing or collision detection, etc..., keeping track of faces or other high level topology data

As long as you only want to...
12. ## Thread: Drawing rectangular tiles

by Agent D
Replies
4
Views
333

### Considering your use case, why don't you simply...

Considering your use case, why don't you simply use a textured rectangle? You draw stuff locally in memory and update portions of
the texture that change. You use nearest-neighbour sampling for the...
13. ## Thread: Drawing rectangular tiles

by Agent D
Replies
4
Views
333

### First of all, if you want "big pixels", why don't...

First of all, if you want "big pixels", why don't you use "big pixels" by switching to a lower resolution?

Second, your memory usage could be improved by using an indexed rendering, i.e. you have...
14. ## Thread: ATI HD4650 not OpenGL 2.0?

by Agent D
Replies
2
Views
324

### You need to install the drivers for your graphics...

You need to install the drivers for your graphics card.

In your screenshot, it says "OpenGL 1.1 (GDI Generic with 2 ext.)". This is the default, built in, fallback software driver
that Windows(R)...
15. ## Thread: glCallLists and Unicode

by Agent D
Replies
9
Views
735

### First of all, you have to find out what you are...

First of all, you have to find out what you are actually trying to accomplish. I can't think of any application that will ever need all unicode code points at the same time.

If you want to use...
16. ## Thread: Solid circle with OpenGL

by Agent D
Replies
5
Views
884

### muthuveera, you might want to re-read the...

muthuveera, you might want to re-read the original post that startet this thread.

The function you pasted here uses deprecated glBegin/glColor/glVertex/glEnd calls and the circle it produces is...
17. ## Thread: GLSL; return statement ...

by Agent D
Replies
7
Views
536

### You have to understand how the processor...

You have to understand how the processor architecture that this is run on works. Branches in general are very bad for performance.

Shader executions are basically divided into groups, where each...

by Agent D
Replies
2
Views
304

### What problem? This function call binds "position"...

What problem? This function call binds "position" to vertex attribute array 0. Above you configured the vertex attribute 0 to be read from the specifed VBO.

There is your problem. You are not...
19. ## Thread: Creating a square where I am able to drag one corner

by Agent D
Replies
8
Views
706

### That doesn't make sense. Scaling means...

That doesn't make sense. Scaling means multiplying it by some factor. That is something completely different than moving one corner.

What I had in mind was something like this:

struct
{
...
20. ## Thread: Creating a square where I am able to drag one corner

by Agent D
Replies
8
Views
706

### First of all, that code shouldn't even compile....

First of all, that code shouldn't even compile. You have a function declaration inside your OnMouseClick function.

Second, what was that code intended to do? Scale the polygon when the mouse...
21. ## Thread: Unified and Khronos guided Opengl Development strategy tools humbly requested.

by Agent D
Replies
8
Views
643

### And you think a magic, pre-packaged IDE is a good...

And you think a magic, pre-packaged IDE is a good solution? That's one of the things I absolutely hated in electronics engineering. Almost every microcontroller vendor seems to think like that.
"You...
22. ## Thread: NULL returned from glfwCreateWindow when setting OpenGL context hints

by Agent D
Replies
2
Views
451

### This sounds like your implementation does not...

This sounds like your implementation does not support OpenGL(R) 3.2.

No.[/QUOTE]
We have the GLFW source code. Of course we can debug it and step into glfwCreateWindow. But I don't think that...
23. ## Thread: Creating a square where I am able to drag one corner

by Agent D
Replies
8
Views
706

### Handling mouse clicks, etc. is not part of...

Handling mouse clicks, etc. is not part of OpenGL(R). The OpenGL(R) specification onyl specifies an abstract API for rasterization based rendering.

Managing a window and handling mouse clicks has...
24. ## Thread: Best Way to Store Texture or Image Information in a File

by Agent D
Replies
6
Views
646

### There are functions related to SDL_RWFromFile...

There are functions related to SDL_RWFromFile that can write to a file pointer. Also, the "w" mode would only overwrite the file anyway, so you end up having a file
that contains the last image....
25. ## Thread: Solid circle with OpenGL

by Agent D
Replies
5
Views
884

### You couldn't draw a circle in fixed function GL...

You couldn't draw a circle in fixed function GL either.

There are multiple things that you could do to get circles:

Draw a triangle fan.
Draw a rectangle out of two triangles with an...
Results 1 to 25 of 247
Page 1 of 10 1