Fast Tracking my BAM/FP comprehension

I remember that video... I think I provided the winged little friend!...the concept of auto orient to camera (camera lookup) is quite popular in general and a very old game technique
 
I remember that video... I think I provided the winged little friend!...the concept of auto orient to camera (camera lookup) is quite popular in general and a very old game technique


I actually did a similar trick on an old video I made with my kids many years ago (2005 I think).

I filmed myself sitting on one of those metal spinning playground things you no longer see. I then manually rotoscoped myself out (like a green screen) and used that video in Lightwave 3D on a flat square object.

Then I did my 3d animation with every object of "me" always moving and facing the camera perfectly in sync with the video image to match the movement of the camera or environment,etc. I was impressed I pulled that off.

Here's a short "making of video" that shows how a dork with minimal resources comes up with this stuff. I think you'll be amused.



For anyone who wants to watch the whole movie (in better quality) here you go. What can I say... i'm a dork. :)

 
To answer another question... it looks like 1000 images are the maximum for Image Lists

1591148047806.png

One trick I use...is to have a transparent image at the end of video sequence. This allows a video to play to the end, then the overlay / hologram will just be invisible when the video is done (instead of being stuck on the last frame). This way you don't need to shuffle multiple overlay layers all the time to fadeout, etc.

I did this with MOTU. and I also used this for the new PinEvent 1.4 pupstream update to make everything visible or invisible...the apron cards, the mini screens... the backbox, dmd, backglass, huds, holograms,etc.

I have 13 different overlay / holograms on each new updated PinEvent table. On startup, they are all using a transparent image. It checks for the pup stream windows. If they dont exist, then they all just stay transparent. If pup is enabled and the specified pup stream windows are found... then the appropriate overlays and holograms will change to the texture used for the stream. It works really nice to help automate all these options.
 
Last edited:
Ah!!! TerryRed the special effects man. When are you moving to Hollywood?
 
very creative Terry! I like it. Would PUP work as a controllable texture on an actual hologram object? If not I could also make a fake holo from a 3d plane in softimage tilted at 45 degrees backward. only problem is the property. the holo work because of it's blending mode (Add/Linear Dodge) this property would have to be added in bam. Other blending mode would be usefull too (Multiply and Overlay per say).

Does anyone have connection to Rafal so we can see if this table template still exist? the feature seem to be there in BAM,
but selecting it does nothing.
 
Last edited:
very creative Terry! I like it. Would PUP work as a controllable texture on an actual hologram object? If not I could also make a fake holo from a 3d plane in softimage tilted at 45 degrees backward. only problem is the property. the holo work because of it's blending mode (Add/Linear Dodge) this property would have to be added in bam. Other blending mode would be usefull too (Multiply and Overlay per say)

The BAM pup plug-in simply streams another program's window into FP to "replace" any texture being used. This window can be pup...or any other program / video player,etc.

What controls the window you are streaming from is up to you (if you can get another program to be controllable from FP script). PuP works because I am triggering it from FP and it's a COM object...so we can access it. Any program that has that capability can be triggered from FP now if you know the code to do so. (its not FP specific code) So I can use the same code on VPX or FP to control pup if it want to.

My PinEvent 1.4 update video shows me using holograms for the apron card video streams, and the mini screen on the playfield. The backglass has a few different overlays that also use the streams. All I do is use BAM to say "switch this texture with that window"... and then it works! Its crazy simple. Doesn't matter if its a hologram with an image list, or an overlay with an image list.... or a bump mapped jaws head... or the playfeild texture... or a drop target... it all works. Its cool!


So I use both holograms and an Overlay image frame to provide the black backing so the hologram isnt transparent. Without that, then its just a hologram.

Again, the limitation is that you must "display" the window to stream from on some kind of monitor / dummy plug,etc.

You could use methods to check for pup plugin window...if it exists then hide current hologram with a mini playfield (or make it sized 0) ... and then change the new pup hologram to switch to the texture that is set to stream. This is what I do for JAWS to hide the billboard and show my hologram instead (if the user enabled that option)


Some silly other examples I did for fun when first trying the plugin...




An example of the code I use. This is just for the Backglass Overlay that streams the pup backglass window. (PUPSCREEN2)

Start the pup plug-in
Dim PP
Set PP = xBAM.Get("PuPPlugin")
If PP Is Nothing Then
AddDebugText "PuP Plugin is missing"
Else
AddDebugText "PuP Plugin has started"
End if

'set what window we use to stream from

Dim usePUP_Stream_Backglass: PUP_Stream_Backglass

usePUP_Stream_Backglass = true

PUP_Stream_Backglass = "PUPSCREEN2"

'check for the window to see if its valid and exits

If usePUP_Stream_Backglass = true then usePUP_Stream_Backglass = PP.IsWindowValid(PUP_Stream_Backglass)

'if window exists, then swap the image list jpg "PUP_BG_Video" with the PUP_Stream_Backglass stream (PUPSCREEN2 window)

If usePUP_Stream_Backglass = true then PP.ShowVideo "PUP_BG_Video", PUP_Stream_Backglass

if usePUP_Stream_Backglass=false then AddDebugText "PS-BG disabled, or " & PUP_Stream_Backglass & " not detected"

'if after all checks are done and the stream is valid...then usePUP_Stream_Backglass is still enabled...so change the image list from frame 1 (transparent TGA) to frame 2 (PUP_BG_Video.jpg which is our stream image)

If usePUP_Stream_Backglass = true then PuP_BG_Video.Frame 2:AddDebugText "PuP Stream-Backglass-using " & PUP_Stream_Backglass


That's it. That's a way to do checks and then show the stream if its all good. Otherwise the table plays like normal without any stream. I do this for the Overlay frame, speaker panel images,etc. It's all controlled by the startup checks.
 
Last edited:
...so as a texture, I guess that an html5 game/animation would work.

as a practical example, do you happen to have a fp new_table (nothing on it but what's on a new table...) with a simple surface getting it's top texture from this concept? I'm a visual learner and too much explanation trigger my ADDH.
 
Here's the github for rav's pup plug-in. The description is a bit out of date because it does do mip mapping now. He includes a simple new table example.

Click on the Green button "Clone or Download" and download the zip. In that zip (in the BAM folder) is the newest BAM pup plugin (copy it to BAM\plugins) . It also has the table example. The page tells you what keys to test it with,etc.




At the super simple basic use...this is all you need.

Start the pup plug-in
Dim PP
Set PP = xBAM.Get("PuPPlugin")


The command to swap the texture with the stream

PP.ShowVideo "the fp texture to swap with the stream-no extension", "the name of the window you want to stream"


That's it. The only thing is you want to delay using it a few seconds after the table starts.... so you can just add that command to a timer or a key press,etc.
 
got the file thx! will play with it later today
 
@polygame

Ask and ye shall receive. A gift from rav this morning! DANG!


=======================================

Part 1:
Part 2:


From ravarcade:

I need to add some explanation to this:
1. if it don't have animation use waveform format ( .obj), because:
- it is text forma and you may search for command in it
- it has: vertices, normals, texture coords.... almost everything needed. Only skeleton animation is missing
- it has *.mtl file associated with it and it can be edited with text editor to add textures.
For models with animations try exporting to FBX format.

2. On my video you can see how i add missing textures to mtl file.
You don't need any other params for materials than texture name defined with map_Kd
To mach all togethere you may do few steps and look in text editor in obj and mtl files
First obj:
- search for mtllib. After it you have name of mtl file. If it is missing you can even add line manually:
mtllib fileWithMaterials.mtl
- search for usemtl. Here you have name of material from mtl. You may copy it to notepad for later.
Second mtl:
- you can remove any other line than startig from newmtl or map_Kd. Nothing else is needed
- after newmtl you have name of material (you can compare it with usemtl in obj
- map_Kd line. Here you can enter name of file with main texture.

All above should be done correctly when you export model from program... but sometimes textures are missig.

3. Additional textures with normal maps and other .....
This is usefull only if you want to use normal map, or specular map.
If you put at end of main texture _DIFF, so instead fester_body_giON.png you will have fester_body_giON_DIFF.png when ModelImporter will try to find additional textures by replacing _DIFF with _NORM. So, if you have fester_body_giON_NORM.png texture on dist it will be loaded as normal map.

This is how you can add normal map to model: make correct texture names.

4. Importing model to FP.
On video you can see line in script:

Set fester = xBAM.CreateModel "fester", 250, 700, 0, 200

That 4 params are 3 coords x,y,z and model height in FP. There is more params, but defaul values are used.

I want to add default values for that params, so in future all you need to enter in script to edit model with bam menu will look:
xBAM.CreateModel "fester"

No additional params, no variable declaration. This will display model on table....

5. CTRL-C is missing.
In BAM menu "Custom models", ctrl+c is not working. I will add it. Thats why i don't bother to write about params to control look, position, size of model. All can be set with BAM menu and ctrl-c will make copy of required commands.

6. Models can have parts. Your fester have 2. You can edit params of part in menu. There are:

Kd: red, green, blue

- color... simple

Ks: red, green, blue, alpha

- color for light reflections + alpha value is used to set balance between (1) color of light source and (2) color of model. That param can be used to make difference between metalic and not-metalic objects (like in PBR)

Rim: red, green, blue, alpha

- rim color for rim effect. Last param is used to control level.. set alpha to 0 and rim effect is off.

Spe: x, y

- x controls angle for specular reflection. Small value = big range (not-metalic object), high value = small range (sharp reflection like for metalic objects). y is another multiplier for this.

In short, just play with values.

You can select "part" of model. Params for "part 0" are used for all parts until you change it. So, until you don't change params for "part 1" it will have same. When select "part 1" and change param, when "part 2" will have different look. See it on my video.

7. You can change params for model (position, size, colors... ) from script. So, you can change look of model in response to what is happening on table.

.... i need coffee

new BAM v291: http://ravarcade.pl/beta/BAM.zip

- ctrl-c in Custom Model menu will work
- no crash when you try to add not existing model
- line: xBAM.CreateModel "name_of_model" works


===========================


I provided that fester model to rav, as a test. It's from a friend's stunning VPX TAF (that uses a lot of pre-rendered baked in textures, and lots of detailed models). Its a very high polygon model...and when loaded into FP the normal way... it took 15 mins to load the table!

As you can see.... it took seconds, and you get the benefit of BAM's Custom Model features so you can make changes in realtime, and also in script!

...and we have a new update for BAM! Fantastic!
 
Last edited:
Works great. Super easy...and works with mini playfield tool!

1591217198812.png


Use the BAM Model Importer to open model. If the object has UV mapping image... then follow his example in the video for changing the mtl file to match the images with the object. Then Save the object as a TGA.

Import the TGA into the Texture Manager (that TGA is the actual object AND the UV texture). You dont place the object on the table in th editor at all.

Then in script... this is all you need to start.

Dim cm_fester
Set cm_fester = xBAM.CreateModel("fester")

fester is our TGA image (object)

Save the table.

Run the table... and model is there... instantly! Fast load times!

Goto the BAM Custom Models menu.... and then make your tweaks and changes for visuals / size / positioning,etc...

When happy just use CTRL+C in the Models menu.

Now you paste this into the script to replace what you have above. This includes your changes.

Dim cm_fester
Set cm_fester = xBAM.CreateModel("fester", 250, 800, 0, 200, 0, 0, -0, True, False)
cm_fester.Kd.Set 0.6, 0.6, 0.6
cm_fester.Ks.Set 0, 0, 0, 1
cm_fester.Rim.Set 1, 1, 1, 0
cm_fester.Spe.Set 1, 1

Now you can use the mini playfield tool to do as you want with it. Pretty neat!
 
share your table when it's done please :)
 

Attachments

  • Fester Test.fpt
    2 MB · Views: 110
Playing around with some old Babylon 5 Lightwave models (I can't convert new ones :( ). This a "Shadow" ship. It's normally black with procedurally generated bump / normal maps (mathmatically created by Lightwave without using any images)... so thats why there's no texture.

I can convert my old creations...but I need to learn how to UV map images since that wasn't a thing back in 1995. :)

1591232843352.png
 
A surprise release today! Now this is a pretty Aliens Legacy Ultimate Pro update!

Didn't you do to Alien model for this @polygame and @wild you did the new sentry gun?

1591234875255.png

1591234886209.png

1591234900971.png
 
you did the new sentry gun?

yes,I provided it to "slam",excellent use for its part .
you could suggest to "slam", that the shadows -maps, can be inserted in TGA mode, and the rolling sound, directly in the script
 
If you want to lighting to look more like in my pics above and below... then make the changes to BAM Post Processing on this line to match:

1591285271307.png



If you are familiar with the mini playfield tool, then you can reposition the motion tracker to the playfield like what I did for my pup stream updates

1591285345004.png

1591285370359.png

1591285395221.png


The change to Post Processing can really bring out the lighting and colours if it's balanced correctly.

It also helps the shadow maps be more visible as well.



The code for mini playfield for the motion tracker example:

1591289931611.png


Just copy and paste this into the script:



Dim MiniPlayField_0 ' Xmin Xmax Ymin Ymax Zmin Zmax CenX CenY CenZ
Set MiniPlayField_0 = xBAM.CreateMiniPlayfield( 13, 133, 954, 1044, 40, 55, 73, 999, 47.5)


' DstX DstY DstZ RotX RotY RotZ Scale Time
Call MiniPlayField_0.MoveTo( 94.6, 461, 94.7, -66.6, 19.8, -10, 0.9, 1)




Is there a way to make text formatted as "code"?
 

Attachments

  • 1591286216814.png
    1591286216814.png
    73.5 KB · Views: 98
Last edited:
in the editor, I don't know. Thx for the share though.
 
in the editor, I don't know. Thx for the share though.

For the mini playfield tool?

You just copy and paste the code into the script. Thats all you need to do to move the motion tracker. I updated it a little.

Update: NVM... you meant making the text as code. :)
 
Last edited:
Good question. We are grabbing the light sabers in a MP. and there is a "with easing" function that no one has every used...but that may be the ticket
 
General chit-chat
Help Users
You can interact with the ChatGPT Bot in any Chat Room and there is a dedicated room. The command is /ai followed by a space and then your ? or inquiry.
ie: /ai What is a EM Pinball Machine?
  • No one is chatting at the moment.
      Chat Bot Mibs Chat Bot Mibs: roachie has left the room.
      Back
      Top