Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

360 Video Starting Orientation #45

Open
tylerrcady opened this issue Jun 12, 2024 · 2 comments
Open

360 Video Starting Orientation #45

tylerrcady opened this issue Jun 12, 2024 · 2 comments

Comments

@tylerrcady
Copy link

Hello! I am not sure the best way to contact the developers, so please let me know if I should go through different channels.

With the vr_player, the initial orientation/yaw is not facing where my team and I want it to, and we wonder if it is possible with vr_player to change the starting orientation, say left x-degrees. We are trying to see what packages work best for us, and would love any input.

Thank you!

@tylerrcady tylerrcady changed the title Video Orientation 360 Video Starting Orientation Jun 12, 2024
@mark1684
Copy link

mark1684 commented Aug 6, 2024

when we implement according to you - if auto rotation is on then preview is rotate but if auto rotation locked in ios then video move also chnage height width but video view is showing like -- assume a man stand in video if its portrait mode view is okay , if i change to landscape and auto rotation on man showing right way means head on top , if auto rotation lock then men head is left side .... means video angel changed height width change video also look in landscape but view is not moving .... im share my code for portrait to landscape in ios ===>

Future fullScreenPressedIos() async {

if (_viewPlayerController != null) {
  // await _viewPlayerController.fullScreen(
  //
  // );
}

setState(() {
  _isFullScreen = !_isFullScreen;
});

if (_isFullScreen) {
  SystemChrome.setPreferredOrientations([
    DeviceOrientation.landscapeRight,
    DeviceOrientation.landscapeLeft,
  ]);
  // setState(() {
  //   _rotation =  pi ; // rotate 90 degrees
  // });
  SystemChrome.setEnabledSystemUIMode(
    SystemUiMode.manual,
    // overlays: SystemUiOverlay.bottom,
    overlays: SystemUiOverlay.values,
  );
} else {
  SystemChrome.setPreferredOrientations([
    DeviceOrientation.landscapeRight,
    DeviceOrientation.landscapeLeft,
    DeviceOrientation.portraitUp,
    DeviceOrientation.portraitDown,
  ]);
  SystemChrome.setEnabledSystemUIMode(
    SystemUiMode.manual,
    overlays: SystemUiOverlay.values,
  );
}

}

@mark1684
Copy link

mark1684 commented Aug 6, 2024

its working in android perfectly ... but in ios not wokring when auto rotation is locked

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants