Skip to content

Commit

Permalink
Updated effect according to API changes (#20)
Browse files Browse the repository at this point in the history
* update Pinta submodule
  • Loading branch information
Lehonti authored Oct 4, 2024
1 parent a9ac90a commit 397f245
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions NightVisionAddin/NightVisionEffect.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
using System;
using System.Threading.Tasks;
using Cairo;
using Pinta.Core;
using Pinta.Gui.Widgets;
Expand All @@ -48,9 +49,9 @@ public NightVisionEffect ()

public override bool IsTileable => true;

public override void LaunchConfiguration ()
public override Task<bool> LaunchConfiguration ()
{
LaunchSimpleEffectDialog (AddinManager.CurrentLocalizer);
return LaunchSimpleEffectDialog (AddinManager.CurrentLocalizer);
}

public NightVisionData Data => (NightVisionData) EffectData!; // NRT - Set in constructor.
Expand All @@ -61,7 +62,7 @@ public override void Render (ImageSurface src, ImageSurface dst, ReadOnlySpan<Re
foreach (var rect in rois)
Render (src, dst, rect); //Uses superclass chain of rendering to pass render down to single-pixel renderer.
} else {
var noiseEffect = new AddNoiseEffect ();
var noiseEffect = new AddNoiseEffect (PintaCore.Services);

noiseEffect.Render (src, dst, rois);

Expand Down
2 changes: 1 addition & 1 deletion Pinta
Submodule Pinta updated 405 files

0 comments on commit 397f245

Please sign in to comment.