Package vavi.sound.mfi

Examples of vavi.sound.mfi.MfiEvent


        mfiMessage.setPanpot(data2 / 2);

        context.setPreviousTick(track, midiEvent.getTick());

        return new MfiEvent[] {
            new MfiEvent(mfiMessage, midiEvent.getTick())
        };
    }
View Full Code Here


            throw new InvalidMfiDataException("no tracks");
        }

        Track track = mfiTracks[0];
        for (int j = 0; j < track.size(); j++) {
            MfiEvent event = track.get(j);
            MfiMessage message = event.getMessage();

            if (message instanceof TempoMessage) {
                return ((TempoMessage) message).getTimeBase();
            }
        }
View Full Code Here

     */
    public HeaderChunk(Sequence sequence) {
        //
        Track track = sequence.getTracks()[0];
        for (int j = 0; j < track.size(); j++) {
            MfiEvent event = track.get(j);
            MfiMessage message = event.getMessage();
            if (message instanceof SubMessage) {
                SubMessage subChunk = (SubMessage) message;
//Debug.println(infoMessage);
                subChunks.put(subChunk.getSubType(), subChunk);
            }
View Full Code Here

     * @param masterVolume in %
     */
    public static MfiEvent getMasterVolumeEvent(int masterVolume) {
        int realMasterVolume = (int) (masterVolume * maxMasterVolume / 100f);
        MfiMessage message = new MasterVolumeMessage(0x00, 0xff, 0xb0, realMasterVolume);
        return new MfiEvent(message, 0l);
    }
View Full Code Here

    /** */
    private static final TempoMessage tempoMessage = new TempoMessage(0x00, 0xff, 0xcb, 100);

    /** @return TempoMessage is always the same instance */
    public static MfiEvent getTempoEvent() {
        return new MfiEvent(tempoMessage, 0l);
    }
View Full Code Here

        mfiMessage.setPitchBendRange(Math.min(data2 / 2, 24));

        context.setPreviousTick(track, midiEvent.getTick());

        return new MfiEvent[] {
            new MfiEvent(mfiMessage, midiEvent.getTick())
        };
    }
View Full Code Here

//Debug.println(mfiMessage.getVoice() + ", " + ((mfiMessage.getMessage()[3] & 0xc0) >> 6));

        context.setPreviousTick(track, midiEvent.getTick());

        return new MfiEvent[] {
            new MfiEvent(mfiMessage, midiEvent.getTick())
        };
    }
View Full Code Here

            events.add(getWaveEvent(R, 1, sampleRate, bits));
        }
        // fill nop
        for (int i = 0; i < delta / Nop2Message.maxDelta; i++) {
            Nop2Message nop2 = new Nop2Message(0xff, 0xff);
            events.add(new MfiEvent(nop2, 0l));
        }
        int moduloOfDelta = delta % Nop2Message.maxDelta;
        Nop2Message nop2 = new Nop2Message(moduloOfDelta % 0x100, moduloOfDelta / 0x100);
        events.add(new MfiEvent(nop2, 0l));

        return events;
    }
View Full Code Here

        function.setSamplingRate(sampleRate);
        function.setSamplingBits(bits);
        function.setContinued(continued);
        function.setAdpcm(adpcm);
        message.setMessage(0x00, function.getMessage());
        return new MfiEvent(message, 0l);
    }
View Full Code Here

        function.setSamplingRate(sampleRate);
        function.setSamplingBits(bits);
        function.setContinued(false);
        function.setAdpcm(new byte[0]);
        message.setMessage(0x00, function.getMessage());
        return new MfiEvent(message, 0l);
    }
View Full Code Here

TOP

Related Classes of vavi.sound.mfi.MfiEvent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.