Added getTexId function.  Added some debugging code to be removed in main.cpp