Adaptive silicon oxycarbide coatings with controlled hydrophilic or hydrophobic properties