Usually for bmp, jpg, png, tiff etc etc file formats require the use of their relevant libraries to ease our task. Say I want to "decipher" bmp I use a BMP library. I want to "decipher" jpg I use a JPG library etc etc.
Since you are using TIFF, then go Internet to search for the relevant library. Of cuz you can do it the hard way by reading bytes and bytes and try to interpret them yourselves based on the published TIFF format but I feel this is quite time consuming.
If you take a look at some companies, they also use libraries. It is impossible for them to do everything from scratch. Time to market is very important.
Please note for some image file format, it is proprietary so they are not published. But in general nowadays, bmp, jpg, png are the more common ones with png gaining popularity day by day.
Alternatively, imageMagick is well respected and not too tricky to use (good support forums, too), and should be able to handle your conversion needs well.