Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Rosenzweig

Pages: [1]
1
Graphics / Segmentation Fault
« on: November 19, 2011, 07:40:31 pm »
Quote from: "Laurent"
Quote
The debugger says nothing

If there's a segmentation fault, it should say something. Do you know how to use it?


I ended up fixing the problem. Something was wrong with the debugger (Damn Codeblocks) and I had to fix it. So after fixing it, I removed a few OpenGL functions to find out that only 2 OpenGL 1.x functions worked. So, I basically had to redownload gl3.h, because the old one was corrupted or something (I have no clue). Basically, it works now. Thanks for the help.

2
Graphics / Segmentation Fault
« on: November 18, 2011, 10:54:34 pm »
Quote from: "Laurent"
Ok. What does the debugger say?


The debugger says nothing. I have a console window that pops up with my GUI. Basically I run the program, the GUI pops up for a moment, and then it disappears (terminates). Thus I am left with a console window saying "Segmentation Fault".

3
Graphics / Segmentation Fault
« on: November 18, 2011, 09:57:42 pm »
Quote from: "Laurent"
You never call Render() in your main. So no OpenGL function is called.

You'd better use your debugger to find out what's wrong in your code.


The link I gave you didn't show it, sorry. I removed the line to clear errors.

It gives me the segmentation fault when I do this:
Code: [Select]

OpenGL.Render();
Window.Display();

4
Graphics / Segmentation Fault
« on: November 18, 2011, 09:31:41 pm »
Quote from: "Laurent"
It seems that the second one is empty. It might be my fault, I edited your message to make the links clickable.


I fixed it. I was copying the links off my laptop, sorry for the mistake.

5
Graphics / Segmentation Fault
« on: November 18, 2011, 08:35:53 pm »
I just compiled my SFML 2.0 (with OpenGL 3.2) and I get a segmentation fault when I run the program. I guess it's because I call the OpenGL functions when a context does not exist. Can someone help resolve this? I guess this is more of a C++ general question, but I've been trying to resolve this for a while.

Here is my source code:
http://pastebin.com/chxfsk63 - main.cpp
http://pastebin.com/d8d6YtWU - hipstergl.cpp
http://pastebin.com/Qq6QaP9j - hipstergl.hpp

Basically, I make a class with a void function called "Render" in hipstergl.hpp. Then in hipstergl.cpp I insert some OpenGL API calls into the Render function. Then finally I set up my context settings into my Render window, create a while loop for the window, call the Render function and the Window.Display function.

6
Graphics / OpenGL 3.x will not work.
« on: November 17, 2011, 10:52:00 pm »
I just included glew and it made my problems magically go away. :D

7
Graphics / OpenGL 3.x will not work.
« on: November 17, 2011, 10:36:53 pm »
Quote from: "Laurent"
This is just confusing. Please give us the error message instead of your interpretations of it ;)


I'm a bit brain exhausted, because I just got out of calculus. Sorry.

Here are some of the errors I get:
error: 'glBindBuffer' was not declared in this scope.
error: 'glEnableVertexAttribArray' was not declared in this scope
error: 'glVertexAttribPointer' was not declared in this scope

Again, I believe this is a linker issue.

8
Graphics / OpenGL 3.x will not work.
« on: November 17, 2011, 10:28:04 pm »
So I installed SFML 2.0, got it configured on Code::Blocks, and it's all set up on my laptop (Debian). However, it will not compile a simple project that uses OpenGL 3.x functions. It keeps saying they're not declared in scope. I think this is a linker issue. Is there any way to resolve this? I even passed the context settings as a parameter in the render window class that I use.

9
General / OpenGL which versions are supported/used?
« on: October 20, 2011, 06:55:22 am »
Quote from: "OniLink10"
ContextSettings.


Can you explain further? I just got done getting SFML 2.0 to work on my laptop.

SF:ContextSettings ContextSettings
ContextSettings.Major = 3;
ContextSettings.Minor = x;

I think I got it.

10
General / OpenGL which versions are supported/used?
« on: October 20, 2011, 12:16:54 am »
Apparently only SFML 2.0 supports OpenGL 3.x. Now to find out how it use 3.x or if it does it automatically.

11
General / OpenGL which versions are supported/used?
« on: October 19, 2011, 11:29:58 pm »
So I'm using SFML 1.6 and I do not wish to use OpenGL 2.x anymore. I like shaders and vertex buffers. Well anyways, does SFML 1.6 use a specific version of OpenGL? Do I have to make it use a specific version? Can SFML 1.6 even use OpenGL 3.x+ or what?

12
General / Expected a ';' before polygon... what?
« on: October 10, 2011, 11:16:04 pm »
Quote from: "Laurent"
Polygon is a Win32 function. I can't believe that the compiler is stupid enough (well, most likely the C++ rules rather than the compiler) to be stuck on this.


I've been stuck on this for 5 hours. HAHA, thanks. I'm not that good with classes so I thought I did something completely ass backwards in OOP. Thanks again.

13
General / Expected a ';' before polygon... what?
« on: October 10, 2011, 11:01:04 pm »
So I started messing around with SFML and only intended to use it for the window aspect of a game, not the actual rendering. Well, I now I have this issue at line 44 where it expects a ';' before polygon. The error itself makes no sense, so can someone help me?

Here is the pastebin:
pastebin.com/e4phVAGF

Pages: [1]
anything