{"id":13717121,"url":"https://github.com/glomadrian/RoadRunner","last_synced_at":"2025-05-07T06:31:59.602Z","repository":{"id":138276856,"uuid":"54311516","full_name":"glomadrian/RoadRunner","owner":"glomadrian","description":"Road Runner is a library for android which allow you to make your own loading animation using a SVG image","archived":false,"fork":false,"pushed_at":"2022-07-29T05:15:46.000Z","size":3880,"stargazers_count":1147,"open_issues_count":9,"forks_count":131,"subscribers_count":39,"default_branch":"master","last_synced_at":"2025-04-12T14:56:13.271Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/glomadrian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2016-03-20T10:19:01.000Z","updated_at":"2025-03-30T00:20:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"811cc8cb-c90d-4462-bbcf-06d98f94882d","html_url":"https://github.com/glomadrian/RoadRunner","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/glomadrian%2FRoadRunner","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/glomadrian%2FRoadRunner/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/glomadrian%2FRoadRunner/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/glomadrian%2FRoadRunner/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/glomadrian","download_url":"https://codeload.github.com/glomadrian/RoadRunner/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252826899,"owners_count":21810201,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T00:01:18.191Z","updated_at":"2025-05-07T06:31:57.135Z","avatar_url":"https://github.com/glomadrian.png","language":"Java","funding_links":[],"categories":["Libs","Java"],"sub_categories":["\u003cA NAME=\"Animations\"\u003e\u003c/A\u003eAnimations"],"readme":"# Road Runner\n[![Download](https://api.bintray.com/packages/glomadrian/maven/RoadRunner/images/download.svg) ](https://bintray.com/glomadrian/maven/RoadRunner/_latestVersion)\n[![Hex.pm](https://img.shields.io/hexpm/l/plug.svg)](http://www.apache.org/licenses/LICENSE-2.0) [![Platform](https://img.shields.io/badge/platform-android-green.svg)](http://developer.android.com/index.html)\n[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-RoadRunner-green.svg?style=true)](https://android-arsenal.com/details/1/3303)\n\u003ccenter\u003e\n\u003cimg src=\"./art/roadrunnerlogo.png \" alt=\"Drawing\" width=\"250\" /\u003e\n\u003c/center\u003e\n\u003c/br\u003e\n\u003cp\u003e\nRoad Runner is a library for android which allow you to make your own loading\nanimation using a SVG image\n\u003cp/\u003e\n\n\n## Sample video\n\n[View in Youtube](https://www.youtube.com/watch?v=1ru8vBtywHE)\n## Demo Application\n\u003ca href=\"https://play.google.com/store/apps/details?id=com.github.glomadrian.pathloading\"\u003e\n\u003cimg src=\"https://play.google.com/intl/en_us/badges/images/generic/en-play-badge.png\" alt=\"Get on google play\" height=\"60\" border=\"0\"\u003e\n\u003c/a\u003e\n#### Road Runner intro\n\u003ccenter\u003e\n\u003cimg src=\"./art/roadRunner.gif \" alt=\"Drawing\"  width=\"250\" /\u003e\n\n\n#### Determiante\n\u003ccenter\u003e\n\u003cimg src=\"./art/cityshort.gif \" alt=\"Drawing\" width=\"250\" /\u003e\n\u003cimg src=\"./art/citylong.gif \" alt=\"Drawing\" width=\"250\" /\u003e\n\n#### Determiante with value update\n\u003ccenter\u003e\n\u003cimg src=\"./art/determinateTwoWay.gif \" alt=\"Drawing\" width=\"250\" /\u003e\n\n#### Material animation with twitter logo\n\u003ccenter\u003e\n\u003cimg src=\"./art/materialTwitter.gif \" alt=\"Drawing\" width=\"250\" /\u003e\n\n#### TwoWay animation with Github logo\n\u003ccenter\u003e\n\u003cimg src=\"./art/twowaygthub.gif \" alt=\"Drawing\" width=\"250\" /\u003e\n\n## How to\n\nThe library use the standard String path information (only one path) and the original size to works, you need to obtain it using a external tool, the path information look like this:\n\n```\nM306.314,58.9801 C275.235,27.9011,224.837,27.9011,193.759,58.9801\nL39.0019,213.736 C15.6832,237.055,15.6832,274.838,39.0019,298.158\nC58.2219,317.378,87.2116,320.482,109.874,308.007\nC112.241,307.888,114.569,306.993,116.38,305.202 L271.136,150.445\nC286.675,134.906,286.675,109.717,271.136,94.1779\nC255.597,78.6389,230.408,78.6389,214.869,94.1779 L88.2461,220.8\nC84.366,224.68,84.366,230.987,88.2461,234.866\nC92.1263,238.746,98.4335,238.746,102.313,234.866 L228.935,108.245\nC236.715,100.465,249.309,100.465,257.07,108.245\nC264.85,116.025,264.85,128.619,257.07,136.379 L109.337,284.111\nC93.7979,299.65,68.6085,299.65,53.0694,284.111\nC37.5304,268.572,37.5304,243.383,53.0694,227.844 L207.825,73.0468\nC231.144,49.7281,268.928,49.7281,292.247,73.0468\nC315.566,96.3654,315.566,134.149,292.247,157.469 L151.558,298.158\nC147.678,302.038,147.678,308.345,151.558,312.225\nC155.438,316.105,161.745,316.105,165.625,312.225 L306.314,171.535\nC337.393,140.457,337.393,90.0591,306.314,58.98 Z\n```\nAnd the width and height can be found in the svg definition:\n\n```\nheight=\"316\"\nwidth=\"512\"\n```\n\n\n### Using the view (Samples)\n\n#### Two way\n\n``` xml\n\u003ccom.github.glomadrian.roadrunner.IndeterminateRoadRunner\n      android:id=\"@+id/two_way\"\n      android:layout_width=\"match_parent\"\n      android:layout_height=\"match_parent\"\n      lib:movement_loop_time=\"4000\"\n      lib:movement_direction=\"counter_clockwise\"\n      lib:path_color=\"@color/two_way\"\n      lib:line_size=\"0.05\"\n      lib:stroke_width=\"3sp\"\n      lib:left_line_animation_time=\"2800\"\n      lib:left_line_max_size=\"0.5\"\n      lib:left_line_animation_start_delay=\"2500\"\n      lib:right_line_animation_start_delay=\"2000\"\n      lib:right_line_max_size=\"0.5\"\n      lib:right_line_animation_time=\"2000\"\n      lib:path_data=\"@string/github\"\n      lib:path_original_width=\"@integer/github_original_width\"\n      lib:path_original_height=\"@integer/github_original_height\"\n      lib:path_animation_type=\"twoWay\"\n      /\u003e\n```\n#### Material\n``` xml\n\u003ccom.github.glomadrian.roadrunner.IndeterminateRoadRunner\n     android:id=\"@+id/material\"\n     android:layout_width=\"match_parent\"\n     android:layout_height=\"match_parent\"\n     lib:movement_direction=\"counter_clockwise\"\n     lib:path_color=\"#FFFFFF\"\n     lib:stroke_width=\"3sp\"\n     lib:path_data=\"@string/twitter\"\n     lib:path_original_width=\"@integer/twitter_original_width\"\n     lib:path_original_height=\"@integer/twitter_original_height\"\n     lib:path_animation_type=\"material\"\n     /\u003e\n```\n#### Determinate Two way\n``` xml\n\u003ccom.github.glomadrian.roadrunner.DeterminateRoadRunner\n    android:id=\"@+id/determinate\"\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"match_parent\"\n    lib:min=\"0\"\n    lib:max=\"100\"\n    lib:movement_direction=\"counter_clockwise\"\n    lib:path_color=\"@color/colorAccent\"\n    lib:stroke_width=\"2sp\"\n    lib:movement_loop_time=\"1500\"\n    lib:path_data=\"@string/clip\"\n    lib:path_original_width=\"@integer/clip_original_width\"\n    lib:path_original_height=\"@integer/clip_original_height\"\n    lib:animate_on_start=\"false\"\n    /\u003e\n```\n\n## Custom attributes\n\n### Common\n\n* **movement_direction:** clockwise or counter_clockwise\n* **path_color:** color of the painted path\n* **stroke_width:** width of the painted path\n* **path_data:** String with the path information\n* **path_original_width:** The original with defined in the SVG\n* **path_original_height:** The original height defined in the SVG\n* **animate_on_start:** true or false, init the animation on first paint (true by default)\n\n\n### Indeterminate\n* **path_animation_type:** Select indetermina animation type, can be:\n  * material\n  * twoWay\n\n#### Indeterminate Material\n\n* Dont have any custom attributes\n\n#### Indeterminate Two way\n* **movement_loop_time:**** Time take to do a complete loop\n* **line_size:**\\* The size of the base line\n* **left_line_animation_time:** Time take to do a complete animation to the left line\n* **right_line_animation_time:** Time take to do a complete animation to the right line\n* **left_line_max_size:**\\*  The max size that the left line can research in the animation\n* **right_line_max_size:**\\* The max size that the right line can research in the animation\n* **left_line_animation_start_delay:** Time to wait to start the left line animation (in milliseconds)\n* **right_line_animation_start_delay:** Time to wait to start the right line animation (in milliseconds)\n\n\\* From 0f to 1f, 1f is all the path\n\n### Determinate\n* **min:** Min value for the progress\n* **max:** Max value for the progress\n* **movement_loop_time:** Time take to do a complete loop\n* **movement_line_size:**\\*  The size of the line\n\n\\* From 0f to 1f, 1f is all the path\n\n\n## Attributions\n* Thanks to Jorge Castillo Pérez for his [AndroidFillableLoaders](https://github.com/JorgeCastilloPrz/AndroidFillableLoaders) has been very helpful\n\n\nFor Gradle\n---------------------\n\nAdd repository\n\n```groovy\nrepositories {\n  maven {\n    url \"http://dl.bintray.com/glomadrian/maven\"\n  }\n}\n```\nAdd dependency\n```groovy\ncompile 'com.github.glomadrian:roadrunner:1.0@aar'\n```\nDeveloped By\n------------\nAdrián García Lomas - \u003cglomadrian@gmail.com\u003e\n* [Twitter](https://twitter.com/glomadrian)\n* [LinkedIn](https://es.linkedin.com/in/glomadrian )\n\nLicense\n-------\n\n    Copyright 2016 Adrián García Lomas\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fglomadrian%2FRoadRunner","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fglomadrian%2FRoadRunner","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fglomadrian%2FRoadRunner/lists"}