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 - mystb

Pages: [1]
1
Graphics / Re: sfml2.0-rc pushStates/poStates crash (with Horde3d)
« on: April 10, 2013, 02:02:08 pm »
It's funny that the texture matrix always fails, and nothing else. Do you get the same error with a SFML-only program?

Not at all. No errors, no warnings. Everything is correct. I just tried something now... I commented out every piece of horde3d interaction, but not h3dInit(), and I get this behavior too. Commenting it, everything works, enabling it, it gives the same results as with everything in.

Quote
You can test many graphics API, but... one at a time ;)

I've seen that it's a recurring subject on the forum :) It says something (good) about SFML, doesn't it?  ;)

2
Graphics / Re: sfml2.0-rc pushStates/poStates crash (with Horde3d)
« on: April 10, 2013, 12:47:12 pm »
Which version of SFML are you using? Or maybe you can directly tell me which are the OpenGL calls that fail at lines 252, 269 and 469.

251: glCheck(glMatrixMode(GL_TEXTURE));
252: glCheck(glPushMatrix());

268: glCheck(glMatrixMode(GL_TEXTURE));
269: glCheck(glPopMatrix());

468: glCheck(glMatrixMode(GL_TEXTURE));
469: glCheck(glLoadMatrixf(matrix));

Oops... I had glCheck... sorry. I was searching for SFML/Graphics/GLcheck.hpp, that's why I couldn't find it.

my tgz file with sfml source is named: LaurentGomila-SFML-2.0-rc-114-g03b8a1c.tar.gz

I'm not sure that mixing SFML with a 3D engine is a good thing to learn. I couldn't even tell you what behaviour to expect from such a combination. To me it's more a hack than a cool thing to try. And it's not fun.
I'm really starting on this 2D or 3D stuff and as many people, I don't have a clear objective, so I just started to collect some stuff that I *though* it should be useful some day. Maybe its time to lay down some plans and stay on track. But, if you don't mind helping out, I would like to track this down :)

3
Graphics / Re: sfml2.0-rc pushStates/poStates crash (with Horde3d)
« on: April 10, 2013, 12:23:07 pm »
My sfml version doesn't have glcheck.hpp/cpp, so I hacked one.

With this function:
function c:tick()
        self:setWireFrameMode(self.d3doptions.WireFrameMode)
        self:setDebugViewMode(self.d3doptions.DebugViewMode)
        c.handlers.window:clear()
        self.camera.object:update()
        llrender.render(self.camera.object)

        print("BEFORE PUSHSTATES")
        c.handlers.window:pushStates()
        print("BEFORE 2DTICK")
        c.handlers.overlaymanager:tick(self.dimensions)
        print("AFTER 2DTICK")
        c.handlers.window:popStates()
        print("AFTER POPSTATES")
        print(testgl())
        print("AFTER GLTEST")
        llrender.finalize()    
        c.handlers.window:display()
end
 
I get this output:
BEFORE PUSHSTATES
An internal OpenGL call failed in RenderTarget.cpp (252) : GL_INVALID_OPERATION, the specified operation is not allowed in the current stat

BEFORE 2DTICK
An internal OpenGL call failed in Texture.cpp (469) : GL_INVALID_OPERATION, the specified operation is not allowed in the current state
An internal OpenGL call failed in Texture.cpp (469) : GL_INVALID_OPERATION, the specified operation is not allowed in the current state
An internal OpenGL call failed in Texture.cpp (469) : GL_INVALID_OPERATION, the specified operation is not allowed in the current state
An internal OpenGL call failed in Texture.cpp (469) : GL_INVALID_OPERATION, the specified operation is not allowed in the current state
An internal OpenGL call failed in Texture.cpp (469) : GL_INVALID_OPERATION, the specified operation is not allowed in the current state
AFTER 2DTICK
An internal OpenGL call failed in RenderTarget.cpp (269) : GL_INVALID_OPERATION, the specified operation is not allowed in the current stat

AFTER POPSTATES
GL_VERTEX_ARRAY:no error
GL_COLOR_ARRAY:no error
GL_TEXTURE_COORD_ARRAY:no error

 
and this on screen (image is small but what I get is just colored blocks):


any idea?

4
Graphics / Re: sfml2.0-rc pushStates/poStates crash (with Horde3d)
« on: April 10, 2013, 11:52:58 am »
I'll look at the docs, and try your suggestion.

About the 2D,3D question: I know that Horde3D also has overlay support, but my intention here is to learn and have fun. For starters, I might do a pong clone with it  :P I know that I could code something in two days, without lua, tolua and horde3d, but maybe I can learn something in the process.

Thanks for your help, I'll give feedback.

5
Graphics / sfml2.0-rc pushStates/poStates crash (with Horde3d)
« on: April 10, 2013, 11:30:11 am »
Hi all,

 I'm trying to run a c++ + lua + sfml + horde3D environment.
Everything is running, e.g., I can draw 2D stuff with sfml and I can draw 3D stuff with Horde3D... but not at the same time. If I enable both it just crashes.

I've asked for help on gamedev (http://www.gamedev.net/topic/641539-mixing-sfml-and-horde3d-operation-not-allowed-in-current-state/ ) but thinking about it, I might have a better chance of finding some help here.

Window Creation:
function window:create(cfg)
  ...
  ...
  llwindow.set_window_style(style)
  llwindow.create_window(title)               -- SFML::RenderWindow

  self:pushStates() -- [1]
end
 
So, here is my main render loop:
function render:tick()
   self:setWireFrameMode(self.d3doptions.WireFrameMode)    -- HORDE3D specific
   self:setDebugViewMode(self.d3doptions.DebugViewMode)    -- HORDE3D specific
   window:clear()                                          -- SFML::RenderWindow
   self.camera.object:update()                             -- HORDE3D specific
   llrender.render(self.camera.object) --[2]               -- HORDE3D specific

   window:popStates() --[3]                                -- SFML::Window
   window:resetStates() --[4]                              -- SFML::Window
   overlaymanager:tick(self.dimensions) --[5]              -- SFML::Text, SFML::Sprite, etc....
   window:pushStates() --[6]                               -- SFML::Window
   
   llrender.finalize()   --[7]                             -- HORDE3D specific
   window:display()                                        -- SFML::Window
end
 
With 1,3,4,5,6 enabled and 2,7 commented out, SFML outputs ok, but outputs this message once:
 An internal OpenGL call failed in RenderTarget.cpp (269) : GL_INVALID_OPERATION, the specified operation is not allowed in the current state
 
With 1,3,4,5,6 commented and 2,7 enabled Horde3d outputs ok.
With any combination of these... app crashes first time that llrender.render(self.camera.object)  is called or after outputting several GL_INVALID_OPERATION messages like above.

Any help would be appreciated  :)
P.S: sorry for my spelling/grammar, I'm portuguese.
(Edited for formatting)

Pages: [1]
anything