Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright 2012-04-26 Werner Randelshofer
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.monte.media.ilbm
Class DRNGColorCycle

    java.lang.Object
      org.monte.media.ilbm.ColorCycle
          org.monte.media.ilbm.DRNGColorCycle

All Implemented Interfaces:
  java.lang.Cloneable

    public class DRNGColorCycle

extends ColorCycle

Implements DRNG color cycling for an IFF ILBM image.

     ILBM DRNG DPaint IV enhanced color cycle chunk
     --------------------------------------------

     set {
         active=1,DPReserved=4
     } drngFlags;

     /* True color cell * /
     typedef struct {
         UBYTE cell;
         UBYTE r;
         UBYTE g;
         UBYTE b;
     } ilbmDRNGDColor;

     /* Color register cell * /
     typedef struct {
         UBYTE cell;
         UBYTE index;
     } ilbmDRNGDIndex;

     /* DRNG chunk. * /
     typedef struct {
         UBYTE min; /* min cell value * /
         UBYTE max; /* max cell value * /
         UWORD rate; /* color cycling rate, 16384 = 60 steps/second * /
         UWORD set drngFlags flags; /* 1=RNG_ACTIVE, 4=RNG_DP_RESERVED * /
         UBYTE ntrue; /* number of DColorCell structs to follow * /
         UBYTE ntregs; /* number of DIndexCell structs to follow * /
         ilbmDRNGDColor[ntrue] trueColorCells;
         ilbmDRNGDIndex[ntregs] colorRegisterCells;
     } ilbmDRangeChunk;

Version:
  1.0.1 2010-11-08 Fixed color cycling rate.
  1.0 2009-12-23 Created.
Author:
  Werner Randelshofer

Nested Class Summary
`static class` | `DRNGColorCycle.Cell`
`static class` | `DRNGColorCycle.DColorCell` True color cell.
`static class` | `DRNGColorCycle.DIndexCell` Color register cell.

Field Summary

Fields inherited from class org.monte.media.ilbm.ColorCycle
`isActive, isBlended, rate, timeScale`

Constructor Summary
`DRNGColorCycle(int rate, int timeScale, int min, int max, boolean isActive, boolean isEHB, DRNGColorCycle.Cell[] cells)`

Method Summary
`void` | `doCycle(int[] rgbs, long time)`
`int` | `getMax()`
`int` | `getMin()`

Methods inherited from class org.monte.media.ilbm.ColorCycle
`clone, getRate, getTimeScale, isActive, isBlended, setBlended`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DRNGColorCycle

    public DRNGColorCycle(int rate,
                          int timeScale,
                          int min,
                          int max,
                          boolean isActive,
                          boolean isEHB,
                          DRNGColorCycle.Cell[] cells)

Parameters:
  `rate` -
  `timeScale` -
  `min` -
  `max` -
  `isActive` -
  `isEHB` -
  `cells` -

Method Detail

### getMin

    public int getMin()

### getMax

    public int getMax()

### doCycle

    public void doCycle(int[] rgbs,
                        long time)

  Specified by:
    `doCycle` in class `ColorCycle`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright 2012-04-26 Werner Randelshofer
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD