revised

change base code to shader based openGL