

I ran MGED, made the coil and tried to understand what was happening.
#Brl cad not working how to
There are some relative constraints on the values that these 3 parameters can take, which can be found in Volume III at the end of this topic on how to make a coil using a Pipe. At each vertex (which we call “Control Point”), there is an associated inner diameter, outer diameter and a bend radius. Between every two vertices in the Pipe, there is a segment. Actually, the Pipe is made up of numerous segments. Oh yes, that creativity leads to making a coil using the Pipe primitive. Well, I found out that there was a MGED tutorial (Volume III – Principles of Effective Design) on how to use Pipe creatively, which was also elaborate enough to make me understand what I needed to about Pipe. What happened is that, after I started writing the tests, I was not even halfway through and I realized that I needed to understand what exactly does this Pipe primitive look like and what are the parameters that govern it’s making.
#Brl cad not working Patch
So I was trying to write some tests for the Pipe implementation done by Andrei Popescu, after applying a patch submitted by Andrei Ilinca. I’m enjoying this work and hoping to see more of challenges with time.
#Brl cad not working free
As this was happening, it was not possible to free it right away. Here is how I handled it :īu_free(itr, "Pipe::DeleteControlPoint::itr") This was coming up because the wdb_pipept pointer that was being used to traverse the pipe segment list was always getting modified due to the routine. Wait a minute, there was one more error still popping up : invalid pointer in free(). Size of list growing after each iteration the elements being inserted were also correct.

I tried to understand my error messages and after thinking and searching for reasons, finally came to a conclusion : The destination list entries were not being allocated memory before being inserted into the list and hence the pointers were getting messed up after the first iteration. Moral : Learn to interpret such error messages, because we can’t afford to be perfect all the time. Be a little careless and you screen will be all littered with huge error messages.

Now, as we were dealing with pointers, memory management (allocation and freeing) becomes very crucial. I have learnt how to Google things and I thought that should help right now. I tried printing the list size after each iteration and figured out that the list was getting initialized in first iteration, but getting down to 0 size after first iteration.

And for that, I had to understand what was happening in BU_LIST_* routines and what was causing the output list to be of size 0. Well, I could pull off a decent task of understanding at least what was happening. I was having a hard time because all work was done using pointers and that is not my strong area. I had been trying to understand what exactly was going on in the function since yesterday evening. Yes, finally I understood today that what was the problem in the Pipe implementation and I had found the Big Fish : the function rt_pipe_copy was not working properly and hence was messing up my tests and giving test failures.
