- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
Being a junior programmer, I have to dig into this most complicated codec...
2 programming questions at this point:
1. what does this mean:
#define H264ENC_UNREFERENCED_PARAMETER(X) X
2. Why every time I run the code, for function calls it automatically goes into PIXBITS==8, rather than 16, is it because the following header is onlycalled once?then how can I step into the 16 case?
#define PIXBITS 8
#include "umc_base_bitstream_tmpl.h"
#undef PIXBITS
#if defined (BITDEPTH_9_12)
#define PIXBITS 16
#include "umc_base_bitstream_tmpl.h"
#undef PIXBITS
#endif // BITDEPTH_9_12
Thanks for any help and hint!
Best
R
Being a junior programmer, I have to dig into this most complicated codec...
2 programming questions at this point:
1. what does this mean:
#define H264ENC_UNREFERENCED_PARAMETER(X) X
2. Why every time I run the code, for function calls it automatically goes into PIXBITS==8, rather than 16, is it because the following header is onlycalled once?then how can I step into the 16 case?
#define PIXBITS 8
#include "umc_base_bitstream_tmpl.h"
#undef PIXBITS
#if defined (BITDEPTH_9_12)
#define PIXBITS 16
#include "umc_base_bitstream_tmpl.h"
#undef PIXBITS
#endif // BITDEPTH_9_12
Thanks for any help and hint!
Best
R
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I have the same problem like you. I want to review the h.264 code but its very complicated.
I tried to use Doxygen to generate some helpful HTML meta-data, but unfortunately, the IPP comments dont follow the Doxygen recommendation. Please, my question is what steps youre following to understand the code?
Thanks.
I have the same problem like you. I want to review the h.264 code but its very complicated.
I tried to use Doxygen to generate some helpful HTML meta-data, but unfortunately, the IPP comments dont follow the Doxygen recommendation. Please, my question is what steps youre following to understand the code?
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
1. This only serves to remove a common compiler warning such as "parameter foo is not referenced".
An exemple would be void function(int foo) { }, which could also be fixed by void function(int /*foo*/) { }
2. The H.264 encoder is implemented using C++ templates. The algorithms are implemented on a type, T, which is defined later. T could be 'unsigned char' or 'unsigned short', in the same way that you have std::vector or std::vector. Instead of implementing both function(char) and function(short), you implement template function(T), and then the proper version is called depending on the argument. For the H.264 encoder, this allows support for 8-bit images and 16-bit images without copy-pasting common code. With templates, code is lazilly compiled only if it's used, so you won't end up with function(int) if you don't need a 32-bit version. umc_base_bitstream_tmpl.h is included twice to tell it to force compilaton of both 8-bit and 16-bit versions (template instantiation).
An exemple would be void function(int foo) { }, which could also be fixed by void function(int /*foo*/) { }
2. The H.264 encoder is implemented using C++ templates. The algorithms are implemented on a type, T, which is defined later. T could be 'unsigned char' or 'unsigned short', in the same way that you have std::vector
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page