Giter Site home page Giter Site logo

arfoundation-demos's People

Contributors

arturonereu avatar danmillerdev avatar todds-unity avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

arfoundation-demos's Issues

Incompatible with XRInteractionToolkit

I have a problem integrating the UX part of this repo into my app.
The PlaceObjectOnPlane script replaces the ARPlacementInteractable of XRInteractionToolkit but doesn't integrate well with the ARSelectionInteractable. The PlaceObjectOnPlane script places a new object instead of deselecting another object.
Maybe it is an option to integrate the UX example into XRInteractionToolkit as it is a useful feature for almost all AR apps?

UX Samples do not scale with the screen well - tested on Iphone 7

Try 800 x 480 in Game view or 1280 x 720 and the bottom anchored overlay is off screen, also the Top of screen content is then simply huge and overlapping the bottom anchored content.

Iphone 7 is 1334 x 750 Pixels.

I am shocked this was released without a simple test of the resolutions in the Game view you can choose by default when making an IOS or Android project in Unity with ARFoundation.

The first device I tested on was an Iphone 7 which experienced these issues unfortunately this solution does not scale well.

Setting the Canvas Scaler to scale with screen size just means that the bottom anchored popups are off the screen always but scaling with it.

Not impressed with the scaling, however the icons are very nice and the presentation is great when it is on the right size phone screen.

AddToQueue() is not working properly

Let's say I want to restart my AR Onboarding UX.

Instructional IU: CrossPlatform Find A Plane
Goal: Found A Plane

Secondary Instructional IU: Tap To Place
Goal: Placed An Object

So to restart I just use the part of provided code:

public void ResetUXOrderedQueue() { if (m_StartWithInstructionalUI) { m_UXOrderedQueue.Enqueue(new UXHandle(m_InstructionalUI, m_InstructionalGoal)); } if (m_ShowSecondaryInstructionalUI) { m_UXOrderedQueue.Enqueue(new UXHandle(m_SecondaryInstructionUI, m_SecondaryGoal)); } }

Issue 1.

If I run this function before fading off of Secondary Instructional IU the it's working like a charm.
If I run this function after then UX will start with Secondary Instructional IU !

Issue 2.

When I switch to other app and go back to my App the Video Instruction is disappeared and in next restarts I have only text.

Environment:

  • iOS 15.0
  • Unity 2021.1.20
  • iPhone XS Max.

Issues opening project

I am having issues opening in Unity in 2020.1.0.a11 and also tried a newer version.

I get the following error:
Library/PackageCache/[email protected]/Editor/Shims/ApplicationSimulation.cs(6,44): error CS0246: The type or namespace name 'ApplicationShimBase' could not be found (are you missing a using directive or an assembly reference?)

Any ideas?

Second goal don't disappear

Hello,

When you reach the second goal before the first goal fade off (or the second fade on), the instruction don't disappear.
It's a little issue but it can be disturbing for the users.

Best,
Alexis

Fix CS0649 warnings (field never assigned)

Opening the project for the first time, I get 24 instances of

warning CS0649: Field 'XXX' is never assigned to, and will always have its default value null

Most of these are because a MonoBehaviour has a private [SerializeField] and only a public getter. There needs to be a public setter for each of these (this is also in line with established Unity coding standards -- see Slack thread)

KeyNotFoundException after adding ARPlane prefab to ARPlaneManager

After adding a ARPlane Prefab to ARPlaneManager I get constant KeyNotFoundException errors

This is the Xcode console output
KeyNotFoundException: The given key was not present in the dictionary.
at System.Collections.Generic.Dictionary`2[TKey,TValue].get_Item (TKey key) [0x00000] in <00000000000000000000000000000000>:0
at MeshClassificationManager.SetCurrentClassification (UnityEngine.XR.ARSubsystems.TrackableId meshID, System.Int32 triangleIndex) [0x00000] in <00000000000000000000000000000000>:0
at MeshClassificationManager.Update () [0x00000] in <00000000000000000000000000000000>:0

UX bugging on changing scene

UX manager is bugging when I'm swapping between different scenes that use AR. My use is simple, first goal is to detect at least one plane and second one is to tap to place the object. When I finish one scene and load next one I don't have this part of UI (bottom part is working ok).

I modified Update in UIManager.cs with Debug to check what is the problem.

    void Update ()
    {
        if (m_AnimationManager.localizeText)
        {
            if (!m_LocalizationManager.localizationComplete)
            {
                return;
            }
        }

        if (m_UXOrderedQueue.Count > 0 && !m_ProcessingInstructions)
        {
            // pop off
            m_CurrentHandle = m_UXOrderedQueue.Dequeue ();

            // fade on
            FadeOnInstructionalUI (m_CurrentHandle.InstructionalUI);
            m_GoalReached = GetGoal (m_CurrentHandle.Goal);
            m_ProcessingInstructions = true;
            m_FadedOff = false;
            Debug.Log ("Fade on " + m_CurrentHandle.Goal);
        }

        if (m_ProcessingInstructions)
        {
            // start listening for goal reached
            if (m_GoalReached.Invoke ())
            {
                // if goal reached, fade off
                if (!m_FadedOff)
                {
                    m_FadedOff = true;
                    m_AnimationManager.FadeOffCurrentUI ();
                    Debug.Log ("Fade off " + m_CurrentHandle.Goal);
                }
            }
        }
    }

When I change the scene, I call arsession.Reset() from another script, but it seems that phone is relocating all planes almost instantly. Therefore in console I have debug (based on Update() modifications) like this:

  • Fade on FoundAPlane
  • Fade off FoundAPlane
  • Fade on PlacedAnObject
    This 3 things happens almost at the same time. My app is working perfectly fine, but it turns out that ARUXAnimationManager class can't cope with this. It manages to change player to "tap to place" video, but is stuck on AlphaWhite therefore user can't see instruction.

How can I fix it so user instantly see "Tap to place object" instruction if phone already loaded planes on scene swap?

IOS - Guidance UI Graphic Raycaster interferes with Worldspace Canvas UI Buttons in a scene

So I made a demo project a short while ago using the demos repo here, I liked the guidance UI. We were spawning a prefab with worldspace UI Canvas + buttons on it from an image marker.

On Android 10 devices the buttons work fine, but on IOS 13+ devices, the buttons are intermittently interactable due to the screen space canvas having a graphic raycaster on it

I have created a reproduction project in 2020.2.0b10 and reported the bug in the bug case below so you can see for yourself but it was easy to recreate by using the UI guidance sample and adding a spawned gameobject in the scene with worldspace canvas ui + buttons to try to press.

(Case 1291989) [UI][AR Foundation] Worldspace UI buttons work fine on Android but intermittently on IOS while in AR

The fix was to remove/disable the graphic raycaster from the Guidance Canvas, I think this issue may be IOS specific? <

Android

Hello and happy new year .

I want to use AR Foundation Demo — Onboarding UX simple AR on an app that i have built on android. Is this demo only for IOS?

Thanks in advance.

Shadow shader visble when camera moved outside of object.

After placing an object on a plane the object has a nice shadow and the plane is invisible.

But as soon as the phone (camera) is moved, and the object is no longer visible, the 'shadown plane' becomes gray and semi-transparent.

The blue sphere image shows the plane under invisible with a blurred shadow, whereas the second image shows a white wall and a dark-gray plane (changed to be more visible than the one under the blue sphere).

IMG_6854
IMG_6855

AR Foundation Demos — Onboarding UX

Hello,

i have 2 questions.

1)On ArSession there is a script which called AR Kit Overcoaching Overlay. And on ScreenSpaceUI, on AUX Animation Manager (script) there is Coaching overlay where you place the previous AR Kit Overcoaching Overlay. This is for IOS right ?
So i dont have to use it for Arcore

1
2

2)when im running the app my AR Camera doesnt work because i have black screen and keep saying "wait for tracking to begin"

3

Sorry for my noob questions but im new on AR and unity generally.

Thanks in advance.

Originally posted by @ManChrys in #42 (comment)

Prevent the real object while plane tracking

Hi

how can i prevent the real object while the plane tracking. if i am tracking the plane (Both Vertical and horizontal) then real object like Laptop, Chair ,TV and AC on this object the plane will not draw but it will draw plane around them
i am attaching the the reference video so you can understand what i mean to say.

RPReplay_Final1618568168.2.mov

All materials are missing texture?

From the meshing of plane, to wireframe shader. It looks like the texture is missing and it's all in magenta color.
Is there anything wrong or is there any further step to perform before building the scenes?
Never mind, this is because I didn't assign URP in project setting =)

BlurredShadow performance issues

I'm testing out different plane shadow solutions in my AR game. So far I've been using this solution https://github.com/HippoAR/Unity-Technologies-unity-arkit-plugin/blob/master/Assets/UnityARKitPlugin/Examples/Common/Shaders/MobileARShadow.shader. It's highly efficient, but your Blurred Shadows solution fits my game art style way better.

My game is 30 FPS capped, I'm testing it on Galaxy Tab S6 Lite and Galaxy S10. With MobileARShadow both devices has stable 30 FPS. When I use BlurredShadow Galaxy S10 is still doing great, but S6 Lite drops to 12-15 FPS. Can I adjust some settings to avoid this drop? It's pretty weird that shadow casted by 1 object cuts framerate by half, even on device like S6 Lite.

Fix light estimation

This snipped from LightEstimation.cs doesn't seem right:

#if PLATFORM_ANDROID
            // ARCore needs to apply energy conservation term (1 / PI) and be placed in gamma
            m_Light.color = mainLightColor.Value / Mathf.PI;
            m_Light.color = m_Light.color.gamma;
  1. The energy conservation term is already applied in native code.
  2. m_Light.color = m_Light.color.gamma; will overwrite the previous line. Is this intended?

Occlusion is not working properly

Hi everyone,

I used Occlusion shader from ARfoundation samples and added occlusion material to ARPlane prefab additionally to default PlaneMat.
It is working fine when detecting surfaces the high surface hides the lower one but when I place an object, the high surface does not hide the object.

Problems with Gradle version and ARF/ARCore/ARkit

Hello!!!!

The Project comes with the AR Foundation/ AR Subsystems/ ARCore/ and ARKit Ver 4.1.0 preview 10 and I having buildings errors that pointed to gradle version (every time fails in the "Bulding Gradle project" part).

GradleError

I'm using Unity 2019.4.15 and Gradle version 5.6.4 (under "Preferences - External Tools - Gradle). In other AR projects I make things work with ARF ver3.1.3, ARS ver3.1.5 ARCore ver3.1.7 but if I change to that versions in this project all kind of error start to popup.

Can anybody please tell me what Gradle versions are using in their AR projects, at least in this one and what ARF/ARCore version are using too?

Any workarround?

Thanks in advance!!!

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.