Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • LibVLCSharp LibVLCSharp
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 79
    • Issues 79
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • VideoLANVideoLAN
  • LibVLCSharpLibVLCSharp
  • Issues
  • #480
Closed
Open
Issue created Jun 28, 2021 by bbhxwl@bbhxwl

Can't xamarin.forms uwp and net core play video?

https://code.videolan.org/videolan/LibVLCSharp/-/blob/3.x/samples/LibVLCSharp.GTK.Sample/Program.cs Can't net core use GTK # + VLC to play video? net core no have VideoView Net core GTK # can't play video on raspberry pie.

Can't xamarin.forms uwp play the video? https://github.com/ZeBobo5/Vlc.DotNet/issues/694

app.cs

public App() { LibVLCSharpFormsRenderer.Init(); LibVLCSharp.Shared.Core.Initialize(); this.InitializeComponent(); this.Suspending += OnSuspending; }

MainPage.cs

using LibVLCSharp.Forms.Shared; using LibVLCSharp.Shared; using System; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Text; using System.Threading.Tasks; using Xamarin.Forms;

namespace App3 { public partial class MainPage : ContentPage { LibVLC LibVLC; MediaPlayer MediaPlayer; public MainPage() {

        InitializeComponent();
        this.Appearing += MainPage_Appearing;
       


    }


    private void MainPage_Appearing(object sender, EventArgs e)
    {
        LibVLC = new LibVLC(enableDebugLogs: true);

        var media = new Media(LibVLC, new Uri("https://bj.bcebos.com/kpy-organizations/U4460574/videos/2021052812045239653257462221.mp4"));

        MediaPlayer = new MediaPlayer(media) { EnableHardwareDecoding = true };
        MediaPlayer.Play();


         vlc.MediaPlayer = MediaPlayer;
        bool b = MediaPlayer.Play();
    }
}

}

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking

VideoLAN code repository instance