Jump to content
How to Install Plugins ×

TR's Film Stock Plugin V1.2.0 (Dec 18 2013)


Recommended Posts

TechnoRobbo's Film Stock Plugin v 1.2.0


A photographer often chooses his film speed to, among other things, control the contrast of the image.


High ISO yield high contrast images and low ISO yield low contrast.


 


TR's Film Stock re-interprets the image's contrast without loosing the images dynamic range.


Low contrast doesn't fog the image shadows, and high contrast doesn't wash out highlights.


 


V1.2.0 Code Updated for Speed


V1.1 Updated for Paint.net 4.0


V1.0.1 same plugin different menu


 


Menu: effects->Photo


 


FilmStockMenu.PNG?raw=1 


 


Examples


FilmStock.png?raw=1


Example2


FilmStock2.png?raw=1


 


sidebyside


sidebyside.png?raw=1


 


The VS Source Code


 


 


 


 


The Plug-In


TRsFilmStock.zip


Edited by TechnoRobbo
  • Upvote 2

Go out there and be amazing. Have Fun, TR
TRsSig.png?raw=1
Some Pretty Pictures Some Cool Plugins

Link to comment
Share on other sites

I thought you were on holiday!

Haven't played with this one yet - bit confused by the code - (I often am).
Code looks like there should be a checkbox and an integer slider, screen shot just has int slider?

Many many thanks for all the new plugins (and example code) - go and enjoy your holiday (vacation)!

all the best :beer:
 

 

Red ochre Plugin pack.............. Diabolical Drawings ................Real Paintings

 

PdnForumSig2.jpg

Link to comment
Share on other sites

Red,

 

Yes I finished this at night in the hotel room, I used my daughters laptop , thats why the menu's purple

Code looks like there should be a checkbox and an integer slider, screen shot just has int slider?

 

the invisible checkbox is used as a global variable. it's a semaphore used to accelerate the render.

The biggest issue that slows down the code is the line by line way PDN feeds the image giving the user a realtime preview and thumbnail.

 

One of several work arounds I use is the semaphore. I couple it with a try catch(needed if user changes settings often)  and a keep alive code for the ui dialog so it displays status.

 

Note I use it with the selection and not the rect parameter. I process the whole image once and use the semaphore to ignore the subsequent calls.

 

I use the pdnregion if I want to process only the selected pixels.

 

If I were to remove the wrapper the code would take forever since it's calculatuing the brightest and darkest pixels. and it would scan for them on every scanline, yikes

 

 

I use this wrapper for slow code:

 

#region UICode 
bool Amount1 = true; // [0,1] 
#endregion 

void Render(Surface dst, Surface src, Rectangle rect)
{
     if (Amount1){
          // next two lines are necessary if you are using system graphics. 
          Rectangle sel = EnvironmentParameters.GetSelection(src.Bounds).GetBoundsInt();
          dst.CopySurface(src, sel.Location,sel);
         //========================= 
          Amount1=false;
          try {

               //your code goes here
     
          }catch(Exception e){}

     }else{
      //======= next code is a keep alive for dialog box 
     //so users know its working. 
            ColorBgra CP=dst[0,0];
            dst[0,0]=CP;
     }
}
 
Edited by TechnoRobbo
  • Upvote 2

Go out there and be amazing. Have Fun, TR
TRsSig.png?raw=1
Some Pretty Pictures Some Cool Plugins

Link to comment
Share on other sites

Hi TR,

Thanks for the explanation and wrapper code example. All just a little bit clearer now! - it can be slow getting new ideas into an old head like mine. :D

Enjoy the rest of your time off.
Useful effect Btw. Thanks.

 

Red ochre Plugin pack.............. Diabolical Drawings ................Real Paintings

 

PdnForumSig2.jpg

Link to comment
Share on other sites

wouldn't it be more @ home in Effects >>> Photo ?)

Sure, if you wanna be all "logical" about it. I suppose I could skip the hotel's free Twerking lessons and update the menu.

 

Thanks for the tip Welsh, I uploaded the change. I kept version the same since it's functionally the same program.

Edited by TechnoRobbo

Go out there and be amazing. Have Fun, TR
TRsSig.png?raw=1
Some Pretty Pictures Some Cool Plugins

Link to comment
Share on other sites

  • 2 months later...
  • 1 month later...

I have been flipping between both images that Seerose posted and I can not see a difference. Even after seeing TR's reply I studied the green until my eyes hurt and still see no difference. I can definitely see the differences in TR's pics though. 

 

                                                              http://forums.getpaint.net/index.php?/topic/21233-skullbonz-art-gallery

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...