{"id":18352829,"url":"https://github.com/membraneframework/membrane_camera_capture_plugin","last_synced_at":"2025-04-06T11:33:07.827Z","repository":{"id":39995204,"uuid":"447151771","full_name":"membraneframework/membrane_camera_capture_plugin","owner":"membraneframework","description":"A set of elements allowing for capturing local media such as camera or microphone","archived":false,"fork":false,"pushed_at":"2023-12-14T10:18:01.000Z","size":78,"stargazers_count":3,"open_issues_count":0,"forks_count":3,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-21T22:41:23.359Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/membraneframework.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":"2022-01-12T09:21:45.000Z","updated_at":"2024-04-02T17:40:51.000Z","dependencies_parsed_at":"2023-02-03T20:47:11.382Z","dependency_job_id":"8b8c5d4f-b022-4b96-98f0-4681870b7be7","html_url":"https://github.com/membraneframework/membrane_camera_capture_plugin","commit_stats":{"total_commits":28,"total_committers":10,"mean_commits":2.8,"dds":0.6428571428571428,"last_synced_commit":"b680ee060785c27e28b7d91296a6d22faaa55fe4"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":"membraneframework/membrane_template_plugin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/membraneframework%2Fmembrane_camera_capture_plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/membraneframework%2Fmembrane_camera_capture_plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/membraneframework%2Fmembrane_camera_capture_plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/membraneframework%2Fmembrane_camera_capture_plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/membraneframework","download_url":"https://codeload.github.com/membraneframework/membrane_camera_capture_plugin/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247478152,"owners_count":20945258,"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-11-05T21:37:35.690Z","updated_at":"2025-04-06T11:33:07.429Z","avatar_url":"https://github.com/membraneframework.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Membrane Camera Capture Plugin\n\n[![Hex.pm](https://img.shields.io/hexpm/v/membrane_camera_capture_plugin.svg)](https://hex.pm/packages/membrane_camera_capture_plugin)\n[![API Docs](https://img.shields.io/badge/api-docs-yellow.svg?style=flat)](https://hexdocs.pm/membrane_camera_capture_plugin)\n[![CircleCI](https://circleci.com/gh/membraneframework/membrane_camera_capture_plugin.svg?style=svg)](https://circleci.com/gh/membraneframework/membrane_camera_capture_plugin)\n\nThis plugin can be used to capture video stream from an input device.\n\nIt is part of [Membrane Multimedia Framework](https://membraneframework.org).\n\n## Installation\n\nAdd the following line to your `deps` in `mix.exs`. Run `mix deps.get`.\n\n```elixir\n\t{:membrane_camera_capture_plugin, \"~\u003e 0.7.2\"}\n```\n\nThis package depends on the [ffmpeg](https://www.ffmpeg.org) libraries. The precompiled builds will be pulled and linked automatically. However, should there be any problems, consider installing it manually.\n\n### Manual installation of dependencies\n#### Ubuntu\n\n```bash\nsudo apt-get install ffmpeg\n```\n\n#### Arch/Manjaro\n\n```bash\npacman -S ffmpeg\n```\n\n#### MacOS\n\n```bash\nbrew install ffmpeg\n```\n\n## Sample Usage\n\nThis example displays the stream from your camera on the screen:\n\n```elixir\nLogger.configure(level: :info)\n\nMix.install([\n  {:membrane_camera_capture_plugin, \"~\u003e 0.7.1\"},\n  :membrane_h264_ffmpeg_plugin,\n  :membrane_ffmpeg_swscale_plugin,\n  :membrane_sdl_plugin\n])\n\ndefmodule Example do\n  use Membrane.Pipeline\n\n  @impl true\n  def handle_init(_ctx, _options) do\n    spec =\n      child(Membrane.CameraCapture)\n      |\u003e child(%Membrane.FFmpeg.SWScale.PixelFormatConverter{format: :I420})\n      |\u003e child(Membrane.SDL.Player)\n\n    {[spec: spec], %{}}\n  end\nend\n\nMembrane.Pipeline.start_link(Example)\n\nProcess.sleep(:infinity)\n```\n\n## Testing\n\nTo run manual tests, you need to install dependencies:\n\n```shell\n$ mix deps.get\n```\n\nAnd run manual (you observe the result and decide whether it works) tests:\n\n```shell\n$ mix test --include manual\n```\n\nIf it runs successfully, you should be able to see video from your camera.\n\n_You might be asked to grant access to your camera, as some operating systems require that_\n\n_In case of the absence of a physical camera, it is necessary to use a virtual camera (e.g. OBS, [see how to set up the virtual camera in OBS](https://obsproject.com/kb/virtual-camera-guide))_\n\n## Copyright and License\n\nCopyright 2022, [Software Mansion](https://swmansion.com/?utm_source=git\u0026utm_medium=readme\u0026utm_campaign=membrane_camera_capture_plugin)\n\n[![Software Mansion](https://logo.swmansion.com/logo?color=white\u0026variant=desktop\u0026width=200\u0026tag=membrane-github)](https://swmansion.com/?utm_source=git\u0026utm_medium=readme\u0026utm_campaign=membrane_camera_capture_plugin)\n\nLicensed under the [Apache License, Version 2.0](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmembraneframework%2Fmembrane_camera_capture_plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmembraneframework%2Fmembrane_camera_capture_plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmembraneframework%2Fmembrane_camera_capture_plugin/lists"}