A pixel is the smallest unit that can be represented or controlled on a display. The word pixel is derived from the phrase "picture element".
Questions tagged [pixel]
4067 questions
10
votes
3 answers
Fastest way to draw 1024x1024 dots on screen
I am developing a program that must calculate a color of each point on a 1024x1024 picture using a special algorithm. The color of a point represents some value. So each point is independent of other points and must be drawn separately. I do not…

pavelkolodin
- 2,859
- 3
- 31
- 74
10
votes
4 answers
android fast pixel access and manipulation
I'm trying to port an emulator that i have written in java to android. Things have been going nicely, I was able to port most of my codes with minor changes however due to how emulation works, I need to render image at pixel level.
As for desktop…

afro100
- 101
- 1
- 1
- 3
10
votes
4 answers
How to convert DLU into pixels?
Microsoft uses dialog length units (DLU) in their guidelines for UI. How can I convert them into pixels?
As I know, DLU depending on system font size. Can you advise some simple method of such conversion in Delphi for Win32?

Andrew
- 3,696
- 3
- 40
- 71
10
votes
1 answer
OpenGL/PBO pixel drawing example needed
I need to draw pixels very fast on a screen.
I found this interesting page
Fast pixel drawing library
author posted:
"Using an OpenGL texture along with a PBO seems to be the best choice. Thanks."
I guess OpenGL/PBO is what i need.
I was reading…

Stan
- 101
- 1
- 1
- 3
10
votes
2 answers
Android color splash
Can someone suggest me a fast method or a library for color splash effect? For example, I select a color and a photo gets desaturated for all colors except that one I have picked.
I have tried using pixel by pixel color check and then replace the…

filipst
- 1,547
- 1
- 30
- 55
10
votes
5 answers
GetDIBits and loop through pixels using X, Y
I'm grabbing a portion of the screen and scanning through the pixels for a certain color range.
I looked at MSDN's Capturing an Image example and know how to use the functions.
I can get the bits into an array, but I'm not sure how to do it in such…

guitar-
- 1,051
- 5
- 15
- 21
10
votes
3 answers
Is there a formula to determine overall color given BGR values? (OpenCV and C++)
I am making a function using C++ and OpenCV that will detect the color of a pixel in an image, determine what color range it is in, and replace it with a generic color. For example, green could range from dark green to light green, the program would…

Wyndrix
- 133
- 2
- 10
10
votes
4 answers
Auto Layout vs Frame Sizes
So I'm slightly embarrassed to ask this because it seems so rudimentary but ever since beginning iOS development (about a year of self/internet teaching), when not using storyboards, I have relied heavily on frame sizes and used auto layout very…

Matt Clevenger
- 297
- 3
- 16
10
votes
1 answer
Is it wise to use fractional / decimal pixels for borders in css?
I have various instances in my design that call for
border-right: 1.5px solid black;
border-bottom: 1.5px solid black;
etc...
I also have design that needs thinner lines: at 1px.
However, it seems the browser may round the decimal, as I'm not…

someoneHere
- 323
- 1
- 3
- 15
10
votes
10 answers
Finding closest non-black pixel in an image fast
I have a 2D image randomly and sparsely scattered with pixels.
given a point on the image, I need to find the distance to the closest pixel that is not in the background color (black).
What is the fastest way to do this?
The only method I could…

shoosh
- 76,898
- 55
- 205
- 325
10
votes
1 answer
Why do rendered pixels differ from real pixels?
In my HTML i have a
(call it the panel) with fixed width that contains some text; that text is set to font-size: 25px; line-height: 25px; in the accompanying CSS. It so happens that the text ends up as 36 lines.
Given that all margins,…

flow
- 3,624
- 36
- 48
10
votes
1 answer
How to draw Pixel Perfectly on iPhone 6 Plus?
Given the iPhone 6 Plus is downscaling from 1242x2208 to 1080x1920, and UIKit is doing that, are there other ways of drawing to the screen that permit absolute (pixel perfect) drawing without downscaling?
I imagine, but am not sure, that OpenGL and…

Confused
- 6,048
- 6
- 34
- 75
10
votes
1 answer
How do I load and edit a bitmap file at the pixel level in Swift for iOS?
I want to manipulate an image at the pixel level in Swift. This question was answered for objective c: How do I access and manipulate JPEG image pixels?, but I would like to see the equivalent source for Swift.

Fred Hamilton
- 697
- 3
- 9
- 22
10
votes
3 answers
Edit raw pixel data of WriteableBitmap?
Is it possible to directly read/write to a WriteableBitmap's pixel data? I'm currently using WriteableBitmapEx's SetPixel() but it's slow and I want to access the pixels directly without any overhead.
I haven't used HTML5's canvas in a while, but…

Oztaco
- 3,399
- 11
- 45
- 84
10
votes
5 answers
How to measure the pixel width of a digit in a given font / size (C#)
I am trying to calculate the pixel width of Excel columns, as described in this post, using the official formula from the OpenXML specification. However, in order to apply this formula, I need to know the Maximum Digit Width of the Normal font,…

Tim Coulter
- 8,705
- 11
- 64
- 95