PyPRP feature question.... Blender Scenes to PRP Files

Announcements and discussion regarding any projects related to Cyan Worlds' Plasma Engine including (but not limited to) CyanWorlds.com Engine, Drizzle, OfflineKI, PyPRP, and libHSPlasma.

PyPRP feature question.... Blender Scenes to PRP Files

Postby Trylon » Sun Jan 06, 2008 6:17 am

I have an interesting question to ask of you.
The reason is that it may significally impact currently used age designs - or perhaps not but that's what the discussion is for...

Basically, my idea is that it would be the most intuitive for builders, to separate prp's based on blender scene.
Currently, you need to add a logic property "page_num" and set the number of the prp that the object must be in - for each object!!

I think that this method is overly complex and annoying, and a more intuitive way would be to separate it based on bender scene.
The new system I propose would simply put each blender scene into a different prp file...

Now, there are obvious drawbacks to this:
  • You can't get an overview of your entire age
  • Existing ages need to be updated - though a conversion script could do that pretty much automatically

Positive points however, would be:
  • It is more obvious how the part of your age looks that is in a certain prp
  • You can better view the relationships between objects
  • It's more or less impossible to put something in another prp by accident...

I'd like opinions please.....
Especially from aloys, as I think ahra pahts is a place expecially influenced by this....
One day I ran through the cleft for the fiftieth time, and found that uru held no peace for me anymore.
User avatar
Trylon
 
Posts: 1446
Joined: Fri Sep 28, 2007 11:08 pm
Location: Gone from Uru

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Aloys » Sun Jan 06, 2008 8:26 am

The idea is quite attractive... I agree that the way Pages are currently handled isn't ideal and would be simplified by this, but the "You can't get an overview of your entire age" part looks quite annoying at first sight, but let's forget it for a second..

I'm not sure Ahra Pahts is the best Age to study for that.. There are nearly 160 PRPs, several hundred thousands of polygons, nearly 9000 objects, that's not exactly your typical Age, it's really an extreme example. But let me have a look.
Right now for Ahra I'm actually using several different blender files (for the city proper, the shells, the larger courtyards) that I export separately (each file has a specific Book with only the needed pages). So in a way it does act like different scenes because the various areas are nicely separate from each other, and when I need to make sure all the objects are properly assigned I just select them all and update the Page property (with Sjaak's Uru Properties script) The one obvious advantage (and the reason I did it in the first place) is that it makes the files much easier to handle for Blender (faster to open/save/close, and much better overall performance when working). When I still had everything in a single file, even when hiding most layers performance was terribly slugish..(undos were especially slow, up to 20 seconds and more). So even if we used the scenes system I'd still keep my pages in separate files for Ahra Pahts, but again AP is quite an extreme Age, and maybe not the best way to test your idea.

My problem with your idea is that as you mention you can't see several scenes at the same time, and there are many cases were you'll need to be able to see several scenes at the same time. For instance if you need to align two objects on different scenes.. Say the outside wall of a mountain on Page1 and the tunnel that goes inside it on Page2; you'd need to see the wall to precisely cut the hole and model the tunnel inside it. I know you get an object to display on several layers, and that's really useful, but I just looked and I can't find a way to display an object on several scenes at the same time; it appears you can only instance objects through scenes.
So in the above example that means you'd first need to model your mountain and the tunnel in a single scene, and only when you are 100% done with the modelling you would move your objects to separate scenes.. (right now I haven't even found how to move an object to a different scene, only found how to duplicate it to a different scene and then to erase the original quite cumbersome). But if for some reason you need to update the entrance of the tunnel you'd need again to have both objects in the same scene... (That happened more than once in the past with Ahra, and that's certainly not a trouble I want to go through again if I can avoid it.)
As I just said you can instance an object through scenes, which would be a work-around, but then what happens during the export? Do we get two duplicate objects? How would we assign it to one PRP rather than the other?..

Also if we go with this system we'd need a way to selectively export PRPs separately as we want. You may not want to export the whole Age if you only changed one PRP. Although I guess that's already the case; that probably a different topic then.

Finally, right now we essentially export only geometry, but in the future, what about GUIs or animations? In Cyan's Ages those are always exported to separate PRPs, I'm not sure why but there must be a reason. Then how would that work? GUIs could easily be put to separate scenes but animations? And again with GUI we might need to put them in relation with objects in other scenes..

All in all I agree this would be a nice way to simplify page assignation, and to avoid wrong assignations, but right now the fact that you can't display several scenes at the same time really seem to be a deal breaker to me. However If we can solve this problem then that system would really seem to me like the way to go.
User avatar
Aloys
 
Posts: 1921
Joined: Sun Oct 21, 2007 7:57 pm
Location: France (GMT +1)

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Trylon » Sun Jan 06, 2008 10:22 am

My problem with your idea is that as you mention you can't see several scenes at the same time, and there are many cases were you'll need to be able to see several scenes at the same time. For instance if you need to align two objects on different scenes.. Say the outside wall of a mountain on Page1 and the tunnel that goes inside it on Page2; you'd need to see the wall to precisely cut the hole and model the tunnel inside it. I know you get an object to display on several layers, and that's really useful, but I just looked and I can't find a way to display an object on several scenes at the same time; it appears you can only instance objects through scenes.


You can link an object to more than one scene by selecting it and doing CTRL+L.
After that it's linked to both scenes, and effectively shown in more than one scene. While any change in one scene will make it change in the other as well.
You'll need to be careful to unlink it from one of them, as a theoretical pyprp export would make a copy of the object for each scene.

So in the above example that means you'd first need to model your mountain and the tunnel in a single scene, and only when you are 100% done with the modelling you would move your objects to separate scenes..


(right now I haven't even found how to move an object to a different scene, only found how to duplicate it to a different scene and then to erase the original quite cumbersome).

I think a script could be made to move objects.

But if for some reason you need to update the entrance of the tunnel you'd need again to have both objects in the same scene... (That happened more than once in the past with Ahra, and that's certainly not a trouble I want to go through again if I can avoid it.)

linking the object to the other scene would allow for changes to be made to the object in both scenes, and after you're done you could delete the link in one of the scenes.

As I just said you can instance an object through scenes, which would be a work-around, but then what happens during the export? Do we get two duplicate objects? How would we assign it to one PRP rather than the other?..

Yes, it would be duplicated for each prp if it stays linked to both. By removing one link (removing it from one scene) you would set it to one prp...

Finally, right now we essentially export only geometry, but in the future, what about GUIs or animations? In Cyan's Ages those are always exported to separate PRPs, I'm not sure why but there must be a reason. Then how would that work? GUIs could easily be put to separate scenes but animations? And again with GUI we might need to put them in relation with objects in other scenes..

I heard that cyan uses a separate .max file for each prp.
And I think that once we implement custom animations, they probably won't be done in the same blender file as the scene, but will require a different export that exports that animation specifically to a separate prp. At the very least, it would have to be done in a different scene anyway, to avoid the animation distorting the other stuff.

But, to be honest, my guess would I think that there will probably be a separate program for making animations.

All in all I agree this would be a nice way to simplify page assignation, and to avoid wrong assignations, but right now the fact that you can't display several scenes at the same time really seem to be a deal breaker to me. However If we can solve this problem then that system would really seem to me like the way to go.


It just came to me that it would be pretty easy to create a script that makes a temporary scene with all objects in other scenes linked to it (and rig it so that it wouldn't be exported). It would be a snapshot moment though, as adding new objects to other scenes wouldn't be reflected in it until the script was run again.
You can then get rid of that scene by just removing it.

Would that be a sufficient solution?
One day I ran through the cleft for the fiftieth time, and found that uru held no peace for me anymore.
User avatar
Trylon
 
Posts: 1446
Joined: Fri Sep 28, 2007 11:08 pm
Location: Gone from Uru

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Kato » Sun Jan 06, 2008 12:03 pm

I was onboard at first, but this is just sounding more complex. I like the ability to paginate objects as I wish, and working in a "unified scene" generated by a script would be cumbersome.

Maybe you could find some middle ground or use both?

-Kato
Image
(explorer card designed and created by me)
User avatar
Kato
 
Posts: 315
Joined: Fri Sep 28, 2007 8:02 pm
Location: South USA

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Nadnerb » Sun Jan 06, 2008 1:10 pm

As much as this sounds like the technically correct way to go, I'm going to have to say I don't like it. The way I work on my ages, I try to do everything so that it looks identical (or as close as possible) in the blender real time view and plasma. (for example, I tend to use duplicate decal meshes instead of multitextures because the blender real time interface doesn't support them and use vertex colors instead of lightXXX properties because the real time (uv texture enabled) lighting is so different between blender and plasma) As a result, I prefer to be able to see everything at once, a few parts, or any combination thereof. Because of this, I usually separate my pages by blender layers. That would be a problem for implementation however, because there are a limited number of layers. I'm going to have to argue for this to remain a property of the objects, rather than separating them among scene files.

Going a little off topic for a bit, most of the changes now seem to be moving away from the real time view, and relying on guesswork as to what the age will really look like in plasma. Historically, my 'most annoying' issues with the plugin have been centered on inconsistencies like the differences in the lighting models, constantly having to set the 'Amb' slider on all my materials so that they don't show up 50% gray in plasma, and having objects with per face UV texture settings ignored in favor of the 'invisible' material button settings. While I realize that the material settings are necessary for things such as environment maps and multi texturing, the default automaterial (for objects with no linked material) should have Amb 1 and check each face uv texture.

Also, the move away from text properties is also starting to make it harder to do a mass change on objects without using a script. Before, I could ctrl+c the col_type property to cover a huge selection of objects in a few seconds. Now that this attribute has been moved to the bounds button, I am once again reduced to individually selecting and activating each object. Could there possibly be scripts included in pyprp to mass set certain attributes which are difficult/impossible to do otherwise? Such as a 'set bounds on all selected objects' script?
Live KI: 34914 MOULa KI: 23247 Gehn KI: 11588 Available Ages: TunnelDemo3, BoxAge, Odema
Nadnerb
 
Posts: 1057
Joined: Fri Sep 28, 2007 8:01 pm
Location: US (Eastern Time)

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Trylon » Sun Jan 06, 2008 2:28 pm

I understand your posts. And I'd like to make two points of my own:
1) I probably explained things a little more complex than they are.
This video: http://www.gryllus.net/Blender/QT_HTML/MultipleCameras.html gives a nice overview of using scenes.

2) One of the design principles of the rewriting could be described in the following words:
"If it can be done the Blender way, do it the blender way. - If it can't, do it the Blender way as much as possible."
The material and texturing interpretation is that it should match the renders of blender as much as possible, and not neccesarily the design view.

The reason for this is quite simple:
When new writers start coming here, they have to learn blender and the plugin.
I remember that when we started - when I started - I tried all sorts of things in blender, only to be disappointed that it had to be done in some obscure way
to be visible in plasma.
To new builders that just learned Blender through a steep learning curve, the way things are implemented should be as logical as possible.
Text properties are just not cutting it with that philosophy.

BTW, that's also why the lights000 properties are removed - PyPRP now uses all the lights in the scene by default, unless you specify "shadeless" in the material, or set a "lightgroup" to set specific lights that the object should react to.... - It can be done the blender way, so we're doing it the blender way...
One day I ran through the cleft for the fiftieth time, and found that uru held no peace for me anymore.
User avatar
Trylon
 
Posts: 1446
Joined: Fri Sep 28, 2007 11:08 pm
Location: Gone from Uru

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Chacal » Sun Jan 06, 2008 2:37 pm

Nadnerb has a point. One of the main annoyances after Blender itself will be the complexity (cumbersome-ness) of testing in Plasma. If we can have a pretty accurate render in Blender itself, this will be much easier.

Also relating to testing, it would be great if all tools (Blender using the plugin, PrpExplorer, etc) had command-line arguments, so that we could write batch files automating all processes.
Chacal


"The weak can never forgive. Forgiveness is an attribute of the strong."
-- Mahatma Gandhi
User avatar
Chacal
 
Posts: 2463
Joined: Tue Nov 06, 2007 2:45 pm
Location: Quebec, Canada

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Trylon » Sun Jan 06, 2008 2:41 pm

Chacal wrote:Nadnerb has a point. One of the main annoyances after Blender itself will be the complexity (cumbersome-ness) of testing in Plasma. If we can have a pretty accurate render in Blender itself, this will be much easier.

Very true - achieving that is one of the goals - and is in line with the "If it can be done the blender way - do it the blender way" philosophy.

Using the uv mappes faces to determine material settings is another can of works however - I have thought of that, but the addition of even more code complexity scared me off for a while :) - I like the idea though. (Though I'd also use the "texface" property to determine if it should be used )

Also relating to testing, it would be great if all tools (Blender using the plugin, PrpExplorer, etc) had command-line arguments, so that we could write batch files automating all processes.


Interesting idea. How do you envision that?
One day I ran through the cleft for the fiftieth time, and found that uru held no peace for me anymore.
User avatar
Trylon
 
Posts: 1446
Joined: Fri Sep 28, 2007 11:08 pm
Location: Gone from Uru

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Kato » Sun Jan 06, 2008 2:55 pm

I have to agree with Nadnerb. The inability to see and work on your Age as a whole with a fairly accurate rendering is a big pitfall.

-Kato
Image
(explorer card designed and created by me)
User avatar
Kato
 
Posts: 315
Joined: Fri Sep 28, 2007 8:02 pm
Location: South USA

Re: PyPRP feature question.... Blender Scenes to PRP Files

Postby Trylon » Sun Jan 06, 2008 3:05 pm

Agreed.

But then the other question would be:
For what do we use prp's?

e.g. - in the case of the kadish alternate vault, there is one prp which has the normal surroundings, and another one that has the alternate surroundings....
Depending on the situation, either one is shown.

I'm just tossing ideas around here btw - but it seems like it woud be a shame not to use scenes on some regard, as they could make desiging something like that kadish stuff a bit easier...

What if we could combine things - like, keeping the properties around, but still allowing those who want to use the different scenes?
One day I ran through the cleft for the fiftieth time, and found that uru held no peace for me anymore.
User avatar
Trylon
 
Posts: 1446
Joined: Fri Sep 28, 2007 11:08 pm
Location: Gone from Uru

Next

Return to Plasma Development

Who is online

Users browsing this forum: No registered users and 3 guests

cron