void Awake() { mInstance = this; light.SetActive(false); mPhotoCam.aspect = 1; mPhotoCam.clearFlags = CameraClearFlags.Color; mPhotoCam.targetTexture = new RenderTexture(128, 128, 16, RenderTextureFormat.ARGB32); mPhotoCam.gameObject.SetActive(false); }
public static Texture2D GetTex() { Camera camera = Camera.main; camera.targetTexture = new RenderTexture(Screen.width, Screen.height, 32); Texture2D image = PhotoStudio.RTImage(camera); camera.targetTexture = null; return(image); }
internal PhotoStudioTool(IWrapperRegistry reg, IProviderRegistry prov) { this.reg = reg; this.prov = prov; if (registry == null) { registry = Helper.WindowsRegistry; } ps = null; }
public Interfaces.Plugin.IToolResult ShowDialog(ref SimPe.Interfaces.Files.IPackedFileDescriptor pfd, ref SimPe.Interfaces.Files.IPackageFile package) { if (!IsReallyEnabled(pfd, package)) { return(new SimPe.Plugin.ToolResult(false, false)); } if (ps == null) { ps = new PhotoStudio(); } return(ps.Execute(ref pfd, ref package, prov)); }
public IActionResult Put_PhotoStudios(int key, [FromBody] PhotoStudio update) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } if (key != update.Id) { return(BadRequest()); } var PhotoStudio = _db.PhotoStudios.AsTracking() .Include(x => x.Workers).SingleOrDefault(x => x.Id == key); //_db.PhotoStudios.AsTracking() //.Include(x => x.Registry).SingleOrDefault(x => x.Id == key); _db.PhotoStudios.Persist().InsertOrUpdate(update); try { _db.SaveChanges(); } catch (DbUpdateConcurrencyException) { if (!_PhotoStudiosExists(key)) { return(NotFound()); } else { throw; } } return(Updated(PhotoStudio)); }
public static PhotoStudioDto ToDto(this PhotoStudio photoStudio) { return(new PhotoStudioDto { }); }
public IActionResult Post([FromBody] PhotoStudio PhotoStudio) { _db.PhotoStudios.Add(PhotoStudio); _db.SaveChanges(); return(Created(PhotoStudio)); }
public PhotoStudioBuilder() { _photoStudio = WithDefaults(); }