# Perspective Workstation architecture question

**URL:** <https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480>\
**Category:** General Discussion\
**Tags:** perspective, ignition81\
**Created:** [May 11, 2022, 9:15pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480 "2022-05-11T21:15:58Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 9:15pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/1 "2022-05-11T21:15:59Z")

</div>

This is probably a stupid question, but:

Is [Perspective Workstation](https://docs.inductiveautomation.com/display/DOC81/Perspective+Workstation) basically just a wrapper around launching perspective projects? Or does/can it act as a client itself and able perform tasks independently from the GW? EG perform animations of objects that don’t make references to any resources in the GW

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 11, 2022, 9:24pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/2 "2022-05-11T21:24:47Z")

</div>

It’s just an embedded Chromium browser running the same Perspective project.

The real value lies in features that are currently unimplemented, like native file system access, native camera access, and other things that you can’t do with with just a browser.

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 9:49pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/3 "2022-05-11T21:49:37Z")

</div>

OK, so Perspective Workstation is just a skinned browser. And like all Perspective systems everything is basically running on the GW.

(maybe this should be a new question, but here it goes anyway)

Now I've seen these:  
[Vision & Perspective: Which Module is Best for Your Next Project?](https://www.inductiveautomation.com/blog/vision-perspective-which-module-is-best-for-your-next-project)  
[Vision and Perspective — Which Visualization System Is Best for Me?](https://docs.inductiveautomation.com/pages/viewpage.action?pageId=34473703)

Where about all it says about Vision is

> Vision is and has been for many years a top-class desktop application. It is the best choice for traditional industrial [plant-floor and desktop screens](https://inductiveautomation.com/resources/webinar/how-to-quickly-create-effective-plantfloor-screens), standalone HMIs, and the like. If you need a full, production-ready application right now, then it is best to choose Vision.

So the big question I really have is:

At a mile high level, is the Vision architecture an equivalent to Perspective, (IE the client only acts as an interface to the system, and each type is just using different transport and visualization technologies?) Or is the Vision client fundamentally smarter than Perspective, and does allow local processing?

The reason behind this is that I have whipped up my beautifully skeuomorphic demonstration HMI in Perspective and I am having some issues with missing some mouse events in my fancy momentary pushbuttons [1] and I'm trying to decide if I should have built this in Vision instead [2]

* * *

[1] This system is never going anywhere near a real machine, it was only ever intended as a demonstrator of what could be done visually and how far I could push my design skills.  
[2] Never-less it's been a great ride with Perspective and I have learnt an huge amount of things.

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 11, 2022, 9:52pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/4 "2022-05-11T21:52:40Z")

</div>

> [@peter](#):
>
> The reason behind this is that I have whipped up my beautifully skeuomorphic demonstration HMI in Perspective and I am having some issues with missing some mouse events in my fancy momentary pushbuttons [1] and I’m trying to decide if I should have built this in Vision instead [2]

I'm not sure I could recommend one or the other, maybe others will have an opinion. I don't know why you'd be missing mouse events in Perspective, regardless of what you're doing... but 🤷‍♂️

> [@peter](#):
>
> Or is the Vision client fundamentally smarter than Perspective, and does allow local processing?

It does allow local processing. Client scope scripts run in the client, which is why Vision Clients can access things like the file system and serial ports or get the hostname without relying on what the IP address that gateway sees.

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [May 11, 2022, 9:56pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/5 "2022-05-11T21:56:20Z")

</div>

> [@peter](#):
>
> missing some mouse events i

Have you tried adding button components on top of your graphics and using those for your mouse actions? You can make the button styling invisible

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 11, 2022, 9:57pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/6 "2022-05-11T21:57:43Z")

</div>

> [@Kevin.Herron](#):
>
> It does allow local processing. Client scope scripts run in the client, which is why Vision Clients can access things like the file system and serial ports or get the hostname without relying on what the IP address that gateway sees.

One caveat: While the _execution_ of code happens locally, it _will not_ happen without a connection back to the gateway - not because it _couldn't_, but because the decision was made a _long_ time ago to not allow this in Vision.

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 10:11pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/7 "2022-05-11T22:11:01Z")

</div>

> [@nminchin](#):
>
> > [@peter](#):
> >
> > missing some mouse events i
> 
> Have you tried adding button components on top of your graphics and using those for your mouse actions? You can make the button styling invisible

That's an interesting concept that I haven't tried. But fundamentally wouldn't the button component still rely on the same mouse events that I am relying on explicitly?

Going off into the weeds the flow of my button architecture is:

1. On Mouse down, set a local bool property to true (which is eventually bound to a tag in the PLC)
2. The visual state of the button press is indicated by changing a radial fill that is bound to the state of the local bool (and for flexibility the radial fill itself is calculated from a script attached to the button)
3. On Mouse Up (and also Mouse Leave), reset the bool to false
4. Redo the radial fill based on the bool value etc

What I have encountered is that sometimes when I click a button, it presses OK, but doesn't un-press at all, even when I move the mouse off the button. It's only when I move back on and then off does the un-press trigger.

I am not sure why this occurs, but if everything (including local properties) are stored on the GW then this could simply be an issue with data transport from the Perspective session back to the GW.

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 10:12pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/8 "2022-05-11T22:12:18Z")

</div>

> [@paul-griffith](#):
>
> One caveat: While the _execution_ of code happens locally, it _will not_ happen without a connection back to the gateway.

Not a problem, I'm not trying to make an application that is independent of the GW. But thanks for the heads up

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 10:15pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/9 "2022-05-11T22:15:23Z")

</div>

> [@Kevin.Herron](#):
>
> Client scope scripts run in the client

Does that mean a script attached to a component will run in the Vision client itself (EG one that calculates a new fill color based on a local property attached to that component)? My understanding of Perspective is that _all_ scripts run on the GW

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 11, 2022, 10:23pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/10 "2022-05-11T22:23:07Z")

</div>

> [@peter](#):
>
> Does that mean a script attached to a component will run in the Vision client itself (EG one that calculates a new fill color based on a local property attached to that component)?

Yes

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [May 11, 2022, 10:30pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/11 "2022-05-11T22:30:04Z")

</div>

Scripts run in the GW for Perspective, but expressions don’t, right? I don’t think i’ve ever bothered to clarify that before…

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 11, 2022, 10:35pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/12 "2022-05-11T22:35:20Z")

</div>

Nope, gateway as well.

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [May 11, 2022, 10:37pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/13 "2022-05-11T22:37:08Z")

</div>

Well then… lucky it’s only my first day using Ignition! 😬

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 10:41pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/14 "2022-05-11T22:41:54Z")

</div>

> [@Kevin.Herron](#):
>
> Nope, gateway as well.

Is there any public documentation that shows this level of detail, for both Vision and/or Perspective?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 11, 2022, 10:46pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/15 "2022-05-11T22:46:55Z")

</div>

> [@nminchin](#):
>
> Scripts run in the GW for Perspective, but expressions don’t, right? I don’t think i’ve ever bothered to clarify that before…

The only user-provided stuff that can run in the frontend in Perspective are (most) actions.

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 11, 2022, 10:47pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/16 "2022-05-11T22:47:12Z")

</div>

Hmm. I’m not sure if there’s anything that breaks it down specifically regarding where things run, but it’s actually pretty simple:

In Perspective, EVERYTHING RUNS ON THE GATEWAY. That’s it. What you see in the browser is basically just the view of the current session state being rendered by the browser. The session is synced between browser and gateway. All the logic runs on the gateway and the changes to the session are synced up to the browser, and your input events from the browser are relayed down to the session to react to.

edit: I don’t even know what actions Paul is talking about, but that’s probably my lack of Perspective knowledge. Maybe that in code running on the gateway you can trigger certain things to happen in the browser? 🤷

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 10:49pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/17 "2022-05-11T22:49:13Z")

</div>

So what’s your elevator speech for Vision then?

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [May 11, 2022, 10:49pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/18 "2022-05-11T22:49:52Z")

</div>

Use it if you still need local file system / serial / other access? 🤷

Certainly don’t use it if you have any kind of high DPI screen 🙃

There’s other things too… Perspective hasn’t reached 1:1 Vision feature parity, but it’s steadily on its way.

We’ve wandered beyond where you should be listening to my advice. I don’t have to use either of these to deploy real world applications. Listen to the other guys here who actually do.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 11, 2022, 10:57pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/19 "2022-05-11T22:57:18Z")

</div>

Specifically, by actions, I’m referring to these:  
[https://docs.inductiveautomation.com/display/DOC81/Component+Events+and+Actions](https://docs.inductiveautomation.com/display/DOC81/Component+Events+and+Actions)

~Most of these are able to execute locally before any roundtrip to the gateway.

---

<div class="post-metadata">

**Author:** ![peter](https://avatars.discourse-cdn.com/v4/letter/p/278dde/32.png) [@peter](https://forum.inductiveautomation.com/u/peter)\
**Post date:** [May 11, 2022, 11:00pm UTC](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480/20 "2022-05-11T23:00:18Z")

</div>

Ok … but if an Event has a script attached to it, doesn’t that imply that there is a trip to the GW in its future?

(and isn’t the state of local properties maintained in GW?)

[Next page](https://forum.inductiveautomation.com/t/perspective-workstation-architecture-question/59480.md?page=2)
