modularized texture loading