{"action":"created","issue":{"url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc/issues/19","repository_url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc","labels_url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc/issues/19/labels{/name}","comments_url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc/issues/19/comments","events_url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc/issues/19/events","html_url":"https://github.com/disguise-one/hap-encoder-adobe-cc/issues/19","id":370706368,"node_id":"MDU6SXNzdWUzNzA3MDYzNjg=","number":19,"title":"Performance improvements - different DXT compression algorithms?","user":{"login":"DouglasHeriot","id":238401,"node_id":"MDQ6VXNlcjIzODQwMQ==","avatar_url":"https://avatars1.githubusercontent.com/u/238401?v=4","gravatar_id":"","url":"https://api.github.com/users/DouglasHeriot","html_url":"https://github.com/DouglasHeriot","followers_url":"https://api.github.com/users/DouglasHeriot/followers","following_url":"https://api.github.com/users/DouglasHeriot/following{/other_user}","gists_url":"https://api.github.com/users/DouglasHeriot/gists{/gist_id}","starred_url":"https://api.github.com/users/DouglasHeriot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DouglasHeriot/subscriptions","organizations_url":"https://api.github.com/users/DouglasHeriot/orgs","repos_url":"https://api.github.com/users/DouglasHeriot/repos","events_url":"https://api.github.com/users/DouglasHeriot/events{/privacy}","received_events_url":"https://api.github.com/users/DouglasHeriot/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-10-16T16:56:47Z","updated_at":"2018-10-17T06:16:07Z","closed_at":null,"author_association":"NONE","body":"One issue I have consistently as a media server user is convincing my content creation teams that the long export times of HAP codec is worthwhile. I've done some basic testing of different HAP encoders (QT Plugin, FFMPEG, and this Adobe Plugin), and found that FFMPEG runs significantly faster.\r\n\r\nHere's my very quick, non-scientific, ball-park test results converting a 6 minute long video from ProRes 422 LT to HAP:\r\n(2015 MacBook Pro, 2.2GHz i7, Quad Core with hyperthreading)\r\n\r\nEncoder | Time|CPU Usage\r\n-----|----|---\r\nHAP Adobe Plugin 1.0.8-rc4 (Media Encoder 15.1.1)|14m 49s|All CPU cores used\r\nHAP QT Plugin (Media Encoder 15.0)|20m 16s\r\nAVF Batch Converter (highest quality)|22m 30s|All CPU cores used\r\nAVF Batch Converter (lowest quality)|1m 46s|All CPU cores used\r\nFFMPEG 4.0.2|3m 36s|Only single core used\r\n\r\nIt's interesting what the quality slider is doing in the AVFoundation implementation, and interesting that FFMPEG beats the other encoders by so much, and only uses a single core!\r\n\r\nDoing some CPU profiling on my Mac with Xcode Instruments, reveals that almost all of the time in this Adobe plugin is spent inside the DXT compressor (Squish).\r\n\r\nI found that the FFMPEG project uses a different DXT compressor instead of Squish: https://github.com/FFmpeg/FFmpeg/blob/a0ac49e38ee1d1011c394d7be67d0f08b2281526/libavcodec/texturedspenc.c\r\n\r\nAnd it looks like the other Vidvox implementations in QT and AVF use either Squish, or GPU-based DXT compression for lower quality but higher speed.\r\nhttps://github.com/Vidvox/hap-in-avfoundation/blob/master/source/DXT/HapCodecGL.c\r\n\r\nAfter a bit of Googling, I found that Id software wrote a paper in 2006 about Real-Time DXT compression, and then Intel in 2012 improved upon this with more modern SSE instructions.\r\nhttps://software.intel.com/en-us/articles/fast-cpu-dxt-compression\r\nThe Id paper shows a 50x speed increase over Squish. This sounds possible, considering FFMPEG with single core was 8x faster than Squish (this Adobe plugin) which used 8 cores.\r\n\r\n\r\nSo what I'm wondering now:\r\n* How much have you already investigated and tested different DXT compression methods? (I'm pretty new to learning about this)\r\n* If I found the time (no promises!), would you accept a pull request that introduced a \"fast but lower quality\" option that used either this Intel or FFMPEG's DXT compression algorithms?\r\n* Is anyone else out there already working on this?\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc/issues/comments/430502887","html_url":"https://github.com/disguise-one/hap-encoder-adobe-cc/issues/19#issuecomment-430502887","issue_url":"https://api.github.com/repos/disguise-one/hap-encoder-adobe-cc/issues/19","id":430502887,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMDUwMjg4Nw==","user":{"login":"tromerk","id":17144416,"node_id":"MDQ6VXNlcjE3MTQ0NDE2","avatar_url":"https://avatars2.githubusercontent.com/u/17144416?v=4","gravatar_id":"","url":"https://api.github.com/users/tromerk","html_url":"https://github.com/tromerk","followers_url":"https://api.github.com/users/tromerk/followers","following_url":"https://api.github.com/users/tromerk/following{/other_user}","gists_url":"https://api.github.com/users/tromerk/gists{/gist_id}","starred_url":"https://api.github.com/users/tromerk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tromerk/subscriptions","organizations_url":"https://api.github.com/users/tromerk/orgs","repos_url":"https://api.github.com/users/tromerk/repos","events_url":"https://api.github.com/users/tromerk/events{/privacy}","received_events_url":"https://api.github.com/users/tromerk/received_events","type":"User","site_admin":false},"created_at":"2018-10-17T06:16:07Z","updated_at":"2018-10-17T06:16:07Z","author_association":"NONE","body":"I am not knowledgeable on what compressor is being used in which encoder.  And of course we all like it to be fast.  But not at the expense of quality.  \r\n\r\nMy previous findings (this was more than a year ago - not sure if anything has changed) were that the quality results while using FFMPEG were not as good as when using AME (prior to recent releases):\r\nhttps://github.com/Vidvox/hap-qt-codec/issues/39  "}}
{"actor":{"display_login":"tromerk"}}