If I erase and sync my iTunes library on my iPhone will I also lose my pictures that are on iCloud?
The photos won't be deleted from iCloud, as re-syncing your device won't delete, nor reset the Photo Stream. 

Photos are deleted from the Photo Stream just by selecting the one you want to get rid of and taping the trash can icon, on iOS, or clicking Delete on the computer. There is, too, a Reset Photo Stream button in you account at iCloud.com.

Just keep in mind that photos are stored in iCloud for 30 days.