Fixing camera recordings.

parent e9f24acb
......@@ -132,7 +132,6 @@ GameObject:
- component: {fileID: 1309245142}
- component: {fileID: 1309245141}
- component: {fileID: 1309245143}
- component: {fileID: 1309245144}
m_Layer: 0
m_Name: DLU
m_TagString: Untagged
......@@ -153,7 +152,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
contextScene: Kitchen
captureVideo: 0
captureVideo: 1
timeoutAfterSeconds: 40
--- !u!4 &1309245142
Transform:
......@@ -183,17 +182,3 @@ MonoBehaviour:
m_EditorClassIdentifier:
address: tcp://127.0.0.1:5559
sceneController: {fileID: 0}
--- !u!114 &1309245144
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1309245140}
m_Enabled: 0
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0bf19aac958d45fba9fe660e211e56a, type: 3}
m_Name:
m_EditorClassIdentifier:
cameraCapture: {fileID: 0}
useScreenSize: 0
......@@ -11020,6 +11020,7 @@ GameObject:
- component: {fileID: 1929291042}
- component: {fileID: 1929291044}
- component: {fileID: 1929291043}
- component: {fileID: 1929291045}
m_Layer: 0
m_Name: Main Camera
m_TagString: MainCamera
......@@ -11093,6 +11094,20 @@ Camera:
m_OcclusionCulling: 1
m_StereoConvergence: 10
m_StereoSeparation: 0.022
--- !u!114 &1929291045
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1929291041}
m_Enabled: 0
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0bf19aac958d45fba9fe660e211e56a, type: 3}
m_Name:
m_EditorClassIdentifier:
cameraCapture: {fileID: 0}
useScreenSize: 0
--- !u!1 &1929678088
GameObject:
m_ObjectHideFlags: 0
......
......@@ -16631,6 +16631,7 @@ GameObject:
- component: {fileID: 963194228}
- component: {fileID: 963194227}
- component: {fileID: 963194226}
- component: {fileID: 963194229}
m_Layer: 0
m_Name: Main Camera
m_TagString: MainCamera
......@@ -16704,6 +16705,20 @@ Transform:
m_Father: {fileID: 44631460}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 26.049002, y: 32.257, z: 0}
--- !u!114 &963194229
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 963194225}
m_Enabled: 0
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0bf19aac958d45fba9fe660e211e56a, type: 3}
m_Name:
m_EditorClassIdentifier:
cameraCapture: {fileID: 0}
useScreenSize: 0
--- !u!1001 &964251520
PrefabInstance:
m_ObjectHideFlags: 0
......@@ -18,7 +18,7 @@ public class FFmpegCapture : MonoBehaviour
{
if (cameraCapture == null)
{
cameraCapture = Camera.main.gameObject.GetComponent<CameraCapture>();
cameraCapture = Camera.main.GetComponentInChildren<CameraCapture>();
}
if (useScreenSize)
{
......
......@@ -9,7 +9,6 @@ using System.Collections.Generic;
namespace dlu
{
[RequireComponent(typeof(FFmpegCapture))]
public class SceneController : MonoBehaviour
{
private JSONArray instruction;
......@@ -36,7 +35,7 @@ public class SceneController : MonoBehaviour
}
if (videoCapture == null)
{
videoCapture = GetComponent<FFmpegCapture>();
videoCapture = Camera.main.GetComponent<FFmpegCapture>();
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment