Example #1
0
File: tex.cpp Project: ZeXx86/gen
bool tex_init ()
{
	tex_cnt = 0;
	tex_list = 0;
	
#ifndef ANDROID
	/*tex_create (PATH_DATA "skybox/negz.jpg");
	tex_create (PATH_DATA "skybox/posx.jpg");
	tex_create (PATH_DATA "skybox/posz.jpg");
	tex_create (PATH_DATA "skybox/negx.jpg");
	tex_create (PATH_DATA "skybox/posy.jpg");
	tex_create (PATH_DATA "skybox/negy.jpg");*/
	tex_create_skybox ();
	
	tex_create_alpha (PATH_DATA "water.jpg", PATH_DATA "alpha.jpg");
	
	tex_create (PATH_DATA "grass.jpg");
	tex_create (PATH_DATA "rock.jpg");
	tex_create (PATH_DATA "snow.jpg");
	tex_create (PATH_DATA "water.jpg");
#endif
	
	//tex_create ("./data/snow.jpg");
	//tex_create ("./data/oct20clava.jpg");
	


	return true;
}
Example #2
0
static struct pipe_resource *
ilo_resource_create(struct pipe_screen *screen,
                    const struct pipe_resource *templ)
{
   if (templ->target == PIPE_BUFFER)
      return buf_create(screen, templ);
   else
      return tex_create(screen, templ, NULL);
}
Example #3
0
static struct pipe_resource *
ilo_resource_from_handle(struct pipe_screen *screen,
                         const struct pipe_resource *templ,
                         struct winsys_handle *handle)
{
   if (templ->target == PIPE_BUFFER)
      return NULL;
   else
      return tex_create(screen, templ, handle);
}