Closed KamranUnity123 closed 1 year ago
How to resolve this issue
There's a sample that shows how to do this. See https://github.com/Unity-Technologies/arfoundation-samples#camera
Thank you
On Thu, Jan 26, 2023 at 7:33 PM Tim Mowrer @.***> wrote:
There's a sample that shows how to do this. See https://github.com/Unity-Technologies/arfoundation-samples#camera
— Reply to this email directly, view it on GitHub https://github.com/Unity-Technologies/arfoundation-samples/issues/1051#issuecomment-1405091813, or unsubscribe https://github.com/notifications/unsubscribe-auth/AX36562VKRM2ZRYRMG3ZBPDWUKDK3ANCNFSM6AAAAAAUE6UYU4 . You are receiving this because you authored the thread.Message ID: @.*** com>
--
Muhammad KamranUnity Game Developer
@.** | (m) +92 3095586608 | (S) muhammad .kamran.BiM bigimmersive.com http://www.bigimmersive.com/ |163 CCA | DHA Phase-6 | Lahore, Pakistan*
Connect with me on LinkedIn https://www.linkedin.com/in/muhammad-kamran-bb5539198/ | Follow Big Immersive https://www.linkedin.com/company/big-immersive/ The information in or attached to this email is confidential and may be legally privileged. If you are not the intended recipient of this message any use, disclosure, copying, distribution or any action taken in reliance on it is prohibited and may be unlawful. All the information sent and received by the originator and recipient is official correspondence and legally sustainable. If you have received this message in error, please notify the sender immediately by return email and delete this message and any copies from your computer and network. Big immersive does not warrant that this email and any attachments are free from viruses and accepts no liability for any loss resulting from infected email transmissions.
@tdmowrer how to change resolution ? width and height not change in android
What does the sample do for you? Does it list resolutions other than 640x480?
No Always Resolution is 640x480 Not other than resolution in list
Different phones have different capabilities; maybe the one you are using only supports a single resolution. What is it?
It's probably worth logging a bug at this point since the initial question was a how-to, and now you know how to, but it isn't working as expected.
Basically, I am recording video through AR camera. Everything working fine, but Resolution always 640*480 in every android device.
I am testing below mention android devices
Samsung s10
Oppo f21 pro 5g
Samsung s9
Xomi s10 pro
I suggest logging a bug then.
StartRecording
public void StartRecording() { if (m_Session.subsystem is ARCoreSessionSubsystem subsystem) { //m_Mp4Path = Path.Combine(Application.persistentDataPath, "arcore-session"+aRRecorderPlayBackHolder.videosList.Count+".mp4"); var session = subsystem.session; if (session == null) return;
var playbackStatus = subsystem.playbackStatus;
var recordingStatus = subsystem.recordingStatus;
if (!playbackStatus.Playing() &&
!recordingStatus.Recording())
{
if (playbackStatus != ArPlaybackStatus.Finished)
{
using (var config = new ArRecordingConfig(session))
{
config.SetMp4DatasetFilePath(session, m_Mp4Path);
config.SetRecordingRotation(session, GetRotation());
var status = subsystem.StartRecording(config);
Log($"StartRecording to {config.GetMp4DatasetFilePath(session)} => {status}");
//customCofigNativeArray.CustomNativeConfig();
}
}
}
}
}
StopRecording
public void StopRecording() { if (m_Session.subsystem is ARCoreSessionSubsystem subsystem) { var session = subsystem.session; if (session == null) return;
var playbackStatus = subsystem.playbackStatus;
var recordingStatus = subsystem.recordingStatus;
if (recordingStatus.Recording())
{
var status = subsystem.StopRecording();
Debug.Log($"StopRecording() => {status}");
if (status == ArStatus.Success)
{
Debug.Log(File.Exists(m_Mp4Path)
? $"ARCore session saved to {m_Mp4Path} ({GetFileSize(m_Mp4Path)})"
: "Recording completed, but no file was produced.");
}
}
}
}
I am use this code to Record AR Camera Start Recording and Stop Recording working fine but resolution always 640*480 in all android devices how to set this resolution according to device Thank You
Saved Video Resolution is 640*480
@tdmowrer answer please?
Have you logged a bug? I don't work at Unity and just try to be helpful where I can. This sounds like unexpected behavior that requires a repro case and investigation by Unity.
Thank You
Closing this issue due to inactivity. Feel free to re-open it if you still have questions. If you do so, please include your bug number.
How to change camera resolution? I am working in AR Camera recording on android. everything working fine but resolution always 640*480.