[vlc-devel] [PATCH] vout: snapshot: fix snapshots cropping
Rémi Denis-Courmont
remi at remlab.net
Fri Nov 3 16:04:57 CET 2017
Le 3 novembre 2017 13:09:35 GMT+02:00, Romain Vimont <rom at rom1v.com> a écrit :
>Le vendredi 3 novembre 2017 à 12:52 +0200, Rémi Denis-Courmont a écrit
>:
>> I don't know why picture copy does not copy the offsets (not to say
>> that there is no reason).
>
>Even if it did, in vout_snapshot_Set(), the picture has no offsets,
>they
>are provided in a separate video_format_t parameter.
>
>> But clone implies shallow copy.
>
>I am not sure that "clone" implies shallow copy. IMO, it depends.
>
>For instance, in C++, a "clone()" method usually calls the *copy*
>constructor (it is just provided for polymorphism), which may deep- or
>shallow-copy.
>
>In Rust, the Clone trait is typically used to deep-copy an object.
>
>I think that *clone* suggests that the copy is returned (contrary to
>*copy*).
>
>What name do you suggest instead?
>
>> --
>> Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez
>excuser ma brièveté.
>> _______________________________________________
>> vlc-devel mailing list
>> To unsubscribe or modify your subscription options:
>> https://mailman.videolan.org/listinfo/vlc-devel
>_______________________________________________
>vlc-devel mailing list
>To unsubscribe or modify your subscription options:
>https://mailman.videolan.org/listinfo/vlc-devel
Sure but in C, and especially in VLC, we use clone for shallow copy, as opposed to, well, copy for deep copy.
--
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.
More information about the vlc-devel
mailing list