[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kwin
Subject:    Functionality checks rethink for KDE SC 4.5?
From:       Lucas Murray <lmurray () undefinedfire ! com>
Date:       2010-01-20 7:10:04
Message-ID: 20100120071003.GA5122 () micchon
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


Since the current code breaks whenever the driver developers change
their version/renderer string I think we need to redesign how the checks
operate.

I'm thinking something along the lines of:

- Don't blacklist anything, including old drivers and software
  renderers. Assume everything works by default before the later
  rendering and speed tests.

- Don't write code that assumes that OpenGL initialisation code can
  crash KWin. Just have let KWin crash and auto-disable the entire
  OpenGL code with the config setting sync trick. E.g. the code would
  read:

    If config "OpenGLIsUnsafe" is unset {
      Write config "OpenGLIsUnsafe" = true
      Initialize OpenGL
      Set timer to delete config "OpenGLIsUnsafe" after 30 seconds
    }

  The 30 second delay is to protect against screen freezes that doesn't
  freeze process execution at the same time. The config setting would
  also need to be deleted when KWin safely exits.

  Note that this setting is separate from the normal disable compositing
  setting as the code needs to know the reason why it was disabled. Also
  there would need to be a manual "force recheck" button somewhere in
  the KCM as KWin will never know when to retest OpenGL.

- After OpenGL is initialized do the framebuffer rendering check only
  when the driver version or renderer string changes. The test may also
  need to have an artificial delay added as I think the current one
  sometimes has false-fails with some drivers as the first flush takes
  too long to execute?

- Don't have any OpenGL code in the KCMs at all. This prevents having to
  have duplicated code in KWin as well as helps keep the KCMs stable. If
  they need information on whether or not compositing is available they
  can just check the config files or D-Bus a running KWin process (If no
  process is running we can assume everything is supported as when KWin
  is started it does the functionality checks anyway).

- I can't think of a better way to do the speed test at the moment so
  it's fine how it is I guess.

- Although slightly unrelated I also think that the compositing suspend
  feature would be better removed as the difference between suspended
  and disabled is almost non-existent.

Thoughts/comments?

I know this new way is more susceptible to crashes and freezes than the
current method but I honestly think it's better in the long run.

-- 

Lucas Murray

PGP/GPG: 0x3D1C34CE; Fingerprint:
  3194 9C1D 4B4C AD7B 3538  551A 87F3 A7A8 3D1C 34CE

[Attachment #5 (application/pgp-signature)]

_______________________________________________
kwin mailing list
kwin@kde.org
https://mail.kde.org/mailman/listinfo/kwin


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic