Export

There are different ways you can export vectorlists from vecci.

Text export



text export


Text export is the "main" export vecci offers, some other exports are supported (see below) plus there can be user defined exports, with user definitions you can probably export to any imaginable format (if you do know a little bit about java).

Anyway...

The export tab is divided into 2 main sections:

Following features are the same for both sections:

Following types of exports are supported (if possible):

Mov_Draw_VLc_a
This routine moves to the first location specified in vector list,
and then draws lines between the rest of coordinates in the list.
The number of vectors to draw is specified as the first byte in the vector list. The current scale factor is used. The vector list has
the following format:

      count, rel y, rel x, rel y, rel x, ...

ENTRY DP = $D0
      X-reg points to the vector list

EXIT: X-reg points to next byte after list

      D-reg trashed

Draw_VLc
This routine draws vectors between the set of (y,x) points pointed
to by the X register. The number of vectors to draw is specified
as the first byte in the vector list. The current scale factor is
used. The vector list has the following format:

      count, rel y, rel x, rel y, rel x, ...

ENTRY DP = $D0
      X-reg points to the vector list

EXIT: X-reg points to next byte after list

      D-reg trashed

Draw_VLp
This routine draws patterned lines using the vector list pointed to
by the X-register. The current scale factor is used. The vector
list has the following format:

      pattern, rel y, rel x
      pattern, rel y, rel x
      . . .
      . . .
      pattern, rel y, rel x
      0x01

The list is terminated by a pattern byte with the high bit cleared.

ENTRY DP = $D0
      X-reg points to the vector list

EXIT: X-reg points to the terminator byte

      D-reg trashed

Note!
The BIOS Draw_VLp seems to be buggy, for the examples I provided a working version.

Draw_VL_mode
This routine processes the vector list pointed to by the X register.
The current scale factor is used. The vector list has the following
format:

      mode, rel y, rel x,
      mode, rel y, rel x,
      . . .
      . . .
      mode, rel y, rel x,
      0x01

where mode has the following meaning:

      < 0 use the pattern in $C829
      = 0 move to specified endpoint
      = 1 end of list, so return
      > 1 draw to specified endpoint

ENTRY DP = $D0
      X-reg points to the vector list
      $C829 contains the line pattern.

EXIT: X-reg points to next byte after terminator

      D-reg trashed

Looking at the above definitions of these vectorlist types you can gather that not vectorlists can be exported with every list type.
There is one thing all these routines have in common, they all only take relative positioning information. That is the reason why you can export only vectorlists, which can be drawn in one "go".
"In one go" is again relative :-()! Since some formats accept patterns or mode bytes. Using these it is possible to sneak some invisible vectors (pattern = 0) into a list. Thus you can still draw them in one go, but some drawings are simply invisible.

The only possible way to draw totally "disjunct" vectorlists is doing so with a scenario. (You might not use the scenario option with vecci, but drawing two or more vectorlists seperately is just exactly what a scenario does...)

Note:!
The formats: Draw VLx have no way to "place" the vectorlist. The vectorlist is drawn at the "current" place with the first relative coordinate. Keep that in mind, when you wonder why it looks "displaced". (This is espacially queer if you have an animation, these seem to spin around themselfs...)

Note:!
In order to be able to export an animation be sure the "original" single vectors are exportable in the format you wish.

Draw sync list
This routine does not have BIOS pendant, with this type of list output of large non linear vectorlists can be achieved, which additionally are not prone (not very) to vectrex drift.

The list look a lot like the Draw_VL_mode format:

      mode, rel y, rel x,
      mode, rel y, rel x,
      . . .
      . . .
      mode, rel y, rel x,
      0x02

But the behaviour is a bit different. Following mode bytes are supported:

As you see with this list it is possible to "resync" the beam in between drawing of the vectorlist.

For the above mentioned resync to be possible the call to the routine must provide additional information, as:

Examples (runnable) for this type of vectorlist can be generated as for all others.

Note:
The vectorlists build in vecci automatically resync at points in the list which are not connected. One additional parameter can be given to the generation of the list (textfield right beside the button). This is the maximum of vectors that are drawn without a resync (or -1, if only resyncs should be inserted at non connected vectors).

An example of the differences of a synced and not synced vectorlist:



Not synced




synced


Vectorlist export

Look above...

Animation/Scenario export

Animation

In order to be able to save an animation in one format, ALL vectorlists of that animation must be saveable in that format!

If you use rotation, be sure to either have a correct startpoint, or use one of the Mov_Draw... or Mode... formats, otherwise it might happen, that you are "rotating" around the wrong point!

Scenario

Scenarios, since they MUST use positioning, can only ever be saved with the Mov_Draw... or Mode... formats.

Scenarios also make sense if you want to display LARGE vectorlists (say >40 or 50 vectors), since it is very advisable to give the integrators some rest, if you zero them or at least reset them once in a while.

Code export



code export


The following section is the same for vectorlists/animations/scenarios, I won't differentiate here.

Code export has the same prerequisites than the text - "Move..." export. Apart from that it differs greatly from text export.

Using the code export options allows you to export your vectors not as DATA statements, but as code, which actually draws vectors directly. If you are old enough to know the concept behind a library called Xlib (from DOS days) than you might recognize this as a relative to compiled bitmaps (although obviously these are no bitmaps!).

The general logic for the codeexport goes like this:

Thats all - for large vectorlists (or animations/scenarios for that matter) HUGE pieces of code are generated (but nowadays you can bankswitch for all your needs).

The templates provided work fairly well, but they were done more in the spirit of an example than as well optimized code. You as the user can change them to your needs.
Following templates are used:

They (as usually) can be found in the "template" directory! In order to set apropriate vectorinformation following keys are used for replacement in the above files:

User export

Here a user can configure (meaning program) his own export routines. A simple example is given, as of now I will not elaborate these settings.

Other / SVG

The last option to export is to SVG. The SVG export is at the moment very basic, since it only makes use of the "line" command. If you want to reuse the export you are probaby better of if you edit the result in some svg supporting tool (Inkscape?).

The resulting SVG file is always placed in the default vectorlist directory under:
      Vide/xml/vectorlist/