• Content count

  • Joined

  • Last visited

Community Reputation

373 Neutral

About Sagaceil

  • Rank
  1. 8Suns

    Explore the world ruled by empires that inevitably awaits destruction. Immoral lifestyle all major societies led to an internal collapse, and this in turn made it possible to spread anarchy and heresy. Guard stands Kshatriya - the Order of Inquisitors, who seek with a firm hand to keep order. At the time of the greatest trials, there is something unexpected - the majority of members of the Order disappears. With the old guard, only a few inquisitors still serve the law. One of them is Saanjh, who tried to find out about the mysterious disappearance of his brothers.
  2. Error with shaders - OpenGL

      It seems like strings are created from function, then you getting c_str of them. Now strings are destroyed, but pointers are still in use. Try to do something like: const std::string vertSource = FileUtils::read_file(m_VertPath); const std::string fragSource = FileUtils::read_file(m_FragPath); // ... glShaderSource(vertex, 1, &vertSource.c_str(), NULL); // same for fragment // ... This way, strings are remaninbg for whole function scope and keeps valid c_str pointers.
  3. When Im importing textures to engine, Im doing offline compression using close fit range compression. So I have to ananlize whole 4x4 blocks as an input. When loading textures , they are in compressed format arleady, and the last mipmaps are stored as a raw RGB(A) data.
  4. Ok, solved.   I'm uploading compressed mipmaps using glCompressedTex* ( mipmaps with size >= 4px ) and using glTexImage* with GL_COMPRESSED_RGB(A) for lower mipmaps.
  5. So actually theres no way to use compressed textures and use lower size than 4px. I supposue that compression require 4x4 px blocks to be compressed.
  6. Is it posible to use both compressed and uncompressed texture data when uploading mipmaps for texture ? I'm working on better streaming system for textures with seamless transition beetwen mipmap lvl's.  So far so good. Everything working fine untill I'm uploading non compressed data using glTexImage. I'm setting GL_TEXTURE_MAX_LEVEL to the last (1x1) mipmap index but it seems that texture gets uncompletness when that happen. I'm forced to set GL_TEXTURE_MAX_LEVEL as the last compressed mipmap and then it works. My question : bcoz glTexImage doesnt return any GL Error, is it possible to use non compressed data with compressed in another mipmaps ( compressed data works great when te resolution is >= 16, i need <16 texture mipmaps to avoid aliasing ).   Thanks for any help ! :)
  7. OpenGL FullScreen and OS cursor

    I'm using AllegroGL to initialize the window. GUI is rendering afret whole 3D part, and then my own mouse curosor onto the main framebufer. Flip at the end. I tried to find all chain of functions that are call when window init. But theres no entry about hiding coursor in full screen. Heres these functions : 1) allegro_gl_win_init_fullscreen 2) allegro_gl_win_init I'll try to make some experiments to force ShowOsCuros after every Flip.
  8. Hello, I have some quick question. I'm trying to create a mouse cursor under fullscreen mode of OpenGL. I've seen that many games ( usually MMO's ) have a OS cursor system in fullscreen mode of the game - thats why it hase independedt thread of mouse rendering and it has all features like acceleration, speed set up in system. Another advantage is that fps doesnt affect of the refreshing mouse cursor. Is it possible ( and how , if not regular API ) to create a fullscreen OS mouse cursor. ( tried to use ShowCursor, LoadCursor etc, but it seems not to work propertly ). Thatnks for any answers.
  9. 2D text + depth test

    Done: [img][/img]
  10. 2D text + depth test

    I tried AION to find some solutions, and there are that kind of hiding texts. I'll try some 3D text, and post if it works.
  11. Hello, I'm writing a game, and I found some ( not so big ) problem. I have a players on the scene and I'm trying to print theyrs nick. So I just use gluUnproject and I'm recieving a 2D window position of 3D point. My question: how to use a depth buffer ( using pipe line , dunno maybe some matrix tricks ), to when I'm printing a text. Becaouse now I'm using a Orthogonal mode, when the far and near planes are the same ( and different than 3D planes ), so theres no chance to simply turn on depth testing. Screenshot: Here you can see that the tree is behind 'Sagaceil'. I'd like to test depth buffer correctly so if something covers text it shouldn't be visible. Thank you for any ideas..