{"id":18440478,"url":"https://github.com/lackhole/plotting-for-opencv","last_synced_at":"2025-07-16T10:34:12.454Z","repository":{"id":116951206,"uuid":"150936669","full_name":"lackhole/Plotting-for-OpenCV","owner":"lackhole","description":"Plotting for OpenCV (C++)","archived":false,"fork":false,"pushed_at":"2019-12-06T14:09:56.000Z","size":610,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-14T17:32:20.585Z","etag":null,"topics":["cpp","graph","image","math","opencv","plot","plotting"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lackhole.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-09-30T06:13:16.000Z","updated_at":"2024-01-01T07:04:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"06265dfd-6a87-4c7a-a21f-9a278bb87e31","html_url":"https://github.com/lackhole/Plotting-for-OpenCV","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/lackhole/Plotting-for-OpenCV","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lackhole%2FPlotting-for-OpenCV","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lackhole%2FPlotting-for-OpenCV/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lackhole%2FPlotting-for-OpenCV/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lackhole%2FPlotting-for-OpenCV/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lackhole","download_url":"https://codeload.github.com/lackhole/Plotting-for-OpenCV/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lackhole%2FPlotting-for-OpenCV/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265503163,"owners_count":23778015,"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":["cpp","graph","image","math","opencv","plot","plotting"],"created_at":"2024-11-06T06:30:28.785Z","updated_at":"2025-07-16T10:34:12.349Z","avatar_url":"https://github.com/lackhole.png","language":"C++","readme":"# Plotting for OpenCV\n## Plotting for OpenCV(C++)\n\u003c/br\u003e\u003c/br\u003e\nSimple Plot  \n\u003cimg src=\"/Example.png\" width=\"450px\" height=\"300px\"\u003e\u003c/img\u003e\u003c/br\u003e  \nGUI Plot  \n\u003cimg src=\"/22.PNG\" width=\"450px\" height=\"400px\"\u003e\u003c/img\u003e\u003c/br\u003e\n\n\n## Requirements :\n        -OpenCV version 3.4.0 or later (4.X might not be compatible)\n\n\n1. Include plot.h, plot.cpp to your main project\n2. Create `Canvas` for drawing plot(written below)\n3. Draw!\n\n## Creating Canvas Examples:\n\n        Canvas instance([height],[width],[\"Title Name\"]); ::\n        \n        Canvas example1(600,800,\"Example Plot\");\n        Canvas example2(700,700);\n        Canvas example3;\n        example3.create(400,500);\n        Canvas example4;\n        example4.create(500,600,\"Example Plot\");\n        \nAfter you declare a empty Canvas, you can draw a plot with number of dots, array of x and y data, and Scalar color(provided by OpenCV).\n\n\nFor example, let's assume that x[100] and y[100] is filled with data.\n\n        example1.draw(100,x,y,Scalar(0,0,0));           // draw first 100 numbers of array x and y\n        example1.draw(30,x,y,Scalar(255,0,0));          // draw first 30 numbers of array x and y\n        example2.draw(70,x,y,Scalar(0,0,255),\"y=sin(x)\"); // draw first 70 numbers of array x and y, with name shown with colors.\n        \n   + Alert : ranges are set by first given plot.\n        if you draw x[]={1,2,3} and y[]={-1,-2,-3} first, then draw x2[]={4,5,6},y2[]={7,8,9} later,\n        the range is fixed to x-axis = [1,3] and y-axis = [-3,1], so x2 and y2 is not visible.\n        You can solve this by setting range manually, or draw big invisible(white) dummy plot first.\n        \n        \nAfter you draw a plot, you have to call show() function.\n\n        example1.show();\n        example2.show();\n        You can also show multiple plot at once.\n        Given example will show 2 plots.\n                \n## Functions:\n`Double click` to zoom in, press Home Button to return.\n\n## Additional Options:\n\n        example1.grid(true)     // turns on grid\n        example2.expand(false)  // turns off expanding axis range. default expands 20%\n        example3.range(0,10,20,50)      // set range manually.\n        example1.write(\"C:/myfolder/\",\"plot.png\")       //save plot.png at C:\\myfolder\\\n\n\n\nCurrently in develop! :D\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flackhole%2Fplotting-for-opencv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flackhole%2Fplotting-for-opencv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flackhole%2Fplotting-for-opencv/lists"}