-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect format when used with ofVideoPlayer #10
Comments
hey prisonerjohn-just confirmed the issue over here and am looking into it |
using a shared_ptr to ofxDSHapVideoPlayer, ofVideoPlayer both overwrites the HAP texture data in ofVideoPlayer::update and never calls ofxDSHapVideoPlayer::draw, which contains some critical logic. ofVideoPlayer::update isn't a virtual function, so ofxDSHapVideoPlayer::update cant override it. unfortunately, it looks like this addon doesn't align with OF's intended architecture for extending video players. i'm happy to chat about mitigating this if you have any ideas. |
Ah I see. It would be nice to solve this if possible, I can look into it more closely and reply here if I find a suitable solution. |
I spent a bit more time on this the other day. If the ofxDSHapVideoPlayer extends ofBaseVideoDraws then it can override the virtual draw() function but ofBaseVideoPlayer doesn't have a virtual update() function that can be overridden. You can cast the player pointer from getplayer() and then call update on it. |
I was wrong in my last post: ofxDSHapVideoPlayer::update() will be called if ofxDSHapVideoPlayer extends ofBaseVideoDraws, but due to the way ofVideoPlayer is structured, ofxDSHapVideoPlayer::draw() will never be called. This is critical if ofxDSHapVideoPlayer is playing a DXT5 encoded file. Let me know if you can think of any other workarounds. |
@mantissa Just curious if this issue was ever resolved? found myself bumping into this issue because I was creating a vector of When I switch from a vector of shared pointers to a
Any suggestions? Thanks for your help in advance! |
Hi, I am facing a very similar issue in my cinder port of this of addon. Did you ever found a way to solve this problem in OF? Thanks! |
I'm trying to use the ofxDSHapVidePlayer inside ofVideoPlayer:
shared_ptr<ofxDSHapVideoPlayer> hapPlayer = make_shared<ofxDSHapVideoPlayer>(); videoPlayer.setPlayer(hapPlayer); videoPlayer.load("sample-1080p30-Hap.avi");
It's running but interpreting the format wrong:

The text was updated successfully, but these errors were encountered: