{"id":17970446,"url":"https://github.com/justadudewhohacks/opencv-electron","last_synced_at":"2025-03-25T11:31:22.287Z","repository":{"id":57315312,"uuid":"105622774","full_name":"justadudewhohacks/opencv-electron","owner":"justadudewhohacks","description":"Example for using opencv4nodejs with electron.","archived":false,"fork":false,"pushed_at":"2019-02-25T03:14:25.000Z","size":807,"stargazers_count":144,"open_issues_count":8,"forks_count":40,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-03-18T10:53:24.979Z","etag":null,"topics":["electron","javascript","node","nodejs","opencv","react","reactjs","webpack"],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/justadudewhohacks.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}},"created_at":"2017-10-03T06:57:59.000Z","updated_at":"2025-02-16T07:35:38.000Z","dependencies_parsed_at":"2022-09-12T15:02:14.443Z","dependency_job_id":null,"html_url":"https://github.com/justadudewhohacks/opencv-electron","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/justadudewhohacks%2Fopencv-electron","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justadudewhohacks%2Fopencv-electron/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justadudewhohacks%2Fopencv-electron/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justadudewhohacks%2Fopencv-electron/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/justadudewhohacks","download_url":"https://codeload.github.com/justadudewhohacks/opencv-electron/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245453902,"owners_count":20617939,"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":["electron","javascript","node","nodejs","opencv","react","reactjs","webpack"],"created_at":"2024-10-29T15:05:29.002Z","updated_at":"2025-03-25T11:31:21.587Z","avatar_url":"https://github.com/justadudewhohacks.png","language":"HTML","funding_links":[],"categories":["HTML"],"sub_categories":[],"readme":"opencv-electron\n==============\n**This is an example of how to use [opencv4nodejs](https://github.com/justadudewhohacks/opencv4nodejs) with electron to build cross-platform desktop apps.**\n\n![opencv-electron](https://user-images.githubusercontent.com/31125521/31113188-51e7c6d8-a818-11e7-9015-295d1864e1d6.jpg)\n\nNote that there is an additional npm script to rebuild the package for electron, which is called from the install script:\n```\n\"electron-rebuild\": \"electron-rebuild -w opencv4nodejs\"\n```\n\n# plain-js\nThis example shows how to use opencv4nodejs with electron and plain HTML + Javascript without any bundler.\n\n## Running this example:\n\n### Set up opencv4nodejs, electron and rebuild the module for electron:\n``` bash\nnpm install\n```\n\n### Run:\n``` bash\nnpm start\n```\n\n# webpack-reactjs\nThis example shows how to use opencv4nodejs with webpack and react, requires node-loader to load the native addon.\n``` bash\nnpm i node-loader\n```\n\n## On windows\nIf you are using the autobuild on windows, you have to append the path to the binaries\nto the path env of main process manually as follows (in main.js):\n```\nif (process.platform === 'win32' \u0026\u0026 !process.env.OPENCV4NODEJS_DISABLE_AUTOBUILD) {\n  process.env.path += ';' + require('../renderer/node_modules/opencv-build').opencvBinDir\n}\n```\n\n## Running this example:\n\nIn the root directory:\n``` bash\nnpm install\nnpm start\n```\n\nIn another terminal cd into ./renderer and run the dev server:\n``` bash\nnpm install\nnpm start\n```\n\n# Known issues\n\nIf you are receiving the following error on windows during electron-rebuild:\n``` bash\nAttributeError: 'MSVSProject' object has no attribute 'iteritems'\n```\n\nDelete fsevents from your node_modules folder and rerun:\n```\nnpm run electron-rebuild\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustadudewhohacks%2Fopencv-electron","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjustadudewhohacks%2Fopencv-electron","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustadudewhohacks%2Fopencv-electron/lists"}