Author Topic: Using OpenLase to Create Text Events  (Read 17397 times)

landshark

  • Newbie
  • *
  • Posts: 35
  • Karma: +0/-0
    • View Profile
Using OpenLase to Create Text Events
« on: February 09, 2014, 05:50:01 AM »
Hi there,

If you see this, thanks Jeff for all the help you've given as I set up Linux and troubleshoot an OpenLase install. I was wondering if you or anybody else could help me with this question:

I'd like to be able to program words to appear in different places, edges, corners, middle, etc, on the surface projected on, at different times. From running examples, I understand at least that open lace can, as it were, load programs, and run them. Mostly, I'm interested in words and text at different places, times, different areas of scrolling on the total surface, and those kinds of things.

Do I need to learn a specific language to do this? Aside from the language and maybe framework I should learn, how would I then turn that code into something OpenLase could load?

Thanks so much.

Best,
Finley

Macpod

  • Administrator
  • Full Member
  • *****
  • Posts: 179
  • Karma: +3/-0
    • View Profile
Re: Using OpenLase to Create Text Events
« Reply #1 on: February 09, 2014, 12:41:32 PM »
To make your own apps, the best thing you can do is look at the example code that does things similar to what you want which are present in the examples folder of your OpenLase install. Tweaking this code (after making a backup) and determining what changed can also be very helpful.

OpenLase is quite similar to OpenGL (but not 100%!.. it has a reduced number of functions) so learning a little bit about OpenGL should be helpful.

You can see what functions are provided by checking out the include directory present in your OpenLase install. ... specifically text.h and libol.h will be of interest.

You can program these in C, or if you have enabled it Python you can use this too.

If you go the C route, you will need to take a look at the cmake build system to learn how to integrate libol into your code.
« Last Edit: February 09, 2014, 12:43:03 PM by Macpod »

landshark

  • Newbie
  • *
  • Posts: 35
  • Karma: +0/-0
    • View Profile
Re: Using OpenLase to Create Text Events
« Reply #2 on: February 10, 2014, 02:40:37 AM »
Alright, thanks! That's very helpful. I have more experience with C but I understand Python is a scripting language. I'll end up going with whatever is easier. I can look in the libol.h and text.h files and they look very interesting. Are there .m files for these to look at?

[deleted post content, I found the .c files!]

So I will look into the 'cmake build system' to see if I can learn enough not to go Python. At least I understand some of the things I'm seeing on those files!

Thanks again,
Finley
« Last Edit: February 10, 2014, 02:45:14 AM by Fstill »

Macpod

  • Administrator
  • Full Member
  • *****
  • Posts: 179
  • Karma: +3/-0
    • View Profile
Re: Using OpenLase to Create Text Events
« Reply #3 on: February 10, 2014, 08:54:58 PM »
If you're familiar with C, stick with that.

.m files are Objective-c files and OpenLase doesn't use these.

C uses the .c extension and you will find those as that's what OpenLase is written in.


landshark

  • Newbie
  • *
  • Posts: 35
  • Karma: +0/-0
    • View Profile
Re: Using OpenLase to Create Text Events
« Reply #4 on: February 11, 2014, 08:11:50 PM »
Ah, gotcha. That makes it easier then. Well, I have a ton to learn about this coding stuff and openGL and libol, a ton.
Until later,
Hasta pronto! Thanks again.
Finley