forked from forks/ffprobe-wasm
Read frames from file and add to table.
This commit is contained in:
35
www/src/components/Frames.vue
Normal file
35
www/src/components/Frames.vue
Normal file
@@ -0,0 +1,35 @@
|
||||
<template>
|
||||
<div>
|
||||
<h4>Frames</h4>
|
||||
<b-table striped hover :items="frames">
|
||||
<template #cell(frame_type)="data">
|
||||
{{ String.fromCharCode(data.value) }}
|
||||
</template>
|
||||
|
||||
</b-table>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'Frames',
|
||||
props: [''],
|
||||
data() {
|
||||
return {
|
||||
data: null,
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
frames() {
|
||||
const s = [];
|
||||
for (let i = 0; i < this.data.frames.size(); i++) {
|
||||
s.push(this.data.frames.get(i));
|
||||
}
|
||||
return s;
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.data = window.Module.get_frames();
|
||||
},
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user