Group definitions in a mi file?

Reality Server® und Anwendungen.

Group definitions in a mi file?

Postby Mika on Fri Oct 28, 2011 14:56 pm

Exist group defintions in a mi file?
Because i have to turn of visiblity of huge amount of objects
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby Einstein on Fri Oct 28, 2011 16:45 pm

Hi,

yes there are. If you export from 3dsmax with the "new" exportplugin you can export existing groups in the scene.
If you want to create groups on yourself it should work like this.

Code: Select all
instgroup "mygroup_inst"
        "object1_inst"
        "object2_inst"
        "object3_inst"
end instgroup


There is (and has to be) also a root group, in this group every instance should be placed, of course your new generated "my_group_inst" too.

Ciao
Andreas
User avatar
Einstein
Admin
 
Posts: 841
Joined: Sat Sep 29, 2007 9:46 am
Location: Kipfenberg

Re: Group definitions in a mi file?

Postby Mika on Mon Oct 31, 2011 6:41 am

Thanks, Einstein.

Yesterday, i change the content in the .mi files in a text editor....

But i got another problem now:
I implemented a tonemapper again and i cannot access the camera attributes (eg.:focal) anymore :roll:

bye
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby Einstein on Mon Oct 31, 2011 10:24 am

Where do you implemented the tonemapper?
As i know from the bmw project, we implemented the tonemapper in the flash code, right?
Maybe then, you have to edit the camera attributes also there.
Cant imagine why your camera control should not work any longer.

Ciao
User avatar
Einstein
Admin
 
Posts: 841
Joined: Sat Sep 29, 2007 9:46 am
Location: Kipfenberg

Re: Group definitions in a mi file?

Postby Mika on Wed Nov 02, 2011 8:40 am

Where do you implemented the tonemapper?

In the camera.mi file.

As i know from the bmw project, we implemented the tonemapper in the flash code, right?

i did not look into the bmw project.

Tonemapper in the flash code? wtf... i do not think so
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby Einstein on Wed Nov 02, 2011 14:59 pm

Tonemapper in the flash code? wtf... i do not think so

Not directly, but i think Dennis called the function from there.
User avatar
Einstein
Admin
 
Posts: 841
Joined: Sat Sep 29, 2007 9:46 am
Location: Kipfenberg

Re: Group definitions in a mi file?

Postby Seeda on Wed Nov 02, 2011 15:23 pm

Hi Together.

Yes, Andi`s answer is right.
I think you can remember the system of Patrick?!
He put the complete logic out of the model and put it into the app. server.
That means he also gave the order to reality server how the render result should have been tone mapped.

Is it right, Andi ?

But as I can remember we also put some logic into the model, because how could the applikation server know where the position of the camera actually was?
Think about the problem with Interior and Exterior in the freestyle mode. There we had to tell reality server now its interior or exterior. So where was/is the initiator ?

Best regards Seeda.
User avatar
Seeda
Admin
 
Posts: 3784
Joined: Sun Nov 12, 2006 20:25 pm

Re: Group definitions in a mi file?

Postby Mika on Wed Nov 02, 2011 18:58 pm

This was the old version of rs.
The positions are in the scen graph. ergo: you can access & edit them
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby Einstein on Wed Nov 02, 2011 21:15 pm

Yes right, the logic was in the App Server, but the settings where stored in the mi-files of course.
But as I can remember we also put some logic into the model, because how could the applikation server know where the position of the camera actually was?
Think about the problem with Interior and Exterior in the freestyle mode. There we had to tell reality server now its interior or exterior. So where was/is the initiator ?

This was an other problem, you can grab the camera position out of the running scene.
The initiator was a big sphere, wich where place in the interieur. When the camera reached the sphere, the RS changed the tonemapping attributes, but i think this is will not solve Mika´s problem.

So, i only know the file handling of the old RS. There wasnt a camera.mi file.

There was the main_objects.mi and the main_instances.mi

in main_objects all the settings of the camera, also the exposurevalues
Code: Select all
camera "Camera10|Camera"
   environment     = "Environment|Shader"
   lens     = "GBuffer_Lens|Shader"
   focal 24.142136
   aperture 20.000000
   aspect 1.777778
   resolution 1280 720
   window 0 0 1279 719
   offset 0.000000 0.000000
   clip 0.100000 1000000015047466200000000000000.000000
   attribute string "tm_tonemapper" "mia_exposure_photographic"
   attribute scalar "mip_cm2_factor" 1
   attribute color  "mip_whitepoint" 1.042870044708252 0.9838629961013794 1.03357994556427 1
   attribute scalar "mip_film_iso" 100
   attribute scalar "mip_camera_shutter" 512
   attribute scalar "mip_f_number" 8
   attribute scalar "mip_vignetting" 0
   attribute scalar "mip_burn_highlights" 0.25
   attribute scalar "mip_crush_blacks" 0.800000011920929
   attribute scalar "mip_saturation" 1
   attribute scalar "mip_gamma" 1
end camera


in the main_instances the position of the camera was stored, same use as with other objects/instances
Code: Select all
instance "Camera10|Instance"
   "Camera10|Camera"
   visible on
   transform
      0.93041778 0.09176451 -0.35482728 0
      -0.36650077 0.23295802 -0.90078187 0
      -7.4505833e-009 0.96814764 0.25038004 0
      2010.6144 48.802612 -3370.4087 1
   ()
end instance


Maybe you missed to add the camera instance to the SceneRoot|Group?
User avatar
Einstein
Admin
 
Posts: 841
Joined: Sat Sep 29, 2007 9:46 am
Location: Kipfenberg

Re: Group definitions in a mi file?

Postby Mika on Thu Nov 03, 2011 8:39 am

Hm, the best way to determine the problem is to use the same version. You worked with the old version and i work with the latest version. You can test it with the latest free dev./rp version from arc

Maybe you missed to add the camera instance to the SceneRoot|Group?

The cam is in the instances_group.mi file... because without tonemapper i can access the cam attributes....
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby Mika on Thu Nov 03, 2011 12:07 pm

BTW: It´s the same problem in every scene i tested...
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby isaaah on Thu Nov 03, 2011 23:48 pm

mika, can you post a code snippet? i did not try myself but i really can't imagine why you shouldn't be able to access camera properties after having created tonemapper attributes.
do you use the correct commands, i. e camera_get_focal/camera_set_focal?
User avatar
isaaah
User
 
Posts: 11
Joined: Fri Apr 02, 2010 1:28 am

Re: Group definitions in a mi file?

Postby Mika on Fri Nov 04, 2011 14:49 pm

@isaaah:

I use the right commands.
These week, i cannot show code snippets because i´m not at work.

Do you work with RS? Maybe we can exchange our experience some day ;)
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Re: Group definitions in a mi file?

Postby isaaah on Mon Nov 07, 2011 23:20 pm

Mika wrote:@isaaah:
Do you work with RS? Maybe we can exchange our experience some day ;)


i played around with it, mostly exploring the commands and rendering stuff, but did not write a "real" application ...
User avatar
isaaah
User
 
Posts: 11
Joined: Fri Apr 02, 2010 1:28 am

Re: Group definitions in a mi file?

Postby Mika on Tue Nov 08, 2011 9:09 am

@isaaah:
I see. Thanks for your comment
http://www.twitter.com/mika_gmr

"Das Bessere ist der Feind des Guten."
François-Marie Arouet, 1694 - 1778
Mika
Admin
 
Posts: 1807
Joined: Fri Jun 01, 2007 13:38 pm
Location: Berlin & Osterode am Harz, Lower Saxony (Earth)

Return to Reality Server®

Who is online

Users browsing this forum: No registered users and 1 guest