void CVK::ShaderPhong::update( CVK::Node* node)
{

	if( node->hasMaterial())
	{
		CVK::Material* mat = node->getMaterial();
		CVK::Texture *color_texture;

		glUniform1f( m_kdID, mat->getKd());
		glUniform1f( m_ksID, mat->getKs());
		glUniform1f( m_ktID, mat->getKt());
		glUniform3fv( m_diffuseID, 1, glm::value_ptr( *mat->getdiffColor()));
		glUniform3fv( m_specularID, 1, glm::value_ptr( *mat->getspecColor()));
		glUniform1f( m_shininessID, mat->getShininess());

		bool colorTexture = mat->hasTexture(COLOR_TEXTURE);
		glUniform1i( m_useColorTexture, colorTexture);

		if (colorTexture)
		{	
			//TODO: COLOR_TEXTURE_UNIT
			glUniform1i( m_colorTextureID, 0);

			glActiveTexture(COLOR_TEXTURE_UNIT);
			color_texture = mat->getTexture(COLOR_TEXTURE);
			color_texture->bind();
		}
	}
}