public void Evaluate(int SpreadMax) { if (this.videoin == null || this.FInReset[0]) { if (this.videoin != null) { this.videoin.OnFrameReady -= videoin_OnFrameReady; this.videoin.Stop(); } this.reset = true; this.videoin = new VideoInThread(); this.videoin.OnFrameReady += this.videoin_OnFrameReady; this.videoin.Start(this.FInW[0], this.FInH[0],this.FInFPS[0]); } if (this.FTextureOutput[0] == null) { this.FTextureOutput[0] = new DX11Resource<DX11DynamicTexture2D>(); } try { this.FOutW[0] = this.videoin.GetWidth(); this.FOutH[0] = this.videoin.GetHeight(); } catch { } }
public void Evaluate(int SpreadMax) { if (this.videoin == null || this.FInReset[0]) { if (this.videoin != null) { this.videoin.OnFrameReady -= videoin_OnFrameReady; this.videoin.Stop(); } this.reset = true; this.videoin = new VideoInThread(); this.videoin.OnFrameReady += this.videoin_OnFrameReady; this.videoin.Start(this.FInW[0], this.FInH[0], this.FInFPS[0]); } if (this.FTextureOutput[0] == null) { this.FTextureOutput[0] = new DX11Resource <DX11DynamicTexture2D>(); } try { this.FOutW[0] = this.videoin.GetWidth(); this.FOutH[0] = this.videoin.GetHeight(); } catch { } }