-
Notifications
You must be signed in to change notification settings - Fork 180
Conversation
eliasnaur
commented
Jul 26, 2022
It seems to me you only need the effective position to implement LinkedViewOp in the client. If so, I wonder whether a lightweight transform feedback machanism would suffice:
package op
// TransformFeedbackOp can retrieve the transformation effective
// at the point of recording into the frame.
type TransformFeedbackOp struct {
// Transform is filled in with the transformation during processing
// of the frame the op is recorded into. Transform must not be nil.
Transform *f32.Affine2D
}
Then, app.Window.Frame will, through the router, fill in Transforms during frame processing where transforms are realized. And you can use the usual app.ViewEvent to update your embedded view.
WDYT?
hanswered
commented
Jul 26, 2022
WDYT?
I didn't observe any bottle-neck calling MoveWindow every frame. In case of lightweight code...
As long as link.Move(...) is called whenever it's expected boundary changes, things should be fine 🔥
eliasnaur
commented
Aug 2, 2022
WDYT?
I didn't observe any bottle-neck calling MoveWindow every frame. In case of lightweight code... As long as
link.Move(...)is called whenever it's expected boundary changes, things should be fine 🔥
What did you think of the rest of my proposal? If it's acceptable, we can avoid having any extra paltform specific code in Gio to support native windows.
hanswered
commented
Aug 2, 2022
WDYT?
I didn't observe any bottle-neck calling MoveWindow every frame. In case of lightweight code... As long as
link.Move(...)is called whenever it's expected boundary changes, things should be fine 🔥What did you think of the rest of my proposal? If it's acceptable, we can avoid having any extra paltform specific code in Gio to support native windows.
To support native window GIO should have platform view api available to it. Since GIO app is expected run on multiple platforms this could be more useful in the long run.
I think I can change some platform specific API calls to that are already available in GIO.
hanswered
commented
Aug 2, 2022
And I also think that having a pointer passed around just for knowing it's boundary a little bit much. But for convenience we may want GIO to know about the underlying platform code.
eliasnaur
commented
Aug 2, 2022
WDYT?
I didn't observe any bottle-neck calling MoveWindow every frame. In case of lightweight code... As long as
link.Move(...)is called whenever it's expected boundary changes, things should be fine 🔥What did you think of the rest of my proposal? If it's acceptable, we can avoid having any extra paltform specific code in Gio to support native windows.
To support native window GIO should have platform view api available to it. Since GIO app is expected run on multiple platforms this could be more useful in the long run. I think I can change some platform specific API calls to that are already available in GIO.
I'm don't think the platform view API belongs in Gio if it doesn't need to. Like most other projects, we should be diligent about not increasing the long-term maintenance burden, and platform code is always the most troublesome to maintain.
hanswered
commented
Aug 2, 2022
I think having some examples based around it might be enough.
0d543a0 to
1686874
Compare
67c77c9 to
46cc311
Compare
f8029f2 to
026d3f9
Compare
632a44d to
072d68c
Compare
3d36537 to
74ccc9c
Compare
e8d63ad to
c250d7d
Compare
4d8d111 to
23e823d
Compare
Uh oh!
There was an error while loading. Please reload this page.
This is my implementation of win32 platform view.
To fix https://todo.sr.ht/~eliasnaur/gio/428