Commit Graph

50 Commits

Author SHA1 Message Date
Saxon d17880714e container/mts: make rate and media type encoder parameters option functions 2020-05-06 20:10:55 +09:30
Saxon 13ce7cdba0 container/mts: doing logging in encoder code now 2020-05-03 16:54:12 +09:30
Saxon 18ffefd7cb give container/mts NewEncoder(...) log parameter and update code around repo accordingly 2020-05-03 14:14:31 +09:30
Scott d0adae710e PR fixes 2019-12-19 14:21:32 +10:30
Ella Pietraroia 0ec0a08e0e comments and some other small changes made to revid.go encoder.go and config.go 2019-12-19 11:15:47 +10:30
Ella Pietraroia 222864108f making a time based psi method for when to send packets
Added a case that allows packets to be sent by unit of time (in seconds) rather than by number of packets or nal methods. Also made a variable that can be changed in vidgrinder to choose the amount of time, called PsiTime
2019-12-19 09:56:24 +10:30
Scott e116e197ae Changed all %v's to %w's where appropriate 2019-12-04 14:12:20 +10:30
Saxon d554173d7c container/mts/encoder.go: fixed typo in comment for global Meta var 2019-09-24 12:57:38 +09:30
Saxon 4ecd99b0f5 container/mts/encoder.go: gave MJPEG stream ID unique value 2019-09-24 12:54:12 +09:30
Saxon 191be04b11 revid: added support for MJPEG packetisation
Changes included adding support for variable InputCodec that may be set via netreceiver/vidgrind to set to H264/MJPEG. Also setting revid's lexTo
function to mjpeg.Lex in the case of an MJPEG InputCodec. Added options parameter to mts.NewEncoder function so that we can change options of the
encoder, namely whether it bases PSI interval on NAL type, or number of frames - in the case of MJPEG we based PSI interval on number of frames.
2019-09-24 07:42:26 +09:30
Dan Kortschak 8a9d914283 container/mts: use uint16 for media PID 2019-09-15 09:27:26 +09:30
Trek H c3df750175 mts: set nalbasedpsi to false for audio 2019-09-12 23:12:55 +09:30
Trek H e7a02a818f mts: fixed type conversion 2019-09-12 21:29:40 +09:30
Trek H 96035f6d8b adpcm and mts: comments and pid change 2019-09-12 19:16:11 +09:30
Saxon e57e14678a container/mts: using RealTime type from utils package instead of global vars with mutator functions 2019-08-26 13:29:07 +09:30
Saxon b9cd6b3f13 container/mts/encoder.go: using NALTypeSPS from h264dec package 2019-08-26 09:24:18 +09:30
Saxon 817cc86a34 revid: now have MinPeriod and ClipDuration params
This change included a rename of IntraRefreshPeriod to MinPeriod, and the addition of the ClipDuration param. PSI are now written before IDR. Clips are no longer outputed
based on PSI but rather a time ClipDuration, where ClipDuration >= MinPeriod, however, PSI must still be at the beginning of each clip. Also created functionality to update
meta time even if we don't have a response to update.
2019-08-25 20:42:01 +09:30
Trek H 3f29f0c84e Merge branch 'master' into revid-audio 2019-08-02 23:32:21 +09:30
scruzin 90efebdc91 Added BasePMT which is a PMT without specific data, and removed StandardPMT. 2019-07-10 10:17:34 +09:30
scruzin 1728c3a531 Export StandardPAT, StandardPMT and MaxPTS. 2019-07-10 09:26:54 +09:30
Trek H 3e2ff49420 revid: mts encoder uses exported pids 2019-06-06 00:28:26 +09:30
Trek H 3d7539c6df Merge branch 'master' into revid-audio 2019-06-03 17:50:48 +09:30
Saxon ecc0ab8664 container/mts/encoder.go: updated comment for Encode constants 2019-05-23 14:05:17 +09:30
Saxon 85984555a3 container/mts/encoder.go: fixed comment for pmtTable initialisation 2019-05-21 17:09:47 +09:30
Saxon d29141cf05 container/mts: changed consts H264, H265 and Audio to EncodeH264, EncodeH265 and EncodeAudio 2019-05-21 16:57:17 +09:30
Saxon 92d4c5f79a container/mts/encoder.go: generalising stream id logic 2019-05-16 16:41:52 +09:30
Saxon 548b7caa81 revid: fixed rtpPort and rtcpPort parsing and added H264 and H265 IDs
Added H264ID and H265ID consts and added logic to select this const for use in encoder based on mediaType param in NewEncoder. Also now
declaring PMT in NewEncoder so that we can set streamID correctly based on mediaType.
2019-05-16 13:57:10 +09:30
Saxon 8081fd48a0 container/mts/mpegts.go: fixed conflict with master 2019-05-13 17:07:53 +09:30
Saxon 51f4d123bf container/mts: using MPEG-TS in comments rather than MPEGTS or mpegts 2019-05-11 21:14:28 +09:30
Saxon 1ab6ab116a container/mts/encoder.go: fixed comment for PTSFrequency const. 2019-05-11 16:33:09 +09:30
Saxon aa5a089c55 container/mts/encoder.go: fixed comment for time-related constants 2019-05-11 16:32:00 +09:30
Saxon 0d3463ac87 container/mts: update comments for PCRFrequency and PTSFrequency 2019-05-11 13:57:02 +09:30
Saxon 8f8ae7c558 container/mts: using uint16 for PID always 2019-05-11 13:50:40 +09:30
Saxon 04c7825063 container/mts: PCRFreq->PCRFrequency and PTSFreq->PTSFrequency 2019-05-11 13:48:32 +09:30
Saxon e2d9853264 container/mts: fixed build error 2019-05-11 12:49:31 +09:30
Saxon 594dca1b21 container/mts/encoder.go: export PTS frequency. 2019-05-11 12:46:31 +09:30
Trek H faa6246a51 Merge branch 'master' into revid-audio 2019-05-08 16:23:56 +09:30
Saxon 3292ce0506 container/mts: simplified Packet.Bytes(), and tested 2019-05-07 23:10:03 +09:30
Saxon 77ff88392f revid: setupInput function for revid now returns closure that is used to do any clean up 2019-05-06 15:12:05 +09:30
Trek H 09db8907a5 revid: matching up audio packet sizes, chunk sizes and rates throughout revid pipeline 2019-04-26 17:03:30 +09:30
Trek H b1e5b4341f revid: pid for audio being written to mts packets 2019-04-24 16:39:18 +09:30
Trek H 20c9e6c409 revid: added PCM and ADPCM codecs 2019-04-23 16:20:47 +09:30
Saxon f59879b51d revid: removed ringBuffer after lexer
Now that we want buffered senders (as required), the ringBuffer that was after the
lexer has been removed. Instead, we now have an ioext.multiWriterCloser to which the
lexer writes to. This then writes to the encoders, and then encoders write to each of
their own multiWriteClosers, which write to the appropriate senders. We now call
close on the first multiWriteCloser to close down the entired pipeline, as this close
call propogates through each level.

We have removed the outputClips routine as it's not required anymore to get data
from the revid ringBuffer, and have removed other things that were used by this, like
the IsRunning function.

We have also updated tests to work with these changes - they are passing.
2019-04-15 08:42:56 +09:30
Trek H 7c990b3bb5 mts: reordered, neatened and clarified code. 2019-04-10 17:18:42 +09:30
Trek H 3c29ca554d mts: removed readme reference, added comments to test 2019-04-09 14:59:10 +09:30
Trek H 634ecfdbb2 mts: Limited size of encoder writes and updated audio_test
Previously the encoder would not care if a write was given that exceeded the max PES packet size
because we were never using PES packets bigger than a frame of video. Now I have changed it so that
the encoder will check the write length and create a new PES packet if needed.
I have also restructured my test so that it can extract the data from PES packets that span accross multiple
MTS packets.
2019-04-09 13:55:46 +09:30
Trek H 78447ed495 mts: Added audio mts encoding and test 2019-04-09 13:55:45 +09:30
Saxon 937f54f418 av: fixed conflicts with master 2019-03-28 11:03:05 +10:30
Saxon 5366eca2f2 av: fixed imports 2019-03-25 11:51:03 +10:30
Saxon 3a736172ee av: restructured directories 2019-03-25 11:34:56 +10:30