Decent Hap video playback solution for vvvv [GPU video decoding]

Important update: now we have an established commercial supporter, and reaching the campaign goal will only determine whether the plugin will be released in public for non-commercial use.

Campaign ends on April 1st. In case we won’t reach the goal, the money will be automatically sent back to all the supporters!

I’ve found out today (thanks to Gareth Griffiths from Uberact) that the fact that if wasn’t explicitly stated anywhere prevented some people from supporting the development, hope it won’t be a problem now!

that’s great to hear, thanks m-box!

for developing the plugin keep in mind that the pro playback has to compete with the image stack player of vvvv, which does frame loading in a background thread and only swaps texture references in the mainloop. the idea behind the stack player is that the user sets some frame numbers that the player will load ahead of time in the background. if a specific frame number is requested for display in the mainloop it should already be in memory. automatic playback constantly loads a few frames ahead of the current time.

have a look at the helpatches of the node Player (EX9.Texture) and Player (EX9.Texture Timebased), load a DDS sequence and press CTRL+F9 to compare mainloop time.

1 Like

We’ve done it in just two days over the weekend! Thanks to everyone!
Please see the Initial croudfunding summary and What’s next sections of the top post!!

2 Likes

Development WIP screenshot #1

Btw: for Hap Q, does anyone prefer getting raw YCoCg video texture over the one converted to RGB with an internal color conversion render pass? :-)

3 Likes

Great work @lev!

Glad that you found a model which works for funding development and releasing it to the public (understood re: license limitations there).

If I was designing this myself i’d probably have something like the following node set:

  • Reader (HAP) : Loads HAP file, outputs file reference
  • Info (HAP) : Gives all file info
  • AudioClock (HAP)
  • VideoClock (HAP)
  • FrameClock (HAP)
  • HAPTexture (HAP, DX11.Texture2D)
  • HAPTexture (HAP, DX11.Texture2D YUV)
  • HAPTexture (HAP, EX9.Texture)
  • FileStream (HAP DX11.Texture2D) <- module which wraps everything above with your current proposed interface

The Reader node accepts a Clock input. The clocks have time start/end or frame start/end for FrameClock. Also play/skip/etc controls are applied to the Clock. I’m sure that’s not quite right, but anyway I’d split the playback control elements from the file reading / texture handling / info parts

Something like that.

I generally find ‘one big node’ is good for beginners but gets frustrating quickly. So a big module / broken down into plugins is the best way to expose power and simplicity.

Feel free to ignore this of course! otherwise hope it’s useful

6 Likes

+1 :)

+1

meanwhile there is a hap survey: https://www.surveymonkey.com/r/9TWN88Y

It’s a shame vvvv isn’t in the supported software list yet! I should work faster!
Same goes to https://github.com/Vidvox/hap/blob/master/README.md

Hi everyone!
The Hap player is up and running! We worked a lot on stability, fixing all the memory leaks (including GPU ones) and crashes. However we’re still in closed beta testing and some functionality is missing (audio output and precise external clock synchronization to mention)

Anyone wants to join our betatesting? If yes, drop me a line to lev.panov@gmail.com, or to skype: leavittx. I think we need 2-3 people more right now. Especially interested in someone who’ll be doing some VJ stuff with dynamic videos list change!

Development WIP screenshot #2


It is a bit less modular compared to what @elliotwoods proposed, but I find it modular enough

3 Likes

Will the plugin aoutput audio to the VAudio engine?

@sunep yes!

1 Like

Latest news everybody. Several people have already made really good testing of the plugin. With the awesome feedback they’ve provided over last few weeks, I’ve decided to start public beta-testing today!

Here you go (fresh 64-bit vvvv and dx11 pack are needed, VAudio for audio output)
Known issues are listed in the readme file!

7 Likes

Wow…native HAP …Thanks Lev.

Quickly encoded some of my clips and boom…4 sd videos off my hdd.

.!..might even come out of VJ retirement
because of this…

Need an ssd in my x64 machine now…

Not tried the Vaudio part yet.

1 Like

A new version of Hap player is ready!

What’s new:

  1. Experimental support of non-multiple of 2 video resolutions
  2. Accurate computation of the current frame index
  3. The image queue size was increased to 10 frames/100Mb, which gives slightly better performance in some cases
  4. Don’t seek to the first frame when the playback is finished
  5. Loop pin of HapAudioClock now accepts a boolean (on/off)
  6. Fix Opened/Playing outputs of HapState: don’t reset to false when opening a single video from the input Path spread
  7. HapReaderNode: make number of ouput slices equal to maximum slicecount of (Path, Open) input spreads
  8. You can open one video multiple times, or open a video using arbitrary Open slice, without opening all the slices prior to it in the Open spread
  9. Now works with vvvv 45beta34.2

Downloads: x64 version, x86 version

3 Likes

niiiice! great news! if you deal with hap there’s a high chance you do that on a 64 bit CPU. so I wouldn’t bother with x86

@microdee i’d like to politely disagree. I have to use a plugin only available in 32bit, but I would have to run hapvid as a sub routine and share the texture, which, given its unreliabilty, isn’t an option for me,

So yes Lev, a 32bit plugin would be appreciated if it isn’t too much trouble.

I’ve just noticed that actually there were 3 more important changes in this version! Please take a look at the updated “What’s new” section of my previous post. Also attached a link to the 32-bit plugin version for those who need it!

Please note that for 32-bit applications there exists a per-process memory limit of 2Gb (by default), so don’t try to preload to memory large Hap files, as it might crash vvvv. So 64-bit is much better choice here.

Will work on better help-patches and post them soon!

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.