I am trying to detect whether a particular pixel is filled or not in OpenGL in order to implement the flood fill algorithm. So, I searched and found the glreadpixel function but I don't get how I can use this function and whether or not it can solve my problem.
How do I check whether a pixel is filled or not on a canvas in OpenGL?
284 Views Asked by java_doctor_101 At
2
There are 2 best solutions below
Related Questions in OPENGL
- setting OpenGL version in objective-C
- How to run OpenGL version 3.3 (with Intel HD 4000) on Ubuntu 15.04
- Can linear filtering be used for an FBO blit of an MSAA texture to non-MSAA texture?
- How to get shader version from QOpenGLShader?
- "Capture GPU Frame" in XCode -- iOS only?
- Difference between glewGetString(GLEW_VERSION) and glewIsSupported
- Tesselation result flickering - OpenGL/GLSL
- Water rendering in opengl
- Texture mapping consuming physical memory
- Rotating a Cube using Quaternions in PyOpenGL
- Switching from perspective orthographic projection in OpenGL
- FreeType2 and OpenGL : Use unicode
- Should Meshes with and without Skeleton use different Shaders?
- How to get accurate 3D depth from 2D screen mouse click for large scale object in OpenGL?
- Trying to load 2d texture with glTexImage2D, but just getting blank
Related Questions in PIXEL
- Is it possible to access gmail anonymous profile for a logged in user?
- Excel VBA - Click a specific pixel location in an open IE window
- Java replacing the background of an image
- Treating 2d array data as pixels defining a shape - is it possible to create an inside and a surface?
- Draw on screen using mouse in assembly (emu8086)
- Pixel-based scan for a game AI taking a huge amount of time
- Is there any easy way to rotate the values of a matrix/array?
- Browsers truncate border values to integers
- Can't getImageData() in javascript with gif file; can with FillRect. What's wrong?
- Read in Bufferedimage pixel values then manipulate each one and write to file
- How can you get the intensity of a pixel in java?
- assign RGB values in java with nested for function
- Creating icons and images for an iOS application with points vs pixels
- Integrate affiliateTracking Pixel
- Getting the color of a pixel
Related Questions in GLUT
- Texture mapping consuming physical memory
- Check Q button is held down using GLUT?
- Get normal of a gluDisk?
- haskell/gloss example error w/ GLUT dynamic library "Symbol not found: _glutBitmap8By13 error"
- Stack Overflow Error when using glReadPixel
- glutTimerFunc() not limiting framerate
- Visual Studio : when changed from win32 to x64, its showing linking error
- How to put the "camera" inside a cube in OpenGL
- Limiting fps in glut
- How can I replace main() with WinMain()?
- I have entered glutPostRedisplay(); but it does not refresh the window and/or the output?
- How do I get the glew.h & freeglut.h libraries?
- OpenGL: How to make light stationary when moving the camera around?
- Unresolved external typedef while compiling with X11
- 2D array pointer in C++ GLUT modified using keyboard function
Related Questions in GLREADPIXELS
- glReadPixels always returns a black image
- glReadPixels returns more data than expected
- glReadPixels save to BMP - Color Dirstortion
- GLSURFACEVIEW SAVE to PNG - ERROR glReadPixels
- How to save picture (applied glsl effects) captured by camera in Android?
- How to save large texture (efficiently) by OpenGL ES 2.0 in Android
- glReadPixels when using PBuffers is failing in some android devices
- Modify an existing opengl application to render to a PBO (and from there to a file)?
- Performance boost for glReadPixels in Android by OpenGL ES 3.0
- OpenGL ES2.0 glReadPixels() is very slow
- Use glEGLImageTargetTexture2DOES to replace glReadPixels on Android
- Converting RGBA to ARGB (glReadPixels -> AVAssetWriter)
- Converting data from glReadPixels() to OpenCV::Mat
- iOS: render to and read from depthbuffer for offscreen processing
- glReadPixel returns zeros and error 1282 (Android)
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
The proper way is probably not to read back pixels. Instead, you should do all manipulations in a bitmap that you manage on your own. Then you request OpenGL to show this bitmap.