stereogram | Renders single-image stereograms using WebGL | Computer Vision library

 by   moefh JavaScript Version: Current License: MIT

kandi X-RAY | stereogram Summary

kandi X-RAY | stereogram Summary

stereogram is a JavaScript library typically used in Artificial Intelligence, Computer Vision, WebGL applications. stereogram has no bugs, it has no vulnerabilities, it has a Permissive License and it has low support. You can download it from GitHub.

Renders single-image stereograms using WebGL. Try the online demo.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              stereogram has a low active ecosystem.
              It has 6 star(s) with 0 fork(s). There are 3 watchers for this library.
              OutlinedDot
              It had no major release in the last 6 months.
              stereogram has no issues reported. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of stereogram is current.

            kandi-Quality Quality

              stereogram has no bugs reported.

            kandi-Security Security

              stereogram has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              stereogram is licensed under the MIT License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              stereogram releases are not available. You will need to build from source code and install.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of stereogram
            Get all kandi verified functions for this library.

            stereogram Key Features

            No Key Features are available at this moment for stereogram.

            stereogram Examples and Code Snippets

            No Code Snippets are available at this moment for stereogram.

            Community Discussions

            QUESTION

            Anti-aliasing of random dot stereograms
            Asked 2018-Jan-21 at 13:56

            I recently completed some Python (2.7) code for generating random dot stereograms based on this paper. The output is fairly good, though I have noticed that, even with a smooth gradient in the depth map, the output stereogram lacks these smooth gradients, instead having varying levels of depth. I believe this to be due to the DPI chosen when generating the image. While the detail of the depth can be increased by increasing the DPI, this becomes impractical as the convergence point becomes more difficult to reach.

            Here are two examples. First at 75 DPI and second at 175 DPI. On the 75 DPI image, distinct "triangles" of depth can be seen. In the 175 DPI image, these are less pronounced but the guidance dots at the bottom of the image are further apart, and therefore viewing the 3D image is more difficult.

            I'm looking to modify my current code to anti-alias the 3D image in order to smooth out the gradients even with a lower DPI. I have tried using SSAA on the depth map and pattern and generating the stereogram, then reducing the image size again with an antialiasing filter. However this seems to just contain the stereogram to the left of the image. For example, if I make the image 4 times bigger, the stereogram is limited to the left hand quarter of the image. The rest is just random noise and cannot be viewed. How would I go about antialiasing the image hidden in the stereogram? My code is almost the same as the algorithm described in the paper, so an antialiasing algorithm based on that would be perfect.

            ...

            ANSWER

            Answered 2018-Jan-21 at 13:56

            The solution for the problem I was having, with the stereogram being contained to the left of the image, was caused by not extending the same array to reflect the larger depth map. This caused everything beyond the original length of the depth map to be randomly generated noise.

            After solving this problem, a second problem arose, in that the 3D image was distorted by the anti-aliasing, causing more gradient issues than it was solving. My solution for this was to increase the DPI setting in the code. For example, if I increased the size of the depth map by 4x, the stereogram must be generated with a DPI 4 times greater (300, rather than 75). When scaled down again, this produced excellent results.

            This image uses 2x SSAA, making the gradients comparable with the 175DPI image from the question, but with a much easier converging point.

            This image uses 4x SSAA, and I find the jaggies barely visible at all. The noise here becomes a lot more blurred and the general colour of the image becomes quite grey. I have found this effect can be avoided by pregenerating the noise and scaling that up by the same AA factor. This is demonstrated in the next image.

            Source https://stackoverflow.com/questions/48362837

            QUESTION

            How to create random-dot stereogram (RDS)?
            Asked 2017-Apr-11 at 13:45

            I am trying to understand and code a python script that create a random-dot stereogram (RDS) from a depthmap and a random-dot generated pattern. From what I've understood, to create the illusion of depth, pixels are shifted so when we make them merge by changing focus the difference of shifting creates the illusion.

            I put this into practice with this depth map:

            Here is the result:

            But I don't understand why I can see on the result 2 objects, 1 star "close" to me and an other star "far" from me. And there is different possible results depending of how I focus my eyes.

            I have read many things on the subject but I don't get it. Maybe the problem is my poor english or understanding of what I've read but I will appreciate some detailed explanations since there not that much technical explanations on the web about how to code this from scratch.

            Note: I have tried with different size on shift and pattern and it doesn't seem to change anything

            Code: (Tell me if you need other part of the code or some comment about how it work. I didn't clean it yet)

            ...

            ANSWER

            Answered 2017-Apr-11 at 13:45

            The problem "I can see on the result 2 objects, 1 star "close" to me and an other star "far" from me" is due to the fact that I get the wrong approach when I try to generalize my understanding of stereograms made with 2 images to stereograms using repeated pattern.

            To create 2 images stereograms you need to shift pixels of one image to make the depth illusion.

            What was wrong in my approch is that I only shift pixels that should create the star. What I didn't get is that because RDS are made by repeated patterns, shifting these pixels also create an opposite shifting with next patterns creating an other star of the opposite depth.

            To correct this I paired every point of the depth map (not only the white one) in order to come back to the base shifting amount after the end of the star.

            Here is the result:

            Code: (This code is the previous one quickly modified after the help of Neil Slater so it's not clean yet. I will try to improve this)

            Source https://stackoverflow.com/questions/43343503

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install stereogram

            You can download it from GitHub.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/moefh/stereogram.git

          • CLI

            gh repo clone moefh/stereogram

          • sshUrl

            git@github.com:moefh/stereogram.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link