#include <s3d.h>
int s3d_pep_material_texture( int object, unsigned long tex );
int s3d_pep_material_texture
Assign the latest material a texture referenced by the index tex. Of course, you will have pushed this texture with s3d_push_texture