|
|
On 5/21/21 11:36 PM Ian MacArthur wrote:
On 21 May 2021, at 22:12, Albrecht Schlosser wrote:
On 5/21/21 9:57 PM Ian MacArthur wrote:
On 21 May 2021, at 13:11, Albrecht Schlosser wrote:
I'd also like to see an option to switch drivers (GDI <-> GDI+) dynamically so users can maybe switch back to pure old GDI in time-critical drawing paths (somebody mentioned this, IIRC). This option might already exist (internally) but I don't know if there's an API to be easily applied. If so, it should be documented.
I have no idea if this is even feasible?
We’ve never really had support for changing the back-end dynamically at runtime, though, have we? It’s always been a build-time sort of option.
Changing the "driver" during runtime is well-established. Think of offline drawing, Fl_Printer, and whatnot.
OK, yes, this is true. I think I expressed myself poorly here... in essence, I think that GDI and GDI+ are “the same” driver, but have somewhat different internal paths for the rendering. It is this internal path that we would have to change dynamically, and I do not think that is a thing we do at present, changing the internals of the driver to use a different back-end during runtime...?
The GDI and GDI+ drivers are different classes. The GDI+ driver is
derived from the GDI driver and defines its own virtual methods. IMHO
the only part we don't have yet is that at initialization time only one
of these two drivers is instantiated which is done by #ifdef'ed code. If
we managed to instantiate both drivers and assign the "correct one" at
any time we can presumably switch drivers as we like. Another problem I
can see may be the driver's (i.e. GDI vs. GDI+) internal Windows context
but I don't know anything about that.
Note that this view is partially backed by viewing the current source
code (virtual driver methods) but other parts are just educated guesses
and may be oversimplified.
--
You received this message because you are subscribed to the Google Groups "fltk.coredev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkcoredev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/d91950ff-243d-2db9-deb9-01fb3d7ab1a0%40online.de.
[ Direct Link to Message ] | |
|
| |