9 more watchfaces and refactoring/redesign of old ones #11

Merged
merged 11 commits into from Mar 13, 2018

Conversation

Projects
None yet
2 participants
@eLtMosen
Collaborator

eLtMosen commented Mar 11, 2018

I gave up on finding a nice solution how to put gifs into the readme.md without having a seperate column. Markdown is pretty limited in that aspect sadly. Will look into designing a watchface page for asteroidOS.org and have neat user controlled play/stoppable gifs.
So this is what i got from cleaning up new watchfaces from last two weeks.
Hope you'll like some :)

@FlorentRevest

This comment has been minimized.

Show comment
Hide comment
@FlorentRevest

FlorentRevest Mar 13, 2018

Member

Hi @eLtMosen,

First of all thank you for your great work, as always.
This PR is definitely much better than the previous one, would it only be because of the commit log. I can accept it right away.

However, I have two points I wanted to mention:

  • First of all, I noticed you started using fragment shaders. This is great, it gives good perfs and amazing renderings however, due to a fault hw adaptation it produces garbage renderings on the Sony Smartwatch 3. This is actually the reason why we use Canvas everytime we need shadows in the official watchfaces. We used to have DropShadows from QtGraphicalEffects but the result was completely random on the sony sw3 and made this change... I still haven't decided how we should cleanly handle that. This watch has made watchfaces development a real pain and I still wonder if having switched everything to Canvas was a good decision... Anyway, just keep that in mind! The watchfaces using fragmentshaders will probably not be merged to asteroid-launcher. (or if they do, they will be disabled on the sony sw3)
  • The other observation I have is that you duplicate a lot of code between canvases and between watchfaces. For instance, I see a lot of the same trigonometric calculation across your entire PR. Would you be interested in modularizing your code with watchfaces templates in a new qml-asteroid submodule? For example, we could have an "org.asteroid.watchfaces 1.0" module exporting JS functions for the common trigonometric operations and also a bunch of QML items to inherit from such as AnalogWatchTemplate or DigitalWatchTemplate that would already have most of the code you write (Connections, the various Canvases you use everytime) plus a few properties to actually modify what matters (the arrow shapes/colors...)... This is a very open suggestion, feel free to experiment with this idea if you feel like it but I believe it could make a watchfaces developer life much easier...
Member

FlorentRevest commented Mar 13, 2018

Hi @eLtMosen,

First of all thank you for your great work, as always.
This PR is definitely much better than the previous one, would it only be because of the commit log. I can accept it right away.

However, I have two points I wanted to mention:

  • First of all, I noticed you started using fragment shaders. This is great, it gives good perfs and amazing renderings however, due to a fault hw adaptation it produces garbage renderings on the Sony Smartwatch 3. This is actually the reason why we use Canvas everytime we need shadows in the official watchfaces. We used to have DropShadows from QtGraphicalEffects but the result was completely random on the sony sw3 and made this change... I still haven't decided how we should cleanly handle that. This watch has made watchfaces development a real pain and I still wonder if having switched everything to Canvas was a good decision... Anyway, just keep that in mind! The watchfaces using fragmentshaders will probably not be merged to asteroid-launcher. (or if they do, they will be disabled on the sony sw3)
  • The other observation I have is that you duplicate a lot of code between canvases and between watchfaces. For instance, I see a lot of the same trigonometric calculation across your entire PR. Would you be interested in modularizing your code with watchfaces templates in a new qml-asteroid submodule? For example, we could have an "org.asteroid.watchfaces 1.0" module exporting JS functions for the common trigonometric operations and also a bunch of QML items to inherit from such as AnalogWatchTemplate or DigitalWatchTemplate that would already have most of the code you write (Connections, the various Canvases you use everytime) plus a few properties to actually modify what matters (the arrow shapes/colors...)... This is a very open suggestion, feel free to experiment with this idea if you feel like it but I believe it could make a watchfaces developer life much easier...

@FlorentRevest FlorentRevest merged commit caeac06 into AsteroidOS:master Mar 13, 2018

@eLtMosen

This comment has been minimized.

Show comment
Hide comment
@eLtMosen

eLtMosen Mar 13, 2018

Collaborator

Thank you for merging!

  • fragmentShader is what i used after discovering that OpacityMask from QtGraphicalEffects is not available. But i guess it would also produce junk on sony sw3?

  • modularization superceeds my current skills sadly, though i fully support your opinion on repetitive code. If you hint to a kind of self explanatory library i could sure try to work myself into that.
    It is also very helpfull for beginners to have well named functions opposed to naked instructions.

Currently i am building a new collection of wallpapers because i can do that in pauses during work.
Will open an issue over at asteroid-wallpapers with questions soonish.

Collaborator

eLtMosen commented Mar 13, 2018

Thank you for merging!

  • fragmentShader is what i used after discovering that OpacityMask from QtGraphicalEffects is not available. But i guess it would also produce junk on sony sw3?

  • modularization superceeds my current skills sadly, though i fully support your opinion on repetitive code. If you hint to a kind of self explanatory library i could sure try to work myself into that.
    It is also very helpfull for beginners to have well named functions opposed to naked instructions.

Currently i am building a new collection of wallpapers because i can do that in pauses during work.
Will open an issue over at asteroid-wallpapers with questions soonish.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment