?
Solved

Check if Image is Blank

Posted on 2007-03-18
1
Medium Priority
?
293 Views
Last Modified: 2007-03-18
Is there a way I can load an image and check if the image is blank(all white) with vb.net?
0
Comment
Question by:mxpoint
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 4

Accepted Solution

by:
cx323 earned 2000 total points
ID: 18744523
Dim bmp As Bitmap = CType(Me.PictureBox1.Image, Bitmap) 'change to your picturebox
Dim y As Integer
Dim x As Integer
Dim bmpmaxX As Integer = bmp.Size.Width
Dim bmpmaxY As Integer = bmp.Size.Height
For x  = 0 To bmpmaxX - 1
      For y  = 0 To bmpmaxY - 1
                If Not bmp.GetPixel(x, y) = Color.White Then
                    'there's a pixel that is not white so do something else
                End If
        Next
Next
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will show, step by step, how to integrate R code into a R Sweave document
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
Suggested Courses

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question