It is currently March 28th, 2024, 11:12 pm

second/third screen preview box

Get help with creating, editing & fixing problems with skins
Akallabethuial
Posts: 2
Joined: November 12th, 2015, 8:33 am

second/third screen preview box

Post by Akallabethuial »

I have a 3 monitor setup with two monitors on my desk in my room and the third in a different room all set as extensions due to resolution differences. I'm looking for a way to display a small preview of the third screen on my main screen in the corner or something similar. Is rainmeter capable of this? all i could find close to this was the virtual desktop plugin.
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: second/third screen preview box

Post by dgrace »

That sounded kinda interesting, so I wrote a quick plugin. Give this a shot. Set ScreenIndex to pick the screen. Note: it assumes that all the screens are the same size, at the moment.

dave
You do not have the required permissions to view the files attached to this post.
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: second/third screen preview box

Post by jsmorley »

Seems to work fine for me. Needs an UpdateDivider on the [measureVC] measure or it uses a bit more CPU than I like, but if you set UpdateDivider=10 or even 5, it seems pretty light.
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: second/third screen preview box

Post by dgrace »

Actually, this is better - you can use ScreenX, ScreenY, ScreenW and ScreenH to pick the rectangle to capture.

Enjoy,

dave
You do not have the required permissions to view the files attached to this post.
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: second/third screen preview box

Post by dgrace »

jsmorley wrote:Seems to work fine for me. Needs an UpdateDivider on the [measureVC] measure or it uses a bit more CPU than I like, but if you set UpdateDivider=10 or even 5, it seems pretty light.
Passing the bitmap data through memory rather than writing out to a file would help a bit there, but it would require an update to the plugin interface. ;>

dave
User avatar
jsmorley
Developer
Posts: 22628
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: second/third screen preview box

Post by jsmorley »

Seems to work pretty well. The ScreenX / ScreenY stuff with no ScreenIndex may be a little harder for some folks to wrap their head around, but it does offer some more flexibility.

Code: Select all

[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1
OnRefreshAction=[!ZPos "2"]

[Metadata]
Name=SecondMonitor
Author=JSMorley
Version=Nov 12, 2015
License=Creative Commons Attribution-Non-Commercial-Share Alike 3.0
Information=Example skin for dgrace's ScreenShot plugin.

[MeasureSecondScreen]
Measure=Plugin
Plugin=ScreenShot
ScreenX=(#SCREENAREAWIDTH@1# + 1)
ScreenY=0
ScreenW=#SCREENAREAWIDTH@2#
ScreenH=#SCREENAREAHEIGHT@2#
ImageName=#CURRENTPATH#frame.bmp
Paused=1

[MeterSecondScreen]
Meter=IMAGE
ImageName=#CURRENTPATH#frame.bmp
DynamicVariables=1
W=400
ImageAlpha=0

[MeterIcon]
Meter=Image
ImageName=#@#Images\Monitor.png
W=24
H=24
X=(200 - 24)
Y=5R
MouseOverAction=[!UnpauseMeasure MeasureSecondScreen][!SetOption MeterSecondScreen ImageAlpha "255"][!UpdateMeter *]
MouseLeaveAction=[!PauseMeasure MeasureSecondScreen][!SetOption MeterSecondScreen ImageAlpha "0"][!UpdateMeter *]
Monitor.png
Click to Animate:
test.gif
You do not have the required permissions to view the files attached to this post.
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: second/third screen preview box

Post by balala »

That's a very interesting plugin dgrace, congratulations. It's working well for me too (it's true I have just one single monitor). I changed just one single thing in your code: as jsmorley suggested, I used:

Code: Select all

[measureSS]
Measure=Plugin
Plugin=ScreenShot
...
ScreenW=#SCREENAREAWIDTH#
ScreenH=#SCREENAREAHEIGHT#
...
for my single monitor, instead of the initial

Code: Select all

[measureSS]
Measure=Plugin
Plugin=ScreenShot
...
ScreenW=1920
ScreenH=1080
...
Keep working on it, because it can be very useful, I think.
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: second/third screen preview box

Post by dgrace »

If you leave ScreenW and ScreenH blank, it should default to your primary monitor size. I just didn't want to go to the hassle of interrogating all the monitors to get each size, and by letting the user specify the range, they can grab a sub-rectangle of the total area. (i.e. you could use it to do a "magnifying glass" kind of thing, tracking the mouse coords)

Cheers,

dave
User avatar
dgrace
Developer
Posts: 265
Joined: June 28th, 2014, 8:32 am
Location: Tokyo, Japan

Re: second/third screen preview box

Post by dgrace »

Check it out: recursion! ;)

dave
You do not have the required permissions to view the files attached to this post.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5384
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: second/third screen preview box

Post by eclectic-tech »

:Watching:
"More!" ... "More!"

Like what you have...
Keep tinkering Dave!