iphone Programming Glossary: sampleadjustmentfactor
Drawing waveform with AVAssetReader http://stackoverflow.com/questions/5032775/drawing-waveform-with-avassetreader imageHeight 2 float channelCount float centerLeft halfGraphHeight float centerRight halfGraphHeight 3 float sampleAdjustmentFactor imageHeight float channelCount float normalizeMax for NSInteger intSample 0 intSample sampleCount intSample SInt16 left.. for NSInteger intSample 0 intSample sampleCount intSample SInt16 left samples float pixels float left pixels sampleAdjustmentFactor CGContextMoveToPoint context intSample centerLeft pixels CGContextAddLineToPoint context intSample centerLeft pixels CGContextSetStrokeColorWithColor.. context leftcolor CGContextStrokePath context if channelCount 2 SInt16 right samples float pixels float right pixels sampleAdjustmentFactor CGContextMoveToPoint context intSample centerRight pixels CGContextAddLineToPoint context intSample centerRight pixels CGContextSetStrokeColorWithColor..
|