vlc | branch: master | Francois Cartegnie <[email protected]> | Wed Mar 14 
17:38:20 2018 +0100| [041e9c6338403afdbb7a442b2f8fac190e957157] | committer: 
Francois Cartegnie

demux: heif: apply colr

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=041e9c6338403afdbb7a442b2f8fac190e957157
---

 modules/demux/mp4/heif.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/modules/demux/mp4/heif.c b/modules/demux/mp4/heif.c
index ae8a8e96ad..e7c415e3af 100644
--- a/modules/demux/mp4/heif.c
+++ b/modules/demux/mp4/heif.c
@@ -32,6 +32,7 @@
 
 #include "libmp4.h"
 #include "heif.h"
+#include "color_config.h"
 
 struct heif_private_t
 {
@@ -337,6 +338,15 @@ static int DemuxHEIF( demux_t *p_demux )
                         case 270: fmt.video.orientation = ORIENT_ROTATED_270 ; 
break;
                     }
                     break;
+                case ATOM_colr:
+                    fmt.video.primaries = iso_23001_8_cp_to_vlc_primaries(
+                                            
p_prop->data.p_colr->nclc.i_primary_idx );
+                    fmt.video.transfer = iso_23001_8_tc_to_vlc_xfer(
+                                            
p_prop->data.p_colr->nclc.i_transfer_function_idx );
+                    fmt.video.space = iso_23001_8_mc_to_vlc_coeffs(
+                                        p_prop->data.p_colr->nclc.i_matrix_idx 
);
+                    fmt.video.b_color_range_full = 
p_prop->data.p_colr->nclc.i_full_range;
+                    break;
             }
         }
     }

_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to