Resolving some issues drawing on android (floating point errors)