Scolring - Forum

Entraides et échanges autour de la technologie Scol - Informations and exchanges on the Scol technology

Vous pouvez changer la langue de l'interface une fois inscrit - You can change the language once registered

You are not logged in.

#1 15-Aug-2012 00:26:18

Alexandre_Brazil
Member
Registered: 8-Dec-2011
Posts: 227

Distance between markers AR

Hello Friends,

Does anyone have an example of the scene that detects the approach of two markers of AR?
When the marker "A" approaching 1 inches of the marker "B" a hidden object will be shown on the screen.

I thank everyone who can help me.

Offline

#2 16-Aug-2012 13:52:40

Alexandre_Brazil
Member
Registered: 8-Dec-2011
Posts: 227

Re: Distance between markers AR

No one has an example? A suggestion? Help me please ....

Offline

#3 22-Aug-2012 11:07:22

arkeon
Admin. / Scol language & OpenSpace3D developer
From: Nantes
Registered: 30-Mar-2009
Posts: 5,161
Website

Re: Distance between markers AR

Hi !

if you use the same scale on markers and objects you can use the distance plugIT to get an event on closes objects

Offline

#4 8-Sep-2012 12:28:58

NovanNingnong
Member
Registered: 8-Sep-2012
Posts: 52

Re: Distance between markers AR

arkeon wrote:

Hi !

if you use the same scale on markers and objects you can use the distance plugIT to get an event on closes objects

dear admin, i'm on this too, then how to do it?can u give me short tutorial to do this, i'm newbie in openspace3d, thx before really appreciate it smile

Last edited by NovanNingnong (8-Sep-2012 12:30:07)

Offline

#5 8-Sep-2012 13:34:39

arkeon
Admin. / Scol language & OpenSpace3D developer
From: Nantes
Registered: 30-Mar-2009
Posts: 5,161
Website

Re: Distance between markers AR

Welcome smile

to detect the distance on AR objects you must set the same scale on the marker plugIT, if you don't want to use a mesh you can add a dummy on each marker and then use this dummies on the object distance plugIT.

Offline

#6 8-Sep-2012 16:51:49

NovanNingnong
Member
Registered: 8-Sep-2012
Posts: 52

Re: Distance between markers AR

arkeon wrote:

Welcome smile

to detect the distance on AR objects you must set the same scale on the marker plugIT, if you don't want to use a mesh you can add a dummy on each marker and then use this dummies on the object distance plugIT.

thx arkeon, i'll try it now, hope it works:)

Offline

#7 10-Sep-2012 06:28:31

NovanNingnong
Member
Registered: 8-Sep-2012
Posts: 52

Re: Distance between markers AR

dear arkeon the admin, i'd try the distance plugIT, i got 2 dummies with sphere object inside, 2 markers with same scale, but i still confuse about how to get an action, i fill the first object with dummy1, second object with dummy2, there is "distance" right down second object,
Untitledsdsd-1.jpg
what is the unit of that?inch?centimeter?then after i set the distance plugIT what kind of link that i have to connect between the markers and distance plugIT?sorry for asking u a lot of question, im newbie and really need ur help arkeon, thanks before sad

Last edited by NovanNingnong (10-Sep-2012 06:37:43)

Offline

#8 10-Sep-2012 08:47:36

arkeon
Admin. / Scol language & OpenSpace3D developer
From: Nantes
Registered: 30-Mar-2009
Posts: 5,161
Website

Re: Distance between markers AR

Hmm you're right the unit info is missed somewhere hmm
every units in OS3D are meter, on the marker the size is the real size of the marker.

for example if your object is 20cm and the real paper marker size 10cm then you set the marker size to 0.2 if you want your object fit the marker.
but this way the object position will be multiplied by the marker size and then be twice further than a maker with the correct object / marker ratio.
so the distance between objects will be more complicated to get.
the better way is to scale the object to fit the real marker size and set correctly the marker size in the plugIT.

then to detect the distance, if your object is 10cm radius you can set the distance between your object to 0.15 m for example to detect the collision.
then the In event will be throw when the objects are closes. you can then link the In event to a sound plugIT for example.

don't forget that the misc debug console can permit you to trace some data in the console (bottom of OS3D interface).

Offline

#9 13-Sep-2012 10:04:25

NovanNingnong
Member
Registered: 8-Sep-2012
Posts: 52

Re: Distance between markers AR

arkeon wrote:

Hmm you're right the unit info is missed somewhere hmm
every units in OS3D are meter, on the marker the size is the real size of the marker.

for example if your object is 20cm and the real paper marker size 10cm then you set the marker size to 0.2 if you want your object fit the marker.
but this way the object position will be multiplied by the marker size and then be twice further than a maker with the correct object / marker ratio.
so the distance between objects will be more complicated to get.
the better way is to scale the object to fit the real marker size and set correctly the marker size in the plugIT.

then to detect the distance, if your object is 10cm radius you can set the distance between your object to 0.15 m for example to detect the collision.
then the In event will be throw when the objects are closes. you can then link the In event to a sound plugIT for example.

don't forget that the misc debug console can permit you to trace some data in the console (bottom of OS3D interface).

arkeon, could u help me how to make an event for that?im just start to learn how to use the os3d, i really have no idea how to use the distance plugIT, i upload the file, can u modified it?so i can learn it, please?:(

http://www.mediafire.com/?jt8qv18qieprjt6

Offline

#10 13-Sep-2012 10:57:54

arkeon
Admin. / Scol language & OpenSpace3D developer
From: Nantes
Registered: 30-Mar-2009
Posts: 5,161
Website

Re: Distance between markers AR

for example add a misc/debug console plugIT

add the links distance.in->debug.Print with a link param "In"
add the links distance.out->debug.Print with a link param "Out"

to get an idea of the distance value you need for your markers use
add the links distance.Current distance->debug.Print

the current distance will be shown in the log entries (zone at the bottom of plugITs)

so you will be able to set the correct needed distance, for your scene try 0.15000

Offline

#11 15-Sep-2012 15:55:11

Alexandre_Brazil
Member
Registered: 8-Dec-2011
Posts: 227

Re: Distance between markers AR

Hello friends,
I created an example of following the guidelines Arkeon. It worked perfectly.
Follow the link to download the project.
Link Download

Important detail. Print markers 819 and 821 with the exact size of 67mm (0.067 m) each.

Last edited by Alexandre_Brazil (15-Sep-2012 16:14:25)

Offline

#12 15-Sep-2012 16:13:21

iri
Admin. / Scol language & Scol apps developer
From: France
Registered: 22-Feb-2009
Posts: 2,024
Website

Re: Distance between markers AR

Thanks a lot smile

Offline

#13 16-Sep-2012 03:27:51

NovanNingnong
Member
Registered: 8-Sep-2012
Posts: 52

Re: Distance between markers AR

Alexandre_Brazil wrote:

Hello friends,
I created an example of following the guidelines Arkeon. It worked perfectly.
Follow the link to download the project.
Link Download

Important detail. Print markers 819 and 821 with the exact size of 67mm (0.067 m) each.

thanks for help me alex, really helpful..
thanks to arkeon too,
thanks for sharing;)

Offline

Board footer

Powered by FluxBB