Optimization of Texture Feature Extraction Algorithm