Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix BORDER_ROUNDED on Container for linux arm devices #47

Merged
merged 1 commit into from
Jun 9, 2020

Conversation

ItaloYeltsin
Copy link
Contributor

Problem: When using Container.setStyle(BORDER_ROUNDED), the rounded border is drawn on java side using CPU and the draw is not right on linux arm resulting in a terrible rounded rectangle draw.

Solution: now BORDER_ROUNDED is drawn using Graphics primitives fillRoundedRect and drawRoundedRect. This allows GPU to take care of this draw fixing the terrible behaviour above. The simulator side keeps the solution above because roundrect does not draw beatufil round rectangles.

Description:

When using Container.setBorderStyle(BORDER_ROUNDED), a rounded rectangle is designed representing such a container. On linux arm devices, the draw is very creepy. In addition the draw is made on the Java side using CPU.

Related Issue:

  • this is being fix for an example

Motivation and Context:

This was made to get a more beautiful draw when using rounded borders on containers

Benefited Devices:

  • Device: linux_arm devices.
  • OS: any linux based distro.

Tested Devices:

  • Device: Raspberry pi 4
  • OS: Raspberry PI OS

@ItaloYeltsin ItaloYeltsin requested a review from ricardobna June 9, 2020 18:02
problem: wrong round rect draw when using setBorderStyle(BORDER_ROUNDED) on Container. Also the draw was made on GPU.
devices: linux_arm devices.
solution: primitives was changed from to fillRoundRect and drawRoundRect in order to use GPU and the behave is kept on simulator.
@ItaloYeltsin ItaloYeltsin force-pushed the bugfix/cotainer-rounded-borders branch from f4f8985 to c531d78 Compare June 9, 2020 19:20
@ItaloYeltsin ItaloYeltsin merged commit e83d277 into develop Jun 9, 2020
@ItaloYeltsin ItaloYeltsin deleted the bugfix/cotainer-rounded-borders branch June 9, 2020 19:33
flsobral pushed a commit that referenced this pull request Jul 16, 2020
problem: wrong round rect draw when using setBorderStyle(BORDER_ROUNDED) on Container. Also the draw was made on CPU.
devices: linux arm devices.
solution: primitives was changed from drawWindowBorder to fillRoundRect and drawRoundRect in order to use GPU. The old behave is kept on simulator because it works on it.
flsobral pushed a commit that referenced this pull request Jul 24, 2020
problem: wrong round rect draw when using setBorderStyle(BORDER_ROUNDED) on Container. Also the draw was made on CPU.
devices: linux arm devices.
solution: primitives was changed from drawWindowBorder to fillRoundRect and drawRoundRect in order to use GPU. The old behave is kept on simulator because it works on it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants