Coder Social home page Coder Social logo

4pablo124 / unity_android_screen_recorder Goto Github PK

View Code? Open in Web Editor NEW

This project forked from thanh-nguyen-kim/unity_android_screen_recorder

0.0 1.0 0.0 1.83 MB

A simpler demo record screen plugin for record Android Screen

License: GNU General Public License v3.0

ShaderLab 4.77% C# 95.23%

unity_android_screen_recorder's Introduction

Unity_Android_Screen_Recorder

https://killertee.wordpress.com/2018/01/08/unity-android-record-game-screen-with-audio-using-your-ad-hoc-plug-in/

If you are using this library in one of your applications and would like to thank me:

Buy Me A Coffee

How to use

  • You need to create a gameobject name 'AndroidUtils' and add 'AndroidUtils.cs' script to it.
  • When you want to start capturing your screen, call 'androidUtils.StartRecording()'. 'androidUtils' is a reference to AndroidUtils.cs instance.
  • When you want to stop capturing your screen, call 'androidUtils.StopRecording()'. 'androidUtils' is a reference to AndroidUtils.cs instance.

A simple demo of AndroidUtils Plugin which provide 3 main function

  • Record android screen.
  • Request runtime permissions like Audio..
  • Refresh android gallery so you capture file will show up on top.

It also contains 2 helper functions

  • NativeShare for native send or share a video, image or text via social network, sms and email.
  • ShowToast show android toast message.

Note that

  • You might need to adjust the 'SCREEN_WIDTH' constant in AndroidUtils.cs for best video resolution. If 'SCREEN_WIDTH' is too big, your app may crash.
  • The plugin only support api 21 and higher.
  • Some Mediatek devices will crash if DEFAULT video encoder is used. Change to H264 may solve the problem.
androidRecorder.Call("setupVideo", width, height,bitrate, fps,audioEnable,VideoEncoder.H264.ToString());

Visit this site to get a details explaining of Unity_Android_Screen_Recorder.

https://killertee.wordpress.com/2018/01/08/unity-android-record-game-screen-with-audio-using-your-ad-hoc-plug-in/

unity_android_screen_recorder's People

Contributors

thanh-nguyen-kim avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.