cv2-rectangle-around-center


Namecv2-rectangle-around-center JSON
Version 0.10 PyPI version JSON
download
home_pagehttps://github.com/hansalemaos/cv2_rectangle_around_center
SummaryCreates a rectangle around a center point
upload_time2022-12-29 22:14:07
maintainer
docs_urlNone
authorJohannes Fischer
requires_python
licenseMIT
keywords cv2 numpy rectangle center
VCS
bugtrack_url
requirements a_cv_imwrite_imread_plus opencv_python
Travis-CI No Travis.
coveralls test coverage No coveralls.
            
<h2>Creates a rectangle around a center point</h2>





```python



$pip install cv2-rectangle-around-center



from cv2_rectangle_around_center import line_rectangle_center, rectangle_center

# Allowed image formats: url/path/buffer/base64/PIL/np





im1 = line_rectangle_center(

    image=r"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png",

    center=(150, 150),

    width=200,

    height=280,

    thickness=6,

    color1=(255, 0, 0),

    color2=(255, 255, 0),

    color3=(255, 0, 255),

    color4=(0, 255, 255),

    save_path="f:\\recta\\lines.png",

)



im2 = rectangle_center(

    image=r"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png",

    center=(150, 150),

    width=200,

    height=280,

    thickness=6,

    color=(255, 0, 0),

    save_path="f:\\recta\\rect1.png",

)



im3 = rectangle_center(

    image=r"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png",

    center=(150, 150),

    width=200,

    height=280,

    thickness=-1,

    color=(255, 255, 0),

    save_path="f:\\recta\\rect2.png",

)



```



<img src="https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png"/>





<img src="https://github.com/hansalemaos/screenshots/raw/main/lines.png"/>





<img src="https://github.com/hansalemaos/screenshots/raw/main/rect1.png"/>







<img src="https://github.com/hansalemaos/screenshots/raw/main/rect2.png"/>

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/hansalemaos/cv2_rectangle_around_center",
    "name": "cv2-rectangle-around-center",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "cv2,numpy,rectangle,center",
    "author": "Johannes Fischer",
    "author_email": "<aulasparticularesdealemaosp@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/50/11/0edc3839ae9d92c91317d9aa8369b04fab9861a55a9ea24ea1a2ba495810/cv2_rectangle_around_center-0.10.tar.gz",
    "platform": null,
    "description": "\n<h2>Creates a rectangle around a center point</h2>\n\n\n\n\n\n```python\n\n\n\n$pip install cv2-rectangle-around-center\n\n\n\nfrom cv2_rectangle_around_center import line_rectangle_center, rectangle_center\n\n# Allowed image formats: url/path/buffer/base64/PIL/np\n\n\n\n\n\nim1 = line_rectangle_center(\n\n    image=r\"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png\",\n\n    center=(150, 150),\n\n    width=200,\n\n    height=280,\n\n    thickness=6,\n\n    color1=(255, 0, 0),\n\n    color2=(255, 255, 0),\n\n    color3=(255, 0, 255),\n\n    color4=(0, 255, 255),\n\n    save_path=\"f:\\\\recta\\\\lines.png\",\n\n)\n\n\n\nim2 = rectangle_center(\n\n    image=r\"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png\",\n\n    center=(150, 150),\n\n    width=200,\n\n    height=280,\n\n    thickness=6,\n\n    color=(255, 0, 0),\n\n    save_path=\"f:\\\\recta\\\\rect1.png\",\n\n)\n\n\n\nim3 = rectangle_center(\n\n    image=r\"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png\",\n\n    center=(150, 150),\n\n    width=200,\n\n    height=280,\n\n    thickness=-1,\n\n    color=(255, 255, 0),\n\n    save_path=\"f:\\\\recta\\\\rect2.png\",\n\n)\n\n\n\n```\n\n\n\n<img src=\"https://raw.githubusercontent.com/hansalemaos/screenshots/main/diff.png\"/>\n\n\n\n\n\n<img src=\"https://github.com/hansalemaos/screenshots/raw/main/lines.png\"/>\n\n\n\n\n\n<img src=\"https://github.com/hansalemaos/screenshots/raw/main/rect1.png\"/>\n\n\n\n\n\n\n\n<img src=\"https://github.com/hansalemaos/screenshots/raw/main/rect2.png\"/>\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Creates a rectangle around a center point",
    "version": "0.10",
    "split_keywords": [
        "cv2",
        "numpy",
        "rectangle",
        "center"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "f13cdad72d1883d4b37cb4ae8316cf55",
                "sha256": "47634b1fcfafb279fd9c1c98fcb786cc3ae12462bf5bf79d5003770c4449b05f"
            },
            "downloads": -1,
            "filename": "cv2_rectangle_around_center-0.10-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "f13cdad72d1883d4b37cb4ae8316cf55",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 5285,
            "upload_time": "2022-12-29T22:14:05",
            "upload_time_iso_8601": "2022-12-29T22:14:05.893423Z",
            "url": "https://files.pythonhosted.org/packages/ae/00/9e9fff1493c38f128cb26584d01798d84a2b09cf83eaa0004111094aead9/cv2_rectangle_around_center-0.10-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "3792ae5808736981952d073c9e35b93b",
                "sha256": "9465807e650c40624c1894cc0203b470581bf7168e5fcf62e69136b65119bc0a"
            },
            "downloads": -1,
            "filename": "cv2_rectangle_around_center-0.10.tar.gz",
            "has_sig": false,
            "md5_digest": "3792ae5808736981952d073c9e35b93b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 3633,
            "upload_time": "2022-12-29T22:14:07",
            "upload_time_iso_8601": "2022-12-29T22:14:07.386001Z",
            "url": "https://files.pythonhosted.org/packages/50/11/0edc3839ae9d92c91317d9aa8369b04fab9861a55a9ea24ea1a2ba495810/cv2_rectangle_around_center-0.10.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-12-29 22:14:07",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "hansalemaos",
    "github_project": "cv2_rectangle_around_center",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "a_cv_imwrite_imread_plus",
            "specs": []
        },
        {
            "name": "opencv_python",
            "specs": []
        }
    ],
    "lcname": "cv2-rectangle-around-center"
}
        
Elapsed time: 0.11990s