diff --git a/README.md b/README.md index 44e314b..40fe579 100644 --- a/README.md +++ b/README.md @@ -1,31 +1,19 @@ -# LMV_unity / Raindrop viewer -## A viewer for secondlife and metaverse sims, target for android. +# Raindrop Viewer +An android client to connect to Secondlife and [OpenSimulator](http://opensimulator.org/wiki/Main_Page) grids, running on the Unity game engine. -Use Unity engine as crossplatform framework and library galore +This is experimental software. -Use LibreMetaverse library for client APIs. -Use FMOD for audio +## Development Screenshots + +![Game/3D Screen](docs/image/game.jpg "Game") + +![Main Screen](docs/image/main.jpg "Main") + +![Login Screen](docs/image/login.jpg "Login") + +![Map Screen](docs/image/map.jpg "Map") + +## How to build/contribute? +Please see [Raindrop Viewer Documentation](docs/Readme.md) -## Key findings -### Imaging -- System.Bitmap and System.Drawing is tightly integrated into the OpenMetaverse/LibreMetaverse library. - - I have since changed all Bitmap references to unity's Texture2D. -- Bitmap reading/drawing seems to take 100x on android compared to laptop. - - slow GPU uploading? to profile. -- J2C is computationally expensive to decode (to profile; apparently in the order of 0.3s on PC), so we will have to get the J2C from tex pipeline, decode, then save as other raw/compressed textures (bitmap? GPU format?) to disk.. -- turn off/ minimal texture fetching when in low-network more (metered internet). - - fetchy-ness factor in settings? -### consistency of connection -- limitiation - activity lifecycle - - android kills apps when switching due to memory pressure. - - user may answer a call, causing app to close. - - when this happens, the connection state can be non-determinatistic - - to avoid non-deterministic connection, our best bet is to force a logoff to the server, then reconnect once the app is switched back. - - our aim is to: - - preserve the illusion of connected-ness as long as the user did not log off. - - switching-off the app ALWAYS triggers log-off in the client API. - - upon returning to the app - - app is still alive : internally re-connect to server and do *not* reload scene. - - app is dead : internally re-connect to server. have to reload scene. - diff --git a/docs/Readme.md b/docs/Readme.md new file mode 100644 index 0000000..06d3c91 --- /dev/null +++ b/docs/Readme.md @@ -0,0 +1,18 @@ +# Raindrop Viewer Documentation + +This is the [Raindrop Viewer](https://github.com/RaindropViewer/RaindropViewer) development +docs. + +## Contributing + +If you are interested in contributing to the project: + +- **[Discord Server](https://discord.gg/B279UXtu)** - Join us on the Raindrop Viewer discord! + +## Building + +- **[How To Build](how-to-build.md)** - learn how to build the + application + +## Developer guide +- **Tooling** - use rider IDE. Or use VS 2019 if you believe in hardly working. diff --git a/docs/code-organisation.md b/docs/code-organisation.md new file mode 100644 index 0000000..5284de0 --- /dev/null +++ b/docs/code-organisation.md @@ -0,0 +1,6 @@ +# Code Organisation + +Under Construction... + +## Libs +It uses a modified [libremetaverse](https://github.com/cinderblocks/libremetaverse) library. diff --git a/docs/how-to-build.md b/docs/how-to-build.md new file mode 100644 index 0000000..af434c5 --- /dev/null +++ b/docs/how-to-build.md @@ -0,0 +1,42 @@ +# How to build Raindrop Viewer + +## Dependencies +- Unity LTS 2020.3.29f1 +- Windows 10 + +## 1. Setup developer environment + +This assumes you are using windows 10. +1. install LTS Unity and your favourite C# IDE (VS 2019 or rider are known to work). +2. open command prompt, input this: + + `git clone https://github.com/RaindropViewer/RaindropViewer` +3. Now you should have a folder called `RaindropViewer`. +4. open Unity Hub, and click the `ADD` button. +5. navigate to the folder `RaindropViewer` and click `Select Folder`. +6. Now, you can click the project and open it with Unity. +7. The project should load with no errors. + +## 2. Run the Viewer in unity editor + +1. In Unity, open up `BootstrapScene` +2. press the `Play button` at the top of unity editor. +3. The viewer should start and you can try out the app. + +## 2b. (optional; sanity check) Try running some tests in Unity Test Runner. +Please ensure you download the unity test runner plugin first. (not documented here) +1. Open the test runner window: Window > General > Test Runner +2. Click `PlayMode` tab +3. You can run tests in the RaindropViewer>Tests.dll>OpenMetaverse folder. These are stable. It might take 5 minutes as a certain test takes strangely long. +4. Do note that network tests will fail unless you set an actual password in `secrets.cs` + +## 3. Build for Android Device +In unity, +1. File > Build Setting +2. ensure `Android` is selected on left. +3. ensure `Raindrop/Bootstrap/Bootstrap` is the first scene at the top. (this is the entry point of the app) +4. (optional) you can now select your android device from the list + + `(make sure you turn on ADB on your phone first!)` +5. Click `Build and Run` or `Build`. +6. if `Build and Run` succeeds, your viewer will start running on the phone! congrats :) \ No newline at end of file diff --git a/docs/image/game.jpg b/docs/image/game.jpg new file mode 100644 index 0000000..776fd4b Binary files /dev/null and b/docs/image/game.jpg differ diff --git a/docs/image/login.jpg b/docs/image/login.jpg new file mode 100644 index 0000000..98e21c5 Binary files /dev/null and b/docs/image/login.jpg differ diff --git a/docs/image/main.jpg b/docs/image/main.jpg new file mode 100644 index 0000000..eb1f8b3 Binary files /dev/null and b/docs/image/main.jpg differ diff --git a/docs/image/map.jpg b/docs/image/map.jpg new file mode 100644 index 0000000..e50148c Binary files /dev/null and b/docs/image/map.jpg differ