Swedlin,
It sounds like you have uneven lighting, which causes bright spots in the image. The best solution is usually to improve the lighting so the background is evenly lit. This makes the threshold operation easy.
Assuming you can't improve the lighting, there is a trick that might work. By using an averaging filter that is 2 or 3 times larger than your objects, you can obtain a second image that represents the background brightness. If you subtract one image from the other, you will eliminate the variations in brightness and it should be easy to threshold your object. This is a very time consuming process for larger objects, so it isn't the best solution, but it should work if your objects aren't too large.
Bruce
Bruce Ammons
Ammons Engineering