diff options
author | David Schleef <ds@schleef.org> | 2014-09-01 18:57:15 -0700 |
---|---|---|
committer | David Schleef <ds@schleef.org> | 2014-09-01 18:57:15 -0700 |
commit | c61055beacf664e072ca763525d110756da98862 (patch) | |
tree | 99b1f7dda941c333844acd51549cb838ded2659c | |
parent | 571f497f7d96da43797f58cfdab82fd37cc98193 (diff) |
info -> stream_id
-rw-r--r-- | plugins/gstrtmp2sink.c | 6 | ||||
-rw-r--r-- | plugins/gstrtmp2src.c | 4 | ||||
-rw-r--r-- | rtmp/rtmpchunk.c | 14 | ||||
-rw-r--r-- | rtmp/rtmpchunk.h | 4 | ||||
-rw-r--r-- | rtmp/rtmpconnection.c | 12 | ||||
-rw-r--r-- | tools/client-test.c | 4 | ||||
-rw-r--r-- | tools/proxy-server.c | 4 |
7 files changed, 24 insertions, 24 deletions
diff --git a/plugins/gstrtmp2sink.c b/plugins/gstrtmp2sink.c index 1c4dd58..b16ec74 100644 --- a/plugins/gstrtmp2sink.c +++ b/plugins/gstrtmp2sink.c @@ -477,7 +477,7 @@ gst_rtmp2_sink_render (GstBaseSink * sink, GstBuffer * buffer) } chunk->message_length = GST_READ_UINT24_BE (data + 1); chunk->timestamp = GST_READ_UINT24_BE (data + 4); - chunk->info = 1; /* FIXME use actual stream id */ + chunk->stream_id = 1; /* FIXME use actual stream id */ if (chunk->message_length != size - 15) { GST_ERROR ("message length was %" G_GSIZE_FORMAT " expected %" @@ -847,10 +847,10 @@ static void dump_chunk (GstRtmpChunk * chunk, gboolean dir) { g_print ("%s chunk_stream_id:%-4d ts:%-8d len:%-6" G_GSIZE_FORMAT - " type_id:%-4d info:%08x\n", dir ? ">>>" : "<<<", + " type_id:%-4d stream_id:%08x\n", dir ? ">>>" : "<<<", chunk->chunk_stream_id, chunk->timestamp, - chunk->message_length, chunk->message_type_id, chunk->info); + chunk->message_length, chunk->message_type_id, chunk->stream_id); if (chunk->message_type_id == 20) { dump_command (chunk); } diff --git a/plugins/gstrtmp2src.c b/plugins/gstrtmp2src.c index a84a247..156a6b4 100644 --- a/plugins/gstrtmp2src.c +++ b/plugins/gstrtmp2src.c @@ -431,10 +431,10 @@ static void dump_chunk (GstRtmpChunk * chunk, gboolean dir) { g_print ("%s chunk_stream_id:%-4d ts:%-8d len:%-6" G_GSIZE_FORMAT - " type_id:%-4d info:%08x\n", dir ? ">>>" : "<<<", + " type_id:%-4d stream_id:%08x\n", dir ? ">>>" : "<<<", chunk->chunk_stream_id, chunk->timestamp, - chunk->message_length, chunk->message_type_id, chunk->info); + chunk->message_length, chunk->message_type_id, chunk->stream_id); if (chunk->message_type_id == 20) { dump_command (chunk); } diff --git a/rtmp/rtmpchunk.c b/rtmp/rtmpchunk.c index 197d66d..1b16271 100644 --- a/rtmp/rtmpchunk.c +++ b/rtmp/rtmpchunk.c @@ -193,14 +193,14 @@ gst_rtmp_chunk_parse_header2 (GstRtmpChunkHeader * header, GBytes * bytes, header->message_type_id = data[offset]; offset += 1; - header->info = (data[offset + 3] << 24) | (data[offset + 2] << 16) | + header->stream_id = (data[offset + 3] << 24) | (data[offset + 2] << 16) | (data[offset + 1] << 8) | data[offset]; offset += 4; } else { header->timestamp = previous_header->timestamp; header->message_length = previous_header->message_length; header->message_type_id = previous_header->message_type_id; - header->info = previous_header->info; + header->stream_id = previous_header->stream_id; if (header->format == 1) { header->timestamp += @@ -262,10 +262,10 @@ gst_rtmp_chunk_serialize (GstRtmpChunk * chunk, data[5] = (chunk->message_length >> 8) & 0xff; data[6] = chunk->message_length & 0xff; data[7] = chunk->message_type_id; - data[8] = chunk->info & 0xff; - data[9] = (chunk->info >> 8) & 0xff; - data[10] = (chunk->info >> 16) & 0xff; - data[11] = (chunk->info >> 24) & 0xff; + data[8] = chunk->stream_id & 0xff; + data[9] = (chunk->stream_id >> 8) & 0xff; + data[10] = (chunk->stream_id >> 16) & 0xff; + data[11] = (chunk->stream_id >> 24) & 0xff; offset = 12; } else { data[1] = (timestamp >> 16) & 0xff; @@ -376,7 +376,7 @@ gst_rtmp_chunk_cache_update (GstRtmpChunkCacheEntry * entry, entry->previous_header.timestamp = chunk->timestamp; entry->previous_header.message_length = chunk->message_length; entry->previous_header.message_type_id = chunk->message_type_id; - entry->previous_header.info = chunk->info; + entry->previous_header.stream_id = chunk->stream_id; } gboolean diff --git a/rtmp/rtmpchunk.h b/rtmp/rtmpchunk.h index 6588f3f..81c9ba5 100644 --- a/rtmp/rtmpchunk.h +++ b/rtmp/rtmpchunk.h @@ -44,7 +44,7 @@ struct _GstRtmpChunkHeader { guint32 timestamp; gsize message_length; int message_type_id; - guint32 info; + guint32 stream_id; }; struct _GstRtmpChunkCacheEntry { @@ -62,7 +62,7 @@ struct _GstRtmpChunk guint32 timestamp; gsize message_length; int message_type_id; - guint32 info; + guint32 stream_id; GBytes *payload; }; diff --git a/rtmp/rtmpconnection.c b/rtmp/rtmpconnection.c index a027552..4a796d6 100644 --- a/rtmp/rtmpconnection.c +++ b/rtmp/rtmpconnection.c @@ -566,7 +566,7 @@ gst_rtmp_connection_chunk_callback (GstRtmpConnection * sc) entry->chunk->timestamp = header.timestamp; entry->chunk->message_length = header.message_length; entry->chunk->message_type_id = header.message_type_id; - entry->chunk->info = header.info; + entry->chunk->stream_id = header.stream_id; entry->payload = g_malloc (header.message_length); } memcpy (&entry->previous_header, &header, sizeof (header)); @@ -909,7 +909,7 @@ gst_rtmp_connection_send_command (GstRtmpConnection * connection, chunk->chunk_stream_id = chunk_stream_id; chunk->timestamp = 0; /* FIXME */ chunk->message_type_id = 0x14; - chunk->info = 0; /* FIXME */ + chunk->stream_id = 0; /* FIXME */ chunk->payload = gst_amf_serialize_command (command_name, transaction_id, command_object, optional_args); @@ -946,7 +946,7 @@ gst_rtmp_connection_send_command2 (GstRtmpConnection * connection, chunk->chunk_stream_id = chunk_stream_id; chunk->timestamp = 0; /* FIXME */ chunk->message_type_id = 0x14; - chunk->info = stream_id; + chunk->stream_id = stream_id; chunk->payload = gst_amf_serialize_command2 (command_name, transaction_id, command_object, optional_args, n3, n4); @@ -980,7 +980,7 @@ gst_rtmp_connection_send_ack (GstRtmpConnection * connection) chunk->chunk_stream_id = 2; chunk->timestamp = 0; chunk->message_type_id = 5; - chunk->info = 0; + chunk->stream_id = 0; data = g_malloc (4); GST_WRITE_UINT32_BE (data, connection->total_input_bytes); @@ -1003,7 +1003,7 @@ gst_rtmp_connection_send_ping_response (GstRtmpConnection * connection, chunk->chunk_stream_id = 2; chunk->timestamp = 0; chunk->message_type_id = 4; - chunk->info = 0; + chunk->stream_id = 0; data = g_malloc (8); GST_WRITE_UINT32_BE (data, 7); @@ -1024,7 +1024,7 @@ gst_rtmp_connection_send_window_size_request (GstRtmpConnection * connection) chunk->chunk_stream_id = 2; chunk->timestamp = 0; chunk->message_type_id = 5; - chunk->info = 0; + chunk->stream_id = 0; data = g_malloc (4); GST_WRITE_UINT32_BE (data, connection->peer_bandwidth); diff --git a/tools/client-test.c b/tools/client-test.c index 6887620..c158c05 100644 --- a/tools/client-test.c +++ b/tools/client-test.c @@ -140,10 +140,10 @@ dump_chunk (GstRtmpChunk * chunk, gboolean dir) return; g_print ("%s chunk_stream_id:%-4d ts:%-8d len:%-6" G_GSIZE_FORMAT - " type_id:%-4d info:%08x\n", dir ? ">>>" : "<<<", + " type_id:%-4d stream_id:%08x\n", dir ? ">>>" : "<<<", chunk->chunk_stream_id, chunk->timestamp, - chunk->message_length, chunk->message_type_id, chunk->info); + chunk->message_length, chunk->message_type_id, chunk->stream_id); if (chunk->message_type_id == 20) { dump_command (chunk); } diff --git a/tools/proxy-server.c b/tools/proxy-server.c index 178dd57..eb0fcba 100644 --- a/tools/proxy-server.c +++ b/tools/proxy-server.c @@ -215,10 +215,10 @@ dump_chunk (GstRtmpChunk * chunk, gboolean dir) return; g_print ("%s chunk_stream_id:%-4d ts:%-8d len:%-6" G_GSIZE_FORMAT - " type_id:%-4d info:%08x\n", dir ? ">>>" : "<<<", + " type_id:%-4d stream_id:%08x\n", dir ? ">>>" : "<<<", chunk->chunk_stream_id, chunk->timestamp, - chunk->message_length, chunk->message_type_id, chunk->info); + chunk->message_length, chunk->message_type_id, chunk->stream_id); if (chunk->message_type_id == 0x14 || chunk->message_type_id == 0x12) { dump_command (chunk); } |