#jogamp @ irc.freenode.net - 20160924 20:19:25 (UTC)


20160924 20:19:25 -jogamp- Previous @ http://jogamp.org/log/irc/jogamp_20160924190524.html
20160924 20:19:25 -NickServ- This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>.
20160924 20:19:31 * jogamp (~jogamp@anon) has joined #jogamp
20160924 20:19:31 * Topic is 'http://jogamp.org | Hacking 3D Graphics, Multimedia and Processing across Devices | logs: http://jogamp.org/log/irc/?C=M;O=D'
20160924 20:19:31 * Set by rmk0 on 20141110 16:19:10
20160924 20:19:32 -NickServ- You are now identified for jogamp.
20160924 20:22:05 * zubzub (~zubzub@anon) has joined #jogamp
20160924 20:25:06 * bigpet (uid25664@anon) Quit (Ping timeout: 265 seconds)
20160924 20:36:49 * rmk0 (~rmk0@anon) has joined #jogamp
20160924 20:52:03 * rmk0 (~rmk0@anon) Quit (Ping timeout: 272 seconds)
20160924 20:53:16 * rmk0 (~rmk0@anon) has joined #jogamp
20160924 20:53:17 * rmk0 (~rmk0@anon) Quit (Changing host)
20160924 20:53:17 * rmk0 (~rmk0@anon) has joined #jogamp
20160924 21:14:52 * bigpet (uid25664@anon) has joined #jogamp
20160924 21:52:41 * bigpet (uid25664@anon) Quit (*.net *.split)
20160924 22:13:18 * bigpet (uid25664@anon) has joined #jogamp
20160924 22:13:26 * bigpet (uid25664@anon) Quit (Changing host)
20160924 22:13:26 * bigpet (uid25664@anon) has joined #jogamp
20160925 08:54:30 * monsieur_max (~maxime@anon) has joined #jogamp
20160925 12:51:41 * bigpet (uid25664@anon) Quit (Read error: Connection reset by peer)
20160925 12:53:14 * bigpet (uid25664@anon) has joined #jogamp
20160925 14:30:06 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20160925 14:33:16 * elect (~elect@anon) has joined #jogamp
20160925 14:34:23 <elect> hi
20160925 14:35:04 <elect> I am exploring the possibility to implement operator overloading in java through pre-compiling IDE plugin or other jvm languages
20160925 14:35:11 <elect> such as groovy, scala or kotlin
20160925 14:35:27 <elect> do you guys have some experience about?
20160925 14:37:03 * caelum19 (b2a78e11@anon) has joined #jogamp
20160925 14:37:14 <caelum19> Hi
20160925 14:57:12 <elect> hi
20160925 14:59:36 <rmk0> .(°_°).
20160925 14:59:55 <elect> rmk0, tell me
20160925 15:00:08 <rmk0> tell you what?
20160925 15:00:30 <elect> do you have something to reply about what I wrote?
20160925 15:00:53 <rmk0> i know scala supports defining arbitrary operators
20160925 15:01:08 <rmk0> i don't know about doing it in java
20160925 15:02:28 <rmk0> i know there's nothing in standard java that would let you implement it
20160925 15:02:42 <elect> afaik
20160925 15:02:45 <rmk0> would be forced to use an external parser of some sort, and i doubt any IDE is going to be able to cope with that
20160925 15:02:48 <elect> there are nowadays only 2 ways
20160925 15:02:58 <elect> http://github.io/mvnrepo/java-oo/
20160925 15:03:05 <elect> or use other jvm languages
20160925 15:03:24 <elect> according to this guy
20160925 15:03:24 <elect> https://artemzin.com/blog/state-of-kotlin-as-main-language-for-android-project/
20160925 15:03:27 <elect> is possible
20160925 15:03:27 <rmk0> that java-oo link doesn't seem to point to anything
20160925 15:03:48 <elect> https://github.com/amelentev/java-oo/
20160925 15:03:49 <elect> sorry
20160925 15:04:08 <elect> btw, the guy says "If your team is Okay -> then this won't be an issue, especially because you have to import the operator implementation so it does not implicitly come to your code."
20160925 15:04:14 <elect> at point 7)
20160925 15:04:30 <rmk0> operator overloading in kotlin is limited
20160925 15:04:34 <elect> I know
20160925 15:04:41 <elect> but it'd be still heaven for me
20160925 15:04:55 <elect> I wrote this kotlin class
20160925 15:04:55 <elect> https://opencredo.com/complex-kotlin/
20160925 15:05:05 <elect> and on java side I tried this
20160925 15:05:06 <rmk0> it really only does arithmetic operators
20160925 15:05:17 <elect> Complex a = new Complex(1.0, -1.0);
20160925 15:05:18 <elect> Complex b = new Complex(2.0, 0.0);
20160925 15:05:18 <elect> Complex c = a + b;
20160925 15:05:24 <rmk0> no monads ._.
20160925 15:05:37 <elect> rmk0, really, it'd be a huge step for me just arithmetic operators
20160925 15:05:48 <elect> however, whenever I compile, it complais
20160925 15:05:57 <elect> error: bad operand types for binary operator '+'
20160925 15:05:57 <elect> Complex c = a + b;
20160925 15:43:47 <caelum19> What's the problem? I'm relatively experienced with Kotlin
20160925 15:44:43 <caelum19> From a limitied skim over the past conversation it sounds like your operator fun's parameters are differenent types to a and b
20160925 15:45:02 <elect> hi caelum19
20160925 15:45:18 <caelum19> hey
20160925 15:45:30 <elect> a and b are both the same class
20160925 15:45:52 <elect> Complex
20160925 15:45:54 <caelum19> and the operator fun's parameters are also that class?
20160925 15:45:57 <elect> I took it from here https://opencredo.com/complex-kotlin/
20160925 15:47:49 <caelum19> Do you have both plus operator methods?
20160925 15:48:01 <elect> what do you mean by both?
20160925 15:48:25 <caelum19> there's one for doubles and another for other Complexes in the link you sent
20160925 15:49:00 <elect> ah you are right
20160925 15:49:02 <elect> shall I delete one?
20160925 15:49:10 <elect> no wait
20160925 15:49:25 <elect> they shouldnt interfeer each other
20160925 15:49:43 <elect> one accept 'double' and one 'Complex'
20160925 15:49:52 <caelum19> yeah they shouldn't, I was just thinking maybe you only copied the one for doubles or something
20160925 15:50:01 <elect> no, I copied the whole class
20160925 15:50:12 <elect> and on java
20160925 15:50:12 <elect> Complex a = new Complex(1.0, -1.0);
20160925 15:50:12 <elect> Complex b = new Complex(2.0, 0.0);
20160925 15:50:12 <elect> Complex c = a + b;
20160925 15:51:00 <caelum19> So you're trying to use an operator overloaded in Kotlin with in Java?
20160925 15:52:31 <elect> yes
20160925 15:53:56 <caelum19> Oh. I think the only special behaviour Java affords to operators on objects is for Strings
20160925 15:54:23 <elect> I guess so
20160925 15:54:24 <elect> pity
20160925 15:54:29 <caelum19> yeah
20160925 15:54:37 <caelum19> So you can't just use Kotlin everywhere? :P
20160925 15:55:00 <elect> :D
20160925 15:55:03 <elect> I wish
20160925 15:55:11 <elect> but what about jogl?
20160925 15:55:23 <caelum19> it's kogl now! :D
20160925 15:55:41 <elect> ^^
20160925 15:56:45 <elect> would it be so hard to port it to kotlin or any other jvm language?
20160925 15:57:30 <caelum19> We could just all download IntellliJ and start going through all the classes and donig ctrl+alt+k
20160925 15:57:44 <caelum19> ctrl+alt+shift+k *
20160925 15:58:27 <elect> no other consequences?
20160925 15:58:37 <elect> what about ant and building scripts?
20160925 15:58:58 <caelum19> The code would be really weird, those would probably break and it would be less accessible as an open source project
20160925 15:59:01 <caelum19> but Kotlin :D
20160925 16:00:09 <caelum19> though, Gradle works with Kotlin, and there's also Kobalt that is cool
20160925 16:07:34 <elect> well, it's possible to call java from kotlin
20160925 16:13:32 <rmk0> i've used jogl from both kotlin and scala
20160925 16:22:59 <elect> experience?
20160925 16:23:08 <elect> in terms of usability and perf?
20160925 16:23:33 <rmk0> is functionally identical to calling it from java
20160925 16:23:36 <rmk0> same bytecode, etc
20160925 16:24:09 <caelum19> same with Kotlin
20160925 16:24:30 <caelum19> wait that's what you mean nevermind me :P
20160925 17:21:18 <elect> I know is reductive
20160925 17:21:40 <elect> but what are your preferences between groovy, scala and kotlin, guys?
20160925 17:22:35 <rmk0> i would pick kotlin if forced to pick
20160925 17:23:20 <rmk0> groovy is too permissive... dynamic typing is not a feature. scala's type system and language semantics are far too complicated
20160925 17:23:35 <rmk0> kotlin wins by not fucking up anything in a major way, but i still don't think much of it
20160925 17:24:04 <rmk0> ceylon is a lot better than all of them, but it's a separate universe
20160925 17:24:18 <rmk0> has its own maven-incompatible packaging system and so on
20160925 17:24:45 <rmk0> the ceylon people actually write proofs of soundness for their type systems and the like
20160925 17:26:02 <rmk0> scala's implicits are an absolute nightmare
20160925 17:26:29 <rmk0> is hard to express just how difficult they make code to read, and how much time they add to compilation
20160925 17:27:01 <rmk0> imagine a structure that can effectively add methods to a given type without you having any idea what you imported that caused the methods to be added
20160925 17:27:37 <rmk0> the compiler has to perform searches to resolve implicits... compilation time explodes when you have several imported
20160925 17:27:40 <rmk0> gruesome
20160925 17:28:05 <rmk0> it's gotten so out of hand that they're completely rewriting the compiler and redesigning parts of the language
20160925 17:39:34 <rmk0> elect: you got some need to switch languages?
20160925 17:45:26 <elect> I'd like operator overloading
20160925 17:45:33 <elect> and some less verbosity
20160925 17:46:50 <elect> but this comes from some late work on glm
20160925 17:47:20 <elect> which ide do you use for kotlin?
20160925 17:48:12 * monsieur_max (~maxime@anon) has joined #jogamp
20160925 17:49:05 <rmk0> elect: intellij idea
20160925 17:49:24 <elect> community edition?
20160925 17:49:29 <rmk0> yeah
20160925 18:18:42 * caelum19 (b2a78e11@anon) Quit (Ping timeout: 240 seconds)
20160925 18:59:29 * elect (~elect@anon) Quit (Ping timeout: 240 seconds)
20160925 20:04:19 * elect (~elect@anon) has joined #jogamp
20160925 20:22:47 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20160925 20:57:00 * elect (~elect@anon) Quit (Ping timeout: 265 seconds)
20160925 23:48:30 * caelum19 (~Caelum@anon) has joined #jogamp
20160925 23:48:40 * caelum19 (~Caelum@anon) has left #jogamp
20160926 05:23:32 * bigpet (uid25664@anon) Quit (Ping timeout: 265 seconds)
20160926 05:26:21 * bigpet (uid25664@anon) has joined #jogamp
20160926 06:29:39 * elect (~elect@anon) has joined #jogamp
20160926 06:29:47 <elect> morning
20160926 06:29:51 <elect> rmk0,
20160926 06:29:55 <elect> you there?
20160926 06:33:29 <elect> I guess not ^^
20160926 06:33:42 <elect> I'll just sit here and wait for your comeback then ^^
20160926 06:33:47 <elect> in the shadow
20160926 06:33:49 <elect> all alone
20160926 06:33:52 <elect> under the rain
20160926 06:33:55 <elect> and the wind
20160926 06:58:41 * monsieur_max (~maxime@anon) has joined #jogamp
20160926 07:27:37 * jvanek (jvanek@anon) has joined #jogamp
20160926 07:27:37 * Eclesia (~husky@anon) has joined #jogamp
20160926 07:33:31 <Eclesia> moin
20160926 08:10:35 <elect> moin moin
20160926 08:23:23 <elect> I'd like to say that I am in negotiation to make a new group for moving most of my jogl samples
20160926 08:23:30 <elect> on github
20160926 08:23:43 <elect> I'd like to take also this chance to play a little with jogl
20160926 08:23:52 <elect> and fix a couple of bugs I am able to
20160926 08:24:14 <elect> since some time ago the ant affair came up
20160926 08:24:57 <elect> if you would like also to play with that thematic, it'd be nice to do all together
20160926 08:25:08 <elect> what do you think about?
20160926 08:26:38 <zubzub> could summarize the issues & proposed solution (I'm a bit out of the loop)?
20160926 08:27:10 <elect> jogamp dev has stopped since almost one year
20160926 08:27:21 <elect> I have a couple of bugs
20160926 08:27:43 <zubzub> right development has stalled because it's basically a one man project
20160926 08:28:14 <elect> to fix, such as, shaders '#include' without double quotes, glNamedBufferData immutable storage with direct state access, etc..
20160926 08:28:36 <elect> so, in the meanwhile jogamp will be back to normality
20160926 08:28:52 <elect> we can "work/experiment" by ourselves
20160926 08:28:57 <zubzub> solution -> http://jakewins.com/p/clickbait
20160926 08:30:39 <elect> interesting :)
20160926 08:31:06 <elect> I'd also like to make jogl modular
20160926 08:31:35 <elect> with glm, gli, assimp and bullet
20160926 08:32:06 <elect> and a dev immediate gui
20160926 08:32:58 <elect> and openvr and ovr
20160926 08:34:16 <elect> One Lib to rule them all, One Lib to find them, One Lib to bring them all, and in the darkness bind them
20160926 08:35:06 <elect> so guys, what do you think?
20160926 08:35:14 <zubzub> to bad it won't render anything on the screen because it's invisible
20160926 08:35:22 <elect> ^^
20160926 08:36:10 <zubzub> try it out, if it makes people lives easier, people will follow
20160926 09:12:18 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20160926 09:24:14 * monsieur_max (~maxime@anon) has joined #jogamp
20160926 09:52:10 <elect> https://github.com/jogamp-labs
20160926 10:17:34 * caelum19 (~Caelum@anon) has joined #jogamp
20160926 12:29:49 <elect> im trying on intellij that operator overloading plugin
20160926 12:29:51 <elect> it works
20160926 12:30:11 <elect> it is really a pity that Netbeans 7.4+ broke up something
20160926 12:47:24 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20160926 14:25:36 * jvanek (jvanek@anon) Quit (Quit: Leaving)
20160926 14:47:26 <elect> rmk0, what do you think about kotlin compared to java?
20160926 14:48:23 <elect> caelum19, you said you are an exp kotlin dev
20160926 14:48:32 <elect> how much do you use kotlin and how much java
20160926 14:49:39 <rmk0> elect: kotlin has algebraic types, which is a massive, massive advantage
20160926 14:50:23 <zubzub> java has a jobmarket, which is a massive, massive advantage ;)
20160926 14:50:26 <zubzub> /troll
20160926 14:50:44 * zubzub would like to learn kotlin
20160926 14:50:55 <zubzub> but I doubt it would gain me any jobskills :(
20160926 14:51:13 <rmk0> yeah, doesn't have much to offer except for ADTs
20160926 14:52:58 <rmk0> if you're stuck on android, kotlin is drastically more pleasant than the awful pseudo-java-6.5 that android has
20160926 14:53:15 <zubzub> yeah I first need to learn some decent android
20160926 14:53:23 <rmk0> there is no decent android
20160926 14:53:27 <elect> what are your plans for the future, rmk0, switching gradually to kotlin, remain at the windows and see how things change
20160926 14:53:29 <zubzub> problem is, is that the dev tools are so... frustrating
20160926 14:53:40 <elect> do you consider it mature enough to be used in production?
20160926 14:53:57 <rmk0> i've got no plans to move away from java 8
20160926 14:54:11 <elect> so, let's say, it was just an excursion?
20160926 14:54:27 <rmk0> i use kotlin for compilers
20160926 14:54:40 <rmk0> writing compilers without ADTs is excruciating. kotlin is the easiest way to get them
20160926 14:54:52 <rmk0> no particular reason to use it for anything else though
20160926 14:55:32 <elect> and scala?
20160926 14:55:34 <zubzub> you write compilers?
20160926 14:55:36 <zubzub> cool
20160926 14:55:39 <elect> you mentioned it yesterday
20160926 14:55:53 <rmk0> scala's a disaster
20160926 14:55:56 <elect> :D
20160926 14:56:14 <elect> yeah, ok, but why did you try?
20160926 14:56:18 <elect> for curiosity or needing?
20160926 14:56:41 <rmk0> i tried it back in the days of java 7
20160926 14:56:54 <rmk0> kotlin didn't exist at that point and noone else was designing a jvm language that had ADTs
20160926 14:57:05 <elect> interesting
20160926 14:57:27 <elect> than when kotlin was out you just jump on that and left scala
20160926 14:57:32 <elect> in the oblivion ^^
20160926 14:58:03 <rmk0> i didn't leave scala because i never joined it. discovered very early on that the compiler was a mess, the tools were a mess, the language was a mess
20160926 14:58:36 <rmk0> typed functional programming without usable type inference. implicits instead of typeclasses, exploding compilation times, etc
20160926 14:58:53 <rmk0> friend of mine worked at a place where they'd make fun of the scala people upstairs because their application took literally three hours to build
20160926 14:59:04 <elect> anyhow I wonder, although you mention all these problems, it looks like scala got adopted by quite some ppl
20160926 14:59:18 <elect> or it's just my false perception?
20160926 14:59:48 <rmk0> no, it did see quite a bit of adoption. most people have absolutely no idea how to objectively evaluate programming languages though, and it was quite exciting to see a typed functional language on the jvm in the first place
20160926 15:00:16 <elect> and then they were too in to exit
20160926 15:00:34 <rmk0> i have heard of companies dropping scala and moving back to java
20160926 15:00:44 <rmk0> java 8 getting lambda expressions helped
20160926 15:00:47 <elect> uhm
20160926 15:03:52 <rmk0> i once made the scala compiler diverge by trying to call fold()
20160926 15:03:57 * monsieur_max (~maxime@anon) has joined #jogamp
20160926 15:04:16 <elect> mean guy ^^
20160926 15:04:38 <rmk0> is just... very bad
20160926 15:04:46 <rmk0> subtyping does not play nicely with type inference
20160926 15:05:11 <elect> you asked me yesterday why would I need another language
20160926 15:06:00 <elect> another feature I'd like is to eliminate most of boilerplate code
20160926 15:06:12 <elect> not critical off course, but liked
20160926 15:08:54 <rmk0> if you just want something a bit more terse, kotlin is fine
20160926 15:09:06 <rmk0> like i said, it wins by default by not managing to do anything insanely destructive
20160926 15:09:08 <elect> if I think about
20160926 15:09:16 <elect> another feature I'd like
20160926 15:09:26 <elect> is union
20160926 15:09:48 <elect> I can overcame that in java with additional methods
20160926 15:09:49 <rmk0> union?
20160926 15:09:58 <elect> but in C++ is easy
20160926 15:10:26 <elect> when, for example, you define float x, and then you can access the same via 'r'
20160926 15:10:32 <elect> type union?
20160926 15:10:35 <elect> how is it called?
20160926 15:10:50 <rmk0> yeah, untagged unions
20160926 15:11:01 <elect> does kotlin have that?
20160926 15:11:10 <elect> that you know?
20160926 15:11:24 <elect> because from my quick google search, it doesnt look so
20160926 15:11:44 <rmk0> it doesn't have them in the way that C languages have them, because they're type unsafe
20160926 15:12:15 <rmk0> you might be able to get that sort of name overloading (where you can reference a field by name x or by name r) using properties somehow
20160926 15:19:30 <elect> looking at this video "kotlin for java devs" https://www.youtube.com/watch?v=vmjfIRsawlg
20160926 15:19:48 <elect> many things looks natural, like smart casting
20160926 15:20:16 <elect> if you check vs an instance, the object will be automatically casted to that after
20160926 15:20:46 <rmk0> yeah
20160926 15:28:20 * elect (~elect@anon) Quit (Ping timeout: 260 seconds)
20160926 16:03:21 * Eclesia (~husky@anon) has left #jogamp
20160926 16:32:38 * caelum19 (~Caelum@anon) has left #jogamp
20160926 17:01:09 <rmk0> elect: https://kotlinlang.org/docs/reference/properties.html#backing-fields
20160926 17:01:20 <rmk0> var x : Float = 0.0
20160926 17:01:36 <rmk0> var r : Float get() = this.x
20160926 17:01:44 <rmk0> something along those lines, i think
20160926 17:01:58 <rmk0> would probably want to define a setter too
20160926 17:02:26 <rmk0> code using the class sees a property x and a separate property r that appears to be aliasing x
20160926 20:21:36 * monsieur_max (~maxime@anon) Quit (Quit: Leaving.)
20160927 05:05:25 -jogamp- Continue @ http://jogamp.org/log/irc/jogamp_20160927050525.html