2) You're using a resource pack that don't have connectected textures in it for use with Optifine
You dont say what minecraft version you're using or if you're using a resource pack but maybe IF you are using a resource pack then you're not using one made for the version of Minecraft you're running
the title says it, the glass is completely normal while everything in optifine is ok
I can think of a couple of things...
1) Optifine doesn't have 'Connected textures' option switched on
Options >Video Settings > Quality > Connected Textures
OR
2) You're using a resource pack that don't have connectected textures in it for use with Optifine
You dont say what minecraft version you're using or if you're using a resource pack but maybe IF you are using a resource pack then you're not using one made for the version of Minecraft you're running