### Author Topic: Mapping Tiles and Bricks  (Read 10350 times)

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Mapping Tiles and Bricks
« on: September 07, 2015, 04:14:34 PM »
Paul Roberts
iToo Software

#### Bruno NM

• Newbie
• Posts: 30
##### Re: Mapping Tiles and Bricks
« Reply #1 on: January 19, 2016, 10:20:19 PM »
Hi,
I was wondering is there is a way to use the same technique, but which handle corners in arrays2s? Like use a X spline with corners an set an Y distance or use a Y spline ? Because with clipping spline area corners are cut.
In the tutorial parameterising windows i noticed you use a different technique but the problem is bricks are not in quincunx, they are in sequence, in quincunx with corners will be better.
Or we have to use a linear 1s method like into ''Getting Sart Exercice'' the scene Operators_1 ?
I would like to use corners for create windows recess.
I hope you understand my issue.

#### Bruno NM

• Newbie
• Posts: 30
##### Re: Mapping Tiles and Bricks
« Reply #2 on: January 25, 2016, 11:14:30 AM »
Hi,
Since some days i try to figure how to create corner with this method. I try do do the same like in the tutorial but which following a rectangular spline, so that's will handle corner.
In the picture below you see the style create kind of square brick on the corner, and the Google picture show us a corner which is a serie of bricks put above each the previous...
If you have a idea to do this ? I was thinking maybe there is a thing with the conditionnal operator, and actually i do the corner lesson (in next step with RC) perhaps there is the tips i would like to find...
Let me know..

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Re: Mapping Tiles and Bricks
« Reply #3 on: January 26, 2016, 02:53:34 PM »
Hi!

Please see the attached for a possible solution. It use padding values to overlap the corners as you would find in a real wall, these have been extracted automatically from the size of the bricks which is why there are a few more nodes in the graph but it could be simplified by hard coding these values.

Because there's no slicing this style works best when the corners are at 90 degrees. I hope it helps but please let me know if you have any further questions.

Many thanks!

Paul
Paul Roberts
iToo Software

#### Bruno NM

• Newbie
• Posts: 30
##### Re: Mapping Tiles and Bricks
« Reply #4 on: January 26, 2016, 09:22:24 PM »
Pretty good ! Thank you a lot !
Just one question for clarify, why do you use an ''Null'' segment in Y Sequence and Compose operator ? Why this is necessary to this style ?

Just below you see i used this style on a rectangular spline, you notice at the end vertex of the spline there is a gap. Maybe this is due to the brick X size, it's normal there is almost no chance that's will end exactly.
So i wonder if we have to use an arithematic node for X size ?
Perhaps with rectangular splines we don't need an half brick...
In this case (with rectangular spline again), do we consider Right like Start (which is the first vertex) and Left like End (which is the last vertex) ? I say that because this is a loop with corner....

Sorry if i'm a bit confused here, hope you understand my basic English level...
Many thanks again for the time you spend to answer our questions =)

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Re: Mapping Tiles and Bricks
« Reply #5 on: January 27, 2016, 10:45:38 AM »
Hi,

The null segments are used in the Sequence operators to create an empty space instead of a brick. There's one sequence operator for each side of the corner and we need to alternate between a brick and a gap, but offset on each side. Imagine in the column below that 1 = brick and 0 = gap. The null segments are used in this case to create the gaps.

1 | 0
0 | 1
1 | 0
0 | 1
1 | 0
0 | 1

The Null wired to the Compose operator performs a slightly different function. When a compose operator is wired to a corner input the number of attached nodes determines how the segments are placed in relation to the corner vertex. An even number will always result in an asymmetric composition whereas an odd number will be centred. Therefore the  null segment in this case is used to create an odd number of inputs and centre the bricks on the corner. You can read more about this in the "How to Fine Tune Corners" chapter of our Next Steps with RailClone guide.

The corner problem shown in your screen shot is caused by a known issue when using sequence operators on the first vertex in a closed spline that causes a mismatch in the counters. This will be addressed in a future release, but in the meantime it is possible to get around it by giving the first vertex a different type, for example a Bezier-Corner for the first vertex and a Corner for all the others. You can then use a Conditional operator to detect that corner and use an adjusted version of the existing sequence operator. In this case I just needed to swap the order.

I've attached a revised version of the wall to illustrate how this works. I hope that helps clear things up a bit.

Many thanks!

Paul
Paul Roberts
iToo Software

#### Bruno NM

• Newbie
• Posts: 30
##### Re: Mapping Tiles and Bricks
« Reply #6 on: January 31, 2016, 06:20:01 PM »
Thanks a lot !
I still have a problem, i create a rectangular shape, edit spline, convert all vertex in corner, make the first corner in bezier corner. The first two rows at the bottom are not calculeted correctly, but other side are fine.
Did you do something with your spline ? Because in the attachment you post your spline works very well...

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Re: Mapping Tiles and Bricks
« Reply #7 on: February 01, 2016, 11:11:11 AM »
Hi,

I've just checked and actually this problem is present in my example file too. Unfortunately it's caused by the problem I mentioned previously. This bug repeats the first input twice at the start of a Y Sequence counter on the first vertex. Please find attached a fix that resolves this using an expression. I apologise for this bug, it will be fixed in the next version.

Many thanks!

Paul
Paul Roberts
iToo Software

#### Bruno NM

• Newbie
• Posts: 30
##### Re: Mapping Tiles and Bricks
« Reply #8 on: February 01, 2016, 03:12:57 PM »
Really sorry to say that, but i still have a mistake...
I use Raiclone 2.5.0, do i need to update my plugin version ?

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Re: Mapping Tiles and Bricks
« Reply #9 on: February 01, 2016, 04:06:25 PM »
Ah, the sample file was created with the RailClone 2.5.2 beta which should be available from your user panel. There were some changes made to the sequence operators between these two versions. I can't find a workaround that is successful with RC 2.5 so if possible the easiest way to get this to work for now is to update to the beta. Be aware though that this problem will be fixed when the next version is released and this style will no longer work (though it'll be much much simpler to setup).

Thanks!

Paul
Paul Roberts
iToo Software

#### TL1895

• Sr. Member
• Posts: 338
##### Re: Mapping Tiles and Bricks
« Reply #10 on: February 15, 2016, 02:44:07 PM »
Hey that's a nice method! Thanks for asking and answering so well!
TL1895

#### TL1895

• Sr. Member
• Posts: 338
##### Re: Mapping Tiles and Bricks
« Reply #11 on: February 29, 2016, 04:19:00 PM »
I've been trying to adapt this setup to also work with the uvw offset randomizing from the tutorial.
I have gotten almost there, but am stuck with an issue at corners or ends?

Thanks,
TL1895

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Re: Mapping Tiles and Bricks
« Reply #12 on: February 29, 2016, 04:59:59 PM »
Hi,

It's quite a complex style so it's hard to tell from a screen shot but it looks to me like one of the inner corner segments is bypassing the UVW XForm modifiers. That could be the issue?

Thanks!

Paul
Paul Roberts
iToo Software

#### TL1895

• Sr. Member
• Posts: 338
##### Re: Mapping Tiles and Bricks
« Reply #13 on: February 29, 2016, 05:08:38 PM »
Yes, but I have not been able to figure out the solution...I'll try some more, and I can also send you the file, if it would help

#### Paul Roberts

• iToo Software
• Hero Member
• Posts: 1760
##### Re: Mapping Tiles and Bricks
« Reply #14 on: February 29, 2016, 05:14:34 PM »
Hi,

I'd recommend putting the UVW part of the graph after the compose/conditional section otherwise you'll have to duplicate all those nodes again. Feel free to send me the file so I can take a look. I might be able to simplify it for you.

Thanks!

Paul
Paul Roberts
iToo Software