Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
D

dspdad010

@dspdad010
About
Posts
3
Topics
1
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • opengl (openTK)
    D dspdad010

    Using unsigned byte in the GL code works much better. Thanks for the suggestion. Still have to verify on the laptop if this solves all or only some of the issues. I also tried copying to a bitmap :

    using (Graphics g = Graphics.FromImage(bitmap))
    {
    g.CopyFromScreen(bounds2.Location, Point.Empty, bounds2.Size);
    }

    which returns the 'right' values from 0..255.

    Graphics winforms graphics game-dev question

  • opengl (openTK)
    D dspdad010

    Using OpenTK in devStudio 15 and windows forms on my dell desktop. When I render a color (eg red = 255, 0, 0, 255), and read the results back it is about, but not quite half of the written value, eg 127, 0, 0, 127.

    private void GetHitMap()
    {
    // copy hitmap from screen
    IntPtr unmanagedPointer = Marshal.AllocHGlobal(_hitMap.Length);
    GL.ReadBuffer(ReadBufferMode.Back);
    GL.ReadPixels(0, 0, renderCanvas.Width, renderCanvas.Height, PixelFormat.Rgba, PixelType.Byte, unmanagedPointer);
    Marshal.Copy(unmanagedPointer, _hitMap, 0, _hitMap.Length);
    Marshal.FreeHGlobal(unmanagedPointer);
    }

    On a laptop, running the same code, same extremely simple shaders, but different gpu, the red is sometime red on the screen, and sometimes 'half red' and the values I read back are sometimes not exactly half, Using a framebuffer in opengl instead of Marshalling gives the same results. All other colors and using r,g,b or any combination gives the same result. I was planning to use 'designated colors' to identify objects, similar to a shadow map, but the colors are not consistent. Is this a known or expected behavior? Is it fixable? Running out of things to look for.

    Graphics winforms graphics game-dev question

  • Is it Sequel or S Q L Server, Interview Gripes
    D dspdad010

    There are at least two types of programmers. Those who have a field of expertise applicable to a well-defined project, vs. those who can understand the problem being addressed and can then evaluate the tools and solutions which might be considerations in solving the problem. Your commentary seems to put you into the second category. You'd probably never fit in a company that worries about correct pronunciation of acryonyms, so getting past the swamp of sadness without getting sucked in should be considered a plus. I run an engineering department, and here is my caveat. (or C.V.T., no just kidding) Both types of people are needed, but the second type are much harder to find.

    The Lounge csharp database career asp-net sql-server
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups