Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Question WebGL ASP.net core Positioning

Discussion in 'Web' started by twocool, Mar 29, 2024.

  1. twocool

    twocool

    Joined:
    Jan 16, 2014
    Posts:
    17
    upload_2024-3-28_22-20-34.png

    I'm trying to set the canvas to center and be fully displayed. The canvas is set at 720x1280. As you can see, the game is cut off to a portion.

    .cshtml script:

    Code (CSharp):
    1. <main id="main">
    2.     <section id="contact" class="contact">
    3.         <div class="container">
    4.             <div class="row" data-aos="fade-in">
    5.                 <div class="col-lg-12 d-flex align-items-stretch">
    6.                     <div class="info">
    7.                         <iframe src="~/UnityWebGL/index.html" frameborder="0" scrolling="no" width="100%" height="100%"></iframe>
    8.                     </div>
    9.                 </div>
    10.             </div>
    11.         </div>
    12.     </section>
    13. </main>
    If anyone has a solution/suggestion, I'm all ears. Thank you!