Perl 6 - the future is here, just unevenly distributed

IRC log for #openframeworks, 2015-03-30

| Channels | #openframeworks index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:27 reqshark joined #openframeworks
01:42 ar_tama joined #openframeworks
01:45 ar_tama_ joined #openframeworks
01:51 jedahan joined #openframeworks
03:00 ar_tama joined #openframeworks
03:32 ar_tama_ joined #openframeworks
03:33 ar_tama joined #openframeworks
03:43 jedahan joined #openframeworks
04:09 jedahan how can I create SomeClass, that sends a reference to the instance of itself for an event using something like `ofNotifyEvent(someEventType, this, this)`, that gets handled by `void someEventTypeHandler(SomeClass &instance){}`?
04:10 jedahan (after adding `ofAddListener(someEventType, this, &ListeningClass::someEventTypeHandler)` )
04:12 admsyn do you mean you want to call a static method of the class?
04:12 admsyn don't 100% follow
04:16 jedahan I have a class Circle, that sends an ofEvent<Circle> SELECTED, when it is selected
04:16 jedahan I want it to send the event using ofNotifyEvent(SELECTED, this)
04:17 jedahan so I can have a handler look at some public properties of that circle
04:17 jedahan get a handle to the circles state at the time SELECTED is handled
04:17 jedahan it might just be I don't understand how to use the void* sender in an event handler
04:18 admsyn yeah I think the intention is to put 'this' in there and then cast it out when you get it on the other side
04:18 admsyn or at least that's how some C APIs deal with that sort of thing
04:18 admsyn but tbh I'm totally guessing, haven't used it that way :)
04:20 jedahan https://github.com/jedahan/kinectFireworks/blob/master/src/Circle.hpp works
04:21 jedahan but if I switch ofEvent<ofColor> to ofEvent<Circle>, and switch ofNotifyEvent(selected, c, this) to ofNotifyEvent(selected, this, this), it all falls apart
04:23 admsyn like crashes or doesn't compile?
04:23 admsyn I think there's an example that shows bundling arbitrary data with an event
04:23 admsyn customEventsExample
04:28 jedahan won't compile. poco complains. I'll read up customEventsExample before heading to bed and sleep on it
04:36 phoenixperry joined #openframeworks
06:00 ar_tama_ joined #openframeworks
06:52 gcds joined #openframeworks
06:53 gcds Hello, guys I am searching for man who could replicate something similar http://www.memo.tv/gold/ as a job
07:03 michela joined #openframeworks
07:40 mhashmi joined #openframeworks
07:51 marcocanc joined #openframeworks
07:59 ar_tama joined #openframeworks
08:11 MyMind joined #openframeworks
08:33 mhashmi_ joined #openframeworks
08:51 ar_tama_ joined #openframeworks
08:57 michela joined #openframeworks
09:47 mhashmi joined #openframeworks
10:53 Phyks jorrakay: ok, so it's less user-friendly than other 3D engines aiming at cross-platform
10:54 Phyks jorrakay: if I understood correctly, this means I can have the core built around OF, but all the UI will need wrappers in Java / Objective-C etc, specific to the devices, true?
10:54 Phyks and using special features like e.g. accelerometers will not be proxified in a common call for all platforms
12:52 okjake joined #openframeworks
13:28 Arthur joined #openframeworks
13:30 Guest62959 Hello guys, I am new in Game development at all, and I am planning to learn C++ game development with OpenGL, can you guys suggest me an good start? What is better for beginner, make own small engine from scatch to learn things? or Use any lightweight libraries / frameworks? Cheers
14:22 HarryHaaren joined #openframeworks
14:33 vade joined #openframeworks
14:45 jedahan joined #openframeworks
14:45 jedahan joined #openframeworks
14:47 HarryHaaren joined #openframeworks
14:59 mhashmi joined #openframeworks
15:17 HarryHaaren joined #openframeworks
15:25 jedahan hmm, so even unordered_set requires some way to compare two values using operator<
15:26 jedahan so set<ofColor> or unordered_set<ofColor> ... I need to learn how to show it a custom comparitor
15:26 jedahan maybe using HSB values to understand operator<
15:31 jedahan I wonder if technically I should be using brightness or hue
15:31 jedahan it depends on how people want to sort "what does it mean for a color to be less than another color?"
15:35 jedahan its weird I would have thought unordered_set would just need ==, not <
15:37 admsyn joined #openframeworks
15:57 lukaszw joined #openframeworks
15:58 synesthete joined #openframeworks
16:04 mhashmi joined #openframeworks
16:18 pizthewiz joined #openframeworks
16:22 mhashmi joined #openframeworks
16:26 jedahan joined #openframeworks
16:26 jedahan joined #openframeworks
16:38 log joined #openframeworks
16:55 jedahan_ joined #openframeworks
17:10 jedahan joined #openframeworks
17:17 mhashmi_ joined #openframeworks
17:23 GuidovanPossum joined #openframeworks
17:44 phoenixperry joined #openframeworks
18:08 phoenixperry Hey any suggestions on why I might get 1386 errors
18:08 phoenixperry on the audiounits addon?
18:09 phoenixperry (I changed the build settings to 10.8 - I also tried it at 10.6 - same)
18:09 jedahan joined #openframeworks
18:09 * pizthewiz pokes ???? @admsyn
18:09 admsyn oh hai
18:09 admsyn what are the errors?
18:09 phoenixperry gimme a sec and I'll copy from console
18:11 admsyn it may just be that you need to add carbon
18:12 admsyn it sounds almost for sure like it's just a missing framework
18:12 phoenixperry ld: symbol(s) not found for architecture i386
18:12 phoenixperry clang: error: linker command failed with exit code 1 (use -v to see invocation)
18:12 phoenixperry I was thinking that
18:12 admsyn what symbols though :p
18:12 admsyn i.e. what's above that
18:12 admsyn but yeah add carbon
18:12 phoenixperry Undefined symbols for architecture i386:
18:12 phoenixperry "_AudioOutputUnitStop", referenced from:
18:12 phoenixperry ofxAudioUnitOutput::stop() in ofxAudioUnitOutput.o
18:12 phoenixperry "_AudioOutputUnitStart", referenced from:
18:12 phoenixperry ofxAudioUnitOutput::start() in ofxAudioUnitOutput.o
18:12 phoenixperry "_AudioUnitRender", referenced from:
18:12 phoenixperry ofxAudioUnit::render(unsigned long*, AudioTimeStamp const*, unsigned long, unsigned long, AudioBufferList*) in ofxAudioUnit.o
18:13 phoenixperry "_AudioUnitSetParameter", referenced from:
18:13 phoenixperry ofxAudioUnitMixer::setInputVolume(float, int) in ofxAudioUnitMixer.o
18:13 phoenixperry ofxAudioUnitMixer::setOutputVolume(float) in ofxAudioUnitMixer.o
18:13 phoenixperry ofxAudioUnitMixer::setPan(float, int) in ofxAudioUnitMixer.o
18:13 phoenixperry "_AudioUnitSetProperty", referenced from:
18:13 pizthewiz Sounds like you aren't linking to the AudioUnit framework
18:13 phoenixperry ofxAudioUnit::connectTo(ofxAudioUnit&, int, int) in ofxAudioUnit.o
18:13 admsyn oh ok that's the AudioUnit framework
18:13 phoenixperry ofxAudioUnit::setRenderCallback(AURenderCallbackStruct, int) in ofxAudioUnit.o
18:13 phoenixperry ofxAudioUnitFilePlayer::setFile(std::string const&) in ofxAudioUnitFilePlayer.o
18:13 phoenixperry ofxAudioUnitFilePlayer::prime() in ofxAudioUnitFilePlayer.o
18:13 phoenixperry ofxAudioUnitFilePlayer::play(unsigned long long) in ofxAudioUnitFilePlayer.o
18:13 phoenixperry "_AudioUnitUninitialize", referenced from:
18:13 phoenixperry ofxAudioUnit::AudioUnitDeleter(ComponentInstanceRecord**) in ofxAudioUnit.o
18:13 admsyn phoenixperry: post stuff like that on pastebin next time, it's easier to read
18:13 phoenixperry "_AudioComponentInstanceDispose", referenced from:
18:13 phoenixperry ofxAudioUnit::AudioUnitDeleter(ComponentInstanceRecord**) in ofxAudioUnit.o
18:13 admsyn and freenode may boot you
18:13 phoenixperry "_AudioComponentInstanceNew", referenced from:
18:13 phoenixperry ofxAudioUnit::allocUnit(AudioComponentDescription) in ofxAudioUnit.o
18:13 phoenixperry "_AudioComponentFindNext", referenced from:
18:13 phoenixperry ofxAudioUnit::allocUnit(AudioComponentDescription) in ofxAudioUnit.o
18:13 phoenixperry "_AudioUnitInitialize", referenced from:
18:13 phoenixperry ofxAudioUnit::initUnit() in ofxAudioUnit.o
18:13 phoenixperry "_AudioUnitReset", referenced from:
18:13 phoenixperry ofxAudioUnit::reset() in ofxAudioUnitFilePlayer.o
18:13 phoenixperry "_AudioUnitGetPropertyInfo", referenced from:
18:13 phoenixperry -[ofxAudioUnitUIWindow initWithCocoaViewForUnit:] in ofxAudioUnitCocoaUtilties.o
18:13 phoenixperry +[ofxAudioUnitUIWindow audioUnitHasCocoaView:] in ofxAudioUnitCocoaUtilties.o
18:13 pizthewiz I wonder if we are going to get all 1386 errors ;0) ????
18:13 phoenixperry +[ofxAudioUnitUIWindow audioUnitHasCarbonView:] in ofxAudioUnitCocoaUtilties.o
18:13 phoenixperry "_AudioUnitGetProperty", referenced from:
18:13 phoenixperry -[ofxAudioUnitUIWindow initWithCocoaViewForUnit:] in ofxAudioUnitCocoaUtilties.o
18:13 admsyn looking forward to it :)
18:14 phoenixperry ofxAudioUnit::getNumOutputChannels() const in ofxAudioUnit.o
18:14 phoenixperry ofxAudioUnitMixer::getInputBusCount() const in ofxAudioUnitMixer.o
18:14 phoenixperry I used project generator to make a new project then added the addon w/your xcode plugin
18:14 admsyn ¯\_(ツ)_/¯ it works when I do it
18:14 phoenixperry I usually get them from just having the wrong version of osx targeted
18:14 admsyn not sure what the deal is
18:14 admsyn but yeah try adding the framework(s)
18:14 phoenixperry ok will do
18:14 admsyn sounds like just the AudioUnit framework
18:14 phoenixperry also should i just copy empty example verses using project generator to create a new project?
18:15 phoenixperry would that possibly cause it?
18:15 admsyn no PG is probably the way to go
18:15 phoenixperry ok
18:15 phoenixperry I'll try again
18:15 admsyn fwiw I usually just make a new app with the PG and add ofxAudioUnit via the plugin and it's fine
18:15 admsyn but `hsrug
18:16 phoenixperry ok let me give it another go
18:16 phoenixperry what OS are you on?
18:16 admsyn 10.10 but I've used it on 10.9 and the code dates back to 10.7
18:18 pizthewiz Yosemite or bust!
18:20 phoenixperry and hello by the way
18:20 phoenixperry :)
18:20 phoenixperry I assume you're not just a robot!
18:20 phoenixperry (but this could be a bad assumption!)
18:21 admsyn boop
18:23 phoenixperry ok I did a new build new code w/ ofApp.cpp copied from the example folder
18:23 phoenixperry and I got this one
18:23 phoenixperry Undefined symbols for architecture i386:
18:23 phoenixperry ".objc_class_name_AUGenericView", referenced from:
18:23 phoenixperry pointer-to-literal-objc-class-name in ofxAudioUnitCocoaUtilties.o
18:23 phoenixperry ld: symbol(s) not found for architecture i386
18:23 phoenixperry clang: error: linker command failed with exit code 1 (use -v to see invocation)
18:23 admsyn that's coreaudiokit
18:23 admsyn CoreAudioKit
18:23 admsyn btw this is documented in the README
18:23 admsyn https://github.com/admsyn/ofxAudioUnit#adding-ofxaudiounit-to-your-of-app
18:24 phoenixperry I saw that
18:24 phoenixperry just looking at it now actually
18:26 phoenixperry oh wait
18:26 phoenixperry is coreAudio different than coreAudioKit
18:26 phoenixperry checking
18:26 admsyn yepp, it's this tiny little thing that just has some stuff for audio unit guis
18:26 phoenixperry wow
18:26 phoenixperry works fine
18:26 phoenixperry I am shame cat
18:26 admsyn cool
18:26 admsyn no worries :p
18:28 phoenixperry you are amazing for all these great tools
18:28 phoenixperry thank you
18:28 phoenixperry Let me know if you need documentation ever
18:28 admsyn will do!
18:31 pizthewiz beep boop blop
18:32 pizthewiz Would OFPlugin have helped here, was it an issue of adding the addon to an existing project?
18:33 admsyn OFPlugin parses the addon_config and adds the frameworks that are specified in it
18:33 admsyn unless it's done broke itself
18:33 pizthewiz Ahh, so it might have worked in this case yeah?
18:36 phoenixperry I used it to add the addon
18:36 phoenixperry so it didn't work in my case
18:36 admsyn well, it does for me but it's been a few months and maybe some part of the chain is borked
18:36 phoenixperry who knows I mean there's a clear back up
18:36 admsyn or maybe it's a bug on older xcode / os
18:37 phoenixperry I only had a few minutes before work today or I'd of tried more earlier before pinging
18:37 phoenixperry yah I'm in an older version
18:37 jedahan joined #openframeworks
18:53 joshuajnoble joined #openframeworks
18:53 joshuajnoble @admsyn hey there you are. i'm kicked out of gchat for whatever reason
18:53 joshuajnoble they've blocked my account for trying to use it through imessage
18:55 admsyn oh hey joshuajnoble yeah I just emailed you :)
18:55 joshuajnoble oh nice. well thank you :)
18:55 lukaszw joined #openframeworks
18:57 joshuajnoble when you say "I’d have to guess something somewhere is trampling on the stack " like, should that be happening in setup()
18:57 admsyn of it could be that one of the things ofApp is inheriting is doing something bad
18:57 joshuajnoble it seems like the simplest possible thing I could be doing
18:57 admsyn or one of the constructors of one of the variables is doing something bad
18:57 joshuajnoble it's weird because everything works fine if I don't use my dataobject
18:57 admsyn yeah ¯\_(ツ)_/¯
18:57 joshuajnoble like, if i just stick with char[] and bool
18:58 joshuajnoble it all runs and actually works just fine
18:58 joshuajnoble hmm.
18:58 admsyn actually one thing you could do to shake out memory bugs is just move over to shared_ptr<ofxBLECharacteristic> instead of using them directly
18:58 joshuajnoble ok. maybe I'll give up on this whole "make it nice" thing
18:58 admsyn if you get the same crash at least it points the finger more directly at ofxBLECharacteristic
18:58 admsyn yeah who needs nice
19:00 admsyn the guard malloc thing can be pretty good at tracking down Weird Shit
19:00 pizthewiz That's just a dynamic linker tweak away no?
19:01 admsyn yeah it's in the scheme
19:02 pizthewiz Even easier then
19:02 admsyn but yeah in terms of Obj-C++ I don't think anything's going on directly that would be causing that
19:02 admsyn I don't think ARC is even enabled for instance
19:03 admsyn pizthewiz: if you have any ideas, this is crashing for some reason https://github.com/joshuajnoble/ofxBLEDevice/blob/master/example/src/ofApp.mm#L11
19:03 admsyn where UUID = std::string and tx is a https://github.com/joshuajnoble/ofxBLEDevice/blob/master/src/ofxBLECharacteristic.h
19:04 pizthewiz The actual assignment blows up?
19:04 admsyn yeah
19:04 pizthewiz Because tx is pointing to garbage?
19:04 admsyn it's just a member of the ofApp though
19:06 joshuajnoble I mean, it could be pointing to garbage bc I'll confess to not understanding how the ObjC memory model works at all
19:06 Phyks left #openframeworks
19:06 joshuajnoble but it seems to me that if its a member then it should be correctly initiliazed
19:07 admsyn yeah it seems pretty squarely in C++ territory
19:07 pizthewiz Yeah this is unrelated to the Obj-C++ characteristic class
19:08 pizthewiz The lifetime of tx should strictly be tied to ofApp
19:08 admsyn does it explode if you get rid of the tx bit and let it go through to assigning to rx?
19:08 pizthewiz Does the constructor get called?
19:08 admsyn ANSWER US
19:08 joshuajnoble don't know my project just suddenly decided that it can't find ofMain.h so I need to figure that out
19:09 admsyn haha
19:09 joshuajnoble i know seriously
19:09 pizthewiz Is this against 0.8.4 or HEAD?
19:09 admsyn watch this be one of those things a clean+build solves
19:09 joshuajnoble since this AM this whole addon dev thing has gone from "things are going great" to "MY COMPUTER IS NOW MELTING"
19:10 pizthewiz When Precompiled Headers Go Bad™
19:17 pizthewiz Strange, I don't see the crash at all when running the example app
19:17 pizthewiz (lldb) p tx
19:17 pizthewiz (ofxBLECharacteristic) $4 = (shouldNotify = false, UUID = "713D0003-503E-4C75-BA94-3148F18D941E")
19:20 joshuajnoble Now I don't either
19:20 joshuajnoble scrapped and completely rebuilt project from scratch and now all is well
19:21 joshuajnoble I just shrugged so hard my neck cracked
19:21 admsyn haha
19:21 admsyn cmd+k cmd-r all day
19:21 admsyn cmd-shift-k whatever
20:01 pizthewiz joined #openframeworks
20:12 jedahan joined #openframeworks
20:45 mhashmi joined #openframeworks
20:59 vade joined #openframeworks
21:20 admsyn left #openframeworks
21:20 admsyn joined #openframeworks
21:40 notjosh joined #openframeworks
21:51 notjosh joined #openframeworks
22:15 pizthewiz joined #openframeworks
22:53 pizthewiz joined #openframeworks
22:55 pizthewiz joined #openframeworks
23:04 pizthewiz joined #openframeworks
23:20 mhashmi joined #openframeworks

| Channels | #openframeworks index | Today | | Search | Google Search | Plain-Text | summary