Jump to content

Josh

Staff
  • Posts

    23,101
  • Joined

  • Last visited

Everything posted by Josh

  1. Quite a lot of Steamworks is exposed already: https://www.ultraengine.com/learn/Steamworks?lang=cpp There is also support for XBox controllers here: https://www.ultraengine.com/learn/GamePad?lang=cpp I have not used Steam input myself. I did some work with their early Steam controller API, but I think that got deprecated.
  2. I just updated the editor with the recent fixes.
  3. When I modify the shadow casting setting of a model in the asset window, the view updates instantly in the main window viewports, before I even save the model.
  4. Is there still any problem with this?
  5. I think this is the same thing:
  6. Directional lights will now use the camera for the LOD distance.
  7. Josh

    Thumbs

    Any problems still?
  8. It works now. I believe this is fixed. I don't understand what is supposed to happen in the code you posted, so please let me know if anything is not right.
  9. Fixed Camera::SetUniform integer variables. Added Camera::SetUniform Mat3 and Mat4 overloads. Camera::SetUniform texture will work with either a GLSL uvec2 or a uint64.
  10. Wouldn't it have to be cast to a uvec2? The first four bytes could form a zero and the second four bytes could be another value, and an uint would not detect that.
  11. I will do this so it will choose the type based on what is in the shader, and you can use either. It also stores a shared pointer to the texture so it can't get deleted as long as it is bound to the shader: void RenderShader::SetUniform(const int location, std::shared_ptr<RenderTexture> tex) { if (not Finalize()) return; if (location < 0 or location >= uniforms.size()) return; auto& u = uniforms[location]; if (u.defined and u.resource == tex) return; if (u.size != 1) return; GLuint64 handle = 0; switch (u.type) { case GL_UNSIGNED_INT64_ARB: if (tex) handle = tex->GetHandle(); glProgramUniformHandleui64ARB(program, u.location, handle); break; case GL_UNSIGNED_INT_VEC2: if (tex) handle = tex->GetHandle(); glProgramUniform2uiv(program, u.location, 1, (GLuint*)handle); break; default: return; break; } glCheckError(); u.defined = true; u.resource = nullptr; if (handle) u.resource = tex; }
  12. The only downside is you can no longer check if the value is 0 to disable the texture.
  13. Don't use integer uniforms right now.
  14. No, that will go out tomorrow.
  15. Josh

    AppendFile

    https://www.ultraengine.com/learn/Stream_Write?lang=cpp
  16. Okay, it must just be standard shadow acne then. The default setting needs adjustment.
  17. What GPU do you have? I do not see anything on my GEForce 1080 in the editor.
  18. I think this occurs because of the asynchronous culling system. If I implement GPU culling this problem will be automatically fixed.
  19. @SpiderPig In the attached map, I disabled shadows on the spotlight. Do you see the same banding pattern in this map? Does it occur in the editor or only in the game? start.zip
  20. Here is an example program. The thickness parameter will work in the next build that goes up: #include "UltraEngine.h" #include "ComponentSystem.h" using namespace UltraEngine; int main(int argc, const char* argv[]) { //Get the displays auto displays = GetDisplays(); //Create a window auto window = CreateWindow("Ultra Engine", 0, 0, 1280*2, 2*720, displays[0], WINDOW_CENTER | WINDOW_TITLEBAR); //Create a world auto world = CreateWorld(); //Create a framebuffer auto framebuffer = CreateFramebuffer(window); //Create a camera auto camera = CreateCamera(world); camera->SetClearColor(0.125); camera->SetFov(70); camera->SetPosition(0, 0, -2); //Create a light auto light = CreateBoxLight(world); light->SetRotation(35, 45, 0); light->SetRange(-10, 10); //Create a box auto box = CreateBox(world); camera->AddPostEffect(LoadPostEffect("Shaders/Outline.fx")); //camera->SetUniform(0, "Thickness", 50); //Main loop while (window->Closed() == false and window->KeyDown(KEY_ESCAPE) == false) { box->Turn(0, 1, 0); world->Update(); world->Render(framebuffer); } return 0; }
  21. If I increase the number of sounds I am getting a syntax error in another part of the code...invstigating further...
  22. How do I trigger the bug in your program? I tried adding this code right before the main loop but there was no error: sounds = {} for t=1, 28 do sounds[t] = LoadSound("https://raw.githubusercontent.com/UltraEngine/Documentation/master/Assets/Sound/notification.wav", LOAD_UNMANAGED ) end sounds[28]:Play() while window:KeyDown(KEY_ESCAPE) == false and window:Closed() == false do
×
×
  • Create New...