Take Pictures in Your App with CameraView for .NET MAUI

Ғылым және технология

CameraView is back! Freshly ported from Xamarin, we have an all new CameraView available for you for .NET MAUI. I made a quick follow-up video too with preventing memory leaks and selecting other cameras: • Select Different Camer...
With this first version of CameraView you can control zoom, flash, resolutions, which camera to use and actually take pictures! In this video I will show you how to get started yourself.
💝 Join this channel to get access to perks:
kzread.info/dron/ral.html...
Disclaimer: this channel is done on personal title, in my free time, and not officially affiliated with or endorsed by Microsoft (my employer) in any way. Opinions and views are my own.
🛑 Don't forget to subscribe to my channel for more cool content: kzread.info...
🐦 Follow me on Twitter: / jfversluis
🤝 Join the Discord server: / discord
🔗 Links
Sample Code Repo: github.com/jfversluis/MauiCam...
CameraView Documentation: learn.microsoft.com/dotnet/co...
⏱ Timestamps
00:00 - CameraView for .NET MAUI
00:13 - Amazing Community Contribution!
01:20 - Add CommunityToolkit.Maui.Camera Package
03:41 - Add Camera Permissions
05:14 - Implement CameraView in XAML
08:00 - Implement Image Capture
13:02 - CameraView Live Demo Android
14:15 - Change SelectedCamera
15:21 - Implement Zoom and Flash
17:54 - Learn More About Switching Cameras?
🎥 Video edited with DaVinci Resolve
🙋‍♂️ Also find my...
Blog: blog.verslu.is
All the rest: jfversluis.dev
#maui #cameraview #android #ios #dotnet #dotnetmaui #communitytoolkit

Пікірлер: 47

  • @jfversluis
    @jfversluis8 күн бұрын

    A made a quick follow-up video too with preventing memory leaks and selecting other cameras: kzread.info/dash/bejne/fImYyKNwnqnKh9o.html

  • @KenRossPhotography
    @KenRossPhotography8 күн бұрын

    It would be a fun project/video to "Create a Pro Camera in MAUI" that leverages all the features for flash, camera selection, zoom, etc. Having a zoom slider on screen, toggle flash on/off, exposure control [if it has that], etc. 😀

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Voila! github.com/CommunityToolkit/Maui/tree/main/samples/CommunityToolkit.Maui.Sample/Pages/Views/CameraView

  • @alelasgrutas
    @alelasgrutas5 күн бұрын

    amazed by this video, thank you very much, keep it up

  • @adinwashere
    @adinwashere8 күн бұрын

    looks great. To use this in a Maui Hybrid Blazor app we would need to use a XAML page or pop I guess?

  • @jfversluis

    @jfversluis

    8 күн бұрын

    That is correct! You can take some inspiration from here: kzread.info/dash/bejne/ZJigztxtfr2pYKw.html

  • @adinwashere

    @adinwashere

    8 күн бұрын

    @@jfversluis Excellent

  • @kamilyt6541
    @kamilyt65418 күн бұрын

    Yeah that's great I have also added this cameraview in my hybrid desktop app It is a xaml popup and I'm open that popup from the razor page So basically I have added that view in hybrid with xaml.. And can this work with DSLR? If I attach a DSLR to my desktop like flash and zoom i haven't try that so....

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Great! Oof I don't know about the DSLR! That would be very interesting... Please let me know if you decide to try!

  • @kamilyt6541

    @kamilyt6541

    7 күн бұрын

    @@jfversluis yes I have already did that but haven't try with the flash and zoom in the desktop app So okay I'll try to do in the DSLR 👍

  • @neosphoros5502
    @neosphoros55028 күн бұрын

    Hello! Very nice video. Is it possible to place half transparent picture (PNG) as the overlay layer on the camera preview?

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Thank you! I would think so, just make sure the elements overlap by putting them both in the same column and row in a grid for example

  • @ericritter46
    @ericritter468 күн бұрын

    i love it. keep it up! I like that implementation is super easy and we dont need a mulititude of xmlns setup.

  • @DeepWorksStudios
    @DeepWorksStudios8 күн бұрын

    Great Update ^^

  • @razgon
    @razgon8 күн бұрын

    Nice, thank you!🙂

  • @deaasaleh3613
    @deaasaleh36138 күн бұрын

    Great job 👏

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Thank you! 😃

  • @dustineatchel9442
    @dustineatchel94428 күн бұрын

    Excellent work! Excited to give this a try. What about recording a video instead of capturing photos? Is that something that is planned for the future? Would be amazing to be able to select the frame rate / resolution when capturing video as well. 👍

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Something we absolutely want to do! We started with the core functionality but video is definitely one of the next things I think we'll do. Thanks!

  • @MartinMcDermot
    @MartinMcDermot8 күн бұрын

    Nice thx

  • @jfversluis

    @jfversluis

    8 күн бұрын

    You’re very welcome! Thank you for your support!

  • @hrishikeshgarud7177
    @hrishikeshgarud71775 күн бұрын

    Can we get the raw camera feed?

  • @jfversluis

    @jfversluis

    5 күн бұрын

    Not at the moment, something we want to do in the future

  • @LuisDulanto-gl6dm
    @LuisDulanto-gl6dm6 күн бұрын

    I'm displaying the new Camera in a popup but if I close it and reopen, the camera is not displayed. How can I fix that?

  • @jfversluis

    @jfversluis

    6 күн бұрын

    Sounds like you need to dispose of it properly and reinitialize

  • @paladinepaladine
    @paladinepaladineКүн бұрын

    System.Reflection.TargetInvocationException: 'Exception has been thrown by the target of an invocation.' I'm getting this error everytime I take a photo. I've got to have missed something, but I can't see it (probably the wood for the trees). Can anyone help?

  • @jfversluis

    @jfversluis

    Күн бұрын

    Try wrapping it in a dispatcher.dispatch call

  • @paladinepaladine

    @paladinepaladine

    Күн бұрын

    @@jfversluis I was trying to make the cameraview invisible, make an imageview visible and pass the e.media across inside a single dispatcher.dispatch when it needed one for each. Should have realised that as it was the moment it didn't have one that the code failed. Many thanks for your help and the excellent videos you keep producing.

  • @MrSuxor
    @MrSuxor8 күн бұрын

    I swear when you come out with that cancelation token video in the cancelation token video you're going to ask if we want a cancelation token video to comment below!

  • @jfversluis

    @jfversluis

    8 күн бұрын

    😂😂😂 cancellationtoken-ception

  • @cocacola7535
    @cocacola75358 күн бұрын

    Please kindly make a video about continuous object tracking with the camera view.

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Not possible right now!

  • @cocacola7535

    @cocacola7535

    8 күн бұрын

    @@jfversluis I see. Thank you.

  • @DM-98
    @DM-988 күн бұрын

    Could you change the methods to have suffix Async when they're async?

  • @jfversluis

    @jfversluis

    8 күн бұрын

    Personally I don't like that. You can tell from the return type, it feels very on the nose to add Async to everything. So not likely!

  • @bity-bite

    @bity-bite

    8 күн бұрын

    Better to be consistent with the BCL maybe? ​@jfversluis

  • @jfversluis

    @jfversluis

    8 күн бұрын

    @@bity-bite be my guest!

  • @bity-bite

    @bity-bite

    8 күн бұрын

    @@jfversluis Thanks! I'll try to make a PR as soon as I get my PC fixed 😃

  • @jfversluis

    @jfversluis

    8 күн бұрын

    @bity-bite ha sorry. That was not what I meant. I’m not planning on changing this for this library or any of my libraries. Be my guest with applying it to your own code 😄

  • @tanakamawere
    @tanakamawere8 күн бұрын

    Gerald, I think you underestimate the number of beginner devs who watch you videos 13:33 . Your "sample code" IS the code.😂😂 whatever bad practices you do, I will do the same because I don't know any better

  • @jfversluis

    @jfversluis

    8 күн бұрын

    I know! I maybe should do better in that regard but then it also comes down to how people like to solve things and taste or what people perceive as being better... But you make a good point! I don't mean to talk down on your code. I will be more mindful of that, thank you!

  • @SuperGulamali
    @SuperGulamali8 күн бұрын

    Waiting for a year for the cancellation token video 😂

  • @jfversluis

    @jfversluis

    8 күн бұрын

    😭😭😭😭

Келесі