[vlc-commits] vlc_bits: add bo_set_64_be
Francois Cartegnie
git at videolan.org
Thu Mar 19 18:37:21 CET 2015
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Thu Mar 19 15:07:26 2015 +0100| [7b91295fcdd16b327e7998bfaea7fb8d1cb43c5b] | committer: Francois Cartegnie
vlc_bits: add bo_set_64_be
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7b91295fcdd16b327e7998bfaea7fb8d1cb43c5b
---
include/vlc_bits.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/include/vlc_bits.h b/include/vlc_bits.h
index 3756e99..1eba5e9 100644
--- a/include/vlc_bits.h
+++ b/include/vlc_bits.h
@@ -304,6 +304,12 @@ static inline void bo_swap_32be (bo_t *p_bo, int i_pos, uint32_t i)
p_bo->b->p_buffer[i_pos + 3] = (i )&0xff;
}
+static inline void bo_set_64be(bo_t *p_bo, int i_offset, uint64_t i)
+{
+ bo_set_32be(p_bo, i_offset, ((i >> 32) &0xffffffff));
+ bo_set_32be(p_bo, i_offset + 4, i &0xffffffff);
+}
+
static inline void bo_add_64be(bo_t *p_bo, uint64_t i)
{
bo_add_32be(p_bo, ((i >> 32) &0xffffffff));
More information about the vlc-commits
mailing list