---
title: "Abstraction levels of multimedia programming"
subject: "Multimedia System"
chapter: 7
key: "semester_8/multimedia_system:abstraction-levels-programming"
source: https://www.bctengineer.com/q/semester_8/multimedia_system/abstraction-levels-programming
site: BCT Engineering
---

# Abstraction levels of multimedia programming

Multimedia System · Chapter 7: Abstractions for Programming

- Asked in: 2076 Bhadra, 9 marks; 2075 Bhadra, 9 marks; 2074 Bhadra, 9 marks; 2074 Magh, 9 marks; 2073 Bhadra, 9 marks; 2072 Magh, 9 marks (asked 6 times)
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_8/multimedia_system/abstraction-levels-programming
- Whole chapter: https://www.bctengineer.com/md/semester_8/multimedia_system/chapter-7

## Question

Explain the abstraction levels of the programming of multimedia systems with block diagram.

## Short answer

Multimedia programming has five abstraction levels: device, library/toolkit, system software, higher programming language, and object-oriented. Higher levels hide hardware details, are easier and more portable but less flexible; lower levels give more control and speed. Examples include DirectX, OS multimedia services, and Java Media Framework.

## Answer

Programming a multimedia system can be done at several abstraction levels, from very close to the hardware to very close to the application. A higher level hides more detail and is easier to use, while a lower level gives more control and speed.

```text
+------------------------------------+
|  Applications                      |
+------------------------------------+
|  Object-oriented approaches        |
+------------------------------------+
|  Higher programming languages      |
+------------------------------------+
|  System software (OS, drivers)     |
+------------------------------------+
|  Libraries / toolkits              |
+------------------------------------+
|  Device (hardware)                 |
+------------------------------------+
```

(In Steinmetz's text the levels are: device, library/toolkit, system software, higher programming language, and object-oriented approaches.)

#### 1. Device level
Programming the hardware directly: setting registers of sound cards, video capture cards and graphics controllers. It gives maximum control but is hardware-specific, difficult and not portable. Mostly done by device driver writers.

#### 2. Libraries (toolkit) level
Pre-written routines that wrap device access, such as audio/video capture, playback and image functions. Examples: DirectX, OpenGL, SDL, Windows Media APIs. The programmer calls functions without knowing the hardware, but is limited to what the library offers.

#### 3. System software level
The operating system and its multimedia extensions give services such as device drivers, scheduling for real-time delivery, file systems for continuous media, and the media control interface. Examples: multimedia support in Windows, Linux ALSA, the Android media framework. It provides resource management and synchronisation.

#### 4. Higher programming language level
Multimedia is supported by language constructs or class libraries, so media can be handled by simple statements. Examples: scripting languages such as Lingo (Director), ActionScript, Java with Java Media Framework, Python with pygame. Hardware and system calls are hidden.

#### 5. Object-oriented level
Media and devices are treated as objects (classes) with attributes and methods, reusable and extensible through inheritance. Example: classes such as Video, Audio, Player, Stream, with methods play(), stop(). This supports reuse, modularity and easy construction of complex applications.

**Summary:** moving up the levels reduces programming effort and increases portability, but reduces flexibility and sometimes performance.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. In the answer's block diagram, which level lies directly above the Device (hardware) level?
   A. Object-oriented approaches
   B. System software
   C. Higher programming languages
   D. Libraries / toolkits
   Answer: D. The levels from bottom are device, libraries/toolkits, system software, higher programming languages, object-oriented approaches. (Key point: Level order)

2. Which describes programming at the device level?
   A. Calling reusable classes such as Player with play()
   B. Setting hardware registers of sound or video cards, giving maximum control but not portable
   C. Using simple statements in a scripting language
   D. Using OS scheduling services
   Answer: B. Device-level programming controls hardware directly, which gives maximum control but is hardware-specific and hard. (Key point: Device level)

3. What does a library (toolkit) level such as DirectX or OpenGL provide?
   A. Direct register access to hardware
   B. Inheritance and polymorphism for media objects
   C. Pre-written routines that wrap device access, though limited to what the library offers
   D. Language constructs that hide all system calls
   Answer: C. Libraries offer ready functions so the programmer need not know the hardware, but are limited to what they provide. (Key point: Library level)

4. What is the effect of moving up the abstraction levels?
   A. Less effort and more portability, but less flexibility and sometimes performance
   B. More effort and more control
   C. More hardware dependence and more speed
   D. No change in effort but better flexibility
   Answer: A. Higher levels hide detail, reducing effort and increasing portability, at the cost of flexibility and sometimes performance. (Key point: Trade-off of higher levels)

## Related in Multimedia System

- [Components to build multimedia systems](https://www.bctengineer.com/question.md?key=semester_8%2Fmultimedia_system%3Acomponents-build-multimedia-systems) — Multimedia System, chapter 1
- [Multimedia user interface design process](https://www.bctengineer.com/question.md?key=semester_8%2Fmultimedia_system%3Aui-design-process) — Multimedia System, chapter 6, asked 2×
- [Global structure of multimedia system](https://www.bctengineer.com/question.md?key=semester_8%2Fmultimedia_system%3Aglobal-structure-multimedia-system) — Multimedia System, chapter 1, asked 3×

## Related in other subjects

- [Open and closed loop systems with block diagram](https://www.bctengineer.com/question.md?key=semester_3%2Fcontrol_systems%3Aol-cl-bd-role) — Control Systems, chapter 1, asked 2×
- [Levels of abstraction in computer simulation](https://www.bctengineer.com/question.md?key=semester_8%2Fsimulation_and_modeling%3Acomputer-system-abstraction-levels) — Simulation and Modeling, chapter 10
- [Standard and ladder programming block diagrams](https://www.bctengineer.com/question.md?key=semester_6%2Fdigital_control_system%3Afilter-standard-ladder-block) — Digital Control System, chapter 4
- [Closed loop control system block diagram explained](https://www.bctengineer.com/question.md?key=semester_3%2Fcontrol_systems%3Awhat-is-cs-bd-closed-loop) — Control Systems, chapter 1, asked 4×
