May 2007 - Posts

Installing Visual Studio SP 1 on Server 2003

I was getting some strange errors when installing SP1 for Visual Studio on Server 2003. Microsoft Update said “Error Code: 0x64C Try to install the update again, or request help from one of the following resources.”  After some research it appears that the problem is with Server 2003 installing large windows installer packages. Installing the fix in the following KB article fixed my problem.

http://support.microsoft.com/?kbid=925336

Posted by sweisfeld | with no comments
Filed under: ,

send a card to a kid

Joe Healy (http://www.devfish.net) blogged this and I hope that my readers will participate also . . .

All around good guy John Papa blogged about a boy named Shane, who is dying of cancer. Through make-a-wish foundation his last wish was to receive 1 million birthday cards for what could be his last birthday. Okay FLORIDA.NET community, I don't ask much, but I'd ask ya'll all to reach out here. Anyone who reads this please cross blog it, link back to Papa's post, and email Joe (jhealy@microsoft.com) the link as well. More info here :: http://codebetter.com/blogs/john.papa/archive/2007/05/14/last-wish-of-a-child.aspx.

 

ONETUG collected 40 Birthday Cards for Shane, a child with cancer from New York. All Shane requested from "Make a Wish" was to get a million birthday cards for his 8th birthday. We hope that Shane gets better and that our small contribution put a smile on his face. 

Download a copy of the card ONETUG set Shane here: http://www.onetug.org/DNN/Portals/0/member_files/shanecard.pdf

Posted by sweisfeld | with no comments

Video Screen Capture

There are a lot of video screen capture software applications out there. Perhaps one of the best know is Camtasia (http://www.techsmith.com/camtasia.asp), but the $300 price tag might be a bit too much for you if you only use video screen capture once in a while and don’t need a bunch of features. If this is you take a look at Windows Media Encoder (http://www.microsoft.com/windows/windowsmedia/howto/articles/screencap.aspx) from Microsoft. I have used it and it works well epically since it is FREE! Give it a try let me know what you think, or if you got any other recommendations feel free to comment below.

Posted by sweisfeld | with no comments
Filed under:

Why Doesn't Microsoft Have A Cult Religion?

The following articles were brought to my attention and did a great job at making me think. . .

Why Doesn't Microsoft Have A Cult Religion?
http://www.informationweek.com/blog/main/archives/2007/05/why_doesnt_micr.html

A good question: Where ARE the Microsoft fanboys?
http://arstechnica.com/journals/microsoft.ars/2007/05/14/good-question-where-are-the-ms-fanboys

After reading the above articles I thought to myself what planet are these guys from and then I spent a little more time thinking about it and I might not totally disagree, but I have a real reason for it, hear me out. So I thought to my self, self what exactly is a cult? David Koresh (http://en.wikipedia.org/wiki/David_Koresh)? Wikipedia defines cult (http://en.wikipedia.org/wiki/Cult) as “a term designating a cohesive group of people devoted to beliefs or practices that the surrounding culture or society considers to be outside the mainstream.” By its very definition most Microsoft products are not “cult” products because they are mainstream, and IMHO that is a good thing. I like the fact that everyone is using it, and I have the support of literally millions of people world wide, and I don’t need to hunt down a MAC “Genius” at an apple store.  

On the other hand I strongly disagree with the comment that Windows and Microsoft products in general have lost there passion. I think the felling that when Microsoft releases a new product people don’t blindly start cheering is due to the fact that most Microsoft products are tools that we use to get out jobs done. As people that use the tools we are always looking for better and better tools. When I go to an event where they are launching something new I do here the ooh’s and ah’s, but the overwhelming feeling I get from the crowd “that is a great tool, that will make it easier for me to do my job”. I think that is the big difference between a “cult” project and a mainstream tool. I don’t use Microsoft products because they are wiz-bang, because they look cool, because they have funny commercials, I use them because they help me get my job done. When was the last time you heard a roofer saying “Yea, man! My new hammer rocks!”

            From what I see as the President of the Orlando .NET User Group there is plenty of passion in the community. The developers I meet are passionate about the upcoming Orcas, Silverlight, and SQL Server Katmai releases. They are embracing these tools as exactly that tools (http://mw1.merriam-webster.com/dictionary/tool) “something used in performing an operation or necessary in the practice of a vocation or profession”. While tools are usually not sexy and usually not cool, tools allow us to get things done. If I wanted something sexy and cool I would buy a sports car. It might go really fast, but don’t even think about taking it to the grocery store.


What do you think? Post comments below

Posted by sweisfeld | with no comments
Filed under:

Bounding Box

In my earlier post I put together an image processing class (http://drowningintechnicaldebt.com/blogs/shawnweisfeld/archive/2006/11/06/Bitmap-Processing-in-C_2300_.aspx). I needed a method that built a bounding box around a given shape. Here is the code:

public static void BoundingBox(Bitmap b, ref Point upperLeft, ref Point lowerRight)
{
    ImagerBitmap i = new ImagerBitmap(b.Clone() as Bitmap);
    Queue<Point> q = new Queue<Point>();
    q.Enqueue(upperLeft);

    int jump = 10;

    while (q.Count > 0)
    {
     Point p = q.Dequeue();
     AddToStack(q, b, i, new Point(p.X + jump, p.Y), ref upperLeft, ref lowerRight);
     AddToStack(q, b, i, new Point(p.X - jump, p.Y), ref upperLeft, ref lowerRight);
     AddToStack(q, b, i, new Point(p.X, p.Y + jump), ref upperLeft, ref lowerRight);
     AddToStack(q, b, i, new Point(p.X, p.Y - jump), ref upperLeft, ref lowerRight);
    }
    i.UnlockBitmap();
}

private static void AddToStack(Queue<Point> q, Bitmap b, ImagerBitmap i, Point p, ref Point upperLeft, ref Point lowerRight)
{
    if (p.X < b.Width
     && p.Y < b.Height
     && i.GetGreyPixel(p.X, p.Y) != 0)
    {
     if (upperLeft.X > p.X)
     {
         upperLeft.X = p.X;
         q.Enqueue(p);
     }
     if (upperLeft.Y > p.Y)
     {
         upperLeft.Y = p.Y;
         q.Enqueue(p);
     }
     if (lowerRight.X < p.X)
     {
         lowerRight.X = p.X;
         q.Enqueue(p);
     }
     if (lowerRight.Y < p.Y)
     {
         lowerRight.Y = p.Y;
         q.Enqueue(p);
     }
    }
}

Posted by sweisfeld | with no comments
Filed under: ,

Center of Mass

In my earlier post I put together an image processing class (http://drowningintechnicaldebt.com/blogs/shawnweisfeld/archive/2006/11/06/Bitmap-Processing-in-C_2300_.aspx). I needed a method that found the center of a given mass of pixels. Here is the code:

public static Point CenterOfMass(Bitmap b)
{
    ImagerBitmap i = new ImagerBitmap(b.Clone() as Bitmap);
    int cogX = 0;
    int cogY = 0;
    int cogTotal = 0;

    for (int column = 0; column < i.Bitmap.Width; column++)
    {
     for (int row = 0; row < i.Bitmap.Height; row++)
     {
         int px = i.GetGreyPixel(column, row);
         cogX += (px * column);
         cogY += (px * row);
         cogTotal += px;
     }
    }
    i.UnlockBitmap();
    return new Point(cogX / cogTotal, cogY / cogTotal);
}

Posted by sweisfeld | with no comments
Filed under: ,

Remove Background

In my earlier post I put together an image processing class (http://drowningintechnicaldebt.com/blogs/shawnweisfeld/archive/2006/11/06/Bitmap-Processing-in-C_2300_.aspx). I needed a method that did some segmentation based on a given color. It needed to take in the color and a threshold and it would black out any pixels that are not within the color threshold. Here is the code:

public static Bitmap RemoveBackground(Bitmap b, Color c, int threshold)
{
    ImagerBitmap i = new ImagerBitmap(b.Clone() as Bitmap);
    int maxGreen = c.G + threshold;
    int minGreen = c.G - threshold;
    int maxRed = c.R + threshold;
    int minRed = c.R - threshold;
    int maxBlue = c.B + threshold;
    int minBlue = c.B - threshold;

    for (int column = 0; column < i.Bitmap.Width; column++)
    {
     for (int row = 0; row < i.Bitmap.Height; row++)
     {
         Color px = i.GetPixel(column, row);

         if (px.G > minGreen && px.G < maxGreen
          && px.R > minRed && px.R < maxRed
          && px.B > minBlue && px.B < maxBlue)
         {
          //i.SetPixel(column, row, Color.FromArgb(255, 255, 255));
         }
         else
         {
          i.SetPixel(column, row, Color.Black);
         }
     }
    }
    i.UnlockBitmap();
    return i.Bitmap.Clone() as Bitmap;
}

Posted by sweisfeld | with no comments
Filed under: ,