void academy_upload_shutdown(void)
{
	if(academy_upload_started)
	{
		academy_upload_started = FALSE;
		vp_os_mutex_lock(&academy_upload.mutex);
		vp_os_cond_signal(&academy_upload.cond);
		vp_os_mutex_unlock(&academy_upload.mutex);
		vp_os_thread_join(academy_upload_thread);
	}
}
Esempio n. 2
0
void appDeinit()
{
	gAppAlive = 0;

	INFO("shutting down application...\n");

#ifdef BUILD_OGLES
	video_deinit();
#endif
	// all threads should implement a loop polling gAppAlive
	vp_os_thread_join( nav_thread );
	vp_os_thread_join( at_thread );
	vp_os_thread_join( stream_thread );

	nav_thread = 0;
	at_thread = 0;
	stream_thread = 0;

	INFO("application was cleanly exited\n");
}
C_RESULT vp_api_join_thread_tab(thread_table_entry_t* tab,int32_t idx)
{
  if(idx < 0)
    return C_FAIL;

  if( tab[idx].handle != 0 )
  {
    vp_os_thread_join(tab[idx].handle);
  }

  return C_OK;
}