Author Topic: Java inline?  (Read 2934 times)

Offline Betlheem

  • Mc. Print
  • *
  • Posts: 23
  • Viva y operativa
    • View Profile
Java inline?
« on: 2015-Mar-05 »
I have ben looking around the forum and yet not find any post about java and inline in GLBasic but the mention is still abaliable since v11. The help is not helping in this point, so I wonder: is it possible to inline java commands in GLBasic? And so on, it is possible to call funtions, classes, etc from a .java file?

I´m testing a free engine which is able to compile for Win/OSX/Linux/IOS/android and provides all the stuff of the full API in .java files. My goal is to get it working in GLBasic, so a little example on how to get it done will be appreciated.

Offline spacefractal

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 3482
    • View Profile
    • Space Fractal
Re: Java inline?
« Reply #1 on: 2015-Mar-06 »
It's will newer been possible. Glbasic is wrote in c++.

It's only been possible with android, but it's uses own java system using virtual machine, so it's not compatible with normal java. Here it's call java directly, no in-line.
Greedy Mouse - Karma Miwa - Spot Race - CatchOut - Android Extras - is on a vacation trip, home before end of few days in jan.

Offline Betlheem

  • Mc. Print
  • *
  • Posts: 23
  • Viva y operativa
    • View Profile
Re: Java inline?
« Reply #2 on: 2015-Mar-06 »
Ok, thank you for the insight. :)
I will just keep looking for an alternative to enrich GLbasic.

Offline Betlheem

  • Mc. Print
  • *
  • Posts: 23
  • Viva y operativa
    • View Profile
Re: Java inline?
« Reply #3 on: 2015-Mar-08 »
A doubt that came around. Bullet Physics is full coded in C++. So... will be possible to "inline" them?

Offline erico

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 4116
    • View Profile
    • Portfolio
Re: Java inline?
« Reply #4 on: 2015-Mar-08 »
I believe so. :good:
It has been done before to a certain level.

Offline mentalthink

  • Prof. Inline
  • *****
  • Posts: 3338
  • Integrated Brain
    • View Profile
Re: Java inline?
« Reply #5 on: 2015-Mar-08 »
if you want enrich GLbasic Bethlem use C++ (better than C++?¿ faster, hardest?¿***) , for use C++ take a look to make Wrappers, the problem it's any wrapper have his own mode to done....

About bullet obviously you can make a port for GLbasic, in fact I think baccslider make a port of BulletPhysics and running but only in desktop platforms...
http://www.glbasic.com/forum/index.php?topic=7757.0 

***Excuseme but I don't know if you have C++ Skills (me not  =D), but here you have in the "Cristian's tongue" a hyper-fantastic explained C++ training from 0 to a mid-high level--- the guy it's a teacher from the Barcelona University... but really its' the best C++ training/trainer I find in the web , you have "C con Clase" only web very good too, but in some terms it's really complex understand the concepts...

There it's the web, with the path for do the training, you have readings, exercices and obviously the Youtube video and Channels for pick a lot of C++ code.

http://www.minidosis.org/#/
 

Offline spacefractal

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 3482
    • View Profile
    • Space Fractal
Re: Java inline?
« Reply #6 on: 2015-Mar-10 »
Inline include c++ code, so its possible to include c++ code directly.

Glbasic actuelly compiles to cpp files first and then compile the cpp files to various platforms.

Only android platform require Java for its UI system. Android Extras does uses Java calls to Android Virtual Machine, but its only works on Android.
Greedy Mouse - Karma Miwa - Spot Race - CatchOut - Android Extras - is on a vacation trip, home before end of few days in jan.