1

(15 replies, posted in Engine)

Sponk wrote:

Are you sure you used the version from SVN while testing?

sure but ... wait.
I was adding some printf in your code to figure out where the problem was, and... now it works! mumble mumble...  it may be due from some package installed by jstest-gtk. I must try Maratis svn version on freshly installed Ubuntu machine.

Lamberto

2

(15 replies, posted in Engine)

lsusb returns

Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 056a:0010 Wacom Co., Ltd Graphire
Bus 001 Device 006: ID 12bd:d012  
Bus 001 Device 005: ID 058f:6364 Alcor Micro Corp. AU6477 Card Reader Controller
Bus 002 Device 003: ID 0409:005a NEC Corp. HighSpeed Hub
Bus 002 Device 004: ID 046d:09a5 Logitech, Inc. Quickcam 3000 For Business
Bus 002 Device 005: ID 1a1d:8301 Veho 
Bus 002 Device 008: ID 0cf3:3005 Atheros Communications, Inc. AR3011 Bluetooth
Bus 002 Device 007: ID 0409:02b9 NEC Corp. 

joypad is Bus 001 Device 006: ID 12bd:d012

I tried "cat /dev/input/js0" that returns weird characters while pressing joypad buttons (meaning it works)

as final test used jstest-gtk and output is fine

any guess?
Lamberto

3

(15 replies, posted in Engine)

Hi Sponk
this is the code I used for testing

function onSceneUpdate()
    print(getAxis("JOY1_Y"))
    print(isKeyPressed("JOY1_BUTTON1"))
end

just tried on different machine (same OS) with different joypad and I got same result:

0
false

Lamberto

4

(15 replies, posted in Engine)

Ubuntu linux 12.10
current svn compiles without errors
can't get joystick input

5

(6 replies, posted in General)

I used codeblocks too, it's quite easy, it's only matter of path.
let's say you have your copy of Maratis in your home dir /home/yourname/Maratis/
make new directory named, for example, demo/ inside your Maratis directory so you will have Bin/ SDK/ demo/directories
Download the first example from here http://www.maratis3d.org/download/SimpleGamePlugin.zip and unzip it inside demo/ dir
openCodebloks (I'm using version 10.05) click on "create new project" link, choose Shared Library, select c++ as language, as Project title write "Game" as folder to create project insert the full path of plugin directory  /home/yourname/Maratis/demo/SimpleGamePlugin/_GamePlugin/
then add files to the project from  /home/yourname/Maratis/demo/SimpleGamePlugin/_GamePlugin/Sources
in Project -> Build 0ptions... dialog select Search directories tab and add 2 new path: ../../../../SDK/MCore/Includes/ and ../../../../SDK/MEngine/Includes/
choose "release" as build targer and click build button
plugin should build without errors
now you should have a file named libGame.so inside /home/yourname/Maratis/demo/SimpleGamePlugin/_GamePlugin/Game/bin/Release/
rename it Game.so and copy it inside /home/yourname/Maratis/examples/SimpleGamePlugin/
open SimpleGamePlugin.mproj with Maratris editor, run it and voilà

hope this helps
Lamberto

6

(61 replies, posted in Editor)

it would be nice if the file selector could remember last path from session to session, sometime it's tedious rebuild the full path of a project starting from the root.

7

(6 replies, posted in General)

nice, plugins compile and run even under linux too, now, if we could get a little more hints on how make them, it would be great!

8

(24 replies, posted in Engine)

what do you think about adding parallel lights (sunlight)?

9

(36 replies, posted in Scripting)

getting all entities of the scene


1) I've not read the code, so, I'm only guessing, I suppose the entities (if not parented with any other) are children of the current scene, so, the getChilds() function, without any parameter, may return a table of them.

2) even better a new function like this:
getEntities(scene, type, needle) where parameters are optionals. "scene" is needed to get entities from specified scene, "type" specifies the kind of entity you wish returned in the table (objects, sounds, camera, texts or lights), needle is a string useful for getting entities with particular name containing it, for example you may wish to get all objects named enemy (enemy1, enemy2,...) so, as needle you write "enemy"

10

(1 replies, posted in Scripting)

can't find a function for getting all entities present in the scene.
is there a way of getting a table like the  getChilds() does or is this a thing to add in function request topic?

blender final release slightly changed python API again, so, here the updated exporter http://www.officinepixel.net/download/m … 266_v2.zip

pre-built library linkage is only matter of name, it must be named libsndfile.so.1 and must change line 42 of file trunk/dev/var/scons/thirdparty/libsndfile.py

in order to play sounds I found 3 ways that work:
1) make maratis links against system libsndfile (on ubuntu this is a default package, don't know other distros)
2) compile libsndfile without external library (this way ogg files are not played)
3) compile libsndfile with support for external FLAC/Ogg/Vorbis library (plays ogg files but libogg0 must installed on user's system, so this solution is much the same as point 1)

I don't know if there is a way of compiling libsndfile with libogg0 statically linked, this is beyond my knowledge.

Lamberto

I'm working on it

[update]
well, I've verified that the problem is libsndfile.
first of all, ldd MaratisEditor shows how it links against libsndfile.so.1 in system path instead of the one in the boundle. After renaming boundled library it links correctly Anyway this alone doesn't resolve the problem.
I compiled Maratis against system library and only after this operation I've got the sounds properly working.

this happens on both builds, I'm using 32 bit Ubuntu linux.
I'm looking into the source, for now I found that M_fopen opens the file, so, I believe  the problem is elsewhere.

I checked other files (wav and ogg) with the same result. I believe the problem is not the sound format, it seems to me that Maratis , for some reason, fails opening the file. I  tried to move the project folder in case it was a path name issue but nothing changed.

Hello everybody,
it seems I'm stuck in a new trouble.
I'm trying to figure how to manage sounds, so, I added  wav sound file from the editor, set it to loop, but, when I start the game, the console outputs this message:

ERROR Load Sound : unable to read /home/zoiba/Lavoro/Maratis/proj01/sounds/fanfare2.wav file


and I can't hear any sound.
I've compiled Maratris in debug mode but no error come up when I run it with GDB , only the console message.
I'm working on Ubuntu 12.10

it works great!!!
you just forgot the semicolon at the end of line 555
thank you for the quick fix.

this is what the debugger outputs:

Program received signal SIGSEGV, Segmentation fault.
0x080cc62c in MWindow::create (this=0x8397e60, title=0x82d6695 "Maratis", 
    width=800, height=600, colorBits=32, fullscreen=true)
    at MSDK/MGui/Sources/X11/MX11Window.cpp:587
587                rootWindow = RootWindow(display,vi->screen);

I get a segmentation fault when passing the fullscreen parameter to the player.
this happen on 2 machines equipped with ubuntu 12.10 and 12.04 and nvidia graphic cards
searching in the forum I found there was a similar problem in past in this topic http://forum.maratis3d.com/viewtopic.php?id=3&p=2 and it seems it was solved.
is there anybody else experiencing the same error?

Lamberto

Hello everybody,
I'm new to Maratis. I gave a try to the working pipeline and I found that Blender exporter has some trouble with animation on Blender 2.66 RC.
After a little search I discovered where is the problem: template_list function now require 2 more attributes.
Here you can download the fixed version: http://www.officinepixel.net/download/m … er-266.zip

[update]

blender final release slightly changed python API again, so, here the updated exporter http://www.officinepixel.net/download/m … 266_v2.zip

Lamberto