Slightly More Advanced Maui.Graphics!

Поділитися
Вставка
  • Опубліковано 18 гру 2024

КОМЕНТАРІ •

  • @ProgrammingWithChris
    @ProgrammingWithChris  2 роки тому +3

    Thanks for watching! I recently started an email "Newsletter" that I'm going to send weekly, describing what types of things I'm studying and resources I found useful for programming and machine learning. If that sounds useful to you, here ya go! - programmingwithchris.substack.com/
    🕘Timestamps:
    00:00 - Video Start
    00:32 - Demoing the Meter Drawables
    02:01 - Showing How it Works in the XAML and Code Behind in .NET Maui
    06:37 - The Linear Meter Drawable
    12:59 - The Radial Gauge Drawable

  • @bomite
    @bomite 2 роки тому +3

    Great job MAUI.
    High performance!

  • @thecacademy5376
    @thecacademy5376 2 роки тому +3

    Looks great! Can’t wait to tinker with this. Definitely subscribed. 😀

  • @kumar--vasan
    @kumar--vasan Рік тому

    Thanks for sharing quality work like this. Much appreciated.

  • @TonyHenrique
    @TonyHenrique 2 роки тому +2

    Very cool!

  • @harag9
    @harag9 2 роки тому +1

    Great video thanks for sharing. Math is always the hardest part of development, I always struggle with that too. As for the 2 circles for the round dial you could have used canvas.DrawArc() - then you wouldn't need to clip that triangle area.

    • @ProgrammingWithChris
      @ProgrammingWithChris  2 роки тому

      Oh wow, yeah, that’s a good point. Would certainly make some parts of it easier to deal with, that’s for sure.

  • @LinaAbdalla-z8p
    @LinaAbdalla-z8p Рік тому

    Hi Chris, thanks for the great video. I am wondering if there's a way to change the GraphicsView Background color? I can't seem to get it to change.

  • @jeffm3865
    @jeffm3865 2 роки тому +1

    Great video. What would it take to take this example a step further and make a standalone reusable component. Seems like this was not included but might be an idea for another video.

    • @ProgrammingWithChris
      @ProgrammingWithChris  2 роки тому

      Yup! I've been thinking about the best way to do that lately, and am a little closer on some drawn controls I've made for my "ShoppingList" app. So I'll show that off in the next vid. And if I get enough of these together, i'd probably throw it in a class library or something, for reuse.

    • @jeffm3865
      @jeffm3865 2 роки тому +1

      @@ProgrammingWithChris Is there an equivalent to WPF user controls in Maui? I think James M partially goes over some of this in: ua-cam.com/video/TkadU_OfmIE/v-deo.html . Your example uses graphics, so it’s different. I haven’t seen any Maui videos on making a graphical custom user control and then reusing that in another project. Just an idea. Thanks

    • @ProgrammingWithChris
      @ProgrammingWithChris  2 роки тому

      Ah, yeah, that’s definitely one way you can do that, if you’re using existing controls. The path I’ve been going down is to create a class that inherits from, say, GraphicsView, and the you can creat custom properties and change the behavior any way you can, and then to use the new control you just use it’s name in the XAML. Fairly clean, so far, though I’ve run into a few tricky things with it. Will talk through it in the next vid.

  • @imrulz1
    @imrulz1 Рік тому

    great video thank you keep up the examples!

  • @crxmaniac
    @crxmaniac 2 роки тому +1

    Great video! Is it possible to draw 2D charts with updating graphs?

    • @ProgrammingWithChris
      @ProgrammingWithChris  2 роки тому +1

      Sure, yeah, you can do that, though I suspect there are some libraries out there that would be easier to use than drawing your own. But yeah, definitely!

  • @nicobecke7395
    @nicobecke7395 2 роки тому

    Hi, pretty nice demo...
    Have you tried to apply the IDrawable objects to an MVVM pattern - in the sense of changing values via properties?
    I'm kinda struggling creating bindable properties AND invalidating the view with updated properties. I can invalidate things via the code behind; but then the whole MVVM approach is kinda... well...

    • @tanakamawere
      @tanakamawere 2 роки тому

      Can't you use EventToCommand Behaviour?

    • @anandshindey
      @anandshindey Рік тому

      I have the same problem, don't know how to make it work with MVVM

  • @Chagpt4
    @Chagpt4 Рік тому

    Hi Chris, could you do this for the line chart with single and multple lines, thank you.

  • @HermanWillems
    @HermanWillems Рік тому

    Why didn't you use a Conic Gradient for the Meter? Why a linear Gradient?

  • @pavelkravchenko2810
    @pavelkravchenko2810 2 роки тому

    Hi! Are you manged to solve your problem with blendmode? I can't(((

  • @RiversJ
    @RiversJ Рік тому

    The reason you couldn't get blending to work is that it's only implemented on iOS/OSX, which is kind of ridiculous but that's what it is.

  • @turgaysenlet
    @turgaysenlet 2 роки тому +1

    The example project does not work on Windows. It crashes with exception "After calling CanvasDrawingSession.CreateLayer, you must close the resulting CanvasActiveLayer before ending the CanvasDrawingSession." which is caused by the canvas.ClipPath(path); statement. This part is the key part of the drawing, so it seems that this is method is out of question to build a pie chart or any other pie drawings.

    • @ProgrammingWithChris
      @ProgrammingWithChris  2 роки тому +1

      That's right, the issue there is that ClipPath hasn't been implemented yet on Windows, which is unfortunate. My suggestion there would be something that another commenter suggested which was to use DrawArc and/or FillArc, etc, instead of doing a circle and clipping out the part we don't want to view. That changes the code quite a bit, but it would at least work on Windows.

    • @turgaysenlet
      @turgaysenlet 2 роки тому +3

      @@ProgrammingWithChris Thank you Chris. I was just looking at FillArc and it unfortunately fills the whole convex area under inside the arc, so not a good look for a pie chart when you go beyond 180 degrees. DrawArc with a thick stroke looks like a good compromise for now, it can implement a stylish pie chart :) Thanks again for the amazing videos and for the quick responses!

  • @DeimosesImpact
    @DeimosesImpact 8 місяців тому

    FYI blendmode is not supported except on iOS, and its pretty low priority for them so expect it to be a while before that works, so dont use it

  • @JohannesJacobusHough-n4j
    @JohannesJacobusHough-n4j 7 місяців тому

    I search Advanced MAUI, finding this!