Comments (9)
OF version and platform?
from ofxhapplayer.
0.9.2 in OSX
from ofxhapplayer.
and works otherwise? ie you are on a 32-bit build?
from ofxhapplayer.
I'd try constructing the player on the thread - but ofxHapPlayer isn't thread-safe, you would have to lock around calls to it if you want to use it from both threads.
from ofxhapplayer.
Yes it works fine without the thread. 32 bit build.
I tried constructing the player in the thread and just omitting it entirely
from ofApp class, it gave me the same result, black screen.
I also tried running ofVideoPlayer in the thread instead of ofxHapPlayer.
That works fine. Perhaps it's something to do with the way video is drawn?
On Feb 13, 2016 18:35, "Tom Butterworth" [email protected] wrote:
I'd try constructing the player on the thread - but ofxHapPlayer isn't
thread-safe, you would have to lock around calls to it if you want to use
it from both threads.—
Reply to this email directly or view it on GitHub
#16 (comment)
.
from ofxhapplayer.
In the interest of getting something workin for you - are you sure the threaded player is necessary? The point of Hap is that it's light on CPU usage.
from ofxhapplayer.
Thanks. The reason I'm using threads is because I want to delay playback for a precise number of milliseconds. The larger goal is to have several machines on a network play back sound and video clips in sync with each other. So I'm mixing ofxHapPlayer with ofxNetworkSync.
from ofxhapplayer.
I don't have time to look into this soon. QuickTime does not like any work happening across threads, so you will have to create the ofxHapPlayer (using new ofxHapPlayer()
) and call all its methods on the thread. That will be complicated because getTexture()
will do work in OpenGL which you will have to coordinate with the main thread - and then use that texture on the main thread.
I'm still not convinced this isn't overkill. On a reliable network I've had success using OSC to push frame numbers - see https://github.com/joanielemercier/MediaPlayer_server and https://github.com/joanielemercier/MediaPlayer_client - largely undocumented and for OF 0.8, but worked well.
from ofxhapplayer.
OK - I will see if ofVideoPlayer can't meet my needs, then branch out from there if needs be.
Thanks for taking the time, much appreciated!
from ofxhapplayer.
Related Issues (20)
- macOS 10.15 and OF 0.11 compile error HOT 8
- setFrame()? TODO HOT 1
- lower fps than ofxHAPAVPlayer with 10 x 4K
- Ringerbuffer clashes with ofxIO HOT 2
- INVALID OR CORRUPT FILE libavcodec.57.64.101.dylib HOT 4
- Exception from unique_lock in Demuxer.cpp HOT 5
- Sending video images to ofxCv HOT 1
- Libdispatch errors with GCC on some Linuxes HOT 4
- getTotalNumFrames() returns 0 HOT 4
- getWidth() and getHeight() return 0 HOT 2
- No PCM audio playback on OSX HOT 1
- Issue with multiple players HOT 6
- same video, asynchronous play
- Compiling on windows with qtcreator/msys2 HOT 1
- Error with @rpath/ffmpeg/lib/osx/libavutil.56.dylib
- Unable to pass ofxHapPlayer textures to a custom shader
- How to access Pixels still?
- It's possible to extract an image frame "offline" to generate thumbnails? HOT 1
- No sound on Windows...
- compatibility with ffmpeg 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ofxhapplayer.