Support Request #3472
closed
Transmission between filterns via IMediaSample in ADTF 2.x
Added by hidden almost 6 years ago.
Updated almost 6 years ago.
Requester's Priority:
Normal
Description
Supportanfrage:
Ich habe eine allgemeine Frage bezüglich der Datenübertragung zwischen Filtern mittels IMediaSample in ADTF 2.x.
Wird bei der Übertragung eine Kopie der Daten an den Empfänger übergeben oder wird auf den Speicherbereich verwiesen in dem die originalen Daten abgelegt sind?
Welche Vorteile bzw. Nachteile bietet die jeweilige Methode?
Lösung:
Beides ist möglich, standardmäßig wird eine Kopie übertragen.
Siehe hierzu das MSF_Reference Flag in der ADTF 2 Doku: MSF_Reference
Vor-/Nachteile können dem DokuLink Pins for Filters: Sending Data entnommen werden:
Warning:
The flag MSF_Reference has to be used with great caution. Its effect is that the data is not copied; instead only a reference to the external memory is saved in the MediaSample. The data may therefore not be changed as long as the MediaSample has not yet been deleted!
The MSF_Reference flag was introduced for the optimization of an entire application in order to prevent the repeated copying of storage ranges. Here it is very important that this is taken into account in the whole application and by all Filters. The use is unproblematic as long as no Filter buffers this MediaSample. The ADTF default Filters (i.e. QueueRecorder) take this into account, which create a copy in every case in order to prevent a collision through MSF_Reference. It is important for other "User" applications that the programmers of Filters that must absolutely use storage references agree with one another.
- Subject changed from AW: Please register to Transmission between filterns via IMediaSample in ADTF 2.x
- Status changed from New to In Progress
- Topic set to ADTF::Streaming
- Customer set to MAN
Hallo André,
Beides ist möglich, aber standardmäßig wird eine Kopie übertragen.
Siehe hierzu das MSF_Reference Flag in der ADTF 2 Doku: MSF_Reference Doku-Link
Gruß,
Michael
Hallo André,
sieh dir bitte bzgl. MSF_Reference auch folgende Seite an (insbesondere das Warning): Pins for Filters
Ist deine Anfrage damit beantwortet?
Gruß,
Michael
- Status changed from In Progress to Customer Feedback Required
Hallo Michael,
danke für deine Antwort. Welche Vorteile bzw. Nachteile bietet die jeweilige Methode?
Viele Grüße
André
Hallo André,
zur Frage Vor-/Nachteile konnte ich dem zweiten DokuLink Pins for Filters entnehmen:
Warning:
The flag MSF_Reference has to be used with great caution. Its effect is that the data is not copied; instead only a reference to the external memory is saved in the MediaSample. The data may therefore not be changed as long as the MediaSample has not yet been deleted!
The MSF_Reference flag was introduced for the optimization of an entire application in order to prevent the repeated copying of storage ranges. Here it is very important that this is taken into account in the whole application and by all Filters. The use is unproblematic as long as no Filter buffers this MediaSample. The ADTF default Filters (i.e. QueueRecorder) take this into account, which create a copy in every case in order to prevent a collision through MSF_Reference. It is important for other "User" applications that the programmers of Filters that must absolutely use storage references agree with one another.
Ist deine Anfrage damit beantwortet und wir können das Ticket schließen?
Gruß,
Michael
Vielen Dank, du kannst das Ticket schließen
Viele Grüße
André
- Description updated (diff)
- Status changed from Customer Feedback Required to To Be Closed
- Resolution set to Solved Issue
- Affected Products ADTF 2.14.2 added
- Platform Windows 7 64bit added
- Status changed from To Be Closed to Closed
- Private changed from Yes to No
Also available in: Atom
PDF