[x265] [PATCH 2 of 9] api: remove hungarian prefixes from x265_nal members
Steve Borho
steve at borho.org
Tue Nov 19 08:41:13 CET 2013
# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1384824953 21600
# Mon Nov 18 19:35:53 2013 -0600
# Node ID 08130599663661b31deeb7bf6771c55c1d7a3027
# Parent 85f3089367c11655b4e23c8a2dc6232a6d4934ed
api: remove hungarian prefixes from x265_nal members
These particular prefixes came from x264 originally
diff -r 85f3089367c1 -r 081305996636 source/encoder/encoder.cpp
--- a/source/encoder/encoder.cpp Mon Nov 18 19:31:35 2013 -0600
+++ b/source/encoder/encoder.cpp Mon Nov 18 19:35:53 2013 -0600
@@ -1375,15 +1375,15 @@
size += nalSize;
memsize += nalSize;
- m_nals[nalcount].i_type = nalu.m_nalUnitType;
- m_nals[nalcount].i_payload = size;
+ m_nals[nalcount].type = nalu.m_nalUnitType;
+ m_nals[nalcount].sizeBytes = size;
}
/* Setup payload pointers, now that we're done adding content to m_packetData */
for (int i = 0; i < nalcount; i++)
{
- m_nals[i].p_payload = (uint8_t*)m_packetData + offset;
- offset += m_nals[i].i_payload;
+ m_nals[i].payload = (uint8_t*)m_packetData + offset;
+ offset += m_nals[i].sizeBytes;
}
fail:
diff -r 85f3089367c1 -r 081305996636 source/x265.cpp
--- a/source/x265.cpp Mon Nov 18 19:31:35 2013 -0600
+++ b/source/x265.cpp Mon Nov 18 19:35:53 2013 -0600
@@ -205,8 +205,8 @@
PPAScopeEvent(bitstream_write);
for (uint32_t i = 0; i < nalcount; i++)
{
- bitstreamFile.write((const char*)nal->p_payload, nal->i_payload);
- totalbytes += nal->i_payload;
+ bitstreamFile.write((const char*)nal->payload, nal->sizeBytes);
+ totalbytes += nal->sizeBytes;
nal++;
}
}
diff -r 85f3089367c1 -r 081305996636 source/x265.h
--- a/source/x265.h Mon Nov 18 19:31:35 2013 -0600
+++ b/source/x265.h Mon Nov 18 19:35:53 2013 -0600
@@ -72,9 +72,9 @@
* before calling x265_encoder_encode again. */
typedef struct x265_nal
{
- uint32_t i_type; /* NalUnitType */
- uint32_t i_payload; /* size in bytes */
- uint8_t* p_payload;
+ uint32_t type; /* NalUnitType */
+ uint32_t sizeBytes; /* size in bytes */
+ uint8_t* payload;
} x265_nal;
typedef struct x265_picture
More information about the x265-devel
mailing list