kakone / GoogleCast

Implementation of the Google Cast protocol (.NET Standard 2.0 library)
GNU General Public License v3.0
141 stars 22 forks source link

Thoughts? #1

Closed hansmbakker closed 6 years ago

hansmbakker commented 6 years ago

Hi, I found your library after you commented on an issue in the SharpCaster repo.

The code looks nice and clean!

Without wanting to judge (you're free to start a new library, and it also gives opportunities to learn from each other), I was curious on why you decided to start from scratch.

I'm curious because maybe you found shortcomings or things you would like to see different in what we did already - I'm interested in such feedback to see where we can improve; also I'm wondering if you'd like to work together in any way since we seem to have the same goals - it could result in less duplicated work.

This isn't meant to be pushy; if you're happy the way things are then it's also fine.

kakone commented 6 years ago

Hello,

The principal reasons I decided to start from scratch (not really from scratch because I used the best of SharpCast and SharpCaster projects) were (in a random order) :

You are right, the ideal would be to have a single project. Personnally, I do not have a lot of time to devote to this project anymore. But, my code is here, feel free to use it and I can try to help if needed.

Cordially, Stephane.

kakone commented 6 years ago

And when I saw the loop :

while (_controller == null)
{
    await Task.Delay(500);
}

in the example, I thought : "There must be a way to do better." :smile:

hansmbakker commented 6 years ago

Hi, thank you for your reply!

I understant most of your points,

What I like about SharpCaster is that there is a lot of functionality already, with some sample apps, Google's own Protobuf nuget packages and a small community.

Out of curiosity: I saw you're using Zeroconf instead of Rssdp, is there a reason behind that?

kakone commented 6 years ago

Yes, it doesn't work (for the moment) on UWP (my own project that uses GoogleCast NuGet package targets Windows desktop and Xamarin, so that was not a problem for me).

I prefer protobuf-net library compared to Google's Protobuf nuget package. The API of protobuf-net follows typical .NET patterns, you can use attributes, it's very simple to use, like Xml or DataContract serializer.

I'm using Zeroconf because mDNS is the primary way of discovering a Chromecast that supports the v2+ API (SSDP was used in GoogleCast v1 SDK). In SharpCaster, I believe that Tmds.MDns package is now used instead of Rssdp. But, I personnaly prefer the async/await syntax of Zeroconf (and I used it already in another personal project).

In terms of features, what is missing in my library compared to SharpCaster ?

kakone commented 6 years ago

It works now in UWP with Fall Creators Update.

hansmbakker commented 6 years ago

:+1: