Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Can't import from Leapmotion into image memblock

Author
Message
basicFanatic
7
Years of Service
User Offline
Joined: 7th Jun 2017
Location:
Posted: 23rd Jun 2018 14:10

I created an memblock image with this:
MemImage = CreateMemblockFromImage(LoadImage("bottlebrush.png"))

And then I tried to overwrite it with leap motion data like so:
AGKLeap.SaveLeapImageToMemblock(1,MemImage)

Yet, the original bottlebrush.png data is in the memblock. I know you most likely are not using leap motion, but maybe you will have some suggestions regarding how those memblocks normally are used?

Bengismo
7
Years of Service
User Offline
Joined: 20th Nov 2017
Location: Yorkshire, England
Posted: 23rd Jun 2018 14:44
Are you trying to use the teir 2 command in teir 1??

You could try...

memblock = AGKLeap.SaveLeapImageToMemblock(1)
pic = CreateImageFromMemblock (Memblock)
SetObjectImage( screen, pic, 0 )


Also...Can you check that there is an image available to read from the leap device
integer AGKLeap.ImageCount()
basicFanatic
7
Years of Service
User Offline
Joined: 7th Jun 2017
Location:
Posted: 23rd Jun 2018 15:33
Despite what the manual says, the tier 1 command for AGKLeap.SaveLeapImageToMemblock(1) follows the same logic as tier 2. Since the command doesn't return anything, and that it expect two integers, I can't go memblock = AGKLeap.SaveLeapImageToMemblock(1)

AGKLeap.ImageCount() was a good idea. It returned "2". Turning the leapmotion off made it return "0" ... so there is some sort of contact!

Login to post a reply

Server time is: 2024-11-23 20:50:36
Your offset time is: 2024-11-23 20:50:36