/// <summary> /// Setup constructor /// </summary> public BuildRequest( IPlanetTerrainModel model, int width, int height, WorkCompleteDelegate workComplete ) { m_Model = model; m_Width = width; m_Height = height; m_WorkComplete = workComplete; }
/// <summary> /// Adds a work request. When the work is complete, the specified delegate will /// be called on the main UI thread /// </summary> /// <param name="model">Terrain model to use to generate the bitamp</param> /// <param name="width">Bitmap width</param> /// <param name="height">Bitmap height</param> /// <param name="workComplete">Delegate to call when the request has been completed</param> public static void AddRequest( IPlanetTerrainModel model, int width, int height, WorkCompleteDelegate workComplete ) { s_SampleUpdateWorker.RunWorkerAsync( new BuildRequest( model, width, height, workComplete ) ); }